___JmolDate="$Date: 2013-10-25 16:02:34 -0500 (Fri, 25 Oct 2013) $";___fullJmolProperties="src/org/jmol/viewer/Jmol.properties";___JmolVersion="13.3.8_dev_2013.10.25";
(function(){Math.log10=function(a){return Math.log(a)/2.302585092994046};Clazz.dateToString=Date.prototype.toString;java.lang.Number=Number;if(Clazz.supportsNativeObject)for(var I=0;I<Clazz.extendedObjectMethods.length;I++){var F=Clazz.extendedObjectMethods[I];Number.prototype[F]=JavaObject.prototype[F]}Number.__CLASS_NAME__="Number";Clazz.implementOf(Number,java.io.Serializable);Number.equals=Clazz.innerFunctions.equals;Number.getName=Clazz.innerFunctions.getName;Number.serialVersionUID=Number.prototype.serialVersionUID=
-0x79536ae2f46b2000;$_M(Number,"shortValue",function(){var a=Math.round(this)&65535;return 0>this&&0<a?a-65536:a});$_M(Number,"byteValue",function(){var a=Math.round(this)&255;return 0>this&&0<a?a-256:a});$_M(Number,"intValue",function(){return Math.round(this)&4294967295});$_M(Number,"longValue",function(){return Math.round(this)});$_M(Number,"floatValue",function(){return this.valueOf()});$_M(Number,"doubleValue",function(){return parseFloat(this.valueOf())});$_V(Number,"hashCode",function(){return this.valueOf()});
java.lang.Integer=Integer=function(){Clazz.instantialize(this,arguments)};Clazz.decorateAsType(Integer,"Integer",Number,Comparable,null,!0);Integer.prototype.valueOf=function(){return 0};Integer.toString=Integer.prototype.toString=function(){return 0!=arguments.length?""+arguments[0]:this===Integer?"class java.lang.Integer":""+this.valueOf()};$_k(Integer,function(a){var b=Math.round(a)&4294967295;this.valueOf=function(){return b}});Integer.serialVersionUID=Integer.prototype.serialVersionUID=0x12e2a0a4f7818700;
Integer.MIN_VALUE=Integer.prototype.MIN_VALUE=-2147483648;Integer.MAX_VALUE=Integer.prototype.MAX_VALUE=2147483647;Integer.TYPE=Integer.prototype.TYPE=Integer;$_M(Integer,"bitCount",function(a){a-=a>>>1&1431655765;a=(a&858993459)+(a>>>2&858993459);a=a+(a>>>4)&252645135;a+=a>>>8;return a+(a>>>16)&63},"Number");Integer.bitCount=Integer.prototype.bitCount;$_M(Integer,"numberOfLeadingZeros",function(a){if(0==a)return 32;var b=1;0==a>>>16&&(b+=16,a<<=16);0==a>>>24&&(b+=8,a<<=8);0==a>>>28&&(b+=4,a<<=4);
0==a>>>30&&(b+=2,a<<=2);return b-(a>>>31)},"Number");Integer.numberOfLeadingZeros=Integer.prototype.numberOfLeadingZeros;$_M(Integer,"numberOfTrailingZeros",function(a){if(0==a)return 32;var b=31,c=a<<16;0!=c&&(b-=16,a=c);c=a<<8;0!=c&&(b-=8,a=c);c=a<<4;0!=c&&(b-=4,a=c);c=a<<2;0!=c&&(b-=2,a=c);return b-(a<<1>>>31)},"Number");Integer.numberOfTrailingZeros=Integer.prototype.numberOfTrailingZeros;$_M(Integer,"parseIntRadix",function(a,b){if(null==a)throw new NumberFormatException("null");if(2>b)throw new NumberFormatException("radix "+
b+" less than Character.MIN_RADIX");if(36<b)throw new NumberFormatException("radix "+b+" greater than Character.MAX_RADIX");if(10==b)for(var c=a.length;0<=--c;){var d=a.charCodeAt(c);if(!(48<=d&&57>=d)&&(0<c||43!=d&&45!=d))throw new NumberFormatException("Not a Number : "+a);}c=parseInt(a,b);if(isNaN(c))throw new NumberFormatException("Not a Number : "+a);return c},"String, Number");Integer.parseIntRadix=Integer.prototype.parseIntRadix;$_M(Integer,"parseInt",function(a){return Integer.parseIntRadix(a,
10)},"String");Integer.parseInt=Integer.prototype.parseInt;$_V(Integer,"$valueOf",function(a){return new Integer(a)});Integer.$valueOf=Integer.prototype.$valueOf;$_V(Integer,"equals",function(a){return null==a||!Clazz.instanceOf(a,Integer)?!1:a.valueOf()==this.valueOf()},"Object");Integer.toHexString=Integer.prototype.toHexString=function(a){a.valueOf&&(a=a.valueOf());if(0>a){var b=a&16777215;return(a>>24&255)._numberToString(16)+(b=b._numberToString(16)).substring(b.length-6)}return a._numberToString(16)};
Integer.toOctalString=Integer.prototype.toOctalString=function(a){a.valueOf&&(a=a.valueOf());return a._numberToString(8)};Integer.toBinaryString=Integer.prototype.toBinaryString=function(a){a.valueOf&&(a=a.valueOf());return a._numberToString(2)};Number.toString=Number.prototype.toString=function(a){return 0==arguments.length?""+a:Integer.toHexString(a)};Integer.decode=$_M(Integer,"decode",function(a){var b=10,c=0,d=!1,e;a.startsWith("-")&&(d=!0,c++);a.startsWith("0x",c)||a.startsWith("0X",c)?(c+=
2,b=16):a.startsWith("#",c)?(c++,b=16):a.startsWith("0",c)&&a.length>1+c&&(c++,b=8);if(a.startsWith("-",c))throw new NumberFormatException("Negative sign in wrong position");try{e=Integer.$valueOf(a.substring(c),b),e=d?new Integer(-e.intValue()):e}catch(f){if(Clazz.instanceOf(f,NumberFormatException))a=d?String.instantialize("-"+a.substring(c)):a.substring(c),e=Integer.$valueOf(a,b);else throw f;}return e},"~S");$_V(Integer,"hashCode",function(){return this.valueOf()});java.lang.Long=Long=function(){Clazz.instantialize(this,
arguments)};Clazz.decorateAsType(Long,"Long",Number,Comparable,null,!0);Long.prototype.valueOf=function(){return 0};Long.toString=Long.prototype.toString=function(){return 0!=arguments.length?""+arguments[0]:this===Long?"class java.lang.Long":""+this.valueOf()};Clazz.makeConstructor(Long,function(){this.valueOf=function(){return 0}});Clazz.makeConstructor(Long,function(a){var b=Math.round(a);this.valueOf=function(){return b}},"Number");Clazz.makeConstructor(Long,function(a){var b=Long.parseLong(a,
10);this.valueOf=function(){return b}},"String");Long.serialVersionUID=Long.prototype.serialVersionUID=0x3b8be490cc8f2400;Long.MIN_VALUE=Long.prototype.MIN_VALUE=-9223372036854775E3;Long.MAX_VALUE=Long.prototype.MAX_VALUE=9223372036854775E3;Long.TYPE=Long.prototype.TYPE=Long;$_M(Long,"parseLong",function(a,b){if(null==a)throw new NumberFormatException("null");if(2>b)throw new NumberFormatException("radix "+b+" less than Character.MIN_RADIX");if(36<b)throw new NumberFormatException("radix "+b+" greater than Character.MAX_RADIX");
var c=parseInt(a,b);if(isNaN(c))throw new NumberFormatException("Not a Number : "+a);return c},"String, Number");$_M(Long,"parseLong",function(a){return Long.parseLong(a,10)},"String");Long.parseLong=Long.prototype.parseLong;$_M(Long,"$valueOf",function(a){return new Long(Long.parseLong(a,10))},"String");$_M(Long,"$valueOf",function(a){return new Long(a)},"Number");$_M(Long,"$valueOf",function(a,b){return new Long(Long.parseLong(a,b))},"String, Number");Long.$valueOf=Long.prototype.$valueOf;$_V(Long,
"equals",function(a){return null==a||!Clazz.instanceOf(a,Long)?!1:a.valueOf()==this.valueOf()},"Object");Long.toHexString=Long.prototype.toHexString=function(a){return a.toString(16)};Long.toOctalString=Long.prototype.toOctalString=function(a){return a.toString(8)};Long.toBinaryString=Long.prototype.toBinaryString=function(a){return a.toString(2)};Long.decode=$_M(Long,"decode",function(a){var b=10,c=0,d=!1,e;a.startsWith("-")&&(d=!0,c++);a.startsWith("0x",c)||a.startsWith("0X",c)?(c+=2,b=16):a.startsWith("#",
c)?(c++,b=16):a.startsWith("0",c)&&a.length>1+c&&(c++,b=8);if(a.startsWith("-",c))throw new NumberFormatException("Negative sign in wrong position");try{e=Long.$valueOf(a.substring(c),b),e=d?new Long(-e.longValue()):e}catch(f){if(Clazz.instanceOf(f,NumberFormatException))a=d?String.instantialize("-"+a.substring(c)):a.substring(c),e=Long.$valueOf(a,b);else throw f;}return e},"~S");java.lang.Short=Short=function(){Clazz.instantialize(this,arguments)};Clazz.decorateAsType(Short,"Short",Number,Comparable,
null,!0);Short.prototype.valueOf=function(){return 0};Short.toString=Short.prototype.toString=function(){return 0!=arguments.length?""+arguments[0]:this===Short?"class java.lang.Short":""+this.valueOf()};$_k(Short,function(a){var b=Math.round(a)&4294967295;this.valueOf=function(){return b}});Short.serialVersionUID=Short.prototype.serialVersionUID=0x684d37133460dc00;Short.MIN_VALUE=Short.prototype.MIN_VALUE=-32768;Short.MAX_VALUE=Short.prototype.MAX_VALUE=32767;Short.TYPE=Short.prototype.TYPE=Short;
$_M(Short,"parseShort",function(a,b){if(null==a)throw new NumberFormatException("null");if(2>b)throw new NumberFormatException("radix "+b+" less than Character.MIN_RADIX");if(36<b)throw new NumberFormatException("radix "+b+" greater than Character.MAX_RADIX");var c=parseInt(a,b);if(isNaN(c))throw new NumberFormatException("Not a Number : "+a);return c},"String, Number");Short.parseShort=Short.prototype.parseShort;$_M(Short,"parseShort",function(a){return Short.parseShort(a,10)},"String");Short.parseShort=
Short.prototype.parseShort;$_V(Short,"$valueOf",function(a){return new Short(a)});Short.$valueOf=Short.prototype.$valueOf;$_V(Short,"equals",function(a){return null==a||!Clazz.instanceOf(a,Short)?!1:a.valueOf()==this.valueOf()},"Object");Short.toHexString=Short.prototype.toHexString=function(a){return a.toString(16)};Short.toOctalString=Short.prototype.toOctalString=function(a){return a.toString(8)};Short.toBinaryString=Short.prototype.toBinaryString=function(a){return a.toString(2)};Short.decode=
$_M(Short,"decode",function(a){var b=10,c=0,d=!1,e;a.startsWith("-")&&(d=!0,c++);a.startsWith("0x",c)||a.startsWith("0X",c)?(c+=2,b=16):a.startsWith("#",c)?(c++,b=16):a.startsWith("0",c)&&a.length>1+c&&(c++,b=8);if(a.startsWith("-",c))throw new NumberFormatException("Negative sign in wrong position");try{e=Short.$valueOf(a.substring(c),b),e=d?new Short(-e.shortValue()):e}catch(f){if(Clazz.instanceOf(f,NumberFormatException))a=d?String.instantialize("-"+a.substring(c)):a.substring(c),e=Short.$valueOf(a,
b);else throw f;}return e},"~S");java.lang.Float=Float=function(){Clazz.instantialize(this,arguments)};Clazz.decorateAsType(Float,"Float",Number,Comparable,null,!0);Float.prototype.valueOf=function(){return 0};Float.toString=Float.prototype.toString=function(){return 0!=arguments.length?""+arguments[0]:this===Float?"class java.lang.Float":""+this.valueOf()};$_k(Float,function(a){this.valueOf=function(){return Float.parseFloat(a)}});Float.serialVersionUID=Float.prototype.serialVersionUID=-0x2512365d24c31000;
Float.MIN_VALUE=Float.prototype.MIN_VALUE=3.4028235E38;Float.MAX_VALUE=Float.prototype.MAX_VALUE=1.4E-45;Float.NEGATIVE_INFINITY=Number.NEGATIVE_INFINITY;Float.POSITIVE_INFINITY=Number.POSITIVE_INFINITY;Float.NaN=Number.NaN;Float.TYPE=Float.prototype.TYPE=Float;$_M(Float,"parseFloat",function(a){if(null==a)throw new NumberFormatException("null");if("number"==typeof a)return a;var b=parseFloat(a);if(isNaN(b))throw new NumberFormatException("Not a Number : "+a);return b},"String");Float.parseFloat=
Float.prototype.parseFloat;$_V(Float,"$valueOf",function(a){return new Float(a)});Float.$valueOf=Float.prototype.$valueOf;$_M(Float,"isNaN",function(a){return isNaN(a)},"Number");Float.isNaN=Float.prototype.isNaN;$_M(Float,"isInfinite",function(a){return!isFinite(a)},"Number");Float.isInfinite=Float.prototype.isInfinite;$_V(Float,"equals",function(a){return null==a||!Clazz.instanceOf(a,Float)?!1:a.valueOf()==this.valueOf()},"Object");java.lang.Double=Double=function(){Clazz.instantialize(this,arguments)};
Clazz.decorateAsType(Double,"Double",Number,Comparable,null,!0);Double.prototype.valueOf=function(){return 0};Double.toString=Double.prototype.toString=function(){return 0!=arguments.length?""+arguments[0]:this===Double?"class java.lang.Double":""+this.valueOf()};$_k(Double,function(a){this.valueOf=function(){return Double.parseDouble(a)}});Double.serialVersionUID=Double.prototype.serialVersionUID=-0x7f4c3db5d6940400;Double.MIN_VALUE=Double.prototype.MIN_VALUE=4.9E-324;Double.MAX_VALUE=Double.prototype.MAX_VALUE=
1.7976931348623157E308;Double.NEGATIVE_INFINITY=Number.NEGATIVE_INFINITY;Double.POSITIVE_INFINITY=Number.POSITIVE_INFINITY;Double.NaN=Number.NaN;Double.TYPE=Double.prototype.TYPE=Double;$_M(Double,"isNaN",function(a){return isNaN(a)},"Number");Double.isNaN=Double.prototype.isNaN;$_M(Double,"isInfinite",function(a){return!isFinite(a)},"Number");Double.isInfinite=Double.prototype.isInfinite;$_M(Double,"parseDouble",function(a){if(null==a)throw new NumberFormatException("null");if("number"==typeof a)return a;
var b=parseFloat(a);if(isNaN(b))throw new NumberFormatException("Not a Number : "+a);return b},"String");Double.parseDouble=Double.prototype.parseDouble;$_M(Double,"$valueOf",function(a){return new Double(a)},"Number");Double.$valueOf=Double.prototype.$valueOf;$_V(Double,"equals",function(a){return null==a||!Clazz.instanceOf(a,Double)?!1:a.valueOf()==this.valueOf()},"Object");java.lang.Byte=Byte=function(){Clazz.instantialize(this,arguments)};Clazz.decorateAsType(Byte,"Byte",Number,Comparable,null,
!0);Byte.prototype.valueOf=function(){return 0};Byte.toString=Byte.prototype.toString=function(){return 0!=arguments.length?""+arguments[0]:this===Byte?"class java.lang.Byte":""+this.valueOf()};Clazz.makeConstructor(Byte,function(){this.valueOf=function(){return 0}});Clazz.makeConstructor(Byte,function(a){var b=Math.round(a)&4294967295;this.valueOf=function(){return b}},"Number");Clazz.makeConstructor(Byte,function(a){var b=Byte.parseByte(a,10);this.valueOf=function(){return b}},"String");Byte.serialVersionUID=
Byte.prototype.serialVersionUID=-0x63b19f7b11af0c00;Byte.MIN_VALUE=Byte.prototype.MIN_VALUE=-128;Byte.MAX_VALUE=Byte.prototype.MAX_VALUE=127;Byte.SIZE=Byte.prototype.SIZE=8;Byte.TYPE=Byte.prototype.TYPE=Byte;$_M(Byte,"parseByte",function(a,b){if(null==a)throw new NumberFormatException("null");if(2>b)throw new NumberFormatException("radix "+b+" less than Character.MIN_RADIX");if(36<b)throw new NumberFormatException("radix "+b+" greater than Character.MAX_RADIX");var c=parseInt(a,b);if(isNaN(c))throw new NumberFormatException("Not a Number : "+
a);return c},"String, Number");Byte.parseByte=Byte.prototype.parseByte;$_M(Byte,"parseByte",function(a){return Byte.parseByte(a,10)},"String");Byte.parseByte=Byte.prototype.parseByte;$_M(Byte,"$valueOf",function(a){return new Byte(Byte.parseByte(a,10))},"String");$_M(Byte,"$valueOf",function(a){return new Byte(a)},"Number");$_M(Byte,"$valueOf",function(a,b){return new Byte(Byte.parseByte(a,b))},"String, Number");Byte.$valueOf=Byte.prototype.$valueOf;$_V(Byte,"equals",function(a){return null==a||!Clazz.instanceOf(a,
Byte)?!1:a.valueOf()==this.valueOf()},"Object");Byte.toHexString=Byte.prototype.toHexString=function(a){return a.toString(16)};Byte.toOctalString=Byte.prototype.toOctalString=function(a){return a.toString(8)};Byte.toBinaryString=Byte.prototype.toBinaryString=function(a){return a.toString(2)};Byte.decode=$_M(Byte,"decode",function(a){var b=10,c=0,d=!1,e;a.startsWith("-")&&(d=!0,c++);a.startsWith("0x",c)||a.startsWith("0X",c)?(c+=2,b=16):a.startsWith("#",c)?(c++,b=16):a.startsWith("0",c)&&a.length>
1+c&&(c++,b=8);if(a.startsWith("-",c))throw new NumberFormatException("Negative sign in wrong position");try{e=Byte.$valueOf(a.substring(c),b),e=d?new Byte(-e.byteValue()):e}catch(f){if(Clazz.instanceOf(f,NumberFormatException))a=d?String.instantialize("-"+a.substring(c)):a.substring(c),e=Byte.$valueOf(a,b);else throw f;}return e},"~S");java.lang.B00lean=Boolean;java.lang.Boolean=Boolean=function(){Clazz.instantialize(this,arguments)};if(Clazz.supportsNativeObject)for(I=0;I<Clazz.extendedObjectMethods.length;I++)F=
Clazz.extendedObjectMethods[I],Boolean.prototype[F]=JavaObject.prototype[F];Boolean.__CLASS_NAME__="Boolean";Clazz.implementOf(Boolean,[java.io.Serializable,java.lang.Comparable]);Boolean.equals=Clazz.innerFunctions.equals;Boolean.getName=Clazz.innerFunctions.getName;Boolean.serialVersionUID=Boolean.prototype.serialVersionUID=-0x32df8d7f2a630600;Clazz.overrideConstructor(Boolean,function(a){var b=("string"==typeof a?Boolean.toBoolean(a):a)?!0:!1;this.valueOf=function(){return b}},"~O");Boolean.parseBoolean=
$_M(Boolean,"parseBoolean",function(a){return Boolean.toBoolean(a)},"~S");$_M(Boolean,"booleanValue",function(){return this.valueOf()});Boolean.$valueOf=$_V(Boolean,"$valueOf",function(a){return a?Boolean.TRUE:Boolean.FALSE});Boolean.toString=$_M(Boolean,"toString",function(a){return a?"true":"false"},"~B");$_V(Boolean,"toString",function(){return this.valueOf()?"true":"false"});$_V(Boolean,"hashCode",function(){return this.valueOf()?1231:1237});$_V(Boolean,"equals",function(a){return Clazz.instanceOf(a,
Boolean)?this.booleanValue()==a.booleanValue():!1},"~O");Boolean.getBoolean=$_M(Boolean,"getBoolean",function(a){var b=!1;try{b=Boolean.toBoolean(System.getProperty(a))}catch(c){if(!Clazz.instanceOf(c,IllegalArgumentException)&&!Clazz.instanceOf(c,NullPointerException))throw c;}return b},"~S");$_V(Boolean,"compareTo",function(a){return a.value==this.value?0:this.value?1:-1},"Boolean");Boolean.toBoolean=$_M(Boolean,"toBoolean",($fz=function(a){return null!=a&&a.equalsIgnoreCase("true")},$fz.isPrivate=
!0,$fz),"~S");Boolean.TRUE=Boolean.prototype.TRUE=new Boolean(!0);Boolean.FALSE=Boolean.prototype.FALSE=new Boolean(!1);Boolean.TYPE=Boolean.prototype.TYPE=Boolean;Encoding={UTF8:"utf-8",UTF16:"utf-16",ASCII:"ascii",guessEncoding:function(a){return 239==a.charCodeAt(0)&&187==a.charCodeAt(1)&&191==a.charCodeAt(2)?Encoding.UTF8:255==a.charCodeAt(0)&&254==a.charCodeAt(1)?Encoding.UTF16:Encoding.ASCII},readUTF8:function(a){var b=this.guessEncoding(a),c=0;b==Encoding.UTF8?c=3:b==Encoding.UTF16&&(c=2);
for(b=[];c<a.length;c++){var d=a.charCodeAt(c);if(128>d)b[b.length]=a.charAt(c);else if(192<d&&224>d){d&=31;c++;var e=a.charCodeAt(c)&63,d=(d<<6)+e;b[b.length]=String.fromCharCode(d)}else if(224<=d){d&=15;c++;e=a.charCodeAt(c)&63;c++;var f=a.charCodeAt(c)&63,d=(d<<12)+(e<<6)+f;b[b.length]=String.fromCharCode(d)}}return b.join("")},convert2UTF8:function(a){var b=this.guessEncoding(a),c=0;if(b==Encoding.UTF8)return a;b==Encoding.UTF16&&(c=2);for(var b=Array(0+a.length-c),d=c;d<a.length;d++){var e=a.charCodeAt(d);
if(128>e)b[0+d-c]=a.charAt(d);else if(2047>=e){var f=192+((e&1984)>>6),g=128+(e&63);b[0+d-c]=String.fromCharCode(f)+String.fromCharCode(g)}else f=224+((e&61440)>>12),g=128+((e&4032)>>6),e=128+(e&63),b[0+d-c]=String.fromCharCode(f)+String.fromCharCode(g)+String.fromCharCode(e)}return b.join("")},base64Chars:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".split(""),encodeBase64:function(a){if(null==a||0==a.length)return a;for(var b=Encoding.base64Chars,c=a.length,d=0,e=[],f,g;d<c;)f=
a.charCodeAt(d++),e[e.length]=b[f>>2],d<c?(g=a.charCodeAt(d++),e[e.length]=b[f<<4&48|g>>4],d<c?(f=a.charCodeAt(d++),e[e.length]=b[g<<2&60|f>>6],e[e.length]=b[f&63]):(e[e.length]=b[g<<2&60],e[e.length]="=")):(e[e.length]=b[f<<4&48],e[e.length]="=",e[e.length]="=");return e.join("")},decodeBase64:function(a){if(null==a||0==a.length)return a;var b=Encoding.base64Chars,c=Encoding.xBase64Chars;if(null==Encoding.xBase64Chars){for(var c={},d=0;d<b.length;d++)c[b[d]]=d;Encoding.xBase64Chars=c}for(var b=a.length,
d=0,e=[],f,g,h,k,l=0;d<b&&6E4>l++;)f=c[a.charAt(d++)],g=c[a.charAt(d++)],h=c[a.charAt(d++)],k=c[a.charAt(d++)],e[e.length]=String.fromCharCode(f<<2&255|g>>4),null!=h&&(e[e.length]=String.fromCharCode(g<<4&255|h>>2),null!=k&&(e[e.length]=String.fromCharCode(h<<6&255|k)));return e.join("")}};if(null==String.prototype.$replace){java.lang.String=String;if(Clazz.supportsNativeObject)for(I=0;I<Clazz.extendedObjectMethods.length;I++)F=Clazz.extendedObjectMethods[I],"to$tring"==F||("toString"==F||"equals"==
F||"hashCode"==F)||(String.prototype[F]=JavaObject.prototype[F]);Clazz.implementOf(String,[java.io.Serializable,CharSequence,Comparable]);String.getName=Clazz.innerFunctions.getName;String.serialVersionUID=String.prototype.serialVersionUID=-0x5f0f5bc785c44c00;String.prototype.$replace=function(a,b){if(a==b||0>this.indexOf(a))return""+this;1==a.length?0<="\\$.*+|?^{}()[]".indexOf(a)&&(a="\\"+a):a=a.replace(/([\\\$\.\*\+\|\?\^\{\}\(\)\[\]])/g,function(a,b){return"\\"+b});return this.replace(RegExp(a,
"gm"),b)};String.prototype.$generateExpFunction=function(a){var b=[],c=[],d=0;b[0]="";for(var e=0;e<a.length;e++){var f=a.charAt(e);e!=a.length-1&&"\\"==f?(e++,f=a.charAt(e),"\\"==f&&(b[d]+="\\"),b[d]+=f):e!=a.length-1&&"$"==f?(e++,c[d]=parseInt(a.charAt(e)),d++,b[d]=""):b[d]="\r"==f?b[d]+"\\r":"\n"==f?b[d]+"\\n":"\t"==f?b[d]+"\\t":'"'==f?b[d]+'\\"':b[d]+f}a="f = function (";d=Math.max.apply({},c);for(e=0;e<=d;e++)a+="$"+e,e!=d&&(a+=", ");a+=") { return ";for(e=0;e<b.length-1;e++)a+='"'+b[e]+'" + $'+
c[e]+" + ";a+='"'+b[e]+'"; }';eval(a);return null};String.prototype.replaceAll=function(a,b){return this.replace(RegExp(a,"gm"),this.$generateExpFunction(b))};String.prototype.replaceFirst=function(a,b){return this.replace(RegExp(a,"m"),this.$generateExpFunction(b))};String.prototype.matches=function(a){null!=a&&(a="^("+a+")$");a=this.match(RegExp(a,"gm"));return null!=a&&0!=a.length};String.prototype.regionMatches=function(a,b,c,d,e){if("number"==typeof a||!0!=a&&!1!=a)e=d,d=c,c=b,b=a,a=!1;if(0>
d||0>b||b>this.length-e||d>c.length-e)return!1;b=this.substring(b,b+e);c=c.substring(d,d+e);a&&(b=b.toLowerCase(),c=c.toLowerCase());return b==c};String.prototype.$plit=function(a,b){if(null!=b&&0<b){if(1==b)return this;var c=RegExp("("+a+")","gm"),d=1,e=this.replace(c,function(a){d++;return d==b?"@@_@@":a}),c=RegExp(a,"gm"),c=this.split(c);c.length>b&&(c[b-1]=e.substring(e.indexOf("@@_@@")+5),c.length=b);return c}c=RegExp(a,"gm");return this.split(c)};String.prototype.trim=function(){for(var a=this.length,
b=0;b<a&&" ">=this.charAt(b);)b++;for(;b<a&&" ">=this.charAt(a-1);)a--;return 0<b?this.substring(b,a):this};String.prototype.trim=function(){return this.replace(/^\s+/g,"").replace(/\s+$/g,"")};String.prototype.startsWith_string_number=function(a,b){var c=b,d=0,e=a.length;if(0>b||b>this.length-e)return!1;for(;0<=--e;)if(this.charAt(c++)!=a.charAt(d++))return!1;return!0};String.prototype.startsWith=function(a){return 1==arguments.length?this.startsWith_string_number(arguments[0],0):2==arguments.length?
this.startsWith_string_number(arguments[0],arguments[1]):!1};String.prototype.endsWith=function(a){return this.startsWith(a,this.length-a.length)};String.prototype.equals=function(a){return this.valueOf()==a};String.prototype.equalsIgnoreCase=function(a){return null==a?!1:this==a||this.toLowerCase()==a.toLowerCase()};String.prototype.hash=0;String.prototype.hashCode=function(){var a=this.hash;if(0==a){for(var b=0,c=this.length,d=0;d<c;d++)a=31*a+this.charCodeAt(b++),a&=4294967295;this.hash=a}return a};
String.prototype.getBytes=function(){if(4==arguments.length)return this.getChars(arguments[0],arguments[1],arguments[2],arguments[3]);var a=this;if(1==arguments.length){for(var b=arguments[0].toString().toLowerCase(),c="utf-8 UTF8 us-ascii iso-8859-1 8859_1 gb2312 gb18030 gbk".split(" "),d=!1,e=0;e<c.length;e++)if(c[e]==b){d=!0;break}if(!d)throw new java.io.UnsupportedEncodingException;if("utf-8"==b||"utf8"==b)a=Encoding.convert2UTF8(this)}b=Array(a.length);for(e=d=c=0;e<a.length;e++)c=a.charCodeAt(e),
255<c?(b[d]=26,b[d+1]=c&255,b[d+2]=(c&65280)>>8,d+=2):b[d]=c,d++;return b};String.prototype.compareTo=function(a){if(null==a)throw new java.lang.NullPointerException;for(var b=this.length,c=a.length,d=Math.min(b,c),e=0;e<d;){var f=this.charCodeAt(e),g=a.charCodeAt(e);if(f!=g)return f-g;e++}return b-c};String.prototype.toCharArray=function(){for(var a=Array(this.length),b=0;b<this.length;b++)a[b]=this.charAt(b);return a};String.value0f=String.valueOf;String.valueOf=function(a){if("undefined"==a)return String.value0f();
if(a instanceof Array){if(1==arguments.length)return a.join("");for(var b=arguments[1],c=arguments[2],d=Array(c),e=0;e<c;e++)d[e]=a[b+e];return d.join("")}return""+a};String.prototype.subSequence=function(a,b){return this.substring(a,b)};String.prototype.compareToIgnoreCase=function(a){if(null==a)throw new NullPointerException;var b=this.toUpperCase(),c=a.toUpperCase();if(b==c)return 0;b=this.toLowerCase();c=a.toLowerCase();return b==c?0:b>c?1:-1};String.prototype.contentEquals=function(a){if(this.length!=
a.length())return!1;a=a.getValue();for(var b=0,c=0,d=this.length;0!=d--;)if(this.charCodeAt(b++)!=a[c++])return!1;return!0};String.prototype.getChars=function(a,b,c,d){if(0>a)throw new StringIndexOutOfBoundsException(a);if(b>this.length)throw new StringIndexOutOfBoundsException(b);if(a>b)throw new StringIndexOutOfBoundsException(b-a);if(null==c)throw new NullPointerException;for(var e=0;e<b-a;e++)c[d+e]=this.charAt(a+e)};String.prototype.$concat=String.prototype.concat;String.prototype.concat=function(a){if(null==
a)throw new NullPointerException;return this.$concat(a)};String.prototype.$lastIndexOf=String.prototype.lastIndexOf;String.prototype.lastIndexOf=function(a,b){return null!=b&&0>=b+this.length?-1:null!=b?this.$lastIndexOf(a,b):this.$lastIndexOf(a)};String.prototype.intern=function(){return this.valueOf()};String.copyValueOf=String.prototype.copyValueOf=function(){return 1==arguments.length?String.instantialize(arguments[0]):String.instantialize(arguments[0],arguments[1],arguments[2])};String.indexOf=
function(a,b,c,d,e,f,g){if(g>=c)return 0==f?c:-1;0>g&&(g=0);if(0==f)return g;var h=d[e];g=b+g;c=b+(c-f);a:for(;;){for(;g<=c&&a[g]!=h;)g++;if(g>c)return-1;for(var k=g+1,l=k+f-1,m=e+1;k<l;)if(a[k++]!=d[m++]){g++;continue a}return g-b}};String.instantialize=function(){switch(arguments.length){case 0:return new String;case 1:var a=arguments[0];if("string"==typeof a||a instanceof String)return new String(a);if(a instanceof Array||a instanceof Int32Array){if(0<a.length&&"number"==typeof a[0]){for(var b=
Array(a.length),c=0;c<a.length;c++)b[c]=String.fromCharCode(a[c]&255);return Encoding.readUTF8(b.join(""))}return a.join("")}if("StringBuffer"==a.__CLASS_NAME__||"java.lang.StringBuffer"==a.__CLASS_NAME__){for(var b=a.shareValue(),d=a.length(),a=Array(d),c=0;c<d;c++)a[c]=b[c];return a.join("")}return""+a;case 2:return a=arguments[0],d=arguments[1],"string"==typeof d?String.instantialize(a,0,a.length,d):String.instantialize(a,d,0,a.length);case 3:var a=arguments[0],e=arguments[1],d=arguments[2];arguments[2]instanceof
Array&&(a=arguments[2],e=arguments[0],d=arguments[1]);b=Array(d);if(0>e||d+e>a.length)throw new IndexOutOfBoundsException;if(0<d)if(null!=a[e].length)for(c=0;c<d;c++)b[c]=a[e+c];else for(c=0;c<d;c++)b[c]=String.fromCharCode(a[e+c]);return b.join("");case 4:var a=arguments[0],f=arguments[3];if("string"==typeof f||f instanceof String){e=arguments[1];d=arguments[2];b=Array(d);for(c=0;c<d;c++)b[c]=a[e+c],"number"==typeof b[c]&&(b[c]=String.fromCharCode(b[c]&255));c=f.toLowerCase();return"utf-8"==c||"utf8"==
c?Encoding.readUTF8(b.join("")):b.join("")}c=arguments[3];e=arguments[2];d=arguments[1];b=Array(c);if(0==d)for(;0<c--;)b[c]=String.fromCharCode(a[c+e]&255);else for(d<<=8;0<c--;)b[c]=String.fromCharCode(d|a[c+e]&255);return b.join("");default:b="";for(c=0;c<arguments.length;c++)b+=arguments[c];return b}};-1!=navigator.userAgent.toLowerCase().indexOf("chrome")&&(String.prototype.toString=function(){return this})}c$=$_C(function(){this.value=0;$_Z(this,arguments)},java.lang,"Character",null,[java.io.Serializable,
Comparable]);$_K(c$,function(a){this.value=a},"~N");$_M(c$,"charValue",function(){return this.value});$_V(c$,"hashCode",function(){return this.value.charCodeAt(0)});$_V(c$,"equals",function(a){return $_O(a,Character)?this.value.charCodeAt(0)==a.charValue().charCodeAt(0):!1},"~O");$_V(c$,"compareTo",function(a){return this.value.charCodeAt(0)-a.value.charCodeAt(0)},"Character");c$.toLowerCase=$_M(c$,"toLowerCase",function(a){return(""+a).toLowerCase().charAt(0)},"~N");c$.toUpperCase=$_M(c$,"toUpperCase",
function(a){return(""+a).toUpperCase().charAt(0)},"~N");c$.isDigit=$_M(c$,"isDigit",function(a){if(48<=a.charCodeAt(0)&&57>=a.charCodeAt(0))return!0;a.charCodeAt(0);return!1},"~N");c$.isUpperCase=$_M(c$,"isUpperCase",function(a){return 65<=a.charCodeAt(0)&&90>=a.charCodeAt(0)?!0:!1},"~N");c$.isLowerCase=$_M(c$,"isLowerCase",function(a){return 97<=a.charCodeAt(0)&&122>=a.charCodeAt(0)?!0:!1},"~N");c$.isWhitespace=$_M(c$,"isWhitespace",function(a){return 28<=a.charCodeAt(0)&&32>=a.charCodeAt(0)||9<=
a.charCodeAt(0)&&13>=a.charCodeAt(0)||5760==a.charCodeAt(0)?!0:8192>a.charCodeAt(0)||8199==a.charCodeAt(0)?!1:8203>=a.charCodeAt(0)||8232==a.charCodeAt(0)||8233==a.charCodeAt(0)||12288==a.charCodeAt(0)},"~N");c$.isLetter=$_M(c$,"isLetter",function(a){if(65<=a.charCodeAt(0)&&90>=a.charCodeAt(0)||97<=a.charCodeAt(0)&&122>=a.charCodeAt(0))return!0;a.charCodeAt(0);return!1},"~N");c$.isLetterOrDigit=$_M(c$,"isLetterOrDigit",function(a){return Character.isLetter(a)||Character.isDigit(a)},"~N");c$.isSpaceChar=
$_M(c$,"isSpaceChar",function(a){return 32==a.charCodeAt(0)||160==a.charCodeAt(0)||5760==a.charCodeAt(0)?!0:8192>a.charCodeAt(0)?!1:8203>=a.charCodeAt(0)||8232==a.charCodeAt(0)||8233==a.charCodeAt(0)||8239==a.charCodeAt(0)||12288==a.charCodeAt(0)},"~N");c$.digit=$_M(c$,"digit",function(a,b){if(2<=b&&36>=b&&128>a.charCodeAt(0)){var c=-1;48<=a.charCodeAt(0)&&57>=a.charCodeAt(0)?c=a.charCodeAt(0)-48:97<=a.charCodeAt(0)&&122>=a.charCodeAt(0)?c=a.charCodeAt(0)-87:65<=a.charCodeAt(0)&&90>=a.charCodeAt(0)&&
(c=a.charCodeAt(0)-55);return c<b?c:-1}return-1},"~N,~N");$_V(c$,"toString",function(){return String.valueOf([this.value])});c$.toString=$_V(c$,"toString",function(a){return this===Character?"class java.lang.Character":String.valueOf(a)},"~N");$_S(c$,"MIN_VALUE","\x00","MAX_VALUE","\uffff","MIN_RADIX",2,"MAX_RADIX",36,"TYPE",null);java.lang.Character.TYPE=java.lang.Character.prototype.TYPE=java.lang.Character;Array.getComponentType=function(){return Object};c$=$_T(java.lang.reflect,"Array");c$.newInstance=
$_M(c$,"newInstance",function(){return $_A(length)},"Class,~N");java.util.Date=Date;Clazz.decorateAsType(java.util.Date,"java.util.Date",null,[java.io.Serializable,Cloneable,Comparable]);java.util.Date.prototype.toString=Clazz.dateToString;$_M(java.util.Date,"clone",function(){return new Date(this.getTime())});$_M(java.util.Date,"before",function(a){return this.getTime()<a.getTime()},"java.util.Date");$_M(java.util.Date,"after",function(a){return this.getTime()>a.getTime()},"java.util.Date");$_M(java.util.Date,
"equals",function(a){return Clazz.instanceOf(a,java.util.Date)&&this.getTime()==a.getTime()},"Object");$_M(java.util.Date,"compareTo",function(a){var b=this.getTime();a=a.getTime();return b<a?-1:b==a?0:1},"java.util.Date");$_M(java.util.Date,"compareTo",function(a){return this.compareTo(a)},"Object");$_V(java.util.Date,"hashCode",function(){var a=this.getTime();return parseInt(a)^parseInt(a>>32)});c$=$_C(function(){this.source=null;$_Z(this,arguments)},java.util,"EventObject",null,java.io.Serializable);
$_K(c$,function(a){if(null!=a)this.source=a;else throw new IllegalArgumentException;},"~O");$_M(c$,"getSource",function(){return this.source});$_V(c$,"toString",function(){return this.getClass().getName()+"[source="+String.valueOf(this.source)+"]"});$_I(java.util,"EventListener");c$=$_C(function(){this.listener=null;$_Z(this,arguments)},java.util,"EventListenerProxy",null,java.util.EventListener);$_K(c$,function(a){this.listener=a},"java.util.EventListener");$_M(c$,"getListener",function(){return this.listener});
$_I(java.util,"Iterator");$_I(java.util,"ListIterator",java.util.Iterator);$_I(java.util,"Enumeration");$_I(java.util,"Collection",Iterable);$_I(java.util,"Set",java.util.Collection);$_I(java.util,"Map");$_I(java.util.Map,"Entry");$_I(java.util,"List",java.util.Collection);$_I(java.util,"Queue",java.util.Collection);$_I(java.util,"RandomAccess");c$=$_C(function(){this.stackTrace=this.cause=this.detailMessage=null;$_Z(this,arguments)},java.lang,"Throwable",null,java.io.Serializable);$_Y(c$,function(){this.cause=
this});$_K(c$,function(){this.fillInStackTrace()});$_K(c$,function(a){this.fillInStackTrace();this.detailMessage=a},"~S");$_K(c$,function(a,b){this.fillInStackTrace();this.detailMessage=a;this.cause=b},"~S,Throwable");$_K(c$,function(a){this.fillInStackTrace();this.detailMessage=null==a?null:a.toString();this.cause=a},"Throwable");$_M(c$,"getMessage",function(){return"undefined"!=typeof this.message?this.message:this.detailMessage});$_M(c$,"getLocalizedMessage",function(){return this.getMessage()});
$_M(c$,"getCause",function(){return this.cause===this?null:this.cause});$_M(c$,"initCause",function(a){if(this.cause!==this)throw new IllegalStateException("Can't overwrite cause");if(a===this)throw new IllegalArgumentException("Self-causation not permitted");this.cause=a;return this},"Throwable");$_V(c$,"toString",function(){var a=this.getClass().getName(),b=this.getLocalizedMessage();return null!=b?a+": "+b:a});$_M(c$,"printStackTrace",function(){System.err.println(this);for(var a=0;a<this.stackTrace.length;a++){var b=
this.stackTrace[a],c=b.methodName.indexOf("(");("construct"!=b.methodName.substring(0,c).replace(/\s+/g,"")||null==b.nativeClazz||0>Clazz.getInheritedLevel(b.nativeClazz,Throwable))&&System.err.println(b)}});$_M(c$,"printStackTrace",function(){this.printStackTrace()},"java.io.PrintStream");$_M(c$,"printStackTrace",function(){this.printStackTrace()},"java.io.PrintWriter");$_M(c$,"fillInStackTrace",function(){this.stackTrace=[];for(var a=arguments.callee.caller,b=null,c=[],d=Clazz.callingStackTraces.length-
1,e=!0;-1<d||null!=a;){var f=null;if(!e||a==Clazz.tryToSearchAndExecute||a==$_U||null==a){if(0>d)break;e=!0;b=Clazz.callingStackTraces[d].caller;f=Clazz.callingStackTraces[d].owner;d--}else b=a,null!=b.claxxOwner?f=b.claxxOwner:null!=b.exClazz&&(f=b.exClazz);a=new StackTraceElement(null!=f&&0!=f.__CLASS_NAME__.length?f.__CLASS_NAME__:"anonymous",(null==b.exName?"anonymous":b.exName)+" ("+Clazz.getParamsType(b.arguments)+")",null,-1);a.nativeClazz=f;this.stackTrace[this.stackTrace.length]=a;for(f=
0;f<c.length;f++)c[f]==b&&(a=new StackTraceElement("lost","missing",null,-3),a.nativeClazz=null,this.stackTrace[this.stackTrace.length]=a,e=!1);null!=b&&(c[c.length]=b);a=b.arguments.callee.caller}Clazz.initializingException=!1;return this});$_M(c$,"setStackTrace",function(a){a=a.clone();for(var b=0;b<a.length;b++)if(null==a[b])throw new NullPointerException("stackTrace["+b+"]");this.stackTrace=a},"~A");c$=$_C(function(){this.fileName=this.methodName=this.declaringClass=null;this.lineNumber=0;$_Z(this,
arguments)},java.lang,"StackTraceElement",null,java.io.Serializable);$_K(c$,function(a,b,c,d){if(null==a||null==b)throw new NullPointerException;this.declaringClass=a;this.methodName=b;this.fileName=c;this.lineNumber=d},"~S,~S,~S,~N");$_V(c$,"equals",function(a){if(!$_O(a,StackTraceElement)||(null==this.methodName||null==a.methodName)||!this.getMethodName().equals(a.getMethodName())||!this.getClassName().equals(a.getClassName()))return!1;var b=this.getFileName();if(null==b){if(null!=a.getFileName())return!1}else if(!b.equals(a.getFileName()))return!1;
return this.getLineNumber()!=a.getLineNumber()?!1:!0},"~O");$_M(c$,"getClassName",function(){return null==this.declaringClass?"<unknown class>":this.declaringClass});$_M(c$,"getFileName",function(){return this.fileName});$_M(c$,"getLineNumber",function(){return this.lineNumber});$_M(c$,"getMethodName",function(){return null==this.methodName?"<unknown method>":this.methodName});$_V(c$,"hashCode",function(){return null==this.methodName?0:this.methodName.hashCode()^this.declaringClass.hashCode()});$_M(c$,
"isNativeMethod",function(){return-2==this.lineNumber});$_V(c$,"toString",function(){var a=new StringBuilder(80);a.append(this.getClassName());a.append(".");a.append(this.getMethodName());if(this.isNativeMethod())a.append("(Native Method)");else{var b=this.getFileName();if(null==b)a.append("(Unknown Source)");else{var c=this.getLineNumber();a.append("(");a.append(b);0<=c&&(a.append(":"),a.append(c));a.append(")")}}return a.toString()});c$=$_T(java.lang,"Error",Throwable);c$=$_T(java.lang,"LinkageError",
Error);c$=$_T(java.lang,"IncompatibleClassChangeError",LinkageError);c$=$_T(java.lang,"AbstractMethodError",IncompatibleClassChangeError);c$=$_T(java.lang,"AssertionError",Error);$_K(c$,function(a){$_R(this,AssertionError,[String.valueOf(a),$_O(a,Throwable)?a:null])},"~O");$_K(c$,function(a){this.construct(String.valueOf(a))},"~B");$_K(c$,function(a){this.construct(String.valueOf(a))},"~N");$_K(c$,function(a){this.construct(Integer.toString(a))},"~N");$_K(c$,function(a){this.construct(Long.toString(a))},
"~N");$_K(c$,function(a){this.construct(Float.toString(a))},"~N");$_K(c$,function(a){this.construct(Double.toString(a))},"~N");c$=$_T(java.lang,"ClassCircularityError",LinkageError);c$=$_T(java.lang,"ClassFormatError",LinkageError);c$=$_C(function(){this.exception=null;$_Z(this,arguments)},java.lang,"ExceptionInInitializerError",LinkageError);$_K(c$,function(){$_R(this,ExceptionInInitializerError);this.initCause(null)});$_K(c$,function(a){$_R(this,ExceptionInInitializerError,[a]);this.initCause(null)},
"~S");$_K(c$,function(a){$_R(this,ExceptionInInitializerError);this.exception=a;this.initCause(a)},"Throwable");$_M(c$,"getException",function(){return this.exception});$_V(c$,"getCause",function(){return this.exception});c$=$_T(java.lang,"IllegalAccessError",IncompatibleClassChangeError);c$=$_T(java.lang,"InstantiationError",IncompatibleClassChangeError);c$=$_T(java.lang,"VirtualMachineError",Error);c$=$_T(java.lang,"InternalError",VirtualMachineError);c$=$_T(java.lang,"NoClassDefFoundError",LinkageError);
c$=$_T(java.lang,"NoSuchFieldError",IncompatibleClassChangeError);c$=$_T(java.lang,"NoSuchMethodError",IncompatibleClassChangeError);c$=$_T(java.lang,"OutOfMemoryError",VirtualMachineError);c$=$_T(java.lang,"StackOverflowError",VirtualMachineError);c$=$_T(java.lang,"UnknownError",VirtualMachineError);c$=$_T(java.lang,"UnsatisfiedLinkError",LinkageError);c$=$_T(java.lang,"UnsupportedClassVersionError",ClassFormatError);c$=$_T(java.lang,"VerifyError",LinkageError);c$=$_T(java.lang,"ThreadDeath",Error);
$_K(c$,function(){$_R(this,ThreadDeath,[])});c$=$_T(java.lang,"Exception",Throwable);c$=$_T(java.lang,"RuntimeException",Exception);c$=$_T(java.lang,"ArithmeticException",RuntimeException);c$=$_T(java.lang,"IndexOutOfBoundsException",RuntimeException);c$=$_T(java.lang,"ArrayIndexOutOfBoundsException",IndexOutOfBoundsException);$_K(c$,function(a){$_R(this,ArrayIndexOutOfBoundsException,["Array index out of range: "+a])},"~N");c$=$_T(java.lang,"ArrayStoreException",RuntimeException);c$=$_T(java.lang,
"ClassCastException",RuntimeException);c$=$_C(function(){this.ex=null;$_Z(this,arguments)},java.lang,"ClassNotFoundException",Exception);$_K(c$,function(){$_R(this,ClassNotFoundException,[Clazz.castNullAs("Throwable")])});$_K(c$,function(a){$_R(this,ClassNotFoundException,[a,null])},"~S");$_K(c$,function(a,b){$_R(this,ClassNotFoundException,[a]);this.ex=b},"~S,Throwable");$_M(c$,"getException",function(){return this.ex});$_V(c$,"getCause",function(){return this.ex});c$=$_T(java.lang,"CloneNotSupportedException",
Exception);c$=$_T(java.lang,"IllegalAccessException",Exception);c$=$_T(java.lang,"IllegalArgumentException",RuntimeException);$_K(c$,function(a){$_R(this,IllegalArgumentException,[null==a?null:a.toString(),a])},"Throwable");c$=$_T(java.lang,"IllegalMonitorStateException",RuntimeException);c$=$_T(java.lang,"IllegalStateException",RuntimeException);$_K(c$,function(a){$_R(this,IllegalStateException,[null==a?null:a.toString(),a])},"Throwable");c$=$_T(java.lang,"IllegalThreadStateException",IllegalArgumentException);
c$=$_T(java.lang,"InstantiationException",Exception);c$=$_T(java.lang,"InterruptedException",Exception);c$=$_T(java.lang,"NegativeArraySizeException",RuntimeException);c$=$_T(java.lang,"NoSuchFieldException",Exception);c$=$_T(java.lang,"NoSuchMethodException",Exception);c$=$_T(java.lang,"NullPointerException",RuntimeException);c$=$_T(java.lang,"NumberFormatException",IllegalArgumentException);c$=$_T(java.lang,"SecurityException",RuntimeException);$_K(c$,function(a){$_R(this,SecurityException,[null==
a?null:a.toString(),a])},"Throwable");c$=$_T(java.lang,"StringIndexOutOfBoundsException",IndexOutOfBoundsException);$_K(c$,function(a){$_R(this,StringIndexOutOfBoundsException,["String index out of range: "+a])},"~N");c$=$_T(java.lang,"UnsupportedOperationException",RuntimeException);$_K(c$,function(){$_R(this,UnsupportedOperationException,[])});$_K(c$,function(a){$_R(this,UnsupportedOperationException,[null==a?null:a.toString(),a])},"Throwable");c$=$_C(function(){this.target=null;$_Z(this,arguments)},
java.lang.reflect,"InvocationTargetException",Exception);$_K(c$,function(){$_R(this,java.lang.reflect.InvocationTargetException,[Clazz.castNullAs("Throwable")])});$_K(c$,function(a){$_R(this,java.lang.reflect.InvocationTargetException,[null,a]);this.target=a},"Throwable");$_K(c$,function(a,b){$_R(this,java.lang.reflect.InvocationTargetException,[b,a]);this.target=a},"Throwable,~S");$_M(c$,"getTargetException",function(){return this.target});$_V(c$,"getCause",function(){return this.target});c$=$_C(function(){this.undeclaredThrowable=
null;$_Z(this,arguments)},java.lang.reflect,"UndeclaredThrowableException",RuntimeException);$_K(c$,function(a){$_R(this,java.lang.reflect.UndeclaredThrowableException);this.undeclaredThrowable=a;this.initCause(a)},"Throwable");$_K(c$,function(a,b){$_R(this,java.lang.reflect.UndeclaredThrowableException,[b]);this.undeclaredThrowable=a;this.initCause(a)},"Throwable,~S");$_M(c$,"getUndeclaredThrowable",function(){return this.undeclaredThrowable});$_V(c$,"getCause",function(){return this.undeclaredThrowable});
c$=$_T(java.io,"IOException",Exception);c$=$_T(java.io,"CharConversionException",java.io.IOException);c$=$_T(java.io,"EOFException",java.io.IOException);c$=$_T(java.io,"FileNotFoundException",java.io.IOException);c$=$_C(function(){this.bytesTransferred=0;$_Z(this,arguments)},java.io,"InterruptedIOException",java.io.IOException);c$=$_T(java.io,"ObjectStreamException",java.io.IOException);c$=$_C(function(){this.classname=null;$_Z(this,arguments)},java.io,"InvalidClassException",java.io.ObjectStreamException);
$_K(c$,function(a,b){$_R(this,java.io.InvalidClassException,[b]);this.classname=a},"~S,~S");$_M(c$,"getMessage",function(){var a=$_U(this,java.io.InvalidClassException,"getMessage",[]);null!=this.classname&&(a=this.classname+"; "+a);return a});c$=$_T(java.io,"InvalidObjectException",java.io.ObjectStreamException);c$=$_T(java.io,"NotActiveException",java.io.ObjectStreamException);c$=$_T(java.io,"NotSerializableException",java.io.ObjectStreamException);c$=$_C(function(){this.eof=!1;this.length=0;$_Z(this,
arguments)},java.io,"OptionalDataException",java.io.ObjectStreamException);c$=$_T(java.io,"StreamCorruptedException",java.io.ObjectStreamException);c$=$_T(java.io,"SyncFailedException",java.io.IOException);c$=$_T(java.io,"UnsupportedEncodingException",java.io.IOException);c$=$_T(java.io,"UTFDataFormatException",java.io.IOException);c$=$_C(function(){this.detail=null;$_Z(this,arguments)},java.io,"WriteAbortedException",java.io.ObjectStreamException);$_K(c$,function(a,b){$_R(this,java.io.WriteAbortedException,
[a]);this.detail=b;this.initCause(b)},"~S,Exception");$_M(c$,"getMessage",function(){var a=$_U(this,java.io.WriteAbortedException,"getMessage",[]);null!=this.detail&&(a=a+"; "+this.detail.toString());return a});$_V(c$,"getCause",function(){return this.detail});c$=$_T(java.util,"ConcurrentModificationException",RuntimeException);$_K(c$,function(){$_R(this,java.util.ConcurrentModificationException,[])});c$=$_T(java.util,"EmptyStackException",RuntimeException);c$=$_C(function(){this.key=this.className=
null;$_Z(this,arguments)},java.util,"MissingResourceException",RuntimeException);$_K(c$,function(a,b,c){$_R(this,java.util.MissingResourceException,[a]);this.className=b;this.key=c},"~S,~S,~S");$_M(c$,"getClassName",function(){return this.className});$_M(c$,"getKey",function(){return this.key});c$=$_T(java.util,"NoSuchElementException",RuntimeException);c$=$_T(java.util,"TooManyListenersException",Exception);c$=$_T(java.lang,"Void");$_S(c$,"TYPE",null);java.lang.Void.TYPE=java.lang.Void;$_I(java.lang.reflect,
"GenericDeclaration");$_I(java.lang.reflect,"AnnotatedElement");c$=$_T(java.lang.reflect,"AccessibleObject",null,java.lang.reflect.AnnotatedElement);$_K(c$,function(){});$_M(c$,"isAccessible",function(){return!1});c$.setAccessible=$_M(c$,"setAccessible",function(){},"~A,~B");$_M(c$,"setAccessible",function(){},"~B");$_V(c$,"isAnnotationPresent",function(){return!1},"Class");$_V(c$,"getDeclaredAnnotations",function(){return[]});$_V(c$,"getAnnotations",function(){return[]});$_V(c$,"getAnnotation",function(){return null},
"Class");c$.marshallArguments=$_M(c$,"marshallArguments",function(){return null},"~A,~A");$_M(c$,"invokeV",function(){},"~O,~A");$_M(c$,"invokeL",function(){return null},"~O,~A");$_M(c$,"invokeI",function(){return 0},"~O,~A");$_M(c$,"invokeJ",function(){return 0},"~O,~A");$_M(c$,"invokeF",function(){return 0},"~O,~A");$_M(c$,"invokeD",function(){return 0},"~O,~A");c$.emptyArgs=c$.prototype.emptyArgs=[];$_I(java.lang.reflect,"InvocationHandler");c$=$_I(java.lang.reflect,"Member");$_S(c$,"PUBLIC",0,
"DECLARED",1);c$=$_T(java.lang.reflect,"Modifier");$_K(c$,function(){});c$.isAbstract=$_M(c$,"isAbstract",function(a){return 0!=(a&1024)},"~N");c$.isFinal=$_M(c$,"isFinal",function(a){return 0!=(a&16)},"~N");c$.isInterface=$_M(c$,"isInterface",function(a){return 0!=(a&512)},"~N");c$.isNative=$_M(c$,"isNative",function(a){return 0!=(a&256)},"~N");c$.isPrivate=$_M(c$,"isPrivate",function(a){return 0!=(a&2)},"~N");c$.isProtected=$_M(c$,"isProtected",function(a){return 0!=(a&4)},"~N");c$.isPublic=$_M(c$,
"isPublic",function(a){return 0!=(a&1)},"~N");c$.isStatic=$_M(c$,"isStatic",function(a){return 0!=(a&8)},"~N");c$.isStrict=$_M(c$,"isStrict",function(a){return 0!=(a&2048)},"~N");c$.isSynchronized=$_M(c$,"isSynchronized",function(a){return 0!=(a&32)},"~N");c$.isTransient=$_M(c$,"isTransient",function(a){return 0!=(a&128)},"~N");c$.isVolatile=$_M(c$,"isVolatile",function(a){return 0!=(a&64)},"~N");c$.toString=$_M(c$,"toString",function(a){var b=[];java.lang.reflect.Modifier.isPublic(a)&&(b[b.length]=
"public");java.lang.reflect.Modifier.isProtected(a)&&(b[b.length]="protected");java.lang.reflect.Modifier.isPrivate(a)&&(b[b.length]="private");java.lang.reflect.Modifier.isAbstract(a)&&(b[b.length]="abstract");java.lang.reflect.Modifier.isStatic(a)&&(b[b.length]="static");java.lang.reflect.Modifier.isFinal(a)&&(b[b.length]="final");java.lang.reflect.Modifier.isTransient(a)&&(b[b.length]="transient");java.lang.reflect.Modifier.isVolatile(a)&&(b[b.length]="volatile");java.lang.reflect.Modifier.isSynchronized(a)&&
(b[b.length]="synchronized");java.lang.reflect.Modifier.isNative(a)&&(b[b.length]="native");java.lang.reflect.Modifier.isStrict(a)&&(b[b.length]="strictfp");java.lang.reflect.Modifier.isInterface(a)&&(b[b.length]="interface");return 0<b.length?b.join(" "):""},"~N");$_S(c$,"PUBLIC",1,"PRIVATE",2,"PROTECTED",4,"STATIC",8,"FINAL",16,"SYNCHRONIZED",32,"VOLATILE",64,"TRANSIENT",128,"NATIVE",256,"INTERFACE",512,"ABSTRACT",1024,"STRICT",2048,"BRIDGE",64,"VARARGS",128,"SYNTHETIC",4096,"ANNOTATION",8192,"ENUM",
16384);c$=$_C(function(){this.exceptionTypes=this.parameterTypes=this.clazz=null;this.modifiers=0;$_Z(this,arguments)},java.lang.reflect,"Constructor",java.lang.reflect.AccessibleObject,[java.lang.reflect.GenericDeclaration,java.lang.reflect.Member]);$_K(c$,function(a,b,c,d){$_R(this,java.lang.reflect.Constructor,[]);this.clazz=a;this.parameterTypes=b;this.exceptionTypes=c;this.modifiers=d},"Class,~A,~A,~N");$_V(c$,"getTypeParameters",function(){return null});$_M(c$,"toGenericString",function(){return null});
$_M(c$,"getGenericParameterTypes",function(){return null});$_M(c$,"getGenericExceptionTypes",function(){return null});$_M(c$,"getParameterAnnotations",function(){return null});$_M(c$,"isVarArgs",function(){return!1});$_V(c$,"isSynthetic",function(){return!1});$_V(c$,"equals",function(a){if(null!=a&&$_O(a,java.lang.reflect.Constructor)&&this.getDeclaringClass()===a.getDeclaringClass()){var b=this.parameterTypes;a=a.parameterTypes;if(b.length==a.length){for(var c=0;c<b.length;c++)if(b[c]!==a[c])return!1;
return!0}}return!1},"~O");$_V(c$,"getDeclaringClass",function(){return this.clazz});$_M(c$,"getExceptionTypes",function(){return this.exceptionTypes});$_V(c$,"getModifiers",function(){return this.modifiers});$_V(c$,"getName",function(){return this.getDeclaringClass().getName()});$_M(c$,"getParameterTypes",function(){return this.parameterTypes});$_V(c$,"hashCode",function(){return this.getDeclaringClass().getName().hashCode()});$_M(c$,"newInstance",function(a){var b=new this.clazz($_G);$_Z(b,a);return b},
"~A");$_V(c$,"toString",function(){return null});c$=$_T(java.lang.reflect,"Field",java.lang.reflect.AccessibleObject,java.lang.reflect.Member);$_V(c$,"isSynthetic",function(){return!1});$_M(c$,"toGenericString",function(){return null});$_M(c$,"isEnumConstant",function(){return!1});$_M(c$,"getGenericType",function(){return null});$_V(c$,"equals",function(){return!1},"~O");$_V(c$,"getDeclaringClass",function(){return null});$_V(c$,"getName",function(){return null});$_M(c$,"getType",function(){return null});
$_V(c$,"hashCode",function(){return 0});$_V(c$,"toString",function(){return null});c$=$_C(function(){this.exceptionTypes=this.parameterTypes=this.returnType=this.name=this.clazz=null;this.modifiers=0;$_Z(this,arguments)},java.lang.reflect,"Method",java.lang.reflect.AccessibleObject,[java.lang.reflect.GenericDeclaration,java.lang.reflect.Member]);$_K(c$,function(a,b,c,d,e,f){$_R(this,java.lang.reflect.Method,[]);this.clazz=a;this.name=b;this.parameterTypes=c;this.returnType=d;this.exceptionTypes=e;
this.modifiers=f},"Class,~S,~A,Class,~A,~N");$_V(c$,"getTypeParameters",function(){return null});$_M(c$,"toGenericString",function(){return null});$_M(c$,"getGenericParameterTypes",function(){return null});$_M(c$,"getGenericExceptionTypes",function(){return null});$_M(c$,"getGenericReturnType",function(){return null});$_M(c$,"getParameterAnnotations",function(){return null});$_M(c$,"isVarArgs",function(){return!1});$_M(c$,"isBridge",function(){return!1});$_V(c$,"isSynthetic",function(){return!1});
$_M(c$,"getDefaultValue",function(){return null});$_V(c$,"equals",function(a){if(null!=a&&$_O(a,java.lang.reflect.Method)&&this.getDeclaringClass()===a.getDeclaringClass()&&this.getName()===a.getName()){var b=this.parameterTypes;a=a.parameterTypes;if(b.length==a.length){for(var c=0;c<b.length;c++)if(b[c]!==a[c])return!1;return!0}}return!1},"~O");$_V(c$,"getDeclaringClass",function(){return this.clazz});$_M(c$,"getExceptionTypes",function(){return this.exceptionTypes});$_V(c$,"getModifiers",function(){return this.modifiers});
$_V(c$,"getName",function(){return this.name});$_M(c$,"getParameterTypes",function(){return this.parameterTypes});$_M(c$,"getReturnType",function(){return this.returnType});$_V(c$,"hashCode",function(){return this.getDeclaringClass().getName().hashCode()^this.getName().hashCode()});$_M(c$,"invoke",function(a,b){var c=this.clazz.prototype[this.getName()];null==c&&(c=this.clazz[this.getName()]);null!=c&&c.apply(a,b)},"~O,~A");$_V(c$,"toString",function(){return null});Jmol.debugCode||(Clazz.declarePackage("JU"),
Clazz.load(null,"JU.T3",["java.lang.Float"],function(){c$=Clazz.decorateAsClass(function(){this.z=this.y=this.x=0;Clazz.instantialize(this,arguments)},JU,"T3",null,java.io.Serializable);Clazz.makeConstructor(c$,function(){});$_M(c$,"set",function(a,b,c){this.x=a;this.y=b;this.z=c},"~N,~N,~N");$_M(c$,"setA",function(a){this.x=a[0];this.y=a[1];this.z=a[2]},"~A");$_M(c$,"setT",function(a){this.x=a.x;this.y=a.y;this.z=a.z},"JU.T3");$_M(c$,"add2",function(a,b){this.x=a.x+b.x;this.y=a.y+b.y;this.z=a.z+
b.z},"JU.T3,JU.T3");$_M(c$,"add",function(a){this.x+=a.x;this.y+=a.y;this.z+=a.z},"JU.T3");$_M(c$,"sub2",function(a,b){this.x=a.x-b.x;this.y=a.y-b.y;this.z=a.z-b.z},"JU.T3,JU.T3");$_M(c$,"sub",function(a){this.x-=a.x;this.y-=a.y;this.z-=a.z},"JU.T3");$_M(c$,"scale",function(a){this.x*=a;this.y*=a;this.z*=a},"~N");$_M(c$,"scaleAdd2",function(a,b,c){this.x=a*b.x+c.x;this.y=a*b.y+c.y;this.z=a*b.z+c.z},"~N,JU.T3,JU.T3");$_M(c$,"scaleAdd",function(a,b){this.x=a*this.x+b.x;this.y=a*this.y+b.y;this.z=a*
this.z+b.z},"~N,JU.T3");$_M(c$,"dot",function(a){return this.x*a.x+this.y*a.y+this.z*a.z},"JU.T3");$_M(c$,"lengthSquared",function(){return this.x*this.x+this.y*this.y+this.z*this.z});$_M(c$,"length",function(){return Math.sqrt(this.lengthSquared())});$_M(c$,"normalize",function(){var a=this.length();this.x/=a;this.y/=a;this.z/=a});Clazz.overrideMethod(c$,"hashCode",function(){var a;a=31+JU.T3.floatToIntBits0(this.x);a=31*a+JU.T3.floatToIntBits0(this.y);a=31*a+JU.T3.floatToIntBits0(this.z);return a^
a>>32});c$.floatToIntBits0=$_M(c$,"floatToIntBits0",function(a){return 0==a?0:Float.floatToIntBits(a)},"~N");Clazz.overrideMethod(c$,"equals",function(a){return!Clazz.instanceOf(a,JU.T3)?!1:this.x==a.x&&this.y==a.y&&this.z==a.z},"~O");Clazz.overrideMethod(c$,"toString",function(){return"("+this.x+", "+this.y+", "+this.z+")"})}),Clazz.declarePackage("JU"),c$=Clazz.decorateAsClass(function(){this.z=this.y=this.x=0;Clazz.instantialize(this,arguments)},JU,"T3i",null,java.io.Serializable),Clazz.makeConstructor(c$,
function(){}),$_M(c$,"set",function(a,b,c){this.x=a;this.y=b;this.z=c},"~N,~N,~N"),$_M(c$,"setT",function(a){this.x=a.x;this.y=a.y;this.z=a.z},"JU.T3i"),$_M(c$,"add",function(a){this.x+=a.x;this.y+=a.y;this.z+=a.z},"JU.T3i"),$_M(c$,"scaleAdd",function(a,b,c){this.x=a*b.x+c.x;this.y=a*b.y+c.y;this.z=a*b.z+c.z},"~N,JU.T3i,JU.T3i"),Clazz.overrideMethod(c$,"hashCode",function(){return this.x^this.y^this.z}),Clazz.overrideMethod(c$,"equals",function(a){return!Clazz.instanceOf(a,JU.T3i)?!1:this.x==a.x&&
this.y==a.y&&this.z==a.z},"~O"),Clazz.overrideMethod(c$,"toString",function(){return"("+this.x+", "+this.y+", "+this.z+")"}),Clazz.declarePackage("JU"),Clazz.load(null,"JU.T3d",["java.lang.Double"],function(){c$=Clazz.decorateAsClass(function(){this.z=this.y=this.x=0;Clazz.instantialize(this,arguments)},JU,"T3d",null,java.io.Serializable);Clazz.makeConstructor(c$,function(){});$_M(c$,"set",function(a,b,c){this.x=a;this.y=b;this.z=c},"~N,~N,~N");$_M(c$,"setA",function(a){this.x=a[0];this.y=a[1];this.z=
a[2]},"~A");$_M(c$,"setT",function(a){this.x=a.x;this.y=a.y;this.z=a.z},"JU.T3d");$_M(c$,"add2",function(a,b){this.x=a.x+b.x;this.y=a.y+b.y;this.z=a.z+b.z},"JU.T3d,JU.T3d");$_M(c$,"add",function(a){this.x+=a.x;this.y+=a.y;this.z+=a.z},"JU.T3d");$_M(c$,"sub2",function(a,b){this.x=a.x-b.x;this.y=a.y-b.y;this.z=a.z-b.z},"JU.T3d,JU.T3d");$_M(c$,"sub",function(a){this.x-=a.x;this.y-=a.y;this.z-=a.z},"JU.T3d");$_M(c$,"scale",function(a){this.x*=a;this.y*=a;this.z*=a},"~N");$_M(c$,"scaleAdd",function(a,
b,c){this.x=a*b.x+c.x;this.y=a*b.y+c.y;this.z=a*b.z+c.z},"~N,JU.T3d,JU.T3d");Clazz.overrideMethod(c$,"hashCode",function(){var a=JU.T3d.doubleToLongBits0(this.x),b=JU.T3d.doubleToLongBits0(this.y),c=JU.T3d.doubleToLongBits0(this.z);return a^a>>32^b^b>>32^c^c>>32});c$.doubleToLongBits0=$_M(c$,"doubleToLongBits0",function(a){return 0==a?0:Double.doubleToLongBits(a)},"~N");Clazz.overrideMethod(c$,"equals",function(a){return!Clazz.instanceOf(a,JU.T3d)?!1:this.x==a.x&&this.y==a.y&&this.z==a.z},"~O");Clazz.overrideMethod(c$,
"toString",function(){return"("+this.x+", "+this.y+", "+this.z+")"})}),Clazz.declarePackage("JU"),Clazz.load(["JU.T3"],"JU.P3",null,function(){c$=Clazz.declareType(JU,"P3",JU.T3);c$.newP=$_M(c$,"newP",function(a){var b=new JU.P3;b.x=a.x;b.y=a.y;b.z=a.z;return b},"JU.T3");c$.new3=$_M(c$,"new3",function(a,b,c){var d=new JU.P3;d.x=a;d.y=b;d.z=c;return d},"~N,~N,~N");$_M(c$,"distanceSquared",function(a){var b=this.x-a.x,c=this.y-a.y;a=this.z-a.z;return b*b+c*c+a*a},"JU.T3");$_M(c$,"distance",function(a){return Math.sqrt(this.distanceSquared(a))},
"JU.T3")}),Clazz.declarePackage("JU"),Clazz.load(["JU.T3i"],"JU.P3i",null,function(){c$=Clazz.declareType(JU,"P3i",JU.T3i);c$.new3=$_M(c$,"new3",function(a,b,c){var d=new JU.P3i;d.x=a;d.y=b;d.z=c;return d},"~N,~N,~N")}),Clazz.declarePackage("JU"),Clazz.load(["JU.T3"],"JU.V3",null,function(){c$=Clazz.declareType(JU,"V3",JU.T3);c$.newV=$_M(c$,"newV",function(a){return JU.V3.new3(a.x,a.y,a.z)},"JU.T3");c$.newVsub=$_M(c$,"newVsub",function(a,b){return JU.V3.new3(a.x-b.x,a.y-b.y,a.z-b.z)},"JU.T3,JU.T3");
c$.new3=$_M(c$,"new3",function(a,b,c){var d=new JU.V3;d.x=a;d.y=b;d.z=c;return d},"~N,~N,~N");$_M(c$,"cross",function(a,b){this.set(a.y*b.z-a.z*b.y,a.z*b.x-a.x*b.z,a.x*b.y-a.y*b.x)},"JU.V3,JU.V3");$_M(c$,"angle",function(a){var b=this.y*a.z-this.z*a.y,c=this.z*a.x-this.x*a.z,d=this.x*a.y-this.y*a.x,b=Math.sqrt(b*b+c*c+d*d);return Math.abs(Math.atan2(b,this.dot(a)))},"JU.V3")}),Clazz.declarePackage("JU"),Clazz.load(["JU.T3d"],"JU.V3d",null,function(){c$=Clazz.declareType(JU,"V3d",JU.T3d);$_M(c$,"cross",
function(a,b){this.set(a.y*b.z-a.z*b.y,a.z*b.x-a.x*b.z,a.x*b.y-a.y*b.x)},"JU.V3d,JU.V3d");$_M(c$,"normalize",function(){var a=this.length();this.x/=a;this.y/=a;this.z/=a});$_M(c$,"dot",function(a){return this.x*a.x+this.y*a.y+this.z*a.z},"JU.V3d");$_M(c$,"lengthSquared",function(){return this.x*this.x+this.y*this.y+this.z*this.z});$_M(c$,"length",function(){return Math.sqrt(this.lengthSquared())})}),Clazz.declarePackage("JU"),Clazz.load(null,"JU.M3",["java.lang.ArrayIndexOutOfBoundsException","JU.T3"],
function(){c$=Clazz.decorateAsClass(function(){this.m22=this.m21=this.m20=this.m12=this.m11=this.m10=this.m02=this.m01=this.m00=0;Clazz.instantialize(this,arguments)},JU,"M3",null,java.io.Serializable);Clazz.makeConstructor(c$,function(){});c$.newA=$_M(c$,"newA",function(a){var b=new JU.M3;b.setA(a);return b},"~A");c$.newM=$_M(c$,"newM",function(a){var b=new JU.M3;b.m00=a.m00;b.m01=a.m01;b.m02=a.m02;b.m10=a.m10;b.m11=a.m11;b.m12=a.m12;b.m20=a.m20;b.m21=a.m21;b.m22=a.m22;return b},"JU.M3");Clazz.overrideMethod(c$,
"toString",function(){return"[\n  ["+this.m00+"\t"+this.m01+"\t"+this.m02+"]\n  ["+this.m10+"\t"+this.m11+"\t"+this.m12+"]\n  ["+this.m20+"\t"+this.m21+"\t"+this.m22+"] ]"});$_M(c$,"setIdentity",function(){this.m00=1;this.m10=this.m02=this.m01=0;this.m11=1;this.m21=this.m20=this.m12=0;this.m22=1});$_M(c$,"setElement",function(a,b,c){if(0==a)if(0==b)this.m00=c;else if(1==b)this.m01=c;else if(2==b)this.m02=c;else throw new ArrayIndexOutOfBoundsException("column must be 0 to 2 and is "+b);else if(1==
a)if(0==b)this.m10=c;else if(1==b)this.m11=c;else if(2==b)this.m12=c;else throw new ArrayIndexOutOfBoundsException("column must be 0 to 2 and is "+b);else if(2==a)if(0==b)this.m20=c;else if(1==b)this.m21=c;else if(2==b)this.m22=c;else throw new ArrayIndexOutOfBoundsException("column must be 0 to 2 and is "+b);else throw new ArrayIndexOutOfBoundsException("row must be 0 to 2 and is "+a);},"~N,~N,~N");$_M(c$,"getElement",function(a,b){if(0==a){if(0==b)return this.m00;if(1==b)return this.m01;if(2==b)return this.m02;
throw new ArrayIndexOutOfBoundsException("column must be 0 to 2 and is "+b);}if(1==a){if(0==b)return this.m10;if(1==b)return this.m11;if(2==b)return this.m12;throw new ArrayIndexOutOfBoundsException("column must be 0 to 2 and is "+b);}if(2==a){if(0==b)return this.m20;if(1==b)return this.m21;if(2==b)return this.m22;throw new ArrayIndexOutOfBoundsException("column must be 0 to 2 and is "+b);}throw new ArrayIndexOutOfBoundsException("row must be 0 to 2 and is "+a);},"~N,~N");$_M(c$,"setRow",function(a,
b,c,d){if(0==a)this.m00=b,this.m01=c,this.m02=d;else if(1==a)this.m10=b,this.m11=c,this.m12=d;else if(2==a)this.m20=b,this.m21=c,this.m22=d;else throw new ArrayIndexOutOfBoundsException("row must be 0 to 2 and is "+a);},"~N,~N,~N,~N");$_M(c$,"setRowV",function(a,b){if(0==a)this.m00=b.x,this.m01=b.y,this.m02=b.z;else if(1==a)this.m10=b.x,this.m11=b.y,this.m12=b.z;else if(2==a)this.m20=b.x,this.m21=b.y,this.m22=b.z;else throw new ArrayIndexOutOfBoundsException("row must be 0 to 2 and is "+a);},"~N,JU.T3");
$_M(c$,"getRow",function(a,b){if(0==a)b[0]=this.m00,b[1]=this.m01,b[2]=this.m02;else if(1==a)b[0]=this.m10,b[1]=this.m11,b[2]=this.m12;else if(2==a)b[0]=this.m20,b[1]=this.m21,b[2]=this.m22;else throw new ArrayIndexOutOfBoundsException("row must be 0 to 2 and is "+a);},"~N,~A");$_M(c$,"setRowA",function(a,b){if(0==a)this.m00=b[0],this.m01=b[1],this.m02=b[2];else if(1==a)this.m10=b[0],this.m11=b[1],this.m12=b[2];else if(2==a)this.m20=b[0],this.m21=b[1],this.m22=b[2];else throw new ArrayIndexOutOfBoundsException("row must be 0 to 2 and is "+
a);},"~N,~A");$_M(c$,"setColumn",function(a,b,c,d){if(0==a)this.m00=b,this.m10=c,this.m20=d;else if(1==a)this.m01=b,this.m11=c,this.m21=d;else if(2==a)this.m02=b,this.m12=c,this.m22=d;else throw new ArrayIndexOutOfBoundsException("column must be 0 to 2 and is "+a);},"~N,~N,~N,~N");$_M(c$,"setColumnV",function(a,b){if(0==a)this.m00=b.x,this.m10=b.y,this.m20=b.z;else if(1==a)this.m01=b.x,this.m11=b.y,this.m21=b.z;else if(2==a)this.m02=b.x,this.m12=b.y,this.m22=b.z;else throw new ArrayIndexOutOfBoundsException("column must be 0 to 2 and is "+
a);},"~N,JU.V3");$_M(c$,"setColumnA",function(a,b){if(0==a)this.m00=b[0],this.m10=b[1],this.m20=b[2];else if(1==a)this.m01=b[0],this.m11=b[1],this.m21=b[2];else if(2==a)this.m02=b[0],this.m12=b[1],this.m22=b[2];else throw new ArrayIndexOutOfBoundsException("column must be 0 to 2 and is "+a);},"~N,~A");$_M(c$,"getColumnV",function(a,b){if(0==a)b.x=this.m00,b.y=this.m10,b.z=this.m20;else if(1==a)b.x=this.m01,b.y=this.m11,b.z=this.m21;else if(2==a)b.x=this.m02,b.y=this.m12,b.z=this.m22;else throw new ArrayIndexOutOfBoundsException("column must be 0 to 2 and is "+
a);},"~N,JU.V3");$_M(c$,"getColumn",function(a,b){if(0==a)b[0]=this.m00,b[1]=this.m10,b[2]=this.m20;else if(1==a)b[0]=this.m01,b[1]=this.m11,b[2]=this.m21;else if(2==a)b[0]=this.m02,b[1]=this.m12,b[2]=this.m22;else throw new ArrayIndexOutOfBoundsException("column must be 0 to 2 and is "+a);},"~N,~A");$_M(c$,"add",function(a){this.m00+=a.m00;this.m01+=a.m01;this.m02+=a.m02;this.m10+=a.m10;this.m11+=a.m11;this.m12+=a.m12;this.m20+=a.m20;this.m21+=a.m21;this.m22+=a.m22},"JU.M3");$_M(c$,"sub",function(a){this.m00-=
a.m00;this.m01-=a.m01;this.m02-=a.m02;this.m10-=a.m10;this.m11-=a.m11;this.m12-=a.m12;this.m20-=a.m20;this.m21-=a.m21;this.m22-=a.m22},"JU.M3");$_M(c$,"transpose",function(){var a=this.m01;this.m01=this.m10;this.m10=a;a=this.m02;this.m02=this.m20;this.m20=a;a=this.m12;this.m12=this.m21;this.m21=a});$_M(c$,"transposeM",function(a){this.setM(a);this.transpose()},"JU.M3");$_M(c$,"setAA",function(a){this.setFromAxisAngle(a.x,a.y,a.z,a.angle)},"JU.A4");$_M(c$,"setFromAxisAngle",($fz=function(a,b,c,d){var e=
Math.sqrt(a*a+b*b+c*c),e=1/e;a*=e;b*=e;c*=e;var f=Math.cos(d);d=Math.sin(d);e=1-f;this.m00=f+a*a*e;this.m11=f+b*b*e;this.m22=f+c*c*e;var f=a*b*e,g=c*d;this.m01=f-g;this.m10=f+g;f=a*c*e;g=b*d;this.m02=f+g;this.m20=f-g;f=b*c*e;g=a*d;this.m12=f-g;this.m21=f+g},$fz.isPrivate=!0,$fz),"~N,~N,~N,~N");$_M(c$,"setM",function(a){this.m00=a.m00;this.m01=a.m01;this.m02=a.m02;this.m10=a.m10;this.m11=a.m11;this.m12=a.m12;this.m20=a.m20;this.m21=a.m21;this.m22=a.m22},"JU.M3");$_M(c$,"setA",function(a){this.m00=
a[0];this.m01=a[1];this.m02=a[2];this.m10=a[3];this.m11=a[4];this.m12=a[5];this.m20=a[6];this.m21=a[7];this.m22=a[8]},"~A");$_M(c$,"invertM",function(a){this.setM(a);this.invert()},"JU.M3");$_M(c$,"invert",function(){var a=this.determinant();0!=a&&(a=1/a,this.set(this.m11*this.m22-this.m12*this.m21,this.m02*this.m21-this.m01*this.m22,this.m01*this.m12-this.m02*this.m11,this.m12*this.m20-this.m10*this.m22,this.m00*this.m22-this.m02*this.m20,this.m02*this.m10-this.m00*this.m12,this.m10*this.m21-this.m11*
this.m20,this.m01*this.m20-this.m00*this.m21,this.m00*this.m11-this.m01*this.m10),this.mulf(a))});$_M(c$,"determinant",function(){return this.m00*(this.m11*this.m22-this.m21*this.m12)-this.m01*(this.m10*this.m22-this.m20*this.m12)+this.m02*(this.m10*this.m21-this.m20*this.m11)});$_M(c$,"setScale",function(a){this.m00=a;this.m10=this.m02=this.m01=0;this.m11=a;this.m21=this.m20=this.m12=0;this.m22=a},"~N");$_M(c$,"rotX",function(a){var b=Math.cos(a);a=Math.sin(a);this.m00=1;this.m10=this.m02=this.m01=
0;this.m11=b;this.m12=-a;this.m20=0;this.m21=a;this.m22=b},"~N");$_M(c$,"rotY",function(a){var b=Math.cos(a);a=Math.sin(a);this.m00=b;this.m01=0;this.m02=a;this.m10=0;this.m11=1;this.m12=0;this.m20=-a;this.m21=0;this.m22=b},"~N");$_M(c$,"rotZ",function(a){var b=Math.cos(a);a=Math.sin(a);this.m00=b;this.m01=-a;this.m02=0;this.m10=a;this.m11=b;this.m21=this.m20=this.m12=0;this.m22=1},"~N");$_M(c$,"mulf",function(a){this.m00*=a;this.m01*=a;this.m02*=a;this.m10*=a;this.m11*=a;this.m12*=a;this.m20*=a;
this.m21*=a;this.m22*=a},"~N");$_M(c$,"mul",function(a){this.mul2(this,a)},"JU.M3");$_M(c$,"mul2",function(a,b){this.set(a.m00*b.m00+a.m01*b.m10+a.m02*b.m20,a.m00*b.m01+a.m01*b.m11+a.m02*b.m21,a.m00*b.m02+a.m01*b.m12+a.m02*b.m22,a.m10*b.m00+a.m11*b.m10+a.m12*b.m20,a.m10*b.m01+a.m11*b.m11+a.m12*b.m21,a.m10*b.m02+a.m11*b.m12+a.m12*b.m22,a.m20*b.m00+a.m21*b.m10+a.m22*b.m20,a.m20*b.m01+a.m21*b.m11+a.m22*b.m21,a.m20*b.m02+a.m21*b.m12+a.m22*b.m22)},"JU.M3,JU.M3");Clazz.overrideMethod(c$,"equals",function(a){return!Clazz.instanceOf(a,
JU.M3)?!1:this.m00==a.m00&&this.m01==a.m01&&this.m02==a.m02&&this.m10==a.m10&&this.m11==a.m11&&this.m12==a.m12&&this.m20==a.m20&&this.m21==a.m21&&this.m22==a.m22},"~O");Clazz.overrideMethod(c$,"hashCode",function(){return JU.T3.floatToIntBits0(this.m00)^JU.T3.floatToIntBits0(this.m01)^JU.T3.floatToIntBits0(this.m02)^JU.T3.floatToIntBits0(this.m10)^JU.T3.floatToIntBits0(this.m11)^JU.T3.floatToIntBits0(this.m12)^JU.T3.floatToIntBits0(this.m20)^JU.T3.floatToIntBits0(this.m21)^JU.T3.floatToIntBits0(this.m22)});
$_M(c$,"setZero",function(){this.m22=this.m21=this.m20=this.m12=this.m11=this.m10=this.m02=this.m01=this.m00=0});$_M(c$,"transform",function(a){this.transform2(a,a)},"JU.T3");$_M(c$,"transform2",function(a,b){b.set(this.m00*a.x+this.m01*a.y+this.m02*a.z,this.m10*a.x+this.m11*a.y+this.m12*a.z,this.m20*a.x+this.m21*a.y+this.m22*a.z)},"JU.T3,JU.T3");$_M(c$,"set",($fz=function(a,b,c,d,e,f,g,h,k){this.m00=a;this.m01=b;this.m02=c;this.m10=d;this.m11=e;this.m12=f;this.m20=g;this.m21=h;this.m22=k},$fz.isPrivate=
!0,$fz),"~N,~N,~N,~N,~N,~N,~N,~N,~N")}),Clazz.declarePackage("JU"),Clazz.load(null,"JU.T4",["JU.T3"],function(){c$=Clazz.decorateAsClass(function(){this.w=this.z=this.y=this.x=0;Clazz.instantialize(this,arguments)},JU,"T4",null,java.io.Serializable);Clazz.makeConstructor(c$,function(){});$_M(c$,"set",function(a,b,c,d){this.x=a;this.y=b;this.z=c;this.w=d},"~N,~N,~N,~N");$_M(c$,"scale",function(a){this.x*=a;this.y*=a;this.z*=a;this.w*=a},"~N");Clazz.overrideMethod(c$,"hashCode",function(){return JU.T3.floatToIntBits0(this.x)^
JU.T3.floatToIntBits0(this.y)^JU.T3.floatToIntBits0(this.z)^JU.T3.floatToIntBits0(this.w)});Clazz.overrideMethod(c$,"equals",function(a){return!Clazz.instanceOf(a,JU.T4)?!1:this.x==a.x&&this.y==a.y&&this.z==a.z&&this.w==a.w},"~O");Clazz.overrideMethod(c$,"toString",function(){return"("+this.x+", "+this.y+", "+this.z+", "+this.w+")"})}),Clazz.declarePackage("JU"),Clazz.load(["JU.T4"],"JU.P4",null,function(){c$=Clazz.declareType(JU,"P4",JU.T4);c$.new4=$_M(c$,"new4",function(a,b,c,d){var e=new JU.P4;
e.set(a,b,c,d);return e},"~N,~N,~N,~N");c$.newPt=$_M(c$,"newPt",function(a){var b=new JU.P4;b.set(a.x,a.y,a.z,a.w);return b},"JU.P4");$_M(c$,"distance",function(a){var b=this.x-a.x,c=this.y-a.y,d=this.z-a.z;a=this.w-a.w;return Math.sqrt(b*b+c*c+d*d+a*a)},"JU.P4")}),Clazz.declarePackage("JU"),Clazz.load(null,"JU.M4",["java.lang.ArrayIndexOutOfBoundsException","JU.T3"],function(){c$=Clazz.decorateAsClass(function(){this.m33=this.m32=this.m31=this.m30=this.m23=this.m22=this.m21=this.m20=this.m13=this.m12=
this.m11=this.m10=this.m03=this.m02=this.m01=this.m00=0;Clazz.instantialize(this,arguments)},JU,"M4",null,java.io.Serializable);c$.newA=$_M(c$,"newA",function(a){var b=new JU.M4;b.m00=a[0];b.m01=a[1];b.m02=a[2];b.m03=a[3];b.m10=a[4];b.m11=a[5];b.m12=a[6];b.m13=a[7];b.m20=a[8];b.m21=a[9];b.m22=a[10];b.m23=a[11];b.m30=a[12];b.m31=a[13];b.m32=a[14];b.m33=a[15];return b},"~A");c$.newM=$_M(c$,"newM",function(a){var b=new JU.M4;b.m00=a.m00;b.m01=a.m01;b.m02=a.m02;b.m03=a.m03;b.m10=a.m10;b.m11=a.m11;b.m12=
a.m12;b.m13=a.m13;b.m20=a.m20;b.m21=a.m21;b.m22=a.m22;b.m23=a.m23;b.m30=a.m30;b.m31=a.m31;b.m32=a.m32;b.m33=a.m33;return b},"JU.M4");c$.newMV=$_M(c$,"newMV",function(a,b){var c=new JU.M4;c.setMV(a,b);return c},"JU.M3,JU.V3");$_M(c$,"setMV",function(a,b){this.setM3(a);this.setTranslation(b)},"JU.M3,JU.V3");$_M(c$,"setAA",function(a){this.setFromAxisAngle(a.x,a.y,a.z,a.angle)},"JU.A4");$_M(c$,"setFromAxisAngle",($fz=function(a,b,c,d){var e=Math.sqrt(a*a+b*b+c*c),e=1/e;a*=e;b*=e;c*=e;var f=Math.cos(d);
d=Math.sin(d);e=1-f;this.m00=f+a*a*e;this.m11=f+b*b*e;this.m22=f+c*c*e;var f=a*b*e,g=c*d;this.m01=f-g;this.m10=f+g;f=a*c*e;g=b*d;this.m02=f+g;this.m20=f-g;f=b*c*e;g=a*d;this.m12=f-g;this.m21=f+g},$fz.isPrivate=!0,$fz),"~N,~N,~N,~N");$_M(c$,"setM",function(a){this.m00=a.m00;this.m01=a.m01;this.m02=a.m02;this.m03=a.m03;this.m10=a.m10;this.m11=a.m11;this.m12=a.m12;this.m13=a.m13;this.m20=a.m20;this.m21=a.m21;this.m22=a.m22;this.m23=a.m23;this.m30=a.m30;this.m31=a.m31;this.m32=a.m32;this.m33=a.m33},"JU.M4");
Clazz.overrideMethod(c$,"toString",function(){return"[\n  ["+this.m00+"\t"+this.m01+"\t"+this.m02+"\t"+this.m03+"]\n  ["+this.m10+"\t"+this.m11+"\t"+this.m12+"\t"+this.m13+"]\n  ["+this.m20+"\t"+this.m21+"\t"+this.m22+"\t"+this.m23+"]\n  ["+this.m30+"\t"+this.m31+"\t"+this.m32+"\t"+this.m33+"] ]"});$_M(c$,"setIdentity",function(){this.m00=1;this.m10=this.m03=this.m02=this.m01=0;this.m11=1;this.m21=this.m20=this.m13=this.m12=0;this.m22=1;this.m32=this.m31=this.m30=this.m23=0;this.m33=1});$_M(c$,"setElement",
function(a,b,c){if(0==a)if(0==b)this.m00=c;else if(1==b)this.m01=c;else if(2==b)this.m02=c;else if(3==b)this.m03=c;else throw new ArrayIndexOutOfBoundsException("column must be 0 to 3 and is "+b);else if(1==a)if(0==b)this.m10=c;else if(1==b)this.m11=c;else if(2==b)this.m12=c;else if(3==b)this.m13=c;else throw new ArrayIndexOutOfBoundsException("column must be 0 to 3 and is "+b);else if(2==a)if(0==b)this.m20=c;else if(1==b)this.m21=c;else if(2==b)this.m22=c;else if(3==b)this.m23=c;else throw new ArrayIndexOutOfBoundsException("column must be 0 to 3 and is "+
b);else if(3==a)if(0==b)this.m30=c;else if(1==b)this.m31=c;else if(2==b)this.m32=c;else if(3==b)this.m33=c;else throw new ArrayIndexOutOfBoundsException("column must be 0 to 3 and is "+b);else throw new ArrayIndexOutOfBoundsException("row must be 0 to 2 and is "+a);},"~N,~N,~N");$_M(c$,"getElement",function(a,b){if(0==a){if(0==b)return this.m00;if(1==b)return this.m01;if(2==b)return this.m02;if(3==b)return this.m03;throw new ArrayIndexOutOfBoundsException("column must be 0 to 3 and is "+b);}if(1==
a){if(0==b)return this.m10;if(1==b)return this.m11;if(2==b)return this.m12;if(3==b)return this.m13;throw new ArrayIndexOutOfBoundsException("column must be 0 to 3 and is "+b);}if(2==a){if(0==b)return this.m20;if(1==b)return this.m21;if(2==b)return this.m22;if(3==b)return this.m23;throw new ArrayIndexOutOfBoundsException("column must be 0 to 3 and is "+b);}if(3==a){if(0==b)return this.m30;if(1==b)return this.m31;if(2==b)return this.m32;if(3==b)return this.m33;throw new ArrayIndexOutOfBoundsException("column must be 0 to 3 and is "+
b);}throw new ArrayIndexOutOfBoundsException("row must be 0 to 3 and is "+a);},"~N,~N");$_M(c$,"get",function(a){a.x=this.m03;a.y=this.m13;a.z=this.m23},"JU.V3");$_M(c$,"getRotationScale",function(a){a.m00=this.m00;a.m01=this.m01;a.m02=this.m02;a.m10=this.m10;a.m11=this.m11;a.m12=this.m12;a.m20=this.m20;a.m21=this.m21;a.m22=this.m22},"JU.M3");$_M(c$,"setRotationScale",function(a){this.m00=a.m00;this.m01=a.m01;this.m02=a.m02;this.m10=a.m10;this.m11=a.m11;this.m12=a.m12;this.m20=a.m20;this.m21=a.m21;
this.m22=a.m22},"JU.M3");$_M(c$,"setRow",function(a,b){if(0==a)this.m00=b[0],this.m01=b[1],this.m02=b[2],this.m03=b[3];else if(1==a)this.m10=b[0],this.m11=b[1],this.m12=b[2],this.m13=b[3];else if(2==a)this.m20=b[0],this.m21=b[1],this.m22=b[2],this.m23=b[3];else if(3==a)this.m30=b[0],this.m31=b[1],this.m32=b[2],this.m33=b[3];else throw new ArrayIndexOutOfBoundsException("row must be 0 to 3 and is "+a);},"~N,~A");$_M(c$,"getRow",function(a,b){if(0==a)b[0]=this.m00,b[1]=this.m01,b[2]=this.m02,b[3]=this.m03;
else if(1==a)b[0]=this.m10,b[1]=this.m11,b[2]=this.m12,b[3]=this.m13;else if(2==a)b[0]=this.m20,b[1]=this.m21,b[2]=this.m22,b[3]=this.m23;else if(3==a)b[0]=this.m30,b[1]=this.m31,b[2]=this.m32,b[3]=this.m33;else throw new ArrayIndexOutOfBoundsException("row must be 0 to 3 and is "+a);},"~N,~A");$_M(c$,"setColumn4",function(a,b,c,d,e){if(0==a)this.m00=b,this.m10=c,this.m20=d,this.m30=e;else if(1==a)this.m01=b,this.m11=c,this.m21=d,this.m31=e;else if(2==a)this.m02=b,this.m12=c,this.m22=d,this.m32=e;
else if(3==a)this.m03=b,this.m13=c,this.m23=d,this.m33=e;else throw new ArrayIndexOutOfBoundsException("column must be 0 to 3 and is "+a);},"~N,~N,~N,~N,~N");$_M(c$,"setColumn",function(a,b){if(0==a)this.m00=b[0],this.m10=b[1],this.m20=b[2],this.m30=b[3];else if(1==a)this.m01=b[0],this.m11=b[1],this.m21=b[2],this.m31=b[3];else if(2==a)this.m02=b[0],this.m12=b[1],this.m22=b[2],this.m32=b[3];else if(3==a)this.m03=b[0],this.m13=b[1],this.m23=b[2],this.m33=b[3];else throw new ArrayIndexOutOfBoundsException("column must be 0 to 3 and is "+
a);},"~N,~A");$_M(c$,"getColumn",function(a,b){if(0==a)b[0]=this.m00,b[1]=this.m10,b[2]=this.m20,b[3]=this.m30;else if(1==a)b[0]=this.m01,b[1]=this.m11,b[2]=this.m21,b[3]=this.m31;else if(2==a)b[0]=this.m02,b[1]=this.m12,b[2]=this.m22,b[3]=this.m32;else if(3==a)b[0]=this.m03,b[1]=this.m13,b[2]=this.m23,b[3]=this.m33;else throw new ArrayIndexOutOfBoundsException("column must be 0 to 3 and is "+a);},"~N,~A");$_M(c$,"sub",function(a){this.m00-=a.m00;this.m01-=a.m01;this.m02-=a.m02;this.m03-=a.m03;this.m10-=
a.m10;this.m11-=a.m11;this.m12-=a.m12;this.m13-=a.m13;this.m20-=a.m20;this.m21-=a.m21;this.m22-=a.m22;this.m23-=a.m23;this.m30-=a.m30;this.m31-=a.m31;this.m32-=a.m32;this.m33-=a.m33},"JU.M4");$_M(c$,"transpose",function(){var a=this.m01;this.m01=this.m10;this.m10=a;a=this.m02;this.m02=this.m20;this.m20=a;a=this.m03;this.m03=this.m30;this.m30=a;a=this.m12;this.m12=this.m21;this.m21=a;a=this.m13;this.m13=this.m31;this.m31=a;a=this.m23;this.m23=this.m32;this.m32=a});$_M(c$,"invertM",function(a){this.setM(a);
this.invert()},"JU.M4");$_M(c$,"invert",function(){var a=this.determinant();0!=a&&(a=1/a,this.set(this.m11*(this.m22*this.m33-this.m23*this.m32)+this.m12*(this.m23*this.m31-this.m21*this.m33)+this.m13*(this.m21*this.m32-this.m22*this.m31),this.m21*(this.m02*this.m33-this.m03*this.m32)+this.m22*(this.m03*this.m31-this.m01*this.m33)+this.m23*(this.m01*this.m32-this.m02*this.m31),this.m31*(this.m02*this.m13-this.m03*this.m12)+this.m32*(this.m03*this.m11-this.m01*this.m13)+this.m33*(this.m01*this.m12-
this.m02*this.m11),this.m01*(this.m13*this.m22-this.m12*this.m23)+this.m02*(this.m11*this.m23-this.m13*this.m21)+this.m03*(this.m12*this.m21-this.m11*this.m22),this.m12*(this.m20*this.m33-this.m23*this.m30)+this.m13*(this.m22*this.m30-this.m20*this.m32)+this.m10*(this.m23*this.m32-this.m22*this.m33),this.m22*(this.m00*this.m33-this.m03*this.m30)+this.m23*(this.m02*this.m30-this.m00*this.m32)+this.m20*(this.m03*this.m32-this.m02*this.m33),this.m32*(this.m00*this.m13-this.m03*this.m10)+this.m33*(this.m02*
this.m10-this.m00*this.m12)+this.m30*(this.m03*this.m12-this.m02*this.m13),this.m02*(this.m13*this.m20-this.m10*this.m23)+this.m03*(this.m10*this.m22-this.m12*this.m20)+this.m00*(this.m12*this.m23-this.m13*this.m22),this.m13*(this.m20*this.m31-this.m21*this.m30)+this.m10*(this.m21*this.m33-this.m23*this.m31)+this.m11*(this.m23*this.m30-this.m20*this.m33),this.m23*(this.m00*this.m31-this.m01*this.m30)+this.m20*(this.m01*this.m33-this.m03*this.m31)+this.m21*(this.m03*this.m30-this.m00*this.m33),this.m33*
(this.m00*this.m11-this.m01*this.m10)+this.m30*(this.m01*this.m13-this.m03*this.m11)+this.m31*(this.m03*this.m10-this.m00*this.m13),this.m03*(this.m11*this.m20-this.m10*this.m21)+this.m00*(this.m13*this.m21-this.m11*this.m23)+this.m01*(this.m10*this.m23-this.m13*this.m20),this.m10*(this.m22*this.m31-this.m21*this.m32)+this.m11*(this.m20*this.m32-this.m22*this.m30)+this.m12*(this.m21*this.m30-this.m20*this.m31),this.m20*(this.m02*this.m31-this.m01*this.m32)+this.m21*(this.m00*this.m32-this.m02*this.m30)+
this.m22*(this.m01*this.m30-this.m00*this.m31),this.m30*(this.m02*this.m11-this.m01*this.m12)+this.m31*(this.m00*this.m12-this.m02*this.m10)+this.m32*(this.m01*this.m10-this.m00*this.m11),this.m00*(this.m11*this.m22-this.m12*this.m21)+this.m01*(this.m12*this.m20-this.m10*this.m22)+this.m02*(this.m10*this.m21-this.m11*this.m20)),this.mul(a))});$_M(c$,"determinant",function(){return(this.m00*this.m11-this.m01*this.m10)*(this.m22*this.m33-this.m23*this.m32)-(this.m00*this.m12-this.m02*this.m10)*(this.m21*
this.m33-this.m23*this.m31)+(this.m00*this.m13-this.m03*this.m10)*(this.m21*this.m32-this.m22*this.m31)+(this.m01*this.m12-this.m02*this.m11)*(this.m20*this.m33-this.m23*this.m30)-(this.m01*this.m13-this.m03*this.m11)*(this.m20*this.m32-this.m22*this.m30)+(this.m02*this.m13-this.m03*this.m12)*(this.m20*this.m31-this.m21*this.m30)});$_M(c$,"setM3",function(a){this.m00=a.m00;this.m01=a.m01;this.m02=a.m02;this.m03=0;this.m10=a.m10;this.m11=a.m11;this.m12=a.m12;this.m13=0;this.m20=a.m20;this.m21=a.m21;
this.m22=a.m22;this.m32=this.m31=this.m30=this.m23=0;this.m33=1},"JU.M3");$_M(c$,"setA",function(a,b){this.m00=a[b++];this.m01=a[b++];this.m02=a[b++];this.m03=a[b++];this.m10=a[b++];this.m11=a[b++];this.m12=a[b++];this.m13=a[b++];this.m20=a[b++];this.m21=a[b++];this.m22=a[b++];this.m23=a[b++];this.m30=a[b++];this.m31=a[b++];this.m32=a[b++];this.m33=a[b++]},"~A,~N");$_M(c$,"setTranslation",function(a){this.m03=a.x;this.m13=a.y;this.m23=a.z},"JU.V3");$_M(c$,"rotX",function(a){var b=Math.cos(a);a=Math.sin(a);
this.m00=1;this.m10=this.m03=this.m02=this.m01=0;this.m11=b;this.m12=-a;this.m20=this.m13=0;this.m21=a;this.m22=b;this.m32=this.m31=this.m30=this.m23=0;this.m33=1},"~N");$_M(c$,"rotY",function(a){var b=Math.cos(a);a=Math.sin(a);this.m00=b;this.m01=0;this.m02=a;this.m10=this.m03=0;this.m11=1;this.m13=this.m12=0;this.m20=-a;this.m21=0;this.m22=b;this.m32=this.m31=this.m30=this.m23=0;this.m33=1},"~N");$_M(c$,"rotZ",function(a){var b=Math.cos(a);a=Math.sin(a);this.m00=b;this.m01=-a;this.m03=this.m02=
0;this.m10=a;this.m11=b;this.m21=this.m20=this.m13=this.m12=0;this.m22=1;this.m32=this.m31=this.m30=this.m23=0;this.m33=1},"~N");$_M(c$,"mul",($fz=function(a){this.m00*=a;this.m01*=a;this.m02*=a;this.m03*=a;this.m10*=a;this.m11*=a;this.m12*=a;this.m13*=a;this.m20*=a;this.m21*=a;this.m22*=a;this.m23*=a;this.m30*=a;this.m31*=a;this.m32*=a;this.m33*=a},$fz.isPrivate=!0,$fz),"~N");$_M(c$,"mulM4",function(a){this.mul2(this,a)},"JU.M4");$_M(c$,"mul2",function(a,b){this.set(a.m00*b.m00+a.m01*b.m10+a.m02*
b.m20+a.m03*b.m30,a.m00*b.m01+a.m01*b.m11+a.m02*b.m21+a.m03*b.m31,a.m00*b.m02+a.m01*b.m12+a.m02*b.m22+a.m03*b.m32,a.m00*b.m03+a.m01*b.m13+a.m02*b.m23+a.m03*b.m33,a.m10*b.m00+a.m11*b.m10+a.m12*b.m20+a.m13*b.m30,a.m10*b.m01+a.m11*b.m11+a.m12*b.m21+a.m13*b.m31,a.m10*b.m02+a.m11*b.m12+a.m12*b.m22+a.m13*b.m32,a.m10*b.m03+a.m11*b.m13+a.m12*b.m23+a.m13*b.m33,a.m20*b.m00+a.m21*b.m10+a.m22*b.m20+a.m23*b.m30,a.m20*b.m01+a.m21*b.m11+a.m22*b.m21+a.m23*b.m31,a.m20*b.m02+a.m21*b.m12+a.m22*b.m22+a.m23*b.m32,a.m20*
b.m03+a.m21*b.m13+a.m22*b.m23+a.m23*b.m33,a.m30*b.m00+a.m31*b.m10+a.m32*b.m20+a.m33*b.m30,a.m30*b.m01+a.m31*b.m11+a.m32*b.m21+a.m33*b.m31,a.m30*b.m02+a.m31*b.m12+a.m32*b.m22+a.m33*b.m32,a.m30*b.m03+a.m31*b.m13+a.m32*b.m23+a.m33*b.m33)},"JU.M4,JU.M4");Clazz.overrideMethod(c$,"equals",function(a){return!Clazz.instanceOf(a,JU.M4)?!1:this.m00==a.m00&&this.m01==a.m01&&this.m02==a.m02&&this.m03==a.m03&&this.m10==a.m10&&this.m11==a.m11&&this.m12==a.m12&&this.m13==a.m13&&this.m20==a.m20&&this.m21==a.m21&&
this.m22==a.m22&&this.m23==a.m23&&this.m30==a.m30&&this.m31==a.m31&&this.m32==a.m32&&this.m33==a.m33},"~O");Clazz.overrideMethod(c$,"hashCode",function(){return JU.T3.floatToIntBits0(this.m00)^JU.T3.floatToIntBits0(this.m01)^JU.T3.floatToIntBits0(this.m02)^JU.T3.floatToIntBits0(this.m03)^JU.T3.floatToIntBits0(this.m10)^JU.T3.floatToIntBits0(this.m11)^JU.T3.floatToIntBits0(this.m12)^JU.T3.floatToIntBits0(this.m13)^JU.T3.floatToIntBits0(this.m20)^JU.T3.floatToIntBits0(this.m21)^JU.T3.floatToIntBits0(this.m22)^
JU.T3.floatToIntBits0(this.m23)^JU.T3.floatToIntBits0(this.m30)^JU.T3.floatToIntBits0(this.m31)^JU.T3.floatToIntBits0(this.m32)^JU.T3.floatToIntBits0(this.m33)});$_M(c$,"transformT2",function(a,b){b.set(this.m00*a.x+this.m01*a.y+this.m02*a.z+this.m03*a.w,this.m10*a.x+this.m11*a.y+this.m12*a.z+this.m13*a.w,this.m20*a.x+this.m21*a.y+this.m22*a.z+this.m23*a.w,this.m30*a.x+this.m31*a.y+this.m32*a.z+this.m33*a.w)},"JU.T4,JU.T4");$_M(c$,"transform4",function(a){this.transformT2(a,a)},"JU.T4");$_M(c$,"transform2",
function(a,b){try{b.set(this.m00*a.x+this.m01*a.y+this.m02*a.z+this.m03,this.m10*a.x+this.m11*a.y+this.m12*a.z+this.m13,this.m20*a.x+this.m21*a.y+this.m22*a.z+this.m23)}catch(c){if(!Clazz.exceptionOf(c,NullPointerException))throw c;}},"JU.T3,JU.T3");$_M(c$,"transform",function(a){this.transform2(a,a)},"JU.T3");$_M(c$,"transformV2",function(a,b){b.set(this.m00*a.x+this.m01*a.y+this.m02*a.z,this.m10*a.x+this.m11*a.y+this.m12*a.z,this.m20*a.x+this.m21*a.y+this.m22*a.z)},"JU.V3,JU.V3");$_M(c$,"transformV",
function(a){this.transformV2(a,a)},"JU.V3");$_M(c$,"setZero",function(){this.m33=this.m32=this.m31=this.m30=this.m23=this.m22=this.m21=this.m20=this.m13=this.m12=this.m11=this.m10=this.m03=this.m02=this.m01=this.m00=0});$_M(c$,"set",($fz=function(a,b,c,d,e,f,g,h,k,l,m,n,q,p,r,s){this.m00=a;this.m01=b;this.m02=c;this.m03=d;this.m10=e;this.m11=f;this.m12=g;this.m13=h;this.m20=k;this.m21=l;this.m22=m;this.m23=n;this.m30=q;this.m31=p;this.m32=r;this.m33=s},$fz.isPrivate=!0,$fz),"~N,~N,~N,~N,~N,~N,~N,~N,~N,~N,~N,~N,~N,~N,~N,~N")}),
Clazz.declarePackage("JU"),Clazz.load(null,"JU.A4",["JU.T3"],function(){c$=Clazz.decorateAsClass(function(){this.angle=this.z=this.y=this.x=0;Clazz.instantialize(this,arguments)},JU,"A4",null,java.io.Serializable);Clazz.makeConstructor(c$,function(){this.z=1});c$.new4=$_M(c$,"new4",function(a,b,c,d){var e=new JU.A4;e.set4(a,b,c,d);return e},"~N,~N,~N,~N");c$.newAA=$_M(c$,"newAA",function(a){var b=new JU.A4;b.set4(a.x,a.y,a.z,a.angle);return b},"JU.A4");c$.newVA=$_M(c$,"newVA",function(a,b){var c=
new JU.A4;c.setVA(a,b);return c},"JU.V3,~N");$_M(c$,"setVA",function(a,b){this.x=a.x;this.y=a.y;this.z=a.z;this.angle=b},"JU.V3,~N");$_M(c$,"set4",function(a,b,c,d){this.x=a;this.y=b;this.z=c;this.angle=d},"~N,~N,~N,~N");$_M(c$,"setAA",function(a){this.x=a.x;this.y=a.y;this.z=a.z;this.angle=a.angle},"JU.A4");$_M(c$,"setM",function(a){this.setFromMat(a.m00,a.m01,a.m02,a.m10,a.m11,a.m12,a.m20,a.m21,a.m22)},"JU.M3");$_M(c$,"setFromMat",($fz=function(a,b,c,d,e,f,g,h,k){a=0.5*(a+e+k-1);this.x=h-f;this.y=
c-g;this.z=d-b;b=0.5*Math.sqrt(this.x*this.x+this.y*this.y+this.z*this.z);this.angle=Math.atan2(b,a)},$fz.isPrivate=!0,$fz),"~N,~N,~N,~N,~N,~N,~N,~N,~N");Clazz.overrideMethod(c$,"toString",function(){return"("+this.x+", "+this.y+", "+this.z+", "+this.angle+")"});Clazz.overrideMethod(c$,"equals",function(a){return!Clazz.instanceOf(a,JU.A4)?!1:this.x==a.x&&this.y==a.y&&this.z==a.z&&this.angle==a.angle},"~O");Clazz.overrideMethod(c$,"hashCode",function(){return JU.T3.floatToIntBits0(this.x)^JU.T3.floatToIntBits0(this.y)^
JU.T3.floatToIntBits0(this.z)^JU.T3.floatToIntBits0(this.angle)})}),Clazz.declarePackage("JU"),Clazz.load(null,"JU.BS",["java.lang.IndexOutOfBoundsException","$.NegativeArraySizeException","JU.SB"],function(){c$=Clazz.decorateAsClass(function(){this.words=null;this.wordsInUse=0;this.sizeIsSticky=!1;Clazz.instantialize(this,arguments)},JU,"BS",null,Cloneable);c$.wordIndex=$_M(c$,"wordIndex",($fz=function(a){return a>>5},$fz.isPrivate=!0,$fz),"~N");$_M(c$,"recalculateWordsInUse",($fz=function(){var a;
for(a=this.wordsInUse-1;0<=a&&0==this.words[a];a--);this.wordsInUse=a+1},$fz.isPrivate=!0,$fz));Clazz.makeConstructor(c$,function(){this.initWords(32);this.sizeIsSticky=!1});c$.newN=$_M(c$,"newN",function(a){var b=new JU.BS;b.init(a);return b},"~N");$_M(c$,"init",($fz=function(a){if(0>a)throw new NegativeArraySizeException("nbits < 0: "+a);this.initWords(a);this.sizeIsSticky=!0},$fz.isPrivate=!0,$fz),"~N");$_M(c$,"initWords",($fz=function(a){this.words=Clazz.newIntArray(JU.BS.wordIndex(a-1)+1,0)},
$fz.isPrivate=!0,$fz),"~N");$_M(c$,"ensureCapacity",($fz=function(a){this.words.length<a&&(a=Math.max(2*this.words.length,a),this.setLength(a),this.sizeIsSticky=!1)},$fz.isPrivate=!0,$fz),"~N");$_M(c$,"expandTo",($fz=function(a){a+=1;this.wordsInUse<a&&(this.ensureCapacity(a),this.wordsInUse=a)},$fz.isPrivate=!0,$fz),"~N");$_M(c$,"set",function(a){if(0>a)throw new IndexOutOfBoundsException("bitIndex < 0: "+a);var b=JU.BS.wordIndex(a);this.expandTo(b);this.words[b]|=1<<a},"~N");$_M(c$,"setBitTo",function(a,
b){b?this.set(a):this.clear(a)},"~N,~B");$_M(c$,"setBits",function(a,b){if(a!=b){var c=JU.BS.wordIndex(a),d=JU.BS.wordIndex(b-1);this.expandTo(d);var e=-1<<a,f=-1>>>-b;if(c==d)this.words[c]|=e&f;else{this.words[c]|=e;for(c+=1;c<d;c++)this.words[c]=-1;this.words[d]|=f}}},"~N,~N");$_M(c$,"clear",function(a){if(0>a)throw new IndexOutOfBoundsException("bitIndex < 0: "+a);var b=JU.BS.wordIndex(a);b>=this.wordsInUse||(this.words[b]&=~(1<<a),this.recalculateWordsInUse())},"~N");$_M(c$,"clearBits",function(a,
b){if(a!=b){var c=JU.BS.wordIndex(a);if(!(c>=this.wordsInUse)){var d=JU.BS.wordIndex(b-1);d>=this.wordsInUse&&(b=this.length(),d=this.wordsInUse-1);var e=-1<<a,f=-1>>>-b;if(c==d)this.words[c]&=~(e&f);else{this.words[c]&=~e;for(c+=1;c<d;c++)this.words[c]=0;this.words[d]&=~f}this.recalculateWordsInUse()}}},"~N,~N");$_M(c$,"clearAll",function(){for(;0<this.wordsInUse;)this.words[--this.wordsInUse]=0});$_M(c$,"get",function(a){if(0>a)throw new IndexOutOfBoundsException("bitIndex < 0: "+a);var b=JU.BS.wordIndex(a);
return b<this.wordsInUse&&0!=(this.words[b]&1<<a)},"~N");$_M(c$,"nextSetBit",function(a){if(0>a)throw new IndexOutOfBoundsException("fromIndex < 0: "+a);var b=JU.BS.wordIndex(a);if(b>=this.wordsInUse)return-1;for(a=this.words[b]&-1<<a;;){if(0!=a)return 32*b+Integer.numberOfTrailingZeros(a);if(++b==this.wordsInUse)return-1;a=this.words[b]}},"~N");$_M(c$,"nextClearBit",function(a){if(0>a)throw new IndexOutOfBoundsException("fromIndex < 0: "+a);var b=JU.BS.wordIndex(a);if(b>=this.wordsInUse)return a;
for(a=~this.words[b]&-1<<a;;){if(0!=a)return 32*b+Integer.numberOfTrailingZeros(a);if(++b==this.wordsInUse)return 32*this.wordsInUse;a=~this.words[b]}},"~N");$_M(c$,"length",function(){return 0==this.wordsInUse?0:32*(this.wordsInUse-1)+(32-Integer.numberOfLeadingZeros(this.words[this.wordsInUse-1]))});$_M(c$,"isEmpty",function(){return 0==this.wordsInUse});$_M(c$,"intersects",function(a){for(var b=Math.min(this.wordsInUse,a.wordsInUse)-1;0<=b;b--)if(0!=(this.words[b]&a.words[b]))return!0;return!1},
"JU.BS");$_M(c$,"cardinality",function(){for(var a=0,b=0;b<this.wordsInUse;b++)a+=Integer.bitCount(this.words[b]);return a});$_M(c$,"and",function(a){if(this!==a){for(;this.wordsInUse>a.wordsInUse;)this.words[--this.wordsInUse]=0;for(var b=0;b<this.wordsInUse;b++)this.words[b]&=a.words[b];this.recalculateWordsInUse()}},"JU.BS");$_M(c$,"or",function(a){if(this!==a){var b=Math.min(this.wordsInUse,a.wordsInUse);this.wordsInUse<a.wordsInUse&&(this.ensureCapacity(a.wordsInUse),this.wordsInUse=a.wordsInUse);
for(var c=0;c<b;c++)this.words[c]|=a.words[c];b<a.wordsInUse&&System.arraycopy(a.words,b,this.words,b,this.wordsInUse-b)}},"JU.BS");$_M(c$,"xor",function(a){var b=Math.min(this.wordsInUse,a.wordsInUse);this.wordsInUse<a.wordsInUse&&(this.ensureCapacity(a.wordsInUse),this.wordsInUse=a.wordsInUse);for(var c=0;c<b;c++)this.words[c]^=a.words[c];b<a.wordsInUse&&System.arraycopy(a.words,b,this.words,b,a.wordsInUse-b);this.recalculateWordsInUse()},"JU.BS");$_M(c$,"andNot",function(a){for(var b=Math.min(this.wordsInUse,
a.wordsInUse)-1;0<=b;b--)this.words[b]&=~a.words[b];this.recalculateWordsInUse()},"JU.BS");Clazz.overrideMethod(c$,"hashCode",function(){for(var a=1234,b=this.wordsInUse;0<=--b;)a^=this.words[b]*(b+1);return a>>32^a});$_M(c$,"size",function(){return 32*this.words.length});Clazz.overrideMethod(c$,"equals",function(a){if(!Clazz.instanceOf(a,JU.BS))return!1;if(this===a)return!0;if(this.wordsInUse!=a.wordsInUse)return!1;for(var b=0;b<this.wordsInUse;b++)if(this.words[b]!=a.words[b])return!1;return!0},
"~O");Clazz.overrideMethod(c$,"clone",function(){!this.sizeIsSticky&&this.wordsInUse!=this.words.length&&this.setLength(this.wordsInUse);return JU.BS.copy(this)});$_M(c$,"setLength",($fz=function(a){var b=Clazz.newIntArray(a,0);System.arraycopy(this.words,0,b,0,Math.min(this.wordsInUse,a));this.words=b},$fz.isPrivate=!0,$fz),"~N");Clazz.overrideMethod(c$,"toString",function(){var a=128<this.wordsInUse?this.cardinality():32*this.wordsInUse,a=JU.SB.newN(6*a+2);a.appendC("{");var b=this.nextSetBit(0);
if(-1!=b){a.appendI(b);for(b=this.nextSetBit(b+1);0<=b;b=this.nextSetBit(b+1)){var c=this.nextClearBit(b);do a.append(", ").appendI(b);while(++b<c)}}a.appendC("}");return a.toString()});c$.copy=$_M(c$,"copy",function(a){var b=null,b=Clazz.clone(a),c=a.wordsInUse;0==c?b.words=JU.BS.emptyBitmap:(b.words=Clazz.newIntArray(c,0),System.arraycopy(a.words,0,b.words,0,c));return b},"JU.BS");$_M(c$,"cardinalityN",function(a){for(var b=this.cardinality(),c=this.length();--c>=a;)this.get(c)&&b--;return b},"~N");
Clazz.defineStatics(c$,"ADDRESS_BITS_PER_WORD",5,"BITS_PER_WORD",32,"WORD_MASK",4294967295,"emptyBitmap",Clazz.newIntArray(0,0))}),Clazz.declarePackage("JU"),c$=Clazz.decorateAsClass(function(){this.s=this.sb=null;Clazz.instantialize(this,arguments)},JU,"SB"),Clazz.makeConstructor(c$,function(){this.s=""}),c$.newN=$_M(c$,"newN",function(){return new JU.SB},"~N"),c$.newS=$_M(c$,"newS",function(a){var b=new JU.SB;b.s=a;return b},"~S"),$_M(c$,"append",function(a){this.s+=a;return this},"~S"),$_M(c$,
"appendC",function(a){this.s+=a;return this},"~S"),$_M(c$,"appendI",function(a){this.s+=a;return this},"~N"),$_M(c$,"appendB",function(a){this.s+=a;return this},"~B"),$_M(c$,"appendF",function(a){a=""+a;0>a.indexOf(".")&&0>a.indexOf("e")&&(a+=".0");this.s+=a;return this},"~N"),$_M(c$,"appendD",function(a){a=""+a;0>a.indexOf(".")&&0>a.indexOf("e")&&(a+=".0");this.s+=a;return this},"~N"),$_M(c$,"appendSB",function(a){this.s+=a.s;return this},"JU.SB"),$_M(c$,"appendO",function(a){this.s+=a.toString();
return this},"~O"),$_M(c$,"appendCB",function(a,b,c){for(;0<=--c;)this.s+=a[b++]},"~A,~N,~N"),Clazz.overrideMethod(c$,"toString",function(){return this.s}),$_M(c$,"length",function(){return this.s.length}),$_M(c$,"indexOf",function(a){return this.s.indexOf(a)},"~S"),$_M(c$,"charAt",function(a){return this.s.charAt(a)},"~N"),$_M(c$,"setLength",function(a){this.s=this.s.substring(0,a)},"~N"),$_M(c$,"lastIndexOf",function(a){return this.s.lastIndexOf(a)},"~S"),$_M(c$,"indexOf2",function(a,b){return this.s.indexOf(a,
b)},"~S,~N"),$_M(c$,"substring",function(a){return this.s.substring(a)},"~N"),$_M(c$,"substring2",function(a,b){return this.s.substring(a,b)},"~N,~N"),$_M(c$,"toBytes",function(a,b){0>b&&(b=this.length()-a);for(var c=Clazz.newByteArray(b,0),d=a+b,e=d-a;--d>=a;)c[--e]=this.charAt(d).charCodeAt(0);return c},"~N,~N"),Clazz.declarePackage("JU"),Clazz.load(["java.lang.Boolean"],"JU.DecimalFormat",["java.lang.Double","$.Float","JU.ParserJS","$.SB"],function(){c$=Clazz.declareType(JU,"DecimalFormat");c$.setUseNumberLocalization=
$_M(c$,"setUseNumberLocalization",function(a){JU.DecimalFormat.useNumberLocalization[0]=a?Boolean.TRUE:Boolean.FALSE},"~B");c$.formatDecimalDbl=$_M(c$,"formatDecimalDbl",function(a,b){return 2147483647==b||-Infinity==a||Infinity==a||Double.isNaN(a)?""+a:JU.DecimalFormat.formatDecimal(a,b)},"~N,~N");c$.formatDecimal=$_M(c$,"formatDecimal",function(a,b){if(2147483647==b||-Infinity==a||Infinity==a||Float.isNaN(a))return""+a;var c;if(0>b){b=-b;b>JU.DecimalFormat.formattingStrings.length&&(b=JU.DecimalFormat.formattingStrings.length);
if(0==a)return JU.DecimalFormat.formattingStrings[b]+"E+0";var d;1>Math.abs(a)?(c=10,d=1E-10*a):(c=-10,d=1E10*a);d=(""+d).toUpperCase();var e=d.indexOf("E");c=JU.ParserJS.parseInt(d.substring(e+1))+c;return 0>e?""+a:JU.DecimalFormat.formatDecimal(JU.ParserJS.parseFloat(d.substring(0,e)),b-1)+"E"+(0<=c?"+":"")+c}b>=JU.DecimalFormat.formattingStrings.length&&(b=JU.DecimalFormat.formattingStrings.length-1);d=(""+a).toUpperCase();var f=d.startsWith("-");f&&(d=d.substring(1));c=d.indexOf(".");if(0>c)return d+
JU.DecimalFormat.formattingStrings[b].substring(1);e=d.indexOf("E-");0<e&&(c=JU.ParserJS.parseInt(d.substring(e+1)),d="0."+"0000000000000000000000000000000000000000".substring(0,-c-1)+d.substring(0,1)+d.substring(2,e),c=1);e=d.indexOf("E");0<e&&(c=JU.ParserJS.parseInt(d.substring(e+1)),d=d.substring(0,1)+d.substring(2,e)+"0000000000000000000000000000000000000000",d=d.substring(0,c+1)+"."+d.substring(c+1),c=d.indexOf("."));var g=d.length,e=b+c+1;if(e<g&&"5"<=d.charAt(e))return JU.DecimalFormat.formatDecimal(a+
(f?-1:1)*JU.DecimalFormat.formatAdds[b],b);for(var h=JU.SB.newS(d.substring(0,0==b?c:++c)),e=0;e<b;e++,c++)c<g?h.appendC(d.charAt(c)):h.appendC("0");d=(f?"-":"")+h;return Boolean.TRUE.equals(JU.DecimalFormat.useNumberLocalization[0])?d:d.$replace(",",".")},"~N,~N");c$.formatDecimalTrimmed=$_M(c$,"formatDecimalTrimmed",function(a,b){for(var c=JU.DecimalFormat.formatDecimalDbl(a,b),d=c.length-1;0<=d&&"0"==c.charAt(d);)d--;return c.substring(0,d+1)},"~N,~N");Clazz.defineStatics(c$,"formattingStrings",
"0 0.0 0.00 0.000 0.0000 0.00000 0.000000 0.0000000 0.00000000 0.000000000".split(" "),"zeros","0000000000000000000000000000000000000000","formatAdds",[0.5,0.05,0.005,5E-4,5E-5,5E-6,5E-7,5E-8,5E-9,5E-10]);c$.useNumberLocalization=c$.prototype.useNumberLocalization=[Boolean.TRUE]}),Clazz.declarePackage("JU"),Clazz.load(null,"JU.ParserJS",["java.lang.Character","$.Float"],function(){c$=Clazz.declareType(JU,"ParserJS");c$.parseInt=$_M(c$,"parseInt",function(a){return JU.ParserJS.parseIntNext(a,[0])},
"~S");c$.parseIntNext=$_M(c$,"parseIntNext",function(a,b){var c=a.length;return 0>b[0]||b[0]>=c?-2147483648:JU.ParserJS.parseIntChecked(a,c,b)},"~S,~A");c$.parseIntChecked=$_M(c$,"parseIntChecked",function(a,b,c){var d=!1,e=0,f=c[0];if(0>f)return-2147483648;for(var g;f<b&&JU.ParserJS.isWhiteSpace(a,f);)++f;var h=!1;f<b&&45==a.charCodeAt(f)&&(h=!0,++f);for(;f<b&&48<=(g=a.charCodeAt(f))&&57>=g;)e=10*e+(g-48),d=!0,++f;d?h&&(e=-e):e=-2147483648;c[0]=f;return e},"~S,~N,~A");c$.isWhiteSpace=$_M(c$,"isWhiteSpace",
function(a,b){var c;return 0<=b&&(" "==(c=a.charAt(b))||"\t"==c||"\n"==c)},"~S,~N");c$.parseFloatChecked=$_M(c$,"parseFloatChecked",function(a,b,c,d){var e=!1,f=c[0];if(d&&a.indexOf("\n")!=a.lastIndexOf("\n"))return NaN;for(;f<b&&JU.ParserJS.isWhiteSpace(a,f);)++f;var g=!1;f<b&&"-"==a.charAt(f)&&(++f,g=!0);for(var h=0,k=0,l=0;f<b&&48<=(h=a.charCodeAt(f))&&57>=h;)k=10*k+1*(h-48),++f,e=!0;var m=!1,n=0,q=0==k?-1:0;if(46==h)for(m=!0;++f<b&&48<=(h=a.charCodeAt(f))&&57>=h;){e=!0;if(0>q){if(48==h){q--;continue}q=
-q}n<JU.ParserJS.decimalScale.length&&(l=10*l+1*(h-48),n++)}e?0<l?(e=l*JU.ParserJS.decimalScale[n-1],e=1<q?q-2<JU.ParserJS.decimalScale.length?e*JU.ParserJS.decimalScale[q-2]:e*Math.pow(10,1-q):e+k):e=k:e=NaN;k=!1;if(f<b&&(69==h||101==h||68==h)){k=!0;if(++f>=b)return NaN;h=a.charCodeAt(f);if(43==h&&++f>=b)return NaN;c[0]=f;f=JU.ParserJS.parseIntChecked(a,b,c);if(-2147483648==f)return NaN;0<f&&f<=JU.ParserJS.tensScale.length?e*=JU.ParserJS.tensScale[f-1]:0>f&&-f<=JU.ParserJS.decimalScale.length?e*=
JU.ParserJS.decimalScale[-f-1]:0!=f&&(e*=Math.pow(10,f))}else c[0]=f;g&&(e=-e);Infinity==e&&(e=3.4028235E38);return!d||(!k||m)&&JU.ParserJS.checkTrailingText(a,c[0],b)?e:NaN},"~S,~N,~A,~B");c$.checkTrailingText=$_M(c$,"checkTrailingText",function(a,b,c){for(var d;b<c&&(Character.isWhitespace(d=a.charAt(b))||";"==d);)++b;return b==c},"~S,~N,~N");c$.parseFloatArray=$_M(c$,"parseFloatArray",function(a){return JU.ParserJS.parseFloatArrayNext(a,Clazz.newIntArray(1,0),null,null,null)},"~S");c$.parseFloatArrayInfested=
$_M(c$,"parseFloatArrayInfested",function(a,b){for(var c=b.length,d=a.length,e=0,f=0,g=0;0<=g&&g<c&&e<d;g++){for(var h;Float.isNaN(h=JU.ParserJS.parseFloat(a[e++]))&&e<d;);Float.isNaN(h)||(b[f=g]=h);if(e==d)break}return f+1},"~A,~A");c$.parseFloatArrayNext=$_M(c$,"parseFloatArrayNext",function(a,b,c,d,e){var f=0,g=b[0];0<=g&&(null!=d&&(f=a.indexOf(d,g),0<=f&&(b[0]=f+d.length)),a=a.substring(b[0]),g=null==e?-1:a.indexOf(e),0>g?g=a.length:a=a.substring(0,g),b[0]+=g+1,a=JU.ParserJS.getTokens(a),null==
c&&(c=Clazz.newFloatArray(a.length,0)),f=JU.ParserJS.parseFloatArrayInfested(a,c));if(null==c)return Clazz.newFloatArray(0,0);for(a=f;a<c.length;a++)c[a]=NaN;return c},"~S,~A,~A,~S,~S");c$.parseFloatRange=$_M(c$,"parseFloatRange",function(a,b,c){var d=a.length;b>d&&(b=d);return 0>c[0]||c[0]>=b?NaN:JU.ParserJS.parseFloatChecked(a,b,c,!1)},"~S,~N,~A");c$.parseFloatNext=$_M(c$,"parseFloatNext",function(a,b){var c=null==a?-1:a.length;return 0>b[0]||b[0]>=c?NaN:JU.ParserJS.parseFloatChecked(a,c,b,!1)},
"~S,~A");c$.parseFloatStrict=$_M(c$,"parseFloatStrict",function(a){var b=a.length;return 0==b?NaN:JU.ParserJS.parseFloatChecked(a,b,[0],!0)},"~S");c$.parseFloat=$_M(c$,"parseFloat",function(a){return JU.ParserJS.parseFloatNext(a,[0])},"~S");c$.parseIntRadix=$_M(c$,"parseIntRadix",function(a,b){return Integer.parseIntRadix(a,b)},"~S,~N");c$.getTokens=$_M(c$,"getTokens",function(a){return JU.ParserJS.getTokensAt(a,0)},"~S");c$.parseToken=$_M(c$,"parseToken",function(a){return JU.ParserJS.parseTokenNext(a,
[0])},"~S");c$.parseTrimmed=$_M(c$,"parseTrimmed",function(a){return JU.ParserJS.parseTrimmedRange(a,0,a.length)},"~S");c$.parseTrimmedAt=$_M(c$,"parseTrimmedAt",function(a,b){return JU.ParserJS.parseTrimmedRange(a,b,a.length)},"~S,~N");c$.parseTrimmedRange=$_M(c$,"parseTrimmedRange",function(a,b,c){var d=a.length;c<d&&(d=c);return d<b?"":JU.ParserJS.parseTrimmedChecked(a,b,d)},"~S,~N,~N");c$.getTokensAt=$_M(c$,"getTokensAt",function(a,b){if(null==a)return null;var c=a.length;if(0>b||b>c)return null;
var d=JU.ParserJS.countTokens(a,b),e=Array(d),f=Clazz.newIntArray(1,0);f[0]=b;for(var g=0;g<d;++g)e[g]=JU.ParserJS.parseTokenChecked(a,c,f);return e},"~S,~N");c$.countTokens=$_M(c$,"countTokens",function(a,b){var c=0;if(null!=a)for(var d=a.length;;){for(;b<d&&JU.ParserJS.isWhiteSpace(a,b);)++b;if(b==d)break;++c;do++b;while(b<d&&!JU.ParserJS.isWhiteSpace(a,b))}return c},"~S,~N");c$.parseTokenNext=$_M(c$,"parseTokenNext",function(a,b){var c=a.length;return 0>b[0]||b[0]>=c?null:JU.ParserJS.parseTokenChecked(a,
c,b)},"~S,~A");c$.parseTokenRange=$_M(c$,"parseTokenRange",function(a,b,c){var d=a.length;b>d&&(b=d);return 0>c[0]||c[0]>=b?null:JU.ParserJS.parseTokenChecked(a,b,c)},"~S,~N,~A");c$.parseTokenChecked=$_M(c$,"parseTokenChecked",function(a,b,c){for(var d=c[0];d<b&&JU.ParserJS.isWhiteSpace(a,d);)++d;for(var e=d;d<b&&!JU.ParserJS.isWhiteSpace(a,d);)++d;c[0]=d;return e==d?null:a.substring(e,d)},"~S,~N,~A");c$.parseTrimmedChecked=$_M(c$,"parseTrimmedChecked",function(a,b,c){for(;b<c&&JU.ParserJS.isWhiteSpace(a,
b);)++b;for(c-=1;c>=b&&JU.ParserJS.isWhiteSpace(a,c);)--c;return c<b?"":a.substring(b,c+1)},"~S,~N,~N");c$.dVal=$_M(c$,"dVal",function(a){if(null==a)throw new NumberFormatException("null");var b=parseFloat(a);if(isNaN(b))throw new NumberFormatException("Not a Number : "+a);return b},"~S");c$.fVal=$_M(c$,"fVal",function(a){return this.dVal(a)},"~S");c$.parseIntRange=$_M(c$,"parseIntRange",function(a,b,c){var d=a.length;b>d&&(b=d);return 0>c[0]||c[0]>=b?-2147483648:JU.ParserJS.parseIntChecked(a,b,c)},
"~S,~N,~A");c$.parseFloatArrayData=$_M(c$,"parseFloatArrayData",function(a,b){JU.ParserJS.parseFloatArrayDataN(a,b,b.length)},"~A,~A");c$.parseFloatArrayDataN=$_M(c$,"parseFloatArrayDataN",function(a,b,c){for(;0<=--c;)b[c]=c>=a.length?NaN:JU.ParserJS.parseFloat(a[c])},"~A,~A,~N");Clazz.defineStatics(c$,"tensScale",[10,100,1E3,1E4,1E5,1E6],"decimalScale",[0.1,0.01,0.001,1E-4,1E-5,1E-6,1E-7,1E-8,1E-9])}),Clazz.declarePackage("JU"),Clazz.load(null,"JU.ArrayUtil",["java.util.Arrays","JU.List"],function(){c$=
Clazz.declareType(JU,"ArrayUtil");c$.ensureLength=$_M(c$,"ensureLength",function(a,b){return null!=a&&JU.ArrayUtil.getLength(a)>=b?a:JU.ArrayUtil.arrayCopyObject(a,b)},"~O,~N");c$.ensureLengthS=$_M(c$,"ensureLengthS",function(a,b){return null!=a&&a.length>=b?a:JU.ArrayUtil.arrayCopyS(a,b)},"~A,~N");c$.ensureLengthA=$_M(c$,"ensureLengthA",function(a,b){return null!=a&&a.length>=b?a:JU.ArrayUtil.arrayCopyF(a,b)},"~A,~N");c$.ensureLengthI=$_M(c$,"ensureLengthI",function(a,b){return null!=a&&a.length>=
b?a:JU.ArrayUtil.arrayCopyI(a,b)},"~A,~N");c$.ensureLengthShort=$_M(c$,"ensureLengthShort",function(a,b){return null!=a&&a.length>=b?a:JU.ArrayUtil.arrayCopyShort(a,b)},"~A,~N");c$.ensureLengthByte=$_M(c$,"ensureLengthByte",function(a,b){return null!=a&&a.length>=b?a:JU.ArrayUtil.arrayCopyByte(a,b)},"~A,~N");c$.doubleLength=$_M(c$,"doubleLength",function(a){return JU.ArrayUtil.arrayCopyObject(a,null==a?16:2*JU.ArrayUtil.getLength(a))},"~O");c$.doubleLengthS=$_M(c$,"doubleLengthS",function(a){return JU.ArrayUtil.arrayCopyS(a,
null==a?16:2*a.length)},"~A");c$.doubleLengthF=$_M(c$,"doubleLengthF",function(a){return JU.ArrayUtil.arrayCopyF(a,null==a?16:2*a.length)},"~A");c$.doubleLengthI=$_M(c$,"doubleLengthI",function(a){return JU.ArrayUtil.arrayCopyI(a,null==a?16:2*a.length)},"~A");c$.doubleLengthShort=$_M(c$,"doubleLengthShort",function(a){return JU.ArrayUtil.arrayCopyShort(a,null==a?16:2*a.length)},"~A");c$.doubleLengthByte=$_M(c$,"doubleLengthByte",function(a){return JU.ArrayUtil.arrayCopyByte(a,null==a?16:2*a.length)},
"~A");c$.doubleLengthBool=$_M(c$,"doubleLengthBool",function(a){return JU.ArrayUtil.arrayCopyBool(a,null==a?16:2*a.length)},"~A");c$.deleteElements=$_M(c$,"deleteElements",function(a,b,c){if(0==c||null==a)return a;var d=JU.ArrayUtil.getLength(a);if(b>=d)return a;d-=b+c;0>d&&(d=0);var e=JU.ArrayUtil.newInstanceO(a,b+d);0<b&&System.arraycopy(a,0,e,0,b);0<d&&System.arraycopy(a,b+c,e,b,d);return e},"~O,~N,~N");c$.arrayCopyObject=$_M(c$,"arrayCopyObject",function(a,b){if(null==a)return null;var c=JU.ArrayUtil.getLength(a);
if(b==c)return a;var d=JU.ArrayUtil.newInstanceO(a,b);System.arraycopy(a,0,d,0,c<b?c:b);return d},"~O,~N");c$.newInstanceO=$_M(c$,"newInstanceO",($fz=function(a,b){return Array(b)},$fz.isPrivate=!0,$fz),"~O,~N");c$.getLength=$_M(c$,"getLength",($fz=function(a){return a.length},$fz.isPrivate=!0,$fz),"~O");c$.arrayCopyS=$_M(c$,"arrayCopyS",function(a,b){0>b&&(b=a.length);var c=Array(b);if(null!=a){var d=a.length;System.arraycopy(a,0,c,0,d<b?d:b)}return c},"~A,~N");c$.arrayCopyII=$_M(c$,"arrayCopyII",
function(a,b){var c=JU.ArrayUtil.newInt2(b);if(null!=a){var d=a.length;System.arraycopy(a,0,c,0,d<b?d:b)}return c},"~A,~N");c$.arrayCopyPt=$_M(c$,"arrayCopyPt",function(a,b){0>b&&(b=a.length);var c=Array(b);if(null!=a){var d=a.length;System.arraycopy(a,0,c,0,d<b?d:b)}return c},"~A,~N");c$.arrayCopyF=$_M(c$,"arrayCopyF",function(a,b){0>b&&(b=a.length);var c=Clazz.newFloatArray(b,0);if(null!=a){var d=a.length;System.arraycopy(a,0,c,0,d<b?d:b)}return c},"~A,~N");c$.arrayCopyI=$_M(c$,"arrayCopyI",function(a,
b){0>b&&(b=a.length);var c=Clazz.newIntArray(b,0);if(null!=a){var d=a.length;System.arraycopy(a,0,c,0,d<b?d:b)}return c},"~A,~N");c$.arrayCopyRangeI=$_M(c$,"arrayCopyRangeI",function(a,b,c){if(null==a)return null;var d=a.length;-1==c&&(c=d);-2==c&&(c=Clazz.doubleToInt(d/2));c-=b;d=Clazz.newIntArray(c,0);System.arraycopy(a,b,d,0,c);return d},"~A,~N,~N");c$.arrayCopyRangeRevI=$_M(c$,"arrayCopyRangeRevI",function(a,b,c){if(null==a)return null;b=JU.ArrayUtil.arrayCopyRangeI(a,b,c);0>c&&(c=a.length);for(a=
Clazz.doubleToInt(c/2);0<=--a;)JU.ArrayUtil.swapInt(b,a,c-1-a);return b},"~A,~N,~N");c$.arrayCopyShort=$_M(c$,"arrayCopyShort",function(a,b){0>b&&(b=a.length);var c=Clazz.newShortArray(b,0);if(null!=a){var d=a.length;System.arraycopy(a,0,c,0,d<b?d:b)}return c},"~A,~N");c$.arrayCopyByte=$_M(c$,"arrayCopyByte",function(a,b){0>b&&(b=a.length);var c=Clazz.newByteArray(b,0);if(null!=a){var d=a.length;System.arraycopy(a,0,c,0,d<b?d:b)}return c},"~A,~N");c$.arrayCopyBool=$_M(c$,"arrayCopyBool",function(a,
b){0>b&&(b=a.length);var c=Clazz.newBooleanArray(b,!1);if(null!=a){var d=a.length;System.arraycopy(a,0,c,0,d<b?d:b)}return c},"~A,~N");c$.swapInt=$_M(c$,"swapInt",function(a,b,c){var d=a[b];a[b]=a[c];a[c]=d},"~A,~N,~N");c$.dumpArray=$_M(c$,"dumpArray",function(a,b,c,d,e,f){a="dumpArray: "+a+"\n";for(var g=c;g<=d;g++)a+="\t*"+g+"*";for(;f>=e;f--){a+="\n*"+f+"*";for(g=c;g<=d;g++)a+="\t"+(g<b.length&&f<b[g].length?b[g][f]:NaN)}return a},"~S,~A,~N,~N,~N,~N");c$.dumpIntArray=$_M(c$,"dumpIntArray",function(a,
b){for(var c="",d=0;d<b;d++)c+=" "+a[d];return c},"~A,~N");c$.sortedItem=$_M(c$,"sortedItem",function(a,b){if(0==a.size())return null;if(1==a.size())return a.get(0);var c=a.toArray(Array(a.size()));java.util.Arrays.sort(c);return c[b%c.length]},"JU.List,~N");c$.createArrayOfArrayList=$_M(c$,"createArrayOfArrayList",function(a){return Array(a)},"~N");c$.createArrayOfHashtable=$_M(c$,"createArrayOfHashtable",function(a){return Array(a)},"~N");c$.swap=$_M(c$,"swap",function(a,b,c){var d=a[b];a[b]=a[c];
a[c]=d},"~A,~N,~N");c$.newFloat2=$_M(c$,"newFloat2",function(a){return Clazz.newArray(a,null)},"~N");c$.newInt2=$_M(c$,"newInt2",function(a){return Clazz.newArray(a,null)},"~N");c$.newInt3=$_M(c$,"newInt3",function(a){return Clazz.newArray(a,null)},"~N,~N");c$.newFloat3=$_M(c$,"newFloat3",function(a){return Clazz.newArray(a,null)},"~N,~N");c$.newInt4=$_M(c$,"newInt4",function(a){return Clazz.newArray(a,null)},"~N");c$.newShort2=$_M(c$,"newShort2",function(a){return Clazz.newArray(a,null)},"~N");c$.newByte2=
$_M(c$,"newByte2",function(a){return Clazz.newArray(a,null)},"~N");c$.newDouble2=$_M(c$,"newDouble2",function(a){return Clazz.newArray(a,null)},"~N");c$.removeMapKeys=$_M(c$,"removeMapKeys",function(a,b){for(var c=new JU.List,d,e=a.keySet().iterator();e.hasNext()&&((d=e.next())||1);)d.startsWith(b)&&c.addLast(d);for(d=c.size();0<=--d;)a.remove(c.get(d));return c.size()},"java.util.Map,~S")}),$_L(["java.util.Map"],"java.util.MapEntry",null,function(){c$=$_C(function(){this.value=this.key=null;$_Z(this,
arguments)},java.util,"MapEntry",null,[java.util.Map.Entry,Cloneable]);$_K(c$,function(a){this.key=a},"~O");$_K(c$,function(a,b){this.key=a;this.value=b},"~O,~O");$_M(c$,"clone",function(){try{return $_U(this,java.util.MapEntry,"clone",[])}catch(a){if($_O(a,CloneNotSupportedException))return null;throw a;}});$_V(c$,"equals",function(a){return this===a?!0:$_O(a,java.util.Map.Entry)?(null==this.key?null==a.getKey():this.key.equals(a.getKey()))&&(null==this.value?null==a.getValue():this.value.equals(a.getValue())):
!1},"~O");$_V(c$,"getKey",function(){return this.key});$_V(c$,"getValue",function(){return this.value});$_V(c$,"hashCode",function(){return(null==this.key?0:this.key.hashCode())^(null==this.value?0:this.value.hashCode())});$_V(c$,"setValue",function(a){var b=this.value;this.value=a;return b},"~O");$_V(c$,"toString",function(){return this.key+"="+this.value});$_I(java.util.MapEntry,"Type")}),c$=$_T(java.util,"Dictionary"),$_K(c$,function(){}),$_L(["java.util.Collection"],"java.util.AbstractCollection",
["java.lang.StringBuilder","$.UnsupportedOperationException","java.lang.reflect.Array"],function(){c$=$_T(java.util,"AbstractCollection",null,java.util.Collection);$_K(c$,function(){});$_V(c$,"add",function(){throw new UnsupportedOperationException;},"~O");$_V(c$,"addAll",function(a){var b=!1;for(a=a.iterator();a.hasNext();)this.add(a.next())&&(b=!0);return b},"java.util.Collection");$_V(c$,"clear",function(){for(var a=this.iterator();a.hasNext();)a.next(),a.remove()});$_V(c$,"contains",function(a){var b=
this.iterator();if(null!=a)for(;b.hasNext();){if(a.equals(b.next()))return!0}else for(;b.hasNext();)if(null==b.next())return!0;return!1},"~O");$_V(c$,"containsAll",function(a){for(a=a.iterator();a.hasNext();)if(!this.contains(a.next()))return!1;return!0},"java.util.Collection");$_V(c$,"isEmpty",function(){return 0==this.size()});$_V(c$,"remove",function(a){var b=this.iterator();if(null!=a)for(;b.hasNext();){if(a.equals(b.next()))return b.remove(),!0}else for(;b.hasNext();)if(null==b.next())return b.remove(),
!0;return!1},"~O");$_V(c$,"removeAll",function(a){for(var b=!1,c=this.iterator();c.hasNext();)a.contains(c.next())&&(c.remove(),b=!0);return b},"java.util.Collection");$_V(c$,"retainAll",function(a){for(var b=!1,c=this.iterator();c.hasNext();)a.contains(c.next())||(c.remove(),b=!0);return b},"java.util.Collection");$_M(c$,"toArray",function(){for(var a=this.size(),b=0,c=this.iterator(),d=Array(a);b<a;)d[b++]=c.next();return d});$_M(c$,"toArray",function(a){var b=this.size(),c=0;b>a.length&&(a=a.getClass().getComponentType(),
a=java.lang.reflect.Array.newInstance(a,b));for(var d,b=this.iterator();b.hasNext()&&((d=b.next())||1);)a[c++]=d;c<a.length&&(a[c]=null);return a},"~A");$_V(c$,"toString",function(){if(this.isEmpty())return"[]";var a=new StringBuilder(16*this.size());a.append("[");for(var b=this.iterator();b.hasNext();){var c=b.next();c!==this?a.append(c):a.append("(this Collection)");b.hasNext()&&a.append(", ")}a.append("]");return a.toString()})}),$_L(null,"java.lang.AbstractStringBuilder","java.io.InvalidObjectException java.lang.ArrayIndexOutOfBoundsException $.IndexOutOfBoundsException $.NegativeArraySizeException $.NullPointerException $.StringIndexOutOfBoundsException".split(" "),
function(){c$=$_C(function(){this.value=null;this.count=0;this.shared=!1;$_Z(this,arguments)},java.lang,"AbstractStringBuilder");$_M(c$,"getValue",function(){return this.value});$_M(c$,"shareValue",function(){this.shared=!0;return this.value});$_M(c$,"set",function(a,b){null==a&&(a=$_A(0,"\x00"));if(a.length<b)throw new java.io.InvalidObjectException("K0199");this.shared=!1;this.value=a;this.count=b},"~A,~N");$_K(c$,function(){this.value=$_A(16,"\x00")});$_K(c$,function(a){if(0>a)throw new NegativeArraySizeException;
this.value=$_A(a,"\x00")},"~N");$_K(c$,function(a){this.count=a.length;this.shared=!1;this.value=$_A(this.count+16,"\x00");a.getChars(0,this.count,this.value,0)},"~S");$_M(c$,"enlargeBuffer",($fz=function(a){var b=(this.value.length<<1)+2;a=$_A(a>b?a:b,"\x00");System.arraycopy(this.value,0,a,0,this.count);this.value=a;this.shared=!1},$fz.isPrivate=!0,$fz),"~N");$_M(c$,"appendNull",function(){var a=this.count+4;a>this.value.length?this.enlargeBuffer(a):this.shared&&(this.value=this.value.clone(),this.shared=
!1);this.value[this.count++]="n";this.value[this.count++]="u";this.value[this.count++]="l";this.value[this.count++]="l"});$_M(c$,"append0",function(a){var b=this.count+a.length;b>this.value.length?this.enlargeBuffer(b):this.shared&&(this.value=this.value.clone(),this.shared=!1);System.arraycopy(a,0,this.value,this.count,a.length);this.count=b},"~A");$_M(c$,"append0",function(a,b,c){if(null==a)throw new NullPointerException;if(0<=b&&0<=c&&c<=a.length-b){var d=this.count+c;d>this.value.length?this.enlargeBuffer(d):
this.shared&&(this.value=this.value.clone(),this.shared=!1);System.arraycopy(a,b,this.value,this.count,c);this.count=d}else throw new ArrayIndexOutOfBoundsException;},"~A,~N,~N");$_M(c$,"append0",function(a){this.count==this.value.length&&this.enlargeBuffer(this.count+1);this.shared&&(this.value=this.value.clone(),this.shared=!1);this.value[this.count++]=a},"~N");$_M(c$,"append0",function(a){if(null==a)this.appendNull();else{var b=a.length,c=this.count+b;c>this.value.length?this.enlargeBuffer(c):
this.shared&&(this.value=this.value.clone(),this.shared=!1);a.getChars(0,b,this.value,this.count);this.count=c}},"~S");$_M(c$,"append0",function(a,b,c){null==a&&(a="null");if(0>b||0>c||b>c||c>a.length())throw new IndexOutOfBoundsException;this.append0(a.subSequence(b,c).toString())},"CharSequence,~N,~N");$_M(c$,"capacity",function(){return this.value.length});$_M(c$,"charAt",function(a){if(0>a||a>=this.count)throw new StringIndexOutOfBoundsException(a);return this.value[a]},"~N");$_M(c$,"delete0",
function(a,b){if(0<=a){b>this.count&&(b=this.count);if(b==a)return;if(b>a){var c=this.count-b;if(0<c)if(this.shared){var d=$_A(this.value.length,"\x00");System.arraycopy(this.value,0,d,0,a);System.arraycopy(this.value,b,d,a,c);this.value=d;this.shared=!1}else System.arraycopy(this.value,b,this.value,a,c);this.count-=b-a;return}}throw new StringIndexOutOfBoundsException;},"~N,~N");$_M(c$,"deleteCharAt0",function(a){if(0>a||a>=this.count)throw new StringIndexOutOfBoundsException(a);var b=this.count-
a-1;if(0<b)if(this.shared){var c=$_A(this.value.length,"\x00");System.arraycopy(this.value,0,c,0,a);System.arraycopy(this.value,a+1,c,a,b);this.value=c;this.shared=!1}else System.arraycopy(this.value,a+1,this.value,a,b);this.count--},"~N");$_M(c$,"ensureCapacity",function(a){a>this.value.length&&this.enlargeBuffer(a)},"~N");$_M(c$,"getChars",function(a,b,c,d){if(a>this.count||b>this.count||a>b)throw new StringIndexOutOfBoundsException;System.arraycopy(this.value,a,c,d,b-a)},"~N,~N,~A,~N");$_M(c$,
"insert0",function(a,b){if(0>a||a>this.count)throw new StringIndexOutOfBoundsException(a);0!=b.length&&(this.move(b.length,a),System.arraycopy(b,0,this.value,a,b.length),this.count+=b.length)},"~N,~A");$_M(c$,"insert0",function(a,b,c,d){if(0<=a&&a<=this.count){if(0<=c&&0<=d&&d<=b.length-c){0!=d&&(this.move(d,a),System.arraycopy(b,c,this.value,a,d),this.count+=d);return}throw new StringIndexOutOfBoundsException("offset "+c+", len "+d+", array.length "+b.length);}throw new StringIndexOutOfBoundsException(a);
},"~N,~A,~N,~N");$_M(c$,"insert0",function(a,b){if(0>a||a>this.count)throw new ArrayIndexOutOfBoundsException(a);this.move(1,a);this.value[a]=b;this.count++},"~N,~N");$_M(c$,"insert0",function(a,b){if(0<=a&&a<=this.count){null==b&&(b="null");var c=b.length;0!=c&&(this.move(c,a),b.getChars(0,c,this.value,a),this.count+=c)}else throw new StringIndexOutOfBoundsException(a);},"~N,~S");$_M(c$,"insert0",function(a,b,c,d){null==b&&(b="null");if(0>a||a>this.count||0>c||0>d||c>d||d>b.length())throw new IndexOutOfBoundsException;
this.insert0(a,b.subSequence(c,d).toString())},"~N,CharSequence,~N,~N");$_M(c$,"length",function(){return this.count});$_M(c$,"move",($fz=function(a,b){var c;if(this.value.length-this.count>=a){if(!this.shared){System.arraycopy(this.value,b,this.value,b+a,this.count-b);return}c=this.value.length}else{c=this.count+a;var d=(this.value.length<<1)+2;c=c>d?c:d}c=$_A(c,"\x00");System.arraycopy(this.value,0,c,0,b);System.arraycopy(this.value,b,c,b+a,this.count-b);this.value=c;this.shared=!1},$fz.isPrivate=
!0,$fz),"~N,~N");$_M(c$,"replace0",function(a,b,c){if(0<=a){b>this.count&&(b=this.count);if(b>a){var d=c.length,e=b-a-d;if(0<e)if(this.shared){var f=$_A(this.value.length,"\x00");System.arraycopy(this.value,0,f,0,a);System.arraycopy(this.value,b,f,a+d,this.count-b);this.value=f;this.shared=!1}else System.arraycopy(this.value,b,this.value,a+d,this.count-b);else 0>e?this.move(-e,b):this.shared&&(this.value=this.value.clone(),this.shared=!1);c.getChars(0,d,this.value,a);this.count-=e;return}if(a==b){if(null==
c)throw new NullPointerException;this.insert0(a,c);return}}throw new StringIndexOutOfBoundsException;},"~N,~N,~S");$_M(c$,"reverse0",function(){if(!(2>this.count))if(this.shared){for(var a=$_A(this.value.length,"\x00"),b=0,c=this.count;b<this.count;b++)a[--c]=this.value[b];this.value=a;this.shared=!1}else for(var b=0,c=this.count,a=Math.floor(this.count/2);b<a;b++){var d=this.value[--c];this.value[c]=this.value[b];this.value[b]=d}});$_M(c$,"setCharAt",function(a,b){if(0>a||a>=this.count)throw new StringIndexOutOfBoundsException(a);
this.shared&&(this.value=this.value.clone(),this.shared=!1);this.value[a]=b},"~N,~N");$_M(c$,"setLength",function(a){if(0>a)throw new StringIndexOutOfBoundsException(a);if(this.count<a)if(a>this.value.length)this.enlargeBuffer(a);else if(this.shared){var b=$_A(this.value.length,"\x00");System.arraycopy(this.value,0,b,0,this.count);this.value=b;this.shared=!1}else for(b=this.count;b<a;b++)this.value[b]=String.fromCharCode(0);this.count=a},"~N");$_M(c$,"substring",function(a){if(0<=a&&a<=this.count){if(a==
this.count)return"";this.shared=!0;return String.instantialize(a,this.count-a,this.value)}throw new StringIndexOutOfBoundsException(a);},"~N");$_M(c$,"substring",function(a,b){if(0<=a&&a<=b&&b<=this.count){if(a==b)return"";this.shared=!0;return String.instantialize(this.value,a,b-a)}throw new StringIndexOutOfBoundsException;},"~N,~N");$_V(c$,"toString",function(){if(0==this.count)return"";if(256<=this.count&&this.count<=this.value.length>>1)return String.instantialize(this.value,0,this.count);this.shared=
!0;return String.instantialize(0,this.count,this.value)});$_M(c$,"subSequence",function(a,b){return this.substring(a,b)},"~N,~N");$_M(c$,"indexOf",function(a){return this.indexOf(a,0)},"~S");$_M(c$,"indexOf",function(a,b){0>b&&(b=0);var c=a.length;if(0<c){if(c+b>this.count)return-1;for(var d=a.charAt(0);;){for(var e=b,f=!1;e<this.count;e++)if(this.value[e].charCodeAt(0)==d.charCodeAt(0)){f=!0;break}if(!f||c+e>this.count)return-1;for(var f=e,g=0;++g<c&&this.value[++f].charCodeAt(0)==a.charAt(g).charCodeAt(0););
if(g==c)return e;b=e+1}}return b<this.count||0==b?b:this.count},"~S,~N");$_M(c$,"lastIndexOf",function(a){return this.lastIndexOf(a,this.count)},"~S");$_M(c$,"lastIndexOf",function(a,b){var c=a.length;if(c<=this.count&&0<=b){if(0<c){b>this.count-c&&(b=this.count-c);for(var d=a.charAt(0);;){for(var e=b,f=!1;0<=e;--e)if(this.value[e].charCodeAt(0)==d.charCodeAt(0)){f=!0;break}if(!f)return-1;for(var f=e,g=0;++g<c&&this.value[++f].charCodeAt(0)==a.charAt(g).charCodeAt(0););if(g==c)return e;b=e-1}}return b<
this.count?b:this.count}return-1},"~S,~N");$_M(c$,"trimToSize",function(){if(this.count<this.value.length){var a=$_A(this.count,"\x00");System.arraycopy(this.value,0,a,0,this.count);this.value=a;this.shared=!1}});$_S(c$,"INITIAL_CAPACITY",16)}),$_L(["java.lang.AbstractStringBuilder","$.Appendable"],"java.lang.StringBuilder",["java.lang.Double","$.Float","$.Long"],function(){c$=$_T(java.lang,"StringBuilder",AbstractStringBuilder,[Appendable,CharSequence,java.io.Serializable]);$_K(c$,function(a){$_R(this,
StringBuilder,[a.toString()])},"CharSequence");$_M(c$,"append",function(a){this.append0(a?"true":"false");return this},"~B");$_M(c$,"append",function(a){this.append0(a);return this},"~N");$_M(c$,"append",function(a){this.append0(Integer.toString(a));return this},"~N");$_M(c$,"append",function(a){this.append0(Long.toString(a));return this},"~N");$_M(c$,"append",function(a){this.append0(Float.toString(a));return this},"~N");$_M(c$,"append",function(a){this.append0(Double.toString(a));return this},"~N");
$_M(c$,"append",function(a){null==a?this.appendNull():this.append0(a.toString());return this},"~O");$_M(c$,"append",function(a){this.append0(a);return this},"~S");$_M(c$,"append",function(a){null==a?this.appendNull():this.append0(a.getValue(),0,a.length());return this},"StringBuffer");$_M(c$,"append",function(a){this.append0(a);return this},"~A");$_M(c$,"append",function(a,b,c){this.append0(a,b,c);return this},"~A,~N,~N");$_M(c$,"append",function(a){null==a?this.appendNull():this.append0(a.toString());
return this},"CharSequence");$_M(c$,"append",function(a,b,c){this.append0(a,b,c);return this},"CharSequence,~N,~N");$_M(c$,"$delete",function(a,b){this.delete0(a,b);return this},"~N,~N");$_M(c$,"deleteCharAt",function(a){this.deleteCharAt0(a);return this},"~N");$_M(c$,"insert",function(a,b){this.insert0(a,b?"true":"false");return this},"~N,~B");$_M(c$,"insert",function(a,b){this.insert0(a,b);return this},"~N,~N");$_M(c$,"insert",function(a,b){this.insert0(a,Integer.toString(b));return this},"~N,~N");
$_M(c$,"insert",function(a,b){this.insert0(a,Long.toString(b));return this},"~N,~N");$_M(c$,"insert",function(a,b){this.insert0(a,Float.toString(b));return this},"~N,~N");$_M(c$,"insert",function(a,b){this.insert0(a,Double.toString(b));return this},"~N,~N");$_M(c$,"insert",function(a,b){this.insert0(a,null==b?"null":b.toString());return this},"~N,~O");$_M(c$,"insert",function(a,b){this.insert0(a,b);return this},"~N,~S");$_M(c$,"insert",function(a,b){this.insert0(a,b);return this},"~N,~A");$_M(c$,
"insert",function(a,b,c,d){this.insert0(a,b,c,d);return this},"~N,~A,~N,~N");$_M(c$,"insert",function(a,b){this.insert0(a,null==b?"null":b.toString());return this},"~N,CharSequence");$_M(c$,"insert",function(a,b,c,d){this.insert0(a,b,c,d);return this},"~N,CharSequence,~N,~N");$_M(c$,"replace",function(a,b,c){this.replace0(a,b,c);return this},"~N,~N,~S");$_M(c$,"reverse",function(){this.reverse0();return this})}),$_L(["java.lang.AbstractStringBuilder","$.Appendable"],"java.lang.StringBuffer",["java.lang.Character",
"$.Double","$.Float","$.Long"],function(){c$=$_T(java.lang,"StringBuffer",AbstractStringBuilder,[Appendable,java.io.Serializable,CharSequence]);$_K(c$,function(a){if(null==a)throw new NullPointerException;$_R(this,StringBuffer,[a.toString()])},"CharSequence");$_M(c$,"append",function(a){return this.append(a?"true":"false")},"~B");$_M(c$,"append",function(a){this.append0(a);return this},"~N");$_M(c$,"append",function(a){return this.append(Double.toString(a))},"~N");$_M(c$,"append",function(a){null==
a?this.appendNull():this.append0(a.toString());return this},"~O");$_M(c$,"append",function(a){this.append0(a);return this},"~S");$_M(c$,"append",function(a){null==a?this.appendNull():this.append0(a.getValue(),0,a.length());return this},"StringBuffer");$_M(c$,"append",function(a){this.append0(a);return this},"~A");$_M(c$,"append",function(a,b,c){this.append0(a,b,c);return this},"~A,~N,~N");$_M(c$,"append",function(a){null==a?this.appendNull():this.append0(a.toString());return this},"CharSequence");
$_M(c$,"append",function(a,b,c){this.append0(a,b,c);return this},"CharSequence,~N,~N");$_M(c$,"appendCodePoint",function(a){return this.append(Character.toChars(a))},"~N");$_M(c$,"$delete",function(a,b){this.delete0(a,b);return this},"~N,~N");$_M(c$,"deleteCharAt",function(a){this.deleteCharAt0(a);return this},"~N");$_M(c$,"insert",function(a,b){this.insert0(a,b);return this},"~N,~N");$_M(c$,"insert",function(a,b){return this.insert(a,b?"true":"false")},"~N,~B");$_M(c$,"insert",function(a,b){return this.insert(a,
Integer.toString(b))},"~N,~N");$_M(c$,"insert",function(a,b){return this.insert(a,Long.toString(b))},"~N,~N");$_M(c$,"insert",function(a,b){return this.insert(a,Double.toString(b))},"~N,~N");$_M(c$,"insert",function(a,b){return this.insert(a,Float.toString(b))},"~N,~N");$_M(c$,"insert",function(a,b){return this.insert(a,null==b?"null":b.toString())},"~N,~O");$_M(c$,"insert",function(a,b){this.insert0(a,b);return this},"~N,~S");$_M(c$,"insert",function(a,b){this.insert0(a,b);return this},"~N,~A");
$_M(c$,"insert",function(a,b,c,d){this.insert0(a,b,c,d);return this},"~N,~A,~N,~N");$_M(c$,"insert",function(a,b){this.insert0(a,null==b?"null":b.toString());return this},"~N,CharSequence");$_M(c$,"insert",function(a,b,c,d){this.insert0(a,b,c,d);return this},"~N,CharSequence,~N,~N");$_M(c$,"replace",function(a,b,c){this.replace0(a,b,c);return this},"~N,~N,~S");$_M(c$,"reverse",function(){this.reverse0();return this});$_V(c$,"subSequence",function(a,b){return $_U(this,StringBuffer,"substring",[a,b])},
"~N,~N")}),$_L("java.util.AbstractCollection $.Iterator $.List $.ListIterator $.RandomAccess $.NoSuchElementException".split(" "),"java.util.AbstractList",["java.lang.IllegalArgumentException","$.IllegalStateException","$.IndexOutOfBoundsException","$.UnsupportedOperationException","java.util.ConcurrentModificationException"],function(){c$=$_C(function(){this.modCount=0;$_D("java.util.AbstractList.SimpleListIterator")||java.util.AbstractList.$AbstractList$SimpleListIterator$();$_D("java.util.AbstractList.FullListIterator")||
java.util.AbstractList.$AbstractList$FullListIterator$();$_Z(this,arguments)},java.util,"AbstractList",java.util.AbstractCollection,java.util.List);$_M(c$,"add",function(){throw new UnsupportedOperationException;},"~N,~O");$_M(c$,"add",function(a){this.add(this.size(),a);return!0},"~O");$_M(c$,"addAll",function(a,b){for(var c=b.iterator();c.hasNext();)this.add(a++,c.next());return!b.isEmpty()},"~N,java.util.Collection");$_V(c$,"clear",function(){this.removeRange(0,this.size())});$_V(c$,"equals",function(a){if(this===
a)return!0;if($_O(a,java.util.List)){if(a.size()!=this.size())return!1;var b=this.iterator();for(a=a.iterator();b.hasNext();){var c=b.next(),d=a.next();if(!(null==c?null==d:c.equals(d)))return!1}return!0}return!1},"~O");$_V(c$,"hashCode",function(){for(var a=1,b=this.iterator();b.hasNext();)var c=b.next(),a=31*a+(null==c?0:c.hashCode());return a});$_V(c$,"indexOf",function(a){var b=this.listIterator();if(null!=a)for(;b.hasNext();){if(a.equals(b.next()))return b.previousIndex()}else for(;b.hasNext();)if(null==
b.next())return b.previousIndex();return-1},"~O");$_V(c$,"iterator",function(){return $_N(java.util.AbstractList.SimpleListIterator,this,null)});$_V(c$,"lastIndexOf",function(a){var b=this.listIterator(this.size());if(null!=a)for(;b.hasPrevious();){if(a.equals(b.previous()))return b.nextIndex()}else for(;b.hasPrevious();)if(null==b.previous())return b.nextIndex();return-1},"~O");$_M(c$,"listIterator",function(){return this.listIterator(0)});$_M(c$,"listIterator",function(a){return $_N(java.util.AbstractList.FullListIterator,
this,null,a)},"~N");$_M(c$,"remove",function(){throw new UnsupportedOperationException;},"~N");$_M(c$,"removeRange",function(a,b){for(var c=this.listIterator(a),d=a;d<b;d++)c.next(),c.remove()},"~N,~N");$_V(c$,"set",function(){throw new UnsupportedOperationException;},"~N,~O");$_V(c$,"subList",function(a,b){if(0<=a&&b<=this.size()){if(a<=b)return $_O(this,java.util.RandomAccess)?new java.util.AbstractList.SubAbstractListRandomAccess(this,a,b):new java.util.AbstractList.SubAbstractList(this,a,b);throw new IllegalArgumentException;
}throw new IndexOutOfBoundsException;},"~N,~N");c$.$AbstractList$SimpleListIterator$=function(){$_H();c$=$_C(function(){$_B(this,arguments);this.pos=-1;this.expectedModCount=0;this.lastPosition=-1;$_Z(this,arguments)},java.util.AbstractList,"SimpleListIterator",null,java.util.Iterator);$_K(c$,function(){this.expectedModCount=this.b$["java.util.AbstractList"].modCount});$_V(c$,"hasNext",function(){return this.pos+1<this.b$["java.util.AbstractList"].size()});$_V(c$,"next",function(){if(this.expectedModCount==
this.b$["java.util.AbstractList"].modCount)try{var a=this.b$["java.util.AbstractList"].get(this.pos+1);this.lastPosition=++this.pos;return a}catch(b){if($_O(b,IndexOutOfBoundsException))throw new java.util.NoSuchElementException;throw b;}throw new java.util.ConcurrentModificationException;});$_V(c$,"remove",function(){if(this.expectedModCount==this.b$["java.util.AbstractList"].modCount){try{this.b$["java.util.AbstractList"].remove(this.lastPosition)}catch(a){if($_O(a,IndexOutOfBoundsException))throw new IllegalStateException;
throw a;}this.b$["java.util.AbstractList"].modCount!=this.expectedModCount&&this.expectedModCount++;this.pos==this.lastPosition&&this.pos--;this.lastPosition=-1}else throw new java.util.ConcurrentModificationException;});c$=$_P()};c$.$AbstractList$FullListIterator$=function(){$_H();c$=$_C(function(){$_B(this,arguments);$_Z(this,arguments)},java.util.AbstractList,"FullListIterator",java.util.AbstractList.SimpleListIterator,java.util.ListIterator,$_N(java.util.AbstractList.SimpleListIterator,this,null,
$_G));$_K(c$,function(a){$_R(this,java.util.AbstractList.FullListIterator);if(0<=a&&a<=this.b$["java.util.AbstractList"].size())this.pos=a-1;else throw new IndexOutOfBoundsException;},"~N");$_V(c$,"add",function(a){if(this.expectedModCount==this.b$["java.util.AbstractList"].modCount){try{this.b$["java.util.AbstractList"].add(this.pos+1,a)}catch(b){if($_O(b,IndexOutOfBoundsException))throw new java.util.NoSuchElementException;throw b;}this.pos++;this.lastPosition=-1;this.b$["java.util.AbstractList"].modCount!=
this.expectedModCount&&this.expectedModCount++}else throw new java.util.ConcurrentModificationException;},"~O");$_V(c$,"hasPrevious",function(){return 0<=this.pos});$_V(c$,"nextIndex",function(){return this.pos+1});$_V(c$,"previous",function(){if(this.expectedModCount==this.b$["java.util.AbstractList"].modCount)try{var a=this.b$["java.util.AbstractList"].get(this.pos);this.lastPosition=this.pos;this.pos--;return a}catch(b){if($_O(b,IndexOutOfBoundsException))throw new java.util.NoSuchElementException;
throw b;}throw new java.util.ConcurrentModificationException;});$_V(c$,"previousIndex",function(){return this.pos});$_V(c$,"set",function(a){if(this.expectedModCount==this.b$["java.util.AbstractList"].modCount)try{this.b$["java.util.AbstractList"].set(this.lastPosition,a)}catch(b){if($_O(b,IndexOutOfBoundsException))throw new IllegalStateException;throw b;}else throw new java.util.ConcurrentModificationException;},"~O");c$=$_P()};$_H();c$=$_T(java.util.AbstractList,"SubAbstractListRandomAccess",java.util.AbstractList.SubAbstractList,
java.util.RandomAccess);c$=$_P();$_H();c$=$_C(function(){this.fullList=null;this.$size=this.offset=0;$_Z(this,arguments)},java.util.AbstractList,"SubAbstractList",java.util.AbstractList);$_K(c$,function(a,b,c){$_R(this,java.util.AbstractList.SubAbstractList);this.fullList=a;this.modCount=this.fullList.modCount;this.offset=b;this.$size=c-b},"java.util.AbstractList,~N,~N");$_M(c$,"add",function(a,b){if(this.modCount==this.fullList.modCount)if(0<=a&&a<=this.$size)this.fullList.add(a+this.offset,b),this.$size++,
this.modCount=this.fullList.modCount;else throw new IndexOutOfBoundsException;else throw new java.util.ConcurrentModificationException;},"~N,~O");$_M(c$,"addAll",function(a,b){if(this.modCount==this.fullList.modCount){if(0<=a&&a<=this.$size){var c=this.fullList.addAll(a+this.offset,b);c&&(this.$size+=b.size(),this.modCount=this.fullList.modCount);return c}throw new IndexOutOfBoundsException;}throw new java.util.ConcurrentModificationException;},"~N,java.util.Collection");$_M(c$,"addAll",function(a){if(this.modCount==
this.fullList.modCount){var b=this.fullList.addAll(this.offset+this.$size,a);b&&(this.$size+=a.size(),this.modCount=this.fullList.modCount);return b}throw new java.util.ConcurrentModificationException;},"java.util.Collection");$_M(c$,"get",function(a){if(this.modCount==this.fullList.modCount){if(0<=a&&a<this.$size)return this.fullList.get(a+this.offset);throw new IndexOutOfBoundsException;}throw new java.util.ConcurrentModificationException;},"~N");$_V(c$,"iterator",function(){return this.listIterator(0)});
$_M(c$,"listIterator",function(a){if(this.modCount==this.fullList.modCount){if(0<=a&&a<=this.$size)return new java.util.AbstractList.SubAbstractList.SubAbstractListIterator(this.fullList.listIterator(a+this.offset),this,this.offset,this.$size);throw new IndexOutOfBoundsException;}throw new java.util.ConcurrentModificationException;},"~N");$_M(c$,"remove",function(a){if(this.modCount==this.fullList.modCount){if(0<=a&&a<this.$size)return a=this.fullList.remove(a+this.offset),this.$size--,this.modCount=
this.fullList.modCount,a;throw new IndexOutOfBoundsException;}throw new java.util.ConcurrentModificationException;},"~N");$_M(c$,"removeRange",function(a,b){if(a!=b)if(this.modCount==this.fullList.modCount)this.fullList.removeRange(a+this.offset,b+this.offset),this.$size-=b-a,this.modCount=this.fullList.modCount;else throw new java.util.ConcurrentModificationException;},"~N,~N");$_M(c$,"set",function(a,b){if(this.modCount==this.fullList.modCount){if(0<=a&&a<this.$size)return this.fullList.set(a+this.offset,
b);throw new IndexOutOfBoundsException;}throw new java.util.ConcurrentModificationException;},"~N,~O");$_V(c$,"size",function(){return this.$size});$_M(c$,"sizeChanged",function(a){a?this.$size++:this.$size--;this.modCount=this.fullList.modCount},"~B");$_H();c$=$_C(function(){this.iterator=this.subList=null;this.end=this.start=0;$_Z(this,arguments)},java.util.AbstractList.SubAbstractList,"SubAbstractListIterator",null,java.util.ListIterator);$_K(c$,function(a,b,c,d){this.iterator=a;this.subList=b;
this.start=c;this.end=this.start+d},"java.util.ListIterator,java.util.AbstractList.SubAbstractList,~N,~N");$_M(c$,"add",function(a){this.iterator.add(a);this.subList.sizeChanged(!0);this.end++},"~O");$_V(c$,"hasNext",function(){return this.iterator.nextIndex()<this.end});$_V(c$,"hasPrevious",function(){return this.iterator.previousIndex()>=this.start});$_M(c$,"next",function(){if(this.iterator.nextIndex()<this.end)return this.iterator.next();throw new java.util.NoSuchElementException;});$_M(c$,"nextIndex",
function(){return this.iterator.nextIndex()-this.start});$_M(c$,"previous",function(){if(this.iterator.previousIndex()>=this.start)return this.iterator.previous();throw new java.util.NoSuchElementException;});$_M(c$,"previousIndex",function(){var a=this.iterator.previousIndex();return a>=this.start?a-this.start:-1});$_M(c$,"remove",function(){this.iterator.remove();this.subList.sizeChanged(!1);this.end--});$_M(c$,"set",function(a){this.iterator.set(a)},"~O");c$=$_P();c$=$_P()}),$_L(["java.util.AbstractList",
"$.List","$.RandomAccess"],"java.util.ArrayList",["java.lang.IllegalArgumentException","$.IndexOutOfBoundsException","java.lang.reflect.Array","java.util.Arrays"],function(){c$=$_C(function(){this.lastIndex=this.firstIndex=0;this.array=null;$_Z(this,arguments)},java.util,"ArrayList",java.util.AbstractList,[java.util.List,Cloneable,java.io.Serializable,java.util.RandomAccess]);$_k(c$,function(){this.setup(0)});$_M(c$,"setup",function(a){$_R(this,java.util.ArrayList,[]);this.firstIndex=this.lastIndex=
0;try{this.array=this.newElementArray(a)}catch(b){if($_O(b,NegativeArraySizeException))throw new IllegalArgumentException;throw b;}},"~N");$_M(c$,"newElementArray",($fz=function(a){return Array(a)},$fz.isPrivate=!0,$fz),"~N");$_V(c$,"add",function(a,b){if(1==arguments.length)return this.add1(a);var c=this.size();if(0<a&&a<c){if(0==this.firstIndex&&this.lastIndex==this.array.length)this.growForInsert(a,1);else if(a<Math.floor(c/2)&&0<this.firstIndex||this.lastIndex==this.array.length)System.arraycopy(this.array,
this.firstIndex,this.array,--this.firstIndex,a);else{var d=a+this.firstIndex;System.arraycopy(this.array,d,this.array,d+1,c-a);this.lastIndex++}this.array[a+this.firstIndex]=b}else if(0==a)0==this.firstIndex&&this.growAtFront(1),this.array[--this.firstIndex]=b;else if(a==c)this.lastIndex==this.array.length&&this.growAtEnd(1),this.array[this.lastIndex++]=b;else throw new IndexOutOfBoundsException;this.modCount++},"~N,~O");$_V(c$,"add1",function(a){this.lastIndex==this.array.length&&this.growAtEnd(1);
this.array[this.lastIndex++]=a;this.modCount++;return!0},"~O");$_V(c$,"addAll",function(a){var b=a.size();if(0<b){this.lastIndex>this.array.length-b&&this.growAtEnd(b);a=a.iterator();for(b=this.lastIndex+b;this.lastIndex<b;)this.array[this.lastIndex++]=a.next();this.modCount++;return!0}return!1},"java.util.Collection");$_V(c$,"clear",function(){this.firstIndex!=this.lastIndex&&(this.fill(this.firstIndex,this.lastIndex),this.firstIndex=this.lastIndex=0,this.modCount++)});$_M(c$,"fill",function(a,b){for(var c=
b;--c>=a;)this.array[c]=null},"~N,~N");$_M(c$,"clone",function(){try{var a=$_U(this,java.util.ArrayList,"clone",[]);a.array=this.array.clone();return a}catch(b){if($_O(b,CloneNotSupportedException))return null;throw b;}});$_V(c$,"contains",function(a){if(null!=a)for(var b=this.firstIndex;b<this.lastIndex;b++){if(a.equals(this.array[b]))return!0}else for(b=this.firstIndex;b<this.lastIndex;b++)if(null==this.array[b])return!0;return!1},"~O");$_M(c$,"ensureCapacity",function(a){this.array.length<a&&(0<
this.firstIndex?this.growAtFront(a-this.array.length):this.growAtEnd(a-this.array.length))},"~N");$_V(c$,"get",function(a){if(0<=a&&a<this.size())return this.array[this.firstIndex+a];throw new IndexOutOfBoundsException;},"~N");$_M(c$,"growAtEnd",($fz=function(a){var b=this.size();if(this.firstIndex>=a-(this.array.length-this.lastIndex))a=this.lastIndex-this.firstIndex,0<b&&(System.arraycopy(this.array,this.firstIndex,this.array,0,b),this.fill(a<this.firstIndex?this.firstIndex:a,this.array.length)),
this.firstIndex=0,this.lastIndex=a;else{var c=Math.floor(b/2);a>c&&(c=a);12>c&&(c=12);a=this.newElementArray(b+c);0<b&&System.arraycopy(this.array,this.firstIndex,a,this.firstIndex,b);this.array=a}},$fz.isPrivate=!0,$fz),"~N");$_M(c$,"growAtFront",($fz=function(a){var b=this.size();if(this.array.length-this.lastIndex>=a)a=this.array.length-b,0<b&&(System.arraycopy(this.array,this.firstIndex,this.array,a,b),this.fill(this.firstIndex,this.firstIndex+b>a?a:this.firstIndex+b)),this.firstIndex=a,this.lastIndex=
this.array.length;else{var c=Math.floor(b/2);a>c&&(c=a);12>c&&(c=12);a=this.newElementArray(b+c);0<b&&System.arraycopy(this.array,this.firstIndex,a,a.length-b,b);this.firstIndex=a.length-b;this.lastIndex=a.length;this.array=a}},$fz.isPrivate=!0,$fz),"~N");$_M(c$,"growForInsert",($fz=function(a,b){var c=this.size(),d=Math.floor(c/2);b>d&&(d=b);12>d&&(d=12);var e=this.newElementArray(c+d);if(a<Math.floor(c/2)){var f=e.length-(c+b);System.arraycopy(this.array,a,e,a+d,c-a);System.arraycopy(this.array,
this.firstIndex,e,f,a);this.firstIndex=f;this.lastIndex=e.length}else System.arraycopy(this.array,this.firstIndex,e,0,a),System.arraycopy(this.array,a,e,a+b,c-a),this.firstIndex=0,this.lastIndex+=b;this.array=e},$fz.isPrivate=!0,$fz),"~N,~N");$_V(c$,"indexOf",function(a){if(null!=a)for(var b=this.firstIndex;b<this.lastIndex;b++){if(a.equals(this.array[b]))return b-this.firstIndex}else for(b=this.firstIndex;b<this.lastIndex;b++)if(null==this.array[b])return b-this.firstIndex;return-1},"~O");$_V(c$,
"isEmpty",function(){return this.lastIndex==this.firstIndex});$_V(c$,"lastIndexOf",function(a){if(null!=a)for(var b=this.lastIndex-1;b>=this.firstIndex;b--){if(a.equals(this.array[b]))return b-this.firstIndex}else for(b=this.lastIndex-1;b>=this.firstIndex;b--)if(null==this.array[b])return b-this.firstIndex;return-1},"~O");$_V(c$,"remove",function(a){var b,c=this.size();if(0<=a&&a<c)if(a==c-1)b=this.array[--this.lastIndex],this.array[this.lastIndex]=null;else if(0==a)b=this.array[this.firstIndex],
this.array[this.firstIndex++]=null;else{var d=this.firstIndex+a;b=this.array[d];a<Math.floor(c/2)?(System.arraycopy(this.array,this.firstIndex,this.array,this.firstIndex+1,a),this.array[this.firstIndex++]=null):(System.arraycopy(this.array,d+1,this.array,d,c-a-1),this.array[--this.lastIndex]=null)}else throw new IndexOutOfBoundsException;this.modCount++;return b},"~N");$_M(c$,"removeObject",function(a){a=this.indexOf(a);return 0>a?null:this.remove(a)},"~O");$_V(c$,"removeRange",function(a,b){if(0<=
a&&a<=b&&b<=this.size()){if(a!=b){var c=this.size();b==c?(this.fill(this.firstIndex+a,this.lastIndex),this.lastIndex=this.firstIndex+a):0==a?(this.fill(this.firstIndex,this.firstIndex+b),this.firstIndex+=b):(System.arraycopy(this.array,this.firstIndex+b,this.array,this.firstIndex+a,c-b),c=this.lastIndex+a-b,this.fill(c,this.lastIndex),this.lastIndex=c);this.modCount++}}else throw new IndexOutOfBoundsException;},"~N,~N");$_V(c$,"set",function(a,b){if(0<=a&&a<this.size()){var c=this.array[this.firstIndex+
a];this.array[this.firstIndex+a]=b;return c}throw new IndexOutOfBoundsException;},"~N,~O");$_V(c$,"size",function(){return this.lastIndex-this.firstIndex});$_V(c$,"toArray",function(a){var b=this.size();if(!a||b>a.length)a=Array(b);System.arraycopy(this.array,this.firstIndex,a,0,b);b<a.length&&(a[b]=null);return a},"~O");$_M(c$,"trimToSize",function(){var a=this.size(),b=this.newElementArray(a);System.arraycopy(this.array,this.firstIndex,b,0,a);this.array=b;this.firstIndex=0;this.lastIndex=this.array.length})}),
Clazz.declarePackage("JU"),Clazz.load(["java.util.ArrayList"],"JU.List",null,function(){c$=Clazz.declareType(JU,"List",java.util.ArrayList);$_M(c$,"addLast",function(a){return this.add1(a)},"~O");$_M(c$,"removeObj",function(a){return this.removeObject(a)},"~O")}),Clazz.declarePackage("java.net"),c$=Clazz.decorateAsClass(function(){this.ref=this.query=this.path=null;Clazz.instantialize(this,arguments)},java.net,"Parts"),Clazz.makeConstructor(c$,function(a){var b=a.indexOf("#");this.ref=0>b?null:a.substring(b+
1);a=0>b?a:a.substring(0,b);b=a.lastIndexOf("?");-1!=b?(this.query=a.substring(b+1),this.path=a.substring(0,b)):this.path=a},"~S"),$_M(c$,"getPath",function(){return this.path}),$_M(c$,"getQuery",function(){return this.query}),$_M(c$,"getRef",function(){return this.ref}),$_L(["java.util.AbstractCollection","$.Set"],"java.util.AbstractSet",null,function(){c$=$_T(java.util,"AbstractSet",java.util.AbstractCollection,java.util.Set);$_V(c$,"equals",function(a){return this===a?!0:$_O(a,java.util.Set)?this.size()==
a.size()&&this.containsAll(a):!1},"~O");$_V(c$,"hashCode",function(){for(var a=0,b=this.iterator();b.hasNext();)var c=b.next(),a=a+(null==c?0:c.hashCode());return a});$_V(c$,"removeAll",function(a){var b=!1;if(this.size()<=a.size())for(var c=this.iterator();c.hasNext();)a.contains(c.next())&&(c.remove(),b=!0);else for(c=a.iterator();c.hasNext();)b=this.remove(c.next())||b;return b},"java.util.Collection")}),$_L(["java.util.AbstractList","$.RandomAccess"],"java.util.Arrays",["java.lang.ArrayIndexOutOfBoundsException",
"$.IllegalArgumentException","$.NullPointerException"],function(){c$=$_T(java.util,"Arrays");c$.sort=$_V(c$,"sort",function(a,b,c,d){switch(arguments.length){case 1:for(var e=a.sort(function(a,b){return"string"==typeof a||a instanceof Comparable?a.compareTo(b):a-b}),f=0;f<a.length;f++)a[f]=e[f];break;case 2:e=a.sort(function(a,c){return null!=b?b.compare(a,c):"string"==typeof a||a instanceof Comparable?a.compareTo(c):a-c});for(f=0;f<a.length;f++)a[f]=e[f];break;case 3:var g=b,h=c;this.rangeCheck(a.length,
g,h);e=[];for(f=g;f<h;f++)e[f-g]=a[f];e=e.sort(function(a,b){return"string"==typeof a||a instanceof Comparable?a.compareTo(b):a-b});for(f=g;f<h;f++)a[f]=e[f-g];break;case 4:g=b;h=c;b=d;this.rangeCheck(a.length,g,h);e=[];for(f=g;f<h;f++)e[f-g]=a[f];e=e.sort(function(a,c){return null!=b?b.compare(a,c):"string"==typeof a||a instanceof Comparable?a.compareTo(c):a-c});for(f=g;f<h;f++)a[f]=e[f-g]}});c$.rangeCheck=$_M(c$,"rangeCheck",($fz=function(a,b,c){if(b>c)throw new IllegalArgumentException("fromIndex("+
b+") > toIndex("+c+")");if(0>b)throw new ArrayIndexOutOfBoundsException(b);if(c>a)throw new ArrayIndexOutOfBoundsException(c);},$fz.isPrivate=!0,$fz),"~N,~N,~N");c$.binarySearch=$_M(c$,"binarySearch",function(a,b){for(var c=0,d=a.length-1;c<=d;){var e=c+d>>1,f=a[e];if(f<b)c=e+1;else if(f>b)d=e-1;else return e}return-(c+1)},"~A,~N");c$.binarySearch=$_M(c$,"binarySearch",function(a,b){for(var c=0,d=a.length-1;c<=d;){var e=c+d>>1,f=a[e].compareTo(b);if(0>f)c=e+1;else if(0<f)d=e-1;else return e}return-(c+
1)},"~A,~O");c$.binarySearch=$_M(c$,"binarySearch",function(a,b,c){if(null==c)return java.util.Arrays.binarySearch(a,b);for(var d=0,e=a.length-1;d<=e;){var f=d+e>>1,g=c.compare(a[f],b);if(0>g)d=f+1;else if(0<g)e=f-1;else return f}return-(d+1)},"~A,~O,java.util.Comparator");c$.equals=$_M(c$,"equals",function(a,b){if(a===b)return!0;if(null==a||null==b)return!1;var c=a.length;if(b.length!=c)return!1;for(var d=0;d<c;d++){var e=a[d],f=b[d];if(!(null==e?null==f:null==e.equals?e==f:e.equals(f)))return!1}return!0},
"~A,~A");c$.fill=$_V(c$,"fill",function(a,b,c,d){2==arguments.length&&(d=b,b=0,c=a.length);java.util.Arrays.rangeCheck(a.length,b,c);for(var e=b;e<c;e++)a[e]=d});c$.asList=$_M(c$,"asList",function(a){return new java.util.Arrays.ArrayList(a)},"~A");$_H();c$=$_C(function(){this.a=null;$_Z(this,arguments)},java.util.Arrays,"ArrayList",java.util.AbstractList,[java.util.RandomAccess,java.io.Serializable]);$_K(c$,function(a){$_R(this,java.util.Arrays.ArrayList,[]);if(null==a)throw new NullPointerException;
this.a=a},"~A");$_V(c$,"size",function(){return this.a.length});$_M(c$,"toArray",function(){return this.a.clone()});$_V(c$,"get",function(a){return this.a[a]},"~N");$_V(c$,"set",function(a,b){var c=this.a[a];this.a[a]=b;return c},"~N,~O");$_V(c$,"indexOf",function(a){if(null==a)for(var b=0;b<this.a.length;b++){if(null==this.a[b])return b}else for(b=0;b<this.a.length;b++)if(a.equals(this.a[b]))return b;return-1},"~O");$_V(c$,"contains",function(a){return-1!=this.indexOf(a)},"~O");c$=$_P();$_S(c$,"INSERTIONSORT_THRESHOLD",
7)}),$_L(["java.util.Map"],"java.util.AbstractMap",["java.lang.StringBuilder","$.UnsupportedOperationException","java.util.AbstractCollection","$.AbstractSet","$.Iterator"],function(){c$=$_C(function(){this.valuesCollection=this.$keySet=null;$_Z(this,arguments)},java.util,"AbstractMap",null,java.util.Map);$_K(c$,function(){});$_V(c$,"clear",function(){this.entrySet().clear()});$_V(c$,"containsKey",function(a){var b=this.entrySet().iterator();if(null!=a)for(;b.hasNext();){if(a.equals(b.next().getKey()))return!0}else for(;b.hasNext();)if(null==
b.next().getKey())return!0;return!1},"~O");$_V(c$,"containsValue",function(a){var b=this.entrySet().iterator();if(null!=a)for(;b.hasNext();){if(a.equals(b.next().getValue()))return!0}else for(;b.hasNext();)if(null==b.next().getValue())return!0;return!1},"~O");$_V(c$,"equals",function(a){if(this===a)return!0;if($_O(a,java.util.Map)){if(this.size()!=a.size())return!1;a=a.entrySet();for(var b=this.entrySet().iterator();b.hasNext();)if(!a.contains(b.next()))return!1;return!0}return!1},"~O");$_V(c$,"get",
function(a){var b=this.entrySet().iterator();if(null!=a)for(;b.hasNext();){var c=b.next();if(a.equals(c.getKey()))return c.getValue()}else for(;b.hasNext();)if(c=b.next(),null==c.getKey())return c.getValue();return null},"~O");$_V(c$,"hashCode",function(){for(var a=0,b=this.entrySet().iterator();b.hasNext();)a+=b.next().hashCode();return a});$_V(c$,"isEmpty",function(){return 0==this.size()});$_V(c$,"keySet",function(){null==this.$keySet&&(this.$keySet=($_D("java.util.AbstractMap$1")?0:java.util.AbstractMap.$AbstractMap$1$(),
$_N(java.util.AbstractMap$1,this,null)));return this.$keySet});$_V(c$,"put",function(){throw new UnsupportedOperationException;},"~O,~O");$_V(c$,"putAll",function(a){var b;for(a=a.entrySet().iterator();a.hasNext()&&((b=a.next())||1);)this.put(b.getKey(),b.getValue())},"java.util.Map");$_V(c$,"remove",function(a){var b=this.entrySet().iterator();if(null!=a)for(;b.hasNext();){var c=b.next();if(a.equals(c.getKey()))return b.remove(),c.getValue()}else for(;b.hasNext();)if(c=b.next(),null==c.getKey())return b.remove(),
c.getValue();return null},"~O");$_V(c$,"size",function(){return this.entrySet().size()});$_V(c$,"toString",function(){if(this.isEmpty())return"{}";var a=new StringBuilder(28*this.size());a.append("{");for(var b=this.entrySet().iterator();b.hasNext();){var c=b.next(),d=c.getKey();d!==this?a.append(d):a.append("(this Map)");a.append("=");c=c.getValue();c!==this?a.append(c):a.append("(this Map)");b.hasNext()&&a.append(", ")}a.append("}");return a.toString()});$_V(c$,"values",function(){null==this.valuesCollection&&
(this.valuesCollection=($_D("java.util.AbstractMap$2")?0:java.util.AbstractMap.$AbstractMap$2$(),$_N(java.util.AbstractMap$2,this,null)));return this.valuesCollection});$_M(c$,"clone",function(){var a=$_U(this,java.util.AbstractMap,"clone",[]);a.$keySet=null;a.valuesCollection=null;return a});c$.$AbstractMap$1$=function(){$_H();c$=$_W(java.util,"AbstractMap$1",java.util.AbstractSet);$_V(c$,"contains",function(a){return this.b$["java.util.AbstractMap"].containsKey(a)},"~O");$_V(c$,"size",function(){return this.b$["java.util.AbstractMap"].size()});
$_V(c$,"iterator",function(){return $_D("java.util.AbstractMap$1$1")?0:java.util.AbstractMap.$AbstractMap$1$1$(),$_N(java.util.AbstractMap$1$1,this,null)});c$=$_P()};c$.$AbstractMap$1$1$=function(){$_H();c$=$_C(function(){$_B(this,arguments);this.setIterator=null;$_Z(this,arguments)},java.util,"AbstractMap$1$1",null,java.util.Iterator);$_Y(c$,function(){this.setIterator=this.b$["java.util.AbstractMap"].entrySet().iterator()});$_V(c$,"hasNext",function(){return this.setIterator.hasNext()});$_V(c$,
"next",function(){return this.setIterator.next().getKey()});$_V(c$,"remove",function(){this.setIterator.remove()});c$=$_P()};c$.$AbstractMap$2$=function(){$_H();c$=$_W(java.util,"AbstractMap$2",java.util.AbstractCollection);$_V(c$,"size",function(){return this.b$["java.util.AbstractMap"].size()});$_V(c$,"contains",function(a){return this.b$["java.util.AbstractMap"].containsValue(a)},"~O");$_V(c$,"iterator",function(){return $_D("java.util.AbstractMap$2$1")?0:java.util.AbstractMap.$AbstractMap$2$1$(),
$_N(java.util.AbstractMap$2$1,this,null)});c$=$_P()};c$.$AbstractMap$2$1$=function(){$_H();c$=$_C(function(){$_B(this,arguments);this.setIterator=null;$_Z(this,arguments)},java.util,"AbstractMap$2$1",null,java.util.Iterator);$_Y(c$,function(){this.setIterator=this.b$["java.util.AbstractMap"].entrySet().iterator()});$_V(c$,"hasNext",function(){return this.setIterator.hasNext()});$_V(c$,"next",function(){return this.setIterator.next().getValue()});$_V(c$,"remove",function(){this.setIterator.remove()});
c$=$_P()}}),$_L(["java.util.Map"],"java.util.SortedMap",null,function(){$_I(java.util,"SortedMap",java.util.Map)}),$_L(["java.util.Set"],"java.util.SortedSet",null,function(){$_I(java.util,"SortedSet",java.util.Set)}),$_L("java.util.AbstractList $.AbstractMap $.AbstractSet $.Collection $.Iterator $.List $.ListIterator $.Map $.RandomAccess $.Set $.SortedMap $.SortedSet java.lang.NullPointerException $.UnsupportedOperationException java.lang.reflect.Array".split(" "),"java.util.Collections","java.lang.ArrayIndexOutOfBoundsException $.ClassCastException $.IllegalArgumentException $.IndexOutOfBoundsException java.util.ArrayList $.Arrays $.Enumeration java.util.Map.Entry java.util.NoSuchElementException $.Random".split(" "),
function(){c$=$_T(java.util,"Collections");c$.binarySearch=$_M(c$,"binarySearch",function(a,b){if(null==a)throw new NullPointerException;if(a.isEmpty())return-1;if(!$_O(a,java.util.RandomAccess)){for(var c=a.listIterator();c.hasNext();){var d;if(0>=(d=b.compareTo(c.next())))return 0==d?c.previousIndex():-c.previousIndex()-1}return-a.size()-1}var c=0,e=a.size(),f=e-1;for(d=-1;c<=f;)if(e=c+f>>1,0<(d=b.compareTo(a.get(e))))c=e+1;else{if(0==d)return e;f=e-1}return-e-(0>d?1:2)},"java.util.List,~O");c$.binarySearch=
$_M(c$,"binarySearch",function(a,b,c){if(null==c)return java.util.Collections.binarySearch(a,b);if(!$_O(a,java.util.RandomAccess)){for(var d=a.listIterator();d.hasNext();){var e;if(0>=(e=c.compare(b,d.next())))return 0==e?d.previousIndex():-d.previousIndex()-1}return-a.size()-1}var d=0,f=a.size(),g=f-1;for(e=-1;d<=g;)if(f=d+g>>1,0<(e=c.compare(b,a.get(f))))d=f+1;else{if(0==e)return f;g=f-1}return-f-(0>e?1:2)},"java.util.List,~O,java.util.Comparator");c$.copy=$_M(c$,"copy",function(a,b){if(a.size()<
b.size())throw new ArrayIndexOutOfBoundsException;for(var c=b.iterator(),d=a.listIterator();c.hasNext();){try{d.next()}catch(e){if($_O(e,java.util.NoSuchElementException))throw new ArrayIndexOutOfBoundsException;throw e;}d.set(c.next())}},"java.util.List,java.util.List");c$.enumeration=$_M(c$,"enumeration",function(a){$_D("java.util.Collections$1")||java.util.Collections.$Collections$1$(a);return $_N(java.util.Collections$1,this,null)},"java.util.Collection");c$.fill=$_M(c$,"fill",function(a,b){for(var c=
a.listIterator();c.hasNext();)c.next(),c.set(b)},"java.util.List,~O");c$.max=$_M(c$,"max",function(a){a=a.iterator();for(var b=a.next();a.hasNext();){var c=a.next();0>b.compareTo(c)&&(b=c)}return b},"java.util.Collection");c$.max=$_M(c$,"max",function(a,b){for(var c=a.iterator(),d=c.next();c.hasNext();){var e=c.next();0>b.compare(d,e)&&(d=e)}return d},"java.util.Collection,java.util.Comparator");c$.min=$_M(c$,"min",function(a){a=a.iterator();for(var b=a.next();a.hasNext();){var c=a.next();0<b.compareTo(c)&&
(b=c)}return b},"java.util.Collection");c$.min=$_M(c$,"min",function(a,b){for(var c=a.iterator(),d=c.next();c.hasNext();){var e=c.next();0<b.compare(d,e)&&(d=e)}return d},"java.util.Collection,java.util.Comparator");c$.nCopies=$_M(c$,"nCopies",function(a,b){return new java.util.Collections.CopiesList(a,b)},"~N,~O");c$.reverse=$_M(c$,"reverse",function(a){var b=a.size(),c=a.listIterator();a=a.listIterator(b);for(var d=0;d<Math.floor(b/2);d++){var e=c.next(),f=a.previous();c.set(f);a.set(e)}},"java.util.List");
c$.reverseOrder=$_M(c$,"reverseOrder",function(){return new java.util.Collections.ReverseComparator});c$.reverseOrder=$_M(c$,"reverseOrder",function(a){return null==a?java.util.Collections.reverseOrder():new java.util.Collections.ReverseComparatorWithComparator(a)},"java.util.Comparator");c$.shuffle=$_M(c$,"shuffle",function(a){java.util.Collections.shuffle(a,new java.util.Random)},"java.util.List");c$.shuffle=$_M(c$,"shuffle",function(a,b){if($_O(a,java.util.RandomAccess))for(d=a.size()-1;0<d;d--)e=
b.nextInt()%(d+1),0>e&&(e=-e),a.set(e,a.set(d,a.get(e)));else{for(var c=a.toArray(),d=c.length-1;0<d;d--){var e=b.nextInt()%(d+1);0>e&&(e=-e);var f=c[d];c[d]=c[e];c[e]=f}d=0;for(e=a.listIterator();e.hasNext();)e.next(),e.set(c[d++])}},"java.util.List,java.util.Random");c$.singleton=$_M(c$,"singleton",function(a){return new java.util.Collections.SingletonSet(a)},"~O");c$.singletonList=$_M(c$,"singletonList",function(a){return new java.util.Collections.SingletonList(a)},"~O");c$.singletonMap=$_M(c$,
"singletonMap",function(a,b){return new java.util.Collections.SingletonMap(a,b)},"~O,~O");c$.sort=$_M(c$,"sort",function(a){var b=a.toArray();java.util.Arrays.sort(b);var c=0;for(a=a.listIterator();a.hasNext();)a.next(),a.set(b[c++])},"java.util.List");c$.sort=$_M(c$,"sort",function(a,b){var c=a.toArray(Array(a.size()));java.util.Arrays.sort(c,b);for(var d=0,e=a.listIterator();e.hasNext();)e.next(),e.set(c[d++])},"java.util.List,java.util.Comparator");c$.swap=$_M(c$,"swap",function(a,b,c){if(null==
a)throw new NullPointerException;b!=c&&a.set(c,a.set(b,a.get(c)))},"java.util.List,~N,~N");c$.replaceAll=$_M(c$,"replaceAll",function(a,b,c){for(var d,e=!1;-1<(d=a.indexOf(b));)e=!0,a.set(d,c);return e},"java.util.List,~O,~O");c$.rotate=$_M(c$,"rotate",function(a,b){var c=a.size();if(0!=c){var d;d=0<b?b%c:c- -1*(b%c);if(!(0==d||d==c))if($_O(a,java.util.RandomAccess))for(var e=a.get(0),f=0,g=0,h=0;h<c;h++)f=(f+d)%c,e=a.set(f,e),f==g&&(f=++g,e=a.get(g));else e=(c-d)%c,d=a.subList(0,e),c=a.subList(e,
c),java.util.Collections.reverse(d),java.util.Collections.reverse(c),java.util.Collections.reverse(a)}},"java.util.List,~N");c$.indexOfSubList=$_M(c$,"indexOfSubList",function(a,b){var c=a.size(),d=b.size();if(d>c)return-1;if(0==d)return 0;var e=b.get(0),f=a.indexOf(e);if(-1==f)return-1;for(;f<c&&c-f>=d;){var g=a.listIterator(f);if(null==e?null==g.next():e.equals(g.next())){for(var h=b.listIterator(1),k=!1;h.hasNext();){var l=h.next();if(!g.hasNext())return-1;if(null==l?null!=g.next():!l.equals(g.next())){k=
!0;break}}if(!k)return f}f++}return-1},"java.util.List,java.util.List");c$.lastIndexOfSubList=$_M(c$,"lastIndexOfSubList",function(a,b){var c=b.size(),d=a.size();if(c>d)return-1;if(0==c)return d;for(var d=b.get(c-1),e=a.lastIndexOf(d);-1<e&&e+1>=c;){var f=a.listIterator(e+1);if(null==d?null==f.previous():d.equals(f.previous())){for(var g=b.listIterator(c-1),h=!1;g.hasPrevious();){var k=g.previous();if(!f.hasPrevious())return-1;if(null==k?null!=f.previous():!k.equals(f.previous())){h=!0;break}}if(!h)return f.nextIndex()}e--}return-1},
"java.util.List,java.util.List");c$.list=$_M(c$,"list",function(a){for(var b=new java.util.ArrayList;a.hasMoreElements();)b.add(a.nextElement());return b},"java.util.Enumeration");c$.synchronizedCollection=$_M(c$,"synchronizedCollection",function(a){if(null==a)throw new NullPointerException;return new java.util.Collections.SynchronizedCollection(a)},"java.util.Collection");c$.synchronizedList=$_M(c$,"synchronizedList",function(a){if(null==a)throw new NullPointerException;return $_O(a,java.util.RandomAccess)?
new java.util.Collections.SynchronizedRandomAccessList(a):new java.util.Collections.SynchronizedList(a)},"java.util.List");c$.synchronizedMap=$_M(c$,"synchronizedMap",function(a){if(null==a)throw new NullPointerException;return new java.util.Collections.SynchronizedMap(a)},"java.util.Map");c$.synchronizedSet=$_M(c$,"synchronizedSet",function(a){if(null==a)throw new NullPointerException;return new java.util.Collections.SynchronizedSet(a)},"java.util.Set");c$.synchronizedSortedMap=$_M(c$,"synchronizedSortedMap",
function(a){if(null==a)throw new NullPointerException;return new java.util.Collections.SynchronizedSortedMap(a)},"java.util.SortedMap");c$.synchronizedSortedSet=$_M(c$,"synchronizedSortedSet",function(a){if(null==a)throw new NullPointerException;return new java.util.Collections.SynchronizedSortedSet(a)},"java.util.SortedSet");c$.unmodifiableCollection=$_M(c$,"unmodifiableCollection",function(a){if(null==a)throw new NullPointerException;return new java.util.Collections.UnmodifiableCollection(a)},"java.util.Collection");
c$.unmodifiableList=$_M(c$,"unmodifiableList",function(a){if(null==a)throw new NullPointerException;return $_O(a,java.util.RandomAccess)?new java.util.Collections.UnmodifiableRandomAccessList(a):new java.util.Collections.UnmodifiableList(a)},"java.util.List");c$.unmodifiableMap=$_M(c$,"unmodifiableMap",function(a){if(null==a)throw new NullPointerException;return new java.util.Collections.UnmodifiableMap(a)},"java.util.Map");c$.unmodifiableSet=$_M(c$,"unmodifiableSet",function(a){if(null==a)throw new NullPointerException;
return new java.util.Collections.UnmodifiableSet(a)},"java.util.Set");c$.unmodifiableSortedMap=$_M(c$,"unmodifiableSortedMap",function(a){if(null==a)throw new NullPointerException;return new java.util.Collections.UnmodifiableSortedMap(a)},"java.util.SortedMap");c$.unmodifiableSortedSet=$_M(c$,"unmodifiableSortedSet",function(a){if(null==a)throw new NullPointerException;return new java.util.Collections.UnmodifiableSortedSet(a)},"java.util.SortedSet");c$.frequency=$_M(c$,"frequency",function(a,b){if(null==
a)throw new NullPointerException;if(a.isEmpty())return 0;for(var c=0,d=a.iterator();d.hasNext();){var e=d.next();(null==b?null==e:b.equals(e))&&c++}return c},"java.util.Collection,~O");c$.emptyList=$_M(c$,"emptyList",function(){return java.util.Collections.EMPTY_LIST});c$.emptySet=$_M(c$,"emptySet",function(){return java.util.Collections.EMPTY_SET});c$.emptyMap=$_M(c$,"emptyMap",function(){return java.util.Collections.EMPTY_MAP});c$.checkedCollection=$_M(c$,"checkedCollection",function(a,b){return new java.util.Collections.CheckedCollection(a,
b)},"java.util.Collection,Class");c$.checkedMap=$_M(c$,"checkedMap",function(a,b,c){return new java.util.Collections.CheckedMap(a,b,c)},"java.util.Map,Class,Class");c$.checkedList=$_M(c$,"checkedList",function(a,b){return $_O(a,java.util.RandomAccess)?new java.util.Collections.CheckedRandomAccessList(a,b):new java.util.Collections.CheckedList(a,b)},"java.util.List,Class");c$.checkedSet=$_M(c$,"checkedSet",function(a,b){return new java.util.Collections.CheckedSet(a,b)},"java.util.Set,Class");c$.checkedSortedMap=
$_M(c$,"checkedSortedMap",function(a,b,c){return new java.util.Collections.CheckedSortedMap(a,b,c)},"java.util.SortedMap,Class,Class");c$.checkedSortedSet=$_M(c$,"checkedSortedSet",function(a,b){return new java.util.Collections.CheckedSortedSet(a,b)},"java.util.SortedSet,Class");c$.addAll=$_M(c$,"addAll",function(a,b){for(var c=!1,d=0;d<b.length;d++)c=(new Boolean(c|a.add(b[d]))).valueOf();return c},"java.util.Collection,~A");c$.disjoint=$_M(c$,"disjoint",function(a,b){if($_O(a,java.util.Set)&&!$_O(b,
java.util.Set)||b.size()>a.size()){var c=a;a=b;b=c}for(c=a.iterator();c.hasNext();)if(b.contains(c.next()))return!1;return!0},"java.util.Collection,java.util.Collection");c$.checkType=$_M(c$,"checkType",function(a,b){if(!b.isInstance(a))throw new ClassCastException("Attempt to insert "+a.getClass()+" element into collection with element type "+b);return a},"~O,Class");c$.$Collections$1$=function(a){$_H();c$=$_C(function(){$_B(this,arguments);this.it=null;$_Z(this,arguments)},java.util,"Collections$1",
null,java.util.Enumeration);$_Y(c$,function(){this.it=a.iterator()});$_M(c$,"hasMoreElements",function(){return this.it.hasNext()});$_M(c$,"nextElement",function(){return this.it.next()});c$=$_P()};$_H();c$=$_C(function(){this.n=0;this.element=null;$_Z(this,arguments)},java.util.Collections,"CopiesList",java.util.AbstractList,java.io.Serializable);$_K(c$,function(a,b){$_R(this,java.util.Collections.CopiesList,[]);if(0>a)throw new IllegalArgumentException;this.n=a;this.element=b},"~N,~O");$_V(c$,"contains",
function(a){return null==this.element?null==a:this.element.equals(a)},"~O");$_V(c$,"size",function(){return this.n});$_V(c$,"get",function(a){if(0<=a&&a<this.n)return this.element;throw new IndexOutOfBoundsException;},"~N");c$=$_P();$_H();c$=$_T(java.util.Collections,"EmptyList",java.util.AbstractList,java.io.Serializable);$_V(c$,"contains",function(){return!1},"~O");$_V(c$,"size",function(){return 0});$_V(c$,"get",function(){throw new IndexOutOfBoundsException;},"~N");c$=$_P();$_H();c$=$_T(java.util.Collections,
"EmptySet",java.util.AbstractSet,java.io.Serializable);$_V(c$,"contains",function(){return!1},"~O");$_V(c$,"size",function(){return 0});$_V(c$,"iterator",function(){return $_D("java.util.Collections$EmptySet$1")?0:java.util.Collections.EmptySet.$Collections$EmptySet$1$(),$_N(java.util.Collections$EmptySet$1,this,null)});c$.$Collections$EmptySet$1$=function(){$_H();c$=$_W(java.util,"Collections$EmptySet$1",null,java.util.Iterator);$_V(c$,"hasNext",function(){return!1});$_V(c$,"next",function(){throw new java.util.NoSuchElementException;
});$_V(c$,"remove",function(){throw new UnsupportedOperationException;});c$=$_P()};c$=$_P();$_H();c$=$_T(java.util.Collections,"EmptyMap",java.util.AbstractMap,java.io.Serializable);$_V(c$,"containsKey",function(){return!1},"~O");$_V(c$,"containsValue",function(){return!1},"~O");$_V(c$,"entrySet",function(){return java.util.Collections.EMPTY_SET});$_V(c$,"get",function(){return null},"~O");$_V(c$,"keySet",function(){return java.util.Collections.EMPTY_SET});$_V(c$,"values",function(){return java.util.Collections.EMPTY_LIST});
c$=$_P();$_H();c$=$_T(java.util.Collections,"ReverseComparator",null,[java.util.Comparator,java.io.Serializable]);$_V(c$,"compare",function(a,b){return b.compareTo(a)},"~O,~O");c$=$_P();$_H();c$=$_C(function(){this.comparator=null;$_Z(this,arguments)},java.util.Collections,"ReverseComparatorWithComparator",null,[java.util.Comparator,java.io.Serializable]);$_K(c$,function(a){this.comparator=a},"java.util.Comparator");$_M(c$,"compare",function(a,b){return this.comparator.compare(b,a)},"~O,~O");c$=$_P();
$_H();c$=$_C(function(){this.element=null;$_Z(this,arguments)},java.util.Collections,"SingletonSet",java.util.AbstractSet,java.io.Serializable);$_K(c$,function(a){$_R(this,java.util.Collections.SingletonSet,[]);this.element=a},"~O");$_V(c$,"contains",function(a){return null==this.element?null==a:this.element.equals(a)},"~O");$_V(c$,"size",function(){return 1});$_V(c$,"iterator",function(){return $_D("java.util.Collections$SingletonSet$1")?0:java.util.Collections.SingletonSet.$Collections$SingletonSet$1$(),
$_N(java.util.Collections$SingletonSet$1,this,null)});c$.$Collections$SingletonSet$1$=function(){$_H();c$=$_C(function(){$_B(this,arguments);this.$hasNext=!0;$_Z(this,arguments)},java.util,"Collections$SingletonSet$1",null,java.util.Iterator);$_V(c$,"hasNext",function(){return this.$hasNext});$_V(c$,"next",function(){if(this.$hasNext)return this.$hasNext=!1,this.b$["java.util.Collections.SingletonSet"].element;throw new java.util.NoSuchElementException;});$_V(c$,"remove",function(){throw new UnsupportedOperationException;
});c$=$_P()};c$=$_P();$_H();c$=$_C(function(){this.element=null;$_Z(this,arguments)},java.util.Collections,"SingletonList",java.util.AbstractList,java.io.Serializable);$_K(c$,function(a){$_R(this,java.util.Collections.SingletonList,[]);this.element=a},"~O");$_V(c$,"contains",function(a){return null==this.element?null==a:this.element.equals(a)},"~O");$_V(c$,"get",function(a){if(0==a)return this.element;throw new IndexOutOfBoundsException;},"~N");$_V(c$,"size",function(){return 1});c$=$_P();$_H();c$=
$_C(function(){this.v=this.k=null;$_Z(this,arguments)},java.util.Collections,"SingletonMap",java.util.AbstractMap,java.io.Serializable);$_K(c$,function(a,b){$_R(this,java.util.Collections.SingletonMap,[]);this.k=a;this.v=b},"~O,~O");$_V(c$,"containsKey",function(a){return null==this.k?null==a:this.k.equals(a)},"~O");$_V(c$,"containsValue",function(a){return null==this.v?null==a:this.v.equals(a)},"~O");$_V(c$,"get",function(a){return this.containsKey(a)?this.v:null},"~O");$_V(c$,"size",function(){return 1});
$_V(c$,"entrySet",function(){return $_D("java.util.Collections$SingletonMap$1")?0:java.util.Collections.SingletonMap.$Collections$SingletonMap$1$(),$_N(java.util.Collections$SingletonMap$1,this,null)});c$.$Collections$SingletonMap$1$=function(){$_H();c$=$_W(java.util,"Collections$SingletonMap$1",java.util.AbstractSet);$_V(c$,"contains",function(a){return $_O(a,java.util.Map.Entry)?this.b$["java.util.Collections.SingletonMap"].containsKey(a.getKey())&&this.b$["java.util.Collections.SingletonMap"].containsValue(a.getValue()):
!1},"~O");$_V(c$,"size",function(){return 1});$_V(c$,"iterator",function(){return $_D("java.util.Collections$SingletonMap$1$1")?0:java.util.Collections.$Collections$SingletonMap$1$1$(),$_N(java.util.Collections$SingletonMap$1$1,this,null)});c$=$_P()};c$.$Collections$SingletonMap$1$1$=function(){$_H();c$=$_C(function(){$_B(this,arguments);this.$hasNext=!0;$_Z(this,arguments)},java.util,"Collections$SingletonMap$1$1",null,java.util.Iterator);$_V(c$,"hasNext",function(){return this.$hasNext});$_V(c$,
"next",function(){if(this.$hasNext)return this.$hasNext=!1,$_D("java.util.Collections$SingletonMap$1$1$1")?0:java.util.Collections.$Collections$SingletonMap$1$1$1$(),$_N(java.util.Collections$SingletonMap$1$1$1,this,null);throw new java.util.NoSuchElementException;});$_V(c$,"remove",function(){throw new UnsupportedOperationException;});c$=$_P()};c$.$Collections$SingletonMap$1$1$1$=function(){$_H();c$=$_W(java.util,"Collections$SingletonMap$1$1$1",null,java.util.Map.Entry);$_V(c$,"equals",function(a){return this.b$["java.util.Collections$SingletonMap$1"].contains(a)},
"~O");$_V(c$,"getKey",function(){return this.b$["java.util.Collections.SingletonMap"].k});$_V(c$,"getValue",function(){return this.b$["java.util.Collections.SingletonMap"].v});$_V(c$,"hashCode",function(){return(null==this.b$["java.util.Collections.SingletonMap"].k?0:this.b$["java.util.Collections.SingletonMap"].k.hashCode())^(null==this.b$["java.util.Collections.SingletonMap"].v?0:this.b$["java.util.Collections.SingletonMap"].v.hashCode())});$_V(c$,"setValue",function(){throw new UnsupportedOperationException;
},"~O");c$=$_P()};c$=$_P();$_H();c$=$_C(function(){this.mutex=this.c=null;$_Z(this,arguments)},java.util.Collections,"SynchronizedCollection",null,[java.util.Collection,java.io.Serializable]);$_K(c$,function(a){this.c=a;this.mutex=this},"java.util.Collection");$_K(c$,function(a,b){this.c=a;this.mutex=b},"java.util.Collection,~O");$_M(c$,"add",function(a){return this.c.add(a)},"~O");$_M(c$,"addAll",function(a){return this.c.addAll(a)},"java.util.Collection");$_M(c$,"clear",function(){this.c.clear()});
$_M(c$,"contains",function(a){return this.c.contains(a)},"~O");$_M(c$,"containsAll",function(a){return this.c.containsAll(a)},"java.util.Collection");$_M(c$,"isEmpty",function(){return this.c.isEmpty()});$_M(c$,"iterator",function(){return this.c.iterator()});$_M(c$,"remove",function(a){return this.c.remove(a)},"~O");$_M(c$,"removeAll",function(a){return this.c.removeAll(a)},"java.util.Collection");$_M(c$,"retainAll",function(a){return this.c.retainAll(a)},"java.util.Collection");$_M(c$,"size",function(){return this.c.size()});
$_M(c$,"toArray",function(){return this.c.toArray()});$_M(c$,"toString",function(){return this.c.toString()});$_M(c$,"toArray",function(a){return this.c.toArray(a)},"~A");c$=$_P();$_H();c$=$_T(java.util.Collections,"SynchronizedRandomAccessList",java.util.Collections.SynchronizedList,java.util.RandomAccess);$_V(c$,"subList",function(a,b){return new java.util.Collections.SynchronizedRandomAccessList(this.list.subList(a,b),this.mutex)},"~N,~N");c$=$_P();$_H();c$=$_C(function(){this.list=null;$_Z(this,
arguments)},java.util.Collections,"SynchronizedList",java.util.Collections.SynchronizedCollection,java.util.List);$_K(c$,function(a){$_R(this,java.util.Collections.SynchronizedList,[a]);this.list=a},"java.util.List");$_K(c$,function(a,b){$_R(this,java.util.Collections.SynchronizedList,[a,b]);this.list=a},"java.util.List,~O");$_M(c$,"add",function(a,b){this.list.add(a,b)},"~N,~O");$_M(c$,"addAll",function(a,b){return this.list.addAll(a,b)},"~N,java.util.Collection");$_V(c$,"equals",function(a){return this.list.equals(a)},
"~O");$_M(c$,"get",function(a){return this.list.get(a)},"~N");$_V(c$,"hashCode",function(){return this.list.hashCode()});$_M(c$,"indexOf",function(a){return this.list.indexOf(a)},"~O");$_M(c$,"lastIndexOf",function(a){return this.list.lastIndexOf(a)},"~O");$_M(c$,"listIterator",function(){return this.list.listIterator()});$_M(c$,"listIterator",function(a){return this.list.listIterator(a)},"~N");$_M(c$,"remove",function(a){return this.list.remove(a)},"~N");$_M(c$,"set",function(a,b){return this.list.set(a,
b)},"~N,~O");$_M(c$,"subList",function(a,b){return new java.util.Collections.SynchronizedList(this.list.subList(a,b),this.mutex)},"~N,~N");c$=$_P();$_H();c$=$_C(function(){this.mutex=this.m=null;$_Z(this,arguments)},java.util.Collections,"SynchronizedMap",null,[java.util.Map,java.io.Serializable]);$_K(c$,function(a){this.m=a;this.mutex=this},"java.util.Map");$_K(c$,function(a,b){this.m=a;this.mutex=b},"java.util.Map,~O");$_M(c$,"clear",function(){this.m.clear()});$_M(c$,"containsKey",function(a){return this.m.containsKey(a)},
"~O");$_M(c$,"containsValue",function(a){return this.m.containsValue(a)},"~O");$_M(c$,"entrySet",function(){return new java.util.Collections.SynchronizedSet(this.m.entrySet(),this.mutex)});$_V(c$,"equals",function(a){return this.m.equals(a)},"~O");$_M(c$,"get",function(a){return this.m.get(a)},"~O");$_V(c$,"hashCode",function(){return this.m.hashCode()});$_M(c$,"isEmpty",function(){return this.m.isEmpty()});$_M(c$,"keySet",function(){return new java.util.Collections.SynchronizedSet(this.m.keySet(),
this.mutex)});$_M(c$,"put",function(a,b){return this.m.put(a,b)},"~O,~O");$_M(c$,"putAll",function(a){this.m.putAll(a)},"java.util.Map");$_M(c$,"remove",function(a){return this.m.remove(a)},"~O");$_M(c$,"size",function(){return this.m.size()});$_M(c$,"values",function(){return new java.util.Collections.SynchronizedCollection(this.m.values(),this.mutex)});$_M(c$,"toString",function(){return this.m.toString()});c$=$_P();$_H();c$=$_T(java.util.Collections,"SynchronizedSet",java.util.Collections.SynchronizedCollection,
java.util.Set);$_V(c$,"equals",function(a){return this.c.equals(a)},"~O");$_V(c$,"hashCode",function(){return this.c.hashCode()});c$=$_P();$_H();c$=$_C(function(){this.sm=null;$_Z(this,arguments)},java.util.Collections,"SynchronizedSortedMap",java.util.Collections.SynchronizedMap,java.util.SortedMap);$_K(c$,function(a){$_R(this,java.util.Collections.SynchronizedSortedMap,[a]);this.sm=a},"java.util.SortedMap");$_K(c$,function(a,b){$_R(this,java.util.Collections.SynchronizedSortedMap,[a,b]);this.sm=
a},"java.util.SortedMap,~O");$_M(c$,"comparator",function(){return this.sm.comparator()});$_M(c$,"firstKey",function(){return this.sm.firstKey()});$_M(c$,"headMap",function(a){return new java.util.Collections.SynchronizedSortedMap(this.sm.headMap(a),this.mutex)},"~O");$_M(c$,"lastKey",function(){return this.sm.lastKey()});$_M(c$,"subMap",function(a,b){return new java.util.Collections.SynchronizedSortedMap(this.sm.subMap(a,b),this.mutex)},"~O,~O");$_M(c$,"tailMap",function(a){return new java.util.Collections.SynchronizedSortedMap(this.sm.tailMap(a),
this.mutex)},"~O");c$=$_P();$_H();c$=$_C(function(){this.ss=null;$_Z(this,arguments)},java.util.Collections,"SynchronizedSortedSet",java.util.Collections.SynchronizedSet,java.util.SortedSet);$_K(c$,function(a){$_R(this,java.util.Collections.SynchronizedSortedSet,[a]);this.ss=a},"java.util.SortedSet");$_K(c$,function(a,b){$_R(this,java.util.Collections.SynchronizedSortedSet,[a,b]);this.ss=a},"java.util.SortedSet,~O");$_M(c$,"comparator",function(){return this.ss.comparator()});$_M(c$,"first",function(){return this.ss.first()});
$_M(c$,"headSet",function(a){return new java.util.Collections.SynchronizedSortedSet(this.ss.headSet(a),this.mutex)},"~O");$_M(c$,"last",function(){return this.ss.last()});$_M(c$,"subSet",function(a,b){return new java.util.Collections.SynchronizedSortedSet(this.ss.subSet(a,b),this.mutex)},"~O,~O");$_M(c$,"tailSet",function(a){return new java.util.Collections.SynchronizedSortedSet(this.ss.tailSet(a),this.mutex)},"~O");c$=$_P();$_H();c$=$_C(function(){this.c=null;$_Z(this,arguments)},java.util.Collections,
"UnmodifiableCollection",null,[java.util.Collection,java.io.Serializable]);$_K(c$,function(a){this.c=a},"java.util.Collection");$_V(c$,"add",function(){throw new UnsupportedOperationException;},"~O");$_V(c$,"addAll",function(){throw new UnsupportedOperationException;},"java.util.Collection");$_V(c$,"clear",function(){throw new UnsupportedOperationException;});$_M(c$,"contains",function(a){return this.c.contains(a)},"~O");$_M(c$,"containsAll",function(a){return this.c.containsAll(a)},"java.util.Collection");
$_M(c$,"isEmpty",function(){return this.c.isEmpty()});$_M(c$,"iterator",function(){return $_D("java.util.Collections$UnmodifiableCollection$1")?0:java.util.Collections.UnmodifiableCollection.$Collections$UnmodifiableCollection$1$(),$_N(java.util.Collections$UnmodifiableCollection$1,this,null)});$_V(c$,"remove",function(){throw new UnsupportedOperationException;},"~O");$_V(c$,"removeAll",function(){throw new UnsupportedOperationException;},"java.util.Collection");$_V(c$,"retainAll",function(){throw new UnsupportedOperationException;
},"java.util.Collection");$_M(c$,"size",function(){return this.c.size()});$_M(c$,"toArray",function(){return this.c.toArray()});$_M(c$,"toArray",function(a){return this.c.toArray(a)},"~A");$_M(c$,"toString",function(){return this.c.toString()});c$.$Collections$UnmodifiableCollection$1$=function(){$_H();c$=$_C(function(){$_B(this,arguments);this.iterator=null;$_Z(this,arguments)},java.util,"Collections$UnmodifiableCollection$1",null,java.util.Iterator);$_Y(c$,function(){this.iterator=this.b$["java.util.Collections.UnmodifiableCollection"].c.iterator()});
$_M(c$,"hasNext",function(){return this.iterator.hasNext()});$_M(c$,"next",function(){return this.iterator.next()});$_V(c$,"remove",function(){throw new UnsupportedOperationException;});c$=$_P()};c$=$_P();$_H();c$=$_T(java.util.Collections,"UnmodifiableRandomAccessList",java.util.Collections.UnmodifiableList,java.util.RandomAccess);$_V(c$,"subList",function(a,b){return new java.util.Collections.UnmodifiableRandomAccessList(this.list.subList(a,b))},"~N,~N");c$=$_P();$_H();c$=$_C(function(){this.list=
null;$_Z(this,arguments)},java.util.Collections,"UnmodifiableList",java.util.Collections.UnmodifiableCollection,java.util.List);$_K(c$,function(a){$_R(this,java.util.Collections.UnmodifiableList,[a]);this.list=a},"java.util.List");$_M(c$,"add",function(){throw new UnsupportedOperationException;},"~N,~O");$_M(c$,"addAll",function(){throw new UnsupportedOperationException;},"~N,java.util.Collection");$_V(c$,"equals",function(a){return this.list.equals(a)},"~O");$_M(c$,"get",function(a){return this.list.get(a)},
"~N");$_V(c$,"hashcode",function(){return this.list.hashCode()});$_M(c$,"indexOf",function(a){return this.list.indexOf(a)},"~O");$_M(c$,"lastIndexOf",function(a){return this.list.lastIndexOf(a)},"~O");$_M(c$,"listIterator",function(){return this.listIterator(0)});$_M(c$,"listIterator",function(){return $_D("java.util.Collections$UnmodifiableList$1")?0:java.util.Collections.UnmodifiableList.$Collections$UnmodifiableList$1$(),$_N(java.util.Collections$UnmodifiableList$1,this,null)},"~N");$_M(c$,"remove",
function(){throw new UnsupportedOperationException;},"~N");$_V(c$,"set",function(){throw new UnsupportedOperationException;},"~N,~O");$_M(c$,"subList",function(a,b){return new java.util.Collections.UnmodifiableList(this.list.subList(a,b))},"~N,~N");c$.$Collections$UnmodifiableList$1$=function(){$_H();c$=$_C(function(){$_B(this,arguments);this.iterator=null;$_Z(this,arguments)},java.util,"Collections$UnmodifiableList$1",null,java.util.ListIterator);$_Y(c$,function(){this.iterator=this.b$["java.util.Collections.UnmodifiableList"].list.listIterator(location)});
$_V(c$,"add",function(){throw new UnsupportedOperationException;},"~O");$_M(c$,"hasNext",function(){return this.iterator.hasNext()});$_M(c$,"hasPrevious",function(){return this.iterator.hasPrevious()});$_M(c$,"next",function(){return this.iterator.next()});$_M(c$,"nextIndex",function(){return this.iterator.nextIndex()});$_M(c$,"previous",function(){return this.iterator.previous()});$_M(c$,"previousIndex",function(){return this.iterator.previousIndex()});$_V(c$,"remove",function(){throw new UnsupportedOperationException;
});$_V(c$,"set",function(){throw new UnsupportedOperationException;},"~O");c$=$_P()};c$=$_P();$_H();c$=$_C(function(){this.m=null;$_Z(this,arguments)},java.util.Collections,"UnmodifiableMap",null,[java.util.Map,java.io.Serializable]);$_K(c$,function(a){this.m=a},"java.util.Map");$_V(c$,"clear",function(){throw new UnsupportedOperationException;});$_M(c$,"containsKey",function(a){return this.m.containsKey(a)},"~O");$_M(c$,"containsValue",function(a){return this.m.containsValue(a)},"~O");$_M(c$,"entrySet",
function(){return new java.util.Collections.UnmodifiableMap.UnmodifiableEntrySet(this.m.entrySet())});$_V(c$,"equals",function(a){return this.m.equals(a)},"~O");$_M(c$,"get",function(a){return this.m.get(a)},"~O");$_V(c$,"hashcode",function(){return this.m.hashCode()});$_M(c$,"isEmpty",function(){return this.m.isEmpty()});$_M(c$,"keySet",function(){return new java.util.Collections.UnmodifiableSet(this.m.keySet())});$_V(c$,"put",function(){throw new UnsupportedOperationException;},"~O,~O");$_V(c$,
"putAll",function(){throw new UnsupportedOperationException;},"java.util.Map");$_V(c$,"remove",function(){throw new UnsupportedOperationException;},"~O");$_M(c$,"size",function(){return this.m.size()});$_M(c$,"values",function(){return new java.util.Collections.UnmodifiableCollection(this.m.values())});$_M(c$,"toString",function(){return this.m.toString()});$_H();c$=$_T(java.util.Collections.UnmodifiableMap,"UnmodifiableEntrySet",java.util.Collections.UnmodifiableSet);$_V(c$,"iterator",function(){return $_D("java.util.Collections$UnmodifiableMap$UnmodifiableEntrySet$1")?
0:java.util.Collections.UnmodifiableMap.UnmodifiableEntrySet.$Collections$UnmodifiableMap$UnmodifiableEntrySet$1$(),$_N(java.util.Collections$UnmodifiableMap$UnmodifiableEntrySet$1,this,null)});$_M(c$,"toArray",function(){for(var a=this.c.size(),b=Array(a),c=this.iterator();0<=--a;)b[a]=c.next();return b});$_M(c$,"toArray",function(a){var b=this.c.size(),c=0,d=this.iterator();b>a.length&&(a=a.getClass().getComponentType(),a=java.lang.reflect.Array.newInstance(a,b));for(;c<b;)a[c++]=d.next();c<a.length&&
(a[c]=null);return a},"~A");c$.$Collections$UnmodifiableMap$UnmodifiableEntrySet$1$=function(){$_H();c$=$_C(function(){$_B(this,arguments);this.iterator=null;$_Z(this,arguments)},java.util,"Collections$UnmodifiableMap$UnmodifiableEntrySet$1",null,java.util.Iterator);$_Y(c$,function(){this.iterator=this.b$["java.util.Collections.UnmodifiableMap.UnmodifiableEntrySet"].c.iterator()});$_M(c$,"hasNext",function(){return this.iterator.hasNext()});$_M(c$,"next",function(){return new java.util.Collections.UnmodifiableMap.UnmodifiableEntrySet.UnmodifiableMapEntry(this.iterator.next())});
$_V(c$,"remove",function(){throw new UnsupportedOperationException;});c$=$_P()};$_H();c$=$_C(function(){this.mapEntry=null;$_Z(this,arguments)},java.util.Collections.UnmodifiableMap.UnmodifiableEntrySet,"UnmodifiableMapEntry",null,java.util.Map.Entry);$_K(c$,function(a){this.mapEntry=a},"java.util.Map.Entry");$_V(c$,"equals",function(a){return this.mapEntry.equals(a)},"~O");$_M(c$,"getKey",function(){return this.mapEntry.getKey()});$_M(c$,"getValue",function(){return this.mapEntry.getValue()});$_V(c$,
"hashcode",function(){return this.mapEntry.hashCode()});$_V(c$,"setValue",function(){throw new UnsupportedOperationException;},"~O");$_M(c$,"toString",function(){return this.mapEntry.toString()});c$=$_P();c$=$_P();c$=$_P();$_H();c$=$_T(java.util.Collections,"UnmodifiableSet",java.util.Collections.UnmodifiableCollection,java.util.Set);$_V(c$,"equals",function(a){return this.c.equals(a)},"~O");$_V(c$,"hashCode",function(){return this.c.hashCode()});c$=$_P();$_H();c$=$_C(function(){this.sm=null;$_Z(this,
arguments)},java.util.Collections,"UnmodifiableSortedMap",java.util.Collections.UnmodifiableMap,java.util.SortedMap);$_K(c$,function(a){$_R(this,java.util.Collections.UnmodifiableSortedMap,[a]);this.sm=a},"java.util.SortedMap");$_M(c$,"comparator",function(){return this.sm.comparator()});$_M(c$,"firstKey",function(){return this.sm.firstKey()});$_M(c$,"headMap",function(a){return new java.util.Collections.UnmodifiableSortedMap(this.sm.headMap(a))},"~O");$_M(c$,"lastKey",function(){return this.sm.lastKey()});
$_M(c$,"subMap",function(a,b){return new java.util.Collections.UnmodifiableSortedMap(this.sm.subMap(a,b))},"~O,~O");$_M(c$,"tailMap",function(a){return new java.util.Collections.UnmodifiableSortedMap(this.sm.tailMap(a))},"~O");c$=$_P();$_H();c$=$_C(function(){this.ss=null;$_Z(this,arguments)},java.util.Collections,"UnmodifiableSortedSet",java.util.Collections.UnmodifiableSet,java.util.SortedSet);$_K(c$,function(a){$_R(this,java.util.Collections.UnmodifiableSortedSet,[a]);this.ss=a},"java.util.SortedSet");
$_M(c$,"comparator",function(){return this.ss.comparator()});$_M(c$,"first",function(){return this.ss.first()});$_M(c$,"headSet",function(a){return new java.util.Collections.UnmodifiableSortedSet(this.ss.headSet(a))},"~O");$_M(c$,"last",function(){return this.ss.last()});$_M(c$,"subSet",function(a,b){return new java.util.Collections.UnmodifiableSortedSet(this.ss.subSet(a,b))},"~O,~O");$_M(c$,"tailSet",function(a){return new java.util.Collections.UnmodifiableSortedSet(this.ss.tailSet(a))},"~O");c$=
$_P();$_H();c$=$_C(function(){this.type=this.c=null;$_Z(this,arguments)},java.util.Collections,"CheckedCollection",null,[java.util.Collection,java.io.Serializable]);$_K(c$,function(a,b){if(null==a||null==b)throw new NullPointerException;this.c=a;this.type=b},"java.util.Collection,Class");$_M(c$,"size",function(){return this.c.size()});$_M(c$,"isEmpty",function(){return this.c.isEmpty()});$_M(c$,"contains",function(a){return this.c.contains(a)},"~O");$_M(c$,"iterator",function(){var a=this.c.iterator();
$_O(a,java.util.ListIterator)&&(a=new java.util.Collections.CheckedListIterator(a,this.type));return a});$_M(c$,"toArray",function(){return this.c.toArray()});$_M(c$,"toArray",function(a){return this.c.toArray(a)},"~A");$_M(c$,"add",function(a){return this.c.add(java.util.Collections.checkType(a,this.type))},"~O");$_M(c$,"remove",function(a){return this.c.remove(a)},"~O");$_M(c$,"containsAll",function(a){return this.c.containsAll(a)},"java.util.Collection");$_V(c$,"addAll",function(a){var b=a.size();
if(0==b)return!1;var c=Array(b);a=a.iterator();for(var d=0;d<b;d++)c[d]=java.util.Collections.checkType(a.next(),this.type);a=!1;for(d=0;d<b;d++)a=(new Boolean(a|this.c.add(c[d]))).valueOf();return a},"java.util.Collection");$_M(c$,"removeAll",function(a){return this.c.removeAll(a)},"java.util.Collection");$_M(c$,"retainAll",function(a){return this.c.retainAll(a)},"java.util.Collection");$_M(c$,"clear",function(){this.c.clear()});$_M(c$,"toString",function(){return this.c.toString()});c$=$_P();$_H();
c$=$_C(function(){this.type=this.i=null;$_Z(this,arguments)},java.util.Collections,"CheckedListIterator",null,java.util.ListIterator);$_K(c$,function(a,b){this.i=a;this.type=b},"java.util.ListIterator,Class");$_M(c$,"hasNext",function(){return this.i.hasNext()});$_M(c$,"next",function(){return this.i.next()});$_M(c$,"remove",function(){this.i.remove()});$_M(c$,"hasPrevious",function(){return this.i.hasPrevious()});$_M(c$,"previous",function(){return this.i.previous()});$_M(c$,"nextIndex",function(){return this.i.nextIndex()});
$_M(c$,"previousIndex",function(){return this.i.previousIndex()});$_M(c$,"set",function(a){this.i.set(java.util.Collections.checkType(a,this.type))},"~O");$_M(c$,"add",function(a){this.i.add(java.util.Collections.checkType(a,this.type))},"~O");c$=$_P();$_H();c$=$_C(function(){this.l=null;$_Z(this,arguments)},java.util.Collections,"CheckedList",java.util.Collections.CheckedCollection,java.util.List);$_K(c$,function(a,b){$_R(this,java.util.Collections.CheckedList,[a,b]);this.l=a},"java.util.List,Class");
$_M(c$,"addAll",function(a,b){var c=b.size();if(0==c)return!1;for(var d=Array(c),e=b.iterator(),f=0;f<c;f++)d[f]=java.util.Collections.checkType(e.next(),this.type);return this.l.addAll(a,java.util.Arrays.asList(d))},"~N,java.util.Collection");$_M(c$,"get",function(a){return this.l.get(a)},"~N");$_M(c$,"set",function(a,b){return this.l.set(a,java.util.Collections.checkType(b,this.type))},"~N,~O");$_M(c$,"add",function(a,b){this.l.add(a,java.util.Collections.checkType(b,this.type))},"~N,~O");$_M(c$,
"remove",function(a){return this.l.remove(a)},"~N");$_M(c$,"indexOf",function(a){return this.l.indexOf(a)},"~O");$_M(c$,"lastIndexOf",function(a){return this.l.lastIndexOf(a)},"~O");$_M(c$,"listIterator",function(){return new java.util.Collections.CheckedListIterator(this.l.listIterator(),this.type)});$_M(c$,"listIterator",function(a){return new java.util.Collections.CheckedListIterator(this.l.listIterator(a),this.type)},"~N");$_M(c$,"subList",function(a,b){return java.util.Collections.checkedList(this.l.subList(a,
b),this.type)},"~N,~N");$_V(c$,"equals",function(a){return this.l.equals(a)},"~O");$_V(c$,"hashcode",function(){return this.l.hashCode()});c$=$_P();$_H();c$=$_T(java.util.Collections,"CheckedRandomAccessList",java.util.Collections.CheckedList,java.util.RandomAccess);c$=$_P();$_H();c$=$_T(java.util.Collections,"CheckedSet",java.util.Collections.CheckedCollection,java.util.Set);$_V(c$,"equals",function(a){return this.c.equals(a)},"~O");$_V(c$,"hashCode",function(){return this.c.hashCode()});c$=$_P();
$_H();c$=$_C(function(){this.valueType=this.keyType=this.m=null;$_Z(this,arguments)},java.util.Collections,"CheckedMap",null,[java.util.Map,java.io.Serializable]);$_K(c$,($fz=function(a,b,c){if(null==a||null==b||null==c)throw new NullPointerException;this.m=a;this.keyType=b;this.valueType=c},$fz.isPrivate=!0,$fz),"java.util.Map,Class,Class");$_M(c$,"size",function(){return this.m.size()});$_M(c$,"isEmpty",function(){return this.m.isEmpty()});$_M(c$,"containsKey",function(a){return this.m.containsKey(a)},
"~O");$_M(c$,"containsValue",function(a){return this.m.containsValue(a)},"~O");$_M(c$,"get",function(a){return this.m.get(a)},"~O");$_M(c$,"put",function(a,b){return this.m.put(java.util.Collections.checkType(a,this.keyType),java.util.Collections.checkType(b,this.valueType))},"~O,~O");$_M(c$,"remove",function(a){return this.m.remove(a)},"~O");$_V(c$,"putAll",function(a){var b=a.size();if(0!=b){var c=Array(b);a=a.entrySet().iterator();for(var d=0;d<b;d++){var e=a.next();java.util.Collections.checkType(e.getKey(),
this.keyType);java.util.Collections.checkType(e.getValue(),this.valueType);c[d]=e}for(e=0;e<b;e++)this.m.put(c[e].getKey(),c[e].getValue())}},"java.util.Map");$_M(c$,"clear",function(){this.m.clear()});$_M(c$,"keySet",function(){return this.m.keySet()});$_M(c$,"values",function(){return this.m.values()});$_M(c$,"entrySet",function(){return new java.util.Collections.CheckedMap.CheckedEntrySet(this.m.entrySet(),this.valueType)});$_V(c$,"equals",function(a){return this.m.equals(a)},"~O");$_V(c$,"hashcode",
function(){return this.m.hashCode()});$_M(c$,"toString",function(){return this.m.toString()});$_H();c$=$_C(function(){this.valueType=this.e=null;$_Z(this,arguments)},java.util.Collections.CheckedMap,"CheckedEntry",null,java.util.Map.Entry);$_K(c$,function(a,b){if(null==a)throw new NullPointerException;this.e=a;this.valueType=b},"java.util.Map.Entry,Class");$_M(c$,"getKey",function(){return this.e.getKey()});$_M(c$,"getValue",function(){return this.e.getValue()});$_M(c$,"setValue",function(a){return this.e.setValue(java.util.Collections.checkType(a,
this.valueType))},"~O");$_V(c$,"equals",function(a){return this.e.equals(a)},"~O");$_V(c$,"hashcode",function(){return this.e.hashCode()});c$=$_P();$_H();c$=$_C(function(){this.valueType=this.s=null;$_Z(this,arguments)},java.util.Collections.CheckedMap,"CheckedEntrySet",null,java.util.Set);$_K(c$,function(a,b){this.s=a;this.valueType=b},"java.util.Set,Class");$_M(c$,"iterator",function(){return new java.util.Collections.CheckedMap.CheckedEntrySet.CheckedEntryIterator(this.s.iterator(),this.valueType)});
$_M(c$,"toArray",function(){for(var a=this.size(),b=Array(a),c=this.iterator(),d=0;d<a;d++)b[d]=c.next();return b});$_M(c$,"toArray",function(a){var b=this.size();if(a.length<b){var c=a.getClass().getComponentType();a=java.lang.reflect.Array.newInstance(c,b)}for(var c=this.iterator(),d=0;d<b;d++)a[d]=c.next();b<a.length&&(a[b]=null);return a},"~A");$_M(c$,"retainAll",function(a){return this.s.retainAll(a)},"java.util.Collection");$_M(c$,"removeAll",function(a){return this.s.removeAll(a)},"java.util.Collection");
$_M(c$,"containsAll",function(a){return this.s.containsAll(a)},"java.util.Collection");$_V(c$,"addAll",function(){throw new UnsupportedOperationException;},"java.util.Collection");$_M(c$,"remove",function(a){return this.s.remove(a)},"~O");$_M(c$,"contains",function(a){return this.s.contains(a)},"~O");$_V(c$,"add",function(){throw new UnsupportedOperationException;},"java.util.Map.Entry");$_M(c$,"isEmpty",function(){return this.s.isEmpty()});$_M(c$,"clear",function(){this.s.clear()});$_M(c$,"size",
function(){return this.s.size()});$_V(c$,"hashcode",function(){return this.s.hashCode()});$_V(c$,"equals",function(a){return this.s.equals(a)},"~O");$_H();c$=$_C(function(){this.valueType=this.i=null;$_Z(this,arguments)},java.util.Collections.CheckedMap.CheckedEntrySet,"CheckedEntryIterator",null,java.util.Iterator);$_K(c$,function(a,b){this.i=a;this.valueType=b},"java.util.Iterator,Class");$_M(c$,"hasNext",function(){return this.i.hasNext()});$_M(c$,"remove",function(){this.i.remove()});$_M(c$,"next",
function(){return new java.util.Collections.CheckedMap.CheckedEntry(this.i.next(),this.valueType)});c$=$_P();c$=$_P();c$=$_P();$_H();c$=$_C(function(){this.ss=null;$_Z(this,arguments)},java.util.Collections,"CheckedSortedSet",java.util.Collections.CheckedSet,java.util.SortedSet);$_K(c$,function(a,b){$_R(this,java.util.Collections.CheckedSortedSet,[a,b]);this.ss=a},"java.util.SortedSet,Class");$_M(c$,"comparator",function(){return this.ss.comparator()});$_M(c$,"subSet",function(a,b){return new java.util.Collections.CheckedSortedSet(this.ss.subSet(a,
b),this.type)},"~O,~O");$_M(c$,"headSet",function(a){return new java.util.Collections.CheckedSortedSet(this.ss.headSet(a),this.type)},"~O");$_M(c$,"tailSet",function(a){return new java.util.Collections.CheckedSortedSet(this.ss.tailSet(a),this.type)},"~O");$_M(c$,"first",function(){return this.ss.first()});$_M(c$,"last",function(){return this.ss.last()});c$=$_P();$_H();c$=$_C(function(){this.sm=null;$_Z(this,arguments)},java.util.Collections,"CheckedSortedMap",java.util.Collections.CheckedMap,java.util.SortedMap);
$_K(c$,function(a,b,c){$_R(this,java.util.Collections.CheckedSortedMap,[a,b,c]);this.sm=a},"java.util.SortedMap,Class,Class");$_M(c$,"comparator",function(){return this.sm.comparator()});$_M(c$,"subMap",function(a,b){return new java.util.Collections.CheckedSortedMap(this.sm.subMap(a,b),this.keyType,this.valueType)},"~O,~O");$_M(c$,"headMap",function(a){return new java.util.Collections.CheckedSortedMap(this.sm.headMap(a),this.keyType,this.valueType)},"~O");$_M(c$,"tailMap",function(a){return new java.util.Collections.CheckedSortedMap(this.sm.tailMap(a),
this.keyType,this.valueType)},"~O");$_M(c$,"firstKey",function(){return this.sm.firstKey()});$_M(c$,"lastKey",function(){return this.sm.lastKey()});c$=$_P();c$.EMPTY_LIST=c$.prototype.EMPTY_LIST=new java.util.Collections.EmptyList;c$.EMPTY_SET=c$.prototype.EMPTY_SET=new java.util.Collections.EmptySet;c$.EMPTY_MAP=c$.prototype.EMPTY_MAP=new java.util.Collections.EmptyMap}),$_L("java.util.Dictionary $.Enumeration $.Iterator $.Map $.MapEntry $.NoSuchElementException".split(" "),"java.util.Hashtable",
"java.lang.IllegalArgumentException $.IllegalStateException $.NullPointerException $.StringBuilder java.util.AbstractCollection $.AbstractSet $.Arrays $.Collections $.ConcurrentModificationException java.util.MapEntry.Type".split(" "),function(){c$=$_C(function(){this.elementCount=0;this.elementData=null;this.firstSlot=this.threshold=this.loadFactor=0;this.lastSlot=-1;this.modCount=0;$_D("java.util.Hashtable.HashIterator")||java.util.Hashtable.$Hashtable$HashIterator$();$_D("java.util.Hashtable.HashEnumerator")||
java.util.Hashtable.$Hashtable$HashEnumerator$();$_Z(this,arguments)},java.util,"Hashtable",java.util.Dictionary,[java.util.Map,Cloneable,java.io.Serializable]);c$.newEntry=$_M(c$,"newEntry",($fz=function(a,b){return new java.util.Hashtable.Entry(a,b)},$fz.isPrivate=!0,$fz),"~O,~O,~N");$_k(c$,function(){this.elementCount=0;this.elementData=this.newElementArray(11);this.firstSlot=this.elementData.length;this.loadFactor=0.75;this.computeMaxSize()});$_M(c$,"newElementArray",($fz=function(a){return Array(a)},
$fz.isPrivate=!0,$fz),"~N");$_V(c$,"clear",function(){this.elementCount=0;for(var a=this.elementData.length;0<=--a;)this.elementData[a]=null;this.modCount++});$_M(c$,"clone",function(){try{var a=$_U(this,java.util.Hashtable,"clone",[]);a.elementData=this.elementData.clone();for(var b,c=this.elementData.length;0<=--c;)if(null!=(b=this.elementData[c]))a.elementData[c]=b.clone();return a}catch(d){if($_O(d,CloneNotSupportedException))return null;throw d;}});$_M(c$,"computeMaxSize",($fz=function(){this.threshold=
Math.round(this.elementData.length*this.loadFactor)},$fz.isPrivate=!0,$fz));$_M(c$,"contains",function(a){if(null==a)throw new NullPointerException;for(var b=this.elementData.length;0<=--b;)for(var c=this.elementData[b];null!=c;){if(a.equals(c.value))return!0;c=c.next}return!1},"~O");$_V(c$,"containsKey",function(a){return null!=this.getEntry(a)},"~O");$_V(c$,"containsValue",function(a){return this.contains(a)},"~O");$_V(c$,"elements",function(){return 0==this.elementCount?java.util.Hashtable.EMPTY_ENUMERATION:
$_N(java.util.Hashtable.HashEnumerator,this,null,!1)});$_V(c$,"entrySet",function(){return new java.util.Collections.SynchronizedSet(($_D("java.util.Hashtable$2")?0:java.util.Hashtable.$Hashtable$2$(),$_N(java.util.Hashtable$2,this,null)),this)});$_V(c$,"equals",function(a){if(this===a)return!0;if($_O(a,java.util.Map)){if(this.size()!=a.size())return!1;var b=this.entrySet(),c;for(a=a.entrySet().iterator();a.hasNext()&&((c=a.next())||1);)if(!b.contains(c))return!1;return!0}return!1},"~O");$_V(c$,"get",
function(a){for(var b=a.hashCode(),c=this.elementData[(b&2147483647)%this.elementData.length];null!=c;){if(c.equalsKey(a,b))return c.value;c=c.next}return null},"~O");$_M(c$,"getEntry",function(a){for(var b=a.hashCode(),c=this.elementData[(b&2147483647)%this.elementData.length];null!=c;){if(c.equalsKey(a,b))return c;c=c.next}return null},"~O");$_V(c$,"hashCode",function(){for(var a=0,b=this.entrySet().iterator();b.hasNext();)var c=b.next(),d=c.getKey(),c=c.getValue(),d=(d!==this?d.hashCode():0)^(c!==
this?null!=c?c.hashCode():0:0),a=a+d;return a});$_V(c$,"isEmpty",function(){return 0==this.elementCount});$_V(c$,"keys",function(){return 0==this.elementCount?java.util.Hashtable.EMPTY_ENUMERATION:$_N(java.util.Hashtable.HashEnumerator,this,null,!0)});$_V(c$,"keySet",function(){return new java.util.Collections.SynchronizedSet(($_D("java.util.Hashtable$3")?0:java.util.Hashtable.$Hashtable$3$(),$_N(java.util.Hashtable$3,this,null)),this)});$_V(c$,"put",function(a,b){if(null!=a&&null!=b){for(var c=a.hashCode(),
d=(c&2147483647)%this.elementData.length,e=this.elementData[d];null!=e&&!e.equalsKey(a,c);)e=e.next;if(null==e)return this.modCount++,++this.elementCount>this.threshold&&(this.rehash(),d=(c&2147483647)%this.elementData.length),d<this.firstSlot&&(this.firstSlot=d),d>this.lastSlot&&(this.lastSlot=d),e=java.util.Hashtable.newEntry(a,b,c),e.next=this.elementData[d],this.elementData[d]=e,null;c=e.value;e.value=b;return c}throw new NullPointerException;},"~O,~O");$_V(c$,"putAll",function(a){var b;for(a=
a.entrySet().iterator();a.hasNext()&&((b=a.next())||1);)this.put(b.getKey(),b.getValue())},"java.util.Map");$_M(c$,"rehash",function(){var a=(this.elementData.length<<1)+1;0==a&&(a=1);for(var b=a,c=-1,d=this.newElementArray(a),e=this.lastSlot+1;--e>=this.firstSlot;)for(var f=this.elementData[e];null!=f;){var g=(f.getKeyHash()&2147483647)%a;g<b&&(b=g);g>c&&(c=g);var h=f.next;f.next=d[g];d[g]=f;f=h}this.firstSlot=b;this.lastSlot=c;this.elementData=d;this.computeMaxSize()});$_V(c$,"remove",function(a){for(var b=
a.hashCode(),c=(b&2147483647)%this.elementData.length,d=null,e=this.elementData[c];null!=e&&!e.equalsKey(a,b);)d=e,e=e.next;return null!=e?(this.modCount++,null==d?this.elementData[c]=e.next:d.next=e.next,this.elementCount--,a=e.value,e.value=null,a):null},"~O");$_V(c$,"size",function(){return this.elementCount});$_V(c$,"toString",function(){if(this.isEmpty())return"{}";var a=new StringBuilder(28*this.size());a.append("{");for(var b=this.lastSlot;b>=this.firstSlot;b--)for(var c=this.elementData[b];null!=
c;)c.key!==this?a.append(c.key):a.append("(this Map)"),a.append("="),c.value!==this?a.append(c.value):a.append("(this Map)"),a.append(", "),c=c.next;0<this.elementCount&&a.setLength(a.length()-2);a.append("}");return a.toString()});$_V(c$,"values",function(){return new java.util.Collections.SynchronizedCollection(($_D("java.util.Hashtable$4")?0:java.util.Hashtable.$Hashtable$4$(),$_N(java.util.Hashtable$4,this,null)),this)});c$.$Hashtable$HashIterator$=function(){$_H();c$=$_C(function(){$_B(this,
arguments);this.expectedModCount=this.position=0;this.lastEntry=this.type=null;this.lastPosition=0;this.canRemove=!1;$_Z(this,arguments)},java.util.Hashtable,"HashIterator",null,java.util.Iterator);$_K(c$,function(a){this.type=a;this.position=this.b$["java.util.Hashtable"].lastSlot;this.expectedModCount=this.b$["java.util.Hashtable"].modCount},"java.util.MapEntry.Type");$_V(c$,"hasNext",function(){if(null!=this.lastEntry&&null!=this.lastEntry.next)return!0;for(;this.position>=this.b$["java.util.Hashtable"].firstSlot;)if(null==
this.b$["java.util.Hashtable"].elementData[this.position])this.position--;else return!0;return!1});$_V(c$,"next",function(){if(this.expectedModCount==this.b$["java.util.Hashtable"].modCount){null!=this.lastEntry&&(this.lastEntry=this.lastEntry.next);if(null==this.lastEntry){for(;this.position>=this.b$["java.util.Hashtable"].firstSlot&&null==(this.lastEntry=this.b$["java.util.Hashtable"].elementData[this.position]);)this.position--;null!=this.lastEntry&&(this.lastPosition=this.position,this.position--)}if(null!=
this.lastEntry)return this.canRemove=!0,this.type.get(this.lastEntry);throw new java.util.NoSuchElementException;}throw new java.util.ConcurrentModificationException;});$_V(c$,"remove",function(){if(this.expectedModCount==this.b$["java.util.Hashtable"].modCount)if(this.canRemove){var a=this.canRemove=!1,b=this.b$["java.util.Hashtable"].elementData[this.lastPosition];if(b===this.lastEntry)this.b$["java.util.Hashtable"].elementData[this.lastPosition]=b.next,a=!0;else{for(;null!=b&&b.next!==this.lastEntry;)b=
b.next;null!=b&&(b.next=this.lastEntry.next,a=!0)}if(a){this.b$["java.util.Hashtable"].modCount++;this.b$["java.util.Hashtable"].elementCount--;this.expectedModCount++;return}}else throw new IllegalStateException;throw new java.util.ConcurrentModificationException;});c$=$_P()};c$.$Hashtable$HashEnumerator$=function(){$_H();c$=$_C(function(){$_B(this,arguments);this.key=!1;this.start=0;this.entry=null;$_Z(this,arguments)},java.util.Hashtable,"HashEnumerator",null,java.util.Enumeration);$_K(c$,function(a){this.key=
a;this.start=this.b$["java.util.Hashtable"].lastSlot+1},"~B");$_V(c$,"hasMoreElements",function(){if(null!=this.entry)return!0;for(;--this.start>=this.b$["java.util.Hashtable"].firstSlot;)if(null!=this.b$["java.util.Hashtable"].elementData[this.start])return this.entry=this.b$["java.util.Hashtable"].elementData[this.start],!0;return!1});$_V(c$,"nextElement",function(){if(this.hasMoreElements()){var a=this.key?this.entry.key:this.entry.value;this.entry=this.entry.next;return a}throw new java.util.NoSuchElementException;
});c$=$_P()};c$.$Hashtable$2$=function(){$_H();c$=$_W(java.util,"Hashtable$2",java.util.AbstractSet);$_V(c$,"size",function(){return this.b$["java.util.Hashtable"].elementCount});$_V(c$,"clear",function(){this.b$["java.util.Hashtable"].clear()});$_V(c$,"remove",function(a){return this.contains(a)?(this.b$["java.util.Hashtable"].remove(a.getKey()),!0):!1},"~O");$_M(c$,"contains",function(a){var b=this.b$["java.util.Hashtable"].getEntry(a.getKey());return a.equals(b)},"~O");$_M(c$,"iterator",function(){return $_N(java.util.Hashtable.HashIterator,
this,null,($_D("java.util.Hashtable$2$1")?0:java.util.Hashtable.$Hashtable$2$1$(),$_N(java.util.Hashtable$2$1,this,null)))});c$=$_P()};c$.$Hashtable$2$1$=function(){$_H();c$=$_W(java.util,"Hashtable$2$1",null,java.util.MapEntry.Type);$_V(c$,"get",function(a){return a},"java.util.MapEntry");c$=$_P()};c$.$Hashtable$3$=function(){$_H();c$=$_W(java.util,"Hashtable$3",java.util.AbstractSet);$_V(c$,"contains",function(a){return this.b$["java.util.Hashtable"].containsKey(a)},"~O");$_V(c$,"size",function(){return this.b$["java.util.Hashtable"].elementCount});
$_V(c$,"clear",function(){this.b$["java.util.Hashtable"].clear()});$_V(c$,"remove",function(a){return this.b$["java.util.Hashtable"].containsKey(a)?(this.b$["java.util.Hashtable"].remove(a),!0):!1},"~O");$_V(c$,"iterator",function(){return $_N(java.util.Hashtable.HashIterator,this,null,($_D("java.util.Hashtable$3$1")?0:java.util.Hashtable.$Hashtable$3$1$(),$_N(java.util.Hashtable$3$1,this,null)))});c$=$_P()};c$.$Hashtable$3$1$=function(){$_H();c$=$_W(java.util,"Hashtable$3$1",null,java.util.MapEntry.Type);
$_V(c$,"get",function(a){return a.key},"java.util.MapEntry");c$=$_P()};c$.$Hashtable$4$=function(){$_H();c$=$_W(java.util,"Hashtable$4",java.util.AbstractCollection);$_V(c$,"contains",function(a){return this.b$["java.util.Hashtable"].contains(a)},"~O");$_V(c$,"size",function(){return this.b$["java.util.Hashtable"].elementCount});$_V(c$,"clear",function(){this.b$["java.util.Hashtable"].clear()});$_V(c$,"iterator",function(){return $_N(java.util.Hashtable.HashIterator,this,null,($_D("java.util.Hashtable$4$1")?
0:java.util.Hashtable.$Hashtable$4$1$(),$_N(java.util.Hashtable$4$1,this,null)))});c$=$_P()};c$.$Hashtable$4$1$=function(){$_H();c$=$_W(java.util,"Hashtable$4$1",null,java.util.MapEntry.Type);$_V(c$,"get",function(a){return a.value},"java.util.MapEntry");c$=$_P()};c$.$Hashtable$1$=function(){$_H();c$=$_W(java.util,"Hashtable$1",null,java.util.Enumeration);$_V(c$,"hasMoreElements",function(){return!1});$_V(c$,"nextElement",function(){throw new java.util.NoSuchElementException;});c$=$_P()};$_H();c$=
$_C(function(){this.next=null;this.hashcode=0;$_Z(this,arguments)},java.util.Hashtable,"Entry",java.util.MapEntry);$_k(c$,function(a,b){this.key=a;this.value=b;this.hashcode=a.hashCode()});$_M(c$,"clone",function(){var a=$_U(this,java.util.Hashtable.Entry,"clone",[]);null!=this.next&&(a.next=this.next.clone());return a});$_V(c$,"setValue",function(a){if(null==a)throw new NullPointerException;var b=this.value;this.value=a;return b},"~O");$_M(c$,"getKeyHash",function(){return this.key.hashCode()});
$_M(c$,"equalsKey",function(a){return this.hashcode==a.hashCode()&&this.key.equals(a)},"~O,~N");$_V(c$,"toString",function(){return this.key+"="+this.value});c$=$_P();c$.EMPTY_ENUMERATION=c$.prototype.EMPTY_ENUMERATION=($_D("java.util.Hashtable$1")?0:java.util.Hashtable.$Hashtable$1$(),$_N(java.util.Hashtable$1,this,null))}),Clazz.declarePackage("javajs.awt"),c$=Clazz.decorateAsClass(function(){this.height=this.width=0;Clazz.instantialize(this,arguments)},javajs.awt,"Dimension"),Clazz.makeConstructor(c$,
function(a,b){this.set(a,b)},"~N,~N"),$_M(c$,"set",function(a,b){this.width=a;this.height=b;return this},"~N,~N"),Clazz.load(null,"java.io.InputStream",["java.io.IOException","java.lang.IndexOutOfBoundsException","$.NullPointerException"],function(){c$=Clazz.declareType(java.io,"InputStream");$_M(c$,"read",function(a,b,c){if(null==a)throw new NullPointerException;if(0>b||0>c||c>a.length-b)throw new IndexOutOfBoundsException;if(0==c)return 0;var d=this.readByteAsInt();if(-1==d)return-1;a[b]=d;var e=
1;try{for(;e<c;e++){d=this.readByteAsInt();if(-1==d)break;a[b+e]=d}}catch(f){if(!Clazz.exceptionOf(f,java.io.IOException))throw f;}return e},"~A,~N,~N");$_M(c$,"skip",function(a){var b=a,c;null==java.io.InputStream.skipBuffer&&($t$=java.io.InputStream.skipBuffer=Clazz.newByteArray(2048,0),java.io.InputStream.prototype.skipBuffer=java.io.InputStream.skipBuffer,$t$);var d=java.io.InputStream.skipBuffer;if(0>=a)return 0;for(;0<b;){c=this.read(d,0,Math.min(2048,b));if(0>c)break;b-=c}return a-b},"~N");
$_M(c$,"available",function(){return 0});$_M(c$,"close",function(){});$_M(c$,"mark",function(){},"~N");$_M(c$,"reset",function(){throw new java.io.IOException("mark/reset not supported");});$_M(c$,"markSupported",function(){return!1});$_M(c$,"resetStream",function(){});Clazz.defineStatics(c$,"SKIP_BUFFER_SIZE",2048,"skipBuffer",null)}),Clazz.load(["java.io.InputStream"],"java.io.ByteArrayInputStream",["java.lang.IndexOutOfBoundsException","$.NullPointerException"],function(){c$=Clazz.decorateAsClass(function(){this.buf=
null;this.count=this.$mark=this.pos=0;Clazz.instantialize(this,arguments)},java.io,"ByteArrayInputStream",java.io.InputStream);Clazz.makeConstructor(c$,function(a){Clazz.superConstructor(this,java.io.ByteArrayInputStream,[]);this.buf=a;this.pos=0;this.count=a.length},"~A");Clazz.overrideMethod(c$,"readByteAsInt",function(){return this.pos<this.count?this.buf[this.pos++]&255:-1});Clazz.overrideMethod(c$,"read",function(a,b,c){if(null==a)throw new NullPointerException;if(0>b||0>c||c>a.length-b)throw new IndexOutOfBoundsException;
if(this.pos>=this.count)return-1;var d=this.count-this.pos;c>d&&(c=d);if(0>=c)return 0;System.arraycopy(this.buf,this.pos,a,b,c);this.pos+=c;return c},"~A,~N,~N");Clazz.overrideMethod(c$,"skip",function(a){var b=this.count-this.pos;a<b&&(b=0>a?0:a);this.pos+=b;return b},"~N");Clazz.overrideMethod(c$,"available",function(){return this.count-this.pos});Clazz.overrideMethod(c$,"markSupported",function(){return!0});Clazz.overrideMethod(c$,"mark",function(){this.$mark=this.pos},"~N");Clazz.overrideMethod(c$,
"resetStream",function(){});Clazz.overrideMethod(c$,"reset",function(){this.pos=this.$mark});Clazz.overrideMethod(c$,"close",function(){})}),Clazz.load(["java.io.InputStream"],"java.io.FilterInputStream",null,function(){c$=Clazz.decorateAsClass(function(){this.$in=null;Clazz.instantialize(this,arguments)},java.io,"FilterInputStream",java.io.InputStream);Clazz.makeConstructor(c$,function(a){Clazz.superConstructor(this,java.io.FilterInputStream,[]);this.$in=a},"java.io.InputStream");$_M(c$,"readByteAsInt",
function(){return this.$in.readByteAsInt()});$_M(c$,"read",function(a,b,c){return this.$in.read(a,b,c)},"~A,~N,~N");$_M(c$,"skip",function(a){return this.$in.skip(a)},"~N");$_M(c$,"available",function(){return this.$in.available()});$_M(c$,"close",function(){this.$in.close()});$_M(c$,"mark",function(a){this.$in.mark(a)},"~N");$_M(c$,"reset",function(){this.$in.reset()});$_M(c$,"markSupported",function(){return this.$in.markSupported()})}),Clazz.load(["java.io.FilterInputStream"],"java.io.BufferedInputStream",
["java.io.IOException","java.lang.IndexOutOfBoundsException"],function(){c$=Clazz.decorateAsClass(function(){this.buf=null;this.pos=this.count=0;this.markpos=-1;this.marklimit=0;Clazz.instantialize(this,arguments)},java.io,"BufferedInputStream",java.io.FilterInputStream);$_M(c$,"getInIfOpen",($fz=function(){var a=this.$in;if(null==a)throw new java.io.IOException("Stream closed");return a},$fz.isPrivate=!0,$fz));$_M(c$,"getBufIfOpen",($fz=function(){var a=this.buf;if(null==a)throw new java.io.IOException("Stream closed");
return a},$fz.isPrivate=!0,$fz));Clazz.overrideMethod(c$,"resetStream",function(){});Clazz.makeConstructor(c$,function(a){Clazz.superConstructor(this,java.io.BufferedInputStream,[a]);this.buf=Clazz.newByteArray(java.io.BufferedInputStream.defaultBufferSize,0)},"java.io.InputStream");$_M(c$,"fill",($fz=function(){var a=this.getBufIfOpen();if(0>this.markpos)this.pos=0;else if(this.pos>=a.length)if(0<this.markpos){var b=this.pos-this.markpos;System.arraycopy(a,this.markpos,a,0,b);this.pos=b;this.markpos=
0}else a.length>=this.marklimit?(this.markpos=-1,this.pos=0):(b=2*this.pos,b>this.marklimit&&(b=this.marklimit),b=Clazz.newByteArray(b,0),System.arraycopy(a,0,b,0,this.pos),a=this.buf=b);this.count=this.pos;a=this.getInIfOpen().read(a,this.pos,a.length-this.pos);0<a&&(this.count=a+this.pos)},$fz.isPrivate=!0,$fz));Clazz.overrideMethod(c$,"readByteAsInt",function(){return this.pos>=this.count&&(this.fill(),this.pos>=this.count)?-1:this.getBufIfOpen()[this.pos++]&255});$_M(c$,"read1",($fz=function(a,
b,c){var d=this.count-this.pos;if(0>=d){if(c>=this.getBufIfOpen().length&&0>this.markpos)return this.getInIfOpen().read(a,b,c);this.fill();d=this.count-this.pos;if(0>=d)return-1}c=d<c?d:c;System.arraycopy(this.getBufIfOpen(),this.pos,a,b,c);this.pos+=c;return c},$fz.isPrivate=!0,$fz),"~A,~N,~N");Clazz.overrideMethod(c$,"read",function(a,b,c){this.getBufIfOpen();if(0>(b|c|b+c|a.length-(b+c)))throw new IndexOutOfBoundsException;if(0==c)return 0;for(var d=0;;){var e=this.read1(a,b+d,c-d);if(0>=e)return 0==
d?e:d;d+=e;if(d>=c)return d;e=this.$in;if(null!=e&&0>=e.available())return d}},"~A,~N,~N");Clazz.overrideMethod(c$,"skip",function(a){this.getBufIfOpen();if(0>=a)return 0;var b=this.count-this.pos;if(0>=b){if(0>this.markpos)return this.getInIfOpen().skip(a);this.fill();b=this.count-this.pos;if(0>=b)return 0}a=b<a?b:a;this.pos+=a;return a},"~N");Clazz.overrideMethod(c$,"available",function(){var a=this.count-this.pos,b=this.getInIfOpen().available();return a>2147483647-b?2147483647:a+b});Clazz.overrideMethod(c$,
"mark",function(a){this.marklimit=a;this.markpos=this.pos},"~N");Clazz.overrideMethod(c$,"reset",function(){this.getBufIfOpen();if(0>this.markpos)throw new java.io.IOException("Resetting to invalid mark");this.pos=this.markpos});Clazz.overrideMethod(c$,"markSupported",function(){return!0});Clazz.overrideMethod(c$,"close",function(){var a=this.$in;this.$in=null;null!=a&&a.close()});Clazz.defineStatics(c$,"defaultBufferSize",8192)}),Clazz.load(["java.io.Closeable"],"java.io.Reader",["java.io.IOException",
"java.lang.IllegalArgumentException","$.NullPointerException"],function(){c$=Clazz.decorateAsClass(function(){this.skipBuffer=this.lock=null;Clazz.instantialize(this,arguments)},java.io,"Reader",null,java.io.Closeable);Clazz.makeConstructor(c$,function(a){if(null==a)throw new NullPointerException;this.lock=a},"~O");$_M(c$,"skip",function(a){if(0>a)throw new IllegalArgumentException("skip value is negative");var b=Math.min(a,8192);if(null==this.skipBuffer||this.skipBuffer.length<b)this.skipBuffer=
Clazz.newCharArray(b,"\x00");for(var c=a;0<c;){var d=this.read(this.skipBuffer,0,Math.min(c,b));if(-1==d)break;c-=d}return a-c},"~N");$_M(c$,"ready",function(){return!1});$_M(c$,"markSupported",function(){return!1});$_M(c$,"mark",function(){throw new java.io.IOException("mark() not supported");},"~N");$_M(c$,"reset",function(){throw new java.io.IOException("reset() not supported");});Clazz.defineStatics(c$,"maxSkipBufferSize",8192)}),Clazz.load(["java.io.Reader"],"java.io.InputStreamReader",["java.lang.NullPointerException"],
function(){c$=Clazz.decorateAsClass(function(){this.$in=null;this.isOpen=!0;this.charsetName=null;this.isUTF8=!1;this.bytearr=null;this.pos=0;Clazz.instantialize(this,arguments)},java.io,"InputStreamReader",java.io.Reader);Clazz.makeConstructor(c$,function(a,b){Clazz.superConstructor(this,java.io.InputStreamReader,[a]);this.$in=a;this.charsetName=b;if(!(this.isUTF8="UTF-8".equals(b))&&!"ISO-8859-1".equals(b))throw new NullPointerException("charsetName");},"java.io.InputStream,~S");$_M(c$,"getEncoding",
function(){return this.charsetName});Clazz.overrideMethod(c$,"read",function(a,b,c){if(null==this.bytearr||this.bytearr.length<c)this.bytearr=Clazz.newByteArray(c,0);var d,e,f=0,g=b,h=this.$in.read(this.bytearr,this.pos,c-this.pos),k=this.$in.available();if(0>h)return-1;for(var l=h;f<l;){c=this.bytearr[f]&255;if(this.isUTF8)switch(c>>4){case 12:case 13:if(f+1>=h){if(1<=k){l=f;continue}}else if(128==((d=this.bytearr[f+1])&192)){a[g++]=String.fromCharCode((c&31)<<6|d&63);f+=2;continue}this.isUTF8=!1;
break;case 14:if(f+2>=h){if(2<=k){l=f;continue}}else if(128==((d=this.bytearr[f+1])&192)&&128==((e=this.bytearr[f+2])&192)){a[g++]=String.fromCharCode((c&15)<<12|(d&63)<<6|e&63);f+=3;continue}this.isUTF8=!1}f++;a[g++]=String.fromCharCode(c)}this.pos=h-f;for(a=0;a<this.pos;a++)this.bytearr[a]=this.bytearr[f++];return g-b},"~A,~N,~N");Clazz.overrideMethod(c$,"ready",function(){return this.isOpen});Clazz.overrideMethod(c$,"close",function(){this.$in.close();this.isOpen=!1})}),Clazz.load(["java.io.Reader"],
"java.io.BufferedReader",["java.io.IOException","java.lang.IllegalArgumentException","$.IndexOutOfBoundsException","JU.SB"],function(){c$=Clazz.decorateAsClass(function(){this.cb=this.$in=null;this.nextChar=this.nChars=0;this.markedChar=-1;this.readAheadLimit=0;this.markedSkipLF=this.skipLF=!1;Clazz.instantialize(this,arguments)},java.io,"BufferedReader",java.io.Reader);$_M(c$,"setSize",($fz=function(a){if(0>=a)throw new IllegalArgumentException("Buffer size <= 0");this.cb=Clazz.newCharArray(a,"\x00");
this.nextChar=this.nChars=0},$fz.isPrivate=!0,$fz),"~N");Clazz.makeConstructor(c$,function(a){Clazz.superConstructor(this,java.io.BufferedReader,[a]);this.$in=a;this.setSize(java.io.BufferedReader.defaultCharBufferSize)},"java.io.Reader");$_M(c$,"ensureOpen",($fz=function(){if(null==this.$in)throw new java.io.IOException("Stream closed");},$fz.isPrivate=!0,$fz));$_M(c$,"fill",($fz=function(){var a;if(-1>=this.markedChar)a=0;else{var b=this.nextChar-this.markedChar;b>=this.readAheadLimit?(this.markedChar=
-2,a=this.readAheadLimit=0):(this.readAheadLimit<=this.cb.length?System.arraycopy(this.cb,this.markedChar,this.cb,0,b):(a=Clazz.newCharArray(this.readAheadLimit,"\x00"),System.arraycopy(this.cb,this.markedChar,a,0,b),this.cb=a),this.markedChar=0,this.nextChar=this.nChars=a=b)}do b=this.$in.read(this.cb,a,this.cb.length-a);while(0==b);0<b&&(this.nChars=a+b,this.nextChar=a)},$fz.isPrivate=!0,$fz));$_M(c$,"read1",($fz=function(a,b,c){if(this.nextChar>=this.nChars){if(c>=this.cb.length&&-1>=this.markedChar&&
!this.skipLF)return this.$in.read(a,b,c);this.fill()}if(this.nextChar>=this.nChars||this.skipLF&&(this.skipLF=!1,"\n"==this.cb[this.nextChar]&&(this.nextChar++,this.nextChar>=this.nChars&&this.fill(),this.nextChar>=this.nChars)))return-1;c=Math.min(c,this.nChars-this.nextChar);System.arraycopy(this.cb,this.nextChar,a,b,c);this.nextChar+=c;return c},$fz.isPrivate=!0,$fz),"~A,~N,~N");$_M(c$,"read",function(a,b,c){this.ensureOpen();if(0>b||b>a.length||0>c||b+c>a.length||0>b+c)throw new IndexOutOfBoundsException;
if(0==c)return 0;var d=this.read1(a,b,c);if(0>=d)return d;for(;d<c&&this.$in.ready();){var e=this.read1(a,b+d,c-d);if(0>=e)break;d+=e}return d},"~A,~N,~N");$_M(c$,"readLine1",($fz=function(a){var b=null,c;this.ensureOpen();for(var d=a||this.skipLF;;){this.nextChar>=this.nChars&&this.fill();if(this.nextChar>=this.nChars)return null!=b&&0<b.length()?b.toString():null;var e=!1;a=String.fromCharCode(0);var f;d&&"\n"==this.cb[this.nextChar]&&this.nextChar++;d=this.skipLF=!1;f=this.nextChar;a:for(;f<this.nChars;f++)if(a=
this.cb[f],"\n"==a||"\r"==a){e=!0;break a}c=this.nextChar;this.nextChar=f;if(e)return null==b?b=String.instantialize(this.cb,c,f-c):(b.appendCB(this.cb,c,f-c),b=b.toString()),this.nextChar++,"\r"==a&&(this.skipLF=!0),b;null==b&&(b=JU.SB.newN(java.io.BufferedReader.defaultExpectedLineLength));b.appendCB(this.cb,c,f-c)}},$fz.isPrivate=!0,$fz),"~B");$_M(c$,"readLine",function(){return this.readLine1(!1)});Clazz.overrideMethod(c$,"skip",function(a){if(0>a)throw new IllegalArgumentException("skip value is negative");
this.ensureOpen();for(var b=a;0<b;){this.nextChar>=this.nChars&&this.fill();if(this.nextChar>=this.nChars)break;this.skipLF&&(this.skipLF=!1,"\n"==this.cb[this.nextChar]&&this.nextChar++);var c=this.nChars-this.nextChar;if(b<=c){this.nextChar+=b;b=0;break}b-=c;this.nextChar=this.nChars}return a-b},"~N");$_M(c$,"ready",function(){this.ensureOpen();this.skipLF&&(this.nextChar>=this.nChars&&this.$in.ready()&&this.fill(),this.nextChar<this.nChars&&("\n"==this.cb[this.nextChar]&&this.nextChar++,this.skipLF=
!1));return this.nextChar<this.nChars||this.$in.ready()});Clazz.overrideMethod(c$,"markSupported",function(){return!0});Clazz.overrideMethod(c$,"mark",function(a){if(0>a)throw new IllegalArgumentException("Read-ahead limit < 0");this.ensureOpen();this.readAheadLimit=a;this.markedChar=this.nextChar;this.markedSkipLF=this.skipLF},"~N");Clazz.overrideMethod(c$,"reset",function(){this.ensureOpen();if(0>this.markedChar)throw new java.io.IOException(-2==this.markedChar?"Mark invalid":"Stream not marked");
this.nextChar=this.markedChar;this.skipLF=this.markedSkipLF});$_M(c$,"close",function(){null!=this.$in&&(this.$in.close(),this.cb=this.$in=null)});Clazz.defineStatics(c$,"INVALIDATED",-2,"UNMARKED",-1,"defaultCharBufferSize",8192,"defaultExpectedLineLength",80)}),Clazz.load(["java.io.Reader"],"java.io.StringReader",["java.io.IOException","java.lang.IllegalArgumentException","$.IndexOutOfBoundsException"],function(){c$=Clazz.decorateAsClass(function(){this.str=null;this.$mark=this.next=this.length=
0;Clazz.instantialize(this,arguments)},java.io,"StringReader",java.io.Reader);Clazz.makeConstructor(c$,function(a){Clazz.superConstructor(this,java.io.StringReader,[a]);this.str=a;this.length=a.length},"~S");$_M(c$,"ensureOpen",($fz=function(){if(null==this.str)throw new java.io.IOException("Stream closed");},$fz.isPrivate=!0,$fz));Clazz.overrideMethod(c$,"read",function(a,b,c){this.ensureOpen();if(0>b||b>a.length||0>c||b+c>a.length||0>b+c)throw new IndexOutOfBoundsException;if(0==c)return 0;if(this.next>=
this.length)return-1;c=Math.min(this.length-this.next,c);this.str.getChars(this.next,this.next+c,a,b);this.next+=c;return c},"~A,~N,~N");Clazz.overrideMethod(c$,"skip",function(a){this.ensureOpen();if(this.next>=this.length)return 0;a=Math.min(this.length-this.next,a);a=Math.max(-this.next,a);this.next+=a;return a},"~N");Clazz.overrideMethod(c$,"ready",function(){this.ensureOpen();return!0});Clazz.overrideMethod(c$,"markSupported",function(){return!0});Clazz.overrideMethod(c$,"mark",function(a){if(0>
a)throw new IllegalArgumentException("Read-ahead limit < 0");this.ensureOpen();this.$mark=this.next},"~N");Clazz.overrideMethod(c$,"reset",function(){this.ensureOpen();this.next=this.$mark});Clazz.overrideMethod(c$,"close",function(){this.str=null})}),Clazz.load(["java.io.Closeable","$.Flushable"],"java.io.OutputStream",["java.lang.IndexOutOfBoundsException","$.NullPointerException"],function(){c$=Clazz.declareType(java.io,"OutputStream",null,[java.io.Closeable,java.io.Flushable]);$_M(c$,"write",
function(a,b,c){if(null==a)throw new NullPointerException;if(0>b||b>a.length||0>c||b+c>a.length||0>b+c)throw new IndexOutOfBoundsException;if(0!=c)for(var d=0;d<c;d++)this.writeByteAsInt(a[b+d])},"~A,~N,~N");Clazz.overrideMethod(c$,"flush",function(){});Clazz.overrideMethod(c$,"close",function(){})}),Clazz.load(["java.io.OutputStream"],"java.io.ByteArrayOutputStream",["java.lang.IllegalArgumentException","$.IndexOutOfBoundsException","$.OutOfMemoryError"],function(){c$=Clazz.decorateAsClass(function(){this.buf=
null;this.count=0;Clazz.instantialize(this,arguments)},java.io,"ByteArrayOutputStream",java.io.OutputStream);Clazz.makeConstructor(c$,function(){this.construct(32)});Clazz.makeConstructor(c$,function(a){Clazz.superConstructor(this,java.io.ByteArrayOutputStream,[]);if(0>a)throw new IllegalArgumentException("Negative initial size: "+a);this.buf=Clazz.newByteArray(a,0)},"~N");$_M(c$,"ensureCapacity",($fz=function(a){0<a-this.buf.length&&this.grow(a)},$fz.isPrivate=!0,$fz),"~N");$_M(c$,"grow",($fz=function(a){var b=
this.buf.length<<1;0>b-a&&(b=a);if(0>b){if(0>a)throw new OutOfMemoryError;b=a}this.buf=java.io.ByteArrayOutputStream.arrayCopyByte(this.buf,b)},$fz.isPrivate=!0,$fz),"~N");c$.arrayCopyByte=$_M(c$,"arrayCopyByte",($fz=function(a,b){var c=Clazz.newByteArray(b,0);System.arraycopy(a,0,c,0,a.length<b?a.length:b);return c},$fz.isPrivate=!0,$fz),"~A,~N");Clazz.overrideMethod(c$,"writeByteAsInt",function(a){this.ensureCapacity(this.count+1);this.buf[this.count]=a;this.count+=1},"~N");$_M(c$,"write",function(a,
b,c){if(0>b||b>a.length||0>c||0<b+c-a.length)throw new IndexOutOfBoundsException;this.ensureCapacity(this.count+c);System.arraycopy(a,b,this.buf,this.count,c);this.count+=c},"~A,~N,~N");$_M(c$,"writeTo",function(a){a.write(this.buf,0,this.count)},"java.io.OutputStream");$_M(c$,"reset",function(){this.count=0});$_M(c$,"toByteArray",function(){return this.count==this.buf.length?this.buf:java.io.ByteArrayOutputStream.arrayCopyByte(this.buf,this.count)});$_M(c$,"size",function(){return this.count});Clazz.overrideMethod(c$,
"toString",function(){return String.instantialize(this.buf,0,this.count)});Clazz.overrideMethod(c$,"close",function(){})}),Clazz.declarePackage("java.net"),Clazz.load(["java.io.IOException"],"java.net.MalformedURLException",null,function(){c$=Clazz.declareType(java.net,"MalformedURLException",java.io.IOException);Clazz.makeConstructor(c$,function(){Clazz.superConstructor(this,java.net.MalformedURLException,[])})}),$_J("java.net"),c$=$_T(java.net,"URLEncoder"),c$.encode=$_M(c$,"encode",function(a){return encodeURIComponent(a)},
"~S"),c$.encode=$_M(c$,"encode",function(a){return encodeURIComponent(a)},"~S,~S"),$_S(c$,"digits","0123456789ABCDEF"),$_J("java.net"),$_L(null,"java.net.URLDecoder",["java.lang.NullPointerException"],function(){c$=$_T(java.net,"URLDecoder");c$.decode=$_M(c$,"decode",function(a){return decodeURIComponent(a)},"~S");c$.decode=$_M(c$,"decode",function(a,b){if(null==b)throw new NullPointerException;return decodeURIComponent(a)},"~S,~S")}),Clazz.declarePackage("java.net"),Clazz.declareInterface(java.net,
"URLStreamHandlerFactory"),Clazz.declarePackage("java.net"),Clazz.load(null,"java.net.URLStreamHandler",["java.lang.IllegalArgumentException","$.SecurityException","$.UnsupportedOperationException"],function(){c$=Clazz.declareType(java.net,"URLStreamHandler");$_M(c$,"openConnectionProxy",function(){throw new UnsupportedOperationException("Method not implemented.");},"java.net.URL,java.net.Proxy");$_M(c$,"parseURL",function(a,b,c,d){var e=a.getProtocol(),f=a.getAuthority(),g=a.getUserInfo(),h=a.getHost(),
k=a.getPort(),l=a.getPath(),m=a.getQuery(),n=a.getRef(),q=!1,p=!1;if(c<d){var r=b.indexOf("?"),p=r==c;-1!=r&&r<d&&(m=b.substring(r+1,d),d>r&&(d=r),b=b.substring(0,r))}var s=0;if(!(c<=d-4&&"/"==b.charAt(c)&&"/"==b.charAt(c+1)&&"/"==b.charAt(c+2)&&"/"==b.charAt(c+3))&&c<=d-2&&"/"==b.charAt(c)&&"/"==b.charAt(c+1)){c+=2;s=b.indexOf("/",c);0>s&&(s=b.indexOf("?",c),0>s&&(s=d));h=f=b.substring(c,s);r=f.indexOf("@");-1!=r?(g=f.substring(0,r),h=f.substring(r+1)):g=null;if(null!=h){if(0<h.length&&"["==h.charAt(0))throw new IllegalArgumentException("Invalid host: "+
h);r=h.indexOf(":");k=-1;0<=r&&(h.length>r+1&&(k=Integer.parseInt(h.substring(r+1))),h=h.substring(0,r))}else h="";if(-1>k)throw new IllegalArgumentException("Invalid port number :"+k);c=s;0<f.length&&(l="")}null==h&&(h="");c<d?"/"==b.charAt(c)?l=b.substring(c,d):null!=l&&0<l.length?(q=!0,r=l.lastIndexOf("/"),p="",-1==r&&null!=f&&(p="/"),l=l.substring(0,r+1)+p+b.substring(c,d)):l=(null!=f?"/":"")+b.substring(c,d):p&&null!=l&&(r=l.lastIndexOf("/"),0>r&&(r=0),l=l.substring(0,r)+"/");null==l&&(l="");
if(q){for(;0<=(s=l.indexOf("/./"));)l=l.substring(0,s)+l.substring(s+2);for(s=0;0<=(s=l.indexOf("/../",s));)0<s&&0<=(d=l.lastIndexOf("/",s-1))&&0!=l.indexOf("/../",d)?(l=l.substring(0,d)+l.substring(s+3),s=0):s+=3;for(;l.endsWith("/..");)if(s=l.indexOf("/.."),0<=(d=l.lastIndexOf("/",s-1)))l=l.substring(0,d+1);else break;l.startsWith("./")&&2<l.length&&(l=l.substring(2));l.endsWith("/.")&&(l=l.substring(0,l.length-1))}this.setURL(a,e,h,k,f,g,l,m,n)},"java.net.URL,~S,~N,~N");$_M(c$,"getDefaultPort",
function(){return-1});$_M(c$,"equals2",function(a,b){var c=a.getRef(),d=b.getRef();return(c===d||null!=c&&c.equals(d))&&this.sameFile(a,b)},"java.net.URL,java.net.URL");$_M(c$,"hashCode",function(a){var b=0,c=a.getProtocol();null!=c&&(b+=c.hashCode());b+=a.toString().hashCode();c=a.getFile();null!=c&&(b+=c.hashCode());b=-1==a.getPort()?b+this.getDefaultPort():b+a.getPort();a=a.getRef();null!=a&&(b+=a.hashCode());return b},"java.net.URL");$_M(c$,"sameFile",function(a,b){if(!(a.getProtocol()===b.getProtocol()||
null!=a.getProtocol()&&a.getProtocol().equalsIgnoreCase(b.getProtocol()))||!(a.getFile()===b.getFile()||null!=a.getFile()&&a.getFile().equals(b.getFile())))return!1;var c,d;c=-1!=a.getPort()?a.getPort():a.handler.getDefaultPort();d=-1!=b.getPort()?b.getPort():b.handler.getDefaultPort();return c!=d||!this.hostsEqual(a,b)?!1:!0},"java.net.URL,java.net.URL");$_M(c$,"hostsEqual",function(a,b){return null!=a.getHost()&&null!=b.getHost()?a.getHost().equalsIgnoreCase(b.getHost()):null==a.getHost()&&null==
b.getHost()},"java.net.URL,java.net.URL");$_M(c$,"toExternalForm",function(){return""},"java.net.URL");$_M(c$,"setURL",function(a,b,c,d,e,f,g,h,k){if(this!==a.handler)throw new SecurityException("handler for url different from this handler");a.set(a.getProtocol(),c,d,e,f,g,h,k)},"java.net.URL,~S,~S,~N,~S,~S,~S,~S,~S");$_M(c$,"setURLDeprecated",function(a,b,c,d,e,f){var g=null,h=null;if(null!=c&&0!=c.length){var g=-1==d?c:c+":"+d,k=c.lastIndexOf("@");-1!=k&&(h=c.substring(0,k),c=c.substring(k+1))}var l=
null,k=null;null!=e&&(l=e.lastIndexOf("?"),-1!=l?(k=e.substring(l+1),l=e.substring(0,l)):l=e);this.setURL(a,b,c,d,g,h,l,k,f)},"java.net.URL,~S,~S,~N,~S,~S")}),Clazz.declarePackage("java.net"),Clazz.load(["java.util.Hashtable"],"java.net.URL",["java.io.IOException","java.lang.Character","$.Error","java.net.MalformedURLException"],function(){c$=Clazz.decorateAsClass(function(){this.host=this.protocol=null;this.port=-1;this.handler=this.ref=this.userInfo=this.path=this.authority=this.query=this.file=
null;this.$hashCode=-1;Clazz.instantialize(this,arguments)},java.net,"URL",null,java.io.Serializable);Clazz.makeConstructor(c$,function(a,b,c){var d,e,f,g=0,h=null,k=!1,l=!1;if(null!=c){var m=System.getSecurityManager();null!=m&&this.checkSpecifyHandler(m)}try{for(e=b.length;0<e&&" ">=b.charAt(e-1);)e--;for(;g<e&&" ">=b.charAt(g);)g++;b.regionMatches(!0,g,"url:",0,4)&&(g+=4);g<b.length&&"#"==b.charAt(g)&&(k=!0);for(d=g;!k&&d<e&&47!=(f=b.charCodeAt(d));d++)if(58==f){var n=b.substring(g,d).toLowerCase();
this.isValidProtocol(n)&&(h=n,g=d+1);break}this.protocol=h;if(null!=a&&(null==h||h.equalsIgnoreCase(a.protocol)))null==c&&(c=a.handler),null!=a.path&&a.path.startsWith("/")&&(h=null),null==h&&(this.protocol=a.protocol,this.authority=a.authority,this.userInfo=a.userInfo,this.host=a.host,this.port=a.port,this.file=a.file,this.path=a.path,l=!0);if(null==this.protocol)throw new java.net.MalformedURLException("no protocol: "+b);if(null==c&&null==(c=java.net.URL.getURLStreamHandler(this.protocol)))throw new java.net.MalformedURLException("unknown protocol: "+
this.protocol);this.handler=c;d=b.indexOf("#",g);0<=d&&(this.ref=b.substring(d+1,e),e=d);l&&g==e&&(this.query=a.query,null==this.ref&&(this.ref=a.ref));c.parseURL(this,b,g,e)}catch(q){if(Clazz.exceptionOf(q,java.net.MalformedURLException))throw q;if(Clazz.exceptionOf(q,Exception))throw a=q,b=new java.net.MalformedURLException(a.getMessage()),b.initCause(a),b;throw q;}},"java.net.URL,~S,java.net.URLStreamHandler");$_M(c$,"isValidProtocol",($fz=function(a){var b=a.length;if(1>b)return!1;var c=a.charAt(0);
if(!Character.isLetter(c))return!1;for(var d=1;d<b;d++)if(c=a.charAt(d),!Character.isLetterOrDigit(c)&&"."!=c&&"+"!=c&&"-"!=c)return!1;return!0},$fz.isPrivate=!0,$fz),"~S");$_M(c$,"checkSpecifyHandler",($fz=function(){},$fz.isPrivate=!0,$fz),"SecurityManager");$_M(c$,"set5",function(a,b,c,d,e){this.protocol=a;this.host=b;this.authority=-1==c?b:b+":"+c;this.port=c;this.file=d;this.ref=e;this.$hashCode=-1;a=d.lastIndexOf("?");-1!=a?(this.query=d.substring(a+1),this.path=d.substring(0,a)):this.path=
d},"~S,~S,~N,~S,~S");$_M(c$,"set",function(a,b,c,d,e,f,g,h){this.protocol=a;this.host=b;this.port=c;this.file=null==g?f:f+"?"+g;this.userInfo=e;this.path=f;this.ref=h;this.$hashCode=-1;this.query=g;this.authority=d},"~S,~S,~N,~S,~S,~S,~S,~S");$_M(c$,"getQuery",function(){return this.query});$_M(c$,"getPath",function(){return this.path});$_M(c$,"getUserInfo",function(){return this.userInfo});$_M(c$,"getAuthority",function(){return this.authority});$_M(c$,"getPort",function(){return this.port});$_M(c$,
"getDefaultPort",function(){return this.handler.getDefaultPort()});$_M(c$,"getProtocol",function(){return this.protocol});$_M(c$,"getHost",function(){return this.host});$_M(c$,"getFile",function(){return this.file});$_M(c$,"getRef",function(){return this.ref});Clazz.overrideMethod(c$,"equals",function(a){return!Clazz.instanceOf(a,java.net.URL)?!1:this.handler.equals2(this,a)},"~O");Clazz.overrideMethod(c$,"hashCode",function(){return-1!=this.$hashCode?this.$hashCode:this.$hashCode=this.handler.hashCode(this)});
$_M(c$,"sameFile",function(a){return this.handler.sameFile(this,a)},"java.net.URL");Clazz.overrideMethod(c$,"toString",function(){return this.toExternalForm()});$_M(c$,"toExternalForm",function(){return this.handler.toExternalForm(this)});$_M(c$,"openConnection",function(){return this.handler.openConnection(this)});$_M(c$,"openStream",function(){return this.openConnection().getInputStream()});$_M(c$,"getContent",function(){return this.openConnection().getInputStream()});c$.setURLStreamHandlerFactory=
$_M(c$,"setURLStreamHandlerFactory",function(a){if(null!=java.net.URL.factory)throw Error("factory already defined");var b=System.getSecurityManager();null!=b&&b.checkSetFactory();java.net.URL.handlers.clear();$t$=java.net.URL.factory=a;java.net.URL.prototype.factory=java.net.URL.factory;$t$},"java.net.URLStreamHandlerFactory");c$.getURLStreamHandler=$_M(c$,"getURLStreamHandler",function(a){var b=java.net.URL.handlers.get(a);null==b&&null!=java.net.URL.factory&&(b=java.net.URL.factory.createURLStreamHandler(a));
return b},"~S");Clazz.defineStatics(c$,"factory",null);c$.handlers=c$.prototype.handlers=new java.util.Hashtable;c$.streamHandlerLock=c$.prototype.streamHandlerLock=new JavaObject}),Clazz.declarePackage("java.net"),Clazz.load(null,"java.net.URLConnection",["java.lang.IllegalStateException","$.NullPointerException","java.net.UnknownServiceException","JU.List"],function(){c$=Clazz.decorateAsClass(function(){this.url=null;this.doInput=!0;this.connected=this.doOutput=!1;this.requests=null;Clazz.instantialize(this,
arguments)},java.net,"URLConnection");$_M(c$,"setDoInput",function(a){if(this.connected)throw new IllegalStateException("Already connected");this.doInput=a},"~B");$_M(c$,"getDoInput",function(){return this.doInput});$_M(c$,"setDoOutput",function(a){if(this.connected)throw new IllegalStateException("Already connected");this.doOutput=a},"~B");$_M(c$,"getDoOutput",function(){return this.doOutput});Clazz.makeConstructor(c$,function(a){this.url=a},"java.net.URL");$_M(c$,"getURL",function(){return this.url});
$_M(c$,"getInputStream",function(){throw new java.net.UnknownServiceException("protocol doesn't support input");});$_M(c$,"getOutputStream",function(){throw new java.net.UnknownServiceException("protocol doesn't support output");});$_M(c$,"setRequestProperty",function(a,b){if(this.connected)throw new IllegalStateException("Already connected");if(null==a)throw new NullPointerException("key is null");null==this.requests&&(this.requests=new JU.List);for(var c=this.requests.size();0<=--c;)if(this.requests.get(c)[0].equals(a)){this.requests.get(c)[1]=
b;return}this.requests.addLast([a,b])},"~S,~S")}),Clazz.declarePackage("JU"),Clazz.load(["java.net.URLConnection"],"JU.AjaxURLConnection",null,function(){c$=Clazz.decorateAsClass(function(){this.bytesOut=null;this.postOut="";Clazz.instantialize(this,arguments)},JU,"AjaxURLConnection",java.net.URLConnection);$_M(c$,"doAjax",($fz=function(){return Jmol._doAjax(this.url,this.postOut,this.bytesOut)},$fz.isPrivate=!0,$fz));Clazz.overrideMethod(c$,"connect",function(){});$_M(c$,"outputBytes",function(a){this.bytesOut=
a},"~A");$_M(c$,"outputString",function(a){this.postOut=a},"~S");$_M(c$,"getSB",function(){return this.doAjax()})}),Clazz.declarePackage("JU"),Clazz.load(["java.net.URLStreamHandlerFactory","java.util.Hashtable"],"JU.AjaxURLStreamHandlerFactory",["JU.AjaxURLStreamHandler"],function(){c$=Clazz.decorateAsClass(function(){this.htFactories=null;Clazz.instantialize(this,arguments)},JU,"AjaxURLStreamHandlerFactory",null,java.net.URLStreamHandlerFactory);Clazz.prepareFields(c$,function(){this.htFactories=
new java.util.Hashtable});Clazz.overrideMethod(c$,"createURLStreamHandler",function(a){var b=this.htFactories.get(a);null==b&&this.htFactories.put(a,b=new JU.AjaxURLStreamHandler(a));return null==b.protocol?null:b},"~S")}),Clazz.declarePackage("JU"),Clazz.load(["java.net.URLStreamHandler"],"JU.AjaxURLStreamHandler",["JU.AjaxURLConnection","$.SB"],function(){c$=Clazz.decorateAsClass(function(){this.protocol=null;Clazz.instantialize(this,arguments)},JU,"AjaxURLStreamHandler",java.net.URLStreamHandler);
Clazz.makeConstructor(c$,function(a){Clazz.superConstructor(this,JU.AjaxURLStreamHandler,[]);this.protocol=a},"~S");Clazz.overrideMethod(c$,"openConnection",function(a){return new JU.AjaxURLConnection(a)},"java.net.URL");Clazz.overrideMethod(c$,"toExternalForm",function(a){var b=new JU.SB;b.append(a.getProtocol());b.append(":");null!=a.getAuthority()&&0<a.getAuthority().length&&(b.append("//"),b.append(a.getAuthority()));null!=a.getPath()&&b.append(a.getPath());null!=a.getQuery()&&(b.append("?"),
b.append(a.getQuery()));null!=a.getRef()&&(b.append("#"),b.append(a.getRef()));return b.toString()},"java.net.URL")}),$_J("java.text"),c$=$_C(function(){this.pattern=null;$_Z(this,arguments)},java.text,"MessageFormat"),$_K(c$,function(a){this.pattern=a},"~S"),$_K(c$,function(a){this.pattern=a},"~S,java.util.Locale"),c$.format=$_M(c$,"format",function(a,b){return a.replace(/\{(\d+)\}/g,function(a,d){var e=parseInt(d);return null==b?null:b[e]})},"~S,~A"),$_M(c$,"format",function(a){return java.text.MessageFormat.format(this.pattern,
[a])},"~O"),$_L(null,"java.util.Random",["java.lang.IllegalArgumentException"],function(){c$=$_C(function(){this.haveNextNextGaussian=!1;this.nextNextGaussian=this.seed=0;$_Z(this,arguments)},java.util,"Random",null,java.io.Serializable);$_K(c$,function(){this.setSeed(System.currentTimeMillis())});$_K(c$,function(a){this.setSeed(a)},"~N");$_M(c$,"next",function(a){this.seed=25214903917*this.seed+11&0xffffffffffff;return this.seed>>>48-a},"~N");$_M(c$,"nextBoolean",function(){return 0.5<Math.random()});
$_M(c$,"nextBytes",function(){for(var a=0;a<bytes.length;a++)bytes[a]=Math.round(256*Math.random())},"~A");$_M(c$,"nextDouble",function(){return Math.random()});$_M(c$,"nextFloat",function(){return Math.random()});$_M(c$,"nextGaussian",function(){if(this.haveNextNextGaussian)return this.haveNextNextGaussian=!1,this.nextNextGaussian;var a,b,c;do a=2*this.nextDouble()-1,b=2*this.nextDouble()-1,c=a*a+b*b;while(1<=c);c=Math.sqrt(-2*Math.log(c)/c);this.nextNextGaussian=b*c;this.haveNextNextGaussian=!0;
return a*c});$_M(c$,"nextInt",function(){return Math.ceil(65535*Math.random())-32768});$_M(c$,"nextInt",function(a){if(0<a){if((a&-a)==a)return a*this.next(31)>>31;var b,c;do b=this.next(31),c=b%a;while(0>b-c+(a-1));return c}throw new IllegalArgumentException;},"~N");$_M(c$,"nextLong",function(){return Math.ceil(4294967295*Math.random())-2147483648});$_M(c$,"setSeed",function(a){this.seed=(a^25214903917)&0xffffffffffff;this.haveNextNextGaussian=!1},"~N");$_S(c$,"multiplier",25214903917)}),Clazz.declarePackage("J.util"),
Clazz.declareInterface(J.util,"LoggerInterface"),Clazz.declarePackage("J.util"),Clazz.load(["J.util.LoggerInterface"],"J.util.DefaultLogger",["J.util.Logger"],function(){c$=Clazz.declareType(J.util,"DefaultLogger",null,J.util.LoggerInterface);$_M(c$,"log",function(a,b,c,d){a===System.err&&System.out.flush();if(null!=a&&(null!=c||null!=d))if(a.println((J.util.Logger.logLevel()?"["+J.util.Logger.getLevel(b)+"] ":"")+(null!=c?c:"")+(null!=d?": "+d.toString():"")),null!=d&&(b=d.getStackTrace(),null!=
b))for(c=0;c<b.length;c++)a.println(b[c].getClassName()+" - "+b[c].getLineNumber()+" - "+b[c].getMethodName());a===System.err&&System.err.flush()},"java.io.PrintStream,~N,~S,Throwable");Clazz.overrideMethod(c$,"debug",function(a){this.log(System.out,5,a,null)},"~S");Clazz.overrideMethod(c$,"info",function(a){this.log(System.out,4,a,null)},"~S");Clazz.overrideMethod(c$,"warn",function(a){this.log(System.out,3,a,null)},"~S");Clazz.overrideMethod(c$,"warnEx",function(a,b){this.log(System.out,3,a,b)},
"~S,Throwable");Clazz.overrideMethod(c$,"error",function(a){this.log(System.err,2,a,null)},"~S");Clazz.overrideMethod(c$,"errorEx",function(a,b){this.log(System.err,2,a,b)},"~S,Throwable");Clazz.overrideMethod(c$,"fatal",function(a){this.log(System.err,1,a,null)},"~S");Clazz.overrideMethod(c$,"fatalEx",function(a,b){this.log(System.err,1,a,b)},"~S,Throwable")}),Clazz.declarePackage("J.util"),Clazz.load(["java.util.Hashtable","J.util.DefaultLogger"],"J.util.Logger",["java.lang.Long"],function(){c$=
Clazz.declareType(J.util,"Logger");c$.getProperty=$_M(c$,"getProperty",($fz=function(a,b){try{var c=System.getProperty("jmol.logger."+a,null);if(null!=c)return c.equalsIgnoreCase("true")}catch(d){if(!Clazz.exceptionOf(d,Exception))throw d;}return b},$fz.isPrivate=!0,$fz),"~S,~B");c$.setLogger=$_M(c$,"setLogger",function(a){$t$=J.util.Logger._logger=a;J.util.Logger.prototype._logger=J.util.Logger._logger;$t$;$t$=J.util.Logger.debugging=J.util.Logger.isActiveLevel(5)||J.util.Logger.isActiveLevel(6);
J.util.Logger.prototype.debugging=J.util.Logger.debugging;$t$;$t$=J.util.Logger.debuggingHigh=J.util.Logger.debugging&&J.util.Logger._activeLevels[6];J.util.Logger.prototype.debuggingHigh=J.util.Logger.debuggingHigh;$t$},"J.util.LoggerInterface");c$.isActiveLevel=$_M(c$,"isActiveLevel",function(a){return null!=J.util.Logger._logger&&0<=a&&7>a&&J.util.Logger._activeLevels[a]},"~N");c$.setActiveLevel=$_M(c$,"setActiveLevel",function(a,b){0>a&&(a=0);7<=a&&(a=6);J.util.Logger._activeLevels[a]=b;$t$=J.util.Logger.debugging=
J.util.Logger.isActiveLevel(5)||J.util.Logger.isActiveLevel(6);J.util.Logger.prototype.debugging=J.util.Logger.debugging;$t$;$t$=J.util.Logger.debuggingHigh=J.util.Logger.debugging&&J.util.Logger._activeLevels[6];J.util.Logger.prototype.debuggingHigh=J.util.Logger.debuggingHigh;$t$},"~N,~B");c$.setLogLevel=$_M(c$,"setLogLevel",function(a){for(var b=7;0<=--b;)J.util.Logger.setActiveLevel(b,b<=a)},"~N");c$.getLevel=$_M(c$,"getLevel",function(a){switch(a){case 6:return"DEBUGHIGH";case 5:return"DEBUG";
case 4:return"INFO";case 3:return"WARN";case 2:return"ERROR";case 1:return"FATAL"}return"????"},"~N");c$.logLevel=$_M(c$,"logLevel",function(){return J.util.Logger._logLevel});c$.doLogLevel=$_M(c$,"doLogLevel",function(a){$t$=J.util.Logger._logLevel=a;J.util.Logger.prototype._logLevel=J.util.Logger._logLevel;$t$},"~B");c$.debug=$_M(c$,"debug",function(a){if(J.util.Logger.debugging)try{J.util.Logger._logger.debug(a)}catch(b){}},"~S");c$.info=$_M(c$,"info",function(a){try{J.util.Logger.isActiveLevel(4)&&
J.util.Logger._logger.info(a)}catch(b){}},"~S");c$.warn=$_M(c$,"warn",function(a){try{J.util.Logger.isActiveLevel(3)&&J.util.Logger._logger.warn(a)}catch(b){}},"~S");c$.warnEx=$_M(c$,"warnEx",function(a,b){try{J.util.Logger.isActiveLevel(3)&&J.util.Logger._logger.warnEx(a,b)}catch(c){}},"~S,Throwable");c$.error=$_M(c$,"error",function(a){try{J.util.Logger.isActiveLevel(2)&&J.util.Logger._logger.error(a)}catch(b){}},"~S");c$.errorEx=$_M(c$,"errorEx",function(a,b){try{J.util.Logger.isActiveLevel(2)&&
J.util.Logger._logger.errorEx(a,b)}catch(c){}},"~S,Throwable");c$.getLogLevel=$_M(c$,"getLogLevel",function(){for(var a=7;0<=--a;)if(J.util.Logger.isActiveLevel(a))return a;return 0});c$.fatal=$_M(c$,"fatal",function(a){try{J.util.Logger.isActiveLevel(1)&&J.util.Logger._logger.fatal(a)}catch(b){}},"~S");c$.fatalEx=$_M(c$,"fatalEx",function(a,b){try{J.util.Logger.isActiveLevel(1)&&J.util.Logger._logger.fatalEx(a,b)}catch(c){}},"~S,Throwable");c$.startTimer=$_M(c$,"startTimer",function(a){null!=a&&
J.util.Logger.htTiming.put(a,Long.$valueOf(System.currentTimeMillis()))},"~S");c$.getTimerMsg=$_M(c$,"getTimerMsg",function(a,b){0==b&&(b=J.util.Logger.getTimeFrom(a));return"Time for "+a+": "+b+" ms"},"~S,~N");c$.getTimeFrom=$_M(c$,"getTimeFrom",($fz=function(a){var b;return null==a||null==(b=J.util.Logger.htTiming.get(a))?-1:System.currentTimeMillis()-b.longValue()},$fz.isPrivate=!0,$fz),"~S");c$.checkTimer=$_M(c$,"checkTimer",function(a,b){var c=J.util.Logger.getTimeFrom(a);0<=c&&!a.startsWith("(")&&
J.util.Logger.info(J.util.Logger.getTimerMsg(a,c));b&&J.util.Logger.startTimer(a);return c},"~S,~B");c$.checkMemory=$_M(c$,"checkMemory",function(){J.util.Logger.info("Memory: Total-Free=0; Total=0; Free=0; Max=0")});c$._logger=c$.prototype._logger=new J.util.DefaultLogger;Clazz.defineStatics(c$,"LEVEL_FATAL",1,"LEVEL_ERROR",2,"LEVEL_WARN",3,"LEVEL_INFO",4,"LEVEL_DEBUG",5,"LEVEL_DEBUGHIGH",6,"LEVEL_MAX",7,"_activeLevels",Clazz.newBooleanArray(7,!1),"_logLevel",!1,"debugging",!1,"debuggingHigh",!1);
J.util.Logger._activeLevels[6]=J.util.Logger.getProperty("debugHigh",!1);J.util.Logger._activeLevels[5]=J.util.Logger.getProperty("debug",!1);J.util.Logger._activeLevels[4]=J.util.Logger.getProperty("info",!0);J.util.Logger._activeLevels[3]=J.util.Logger.getProperty("warn",!0);J.util.Logger._activeLevels[2]=J.util.Logger.getProperty("error",!0);J.util.Logger._activeLevels[1]=J.util.Logger.getProperty("fatal",!0);$t$=J.util.Logger._logLevel=J.util.Logger.getProperty("logLevel",!1);J.util.Logger.prototype._logLevel=
J.util.Logger._logLevel;$t$;$t$=J.util.Logger.debugging=null!=J.util.Logger._logger&&(J.util.Logger._activeLevels[5]||J.util.Logger._activeLevels[6]);J.util.Logger.prototype.debugging=J.util.Logger.debugging;$t$;$t$=J.util.Logger.debuggingHigh=J.util.Logger.debugging&&J.util.Logger._activeLevels[6];J.util.Logger.prototype.debuggingHigh=J.util.Logger.debuggingHigh;$t$;c$.htTiming=c$.prototype.htTiming=new java.util.Hashtable}),Clazz.declarePackage("J.i18n"),Clazz.load(null,"J.i18n.Resource",["J.util.Txt"],
function(){c$=Clazz.decorateAsClass(function(){this.className=this.resource=null;Clazz.instantialize(this,arguments)},J.i18n,"Resource");Clazz.makeConstructor(c$,($fz=function(a,b){this.resource=a;this.className=b},$fz.isPrivate=!0,$fz),"~O,~S");c$.getResource=$_M(c$,"getResource",function(a,b){var c=null,c=ClazzLoader.fastGetJ2SLibBase()+"/trans/"+b+".po",c=Jmol._doAjax(c,null,null);if(!c)return null;c=c.toString();try{return null==c?null:J.i18n.Resource.getResourceFromPO(c)}catch(d){if(Clazz.exceptionOf(d,
Exception))return null;throw d;}},"~S,~S");$_M(c$,"getString",function(a){return this.resource.get(a)},"~S");c$.getLanguage=$_M(c$,"getLanguage",function(){var a=null;return a=Jmol.featureDetection.getDefaultLanguage().replace(/-/g,"_")});c$.getResourceFromPO=$_M(c$,"getResourceFromPO",function(a){if(null==a||0==a.length)return null;var b=null;try{var c=J.util.TextFormat.split(a,"\n"),b=new java.util.Hashtable;a=0;for(var d="",e="",f=0;f<c.length;f++){var g=c[f];2>=g.length?2==a&&(0!=d.length&&0!=
e.length)&&b.put(e,d):0==g.indexOf("msgid")?(a=1,e=J.i18n.Resource.fix(g)):0==g.indexOf("msgstr")?(a=2,d=J.i18n.Resource.fix(g)):1==a?e+=J.i18n.Resource.fix(g):2==a&&(d+=J.i18n.Resource.fix(g))}}catch(h){}return null==b||0==b.size()?null:new J.i18n.Resource(b)},"~S");c$.fix=$_M(c$,"fix",function(a){return J.util.Txt.simpleReplace(a.substring(a.indexOf('"')+1,a.lastIndexOf('"')),"\\n","\n")},"~S")}),Clazz.declarePackage("J.i18n"),Clazz.load(null,"J.i18n.Language",["J.i18n.GT"],function(){c$=Clazz.decorateAsClass(function(){this.nativeLanguage=
this.language=this.code=null;this.display=!1;Clazz.instantialize(this,arguments)},J.i18n,"Language");c$.getLanguageList=$_M(c$,"getLanguageList",function(){return[new J.i18n.Language("ar",J.i18n.GT._("Arabic"),"\u0627\u0644\u0639\u0631\u0628\u064a\u0629",!1),new J.i18n.Language("ast",J.i18n.GT._("Asturian"),"Asturian",!1),new J.i18n.Language("az",J.i18n.GT._("Azerbaijani"),"az\u0259rbaycan dili",!1),new J.i18n.Language("bs",J.i18n.GT._("Bosnian"),"bosanski jezik",!1),new J.i18n.Language("ca",J.i18n.GT._("Catalan"),
"Catal\u00e0",!0),new J.i18n.Language("cs",J.i18n.GT._("Czech"),"\u010ce\u0161tina",!0),new J.i18n.Language("da",J.i18n.GT._("Danish"),"Dansk",!0),new J.i18n.Language("de",J.i18n.GT._("German"),"Deutsch",!0),new J.i18n.Language("el",J.i18n.GT._("Greek"),"\u0395\u03bb\u03bb\u03b7\u03bd\u03b9\u03ba\u03ac",!1),new J.i18n.Language("en_AU",J.i18n.GT._("Australian English"),"Australian English",!1),new J.i18n.Language("en_GB",J.i18n.GT._("British English"),"British English",!0),new J.i18n.Language("en_US",
J.i18n.GT._("American English"),"American English",!0),new J.i18n.Language("es",J.i18n.GT._("Spanish"),"Espa\u00f1ol",!0),new J.i18n.Language("et",J.i18n.GT._("Estonian"),"Eesti",!1),new J.i18n.Language("eu",J.i18n.GT._("Basque"),"Euskara",!0),new J.i18n.Language("fi",J.i18n.GT._("Finnish"),"Suomi",!0),new J.i18n.Language("fo",J.i18n.GT._("Faroese"),"F\u00f8royskt",!1),new J.i18n.Language("fr",J.i18n.GT._("French"),"Fran\u00e7ais",!0),new J.i18n.Language("fy",J.i18n.GT._("Frisian"),"Frysk",!1),new J.i18n.Language("gl",
J.i18n.GT._("Galician"),"Galego",!1),new J.i18n.Language("hr",J.i18n.GT._("Croatian"),"Hrvatski",!1),new J.i18n.Language("hu",J.i18n.GT._("Hungarian"),"Magyar",!0),new J.i18n.Language("hy",J.i18n.GT._("Armenian"),"\u0540\u0561\u0575\u0565\u0580\u0565\u0576",!1),new J.i18n.Language("id",J.i18n.GT._("Indonesian"),"Indonesia",!0),new J.i18n.Language("it",J.i18n.GT._("Italian"),"Italiano",!0),new J.i18n.Language("ja",J.i18n.GT._("Japanese"),"\u65e5\u672c\u8a9e",!0),new J.i18n.Language("jv",J.i18n.GT._("Javanese"),
"Basa Jawa",!1),new J.i18n.Language("ko",J.i18n.GT._("Korean"),"\ud55c\uad6d\uc5b4",!0),new J.i18n.Language("ms",J.i18n.GT._("Malay"),"Bahasa Melayu",!0),new J.i18n.Language("nb",J.i18n.GT._("Norwegian Bokmal"),"Norsk Bokm\u00e5l",!1),new J.i18n.Language("nl",J.i18n.GT._("Dutch"),"Nederlands",!0),new J.i18n.Language("oc",J.i18n.GT._("Occitan"),"Occitan",!1),new J.i18n.Language("pl",J.i18n.GT._("Polish"),"Polski",!1),new J.i18n.Language("pt",J.i18n.GT._("Portuguese"),"Portugu\u00eas",!1),new J.i18n.Language("pt_BR",
J.i18n.GT._("Brazilian Portuguese"),"Portugu\u00eas brasileiro",!0),new J.i18n.Language("ru",J.i18n.GT._("Russian"),"\u0420\u0443\u0441\u0441\u043a\u0438\u0439",!1),new J.i18n.Language("sl",J.i18n.GT._("Slovenian"),"Sloven\u0161\u010dina",!1),new J.i18n.Language("sr",J.i18n.GT._("Serbian"),"\u0441\u0440\u043f\u0441\u043a\u0438 \u0458\u0435\u0437\u0438\u043a",!1),new J.i18n.Language("sv",J.i18n.GT._("Swedish"),"Svenska",!0),new J.i18n.Language("ta",J.i18n.GT._("Tamil"),"\u0ba4\u0bae\u0bbf\u0bb4\u0bcd",
!1),new J.i18n.Language("te",J.i18n.GT._("Telugu"),"\u0c24\u0c46\u0c32\u0c41\u0c17\u0c41",!1),new J.i18n.Language("tr",J.i18n.GT._("Turkish"),"T\u00fcrk\u00e7e",!0),new J.i18n.Language("ug",J.i18n.GT._("Uyghur"),"Uy\u01a3urq\u0259",!1),new J.i18n.Language("uk",J.i18n.GT._("Ukrainian"),"\u0423\u043a\u0440\u0430\u0457\u043d\u0441\u044c\u043a\u0430",!0),new J.i18n.Language("uz",J.i18n.GT._("Uzbek"),"O'zbek",!1),new J.i18n.Language("zh_CN",J.i18n.GT._("Simplified Chinese"),"\u7b80\u4f53\u4e2d\u6587",
!0),new J.i18n.Language("zh_TW",J.i18n.GT._("Traditional Chinese"),"\u7e41\u9ad4\u4e2d\u6587",!0)]});Clazz.makeConstructor(c$,($fz=function(a,b,c,d){this.code=a;this.language=b;this.nativeLanguage=c;this.display=d},$fz.isPrivate=!0,$fz),"~S,~S,~S,~B");c$.getSupported=$_M(c$,"getSupported",function(a,b){for(var c=a.length;0<=--c;)if(a[c].code.equalsIgnoreCase(b))return a[c].code;for(c=a.length;0<=--c;)if(a[c].code.startsWith(b))return a[c].code;return null},"~A,~S")}),Clazz.declarePackage("J.i18n"),
Clazz.load(["java.util.Hashtable","J.i18n.Language","$.Resource"],"J.i18n.GT",["java.text.MessageFormat","J.util.Logger"],function(){c$=Clazz.decorateAsClass(function(){this.resources=null;this.resourceCount=0;this.doTranslate=!0;this.language=null;Clazz.instantialize(this,arguments)},J.i18n,"GT");Clazz.makeConstructor(c$,function(){});Clazz.makeConstructor(c$,function(a){this.resources=null;this.resourceCount=0;$t$=J.i18n.GT.$getTextWrapper=this;J.i18n.GT.prototype.$getTextWrapper=J.i18n.GT.$getTextWrapper;
$t$;null!=a&&0==a.length&&(a="none");null!=a&&(this.language=a);"none".equals(this.language)&&(this.language=null);null==this.language&&(this.language=J.i18n.Resource.getLanguage());null==this.language&&(this.language="en");a=this.language;var b=null,c=null,d=this.language.indexOf("_");if(0<=d&&(a=a.substring(0,d),b=this.language,0<=(d=b.indexOf("_",++d))))b=b.substring(0,d),c=this.language;if(null==(this.language=this.getSupported(c))&&null==(this.language=this.getSupported(b))&&null==(this.language=
this.getSupported(a)))this.language="en",System.out.println(this.language+" not supported -- using en");else{b=c=null;switch(this.language.length){default:c=this.language;b=this.language.substring(0,5);a=this.language.substring(0,2);break;case 5:b=this.language;a=this.language.substring(0,2);break;case 2:a=this.language}b=this.getSupported(b);a=this.getSupported(a);if(a===b||"en_US".equals(a))a=null;b===c&&(b=null);"en_US".equals(b)||(J.i18n.GT.allowDebug&&J.util.Logger.debugging&&J.util.Logger.debug("Instantiating gettext wrapper for "+
this.language+" using files for language:"+a+" country:"+b+" variant:"+c),J.i18n.GT.$ignoreApplicationBundle||this.addBundles("Jmol",c,b,a),this.addBundles("JmolApplet",c,b,a))}},"~S");c$.getLanguageList=$_M(c$,"getLanguageList",function(a){null==J.i18n.GT.languageList&&(null==a&&(a=J.i18n.GT.getTextWrapper()),a.createLanguageList());return J.i18n.GT.languageList},"J.i18n.GT");c$.getLanguage=$_M(c$,"getLanguage",function(){return J.i18n.GT.getTextWrapper().language});c$.ignoreApplicationBundle=$_M(c$,
"ignoreApplicationBundle",function(){$t$=J.i18n.GT.$ignoreApplicationBundle=!0;J.i18n.GT.prototype.$ignoreApplicationBundle=J.i18n.GT.$ignoreApplicationBundle;$t$});c$.setDoTranslate=$_M(c$,"setDoTranslate",function(a){var b=J.i18n.GT.getDoTranslate();J.i18n.GT.getTextWrapper().doTranslate=a;return b},"~B");c$.getDoTranslate=$_M(c$,"getDoTranslate",function(){return J.i18n.GT.getTextWrapper().doTranslate});c$._=$_M(c$,"_",function(a){return J.i18n.GT.getTextWrapper().getString(a,null)},"~S");c$._=
$_M(c$,"_",function(a,b){return J.i18n.GT.getTextWrapper().getString(a,[b])},"~S,~S");c$._=$_M(c$,"_",function(a,b){return J.i18n.GT.getTextWrapper().getString(a,[Integer.$valueOf(b)])},"~S,~N");c$._=$_M(c$,"_",function(a,b){return J.i18n.GT.getTextWrapper().getString(a,b)},"~S,~A");c$.escapeHTML=$_M(c$,"escapeHTML",function(a){for(var b,c=a.length;0<=--c;)if(127<(b=a.charAt(c)).charCodeAt(0))a=a.substring(0,c)+"&#"+b.charCodeAt(0)+";"+a.substring(c+1);return a},"~S");c$.getTextWrapper=$_M(c$,"getTextWrapper",
($fz=function(){return null==J.i18n.GT.$getTextWrapper?($t$=J.i18n.GT.$getTextWrapper=new J.i18n.GT(null),J.i18n.GT.prototype.$getTextWrapper=J.i18n.GT.$getTextWrapper,$t$):J.i18n.GT.$getTextWrapper},$fz.isPrivate=!0,$fz));$_M(c$,"createLanguageList",($fz=function(){var a=this.doTranslate;this.doTranslate=!1;$t$=J.i18n.GT.languageList=J.i18n.Language.getLanguageList();J.i18n.GT.prototype.languageList=J.i18n.GT.languageList;$t$;this.doTranslate=a},$fz.isPrivate=!0,$fz));$_M(c$,"getSupported",($fz=
function(a){if(null==a)return null;var b=J.i18n.GT.htLanguages.get(a);if(null!=b)return 0==b.length?null:b;b=J.i18n.Language.getSupported(J.i18n.GT.getLanguageList(this),a);J.i18n.GT.htLanguages.put(a,null==b?"":b);return b},$fz.isPrivate=!0,$fz),"~S");$_M(c$,"addBundles",($fz=function(a,b,c,d){try{a="J.translation."+a+".",null!=b&&this.addBundle(a,b),null!=c&&this.addBundle(a,c),null!=d&&this.addBundle(a,d)}catch(e){if(Clazz.exceptionOf(e,Exception))J.i18n.GT.allowDebug&&J.util.Logger.errorEx("Some exception occurred!",
e),this.resources=null,this.resourceCount=0;else throw e;}},$fz.isPrivate=!0,$fz),"~S,~S,~S,~S");$_M(c$,"addBundle",($fz=function(a,b){var c=J.i18n.Resource.getResource(a,b);null!=c&&(null==this.resources&&(this.resources=Array(8),this.resourceCount=0),this.resources[this.resourceCount]=c,this.resourceCount++,J.i18n.GT.allowDebug&&J.util.Logger.debug("GT adding "+a))},$fz.isPrivate=!0,$fz),"~S,~S");$_M(c$,"getString",($fz=function(a,b){var c=null;if(this.doTranslate){for(var d=this.resourceCount;0<=
--d;)if(c=this.resources[d].getString(a),null!=c){a=c;break}0<this.resourceCount&&(null==c&&J.i18n.GT.allowDebug&&J.util.Logger.debugging)&&J.util.Logger.debug("No trans, using default: "+a)}null==c&&(a.startsWith("[")?a=a.substring(a.indexOf("]")+1):a.endsWith("]")&&(a=a.substring(0,a.indexOf("["))));return null==b?a:java.text.MessageFormat.format(a,b)},$fz.isPrivate=!0,$fz),"~S,~A");Clazz.defineStatics(c$,"$ignoreApplicationBundle",!1,"$getTextWrapper",null,"languageList",null,"allowDebug",!1);
c$.htLanguages=c$.prototype.htLanguages=new java.util.Hashtable}),Clazz.declarePackage("J.api"),Clazz.declareInterface(J.api,"JmolCallbackListener"),Clazz.declarePackage("J.api"),Clazz.load(["J.api.JmolCallbackListener"],"J.api.JmolStatusListener",null,function(){Clazz.declareInterface(J.api,"JmolStatusListener",J.api.JmolCallbackListener)}),Clazz.declarePackage("J.api"),Clazz.declareInterface(J.api,"JmolSyncInterface"),Clazz.declarePackage("J.appletjs"),Clazz.load(["J.api.JmolStatusListener","$.JmolSyncInterface",
"java.util.Hashtable"],"J.appletjs.Jmol","java.lang.Boolean java.net.URL javajs.awt.Dimension JU.List $.SB J.appletjs.JmolAppletRegistry J.constant.EnumCallback J.i18n.GT J.util.Escape $.Logger $.ParserBS $.Txt J.viewer.JC $.Viewer".split(" "),function(){c$=Clazz.decorateAsClass(function(){this.language=null;this.doTranslate=!0;this.loading=this.isStereoSlave=this.haveDocumentAccess=!1;this.mayScript=!0;this.jmol=this.htParams=this.viewerOptions=this.b$=this.viewer=this.gRight=this.outputBuffer=this.syncId=
this.fullName=this.htmlName=null;Clazz.isClassDefined("J.appletjs.Jmol.MyStatusListener")||J.appletjs.Jmol.$Jmol$MyStatusListener$();Clazz.instantialize(this,arguments)},J.appletjs,"Jmol",null,J.api.JmolSyncInterface);Clazz.prepareFields(c$,function(){this.b$=new java.util.Hashtable;this.htParams=new java.util.Hashtable});Clazz.makeConstructor(c$,function(a){null==a&&(a=new java.util.Hashtable);this.viewerOptions=a;var b;for(a=a.entrySet().iterator();a.hasNext()&&((b=a.next())||1);)this.htParams.put(b.getKey().toLowerCase(),
b.getValue());this.init()},"java.util.Map");$_M(c$,"jmolReady",function(){System.out.println("Jmol applet "+this.fullName+" ready");this.viewer.getBooleanProperty("__appletReady")});$_M(c$,"destroy",function(){this.gRight=null;J.appletjs.JmolAppletRegistry.checkOut(this.fullName);this.viewer.setModeMouse(-1);this.viewer.getBooleanProperty("__appletDestroyed");this.viewer=null;System.out.println("Jmol applet "+this.fullName+" destroyed")});$_M(c$,"setStereoGraphics",function(){return null},"~B");$_M(c$,
"init",function(){this.jmol=this;this.htmlName=this.getParameter("name");this.syncId=this.getParameter("syncId");this.fullName=this.htmlName+"__"+this.syncId+"__";System.out.println("Jmol JavaScript applet "+this.fullName+" initializing");this.setLogging();J.i18n.GT.ignoreApplicationBundle();this.viewerOptions.remove("debug");this.viewerOptions.put("fullName",this.fullName);this.haveDocumentAccess="true".equalsIgnoreCase(""+this.getValue("allowjavascript","true"));J.appletjs.JmolAppletRegistry.checkIn(this.fullName,
this);this.initWindows();this.initApplication()});$_M(c$,"initWindows",($fz=function(){this.viewerOptions.put("applet",Boolean.TRUE);null==this.getParameter("statusListener")&&this.viewerOptions.put("statusListener",Clazz.innerTypeInstance(J.appletjs.Jmol.MyStatusListener,this,null));this.viewer=new J.viewer.Viewer(this.viewerOptions);this.mayScript=!0},$fz.isPrivate=!0,$fz));$_M(c$,"initApplication",($fz=function(){this.viewer.pushHoldRepaint();var a=this.getValueLowerCase("emulate","jmol");this.setStringProperty("defaults",
a.equals("chime")?"RasMol":"Jmol");this.setStringProperty("backgroundColor",this.getValue("bgcolor",this.getValue("boxbgcolor","black")));this.loading=!0;for(var b,a=0,c=J.constant.EnumCallback.values();a<c.length&&((b=c[a])||1);a++)this.setValue(b.name()+"Callback",null);this.loading=!1;this.language=this.getParameter("language");null!=this.language&&(System.out.println("requested language="+this.language),new J.i18n.GT(this.language));this.doTranslate=!"none".equals(this.language)&&this.getBooleanValue("doTranslate",
!0);this.language=J.i18n.GT.getLanguage();System.out.println("language="+this.language);null==this.b$.get(J.constant.EnumCallback.SCRIPT)&&null==this.b$.get(J.constant.EnumCallback.ERROR)&&null!=this.b$.get(J.constant.EnumCallback.MESSAGE)&&(this.doTranslate&&null==this.getValue("doTranslate",null)&&(this.doTranslate=!1,J.util.Logger.warn("Note -- Presence of message callback disables translation; to enable message translation use jmolSetTranslation(true) prior to jmolApplet()")),this.doTranslate&&
J.util.Logger.warn("Note -- Automatic language translation may affect parsing of message callbacks messages; use scriptCallback or errorCallback to process errors"));this.doTranslate||(J.i18n.GT.setDoTranslate(!1),J.util.Logger.warn("Note -- language translation disabled"));this.getBooleanValue("popupMenu",!0)||this.viewer.getProperty("DATA_API","disablePopupMenu",null);b=this.getValue("script","");this.viewer.popHoldRepaint("applet init");0<b.length&&this.scriptProcessor(b,null,1);this.jmolReady()},
$fz.isPrivate=!0,$fz));$_M(c$,"setLogging",($fz=function(){var a=this.getValue("logLevel",this.getBooleanValue("debug",!1)?"5":"4").charCodeAt(0)-48;4!=a&&System.out.println("setting logLevel="+a+' -- To change, use script "set logLevel [0-5]"');J.util.Logger.setLogLevel(a)},$fz.isPrivate=!0,$fz));$_M(c$,"getParameter",($fz=function(a){a=this.htParams.get(a.toLowerCase());return null==a?null:String.instantialize(a.toString())},$fz.isPrivate=!0,$fz),"~S");$_M(c$,"getBooleanValue",($fz=function(a,b){var c=
this.getValue(a,b?"true":"");return c.equalsIgnoreCase("true")||c.equalsIgnoreCase("on")||c.equalsIgnoreCase("yes")},$fz.isPrivate=!0,$fz),"~S,~B");$_M(c$,"getValue",($fz=function(a,b){var c=this.getParameter(a);System.out.println("getValue "+a+" = "+c);return null!=c?c:b},$fz.isPrivate=!0,$fz),"~S,~S");$_M(c$,"getValueLowerCase",($fz=function(a,b){var c=this.getValue(a,b);null!=c&&(c=c.trim().toLowerCase(),0==c.length&&(c=null));return c},$fz.isPrivate=!0,$fz),"~S,~S");$_M(c$,"setValue",($fz=function(a,
b){this.setStringProperty(a,this.getValue(a,b))},$fz.isPrivate=!0,$fz),"~S,~S");$_M(c$,"setStringProperty",($fz=function(a,b){null!=b&&(J.util.Logger.info(a+' = "'+b+'"'),this.viewer.setStringProperty(a,b))},$fz.isPrivate=!0,$fz),"~S,~S");$_M(c$,"sendJsTextStatus",function(a){System.out.println(a)},"~S");$_M(c$,"sendJsTextareaStatus",function(a){System.out.println(a)},"~S");$_M(c$,"handleEvent",function(a){return null==this.viewer?!1:this.viewer.handleOldJvm10Event(a.id,a.x,a.y,a.modifiers,a.when)},
"java.awt.Event");$_M(c$,"scriptProcessor",($fz=function(a,b,c){if(null==a||0==a.length)return"";switch(c){case 0:return a=this.viewer.scriptCheck(a),Clazz.instanceOf(a,String)?a:"";case 1:return null!=b?this.viewer.scriptWaitStatus(a,b).toString():this.viewer.scriptWait(a);default:return this.viewer.script(a)}},$fz.isPrivate=!0,$fz),"~S,~S,~N");$_M(c$,"script",function(a){this.scriptNoWait(a)},"~S");$_M(c$,"scriptNoWait",function(a){return null==a||0==a.length?"":this.scriptProcessor(a,null,2)},
"~S");$_M(c$,"scriptCheck",function(a){return null==a||0==a.length?"":this.scriptProcessor(a,null,0)},"~S");$_M(c$,"scriptWait",function(a){return this.scriptWait(a,null)},"~S");$_M(c$,"scriptWait",function(a,b){if(null==a||0==a.length)return"";this.outputBuffer=null;return this.scriptProcessor(a,b,1)},"~S,~S");$_M(c$,"scriptWaitOutput",function(a){if(null==a||0==a.length)return"";this.outputBuffer=new JU.SB;this.viewer.scriptWaitStatus(a,"");a=null==this.outputBuffer?"":this.outputBuffer.toString();
this.outputBuffer=null;return a},"~S");$_M(c$,"syncScript",function(a){this.viewer.syncScript(a,"~",0)},"~S");$_M(c$,"getAppletInfo",function(){return J.i18n.GT._("Jmol Applet version {0} {1}.\n\nAn OpenScience project.\n\nSee http://www.jmol.org for more information",[J.viewer.JC.version,J.viewer.JC.date])+"\nhtmlName = "+J.util.Escape.eS(this.htmlName)+"\nsyncId = "+J.util.Escape.eS(this.syncId)+"\ndocumentBase = "+J.util.Escape.eS(""+this.getProperty("documentBase"))+"\ncodeBase = "+J.util.Escape.eS(""+
this.getProperty("codeBase"))});Clazz.overrideMethod(c$,"getProperty",function(a,b){b||(b="");return this.viewer.getProperty(null,a,b)},"~S,~S");Clazz.overrideMethod(c$,"getPropertyAsString",function(a,b){b||(b="");return this.viewer.getProperty("readable",a,b).toString()},"~S,~S");Clazz.overrideMethod(c$,"getPropertyAsJSON",function(a,b){b||(b="");return this.viewer.getProperty("JSON",a,b).toString()},"~S,~S");$_M(c$,"loadInlineString",function(a,b,c){a=this.viewer.loadInlineAppend(a,c);null==a&&
this.script(b);return a},"~S,~S,~B");$_M(c$,"loadInlineArray",function(a,b,c){if(null==a||0==a.length)return null;a=this.viewer.loadInline(a,c);null==a&&this.script(b);return a},"~A,~S,~B");c$.sendCallback=$_M(c$,"sendCallback",function(a,b,c){if(!(null==b||0==b.length))if(b.equals("alert"))alert(a);else{a=J.util.Txt.split(b,".");try{var d=window[a[0]];for(I=1;I<a.length;I++)d=d[a[I]];return d(c[0],c[1],c[2],c[3],c[4],c[5],c[6],c[7])}catch(e){System.out.println(b+" failed "+e)}}return""},"~S,~S,~A");
Clazz.overrideMethod(c$,"register",function(a,b){J.appletjs.JmolAppletRegistry.checkIn(a,b)},"~S,J.api.JmolSyncInterface");c$.$Jmol$MyStatusListener$=function(){Clazz.pu$h();c$=Clazz.decorateAsClass(function(){Clazz.prepareCallback(this,arguments);this.haveNotifiedError=!1;Clazz.instantialize(this,arguments)},J.appletjs.Jmol,"MyStatusListener",null,J.api.JmolStatusListener);Clazz.overrideMethod(c$,"getRegistryInfo",function(){J.appletjs.JmolAppletRegistry.checkIn(null,null);return J.appletjs.JmolAppletRegistry.htRegistry});
Clazz.overrideMethod(c$,"resizeInnerPanel",function(){return new javajs.awt.Dimension(0,0)},"~S");Clazz.overrideMethod(c$,"notifyEnabled",function(a){switch(a){case J.constant.EnumCallback.ANIMFRAME:case J.constant.EnumCallback.ECHO:case J.constant.EnumCallback.ERROR:case J.constant.EnumCallback.EVAL:case J.constant.EnumCallback.LOADSTRUCT:case J.constant.EnumCallback.MEASURE:case J.constant.EnumCallback.MESSAGE:case J.constant.EnumCallback.PICK:case J.constant.EnumCallback.STRUCTUREMODIFIED:case J.constant.EnumCallback.SYNC:case J.constant.EnumCallback.SCRIPT:return!0}return null!=
this.b$["J.appletjs.Jmol"].b$.get(a)},"J.constant.EnumCallback");$_M(c$,"notifyCallback",function(a,b){var c=this.b$["J.appletjs.Jmol"].b$.get(a),d=null!=c&&(null==b||null==b[0]),e=!1;null!=b&&(b[0]=this.b$["J.appletjs.Jmol"].htmlName);var f=null==b||null==b[1]?null:b[1].toString();switch(a){case J.constant.EnumCallback.APPLETREADY:b[3]=this.b$["J.appletjs.Jmol"].jmol;break;case J.constant.EnumCallback.CLICK:"alert".equals(c)&&(f="x="+b[1]+" y="+b[2]+" action="+b[3]+" clickCount="+b[4]);break;case J.constant.EnumCallback.ANIMFRAME:var g=
b[1],h=g[0],k=g[1],l=g[2],m=g[3],g=g[4],n=-2>=h,q=0>m?-1:1,p=0>g?-1:1;d&&(b=[this.b$["J.appletjs.Jmol"].htmlName,Integer.$valueOf(Math.max(h,-2-h)),Integer.$valueOf(k),Integer.$valueOf(l),Integer.$valueOf(Math.abs(m)),Integer.$valueOf(Math.abs(g)),Integer.$valueOf(n?1:0),Integer.$valueOf(q),Integer.$valueOf(p)]);break;case J.constant.EnumCallback.ECHO:k=(h=2==b.length)||1==b[2].intValue();d||(k&&(e=!0),d=!h&&null!=(c=this.b$["J.appletjs.Jmol"].b$.get(a=J.constant.EnumCallback.MESSAGE)));e||this.output(f);
break;case J.constant.EnumCallback.LOADSTRUCT:h=b[4];if(null!=h){h=(0<=h.indexOf("NOTE:")?"":J.i18n.GT._("File Error:"))+h;this.showStatus(h);this.notifyCallback(J.constant.EnumCallback.MESSAGE,["",h]);return}break;case J.constant.EnumCallback.MEASURE:d||(d=null!=(c=this.b$["J.appletjs.Jmol"].b$.get(a=J.constant.EnumCallback.MESSAGE)));h=b[3];0<=h.indexOf("Picked")||0<=h.indexOf("Sequence")?(this.showStatus(f),e=!0):0<=h.indexOf("Completed")&&(f=h+": "+f,e=!0);break;case J.constant.EnumCallback.MESSAGE:e=
!d;d=(new Boolean(d&null!=f)).valueOf();e||this.output(f);break;case J.constant.EnumCallback.PICK:this.showStatus(f);e=!0;break;case J.constant.EnumCallback.SCRIPT:0<b[3].intValue()?this.notifyScriptTermination():d||(d=null!=(c=this.b$["J.appletjs.Jmol"].b$.get(a=J.constant.EnumCallback.MESSAGE)));this.output(f);this.showStatus(f);break;case J.constant.EnumCallback.STRUCTUREMODIFIED:this.notifyStructureModified(b[1].intValue(),b[2].intValue());break;case J.constant.EnumCallback.SYNC:this.sendScript(f,
b[2],!0,d);return}e&&(e=this.b$["J.appletjs.Jmol"].viewer.getProperty("DATA_API","getAppConsole",null),null!=e&&(e.notifyCallback(a,b),this.output(f),this.b$["J.appletjs.Jmol"].sendJsTextareaStatus(f)));if(d&&this.b$["J.appletjs.Jmol"].mayScript&&!(null==c||!this.b$["J.appletjs.Jmol"].haveDocumentAccess&&!c.startsWith("Jmol.")))try{J.appletjs.Jmol.sendCallback(f,c,b)}catch(r){if(Clazz.exceptionOf(r,Exception))this.haveNotifiedError||J.util.Logger.debugging&&J.util.Logger.debug(a.name()+"Callback call error to "+
c+": "+r),this.haveNotifiedError=!0;else throw r;}},"J.constant.EnumCallback,~A");$_M(c$,"notifyStructureModified",($fz=function(){},$fz.isPrivate=!0,$fz),"~N,~N");$_M(c$,"output",($fz=function(a){null!=this.b$["J.appletjs.Jmol"].outputBuffer&&null!=a&&this.b$["J.appletjs.Jmol"].outputBuffer.append(a).appendC("\n")},$fz.isPrivate=!0,$fz),"~S");$_M(c$,"notifyScriptTermination",($fz=function(){},$fz.isPrivate=!0,$fz));$_M(c$,"notifySync",($fz=function(a,b){var c=this.b$["J.appletjs.Jmol"].b$.get(J.constant.EnumCallback.SYNC);
if(!this.b$["J.appletjs.Jmol"].mayScript||null==c||!this.b$["J.appletjs.Jmol"].haveDocumentAccess&&!c.startsWith("Jmol."))return a;J.util.Logger.info("Jmol.notifySync "+b+" >> "+a);try{return eval(syncCallback)(this.htmlName,info,appletName)}catch(d){if(Clazz.exceptionOf(d,Exception))this.haveNotifiedError||J.util.Logger.debugging&&J.util.Logger.debug("syncCallback call error to "+c+": "+d),this.haveNotifiedError=!0;else throw d;}return a},$fz.isPrivate=!0,$fz),"~S,~S");Clazz.overrideMethod(c$,"setCallbackFunction",
function(a,b){if(!a.equalsIgnoreCase("modelkit"))if(a.equalsIgnoreCase("language"))this.consoleMessage(""),this.consoleMessage(null);else{var c=J.constant.EnumCallback.getCallback(a);null!=c&&(this.b$["J.appletjs.Jmol"].loading||c!==J.constant.EnumCallback.EVAL)?null==b?this.b$["J.appletjs.Jmol"].b$.remove(c):this.b$["J.appletjs.Jmol"].b$.put(c,b):this.consoleMessage("Available callbacks include: "+J.constant.EnumCallback.getNameList().$replace(";"," ").trim())}},"~S,~S");Clazz.overrideMethod(c$,
"eval",function(a){var b=a.indexOf("\u0001");if(0<=b)return this.sendScript(a.substring(b+1),a.substring(0,b),!1,!1);if(!this.b$["J.appletjs.Jmol"].haveDocumentAccess)return"NO EVAL ALLOWED";if(null!=this.b$["J.appletjs.Jmol"].b$.get(J.constant.EnumCallback.EVAL))return this.notifyCallback(J.constant.EnumCallback.EVAL,[null,a]),"";try{return""+eval(a)}catch(c){if(Clazz.exceptionOf(c,Exception))J.util.Logger.error("# error evaluating "+a+":"+c.toString());else throw c;}return""},"~S");Clazz.overrideMethod(c$,
"createImage",function(){return null},"~S,~S,~O,~N");Clazz.overrideMethod(c$,"functionXY",function(a,b,c){a=Clazz.newFloatArray(Math.abs(b),Math.abs(c),0);if(!this.b$["J.appletjs.Jmol"].mayScript||!this.b$["J.appletjs.Jmol"].haveDocumentAccess||0==b||0==c)return a;try{if(0<b&&0<c)for(var d=0;d<b;d++)for(var e=0;e<c;e++)fxy[g][j]=eval(functionName)(this.htmlName,g,j);else if(0<c){data=eval(functionName)(this.htmlName,nX,nY);b=Math.abs(b);e=Clazz.newFloatArray(b*c,0);J.util.ParserBS.parseStringInfestedFloatArray(d,
null,e);for(var f=d=0;d<b;d++)for(var g=0;g<c;g++,f++)a[d][g]=e[f]}else data=eval(functionName)(htmlName,nX,nY,fxy)}catch(h){if(Clazz.exceptionOf(h,Exception))J.util.Logger.error("Exception "+h+" with nX, nY: "+b+" "+c);else throw h;}return a},"~S,~N,~N");Clazz.overrideMethod(c$,"functionXYZ",function(a,b,c,d){var e=Clazz.newFloatArray(Math.abs(b),Math.abs(c),Math.abs(d),0);if(!this.b$["J.appletjs.Jmol"].mayScript||!this.b$["J.appletjs.Jmol"].haveDocumentAccess||0==b||0==c||0==d)return e;try{eval(functionName)(this.htmlName,
nX,nY,nZ,fxyz)}catch(f){if(Clazz.exceptionOf(f,Exception))J.util.Logger.error("Exception "+f+" for "+a+" with nX, nY, nZ: "+b+" "+c+" "+d);else throw f;}return e},"~S,~N,~N,~N");Clazz.overrideMethod(c$,"showUrl",function(a){J.util.Logger.debugging&&J.util.Logger.debug("showUrl("+a+")");if(null!=a&&0<a.length)try{new java.net.URL(Clazz.castNullAs("java.net.URL"),a,null),window.open(url)}catch(b){if(Clazz.exceptionOf(b,java.net.MalformedURLException))this.consoleMessage("Malformed URL:"+a);else throw b;
}},"~S");$_M(c$,"finalize",function(){J.util.Logger.debugging&&J.util.Logger.debug("MyStatusListener finalize "+this);Clazz.superCall(this,J.appletjs.Jmol.MyStatusListener,"finalize",[])});$_M(c$,"showStatus",($fz=function(a){try{System.out.println(a)}catch(b){if(!Clazz.exceptionOf(b,Exception))throw b;}},$fz.isPrivate=!0,$fz),"~S");$_M(c$,"consoleMessage",($fz=function(a){this.notifyCallback(J.constant.EnumCallback.ECHO,["",a])},$fz.isPrivate=!0,$fz),"~S");$_M(c$,"sendScript",($fz=function(a,b,c,
d){if(d&&(a=this.notifySync(a,b),null==a||0==a.length||a.equals("0")))return"";var e=new JU.List;J.appletjs.JmolAppletRegistry.findApplets(b,this.b$["J.appletjs.Jmol"].syncId,this.b$["J.appletjs.Jmol"].fullName,e);var f=e.size();if(0==f)return!d&&!b.equals("*")&&J.util.Logger.error(this.b$["J.appletjs.Jmol"].fullName+" couldn't find applet "+b),"";b=c?null:new JU.SB;d=c&&a.equals("GET_GRAPHICS");var g=c&&a.equals("SET_GRAPHICS_OFF");d&&(this.b$["J.appletjs.Jmol"].gRight=null);for(var h=0;h<f;h++){var k=
e.get(h),l=J.appletjs.JmolAppletRegistry.htRegistry.get(k);J.util.Logger.debugging&&J.util.Logger.debug(this.b$["J.appletjs.Jmol"].fullName+" sending to "+k+": "+a);try{if(d||g)return this.b$["J.appletjs.Jmol"].gRight=l.setStereoGraphics(d),"";c?l.syncScript(a):b.append(l.scriptWait(a,"output")).append("\n")}catch(m){if(Clazz.exceptionOf(m,Exception))k=this.b$["J.appletjs.Jmol"].htmlName+" couldn't send to "+k+": "+a+": "+m,J.util.Logger.error(k),c||b.append(k);else throw m;}}return c?"":b.toString()},
$fz.isPrivate=!0,$fz),"~S,~S,~B,~B");Clazz.overrideMethod(c$,"getProperty",function(){return null},"~S");c$=Clazz.p0p()};Clazz.defineStatics(c$,"SCRIPT_CHECK",0,"SCRIPT_WAIT",1,"SCRIPT_NOWAIT",2)}),Clazz.declarePackage("J.appletjs"),Clazz.load(["java.util.Hashtable"],"J.appletjs.JmolAppletRegistry",["J.util.Logger","$.Txt"],function(){c$=Clazz.declareType(J.appletjs,"JmolAppletRegistry");c$.checkIn=$_M(c$,"checkIn",function(a,b){Jmol._htRegistry?J.appletjs.JmolAppletRegistry.htRegistry=Jmol._htRegistry:
Jmol._htRegistry=J.appletjs.JmolAppletRegistry.htRegistry;J.appletjs.JmolAppletRegistry.cleanRegistry();null!=a&&(J.util.Logger.info("AppletRegistry.checkIn("+a+")"),J.appletjs.JmolAppletRegistry.htRegistry.put(a,b));if(J.util.Logger.debugging)for(var c,d=J.appletjs.JmolAppletRegistry.htRegistry.entrySet().iterator();d.hasNext()&&((c=d.next())||1);){var e=c.getKey();J.util.Logger.debug(e+" "+c.getValue())}},"~S,J.api.JmolSyncInterface");c$.checkOut=$_M(c$,"checkOut",function(a){J.appletjs.JmolAppletRegistry.htRegistry.remove(a)},
"~S");c$.findApplets=$_M(c$,"findApplets",function(a,b,c,d){if(null!=a&&0<=a.indexOf(",")){var e=J.util.Txt.split(a,",");for(a=0;a<e.length;a++)J.appletjs.JmolAppletRegistry.findApplets(e[a],b,c,d)}else if(b="__"+b+"__",null==a||a.equals("*")||a.equals(">"))for(b=J.appletjs.JmolAppletRegistry.htRegistry.keySet().iterator();b.hasNext()&&((e=b.next())||1);)e.equals(c)||d.addLast(e);else 0>a.indexOf("__")&&(a+=b),J.appletjs.JmolAppletRegistry.htRegistry.containsKey(a)||(a="jmolApplet"+a),!a.equals(c)&&
J.appletjs.JmolAppletRegistry.htRegistry.containsKey(a)&&d.addLast(a)},"~S,~S,~S,JU.List");c$.cleanRegistry=$_M(c$,"cleanRegistry",($fz=function(){},$fz.isPrivate=!0,$fz));c$.htRegistry=c$.prototype.htRegistry=new java.util.Hashtable}),$_L(null,"java.lang.Enum",["java.lang.CloneNotSupportedException","$.IllegalArgumentException","$.NullPointerException","java.security.AccessController","$.PrivilegedExceptionAction"],function(){c$=$_C(function(){this.$name=null;this.$ordinal=0;$_Z(this,arguments)},
java.lang,"Enum",null,[java.io.Serializable,Comparable]);$_K(c$,function(a,b){this.$name=a;this.$ordinal=b},"~S,~N");$_M(c$,"name",function(){return this.$name});$_M(c$,"ordinal",function(){return this.$ordinal});$_V(c$,"toString",function(){return this.$name});$_V(c$,"equals",function(a){return this===a},"~O");$_V(c$,"hashCode",function(){return this.$ordinal+(null==this.$name?0:this.$name.hashCode())});$_V(c$,"clone",function(){throw new CloneNotSupportedException("KA004");});$_V(c$,"compareTo",
function(a){return this.$ordinal-a.$ordinal},"~O");$_M(c$,"getDeclaringClass",function(){var a=this.getClass(),b=a.getSuperclass();return Enum===b?a:b});c$.$valueOf=$_M(c$,"$valueOf",function(a,b){if(null==a||null==b)throw new NullPointerException("KA001");var c=Enum.getValues(a);if(null==c)throw new IllegalArgumentException("KA005");for(var d,e=0;e<c.length&&((d=c[e])||1);e++)if(d.$name.equals(b))return d;throw new IllegalArgumentException("KA006");},"Class,~S");c$.getValues=$_M(c$,"getValues",function(a){try{return java.security.AccessController.doPrivileged(($_D("Enum$1")?
0:java.lang.Enum.$Enum$1$(),$_N(Enum$1,this,$_F("enumType",a)))).invoke(a,Clazz.castNullAs("Array"))}catch(b){if($_O(b,Exception))return null;throw b;}},"Class");c$.$Enum$1$=function(){$_H();c$=$_W(null,"Enum$1",null,java.security.PrivilegedExceptionAction);$_V(c$,"run",function(){var a=this.f$.enumType.getMethod("values",null);a.setAccessible(!0);return a});c$=$_P()}}),Clazz.declarePackage("J.constant"),Clazz.load(["java.lang.Enum"],"J.constant.EnumCallback",["JU.SB"],function(){c$=Clazz.declareType(J.constant,
"EnumCallback",Enum);c$.getCallback=$_M(c$,"getCallback",function(a){a=a.toUpperCase();a=a.substring(0,Math.max(a.indexOf("CALLBACK"),0));for(var b,c=0,d=J.constant.EnumCallback.values();c<d.length&&((b=d[c])||1);c++)if(b.name().equalsIgnoreCase(a))return b;return null},"~S");c$.getNameList=$_M(c$,"getNameList",function(){if(null==J.constant.EnumCallback.nameList){for(var a=new JU.SB,b,c=0,d=J.constant.EnumCallback.values();c<d.length&&((b=d[c])||1);c++)a.append(b.name().toLowerCase()).append("Callback;");
$t$=J.constant.EnumCallback.nameList=a.toString();J.constant.EnumCallback.prototype.nameList=J.constant.EnumCallback.nameList;$t$}return J.constant.EnumCallback.nameList});c$.nameList=null;Clazz.defineEnumConstant(c$,"ANIMFRAME",0,[]);Clazz.defineEnumConstant(c$,"APPLETREADY",1,[]);Clazz.defineEnumConstant(c$,"ATOMMOVED",2,[]);Clazz.defineEnumConstant(c$,"CLICK",3,[]);Clazz.defineEnumConstant(c$,"ECHO",4,[]);Clazz.defineEnumConstant(c$,"ERROR",5,[]);Clazz.defineEnumConstant(c$,"EVAL",6,[]);Clazz.defineEnumConstant(c$,
"HOVER",7,[]);Clazz.defineEnumConstant(c$,"LOADSTRUCT",8,[]);Clazz.defineEnumConstant(c$,"MEASURE",9,[]);Clazz.defineEnumConstant(c$,"MESSAGE",10,[]);Clazz.defineEnumConstant(c$,"MINIMIZATION",11,[]);Clazz.defineEnumConstant(c$,"PICK",12,[]);Clazz.defineEnumConstant(c$,"RESIZE",13,[]);Clazz.defineEnumConstant(c$,"SCRIPT",14,[]);Clazz.defineEnumConstant(c$,"SYNC",15,[]);Clazz.defineEnumConstant(c$,"STRUCTUREMODIFIED",16,[])}),Clazz.declarePackage("J.util"),Clazz.load(null,"J.util.Escape","java.lang.Character $.Float JU.List $.M3 $.M4 $.P3 $.P4 $.ParserJS $.SB J.script.SV J.util.BSUtil $.Parser $.Txt".split(" "),
function(){c$=Clazz.declareType(J.util,"Escape");c$.escapeColor=$_M(c$,"escapeColor",function(a){return 0==a?null:"[x"+J.util.Escape.getHexColorFromRGB(a)+"]"},"~N");c$.getHexColorFromRGB=$_M(c$,"getHexColorFromRGB",function(a){if(0==a)return null;var b="00"+Integer.toHexString(a>>16&255),b=b.substring(b.length-2),c="00"+Integer.toHexString(a>>8&255),c=c.substring(c.length-2);a="00"+Integer.toHexString(a&255);a=a.substring(a.length-2);return b+c+a},"~N");c$.eP=$_M(c$,"eP",function(a){return null==
a?"null":"{"+a.x+" "+a.y+" "+a.z+"}"},"JU.T3");c$.matrixToScript=$_M(c$,"matrixToScript",function(a){return J.util.Txt.replaceAllCharacters(a.toString(),"\n\r ","").$replace("\t"," ")},"~O");c$.eP4=$_M(c$,"eP4",function(a){return"{"+a.x+" "+a.y+" "+a.z+" "+a.w+"}"},"JU.P4");c$.e=$_M(c$,"e",function(a){return null==a?"null":Clazz.instanceOf(a,String)?J.util.Escape.eS(a):Clazz.instanceOf(a,JU.List)?J.util.Escape.eV(a):Clazz.instanceOf(a,JU.BS)?J.util.Escape.eBS(a):Clazz.instanceOf(a,JU.T3)?J.util.Escape.eP(a):
Clazz.instanceOf(a,JU.P4)?J.util.Escape.eP4(a):J.util.Escape.isAS(a)?J.util.Escape.eAS(a,!0):J.util.Escape.isAI(a)?J.util.Escape.eAI(a):J.util.Escape.isAF(a)?J.util.Escape.eAF(a):J.util.Escape.isAD(a)?J.util.Escape.eAD(a):J.util.Escape.isAP(a)?J.util.Escape.eAP(a):Clazz.instanceOf(a,JU.M3)||Clazz.instanceOf(a,JU.M4)?J.util.Txt.simpleReplace(a.toString(),"\t",",\t"):Clazz.instanceOf(a,JU.A4)?"{"+a.x+" "+a.y+" "+a.z+" "+180*a.angle/3.141592653589793+"}":Clazz.instanceOf(a,java.util.Map)?J.util.Escape.escapeMap(a):
J.util.Escape.isAII(a)||J.util.Escape.isAFF(a)||J.util.Escape.isAFFF(a)?J.util.Escape.toJSON(null,a):a.toString()},"~O");c$.isAS=$_M(c$,"isAS",function(a){return Clazz.isAS(a)},"~O");c$.isASS=$_M(c$,"isASS",function(a){return Clazz.isASS(a)},"~O");c$.isAP=$_M(c$,"isAP",function(a){return Clazz.isAP(a)},"~O");c$.isAF=$_M(c$,"isAF",function(a){return Clazz.isAF(a)},"~O");c$.isAFloat=$_M(c$,"isAFloat",function(a){return Clazz.isAFloat(a)},"~O");c$.isAV=$_M(c$,"isAV",function(a){return Clazz.instanceOf(a[0],
J.script.SV)},"~O");c$.isAD=$_M(c$,"isAD",function(a){return Clazz.isAF(a)},"~O");c$.isAB=$_M(c$,"isAB",function(a){return Clazz.isAI(a)},"~O");c$.isAI=$_M(c$,"isAI",function(a){return Clazz.isAI(a)},"~O");c$.isAII=$_M(c$,"isAII",function(a){return Clazz.isAII(a)},"~O");c$.isAFF=$_M(c$,"isAFF",function(a){return Clazz.isAFF(a)},"~O");c$.isAFFF=$_M(c$,"isAFFF",function(a){return Clazz.isAFFF(a)},"~O");c$.eS=$_M(c$,"eS",function(a){if(null==a||0==a.length)return'""';for(var b=!1,c=0;10>c;c+=2)if(0<=
a.indexOf('\\\\\tt\rr\nn""'.charAt(c))){b=!0;break}if(b)for(;10>c;){for(var b=-1,d='\\\\\tt\rr\nn""'.charAt(c++),e='\\\\\tt\rr\nn""'.charAt(c++),f=new JU.SB,g=0;0<=(b=a.indexOf(d,b+1));)f.append(a.substring(g,b)).appendC("\\").appendC(e),g=b+1;f.append(a.substring(g,a.length));a=f.toString()}for(c=a.length;0<=--c;)127<a.charCodeAt(c)&&(a=a.substring(0,c)+J.util.Escape.unicode(a.charAt(c))+a.substring(c+1));return'"'+a+'"'},"~S");c$.unicode=$_M(c$,"unicode",($fz=function(a){a="0000"+Integer.toHexString(a.charCodeAt(0));
return"\\u"+a.substring(a.length-4)},$fz.isPrivate=!0,$fz),"~S");c$.eV=$_M(c$,"eV",function(a){if(null==a)return J.util.Escape.eS("");var b=new JU.SB;b.append("[");for(var c=0;c<a.size();c++)0<c&&b.append(", "),b.append(J.util.Escape.escapeNice(a.get(c).asString()));b.append("]");return b.toString()},"JU.List");c$.escapeMap=$_M(c$,"escapeMap",function(a){var b=new JU.SB;b.append("{ ");var c="",d;for(a=a.entrySet().iterator();a.hasNext()&&((d=a.next())||1);){var e=d.getKey();b.append(c).append(J.util.Escape.eS(e)).appendC(":");
c=d.getValue();Clazz.instanceOf(c,J.script.SV)||(c=J.script.SV.getVariable(c));b.append(c.escape());c=","}b.append(" }");return b.toString()},"java.util.Map");c$.escapeFloatA=$_M(c$,"escapeFloatA",function(a,b){if(b)return J.util.Escape.toJSON(null,a);for(var c=new JU.SB,d=0;d<a.length;d++)0<d&&c.appendC("\n"),c.appendF(a[d]);return c.toString()},"~A,~B");c$.escapeFloatAA=$_M(c$,"escapeFloatAA",function(a,b){for(var c=new JU.SB,d=b?";\n":"\n",e=0;e<a.length;e++)if(null!=a[e]){0<e&&c.append(d);for(var f=
0;f<a[e].length;f++)c.appendF(a[e][f]).appendC("\t")}return c.toString()},"~A,~B");c$.escapeFloatAAA=$_M(c$,"escapeFloatAAA",function(a,b){var c=new JU.SB,d=b?";\n":"\n";if(null==a[0]||null==a[0][0])return"0 0 0"+d;c.appendI(a.length).append(" ").appendI(a[0].length).append(" ").appendI(a[0][0].length);for(var e=0;e<a.length;e++)if(null!=a[e]){c.append(d);for(var f=0;f<a[e].length;f++)if(null!=a[e][f]){c.append(d);for(var g=0;g<a[e][f].length;g++)c.appendF(a[e][f][g]).appendC("\t")}}return c.toString()},
"~A,~B");c$.eAS=$_M(c$,"eAS",function(a,b){if(null==a)return J.util.Escape.eS("");var c=new JU.SB;c.append("[");for(var d=0;d<a.length;d++)0<d&&c.append(", "),c.append(b?J.util.Escape.escapeNice(a[d]):J.util.Escape.eS(a[d]));c.append("]");return c.toString()},"~A,~B");c$.eAI=$_M(c$,"eAI",function(a){if(null==a)return J.util.Escape.eS("");var b=new JU.SB;b.append("[");for(var c=0;c<a.length;c++)0<c&&b.append(", "),b.appendI(a[c]);return b.append("]").toString()},"~A");c$.eAD=$_M(c$,"eAD",function(a){if(null==
a)return J.util.Escape.eS("");var b=new JU.SB;b.append("[");for(var c=0;c<a.length;c++)0<c&&b.append(", "),b.appendD(a[c]);return b.append("]").toString()},"~A");c$.eAF=$_M(c$,"eAF",function(a){if(null==a)return J.util.Escape.eS("");var b=new JU.SB;b.append("[");for(var c=0;c<a.length;c++)0<c&&b.append(", "),b.appendF(a[c]);return b.append("]").toString()},"~A");c$.eAP=$_M(c$,"eAP",function(a){if(null==a)return J.util.Escape.eS("");var b=new JU.SB;b.append("[");for(var c=0;c<a.length;c++)0<c&&b.append(", "),
b.append(J.util.Escape.eP(a[c]));return b.append("]").toString()},"~A");c$.escapeNice=$_M(c$,"escapeNice",($fz=function(a){if(null==a)return"null";var b=JU.ParserJS.parseFloatStrict(a);return Float.isNaN(b)?J.util.Escape.eS(a):a},$fz.isPrivate=!0,$fz),"~S");c$.unescapePointOrBitsetOrMatrixOrArray=$_M(c$,"unescapePointOrBitsetOrMatrixOrArray",function(a){return"{"==a.charAt(0)?J.util.Escape.uP(a):(J.util.Escape.isStringArray(a)||a.startsWith("[{")&&a.indexOf("[{")==a.lastIndexOf("[{"))&&0>a.indexOf(",")&&
0>a.indexOf(".")&&0>a.indexOf("-")?J.util.Escape.uB(a):a.startsWith("[[")?J.util.Escape.unescapeMatrix(a):a},"~S");c$.isStringArray=$_M(c$,"isStringArray",function(a){return a.startsWith("({")&&0==a.lastIndexOf("({")&&a.indexOf("})")==a.length-2},"~S");c$.uP=$_M(c$,"uP",function(a){if(null==a||0==a.length)return a;var b=a.$replace("\n"," ").trim();if("{"!=b.charAt(0)||"}"!=b.charAt(b.length-1))return a;for(var c=Clazz.newFloatArray(5,0),d=0,b=b.substring(1,b.length-1),e=Clazz.newIntArray(1,0);5>d;d++)if(c[d]=
JU.ParserJS.parseFloatNext(b,e),Float.isNaN(c[d])){if(e[0]>=b.length||","!=b.charAt(e[0]))break;e[0]++;d--}return 3==d?JU.P3.new3(c[0],c[1],c[2]):4==d?JU.P4.new4(c[0],c[1],c[2],c[3]):a},"~S");c$.uB=$_M(c$,"uB",function(a){var b,c;if(null==a||4>(c=(a=a.trim()).length)||a.equalsIgnoreCase("({null})")||"("!=(b=a.charAt(0))&&"["!=b||a.charAt(c-1)!=("("==b?")":"]")||"{"!=a.charAt(1)||a.indexOf("}")!=c-2)return null;for(var d=c-=2;2<=--d;)if(!Character.isDigit(b=a.charAt(d))&&" "!=b&&"\t"!=b&&":"!=b)return null;
for(var e=c;Character.isDigit(a.charAt(--e)););if(++e==c)e=0;else try{e=Integer.parseInt(a.substring(e,c))}catch(f){if(Clazz.exceptionOf(f,NumberFormatException))return null;throw f;}for(var g=J.util.BSUtil.newBitSet(e),h=e=-1,k=-2,d=2;d<=c;d++)switch(b=a.charAt(d)){case "\t":case " ":case "}":if(0>k)break;if(k<e)return null;e=k;0>h&&(h=k);g.setBits(h,k+1);h=-1;k=-2;break;case ":":h=e=k;k=-2;break;default:Character.isDigit(b)&&(0>k&&(k=0),k=10*k+(b.charCodeAt(0)-48))}return 0<=h?null:g},"~S");c$.unescapeMatrix=
$_M(c$,"unescapeMatrix",function(a){if(null==a||0==a.length)return a;var b=a.$replace("\n"," ").trim();if(0!=b.lastIndexOf("[[")||b.indexOf("]]")!=b.length-2)return a;for(var c=Clazz.newFloatArray(16,0),b=b.substring(2,b.length-2).$replace("["," ").$replace("]"," ").$replace(","," "),d=Clazz.newIntArray(1,0),e=0;16>e&&!(c[e]=JU.ParserJS.parseFloatNext(b,d),Float.isNaN(c[e]));e++);return!Float.isNaN(JU.ParserJS.parseFloatNext(b,d))?a:9==e?JU.M3.newA(c):16==e?JU.M4.newA(c):a},"~S");c$.eBS=$_M(c$,"eBS",
function(a){return J.util.Escape.eB(a,"(",")")},"JU.BS");c$.eBond=$_M(c$,"eBond",function(a){return J.util.Escape.eB(a,"[","]")},"JU.BS");c$.eB=$_M(c$,"eB",($fz=function(a,b,c){if(null==a)return b+"{}"+c;var d=new JU.SB;d.append(b+"{");b=a.length();for(var e=-1,f=-2,g=-1;++g<=b;){var h=a.get(g);if(g==b||0<=e&&!h){0<=e&&f!=e&&d.append((f==e-1?" ":":")+e);if(g==b)break;e=-1}a.get(g)&&(0>e&&(d.append((-2==f?"":" ")+g),f=g),e=g)}d.append("}").appendC(c);return d.toString()},$fz.isPrivate=!0,$fz),"JU.BS,~S,~S");
c$.packageJSONSb=$_M(c$,"packageJSONSb",($fz=function(a,b){return J.util.Escape.packageJSON(a,b.toString())},$fz.isPrivate=!0,$fz),"~S,JU.SB");c$.packageJSON=$_M(c$,"packageJSON",($fz=function(a,b){return null==a?b:'"'+a+'": '+b},$fz.isPrivate=!0,$fz),"~S,~S");c$.fixString=$_M(c$,"fixString",($fz=function(a){if("undefined"==typeof a)return"null";if(null==a||0==a.indexOf('{"'))return a;a=J.util.Txt.simpleReplace(a,'"',"''");a=J.util.Txt.simpleReplace(a,"\n"," | ");return'"'+a+'"'},$fz.isPrivate=!0,
$fz),"~S");c$.toJSON=$_M(c$,"toJSON",function(a,b){var c=new JU.SB,d="";if(null==b)return J.util.Escape.packageJSON(a,null);if(Clazz.instanceOf(b,Integer)||Clazz.instanceOf(b,Float)||Clazz.instanceOf(b,Double))return J.util.Escape.packageJSON(a,b.toString());if(Clazz.instanceOf(b,String))return J.util.Escape.packageJSON(a,J.util.Escape.fixString(b));if(J.util.Escape.isAS(b)){c.append("[");for(var e=b.length,f=0;f<e;f++)c.append(d).append(J.util.Escape.fixString(b[f])),d=",";c.append("]");return J.util.Escape.packageJSONSb(a,
c)}if(J.util.Escape.isAI(b)){c.append("[");e=b.length;for(f=0;f<e;f++)c.append(d).appendI(b[f]),d=",";c.append("]");return J.util.Escape.packageJSONSb(a,c)}if(J.util.Escape.isAF(b)){c.append("[");e=b.length;for(f=0;f<e;f++)c.append(d).appendF(b[f]),d=",";c.append("]");return J.util.Escape.packageJSONSb(a,c)}if(J.util.Escape.isAD(b)){c.append("[");e=b.length;for(f=0;f<e;f++)c.append(d).appendD(b[f]),d=",";c.append("]");return J.util.Escape.packageJSONSb(a,c)}if(J.util.Escape.isAP(b)){c.append("[");
e=b.length;for(f=0;f<e;f++)c.append(d),J.util.Escape.addJsonTuple(c,b[f]),d=",";c.append("]");return J.util.Escape.packageJSONSb(a,c)}if(J.util.Escape.isASS(b)){c.append("[");e=b.length;for(f=0;f<e;f++)c.append(d).append(J.util.Escape.toJSON(null,b[f])),d=",";c.append("]");return J.util.Escape.packageJSONSb(a,c)}if(J.util.Escape.isAII(b)){c.append("[");e=b.length;for(f=0;f<e;f++)c.append(d).append(J.util.Escape.toJSON(null,b[f])),d=",";c.append("]");return J.util.Escape.packageJSONSb(a,c)}if(J.util.Escape.isAFF(b)){c.append("[");
e=b.length;for(f=0;f<e;f++)c.append(d).append(J.util.Escape.toJSON(null,b[f])),d=",";c.append("]");return J.util.Escape.packageJSONSb(a,c)}if(J.util.Escape.isAFFF(b)){c.append("[");e=b.length;for(f=0;f<e;f++)c.append(d).append(J.util.Escape.toJSON(null,b[f])),d=",";c.append("]");return J.util.Escape.packageJSONSb(a,c)}if(Clazz.instanceOf(b,JU.List)){c.append("[ ");e=b.size();for(f=0;f<e;f++)c.append(d).append(J.util.Escape.toJSON(null,b.get(f))),d=",";c.append(" ]");return J.util.Escape.packageJSONSb(a,
c)}if(Clazz.instanceOf(b,JU.M4)){d=Clazz.newFloatArray(4,0);c.appendC("[");for(f=0;4>f;f++)0<f&&c.appendC(","),b.getRow(f,d),c.append(J.util.Escape.toJSON(null,d));c.appendC("]");return J.util.Escape.packageJSONSb(a,c)}if(Clazz.instanceOf(b,JU.M3)){d=Clazz.newFloatArray(3,0);c.appendC("[");for(f=0;3>f;f++)0<f&&c.appendC(","),b.getRow(f,d),c.append(J.util.Escape.toJSON(null,d));c.appendC("]");return J.util.Escape.packageJSONSb(a,c)}if(Clazz.instanceOf(b,JU.T3))return J.util.Escape.addJsonTuple(c,b),
J.util.Escape.packageJSONSb(a,c);if(Clazz.instanceOf(b,JU.A4))return c.append("[").appendF(b.x).append(",").appendF(b.y).append(",").appendF(b.z).append(",").appendF(180*b.angle/3.141592653589793).append("]"),J.util.Escape.packageJSONSb(a,c);if(Clazz.instanceOf(b,JU.P4))return c.append("[").appendF(b.x).append(",").appendF(b.y).append(",").appendF(b.z).append(",").appendF(b.w).append("]"),J.util.Escape.packageJSONSb(a,c);if(Clazz.instanceOf(b,java.util.Map)){c.append("{ ");for(e=b.keySet().iterator();e.hasNext()&&
((f=e.next())||1);)c.append(d).append(J.util.Escape.packageJSON(f,J.util.Escape.toJSON(null,b.get(f)))),d=",";c.append(" }");return J.util.Escape.packageJSONSb(a,c)}return J.util.Escape.packageJSON(a,J.util.Escape.fixString(b.toString()))},"~S,~O");c$.addJsonTuple=$_M(c$,"addJsonTuple",($fz=function(a,b){a.append("[").appendF(b.x).append(",").appendF(b.y).append(",").appendF(b.z).append("]")},$fz.isPrivate=!0,$fz),"JU.SB,JU.T3");c$.toReadable=$_M(c$,"toReadable",function(a,b){var c=new JU.SB,d="";
if(null==b)return"null";if(Clazz.instanceOf(b,String))return J.util.Escape.packageReadable(a,null,J.util.Escape.eS(b));if(J.util.Escape.isAS(b)){c.append("[");for(var e=b.length,f=0;f<e;f++)c.append(d).append(J.util.Escape.eS(b[f])),d=",";c.append("]");return J.util.Escape.packageReadableSb(a,"String["+e+"]",c)}if(J.util.Escape.isAI(b)){c.append("[");e=b.length;for(f=0;f<e;f++)c.append(d).appendI(b[f]),d=",";c.append("]");return J.util.Escape.packageReadableSb(a,"int["+e+"]",c)}if(J.util.Escape.isAF(b)){c.append("[");
e=b.length;for(f=0;f<e;f++)c.append(d).appendF(b[f]),d=",";c.append("]");return J.util.Escape.packageReadableSb(a,"float["+e+"]",c)}if(J.util.Escape.isAD(b)){c.append("[");e=b.length;for(f=0;f<e;f++)c.append(d).appendD(b[f]),d=",";c.append("]");return J.util.Escape.packageReadableSb(a,"double["+e+"]",c)}if(J.util.Escape.isAP(b)){c.append("[");e=b.length;for(f=0;f<e;f++)c.append(d).append(J.util.Escape.eP(b[f])),d=",";c.append("]");return J.util.Escape.packageReadableSb(a,"point3f["+e+"]",c)}if(J.util.Escape.isASS(b)){c.append("[");
e=b.length;for(f=0;f<e;f++)c.append(d).append(J.util.Escape.toReadable(null,b[f])),d=",\n";c.append("]");return J.util.Escape.packageReadableSb(a,"String["+e+"][]",c)}if(J.util.Escape.isAII(b)){c.append("[");e=b.length;for(f=0;f<e;f++)c.append(d).append(J.util.Escape.toReadable(null,b[f])),d=",";c.append("]");return J.util.Escape.packageReadableSb(a,"int["+e+"][]",c)}if(J.util.Escape.isAFF(b)){c.append("[\n");e=b.length;for(f=0;f<e;f++)c.append(d).append(J.util.Escape.toReadable(null,b[f])),d=",\n";
c.append("]");return J.util.Escape.packageReadableSb(a,"float[][]",c)}if(Clazz.instanceOf(b,JU.List)){e=b.size();for(f=0;f<e;f++)c.append(J.util.Escape.toReadable(a+"["+(f+1)+"]",b.get(f)));return J.util.Escape.packageReadableSb(a,"List["+e+"]",c)}if(Clazz.instanceOf(b,JU.M3)||Clazz.instanceOf(b,JU.T3)||Clazz.instanceOf(b,JU.P4)||Clazz.instanceOf(b,JU.A4))return c.append(J.util.Escape.e(b)),J.util.Escape.packageReadableSb(a,null,c);if(Clazz.instanceOf(b,java.util.Map)){for(d=b.keySet().iterator();d.hasNext();)e=
d.next(),c.append(J.util.Escape.toReadable((null==a?"":a+".")+e,b.get(e)));return c.toString()}return J.util.Escape.packageReadable(a,null,b.toString())},"~S,~O");c$.packageReadableSb=$_M(c$,"packageReadableSb",($fz=function(a,b,c){return J.util.Escape.packageReadable(a,b,c.toString())},$fz.isPrivate=!0,$fz),"~S,~S,JU.SB");c$.packageReadable=$_M(c$,"packageReadable",($fz=function(a,b,c){return null==a?(null==b?"":b+"\t")+c:"\n"+a+"\t"+(null==b?"":"*"+b+"\t")+c},$fz.isPrivate=!0,$fz),"~S,~S,~S");c$.escapeModelFileNumber=
$_M(c$,"escapeModelFileNumber",function(a){return""+Clazz.doubleToInt(a/1E6)+"."+a%1E6},"~N");c$.encapsulateData=$_M(c$,"encapsulateData",function(a,b,c){return'  DATA "'+a+'"\n'+(2==c?J.util.Escape.escapeFloatAA(b,!0)+";\n":3==c?J.util.Escape.escapeFloatAAA(b,!0)+";\n":b)+'    END "'+a+'";\n'},"~S,~O,~N");c$.unescapeUnicode=$_M(c$,"unescapeUnicode",function(a){for(var b=a.length,c=JU.SB.newN(b),d=0;d<b;){var e=a.charAt(d++);if("\\"==e&&d<b)switch(e=a.charAt(d++),e){case "u":if(d<b){for(var e=0,f=
4;0<=--f&&d<b;){var g=a.charAt(d),g=J.util.Escape.getHexitValue(g);if(0>g)break;e<<=4;e+=g;++d}e=String.fromCharCode(e)}}c.appendC(e)}return c.toString()},"~S");c$.getHexitValue=$_M(c$,"getHexitValue",function(a){return 48<=a.charCodeAt(0)&&57>=a.charCodeAt(0)?a.charCodeAt(0)-48:97<=a.charCodeAt(0)&&102>=a.charCodeAt(0)?10+a.charCodeAt(0)-97:65<=a.charCodeAt(0)&&70>=a.charCodeAt(0)?10+a.charCodeAt(0)-65:-1},"~S");c$.unescapeStringArray=$_M(c$,"unescapeStringArray",function(a){if(null==a||!a.startsWith("[")||
!a.endsWith("]"))return null;var b=new JU.List,c=Clazz.newIntArray(1,0);for(c[0]=1;c[0]<a.length;){var d=J.util.Parser.getQuotedStringNext(a,c);if(null==d)return null;for(b.addLast(J.util.Txt.simpleReplace(d,'\\"','"'));c[0]<a.length&&'"'!=a.charAt(c[0]);)c[0]++}return b.toArray(Array(b.size()))},"~S");c$.escapeUrl=$_M(c$,"escapeUrl",function(a){a=J.util.Txt.simpleReplace(a,"\n","");a=J.util.Txt.simpleReplace(a,"%","%25");a=J.util.Txt.simpleReplace(a,"[","%5B");a=J.util.Txt.simpleReplace(a,"]","%5D");
return a=J.util.Txt.simpleReplace(a," ","%20")},"~S");Clazz.defineStatics(c$,"escapable",'\\\\\tt\rr\nn""')}),Clazz.declarePackage("J.util"),Clazz.load(null,"J.util.Parser",["JU.ArrayUtil","$.ParserJS","J.util.Logger","$.Txt"],function(){c$=Clazz.declareType(J.util,"Parser");c$.fixDataString=$_M(c$,"fixDataString",function(a){a=a.$replace(";",0>a.indexOf("\n")?"\n":" ");a=J.util.Txt.trim(a,"\n \t");a=J.util.Txt.simpleReplace(a,"\n ","\n");return a=J.util.Txt.simpleReplace(a,"\n\n","\n")},"~S");c$.getQuotedStringAt=
$_M(c$,"getQuotedStringAt",function(a,b){return J.util.Parser.getQuotedStringNext(a,[b])},"~S,~N");c$.getQuotedStringNext=$_M(c$,"getQuotedStringNext",function(a,b){var c=a,d=b[0];if(0>d||0>(d=c.indexOf('"',d)))return"";b[0]=++d;c=c.substring(d);for(d=-1;++d<c.length&&'"'!=c.charAt(d);)"\\"==c.charAt(d)&&d++;b[0]+=d+1;return c.substring(0,d)},"~S,~A");c$.isOneOf=$_M(c$,"isOneOf",function(a,b){if(0==b.length)return!1;";"!=b.charAt(0)&&(b=";"+b+";");return 0>a.indexOf(";")&&0<=b.indexOf(";"+a+";")},
"~S,~S");c$.getQuotedAttribute=$_M(c$,"getQuotedAttribute",function(a,b){var c=a.indexOf(b+"=");return 0>c?null:J.util.Parser.getQuotedStringAt(a,c)},"~S,~S");c$.approx=$_M(c$,"approx",function(a,b){return Math.round(a*b)/b},"~N,~N");c$.parseFloatArray2d=$_M(c$,"parseFloatArray2d",function(a){a=J.util.Parser.fixDataString(a);for(var b=J.util.Parser.markLines(a,"\n"),c=b.length,d=JU.ArrayUtil.newFloat2(c),e=0,f=0;e<c;f=b[e++])f=JU.ParserJS.getTokens(a.substring(f,b[e])),JU.ParserJS.parseFloatArrayData(f,
d[e]=Clazz.newFloatArray(f.length,0));return d},"~S");c$.parseFloatArray3d=$_M(c$,"parseFloatArray3d",function(a){a=J.util.Parser.fixDataString(a);var b=J.util.Parser.markLines(a,"\n"),c=b.length,d=JU.ParserJS.getTokens(a.substring(0,b[0]));if(3!=d.length)return Clazz.newFloatArray(0,0,0,0);var e=JU.ParserJS.parseInt(d[0]),f=JU.ParserJS.parseInt(d[1]),g=JU.ParserJS.parseInt(d[2]);if(1>e||1>f||1>g)return Clazz.newFloatArray(1,1,1,0);for(var h=JU.ArrayUtil.newFloat3(e,f),k=0,l=0,m=1,d=b[0];m<c&&k<e;d=
b[m++])d=JU.ParserJS.getTokens(a.substring(d,b[m])),d.length<g||(JU.ParserJS.parseFloatArrayData(d,h[k][l]=Clazz.newFloatArray(d.length,0)),++l==f&&(k++,l=0));return k!=e?(J.util.Logger.info("Error reading 3D data -- nX = "+e+", but only "+k+" blocks read"),Clazz.newFloatArray(1,1,1,0)):h},"~S");c$.markLines=$_M(c$,"markLines",function(a,b){for(var c=0,d=a.length;0<=--d;)a.charAt(d)==b&&c++;for(var d=Clazz.newIntArray(c+1,0),e=c=0;0<=(e=a.indexOf(b,e));)d[c++]=++e;d[c]=a.length;return d},"~S,~S");
Clazz.defineStatics(c$,"FLOAT_MIN_SAFE",2E-45)}),Clazz.declarePackage("J.util"),Clazz.load(null,"J.util.Txt",["java.lang.Character","$.Double","$.Float","JU.DecimalFormat","$.SB"],function(){c$=Clazz.declareType(J.util,"Txt");c$.formatF=$_M(c$,"formatF",function(a,b,c,d,e){return J.util.Txt.formatS(JU.DecimalFormat.formatDecimal(a,c),b,0,d,e)},"~N,~N,~N,~B,~B");c$.formatD=$_M(c$,"formatD",function(a,b,c,d,e){return J.util.Txt.formatS(JU.DecimalFormat.formatDecimal(a,-1-c),b,0,d,e)},"~N,~N,~N,~B,~B,~B");
c$.formatS=$_M(c$,"formatS",function(a,b,c,d,e){if(null==a)return"";var f=a.length;2147483647!=c&&0<c&&c<f?a=a.substring(0,c):0>c&&0<=f+c&&(a=a.substring(f+c+1));c=b-a.length;if(0>=c)return a;b=e&&!d&&"-"==a.charAt(0);e=e?"0":" ";var g=b?"-":e,f=new JU.SB;d&&f.append(a);for(f.appendC(g);0<--c;)f.appendC(e);d||f.append(b?e+a.substring(1):a);return f.toString()},"~S,~N,~N,~B,~B");c$.formatStringS=$_M(c$,"formatStringS",function(a,b,c){return J.util.Txt.formatString(a,b,c,NaN,NaN,!1)},"~S,~S,~S");c$.formatStringF=
$_M(c$,"formatStringF",function(a,b,c){return J.util.Txt.formatString(a,b,null,c,NaN,!1)},"~S,~S,~N");c$.formatStringI=$_M(c$,"formatStringI",function(a,b,c){return J.util.Txt.formatString(a,b,""+c,NaN,NaN,!1)},"~S,~S,~N");c$.sprintf=$_M(c$,"sprintf",function(a,b,c){if(null==c)return a;var d=b.length;if(d==c.length)try{for(var e=0;e<d;e++)if(null!=c[e])switch(b.charAt(e)){case "s":a=J.util.Txt.formatString(a,"s",c[e],NaN,NaN,!0);break;case "f":a=J.util.Txt.formatString(a,"f",null,c[e].floatValue(),
NaN,!0);break;case "i":a=J.util.Txt.formatString(a,"d",""+c[e],NaN,NaN,!0);a=J.util.Txt.formatString(a,"i",""+c[e],NaN,NaN,!0);break;case "d":a=J.util.Txt.formatString(a,"e",null,NaN,c[e].doubleValue(),!0);break;case "p":var f=c[e];a=J.util.Txt.formatString(a,"p",null,f.x,NaN,!0);a=J.util.Txt.formatString(a,"p",null,f.y,NaN,!0);a=J.util.Txt.formatString(a,"p",null,f.z,NaN,!0);break;case "q":var g=c[e];a=J.util.Txt.formatString(a,"q",null,g.x,NaN,!0);a=J.util.Txt.formatString(a,"q",null,g.y,NaN,!0);
a=J.util.Txt.formatString(a,"q",null,g.z,NaN,!0);a=J.util.Txt.formatString(a,"q",null,g.w,NaN,!0);break;case "S":for(var h=c[e],k=0;k<h.length;k++)a=J.util.Txt.formatString(a,"s",h[k],NaN,NaN,!0);break;case "F":for(var l=c[e],k=0;k<l.length;k++)a=J.util.Txt.formatString(a,"f",null,l[k],NaN,!0);break;case "I":for(var m=c[e],k=0;k<m.length;k++)a=J.util.Txt.formatString(a,"d",""+m[k],NaN,NaN,!0);for(k=0;k<m.length;k++)a=J.util.Txt.formatString(a,"i",""+m[k],NaN,NaN,!0);break;case "D":for(var n=c[e],
k=0;k<n.length;k++)a=J.util.Txt.formatString(a,"e",null,NaN,n[k],!0)}return J.util.Txt.simpleReplace(a,"%%","%")}catch(q){if(!Clazz.exceptionOf(q,Exception))throw q;}System.out.println("TextFormat.sprintf error "+b+" "+a);return J.util.Txt.simpleReplace(a,"%","?")},"~S,~S,~A");c$.formatString=$_M(c$,"formatString",($fz=function(a,b,c,d,e,f){if(null==a)return null;if("".equals(a))return"";var g=b.length;if(0>a.indexOf("%")||0==g||0>a.indexOf(b))return a;var h="",k,l,m;for(k=0;0<=(l=a.indexOf("%",k))&&
0<=(m=a.indexOf(b,l+1));)if(k!=l&&(h+=a.substring(k,l)),k=l+1,m>l+6)h+="%";else try{var n=!1;"-"==a.charAt(k)&&(n=!0,++k);var q=!1;"0"==a.charAt(k)&&(q=!0,++k);for(var p,r=0;"0"<=(p=a.charAt(k))&&"9">=p;)r=10*r+(p.charCodeAt(0)-48),++k;var s=2147483647,t=!1;if("."==a.charAt(k)){++k;if("-"==(p=a.charAt(k)))t=!0,++k;if("0"<=(p=a.charAt(k))&&"9">=p)s=p.charCodeAt(0)-48,++k;t&&(s=-s-(null==c?1:0))}if(a.substring(k,k+g).equals(b)){if(k+=g,Float.isNaN(d)?null!=c?h+=J.util.Txt.formatS(c,r,s,n,q):Double.isNaN(e)||
(h+=J.util.Txt.formatD(e,r,s,n,q,!0)):h+=J.util.Txt.formatF(d,r,s,n,q),f)break}else k=l+1,h+="%"}catch(u){if(Clazz.exceptionOf(u,IndexOutOfBoundsException)){k=l;break}else throw u;}return h+=a.substring(k)},$fz.isPrivate=!0,$fz),"~S,~S,~S,~N,~N,~B");c$.formatCheck=$_M(c$,"formatCheck",function(a){if(null==a||0>a.indexOf("p")&&0>a.indexOf("q"))return a;a=J.util.Txt.simpleReplace(a,"%%","\u0001");a=J.util.Txt.simpleReplace(a,"%p","%6.2p");a=J.util.Txt.simpleReplace(a,"%q","%6.2q");a=J.util.Txt.split(a,
"%");var b=new JU.SB;b.append(a[0]);for(var c=1;c<a.length;c++){var d="%"+a[c],e;if(3<=d.length){if(0<=(e=d.indexOf("p")))d=J.util.Txt.fdup(d,e,3);if(0<=(e=d.indexOf("q")))d=J.util.Txt.fdup(d,e,4)}b.append(d)}return b.toString().$replace("\u0001","%")},"~S");c$.fdup=$_M(c$,"fdup",($fz=function(a,b,c){for(var d,e=0,f=b;1<=--f;)if(!Character.isDigit(d=a.charAt(f)))switch(d){case ".":if(0!=e++)return a;continue;case "-":if(1!=f)return a;continue;default:return a}d=a.substring(0,b+1);e=new JU.SB;for(f=
0;f<c;f++)e.append(d);e.append(a.substring(b+1));return e.toString()},$fz.isPrivate=!0,$fz),"~S,~N,~N");c$.split=$_M(c$,"split",function(a,b){if(0==a.length)return[];var c=1,d=a.indexOf(b),e,f=b.length;if(0>d||0==f)return e=Array(1),e[0]=a,e;for(var g=a.length-f;0<=d&&d<g;c++)d=a.indexOf(b,d+f);e=Array(c);for(var h=d=0,k=0;0<=(h=a.indexOf(b,d))&&k+1<c;)e[k++]=a.substring(d,h),d=h+f;a.indexOf(b,g)!=g&&(g+=f);e[k]=a.substring(d,g);return e},"~S,~S");c$.replaceAllCharacters=$_M(c$,"replaceAllCharacters",
function(a,b,c){for(var d=b.length;0<=--d;){var e=b.substring(d,d+1);a=J.util.Txt.simpleReplace(a,e,c)}return a},"~S,~S,~S");c$.replaceAllCharacter=$_M(c$,"replaceAllCharacter",function(a,b,c){if(null==a)return null;for(var d=b.length;0<=--d;)a=a.$replace(b.charAt(d),c);return a},"~S,~S,~S");c$.simpleReplace=$_M(c$,"simpleReplace",function(a,b,c){if(null==a||0==b.length||0>a.indexOf(b))return a;var d=0<=c.indexOf(b);do a=a.$replace(b,c);while(!d&&0<=a.indexOf(b));return a},"~S,~S,~S");c$.trim=$_M(c$,
"trim",function(a,b){if(0==b.length)return a.trim();for(var c=a.length,d=0;d<c&&0<=b.indexOf(a.charAt(d));)d++;for(c=a.length-1;c>d&&0<=b.indexOf(a.charAt(c));)c--;return a.substring(d,c+1)},"~S,~S");c$.leftJustify=$_M(c$,"leftJustify",function(a,b,c){a.append(c);c=b.length-c.length;0<c&&a.append(b.substring(0,c))},"JU.SB,~S,~S");c$.rightJustify=$_M(c$,"rightJustify",function(a,b,c){var d=b.length-c.length;0<d&&a.append(b.substring(0,d));a.append(c)},"JU.SB,~S,~S");c$.safeTruncate=$_M(c$,"safeTruncate",
function(a,b){-0.001<a&&0.001>a&&(a=0);return(a+"         ").substring(0,b)},"~N,~N");c$.isWild=$_M(c$,"isWild",function(a){return null!=a&&(0<=a.indexOf("*")||0<=a.indexOf("?"))},"~S");c$.isMatch=$_M(c$,"isMatch",function(a,b,c,d){var e=0,f=b.length,g=a.length;if(0==g||0==f)return g==f||1==f&&"*"==b.charAt(0);if((e=c&&d?"*"==b.charAt(0):!1)&&"*"==b.charAt(f-1))return 3>f||0<=a.indexOf(b.substring(1,f-1));for(var h="????";h.length<a.length;)h+=h;if(c){d&&e&&(b=h+b.substring(1));if("*"==b.charAt(e=
b.length-1))b=b.substring(0,e)+h;f=b.length}if(f<g)return!1;for(e=0;f>g;){if(d&&"?"==b.charAt(e))++e;else if("?"!=b.charAt(e+f-1))return!1;--f}for(c=g;0<=--c;)if(d=b.charAt(e+c),"?"!=d&&d!=a.charAt(c)&&("\u0001"!=d||"?"!=a.charAt(c)))return!1;return!0},"~S,~S,~B,~B");c$.join=$_M(c$,"join",function(a,b,c){if(a.length<c)return null;var d=new JU.SB;for(d.append(a[c++]);c<a.length;c++)d.appendC(b).append(a[c]);return d.toString()},"~A,~S,~N");c$.replaceQuotedStrings=$_M(c$,"replaceQuotedStrings",function(a,
b,c){for(var d=b.size(),e=0;e<d;e++){var f=b.get(e),g=c.get(e);g.equals(f)||(a=J.util.Txt.simpleReplace(a,'"'+f+'"','"'+g+'"'))}return a},"~S,java.util.List,java.util.List");c$.replaceStrings=$_M(c$,"replaceStrings",function(a,b,c){for(var d=b.size(),e=0;e<d;e++){var f=b.get(e),g=c.get(e);g.equals(f)||(a=J.util.Txt.simpleReplace(a,f,g))}return a},"~S,java.util.List,java.util.List");c$.ichMathTerminator=$_M(c$,"ichMathTerminator",function(a,b,c){for(var d=1,e="\x00",f="\x00";0<d&&++b<c;){var g=a.charAt(b);
if("\x00"!=e)"\\"==f?g="\x00":g==e&&(e="\x00"),f=g;else switch(g){case "'":case '"':e=g;break;case "{":d++;break;case "}":d--}}return b},"~S,~N,~N");c$.trimQuotes=$_M(c$,"trimQuotes",function(a){return null!=a&&1<a.length&&a.startsWith('"')&&a.endsWith('"')?a.substring(1,a.length-1):a},"~S")}),Clazz.declarePackage("J.script"),Clazz.load(["java.util.Hashtable"],"J.script.T",["java.lang.Boolean","java.util.Arrays","JU.ArrayUtil","$.List","J.util.Logger"],function(){c$=Clazz.decorateAsClass(function(){this.tok=
0;this.value=null;this.intValue=2147483647;Clazz.instantialize(this,arguments)},J.script,"T");c$.t=$_M(c$,"t",function(a){var b=new J.script.T;b.tok=a;return b},"~N");c$.tv=$_M(c$,"tv",function(a,b,c){a=J.script.T.t(a);a.intValue=b;a.value=c;return a},"~N,~N,~O");c$.o=$_M(c$,"o",function(a,b){var c=J.script.T.t(a);c.value=b;return c},"~N,~O");c$.n=$_M(c$,"n",function(a,b){var c=J.script.T.t(a);c.intValue=b;return c},"~N,~N");c$.i=$_M(c$,"i",function(a){var b=J.script.T.t(2);b.intValue=a;return b},
"~N");c$.tokAttr=$_M(c$,"tokAttr",function(a,b){return(a&b)==(b&b)},"~N,~N");c$.tokAttrOr=$_M(c$,"tokAttrOr",function(a,b,c){return(a&b)==(b&b)||(a&c)==(c&c)},"~N,~N,~N");c$.getPrecedence=$_M(c$,"getPrecedence",function(a){return a>>4&15},"~N");c$.getMaxMathParams=$_M(c$,"getMaxMathParams",function(a){return a>>9&7},"~N");c$.addToken=$_M(c$,"addToken",function(a,b){J.script.T.tokenMap.put(a,b)},"~S,J.script.T");c$.getTokenFromName=$_M(c$,"getTokenFromName",function(a){return J.script.T.tokenMap.get(a)},
"~S");c$.getTokFromName=$_M(c$,"getTokFromName",function(a){a=J.script.T.getTokenFromName(a.toLowerCase());return null==a?0:a.tok},"~S");c$.nameOf=$_M(c$,"nameOf",function(a){for(var b,c=J.script.T.tokenMap.values().iterator();c.hasNext()&&((b=c.next())||1);)if(b.tok==a)return""+b.value;return"0x"+Integer.toHexString(a)},"~N");Clazz.overrideMethod(c$,"toString",function(){return this.toString2()});$_M(c$,"toString2",function(){return"Token["+J.script.T.astrType[14>this.tok?this.tok:14]+"("+this.tok%
512+"/0x"+Integer.toHexString(this.tok)+")"+(2147483647==this.intValue?"":" intValue="+this.intValue+"(0x"+Integer.toHexString(this.intValue)+")")+(null==this.value?"":Clazz.instanceOf(this.value,String)?' value="'+this.value+'"':" value="+this.value)+"]"});c$.getCommandSet=$_M(c$,"getCommandSet",function(a){var b="",c=new java.util.Hashtable,d=0;a=null==a||0==a.length?null:a.toLowerCase();for(var e=null!=a&&1<a.length,f,q=J.script.T.tokenMap.entrySet().iterator();q.hasNext()&&((f=q.next())||1);){var p=
f.getKey(),r=f.getValue();0!=(r.tok&4096)&&((null==a||0==p.indexOf(a))&&(e||r.value.equals(p)))&&c.put(p,Boolean.TRUE)}for(q=c.entrySet().iterator();q.hasNext()&&((f=q.next())||1);)if(p=f.getKey(),"s"!=p.charAt(p.length-1)||!c.containsKey(p.substring(0,p.length-1)))b+=(0==d++?"":";")+p;return b},"~S");c$.getAtomPropertiesLike=$_M(c$,"getAtomPropertiesLike",function(a){a=a.toLowerCase();for(var b=new JU.List,c=0==a.length,d,e=J.script.T.tokenMap.entrySet().iterator();e.hasNext()&&((d=e.next())||1);){var f=
d.getKey();if("_"!=f.charAt(0)){var q=d.getValue();if(J.script.T.tokAttr(q.tok,1078984704)&&(c||f.toLowerCase().startsWith(a))){if(c||!q.value.toLowerCase().startsWith(a))q=J.script.T.o(q.tok,f);b.addLast(q)}}}return 0==b.size()?null:b},"~S");c$.getTokensLike=$_M(c$,"getTokensLike",function(a){a=a.equals("setparam")?536870912:a.equals("misc")?1073741824:a.equals("mathfunc")?135266304:4096;for(var b=536870912==a?1610612736:0,c=new JU.List,d,e=J.script.T.tokenMap.entrySet().iterator();e.hasNext()&&
((d=e.next())||1);){var f=d.getKey(),q=d.getValue();J.script.T.tokAttr(q.tok,a)&&(0==b||!J.script.T.tokAttr(q.tok,b))&&c.addLast(f)}d=c.toArray(Array(c.size()));java.util.Arrays.sort(d);return d},"~S");c$.getSettableTokFromString=$_M(c$,"getSettableTokFromString",function(a){a=J.script.T.getTokFromName(a);return 0!=a&&J.script.T.tokAttr(a,2048)&&!J.script.T.tokAttr(a,1141899264)?a:0},"~S");c$.completeCommand=$_M(c$,"completeCommand",function(a,b,c,d,e){null==a?a=J.script.T.tokenMap:c=!1;var f=new JU.List;
d=d.toLowerCase();var q;for(a=a.keySet().iterator();a.hasNext()&&((q=a.next())||1);)if(q.startsWith(d)){var p=J.script.T.getTokFromName(q);(c?J.script.T.tokAttr(p,4096):b?J.script.T.tokAttr(p,536870912)&&!J.script.T.tokAttr(p,1610612736):1)&&f.addLast(q)}return JU.ArrayUtil.sortedItem(f,e)},"java.util.Map,~B,~B,~S,~N");c$.getParamType=$_M(c$,"getParamType",function(a){return!J.script.T.tokAttr(a,536870912)?0:a&662700032},"~N");c$.getTokensType=$_M(c$,"getTokensType",function(a,b){for(var c,d=J.script.T.tokenMap.entrySet().iterator();d.hasNext()&&
((c=d.next())||1);){var e=c.getValue();J.script.T.tokAttr(e.tok,b)&&a.put(c.getKey(),c.getValue())}},"java.util.Map,~N");c$.isIDcmd=$_M(c$,"isIDcmd",function(a){switch(a){case 135180:case 135176:case 135174:case 135188:case 135402505:return!0;default:return!1}},"~N");Clazz.defineStatics(c$,"nada",0,"integer",2,"decimal",3,"string",4,"seqcode",5,"hash",6,"varray",7,"point3f",8,"point4f",9,"bitset",10,"matrix3f",11,"matrix4f",12,"listf",13,"keyword",14,"astrType","nada identifier integer decimal string seqcode hash array point point4 bitset matrix3f matrix4f listf keyword".split(" "),
"setparam",536870912,"misc",1073741824,"deprecatedparam",1610612736,"identifier",1073741824,"scriptCommand",4096,"atomExpressionCommand",12288,"implicitStringCommand",20480,"mathExpressionCommand",36864,"flowCommand",102400,"shapeCommand",135168,"noArgs",262144,"defaultON",524288,"expression",1048576,"predefinedset",3145728,"atomproperty",1078984704,"strproperty",1087373312,"intproperty",1095761920,"floatproperty",1112539136,"PROPERTYFLAGS",1137704960,"strparam",545259520,"intparam",553648128,"floatparam",
570425344,"booleanparam",603979776,"paramTypes",662700032,"mathproperty",1141899264,"mathfunc",135266304,"mathop",269484032,"comparator",269484288,"center",12289,"define",1060866,"$delete",12291,"display",1610625028,"fixed",1060869,"hide",12294,"restrict",12295,"subset",3158024,"zap",1060873,"print",36865,"returncmd",36866,"set",1085443,"$var",36868,"log",36869,"echo",537022465,"help",20482,"hover",544771,"message",20485,"pause",20487,"elseif",102402,"elsecmd",364547,"endifcmd",364548,"whilecmd",
102406,"breakcmd",102407,"continuecmd",102408,"end",1150985,"switchcmd",102410,"casecmd",102411,"catchcmd",102412,"defaultcmd",102413,"trycmd",364558,"animation",4097,"assign",4098,"background",1610616835,"bind",4100,"bondorder",4101,"calculate",4102,"capture",4103,"cd",1069064,"centerAt",4105,"connect",4106,"console",528395,"delay",528397,"depth",554176526,"exit",266255,"exitjmol",266256,"font",4114,"frame",4115,"gotocmd",20500,"hbond",1612189718,"history",1610616855,"initialize",266264,"invertSelected",
4121,"loop",528410,"mapProperty",1052700,"minimize",4126,"move",4128,"moveto",4130,"navigate",4131,"parallel",102436,"plot",4133,"pop",266278,"process",102439,"push",266280,"quit",266281,"ramachandran",1052714,"redomove",4139,"refresh",266284,"reset",4141,"restore",4142,"resume",266287,"rotate",528432,"rotateSelected",4145,"save",4146,"selectionhalos",1611141171,"show",4148,"slab",554176565,"spin",1611141175,"ssbond",1611141176,"step",266298,"stereo",528443,"sync",4156,"timeout",536875070,"translate",
4160,"translateSelected",4162,"unbind",4164,"undomove",4165,"vibration",4166,"zoom",4168,"zoomTo",4170,"axes",1611272194,"cgo",135174,"dipole",135175,"draw",135176,"frank",1611272202,"isosurface",135180,"lcaocartoon",135182,"measurements",537006096,"mo",1183762,"pmesh",135188,"plot3d",135190,"polyhedra",135192,"struts",1708058,"unitcell",1614417948,"vector",135198,"wireframe",659488,"expressionBegin",1048577,"expressionEnd",1048578,"all",1048579,"branch",1048580,"coord",1048582,"dollarsign",1048583,
"per",1048584,"isaromatic",1048585,"leftbrace",1048586,"none",1048587,"off",1048588,"on",1048589,"rightbrace",1048590,"semicolon",1048591,"spec_alternate",1048607,"spec_atom",1048608,"spec_chain",1048609,"spec_model",1048610,"spec_model2",1048611,"spec_name_pattern",1048612,"spec_resid",1048613,"spec_seqcode",1048614,"spec_seqcode_range",1048615,"amino",3145730,"dna",3145732,"hetero",1613758470,"helixalpha",3145735,"helix310",3145736,"helixpi",3145738,"hydrogen",1613758476,"nucleic",3145742,"protein",
3145744,"purine",3145746,"pyrimidine",3145748,"rna",3145750,"solvent",1613758488,"sidechain",3145754,"surface",3145756,"thismodel",3145758,"sheet",3145760,"spine",3145762,"carbohydrate",3145764,"clickable",3145766,"displayed",3145768,"hidden",3145770,"specialposition",3145772,"visible",3145774,"basemodel",3145776,"nonequivalent",3145778,"leftparen",269484048,"rightparen",269484049,"opIf",806354977,"colon",269484066,"comma",269484080,"leftsquare",269484096,"rightsquare",269484097,"opOr",269484112,
"opXor",269484113,"opToggle",269484114,"opAnd",269484128,"opNot",269484144,"opAND",269484160,"opGT",269484432,"opGE",269484433,"opLE",269484434,"opLT",269484435,"opEQ",269484436,"opNE",269484438,"minus",269484192,"plus",269484193,"divide",269484208,"times",269484209,"percent",269484210,"leftdivide",269484211,"unaryMinus",269484224,"minusMinus",269484225,"plusPlus",269484226,"timestimes",269484227,"propselector",269484241,"andequals",269484242,"minmaxmask",480,"min",32,"max",64,"average",96,"sum",
128,"sum2",160,"stddev",192,"selectedfloat",224,"allfloat",256,"settable",2048,"atoms",1141899265,"bonds",1678770178,"length",1141899267,"lines",1141899268,"reverse",1141899269,"size",1141899270,"type",1141899272,"boundbox",1679429641,"xyz",1146095626,"fracxyz",1146095627,"screenxyz",1146095628,"fuxyz",1146095629,"unitxyz",1146093582,"vibxyz",1146095631,"w",1141899280,"keys",1141899281,"occupancy",1129318401,"radius",1666189314,"structure",1641025539,"atomtype",1087375361,"atomname",1087375362,"altloc",
1087373315,"chain",1087373316,"element",1087375365,"group",1087373318,"group1",1087373319,"sequence",1087373320,"identify",1087373321,"insertion",1087373322,"shape",1087373323,"strucid",1087373324,"symbol",1087375373,"symmetry",1089470478,"atomno",1095763969,"atomid",1095761922,"atomindex",1095761923,"bondcount",1095761924,"cell",1095761925,"centroid",1095761926,"configuration",1095766022,"elemisono",1095761927,"elemno",1095763976,"formalcharge",1632634889,"groupid",1095761930,"groupindex",1095761931,
"model",1095766028,"modelindex",1095761933,"molecule",1095761934,"polymer",1095761935,"polymerlength",1095761936,"resno",1095761937,"site",1095761938,"strucno",1095761939,"valence",1095763988,"adpmax",1112539137,"adpmin",1112539138,"chemicalshift",1112539139,"covalent",1112539140,"eta",1112539141,"magneticshielding",1112539142,"mass",1112539143,"omega",1112539144,"phi",1112539145,"psi",1112539146,"screenx",1112539147,"screeny",1112539148,"screenz",1112539149,"straightness",1112539150,"surfacedistance",
1112539151,"theta",1112539152,"unitx",1112539153,"unity",1112539154,"unitz",1112539155,"vectorscale",1649410049,"atomx",1112541185,"atomy",1112541186,"atomz",1112541187,"fracx",1112541188,"fracy",1112541189,"fracz",1112541190,"fux",1112541191,"fuy",1112541192,"fuz",1112541193,"ionic",1112541195,"partialcharge",1112541196,"temperature",1112541199,"vibx",1112541202,"viby",1112541203,"vibz",1112541204,"x",1112541205,"y",1112541206,"z",1112541207,"vanderwaals",1649412120,"property",1716520985,"hydrophobic",
1114638362,"selected",1114638363,"backbone",1115297793,"cartoon",1113200642,"dots",1113198595,"ellipsoid",1113198596,"geosurface",1113198597,"halo",1113200646,"meshRibbon",1113200647,"ribbon",1113200649,"rocket",1113200650,"spacefill",1113200651,"star",1113200652,"strands",1650071565,"trace",1113200654,"angle",135266305,"array",135266306,"axisangle",135266307,"color",1766856708,"compare",135270405,"connected",135266310,"data",135270407,"format",1288701960,"$function",135368713,"getproperty",135270410,
"label",1826248715,"helix",137363468,"measure",1746538509,"now",135266318,"plane",135266319,"point",135266320,"quaternion",135270417,"sort",1276117010,"count",1276117011,"within",135266324,"write",135270421,"cache",135270422,"tensor",1276117015,"modulation",135270424,"acos",135266819,"sin",135266820,"cos",135266821,"sqrt",135266822,"file",1229984263,"forcmd",135369224,"ifcmd",135369225,"abs",135266826,"javascript",135287308,"div",1276117504,"dot",1276117505,"join",1276117506,"mul",1276117507,"split",
1276117508,"sub",1276117509,"trim",1276117510,"volume",1313866247,"col",1276117512,"row",1276117513,"cross",135267329,"load",135271426,"random",135267332,"script",135271429,"substructure",1238369286,"search",135267335,"smiles",135267336,"contact",135402505,"add",1276118017,"distance",1276118018,"replace",1276118019,"hkl",135267841,"intersection",135267842,"prompt",135304707,"select",135280132,"bin",1276118529,"symop",1297090050,"find",1276118531,"bondmode",1610612737,"fontsize",1610612738,"measurementnumbers",
1610612739,"scale3d",1610612740,"togglelabel",1610612741,"backgroundmodel",536870914,"debug",536870916,"defaultlattice",536870918,"highlight",536870920,"showscript",536870922,"specular",536870924,"trajectory",536870926,"undo",536870928,"usercolorscheme",536870930,"animationmode",545259521,"appletproxy",545259522,"atomtypes",545259524,"axescolor",545259526,"axis1color",545259528,"axis2color",545259530,"axis3color",545259532,"backgroundcolor",545259534,"boundboxcolor",545259536,"currentlocalpath",545259538,
"dataseparator",545259540,"defaultanglelabel",545259542,"defaultlabelpdb",545259543,"defaultlabelxyz",545259544,"defaultcolorscheme",545259545,"defaultdirectory",545259546,"defaultdistancelabel",545259547,"defaultdropscript",545259548,"defaultloadfilter",545259549,"defaultloadscript",545259550,"defaults",545259552,"defaulttorsionlabel",545259554,"defaultvdw",545259555,"edsurlcutoff",545259556,"edsurlformat",545259557,"energyunits",545259558,"filecachedirectory",545259559,"forcefield",545259560,"helppath",
545259561,"hoverlabel",545259562,"language",545259564,"loadformat",545259565,"loadligandformat",545259566,"logfile",545259567,"measurementunits",545259568,"nmrpredictformat",545259569,"nmrurlformat",545259570,"pathforallfiles",545259571,"picking",545259572,"pickingstyle",545259574,"picklabel",545259576,"propertycolorscheme",545259578,"quaternionframe",545259580,"smilesurlformat",545259582,"smiles2dimageformat",545259584,"unitcellcolor",545259586,"axesscale",570425346,"bondtolerance",570425348,"cameradepth",
570425350,"defaultdrawarrowscale",570425352,"defaulttranslucent",570425354,"dipolescale",570425355,"drawfontsize",570425356,"ellipsoidaxisdiameter",570425357,"exportscale",570425358,"gestureswipefactor",570425359,"hbondsangleminimum",570425360,"hbondsdistancemaximum",570425361,"hoverdelay",570425362,"loadatomdatatolerance",570425363,"minbonddistance",570425364,"minimizationcriterion",570425365,"mousedragfactor",570425366,"mousewheelfactor",570425367,"multiplebondradiusfactor",570425368,"multiplebondspacing",
570425369,"navfps",570425370,"navigationdepth",570425371,"navigationslab",570425372,"navigationspeed",570425374,"navx",570425376,"navy",570425378,"navz",570425380,"pointgroupdistancetolerance",570425382,"pointgrouplineartolerance",570425384,"rotationradius",570425388,"scaleangstromsperinch",570425390,"sheetsmoothing",570425392,"slabrange",570425393,"solventproberadius",570425394,"spinfps",570425396,"spinx",570425398,"spiny",570425400,"spinz",570425402,"starscale",570425403,"stereodegrees",570425404,
"strutdefaultradius",570425406,"strutlengthmaximum",570425408,"vibrationperiod",570425412,"vibrationscale",570425414,"visualrange",570425416,"ambientpercent",553648130,"animationfps",553648132,"axesmode",553648134,"bondradiusmilliangstroms",553648136,"delaymaximumms",553648138,"diffusepercent",553648142,"dotdensity",553648143,"dotscale",553648144,"ellipsoiddotcount",553648145,"helixstep",553648146,"hermitelevel",553648147,"historylevel",553648148,"isosurfacepropertysmoothingpower",553648149,"loglevel",
553648150,"meshscale",553648151,"minimizationsteps",553648152,"minpixelselradius",553648153,"percentvdwatom",553648154,"perspectivemodel",553648155,"phongexponent",553648156,"pickingspinrate",553648157,"platformspeed",553648158,"propertyatomnumberfield",553648159,"propertyatomnumbercolumncount",553648160,"propertydatacolumncount",553648162,"propertydatafield",553648164,"repaintwaitms",553648165,"ribbonaspectratio",553648166,"scriptreportinglevel",553648168,"smallmoleculemaxatoms",553648170,"specularexponent",
553648172,"specularpercent",553648174,"specularpower",553648176,"strandcount",553648178,"strandcountformeshribbon",553648180,"strandcountforstrands",553648182,"strutspacing",553648184,"zdepth",553648186,"zslab",553648188,"zshadepower",553648190,"allowembeddedscripts",603979778,"allowgestures",603979780,"allowkeystrokes",603979781,"allowmodelkit",603979782,"allowmoveatoms",603979783,"allowmultitouch",603979784,"allowrotateselected",603979785,"antialiasdisplay",603979786,"antialiasimages",603979788,
"antialiastranslucent",603979790,"appendnew",603979792,"applysymmetrytobonds",603979794,"atompicking",603979796,"autobond",603979798,"autofps",603979800,"axesmolecular",603979804,"axesorientationrasmol",603979806,"axesunitcell",603979808,"axeswindow",603979810,"bondmodeor",603979812,"bondpicking",603979814,"cartoonbaseedges",603979817,"cartoonrockets",603979818,"cartoonsfancy",603979819,"cartoonladders",603979820,"celshading",603979821,"chaincasesensitive",603979822,"colorrasmol",603979823,"debugscript",
603979824,"defaultstructuredssp",603979825,"disablepopupmenu",603979826,"displaycellparameters",603979828,"dotsselectedonly",603979829,"dotsurface",603979830,"dragselected",603979831,"drawhover",603979832,"drawpicking",603979833,"dsspcalchydrogen",603979834,"dynamicmeasurements",603979835,"ellipsoidarcs",603979836,"ellipsoidarrows",603979837,"ellipsoidaxes",603979838,"ellipsoidball",603979839,"ellipsoiddots",603979840,"ellipsoidfill",603979841,"filecaching",603979842,"fontcaching",603979844,"fontscaling",
603979845,"forceautobond",603979846,"fractionalrelative",603979848,"greyscalerendering",603979850,"hbondsbackbone",603979852,"hbondsrasmol",603979853,"hbondssolid",603979854,"hidenameinpopup",603979858,"hidenavigationpoint",603979860,"hidenotselected",603979862,"highresolution",603979864,"imagestate",603979868,"iskiosk",603979869,"isosurfacekey",603979870,"isosurfacepropertysmoothing",603979871,"justifymeasurements",603979872,"languagetranslation",603979873,"legacyautobonding",603979874,"legacyhaddition",
603979875,"logcommands",603979876,"loggestures",603979877,"measureallmodels",603979878,"measurementlabels",603979879,"messagestylechime",603979880,"minimizationrefresh",603979881,"minimizationsilent",603979882,"modelkitmode",603979883,"monitorenergy",603979884,"multiprocessor",603979885,"navigatesurface",603979886,"navigationmode",603979887,"navigationperiodic",603979888,"partialdots",603979889,"pdbaddhydrogens",603979890,"pdbgetheader",603979891,"pdbsequential",603979892,"perspectivedepth",603979893,
"preservestate",603979894,"rangeselected",603979895,"refreshing",603979896,"ribbonborder",603979898,"rocketbarrels",603979900,"saveproteinstructurestate",603979902,"scriptqueue",603979904,"selectallmodels",603979906,"selecthetero",603979908,"selecthydrogen",603979910,"showaxes",603979914,"showboundbox",603979916,"showfrank",603979918,"showhiddenselectionhalos",603979920,"showhydrogens",603979922,"showkeystrokes",603979924,"showmeasurements",603979926,"showmultiplebonds",603979928,"shownavigationpointalways",
603979930,"showtiming",603979934,"showunitcell",603979936,"slabbyatom",603979938,"slabbymolecule",603979940,"slabenabled",603979942,"smartaromatic",603979944,"solventprobe",603979948,"ssbondsbackbone",603979952,"statusreporting",603979954,"strutsmultiple",603979955,"syncmouse",603979956,"syncscript",603979958,"testflag1",603979960,"testflag2",603979962,"testflag3",603979964,"testflag4",603979965,"tracealpha",603979966,"translucent",603979967,"twistedsheets",603979968,"usearcball",603979969,"useminimizationthread",
603979970,"usenumberlocalization",603979972,"vectorsymmetry",603979973,"waitformoveto",603979974,"windowcentered",603979975,"wireframerotation",603979976,"zerobasedxyzrasmol",603979978,"zoomenabled",603979980,"zoomheight",603979982,"zoomlarge",603979983,"zshade",603979984,"absolute",1073741826,"addhydrogens",1073741828,"adjust",1073741830,"align",1073741832,"allconnected",1073741834,"angstroms",1073741836,"anisotropy",1073741838,"append",1073741839,"arc",1074790416,"area",1073741842,"aromatic",1076887572,
"arrow",1073741846,"as",1073741848,"atomicorbital",1073741850,"auto",1073741852,"axis",1073741854,"babel",1073741856,"babel21",1073741858,"back",1073741859,"balls",1073741860,"barb",1073741861,"backlit",1073741862,"best",1073741863,"basepair",1073741864,"binary",1073741866,"blockdata",1073741868,"bondset",1073741870,"bottom",1073741871,"brillouin",1073741872,"cancel",1073741874,"cap",1074790451,"cavity",1073741876,"check",1073741878,"chemical",1073741879,"circle",1073741880,"clash",1073741881,"clear",
1073741882,"clipboard",1073741884,"collapsed",1073741886,"colorscheme",1073741888,"command",1073741890,"commands",1073741892,"constraint",1073741894,"contour",1073741896,"contourlines",1073741898,"contours",1073741900,"corners",1073741902,"create",1073741904,"criterion",1073741905,"crossed",1073741906,"curve",1073741908,"cutoff",1073741910,"cylinder",1073741912,"density",1073741914,"dssp",1073741915,"diameter",1073741916,"direction",1073741918,"discrete",1073741920,"displacement",1073741922,"distancefactor",
1073741924,"dotted",1073741926,"downsample",1073741928,"drawing",1073741929,"eccentricity",1073741930,"ed",1074790508,"edges",1073741933,"energy",1073741934,"error",1073741935,"facecenteroffset",1073741937,"fill",1073741938,"filter",1073741940,"first",1073741942,"fixedtemp",1073741946,"flat",1073741948,"fps",1074790526,"from",1073741952,"front",1073741954,"frontedges",1073741956,"frontlit",1073741958,"frontonly",1073741960,"full",1073741961,"fullplane",1073741962,"fullylit",1073741964,"functionxy",
1073741966,"functionxyz",1073741968,"gridpoints",1073741970,"homo",1073741973,"id",1074790550,"ignore",1073741976,"inchi",1073741977,"inchikey",1073741978,"image",1073741979,"$in",1073741980,"increment",1073741981,"info",1073741982,"inline",1073741983,"insideout",1073741984,"interior",1073741986,"internal",1073741988,"intramolecular",1073741989,"intermolecular",1073741990,"jmol",1073741992,"last",1073741993,"lattice",1073741994,"lighting",1073741995,"left",1073741996,"line",1073741998,"link",1073741999,
"linedata",1073742E3,"list",1073742001,"lobe",1073742002,"lonepair",1073742004,"lp",1073742006,"lumo",1073742008,"manifest",1073742010,"maxset",1073742014,"menu",1073742015,"mep",1073742016,"mesh",1073742018,"middle",1073742019,"minset",1073742020,"mlp",1073742022,"mode",1073742024,"modify",1073742025,"modifyorcreate",1073742026,"modelbased",1073742028,"molecular",1073742029,"monomer",1073742030,"morph",1073742031,"movie",1073742032,"mrc",1073742033,"msms",1073742034,"name",1073742035,"nci",1073742036,
"next",1073742037,"nmr",1073742038,"nocontourlines",1073742039,"nocross",1073742040,"nodebug",1073742041,"nodots",1073742042,"noedges",1073742044,"nofill",1073742046,"nohead",1073742048,"noload",1073742050,"nomesh",1073742052,"noplane",1073742054,"normal",1073742056,"notfrontonly",1073742058,"notriangles",1073742060,"obj",1073742062,"object",1073742064,"offset",1073742066,"offsetside",1073742068,"once",1073742070,"only",1073742072,"opaque",1073742074,"options",1073742075,"orbital",1073742076,"orientation",
1073742077,"origin",1073742078,"out",1073742079,"packed",1073742080,"palindrome",1073742082,"parameters",1073742083,"path",1073742084,"pdb",1074790662,"pdbheader",1073742088,"period",1073742090,"perpendicular",1073742092,"phase",1073742094,"play",1073742096,"playrev",1073742098,"pocket",1073742100,"pointgroup",1073742102,"pointsperangstrom",1073742104,"polygon",1073742106,"prev",1073742108,"probe",1073742109,"pymol",1073742110,"rad",1073742111,"radical",1073742112,"range",1073742114,"rasmol",1073742116,
"reference",1073742118,"remove",1073742119,"residue",1073742120,"resolution",1073742122,"reversecolor",1073742124,"rewind",1073742126,"right",1073742128,"rock",1073742129,"rotate45",1073742130,"rotation",1073742132,"rubberband",1073742134,"sasurface",1073742136,"scale",1073742138,"scene",1073742139,"selection",1073742140,"shapely",1073742144,"sigma",1073742146,"sign",1073742147,"silent",1073742148,"solid",1073742150,"spacegroup",1073742152,"sphere",1073742154,"squared",1073742156,"state",1073742158,
"stop",1073742162,"supercell",1073742163,"ticks",1073742164,"title",1073742166,"titleformat",1073742168,"to",1074790746,"top",1074790748,"torsion",1073742174,"transform",1073742176,"translation",1073742178,"triangles",1073742182,"url",1074790760,"user",1073742186,"val",1073742188,"variable",1073742190,"variables",1073742192,"vertices",1073742194,"spacebeforesquare",1073742195,"width",1073742196);c$.tokenSpaceBeforeSquare=c$.prototype.tokenSpaceBeforeSquare=J.script.T.o(1073742195," ");c$.tokenOn=
c$.prototype.tokenOn=J.script.T.tv(1048589,1,"on");c$.tokenOff=c$.prototype.tokenOff=J.script.T.tv(1048588,0,"off");c$.tokenAll=c$.prototype.tokenAll=J.script.T.o(1048579,"all");c$.tokenIf=c$.prototype.tokenIf=J.script.T.o(135369225,"if");c$.tokenAnd=c$.prototype.tokenAnd=J.script.T.o(269484128,"and");c$.tokenAND=c$.prototype.tokenAND=J.script.T.o(269484160,"");c$.tokenOr=c$.prototype.tokenOr=J.script.T.o(269484112,"or");c$.tokenAndFALSE=c$.prototype.tokenAndFALSE=J.script.T.o(269484128,"and");c$.tokenOrTRUE=
c$.prototype.tokenOrTRUE=J.script.T.o(269484112,"or");c$.tokenOpIf=c$.prototype.tokenOpIf=J.script.T.o(806354977,"?");c$.tokenComma=c$.prototype.tokenComma=J.script.T.o(269484080,",");c$.tokenDefineString=c$.prototype.tokenDefineString=J.script.T.tv(1060866,4,"@");c$.tokenPlus=c$.prototype.tokenPlus=J.script.T.o(269484193,"+");c$.tokenMinus=c$.prototype.tokenMinus=J.script.T.o(269484192,"-");c$.tokenTimes=c$.prototype.tokenTimes=J.script.T.o(269484209,"*");c$.tokenDivide=c$.prototype.tokenDivide=
J.script.T.o(269484208,"/");c$.tokenLeftParen=c$.prototype.tokenLeftParen=J.script.T.o(269484048,"(");c$.tokenRightParen=c$.prototype.tokenRightParen=J.script.T.o(269484049,")");c$.tokenArraySquare=c$.prototype.tokenArraySquare=J.script.T.o(135266306,"[");c$.tokenArraySelector=c$.prototype.tokenArraySelector=J.script.T.o(269484096,"[");c$.tokenExpressionBegin=c$.prototype.tokenExpressionBegin=J.script.T.o(1048577,"expressionBegin");c$.tokenExpressionEnd=c$.prototype.tokenExpressionEnd=J.script.T.o(1048578,
"expressionEnd");c$.tokenConnected=c$.prototype.tokenConnected=J.script.T.o(135266310,"connected");c$.tokenCoordinateBegin=c$.prototype.tokenCoordinateBegin=J.script.T.o(1048586,"{");c$.tokenRightBrace=c$.prototype.tokenRightBrace=J.script.T.o(1048590,"}");c$.tokenCoordinateEnd=c$.prototype.tokenCoordinateEnd=J.script.T.tokenRightBrace;c$.tokenColon=c$.prototype.tokenColon=J.script.T.o(269484066,":");c$.tokenSetCmd=c$.prototype.tokenSetCmd=J.script.T.o(1085443,"set");c$.tokenSet=c$.prototype.tokenSet=
J.script.T.tv(1085443,61,"");c$.tokenSetArray=c$.prototype.tokenSetArray=J.script.T.tv(1085443,91,"");c$.tokenSetProperty=c$.prototype.tokenSetProperty=J.script.T.tv(1085443,46,"");c$.tokenSetVar=c$.prototype.tokenSetVar=J.script.T.tv(1085443,61,"var");c$.tokenEquals=c$.prototype.tokenEquals=J.script.T.o(269484436,"=");c$.tokenScript=c$.prototype.tokenScript=J.script.T.o(135271429,"script");c$.tokenSwitch=c$.prototype.tokenSwitch=J.script.T.o(102410,"switch");c$.tokenMap=c$.prototype.tokenMap=new java.util.Hashtable;
for(var a=["(",J.script.T.tokenLeftParen,")",J.script.T.tokenRightParen,"and",J.script.T.tokenAnd,"&",null,"&&",null,"or",J.script.T.tokenOr,"|",null,"||",null,"?",J.script.T.tokenOpIf,",",J.script.T.tokenComma,"+=",J.script.T.t(269484242),"-=",null,"*=",null,"/=",null,"\\=",null,"&=",null,"|=",null,"not",J.script.T.t(269484144),"!",null,"xor",J.script.T.t(269484113),"tog",J.script.T.t(269484114),"<",J.script.T.t(269484435),"<=",J.script.T.t(269484434),">=",J.script.T.t(269484433),">",J.script.T.t(269484432),
"=",J.script.T.tokenEquals,"==",null,"!=",J.script.T.t(269484438),"<>",null,"within",J.script.T.t(135266324),".",J.script.T.t(1048584),"[",J.script.T.t(269484096),"]",J.script.T.t(269484097),"{",J.script.T.t(1048586),"}",J.script.T.t(1048590),"$",J.script.T.t(1048583),"%",J.script.T.t(269484210),":",J.script.T.tokenColon,";",J.script.T.t(1048591),"++",J.script.T.t(269484226),"--",J.script.T.t(269484225),"**",J.script.T.t(269484227),"+",J.script.T.tokenPlus,"-",J.script.T.tokenMinus,"*",J.script.T.tokenTimes,
"/",J.script.T.tokenDivide,"\\",J.script.T.t(269484211),"animation",J.script.T.t(4097),"anim",null,"assign",J.script.T.t(4098),"axes",J.script.T.t(1611272194),"backbone",J.script.T.t(1115297793),"background",J.script.T.t(1610616835),"bind",J.script.T.t(4100),"bondorder",J.script.T.t(4101),"boundbox",J.script.T.t(1679429641),"boundingBox",null,"break",J.script.T.t(102407),"calculate",J.script.T.t(4102),"capture",J.script.T.t(4103),"cartoon",J.script.T.t(1113200642),"cartoons",null,"case",J.script.T.t(102411),
"catch",J.script.T.t(102412),"cd",J.script.T.t(1069064),"center",J.script.T.t(12289),"centre",null,"centerat",J.script.T.t(4105),"cgo",J.script.T.t(135174),"color",J.script.T.t(1766856708),"colour",null,"compare",J.script.T.t(135270405),"configuration",J.script.T.t(1095766022),"conformation",null,"config",null,"connect",J.script.T.t(4106),"console",J.script.T.t(528395),"contact",J.script.T.t(135402505),"contacts",null,"continue",J.script.T.t(102408),"data",J.script.T.t(135270407),"default",J.script.T.t(102413),
"define",J.script.T.t(1060866),"@",null,"delay",J.script.T.t(528397),"delete",J.script.T.t(12291),"density",J.script.T.t(1073741914),"depth",J.script.T.t(554176526),"dipole",J.script.T.t(135175),"dipoles",null,"display",J.script.T.t(1610625028),"dot",J.script.T.t(1276117505),"dots",J.script.T.t(1113198595),"draw",J.script.T.t(135176),"echo",J.script.T.t(537022465),"ellipsoid",J.script.T.t(1113198596),"ellipsoids",null,"else",J.script.T.t(364547),"elseif",J.script.T.t(102402),"end",J.script.T.t(1150985),
"endif",J.script.T.t(364548),"exit",J.script.T.t(266255),"file",J.script.T.t(1229984263),"files",null,"font",J.script.T.t(4114),"for",J.script.T.t(135369224),"format",J.script.T.t(1288701960),"frame",J.script.T.t(4115),"frames",null,"frank",J.script.T.t(1611272202),"function",J.script.T.t(135368713),"functions",null,"geosurface",J.script.T.t(1113198597),"getProperty",J.script.T.t(135270410),"goto",J.script.T.t(20500),"halo",J.script.T.t(1113200646),"halos",null,"helix",J.script.T.t(137363468),"helixalpha",
J.script.T.t(3145735),"helix310",J.script.T.t(3145736),"helixpi",J.script.T.t(3145738),"hbond",J.script.T.t(1612189718),"hbonds",null,"help",J.script.T.t(20482),"hide",J.script.T.t(12294),"history",J.script.T.t(1610616855),"hover",J.script.T.t(544771),"if",J.script.T.t(135369225),"in",J.script.T.t(1073741980),"initialize",J.script.T.t(266264),"invertSelected",J.script.T.t(4121),"isosurface",J.script.T.t(135180),"javascript",J.script.T.t(135287308),"label",J.script.T.t(1826248715),"labels",null,"lcaoCartoon",
J.script.T.t(135182),"lcaoCartoons",null,"load",J.script.T.t(135271426),"log",J.script.T.t(36869),"loop",J.script.T.t(528410),"measure",J.script.T.t(1746538509),"measures",null,"monitor",null,"monitors",null,"meshribbon",J.script.T.t(1113200647),"meshribbons",null,"message",J.script.T.t(20485),"minimize",J.script.T.t(4126),"minimization",null,"mo",J.script.T.t(1183762),"model",J.script.T.t(1095766028),"models",null,"modulation",J.script.T.t(135270424),"move",J.script.T.t(4128),"moveTo",J.script.T.t(4130),
"navigate",J.script.T.t(4131),"navigation",null,"origin",J.script.T.t(1073742078),"out",J.script.T.t(1073742079),"parallel",J.script.T.t(102436),"pause",J.script.T.t(20487),"wait",null,"plot",J.script.T.t(4133),"plot3d",J.script.T.t(135190),"pmesh",J.script.T.t(135188),"polygon",J.script.T.t(1073742106),"polyhedra",J.script.T.t(135192),"print",J.script.T.t(36865),"process",J.script.T.t(102439),"prompt",J.script.T.t(135304707),"quaternion",J.script.T.t(135270417),"quaternions",null,"quit",J.script.T.t(266281),
"ramachandran",J.script.T.t(1052714),"rama",null,"refresh",J.script.T.t(266284),"reset",J.script.T.t(4141),"unset",null,"restore",J.script.T.t(4142),"restrict",J.script.T.t(12295),"return",J.script.T.t(36866),"ribbon",J.script.T.t(1113200649),"ribbons",null,"rocket",J.script.T.t(1113200650),"rockets",null,"rotate",J.script.T.t(528432),"rotateSelected",J.script.T.t(4145),"save",J.script.T.t(4146),"script",J.script.T.tokenScript,"source",null,"select",J.script.T.t(135280132),"selectionHalos",J.script.T.t(1611141171),
"selectionHalo",null,"showSelections",null,"set",J.script.T.tokenSetCmd,"sheet",J.script.T.t(3145760),"show",J.script.T.t(4148),"slab",J.script.T.t(554176565),"spacefill",J.script.T.t(1113200651),"cpk",null,"spin",J.script.T.t(1611141175),"ssbond",J.script.T.t(1611141176),"ssbonds",null,"star",J.script.T.t(1113200652),"stars",null,"step",J.script.T.t(266298),"steps",null,"stereo",J.script.T.t(528443),"strand",J.script.T.t(1650071565),"strands",null,"structure",J.script.T.t(1641025539),"_structure",
null,"strucNo",J.script.T.t(1095761939),"struts",J.script.T.t(1708058),"strut",null,"subset",J.script.T.t(3158024),"switch",J.script.T.tokenSwitch,"synchronize",J.script.T.t(4156),"sync",null,"trace",J.script.T.t(1113200654),"translate",J.script.T.t(4160),"translateSelected",J.script.T.t(4162),"try",J.script.T.t(364558),"unbind",J.script.T.t(4164),"unitcell",J.script.T.t(1614417948),"var",J.script.T.t(36868),"vector",J.script.T.t(135198),"vectors",null,"vibration",J.script.T.t(4166),"while",J.script.T.t(102406),
"wireframe",J.script.T.t(659488),"write",J.script.T.t(135270421),"zap",J.script.T.t(1060873),"zoom",J.script.T.t(4168),"zoomTo",J.script.T.t(4170),"atom",J.script.T.t(1141899265),"atoms",null,"axis",J.script.T.t(1073741854),"axisangle",J.script.T.t(135266307),"basepair",J.script.T.t(1073741864),"basepairs",null,"orientation",J.script.T.t(1073742077),"orientations",null,"pdbheader",J.script.T.t(1073742088),"polymer",J.script.T.t(1095761935),"polymers",null,"residue",J.script.T.t(1073742120),"residues",
null,"rotation",J.script.T.t(1073742132),"row",J.script.T.t(1276117513),"sequence",J.script.T.t(1087373320),"shape",J.script.T.t(1087373323),"state",J.script.T.t(1073742158),"symbol",J.script.T.t(1087375373),"symmetry",J.script.T.t(1089470478),"spaceGroup",J.script.T.t(1073742152),"transform",J.script.T.t(1073742176),"translation",J.script.T.t(1073742178),"url",J.script.T.t(1074790760),"abs",J.script.T.t(135266826),"absolute",J.script.T.t(1073741826),"acos",J.script.T.t(135266819),"add",J.script.T.t(1276118017),
"adpmax",J.script.T.t(1112539137),"adpmin",J.script.T.t(1112539138),"align",J.script.T.t(1073741832),"all",J.script.T.tokenAll,"altloc",J.script.T.t(1087373315),"altlocs",null,"amino",J.script.T.t(3145730),"angle",J.script.T.t(135266305),"array",J.script.T.t(135266306),"as",J.script.T.t(1073741848),"atomID",J.script.T.t(1095761922),"_atomID",null,"_a",null,"atomIndex",J.script.T.t(1095761923),"atomName",J.script.T.t(1087375362),"atomno",J.script.T.t(1095763969),"atomType",J.script.T.t(1087375361),
"atomX",J.script.T.t(1112541185),"atomY",J.script.T.t(1112541186),"atomZ",J.script.T.t(1112541187),"average",J.script.T.t(96),"babel",J.script.T.t(1073741856),"babel21",J.script.T.t(1073741858),"back",J.script.T.t(1073741859),"backlit",J.script.T.t(1073741862),"balls",J.script.T.t(1073741860),"baseModel",J.script.T.t(3145776),"best",J.script.T.t(1073741863),"bin",J.script.T.t(1276118529),"bondCount",J.script.T.t(1095761924),"bottom",J.script.T.t(1073741871),"branch",J.script.T.t(1048580),"brillouin",
J.script.T.t(1073741872),"bzone",null,"wignerSeitz",null,"cache",J.script.T.t(135270422),"carbohydrate",J.script.T.t(3145764),"cell",J.script.T.t(1095761925),"chain",J.script.T.t(1087373316),"chains",null,"chemicalShift",J.script.T.t(1112539139),"cs",null,"clash",J.script.T.t(1073741881),"clear",J.script.T.t(1073741882),"clickable",J.script.T.t(3145766),"clipboard",J.script.T.t(1073741884),"connected",J.script.T.t(135266310),"constraint",J.script.T.t(1073741894),"contourLines",J.script.T.t(1073741898),
"coord",J.script.T.t(1048582),"coordinates",null,"coords",null,"cos",J.script.T.t(135266821),"cross",J.script.T.t(135267329),"covalent",J.script.T.t(1112539140),"direction",J.script.T.t(1073741918),"displacement",J.script.T.t(1073741922),"displayed",J.script.T.t(3145768),"distance",J.script.T.t(1276118018),"div",J.script.T.t(1276117504),"DNA",J.script.T.t(3145732),"dotted",J.script.T.t(1073741926),"DSSP",J.script.T.t(1073741915),"element",J.script.T.t(1087375365),"elemno",J.script.T.t(1095763976),
"_e",J.script.T.t(1095761927),"error",J.script.T.t(1073741935),"exportScale",J.script.T.t(570425358),"fill",J.script.T.t(1073741938),"find",J.script.T.t(1276118531),"fixedTemperature",J.script.T.t(1073741946),"forcefield",J.script.T.t(545259560),"formalCharge",J.script.T.t(1632634889),"charge",null,"eta",J.script.T.t(1112539141),"front",J.script.T.t(1073741954),"frontlit",J.script.T.t(1073741958),"frontOnly",J.script.T.t(1073741960),"fullylit",J.script.T.t(1073741964),"fx",J.script.T.t(1112541188),
"fy",J.script.T.t(1112541189),"fz",J.script.T.t(1112541190),"fxyz",J.script.T.t(1146095627),"fux",J.script.T.t(1112541191),"fuy",J.script.T.t(1112541192),"fuz",J.script.T.t(1112541193),"fuxyz",J.script.T.t(1146095629),"group",J.script.T.t(1087373318),"groups",null,"group1",J.script.T.t(1087373319),"groupID",J.script.T.t(1095761930),"_groupID",null,"_g",null,"groupIndex",J.script.T.t(1095761931),"hidden",J.script.T.t(3145770),"highlight",J.script.T.t(536870920),"hkl",J.script.T.t(135267841),"hydrophobic",
J.script.T.t(1114638362),"hydrophobicity",null,"hydro",null,"id",J.script.T.t(1074790550),"identify",J.script.T.t(1087373321),"ident",null,"image",J.script.T.t(1073741979),"info",J.script.T.t(1073741982),"inline",J.script.T.t(1073741983),"insertion",J.script.T.t(1087373322),"insertions",null,"intramolecular",J.script.T.t(1073741989),"intra",null,"intermolecular",J.script.T.t(1073741990),"inter",null,"ionic",J.script.T.t(1112541195),"ionicRadius",null,"isAromatic",J.script.T.t(1048585),"Jmol",J.script.T.t(1073741992),
"join",J.script.T.t(1276117506),"keys",J.script.T.t(1141899281),"last",J.script.T.t(1073741993),"left",J.script.T.t(1073741996),"length",J.script.T.t(1141899267),"lines",J.script.T.t(1141899268),"list",J.script.T.t(1073742001),"magneticShielding",J.script.T.t(1112539142),"ms",null,"mass",J.script.T.t(1112539143),"max",J.script.T.t(64),"mep",J.script.T.t(1073742016),"mesh",J.script.T.t(1073742018),"middle",J.script.T.t(1073742019),"min",J.script.T.t(32),"mlp",J.script.T.t(1073742022),"mode",J.script.T.t(1073742024),
"modify",J.script.T.t(1073742025),"modifyOrCreate",J.script.T.t(1073742026),"molecule",J.script.T.t(1095761934),"molecules",null,"modelIndex",J.script.T.t(1095761933),"monomer",J.script.T.t(1073742030),"morph",J.script.T.t(1073742031),"movie",J.script.T.t(1073742032),"mul",J.script.T.t(1276117507),"nci",J.script.T.t(1073742036),"next",J.script.T.t(1073742037),"noDots",J.script.T.t(1073742042),"noFill",J.script.T.t(1073742046),"noMesh",J.script.T.t(1073742052),"none",J.script.T.t(1048587),"null",null,
"inherit",null,"normal",J.script.T.t(1073742056),"noContourLines",J.script.T.t(1073742039),"nonequivalent",J.script.T.t(3145778),"notFrontOnly",J.script.T.t(1073742058),"noTriangles",J.script.T.t(1073742060),"now",J.script.T.t(135266318),"nucleic",J.script.T.t(3145742),"occupancy",J.script.T.t(1129318401),"off",J.script.T.tokenOff,"false",null,"on",J.script.T.tokenOn,"true",null,"omega",J.script.T.t(1112539144),"only",J.script.T.t(1073742072),"opaque",J.script.T.t(1073742074),"options",J.script.T.t(1073742075),
"partialCharge",J.script.T.t(1112541196),"phi",J.script.T.t(1112539145),"plane",J.script.T.t(135266319),"planar",null,"play",J.script.T.t(1073742096),"playRev",J.script.T.t(1073742098),"point",J.script.T.t(135266320),"points",null,"pointGroup",J.script.T.t(1073742102),"polymerLength",J.script.T.t(1095761936),"previous",J.script.T.t(1073742108),"prev",null,"probe",J.script.T.t(1073742109),"property",J.script.T.t(1716520985),"properties",null,"protein",J.script.T.t(3145744),"psi",J.script.T.t(1112539146),
"purine",J.script.T.t(3145746),"PyMOL",J.script.T.t(1073742110),"pyrimidine",J.script.T.t(3145748),"random",J.script.T.t(135267332),"range",J.script.T.t(1073742114),"rasmol",J.script.T.t(1073742116),"replace",J.script.T.t(1276118019),"resno",J.script.T.t(1095761937),"resume",J.script.T.t(266287),"rewind",J.script.T.t(1073742126),"reverse",J.script.T.t(1141899269),"right",J.script.T.t(1073742128),"RNA",J.script.T.t(3145750),"rock",J.script.T.t(1073742129),"rubberband",J.script.T.t(1073742134),"saSurface",
J.script.T.t(1073742136),"scale",J.script.T.t(1073742138),"scene",J.script.T.t(1073742139),"search",J.script.T.t(135267335),"smarts",null,"selected",J.script.T.t(1114638363),"shapely",J.script.T.t(1073742144),"sidechain",J.script.T.t(3145754),"sin",J.script.T.t(135266820),"site",J.script.T.t(1095761938),"size",J.script.T.t(1141899270),"smiles",J.script.T.t(135267336),"substructure",J.script.T.t(1238369286),"solid",J.script.T.t(1073742150),"sort",J.script.T.t(1276117010),"specialPosition",J.script.T.t(3145772),
"sqrt",J.script.T.t(135266822),"split",J.script.T.t(1276117508),"starScale",J.script.T.t(570425403),"stddev",J.script.T.t(192),"straightness",J.script.T.t(1112539150),"structureId",J.script.T.t(1087373324),"supercell",J.script.T.t(1073742163),"sub",J.script.T.t(1276117509),"sum",J.script.T.t(128),"sum2",J.script.T.t(160),"surface",J.script.T.t(3145756),"surfaceDistance",J.script.T.t(1112539151),"symop",J.script.T.t(1297090050),"sx",J.script.T.t(1112539147),"sy",J.script.T.t(1112539148),"sz",J.script.T.t(1112539149),
"sxyz",J.script.T.t(1146095628),"temperature",J.script.T.t(1112541199),"relativeTemperature",null,"tensor",J.script.T.t(1276117015),"theta",J.script.T.t(1112539152),"thisModel",J.script.T.t(3145758),"ticks",J.script.T.t(1073742164),"top",J.script.T.t(1074790748),"torsion",J.script.T.t(1073742174),"trajectory",J.script.T.t(536870926),"trajectories",null,"translucent",J.script.T.t(603979967),"triangles",J.script.T.t(1073742182),"trim",J.script.T.t(1276117510),"type",J.script.T.t(1141899272),"ux",J.script.T.t(1112539153),
"uy",J.script.T.t(1112539154),"uz",J.script.T.t(1112539155),"uxyz",J.script.T.t(1146093582),"user",J.script.T.t(1073742186),"valence",J.script.T.t(1095763988),"vanderWaals",J.script.T.t(1649412120),"vdw",null,"vdwRadius",null,"visible",J.script.T.t(3145774),"volume",J.script.T.t(1313866247),"vx",J.script.T.t(1112541202),"vy",J.script.T.t(1112541203),"vz",J.script.T.t(1112541204),"vxyz",J.script.T.t(1146095631),"xyz",J.script.T.t(1146095626),"w",J.script.T.t(1141899280),"x",J.script.T.t(1112541205),
"y",J.script.T.t(1112541206),"z",J.script.T.t(1112541207),"addHydrogens",J.script.T.t(1073741828),"allConnected",J.script.T.t(1073741834),"angstroms",J.script.T.t(1073741836),"anisotropy",J.script.T.t(1073741838),"append",J.script.T.t(1073741839),"arc",J.script.T.t(1074790416),"area",J.script.T.t(1073741842),"aromatic",J.script.T.t(1076887572),"arrow",J.script.T.t(1073741846),"auto",J.script.T.t(1073741852),"barb",J.script.T.t(1073741861),"binary",J.script.T.t(1073741866),"blockData",J.script.T.t(1073741868),
"cancel",J.script.T.t(1073741874),"cap",J.script.T.t(1074790451),"cavity",J.script.T.t(1073741876),"centroid",J.script.T.t(1095761926),"check",J.script.T.t(1073741878),"chemical",J.script.T.t(1073741879),"circle",J.script.T.t(1073741880),"collapsed",J.script.T.t(1073741886),"col",J.script.T.t(1276117512),"colorScheme",J.script.T.t(1073741888),"command",J.script.T.t(1073741890),"commands",J.script.T.t(1073741892),"contour",J.script.T.t(1073741896),"contours",J.script.T.t(1073741900),"corners",J.script.T.t(1073741902),
"count",J.script.T.t(1276117011),"criterion",J.script.T.t(1073741905),"create",J.script.T.t(1073741904),"crossed",J.script.T.t(1073741906),"curve",J.script.T.t(1073741908),"cutoff",J.script.T.t(1073741910),"cylinder",J.script.T.t(1073741912),"diameter",J.script.T.t(1073741916),"discrete",J.script.T.t(1073741920),"distanceFactor",J.script.T.t(1073741924),"downsample",J.script.T.t(1073741928),"drawing",J.script.T.t(1073741929),"eccentricity",J.script.T.t(1073741930),"ed",J.script.T.t(1074790508),"edges",
J.script.T.t(1073741933),"energy",J.script.T.t(1073741934),"exitJmol",J.script.T.t(266256),"faceCenterOffset",J.script.T.t(1073741937),"filter",J.script.T.t(1073741940),"first",J.script.T.t(1073741942),"fixed",J.script.T.t(1060869),"fix",null,"flat",J.script.T.t(1073741948),"fps",J.script.T.t(1074790526),"from",J.script.T.t(1073741952),"frontEdges",J.script.T.t(1073741956),"full",J.script.T.t(1073741961),"fullPlane",J.script.T.t(1073741962),"functionXY",J.script.T.t(1073741966),"functionXYZ",J.script.T.t(1073741968),
"gridPoints",J.script.T.t(1073741970),"homo",J.script.T.t(1073741973),"ignore",J.script.T.t(1073741976),"InChI",J.script.T.t(1073741977),"InChIKey",J.script.T.t(1073741978),"increment",J.script.T.t(1073741981),"insideout",J.script.T.t(1073741984),"interior",J.script.T.t(1073741986),"intersection",J.script.T.t(135267842),"intersect",null,"internal",J.script.T.t(1073741988),"lattice",J.script.T.t(1073741994),"line",J.script.T.t(1073741998),"lineData",J.script.T.t(1073742E3),"link",J.script.T.t(1073741999),
"lobe",J.script.T.t(1073742002),"lonePair",J.script.T.t(1073742004),"lp",J.script.T.t(1073742006),"lumo",J.script.T.t(1073742008),"manifest",J.script.T.t(1073742010),"mapProperty",J.script.T.t(1052700),"map",null,"maxSet",J.script.T.t(1073742014),"menu",J.script.T.t(1073742015),"minSet",J.script.T.t(1073742020),"modelBased",J.script.T.t(1073742028),"molecular",J.script.T.t(1073742029),"mrc",J.script.T.t(1073742033),"msms",J.script.T.t(1073742034),"name",J.script.T.t(1073742035),"nmr",J.script.T.t(1073742038),
"noCross",J.script.T.t(1073742040),"noDebug",J.script.T.t(1073742041),"noEdges",J.script.T.t(1073742044),"noHead",J.script.T.t(1073742048),"noLoad",J.script.T.t(1073742050),"noPlane",J.script.T.t(1073742054),"object",J.script.T.t(1073742064),"obj",J.script.T.t(1073742062),"offset",J.script.T.t(1073742066),"offsetSide",J.script.T.t(1073742068),"once",J.script.T.t(1073742070),"orbital",J.script.T.t(1073742076),"atomicOrbital",J.script.T.t(1073741850),"packed",J.script.T.t(1073742080),"palindrome",J.script.T.t(1073742082),
"parameters",J.script.T.t(1073742083),"path",J.script.T.t(1073742084),"pdb",J.script.T.t(1074790662),"period",J.script.T.t(1073742090),"periodic",null,"perpendicular",J.script.T.t(1073742092),"perp",null,"phase",J.script.T.t(1073742094),"pocket",J.script.T.t(1073742100),"pointsPerAngstrom",J.script.T.t(1073742104),"radical",J.script.T.t(1073742112),"rad",J.script.T.t(1073742111),"reference",J.script.T.t(1073742118),"remove",J.script.T.t(1073742119),"resolution",J.script.T.t(1073742122),"reverseColor",
J.script.T.t(1073742124),"rotate45",J.script.T.t(1073742130),"selection",J.script.T.t(1073742140),"sigma",J.script.T.t(1073742146),"sign",J.script.T.t(1073742147),"silent",J.script.T.t(1073742148),"sphere",J.script.T.t(1073742154),"squared",J.script.T.t(1073742156),"stop",J.script.T.t(1073742162),"title",J.script.T.t(1073742166),"titleFormat",J.script.T.t(1073742168),"to",J.script.T.t(1074790746),"value",J.script.T.t(1073742188),"variable",J.script.T.t(1073742190),"variables",J.script.T.t(1073742192),
"vertices",J.script.T.t(1073742194),"width",J.script.T.t(1073742196),"backgroundModel",J.script.T.t(536870914),"celShading",J.script.T.t(603979821),"debug",J.script.T.t(536870916),"defaultLattice",J.script.T.t(536870918),"measurements",J.script.T.t(537006096),"measurement",null,"scale3D",J.script.T.t(1610612740),"toggleLabel",J.script.T.t(1610612741),"userColorScheme",J.script.T.t(536870930),"timeout",J.script.T.t(536875070),"timeouts",null,"animationMode",J.script.T.t(545259521),"appletProxy",J.script.T.t(545259522),
"atomTypes",J.script.T.t(545259524),"axesColor",J.script.T.t(545259526),"axis1Color",J.script.T.t(545259528),"axis2Color",J.script.T.t(545259530),"axis3Color",J.script.T.t(545259532),"backgroundColor",J.script.T.t(545259534),"bondmode",J.script.T.t(1610612737),"boundBoxColor",J.script.T.t(545259536),"boundingBoxColor",null,"currentLocalPath",J.script.T.t(545259538),"dataSeparator",J.script.T.t(545259540),"defaultAngleLabel",J.script.T.t(545259542),"defaultColorScheme",J.script.T.t(545259545),"defaultColors",
null,"defaultDirectory",J.script.T.t(545259546),"defaultDistanceLabel",J.script.T.t(545259547),"defaultDropScript",J.script.T.t(545259548),"defaultLabelPDB",J.script.T.t(545259543),"defaultLabelXYZ",J.script.T.t(545259544),"defaultLoadFilter",J.script.T.t(545259549),"defaultLoadScript",J.script.T.t(545259550),"defaults",J.script.T.t(545259552),"defaultTorsionLabel",J.script.T.t(545259554),"defaultVDW",J.script.T.t(545259555),"drawFontSize",J.script.T.t(570425356),"edsUrlCutoff",J.script.T.t(545259556),
"edsUrlFormat",J.script.T.t(545259557),"energyUnits",J.script.T.t(545259558),"fileCacheDirectory",J.script.T.t(545259559),"fontsize",J.script.T.t(1610612738),"helpPath",J.script.T.t(545259561),"hoverLabel",J.script.T.t(545259562),"language",J.script.T.t(545259564),"loadFormat",J.script.T.t(545259565),"loadLigandFormat",J.script.T.t(545259566),"logFile",J.script.T.t(545259567),"measurementUnits",J.script.T.t(545259568),"nmrPredictFormat",J.script.T.t(545259569),"nmrUrlFormat",J.script.T.t(545259570),
"pathForAllFiles",J.script.T.t(545259571),"picking",J.script.T.t(545259572),"pickingStyle",J.script.T.t(545259574),"pickLabel",J.script.T.t(545259576),"platformSpeed",J.script.T.t(553648158),"propertyColorScheme",J.script.T.t(545259578),"quaternionFrame",J.script.T.t(545259580),"smilesUrlFormat",J.script.T.t(545259582),"smiles2dImageFormat",J.script.T.t(545259584),"unitCellColor",J.script.T.t(545259586),"axesScale",J.script.T.t(570425346),"axisScale",null,"bondTolerance",J.script.T.t(570425348),"cameraDepth",
J.script.T.t(570425350),"defaultDrawArrowScale",J.script.T.t(570425352),"defaultTranslucent",J.script.T.t(570425354),"dipoleScale",J.script.T.t(570425355),"ellipsoidAxisDiameter",J.script.T.t(570425357),"gestureSwipeFactor",J.script.T.t(570425359),"hbondsAngleMinimum",J.script.T.t(570425360),"hbondsDistanceMaximum",J.script.T.t(570425361),"hoverDelay",J.script.T.t(570425362),"loadAtomDataTolerance",J.script.T.t(570425363),"minBondDistance",J.script.T.t(570425364),"minimizationCriterion",J.script.T.t(570425365),
"mouseDragFactor",J.script.T.t(570425366),"mouseWheelFactor",J.script.T.t(570425367),"navFPS",J.script.T.t(570425370),"navigationDepth",J.script.T.t(570425371),"navigationSlab",J.script.T.t(570425372),"navigationSpeed",J.script.T.t(570425374),"navX",J.script.T.t(570425376),"navY",J.script.T.t(570425378),"navZ",J.script.T.t(570425380),"pointGroupDistanceTolerance",J.script.T.t(570425382),"pointGroupLinearTolerance",J.script.T.t(570425384),"radius",J.script.T.t(1666189314),"rotationRadius",J.script.T.t(570425388),
"scaleAngstromsPerInch",J.script.T.t(570425390),"sheetSmoothing",J.script.T.t(570425392),"slabRange",J.script.T.t(570425393),"solventProbeRadius",J.script.T.t(570425394),"spinFPS",J.script.T.t(570425396),"spinX",J.script.T.t(570425398),"spinY",J.script.T.t(570425400),"spinZ",J.script.T.t(570425402),"stereoDegrees",J.script.T.t(570425404),"strutDefaultRadius",J.script.T.t(570425406),"strutLengthMaximum",J.script.T.t(570425408),"vectorScale",J.script.T.t(1649410049),"vectorSymmetry",J.script.T.t(603979973),
"vibrationPeriod",J.script.T.t(570425412),"vibrationScale",J.script.T.t(570425414),"visualRange",J.script.T.t(570425416),"ambientPercent",J.script.T.t(553648130),"ambient",null,"animationFps",J.script.T.t(553648132),"axesMode",J.script.T.t(553648134),"bondRadiusMilliAngstroms",J.script.T.t(553648136),"delayMaximumMs",J.script.T.t(553648138),"diffusePercent",J.script.T.t(553648142),"diffuse",null,"dotDensity",J.script.T.t(553648143),"dotScale",J.script.T.t(553648144),"ellipsoidDotCount",J.script.T.t(553648145),
"helixStep",J.script.T.t(553648146),"hermiteLevel",J.script.T.t(553648147),"historyLevel",J.script.T.t(553648148),"lighting",J.script.T.t(1073741995),"logLevel",J.script.T.t(553648150),"meshScale",J.script.T.t(553648151),"minimizationSteps",J.script.T.t(553648152),"minPixelSelRadius",J.script.T.t(553648153),"percentVdwAtom",J.script.T.t(553648154),"perspectiveModel",J.script.T.t(553648155),"phongExponent",J.script.T.t(553648156),"pickingSpinRate",J.script.T.t(553648157),"propertyAtomNumberField",
J.script.T.t(553648159),"propertyAtomNumberColumnCount",J.script.T.t(553648160),"propertyDataColumnCount",J.script.T.t(553648162),"propertyDataField",J.script.T.t(553648164),"repaintWaitMs",J.script.T.t(553648165),"ribbonAspectRatio",J.script.T.t(553648166),"scriptReportingLevel",J.script.T.t(553648168),"showScript",J.script.T.t(536870922),"smallMoleculeMaxAtoms",J.script.T.t(553648170),"specular",J.script.T.t(536870924),"specularExponent",J.script.T.t(553648172),"specularPercent",J.script.T.t(553648174),
"specPercent",null,"specularPower",J.script.T.t(553648176),"specpower",null,"strandCount",J.script.T.t(553648178),"strandCountForMeshRibbon",J.script.T.t(553648180),"strandCountForStrands",J.script.T.t(553648182),"strutSpacing",J.script.T.t(553648184),"zDepth",J.script.T.t(553648186),"zSlab",J.script.T.t(553648188),"zshadePower",J.script.T.t(553648190),"allowEmbeddedScripts",J.script.T.t(603979778),"allowGestures",J.script.T.t(603979780),"allowKeyStrokes",J.script.T.t(603979781),"allowModelKit",J.script.T.t(603979782),
"allowMoveAtoms",J.script.T.t(603979783),"allowMultiTouch",J.script.T.t(603979784),"allowRotateSelected",J.script.T.t(603979785),"antialiasDisplay",J.script.T.t(603979786),"antialiasImages",J.script.T.t(603979788),"antialiasTranslucent",J.script.T.t(603979790),"appendNew",J.script.T.t(603979792),"applySymmetryToBonds",J.script.T.t(603979794),"atomPicking",J.script.T.t(603979796),"autobond",J.script.T.t(603979798),"autoFPS",J.script.T.t(603979800),"axesMolecular",J.script.T.t(603979804),"axesOrientationRasmol",
J.script.T.t(603979806),"axesUnitCell",J.script.T.t(603979808),"axesWindow",J.script.T.t(603979810),"bondModeOr",J.script.T.t(603979812),"bondPicking",J.script.T.t(603979814),"bonds",J.script.T.t(1678770178),"bond",null,"cartoonBaseEdges",J.script.T.t(603979817),"cartoonsFancy",J.script.T.t(603979819),"cartoonFancy",null,"cartoonLadders",J.script.T.t(603979820),"cartoonRockets",J.script.T.t(603979818),"chainCaseSensitive",J.script.T.t(603979822),"colorRasmol",J.script.T.t(603979823),"debugScript",
J.script.T.t(603979824),"defaultStructureDssp",J.script.T.t(603979825),"disablePopupMenu",J.script.T.t(603979826),"displayCellParameters",J.script.T.t(603979828),"dotsSelectedOnly",J.script.T.t(603979829),"dotSurface",J.script.T.t(603979830),"dragSelected",J.script.T.t(603979831),"drawHover",J.script.T.t(603979832),"drawPicking",J.script.T.t(603979833),"dsspCalculateHydrogenAlways",J.script.T.t(603979834),"dynamicMeasurements",J.script.T.t(603979835),"ellipsoidArcs",J.script.T.t(603979836),"ellipsoidArrows",
J.script.T.t(603979837),"ellipsoidAxes",J.script.T.t(603979838),"ellipsoidBall",J.script.T.t(603979839),"ellipsoidDots",J.script.T.t(603979840),"ellipsoidFill",J.script.T.t(603979841),"fileCaching",J.script.T.t(603979842),"fontCaching",J.script.T.t(603979844),"fontScaling",J.script.T.t(603979845),"forceAutoBond",J.script.T.t(603979846),"fractionalRelative",J.script.T.t(603979848),"greyscaleRendering",J.script.T.t(603979850),"hbondsBackbone",J.script.T.t(603979852),"hbondsRasmol",J.script.T.t(603979853),
"hbondsSolid",J.script.T.t(603979854),"hetero",J.script.T.t(1613758470),"hideNameInPopup",J.script.T.t(603979858),"hideNavigationPoint",J.script.T.t(603979860),"hideNotSelected",J.script.T.t(603979862),"highResolution",J.script.T.t(603979864),"hydrogen",J.script.T.t(1613758476),"hydrogens",null,"imageState",J.script.T.t(603979868),"isKiosk",J.script.T.t(603979869),"isosurfaceKey",J.script.T.t(603979870),"isosurfacePropertySmoothing",J.script.T.t(603979871),"isosurfacePropertySmoothingPower",J.script.T.t(553648149),
"justifyMeasurements",J.script.T.t(603979872),"languageTranslation",J.script.T.t(603979873),"legacyAutoBonding",J.script.T.t(603979874),"legacyHAddition",J.script.T.t(603979875),"logCommands",J.script.T.t(603979876),"logGestures",J.script.T.t(603979877),"measureAllModels",J.script.T.t(603979878),"measurementLabels",J.script.T.t(603979879),"measurementNumbers",J.script.T.t(1610612739),"messageStyleChime",J.script.T.t(603979880),"minimizationRefresh",J.script.T.t(603979881),"minimizationSilent",J.script.T.t(603979882),
"modelkitMode",J.script.T.t(603979883),"monitorEnergy",J.script.T.t(603979884),"multipleBondRadiusFactor",J.script.T.t(570425368),"multipleBondSpacing",J.script.T.t(570425369),"multiProcessor",J.script.T.t(603979885),"navigateSurface",J.script.T.t(603979886),"navigationMode",J.script.T.t(603979887),"navigationPeriodic",J.script.T.t(603979888),"partialDots",J.script.T.t(603979889),"pdbAddHydrogens",J.script.T.t(603979890),"pdbGetHeader",J.script.T.t(603979891),"pdbSequential",J.script.T.t(603979892),
"perspectiveDepth",J.script.T.t(603979893),"preserveState",J.script.T.t(603979894),"rangeSelected",J.script.T.t(603979895),"redoMove",J.script.T.t(4139),"refreshing",J.script.T.t(603979896),"ribbonBorder",J.script.T.t(603979898),"rocketBarrels",J.script.T.t(603979900),"saveProteinStructureState",J.script.T.t(603979902),"scriptQueue",J.script.T.t(603979904),"selectAllModels",J.script.T.t(603979906),"selectHetero",J.script.T.t(603979908),"selectHydrogen",J.script.T.t(603979910),"showAxes",J.script.T.t(603979914),
"showBoundBox",J.script.T.t(603979916),"showBoundingBox",null,"showFrank",J.script.T.t(603979918),"showHiddenSelectionHalos",J.script.T.t(603979920),"showHydrogens",J.script.T.t(603979922),"showKeyStrokes",J.script.T.t(603979924),"showMeasurements",J.script.T.t(603979926),"showMultipleBonds",J.script.T.t(603979928),"showNavigationPointAlways",J.script.T.t(603979930),"showTiming",J.script.T.t(603979934),"showUnitcell",J.script.T.t(603979936),"slabByAtom",J.script.T.t(603979938),"slabByMolecule",J.script.T.t(603979940),
"slabEnabled",J.script.T.t(603979942),"smartAromatic",J.script.T.t(603979944),"solvent",J.script.T.t(1613758488),"solventProbe",J.script.T.t(603979948),"ssBondsBackbone",J.script.T.t(603979952),"statusReporting",J.script.T.t(603979954),"strutsMultiple",J.script.T.t(603979955),"syncMouse",J.script.T.t(603979956),"syncScript",J.script.T.t(603979958),"testFlag1",J.script.T.t(603979960),"testFlag2",J.script.T.t(603979962),"testFlag3",J.script.T.t(603979964),"testFlag4",J.script.T.t(603979965),"traceAlpha",
J.script.T.t(603979966),"twistedSheets",J.script.T.t(603979968),"undo",J.script.T.t(536870928),"undoMove",J.script.T.t(4165),"useArcBall",J.script.T.t(603979969),"useMinimizationThread",J.script.T.t(603979970),"useNumberLocalization",J.script.T.t(603979972),"waitForMoveTo",J.script.T.t(603979974),"windowCentered",J.script.T.t(603979975),"wireframeRotation",J.script.T.t(603979976),"zeroBasedXyzRasmol",J.script.T.t(603979978),"zoomEnabled",J.script.T.t(603979980),"zoomHeight",J.script.T.t(603979982),
"zoomLarge",J.script.T.t(603979983),"zShade",J.script.T.t(603979984)],b=null,c,d,e,f=0;f+1<a.length;f+=2)c=a[f],e=c.toLowerCase(),d=a[f+1],null==d&&(d=b),null==d.value&&(d.value=c),null!=J.script.T.tokenMap.get(e)&&J.util.Logger.error("duplicate token definition:"+e),J.script.T.tokenMap.put(e,d),b=d;a=null}),Clazz.declarePackage("J.util"),Clazz.load(["JU.BS"],"J.util.BSUtil",null,function(){c$=Clazz.declareType(J.util,"BSUtil");c$.newAndSetBit=$_M(c$,"newAndSetBit",function(a){var b=J.util.BSUtil.newBitSet(a+
1);b.set(a);return b},"~N");c$.areEqual=$_M(c$,"areEqual",function(a,b){return null==a||null==b?null==a&&null==b:a.equals(b)},"JU.BS,JU.BS");c$.haveCommon=$_M(c$,"haveCommon",function(a,b){return null==a||null==b?!1:a.intersects(b)},"JU.BS,JU.BS");c$.cardinalityOf=$_M(c$,"cardinalityOf",function(a){return null==a?0:a.cardinality()},"JU.BS");c$.newBitSet2=$_M(c$,"newBitSet2",function(a,b){var c=J.util.BSUtil.newBitSet(b);c.setBits(a,b);return c},"~N,~N");c$.setAll=$_M(c$,"setAll",function(a){var b=
J.util.BSUtil.newBitSet(a);b.setBits(0,a);return b},"~N");c$.andNot=$_M(c$,"andNot",function(a,b){null!=b&&null!=a&&a.andNot(b);return a},"JU.BS,JU.BS");c$.copy=$_M(c$,"copy",function(a){return null==a?null:a.clone()},"JU.BS");c$.copy2=$_M(c$,"copy2",function(a,b){if(null==a||null==b)return null;b.clearAll();b.or(a);return b},"JU.BS,JU.BS");c$.copyInvert=$_M(c$,"copyInvert",function(a,b){return null==a?null:J.util.BSUtil.andNot(J.util.BSUtil.setAll(b),a)},"JU.BS,~N");c$.invertInPlace=$_M(c$,"invertInPlace",
function(a,b){return J.util.BSUtil.copy2(J.util.BSUtil.copyInvert(a,b),a)},"JU.BS,~N");c$.toggleInPlace=$_M(c$,"toggleInPlace",function(a,b){a.equals(b)?a.clearAll():0==J.util.BSUtil.andNot(J.util.BSUtil.copy(b),a).length()?J.util.BSUtil.andNot(a,b):a.or(b);return a},"JU.BS,JU.BS");c$.deleteBits=$_M(c$,"deleteBits",function(a,b){if(null==a||null==b)return a;var c=b.nextSetBit(0);if(0>c)return a;var d=a.length(),e=Math.min(d,b.length()),f;for(f=b.nextClearBit(c);f<e&&0<=f;f=b.nextClearBit(f+1))a.setBitTo(c++,
a.get(f));for(f=e;f<d;f++)a.setBitTo(c++,a.get(f));c<d&&a.clearBits(c,d);return a},"JU.BS,JU.BS");c$.newBitSet=$_M(c$,"newBitSet",function(a){return JU.BS.newN(a)},"~N");c$.offset=$_M(c$,"offset",function(a,b,c){if(null!=a){for(var d=JU.BS.newN(a.length()+c),e=a.nextSetBit(0);e>=b;e=a.nextSetBit(e+1))d.set(e+c);J.util.BSUtil.copy2(d,a)}},"JU.BS,~N,~N");c$.setMapBitSet=$_M(c$,"setMapBitSet",function(a,b,c,d){var e;a.containsKey(d)?e=a.get(d):a.put(d,e=new JU.BS);e.setBits(b,c+1)},"java.util.Map,~N,~N,~S");
c$.emptySet=c$.prototype.emptySet=new JU.BS}),Clazz.declarePackage("J.util"),Clazz.load(["java.lang.Enum"],"J.util.JmolEdge",null,function(){c$=Clazz.decorateAsClass(function(){this.index=-1;this.order=0;Clazz.instantialize(this,arguments)},J.util,"JmolEdge");c$.getArgbHbondType=$_M(c$,"getArgbHbondType",function(a){return J.util.JmolEdge.argbsHbondType[(a&30720)>>11]},"~N");c$.getBondOrderNumberFromOrder=$_M(c$,"getBondOrderNumberFromOrder",function(a){a&=-131073;return 131071==a||65535==a?"0":J.modelset.Bond.isOrderH(a)||
0!=(a&256)?J.util.JmolEdge.EnumBondOrder.SINGLE.number:0!=(a&224)?(a>>5)+"."+(a&31):J.util.JmolEdge.EnumBondOrder.getNumberFromCode(a)},"~N");c$.getCmlBondOrder=$_M(c$,"getCmlBondOrder",function(a){a=J.util.JmolEdge.getBondOrderNameFromOrder(a);switch(a.charAt(0)){case "s":case "d":case "t":return""+a.toUpperCase().charAt(0);case "a":return 0<=a.indexOf("Double")?"D":0<=a.indexOf("Single")?"S":"aromatic";case "p":return 0<=a.indexOf(" ")?a.substring(a.indexOf(" ")+1):"partial12"}return null},"~N");
c$.getBondOrderNameFromOrder=$_M(c$,"getBondOrderNameFromOrder",function(a){a&=-131073;switch(a){case 65535:case 131071:return"";case 32768:return J.util.JmolEdge.EnumBondOrder.STRUT.$$name;case 1:return J.util.JmolEdge.EnumBondOrder.SINGLE.$$name;case 2:return J.util.JmolEdge.EnumBondOrder.DOUBLE.$$name}return 0!=(a&224)?"partial "+J.util.JmolEdge.getBondOrderNumberFromOrder(a):J.modelset.Bond.isOrderH(a)?J.util.JmolEdge.EnumBondOrder.H_REGULAR.$$name:0!=(a&256)?J.util.JmolEdge.EnumBondOrder.SINGLE.$$name:
J.util.JmolEdge.EnumBondOrder.getNameFromCode(a)},"~N");c$.getPartialBondDotted=$_M(c$,"getPartialBondDotted",function(a){return a&31},"~N");c$.getPartialBondOrder=$_M(c$,"getPartialBondOrder",function(a){return(a&-131073)>>5},"~N");c$.getCovalentBondOrder=$_M(c$,"getCovalentBondOrder",function(a){if(0==(a&1023))return 0;a&=-131073;if(0!=(a&224))return J.util.JmolEdge.getPartialBondOrder(a);0!=(a&256)&&(a&=-257);0!=(a&248)&&(a=1);return a&7},"~N");c$.getBondOrderFromFloat=$_M(c$,"getBondOrderFromFloat",
function(a){switch(Clazz.floatToInt(10*a)){case 10:return 1;case 5:case -10:return 33;case 15:return 515;case -15:return 66;case 20:return 2;case 25:return 97;case -25:return 100;case 30:return 3;case 40:return 4}return 131071},"~N");c$.getBondOrderFromString=$_M(c$,"getBondOrderFromString",function(a){return J.util.JmolEdge.EnumBondOrder.getCodeFromName(a)},"~S");Clazz.pu$h();c$=Clazz.decorateAsClass(function(){this.code=0;this.$$name=this.number=null;Clazz.instantialize(this,arguments)},J.util.JmolEdge,
"EnumBondOrder",Enum);Clazz.makeConstructor(c$,($fz=function(a,b,c){this.code=a;this.number=b;this.$$name=c},$fz.isPrivate=!0,$fz),"~N,~S,~S");c$.getCodeFromName=$_M(c$,"getCodeFromName",function(a){for(var b,c=0,d=J.util.JmolEdge.EnumBondOrder.values();c<d.length&&((b=d[c])||1);c++)if(b.$$name.equalsIgnoreCase(a))return b.code;return 131071},"~S");c$.getNameFromCode=$_M(c$,"getNameFromCode",function(a){for(var b,c=0,d=J.util.JmolEdge.EnumBondOrder.values();c<d.length&&((b=d[c])||1);c++)if(b.code==
a)return b.$$name;return"?"},"~N");c$.getNumberFromCode=$_M(c$,"getNumberFromCode",function(a){for(var b,c=0,d=J.util.JmolEdge.EnumBondOrder.values();c<d.length&&((b=d[c])||1);c++)if(b.code==a)return b.number;return"?"},"~N");Clazz.defineEnumConstant(c$,"SINGLE",0,[1,"1","single"]);Clazz.defineEnumConstant(c$,"DOUBLE",1,[2,"2","double"]);Clazz.defineEnumConstant(c$,"TRIPLE",2,[3,"3","triple"]);Clazz.defineEnumConstant(c$,"QUADRUPLE",3,[4,"4","quadruple"]);Clazz.defineEnumConstant(c$,"AROMATIC",4,
[515,"1.5","aromatic"]);Clazz.defineEnumConstant(c$,"STRUT",5,[32768,"1","struts"]);Clazz.defineEnumConstant(c$,"H_REGULAR",6,[2048,"1","hbond"]);Clazz.defineEnumConstant(c$,"PARTIAL01",7,[33,"0.5","partial"]);Clazz.defineEnumConstant(c$,"PARTIAL12",8,[66,"1.5","partialDouble"]);Clazz.defineEnumConstant(c$,"PARTIAL23",9,[97,"2.5","partialTriple"]);Clazz.defineEnumConstant(c$,"PARTIAL32",10,[100,"2.5","partialTriple2"]);Clazz.defineEnumConstant(c$,"AROMATIC_SINGLE",11,[513,"1","aromaticSingle"]);Clazz.defineEnumConstant(c$,
"AROMATIC_DOUBLE",12,[514,"2","aromaticDouble"]);Clazz.defineEnumConstant(c$,"UNSPECIFIED",13,[17,"1","unspecified"]);c$=Clazz.p0p();Clazz.defineStatics(c$,"BOND_STEREO_MASK",1024,"BOND_STEREO_NEAR",1025,"BOND_STEREO_FAR",1041,"BOND_AROMATIC_MASK",512,"BOND_AROMATIC_SINGLE",513,"BOND_AROMATIC_DOUBLE",514,"BOND_AROMATIC",515,"BOND_SULFUR_MASK",256,"BOND_PARTIAL_MASK",224,"BOND_PARTIAL01",33,"BOND_PARTIAL12",66,"BOND_PARTIAL23",97,"BOND_PARTIAL32",100,"BOND_COVALENT_MASK",1023,"BOND_COVALENT_SINGLE",
1,"BOND_COVALENT_DOUBLE",2,"BOND_COVALENT_TRIPLE",3,"BOND_COVALENT_QUADRUPLE",4,"BOND_ORDER_UNSPECIFIED",17,"BOND_ORDER_ANY",65535,"BOND_ORDER_NULL",131071,"BOND_STRUT",32768,"BOND_AS_SINGLE",65536,"BOND_NEW",131072,"BOND_HBOND_SHIFT",11,"BOND_HYDROGEN_MASK",30720,"BOND_H_REGULAR",2048,"BOND_H_CALC_MASK",28672,"BOND_H_CALC",4096,"BOND_H_PLUS_2",6144,"BOND_H_PLUS_3",8192,"BOND_H_PLUS_4",10240,"BOND_H_PLUS_5",12288,"BOND_H_MINUS_3",14336,"BOND_H_MINUS_4",16384,"BOND_H_NUCLEOTIDE",18432,"argbsHbondType",
[4294928820,4294967040,4294967040,4294967295,4294902015,4294901760,4294944E3,4278255615,4278255360,4294934656],"FLAG_AROMATIC_DOUBLE",16,"FLAG_AROMATIC_DEFINED",8,"FLAG_AROMATIC_STRICT",4,"FLAG_IGNORE_STEREOCHEMISTRY",2,"FLAG_NO_AROMATIC",1)}),Clazz.declarePackage("J.modelset"),Clazz.load(["JU.BS","J.util.JmolEdge","J.viewer.JC"],"J.modelset.Bond",["J.util.BSUtil","$.C"],function(){c$=Clazz.decorateAsClass(function(){this.atom2=this.atom1=null;this.shapeVisibilityFlags=this.colix=this.mad=0;Clazz.instantialize(this,
arguments)},J.modelset,"Bond",J.util.JmolEdge);Clazz.makeConstructor(c$,function(a,b,c,d,e){Clazz.superConstructor(this,J.modelset.Bond,[]);this.atom1=a;this.atom2=b;this.colix=e;this.setOrder(c);this.setMad(d)},"J.modelset.Atom,J.modelset.Atom,~N,~N,~N");$_M(c$,"setMad",function(a){this.mad=a;this.setShapeVisibility(0!=a)},"~N");$_M(c$,"setShapeVisibilityFlags",function(a){this.shapeVisibilityFlags=a},"~N");$_M(c$,"getShapeVisibilityFlags",function(){return this.shapeVisibilityFlags});$_M(c$,"setShapeVisibility",
function(a){0!=(this.shapeVisibilityFlags&J.modelset.Bond.myVisibilityFlag)!=a&&(this.atom1.addDisplayedBond(J.modelset.Bond.myVisibilityFlag,a),this.atom2.addDisplayedBond(J.modelset.Bond.myVisibilityFlag,a),this.shapeVisibilityFlags=a?this.shapeVisibilityFlags|J.modelset.Bond.myVisibilityFlag:this.shapeVisibilityFlags&~J.modelset.Bond.myVisibilityFlag)},"~B");$_M(c$,"getIdentity",function(){return this.index+1+" "+this.getOrderNumberAsString()+" "+this.atom1.getInfo()+" -- "+this.atom2.getInfo()+
" "+this.atom1.distance(this.atom2)});Clazz.overrideMethod(c$,"isCovalent",function(){return 0!=(this.order&1023)});Clazz.overrideMethod(c$,"isHydrogen",function(){return J.modelset.Bond.isOrderH(this.order)});c$.isOrderH=$_M(c$,"isOrderH",function(a){return 0!=(a&30720)},"~N");$_M(c$,"isStereo",function(){return 0!=(this.order&1024)});$_M(c$,"isPartial",function(){return 0!=(this.order&224)});$_M(c$,"isAromatic",function(){return 0!=(this.order&512)});$_M(c$,"setPaletteID",function(){},"~N");$_M(c$,
"getEnergy",function(){return 0});$_M(c$,"getValence",function(){return!this.isCovalent()?0:this.isPartial()||this.is(515)?1:this.order&7});$_M(c$,"deleteAtomReferences",function(){null!=this.atom1&&this.atom1.deleteBond(this);null!=this.atom2&&this.atom2.deleteBond(this);this.atom1=this.atom2=null});$_M(c$,"setColix",function(a){this.colix=a},"~N");$_M(c$,"setTranslucent",function(a,b){this.colix=J.util.C.getColixTranslucent3(this.colix,a,b)},"~B,~N");$_M(c$,"setOrder",function(a){16==this.atom1.getElementNumber()&&
16==this.atom2.getElementNumber()&&(a|=256);512==a&&(a=515);this.order=a|this.order&131072},"~N");$_M(c$,"getAtom1",function(){return this.atom1});$_M(c$,"getAtom2",function(){return this.atom2});Clazz.overrideMethod(c$,"getAtomIndex1",function(){return this.atom1.index});Clazz.overrideMethod(c$,"getAtomIndex2",function(){return this.atom2.index});$_M(c$,"getRadius",function(){return this.mad/2E3});Clazz.overrideMethod(c$,"getCovalentOrder",function(){return J.util.JmolEdge.getCovalentBondOrder(this.order)});
$_M(c$,"getOrderName",function(){return J.util.JmolEdge.getBondOrderNameFromOrder(this.order)});$_M(c$,"getOrderNumberAsString",function(){return J.util.JmolEdge.getBondOrderNumberFromOrder(this.order)});$_M(c$,"getColix1",function(){return J.util.C.getColixInherited(this.colix,this.atom1.colixAtom)});$_M(c$,"getColix2",function(){return J.util.C.getColixInherited(this.colix,this.atom2.colixAtom)});$_M(c$,"getOtherAtom",function(a){return this.atom1===a?this.atom2:this.atom2===a?this.atom1:null},
"J.modelset.Atom");$_M(c$,"setIndex",function(a){this.index=a},"~N");$_M(c$,"is",function(a){return(this.order&-131073)==a},"~N");Clazz.overrideMethod(c$,"getOtherAtomNode",function(a){return this.atom1===a?this.atom2:this.atom2===a?this.atom1:null},"J.util.JmolNode");Clazz.overrideMethod(c$,"toString",function(){return this.atom1+" - "+this.atom2});Clazz.pu$h();c$=Clazz.decorateAsClass(function(){this.associatedAtoms=null;Clazz.instantialize(this,arguments)},J.modelset.Bond,"BondSet",JU.BS);Clazz.makeConstructor(c$,
function(){Clazz.superConstructor(this,J.modelset.Bond.BondSet,[])});$_M(c$,"getAssociatedAtoms",function(){return this.associatedAtoms});Clazz.makeConstructor(c$,function(a){Clazz.superConstructor(this,J.modelset.Bond.BondSet,[]);J.util.BSUtil.copy2(a,this)},"JU.BS");Clazz.makeConstructor(c$,function(a,b){this.construct(a);this.associatedAtoms=b},"JU.BS,~A");c$=Clazz.p0p();c$.myVisibilityFlag=c$.prototype.myVisibilityFlag=J.viewer.JC.getShapeVisibilityFlag(1)}),Clazz.declarePackage("J.util"),Clazz.load(null,
"J.util.Measure","java.lang.Float JU.List $.P3 $.P4 $.V3 J.api.Interface J.util.Escape $.Logger $.Quaternion J.viewer.JC".split(" "),function(){c$=Clazz.declareType(J.util,"Measure");c$.computeAngle=$_M(c$,"computeAngle",function(a,b,c,d,e,f){d.sub2(a,b);e.sub2(c,b);a=d.angle(e);return f?a/0.017453292:a},"JU.T3,JU.T3,JU.T3,JU.V3,JU.V3,~B");c$.computeAngleABC=$_M(c$,"computeAngleABC",function(a,b,c,d){var e=new JU.V3,f=new JU.V3;return J.util.Measure.computeAngle(a,b,c,e,f,d)},"JU.T3,JU.T3,JU.T3,~B");
c$.computeTorsion=$_M(c$,"computeTorsion",function(a,b,c,d,e){var f=a.x-b.x,g=a.y-b.y;a=a.z-b.z;var h=c.x-b.x,k=c.y-b.y,l=c.z-b.z,m=c.x-d.x,n=c.y-d.y,q=c.z-d.z;d=g*l-a*k;b=a*h-f*l;var p=f*k-g*h;c=k*q-l*n;l=l*m-h*q;h=h*n-k*m;m=1/(c*c+l*l+h*h);k=Math.sqrt(1/(d*d+b*b+p*p));m=Math.sqrt(m);d=(d*c+b*l+p*h)*k*m;1<d&&(d=1);-1>d&&(d=-1);d=Math.acos(d);f=f*c+g*l+a*h;g=Math.abs(f);d=0<f/g?d:-d;return e?d/0.017453292:d},"JU.T3,JU.T3,JU.T3,JU.T3,~B");c$.computeHelicalAxis=$_M(c$,"computeHelicalAxis",function(a,
b,c,d,e){var f=new JU.V3;f.sub2(d,c);var g=e.getTheta(),h=e.getNormal(),k=f.dot(h);1E-4>Math.abs(k)&&(k=0);if(1073741854==b)return 0!=k&&h.scale(k),h;var l=new JU.V3;l.cross(f,h);0!=l.dot(l)&&l.normalize();var m=new JU.V3,n=JU.V3.newV(h);0==k&&(k=1.4E-45);n.scale(k);m.sub2(n,f);m.scale(0.5);l.scale(0==g?0:m.length()/Math.tan(3.141592653589793*(g/2/180)));f=JU.V3.newV(l);0!=g&&f.add(m);if(1666189314==b)return f;m=JU.P3.newP(c);m.sub(f);if(135266320==b)return m;1.4E-45!=k&&h.scale(k);l=JU.P3.newP(m);
l.add(h);g=J.util.Measure.computeTorsion(c,m,l,d,!0);if(Float.isNaN(g)||1E-4>f.length())g=e.getThetaDirectedV(h);if(135266305==b)return Float.$valueOf(g);if(135176==b)return'draw ID "'+a+'" VECTOR '+J.util.Escape.eP(m)+" "+J.util.Escape.eP(h)+" color "+(0>g?"{255.0 200.0 0.0}":"{255.0 0.0 128.0}");if(1746538509==b)return"measure "+J.util.Escape.eP(c)+J.util.Escape.eP(m)+J.util.Escape.eP(l)+J.util.Escape.eP(d);a=Math.abs(0==g?0:360/g);k=Math.abs(1.4E-45==k?0:h.length()*(0==g?1:360/g));switch(b){case 135266306:return[m,
h,f,JU.P3.new3(g,k,a)];case 1073742001:return[J.util.Escape.eP(m),J.util.Escape.eP(h),J.util.Escape.eP(f),J.util.Escape.eP(JU.P3.new3(g,k,a))];default:return null}},"~S,~N,JU.P3,JU.P3,J.util.Quaternion");c$.getPlaneThroughPoints=$_M(c$,"getPlaneThroughPoints",function(a,b,c,d,e,f,g){a=J.util.Measure.getNormalThroughPoints(a,b,c,d,e,f);g.set(d.x,d.y,d.z,a)},"JU.P3,JU.P3,JU.P3,JU.V3,JU.V3,JU.V3,JU.P4");c$.getPlaneThroughPoint=$_M(c$,"getPlaneThroughPoint",function(a,b,c){c.set(b.x,b.y,b.z,-b.dot(a))},
"JU.P3,JU.V3,JU.P4");c$.distanceToPlane=$_M(c$,"distanceToPlane",function(a,b){return null==a?NaN:(a.x*b.x+a.y*b.y+a.z*b.z+a.w)/Math.sqrt(a.x*a.x+a.y*a.y+a.z*a.z)},"JU.P4,JU.P3");c$.distanceToPlaneD=$_M(c$,"distanceToPlaneD",function(a,b,c){return null==a?NaN:(a.x*c.x+a.y*c.y+a.z*c.z+a.w)/b},"JU.P4,~N,JU.P3");c$.distanceToPlaneV=$_M(c$,"distanceToPlaneV",function(a,b,c){return null==a?NaN:(a.x*c.x+a.y*c.y+a.z*c.z+b)/Math.sqrt(a.x*a.x+a.y*a.y+a.z*a.z)},"JU.V3,~N,JU.P3");c$.calcNormalizedNormal=$_M(c$,
"calcNormalizedNormal",function(a,b,c,d,e,f){e.sub2(b,a);f.sub2(c,a);d.cross(e,f);d.normalize()},"JU.P3,JU.P3,JU.P3,JU.V3,JU.V3,JU.V3");c$.getDirectedNormalThroughPoints=$_M(c$,"getDirectedNormalThroughPoints",function(a,b,c,d,e,f,g){b=J.util.Measure.getNormalThroughPoints(a,b,c,e,f,g);null!=d&&(c=JU.P3.newP(a),c.add(e),f=c.distance(d),c.setT(a),c.sub(e),f>c.distance(d)&&(e.scale(-1),b=-b));return b},"JU.P3,JU.P3,JU.P3,JU.P3,JU.V3,JU.V3,JU.V3");c$.getNormalThroughPoints=$_M(c$,"getNormalThroughPoints",
function(a,b,c,d,e,f){J.util.Measure.calcNormalizedNormal(a,b,c,d,e,f);e.setT(a);return-e.dot(d)},"JU.P3,JU.P3,JU.P3,JU.V3,JU.V3,JU.V3");c$.getPlaneProjection=$_M(c$,"getPlaneProjection",function(a,b,c,d){var e=J.util.Measure.distanceToPlane(b,a);d.set(b.x,b.y,b.z);d.normalize();d.scale(-e);c.setT(a);c.add(d)},"JU.P3,JU.P4,JU.P3,JU.V3");c$.getNormalFromCenter=$_M(c$,"getNormalFromCenter",function(a,b,c,d,e,f){var g=new JU.V3,h=new JU.V3;b=J.util.Measure.getNormalThroughPoints(b,c,d,f,g,h);a=0<J.util.Measure.distanceToPlaneV(f,
b,a);a==e&&f.scale(-1);return!a},"JU.P3,JU.P3,JU.P3,JU.P3,~B,JU.V3");c$.getNormalToLine=$_M(c$,"getNormalToLine",function(a,b,c){c.sub2(a,b);c.cross(c,J.viewer.JC.axisY);c.normalize();Float.isNaN(c.x)&&c.set(1,0,0)},"JU.P3,JU.P3,JU.V3");c$.getBisectingPlane=$_M(c$,"getBisectingPlane",function(a,b,c,d,e){c.scaleAdd2(0.5,b,a);d.setT(b);d.normalize();J.util.Measure.getPlaneThroughPoint(c,d,e)},"JU.P3,JU.V3,JU.P3,JU.V3,JU.P4");c$.projectOntoAxis=$_M(c$,"projectOntoAxis",function(a,b,c,d){d.sub2(a,b);
var e=d.dot(c);a.setT(c);a.scaleAdd(e,b);d.sub2(a,b)},"JU.P3,JU.P3,JU.V3,JU.V3");c$.calcBestAxisThroughPoints=$_M(c$,"calcBestAxisThroughPoints",function(a,b,c,d,e){var f=a.length;b.setT(a[0]);c.sub2(a[f-1],b);c.normalize();J.util.Measure.calcAveragePointN(a,f,b);for(var g=0;g++<e&&0.001<J.util.Measure.findAxis(a,f,b,c,d););a=JU.P3.newP(a[0]);J.util.Measure.projectOntoAxis(a,b,c,d);b.setT(a)},"~A,JU.P3,JU.V3,JU.V3,~N");c$.findAxis=$_M(c$,"findAxis",function(a,b,c,d,e){for(var f=new JU.V3,g=new JU.V3,
h=new JU.P3,k=new JU.P3,l=JU.V3.newV(d),m=0,n=0;0<=--b;)h.setT(a[b]),k.setT(h),J.util.Measure.projectOntoAxis(k,c,d,e),g.sub2(h,k),n+=g.lengthSquared(),g.cross(e,g),f.add(g),m+=e.lengthSquared();a=JU.V3.newV(f);a.scale(1/m);g.cross(a,d);d.add(g);d.normalize();g.setT(d);g.sub(l);return g.length()},"~A,~N,JU.P3,JU.V3,JU.V3");c$.calcAveragePoint=$_M(c$,"calcAveragePoint",function(a,b,c){c.set((a.x+b.x)/2,(a.y+b.y)/2,(a.z+b.z)/2)},"JU.P3,JU.P3,JU.P3");c$.calcAveragePointN=$_M(c$,"calcAveragePointN",function(a,
b,c){c.setT(a[0]);for(var d=1;d<b;d++)c.add(a[d]);c.scale(1/b)},"~A,~N,JU.P3");c$.getCenterAndPoints=$_M(c$,"getCenterAndPoints",function(a){var b=a.size(),c=Array(b+1);c[0]=new JU.P3;if(0<b){for(var d=0;d<b;d++)c[0].add(c[d+1]=a.get(d));c[0].scale(1/b)}return c},"JU.List");c$.getTransformMatrix4=$_M(c$,"getTransformMatrix4",function(a,b,c,d){a=J.util.Measure.getCenterAndPoints(a);var e=J.util.Measure.getCenterAndPoints(b);b=Clazz.newFloatArray(2,0);var f=J.util.Measure.calculateQuaternionRotation([a,
e],b,!0),e=JU.V3.newV(e[0]);e.sub(a[0]);c.setMV(f.getMatrix(),e);null!=d&&d.setT(a[0]);return b[1]},"JU.List,JU.List,JU.M4,JU.P3");c$.calculateQuaternionRotation=$_M(c$,"calculateQuaternionRotation",function(a,b,c){b[1]=NaN;var d=new J.util.Quaternion;if(1==a[0].length||a[0].length!=a[1].length)return d;var e=a[0].length-1;if(c)for(var f=1;f<=e;f++){var g=a[0][f],h=a[1][f];if(Clazz.instanceOf(g,J.modelset.Atom)&&Clazz.instanceOf(h,J.modelset.Atom))J.util.Logger.info(" atom 1 "+g.getInfo()+"\tatom 2 "+
h.getInfo());else break}if(2>e)return d;for(var k=c=0,l=0,m=0,n=0,q=0,p=0,r=0,s=0,t=new JU.P3,u=new JU.P3,f=e+1;1<=--f;)g=a[0][f],h=a[1][f],t.setT(g),t.sub(a[0][0]),u.setT(h),u.sub(a[0][1]),c+=t.x*u.x,k+=t.x*u.y,l+=t.x*u.z,m+=t.y*u.x,n+=t.y*u.y,q+=t.y*u.z,p+=t.z*u.x,r+=t.z*u.y,s+=t.z*u.z;b[0]=J.util.Measure.getRmsd(a,d);d=Clazz.newDoubleArray(4,4,0);d[0][0]=c+n+s;d[0][1]=d[1][0]=q-r;d[0][2]=d[2][0]=p-l;d[0][3]=d[3][0]=k-m;d[1][1]=c-n-s;d[1][2]=d[2][1]=k+m;d[1][3]=d[3][1]=p+l;d[2][2]=-c+n-s;d[2][3]=
d[3][2]=q+r;d[3][3]=-c-n+s;d=J.api.Interface.getOptionInterface("util.Eigen").newM(d).getEigenvectorsFloatTransposed()[3];d=J.util.Quaternion.newP4(JU.P4.new4(d[1],d[2],d[3],d[0]));b[1]=J.util.Measure.getRmsd(a,d);return d},"~A,~A,~B");c$.getRmsd=$_M(c$,"getRmsd",function(a,b){for(var c=0,d=a[0],e=a[1],f=d[0],g=e[0],h=d.length-1,k=new JU.P3,l=h+1;1<=--l;)k.setT(d[l]),k.sub(f),b.transformP2(k,k).add(g),c+=k.distanceSquared(e[l]);return Math.sqrt(c/h)},"~A,J.util.Quaternion");c$.transformPoints=$_M(c$,
"transformPoints",function(a,b,c){for(var d=new JU.List,e=0;e<a.size();e++){var f=JU.P3.newP(a.get(e));f.sub(c);b.transform2(f,f);f.add(c);d.addLast(f)}return d},"JU.List,JU.M4,JU.P3");c$.isInTetrahedron=$_M(c$,"isInTetrahedron",function(a,b,c,d,e,f,g,h,k,l){J.util.Measure.getPlaneThroughPoints(d,e,b,g,h,k,f);var m=0<=J.util.Measure.distanceToPlane(f,a);J.util.Measure.getPlaneThroughPoints(b,e,c,g,h,k,f);if(m!=0<=J.util.Measure.distanceToPlane(f,a))return!1;J.util.Measure.getPlaneThroughPoints(c,
e,d,g,h,k,f);if(m!=0<=J.util.Measure.distanceToPlane(f,a))return!1;J.util.Measure.getPlaneThroughPoints(b,c,d,g,h,k,f);a=J.util.Measure.distanceToPlane(f,a);if(l)return m==0<=a;e=J.util.Measure.distanceToPlane(f,e);return 0>=e*a||Math.abs(e)>Math.abs(a)},"JU.P3,JU.P3,JU.P3,JU.P3,JU.P3,JU.P4,JU.V3,JU.V3,JU.V3,~B");c$.getIntersectionPP=$_M(c$,"getIntersectionPP",function(a,b){var c=a.x,d=a.y,e=a.z,f=a.w,g=b.x,h=b.y,k=b.z,l=b.w,m=JU.V3.new3(c,d,e),n=JU.V3.new3(g,h,k),q=new JU.V3;q.cross(m,n);var m=Math.abs(q.x),
n=Math.abs(q.y),p=Math.abs(q.z);switch(m>n?m>p?1:3:n>p?2:3){case 1:m=0;n=d*k-h*e;if(0.01>Math.abs(n))return null;e=(e*l-k*f)/n;c=(h*f-l*d)/n;break;case 2:n=c*k-g*e;if(0.01>Math.abs(n))return null;m=(e*l-k*f)/n;e=0;c=(g*f-l*c)/n;break;default:n=c*h-g*d;if(0.01>Math.abs(n))return null;m=(d*l-h*f)/n;e=(g*f-l*c)/n;c=0}d=new JU.List;d.addLast(JU.P3.new3(m,e,c));q.normalize();d.addLast(q);return d},"JU.P4,JU.P4");c$.getIntersection=$_M(c$,"getIntersection",function(a,b,c,d,e,f){J.util.Measure.getPlaneProjection(a,
c,d,e);e.set(c.x,c.y,c.z);e.normalize();null==b&&(b=JU.V3.newV(e));c=b.dot(e);if(0.01>Math.abs(c))return null;f.setT(d);f.sub(a);d.scaleAdd2(f.dot(e)/c,b,a);return d},"JU.P3,JU.V3,JU.P4,JU.P3,JU.V3,JU.V3");Clazz.defineStatics(c$,"radiansPerDegree",0.017453292519943295)}),Clazz.declarePackage("J.script"),Clazz.load(["J.script.T","JU.P3"],"J.script.SV","java.lang.Boolean $.Float java.util.Arrays $.Collections $.Hashtable JU.BS $.List $.ParserJS $.SB J.modelset.Bond J.util.BSUtil $.Escape $.Measure $.Txt".split(" "),
function(){c$=Clazz.decorateAsClass(function(){this.index=2147483647;this.flags=2;this.myName=null;Clazz.isClassDefined("J.script.SV.Sort")||J.script.SV.$SV$Sort$();Clazz.instantialize(this,arguments)},J.script,"SV",J.script.T);c$.newVariable=$_M(c$,"newVariable",function(a,b){var c=new J.script.SV;c.tok=a;c.value=b;return c},"~N,~O");c$.newScriptVariableInt=$_M(c$,"newScriptVariableInt",function(a){var b=new J.script.SV;b.tok=2;b.intValue=a;return b},"~N");c$.newScriptVariableBs=$_M(c$,"newScriptVariableBs",
function(a,b){var c=J.script.SV.newVariable(10,a);0<=b&&(c.index=b);return c},"JU.BS,~N");c$.newScriptVariableToken=$_M(c$,"newScriptVariableToken",function(a){return J.script.SV.newScriptVariableIntValue(a.tok,a.intValue,a.value)},"J.script.T");c$.newScriptVariableIntValue=$_M(c$,"newScriptVariableIntValue",function(a,b,c){a=J.script.SV.newVariable(a,c);a.intValue=b;return a},"~N,~N,~O");c$.sizeOf=$_M(c$,"sizeOf",function(a){switch(null==a?0:a.tok){case 10:return J.util.BSUtil.cardinalityOf(J.script.SV.bsSelectToken(a));
case 1048589:case 1048588:return-1;case 2:return-2;case 3:return-4;case 8:return-8;case 9:return-16;case 11:return-32;case 12:return-64;case 4:return a.value.length;case 7:return 2147483647==a.intValue?a.getList().size():J.script.SV.sizeOf(J.script.SV.selectItemTok(a));case 6:return a.value.size();default:return 0}},"J.script.T");c$.isVariableType=$_M(c$,"isVariableType",function(a){return Clazz.instanceOf(a,J.script.SV)||Clazz.instanceOf(a,JU.BS)||Clazz.instanceOf(a,Boolean)||Clazz.instanceOf(a,
Float)||Clazz.instanceOf(a,Integer)||Clazz.instanceOf(a,String)||Clazz.instanceOf(a,JU.P3)||Clazz.instanceOf(a,JU.V3)||Clazz.instanceOf(a,JU.P4)||Clazz.instanceOf(a,J.util.Quaternion)||Clazz.instanceOf(a,java.util.Map)||J.script.SV.isArray(a)},"~O");c$.getVariable=$_M(c$,"getVariable",function(a){return null==a?J.script.SV.newVariable(4,""):Clazz.instanceOf(a,J.script.SV)?a:Clazz.instanceOf(a,Boolean)?J.script.SV.getBoolean(a.booleanValue()):Clazz.instanceOf(a,Integer)?J.script.SV.newScriptVariableInt(a.intValue()):
Clazz.instanceOf(a,Float)?J.script.SV.newVariable(3,a):Clazz.instanceOf(a,String)?(a=J.script.SV.unescapePointOrBitsetAsVariable(a),Clazz.instanceOf(a,J.script.SV)?a:J.script.SV.newVariable(4,a)):Clazz.instanceOf(a,JU.P3)?J.script.SV.newVariable(8,a):Clazz.instanceOf(a,JU.V3)?J.script.SV.newVariable(8,JU.P3.newP(a)):Clazz.instanceOf(a,JU.BS)?J.script.SV.newVariable(10,a):Clazz.instanceOf(a,JU.P4)?J.script.SV.newVariable(9,a):Clazz.instanceOf(a,J.util.Quaternion)?J.script.SV.newVariable(9,a.toPoint4f()):
Clazz.instanceOf(a,JU.M3)?J.script.SV.newVariable(11,a):Clazz.instanceOf(a,JU.M4)?J.script.SV.newVariable(12,a):Clazz.instanceOf(a,java.util.Map)?J.script.SV.getVariableMap(a):Clazz.instanceOf(a,JU.List)?J.script.SV.getVariableList(a):J.util.Escape.isAV(a)?J.script.SV.getVariableAV(a):J.util.Escape.isAI(a)?J.script.SV.getVariableAI(a):J.util.Escape.isAB(a)?J.script.SV.getVariableAB(a):J.util.Escape.isAF(a)?J.script.SV.getVariableAF(a):J.util.Escape.isAD(a)?J.script.SV.getVariableAD(a):J.util.Escape.isAS(a)?
J.script.SV.getVariableAS(a):J.util.Escape.isAP(a)?J.script.SV.getVariableAP(a):J.util.Escape.isAII(a)?J.script.SV.getVariableAII(a):J.util.Escape.isAFF(a)?J.script.SV.getVariableAFF(a):J.util.Escape.isAFloat(a)?J.script.SV.newVariable(13,a):J.script.SV.newVariable(4,J.util.Escape.toReadable(null,a))},"~O");c$.isArray=$_M(c$,"isArray",($fz=function(a){return Clazz.instanceOf(a,Array)},$fz.isPrivate=!0,$fz),"~O");c$.getVariableMap=$_M(c$,"getVariableMap",function(a){for(var b=a,c=null,d,e=b.values().iterator();e.hasNext()&&
((d=e.next())||1);){c=d;break}if(!Clazz.instanceOf(c,J.script.SV)){a=new java.util.Hashtable;for(var f,b=b.entrySet().iterator();b.hasNext()&&((f=b.next())||1);)d=f.getKey(),c=f.getValue(),a.put(d,J.script.SV.isVariableType(c)?J.script.SV.getVariable(c):J.script.SV.newVariable(4,J.util.Escape.toReadable(null,c)))}return J.script.SV.newVariable(6,a)},"java.util.Map");c$.getVariableList=$_M(c$,"getVariableList",function(a){var b=a.size();if(0<b&&Clazz.instanceOf(a.get(0),J.script.SV))return J.script.SV.newVariable(7,
a);for(var c=new JU.List,d=0;d<b;d++)c.addLast(J.script.SV.getVariable(a.get(d)));return J.script.SV.newVariable(7,c)},"JU.List");c$.getVariableAV=$_M(c$,"getVariableAV",function(a){for(var b=new JU.List,c=0;c<a.length;c++)b.addLast(a[c]);return J.script.SV.newVariable(7,b)},"~A");c$.getVariableAD=$_M(c$,"getVariableAD",function(a){for(var b=new JU.List,c=0;c<a.length;c++)b.addLast(J.script.SV.newVariable(3,Float.$valueOf(a[c])));return J.script.SV.newVariable(7,b)},"~A");c$.getVariableAS=$_M(c$,
"getVariableAS",function(a){for(var b=new JU.List,c=0;c<a.length;c++)b.addLast(J.script.SV.newVariable(4,a[c]));return J.script.SV.newVariable(7,b)},"~A");c$.getVariableAP=$_M(c$,"getVariableAP",function(a){for(var b=new JU.List,c=0;c<a.length;c++)b.addLast(J.script.SV.newVariable(8,a[c]));return J.script.SV.newVariable(7,b)},"~A");c$.getVariableAFF=$_M(c$,"getVariableAFF",function(a){for(var b=new JU.List,c=0;c<a.length;c++)b.addLast(J.script.SV.getVariableAF(a[c]));return J.script.SV.newVariable(7,
b)},"~A");c$.getVariableAII=$_M(c$,"getVariableAII",function(a){for(var b=new JU.List,c=0;c<a.length;c++)b.addLast(J.script.SV.getVariableAI(a[c]));return J.script.SV.newVariable(7,b)},"~A");c$.getVariableAF=$_M(c$,"getVariableAF",function(a){for(var b=new JU.List,c=0;c<a.length;c++)b.addLast(J.script.SV.newVariable(3,Float.$valueOf(a[c])));return J.script.SV.newVariable(7,b)},"~A");c$.getVariableAI=$_M(c$,"getVariableAI",function(a){for(var b=new JU.List,c=0;c<a.length;c++)b.addLast(J.script.SV.newScriptVariableInt(a[c]));
return J.script.SV.newVariable(7,b)},"~A");c$.getVariableAB=$_M(c$,"getVariableAB",function(a){for(var b=new JU.List,c=0;c<a.length;c++)b.addLast(J.script.SV.newScriptVariableInt(a[c]));return J.script.SV.newVariable(7,b)},"~A");$_M(c$,"setv",function(a,b){this.index=a.index;this.intValue=a.intValue;this.tok=a.tok;this.value=a.value;if(b)switch(this.tok){case 6:this.value=new java.util.Hashtable(a.value);break;case 7:for(var c=new JU.List,d=a.getList(),e=0;e<d.size();e++)c.addLast(d.get(e));this.value=
c}return this},"J.script.SV,~B");$_M(c$,"setName",function(a){this.myName=a;this.flags|=1;return this},"~S");$_M(c$,"setGlobal",function(){this.flags&=-3;return this});$_M(c$,"canIncrement",function(){return J.script.T.tokAttr(this.flags,1)});$_M(c$,"increment",function(a){if(!this.canIncrement())return!1;switch(this.tok){case 2:this.intValue+=a;break;case 3:this.value=Float.$valueOf(this.value.floatValue()+a);break;default:this.value=J.script.SV.nValue(this),Clazz.instanceOf(this.value,Integer)?
(this.tok=2,this.intValue=this.value.intValue()):this.tok=3}return!0},"~N");$_M(c$,"asBoolean",function(){return J.script.SV.bValue(this)});$_M(c$,"asInt",function(){return J.script.SV.iValue(this)});$_M(c$,"asFloat",function(){return J.script.SV.fValue(this)});$_M(c$,"asString",function(){return J.script.SV.sValue(this)});c$.oValue=$_M(c$,"oValue",function(a){switch(null==a?0:a.tok){case 1048589:return Boolean.TRUE;case 0:case 1048588:return Boolean.FALSE;case 2:return Integer.$valueOf(a.intValue);
case 10:case 135266306:return J.script.SV.selectItemVar(a).value;default:return a.value}},"J.script.SV");c$.nValue=$_M(c$,"nValue",function(a){switch(null==a?0:a.tok){case 3:return a.value;case 2:a=a.intValue;break;case 4:if(0<=a.value.indexOf("."))return Float.$valueOf(J.script.SV.toFloat(a.value));a=Clazz.floatToInt(J.script.SV.toFloat(a.value));break;default:a=0}return Integer.$valueOf(a)},"J.script.T");c$.bValue=$_M(c$,"bValue",($fz=function(a){switch(null==a?0:a.tok){case 1048589:case 6:return!0;
case 1048588:return!1;case 2:return 0!=a.intValue;case 3:case 4:case 7:return 0!=J.script.SV.fValue(a);case 10:return 0!=J.script.SV.iValue(a);case 8:case 9:case 11:case 12:return 1E-4<Math.abs(J.script.SV.fValue(a));default:return!1}},$fz.isPrivate=!0,$fz),"J.script.T");c$.iValue=$_M(c$,"iValue",function(a){switch(null==a?0:a.tok){case 1048589:return 1;case 1048588:return 0;case 2:return a.intValue;case 3:case 7:case 4:case 8:case 9:case 11:case 12:return Clazz.floatToInt(J.script.SV.fValue(a));
case 10:return J.util.BSUtil.cardinalityOf(J.script.SV.bsSelectToken(a));default:return 0}},"J.script.T");c$.fValue=$_M(c$,"fValue",function(a){switch(null==a?0:a.tok){case 1048589:return 1;case 1048588:return 0;case 2:return a.intValue;case 3:return a.value.floatValue();case 7:if(2147483647==a.intValue)return a.getList().size();case 4:return J.script.SV.toFloat(J.script.SV.sValue(a));case 10:return J.script.SV.iValue(a);case 8:return a.value.length();case 9:return J.util.Measure.distanceToPlane(a.value,
J.script.SV.pt0);case 11:var b=new JU.P3;a.value.transform(b);return b.length();case 12:return b=new JU.P3,a.value.transform(b),b.length();default:return 0}},"J.script.T");c$.sValue=$_M(c$,"sValue",function(a){if(null==a)return"";var b,c;switch(a.tok){case 1048589:return"true";case 1048588:return"false";case 2:return""+a.intValue;case 10:return b=J.script.SV.bsSelectToken(a),Clazz.instanceOf(a.value,J.modelset.Bond.BondSet)?J.util.Escape.eBond(b):J.util.Escape.eBS(b);case 7:if(c=a.getList(),b=a.intValue,
0>=b&&(b=c.size()-b),2147483647!=b)return 1>b||b>c.size()?"":J.script.SV.sValue(c.get(b-1));case 6:return b=new JU.SB,c=new java.util.Hashtable,J.script.SV.sValueArray(b,a,c,0,!1),b.toString();case 4:return c=a.value,b=a.intValue,0>=b&&(b=c.length-b),2147483647==b?c:1>b||b>c.length?"":""+c.charAt(b-1);case 8:return J.util.Escape.eP(a.value);case 9:return J.util.Escape.eP4(a.value);case 11:case 12:return J.util.Escape.e(a.value);default:return a.value.toString()}},"J.script.T");c$.sValueArray=$_M(c$,
"sValueArray",($fz=function(a,b,c,d,e){switch(b.tok){case 6:if(c.containsKey(b)){a.append(e?"{}":null==b.myName?"<circular reference>":"<"+b.myName+">");break}c.put(b,Boolean.TRUE);var f=b.value;b=f.keySet();var g=f.keySet().toArray(Array(b.size()));java.util.Arrays.sort(g);if(e){a.append("{ ");e="";for(b=0;b<g.length;b++){var h=g[b];a.append(e).append(J.util.Escape.eS(h)).appendC(":");J.script.SV.sValueArray(a,f.get(h),c,d+1,!0);e=", "}a.append(" }");break}for(b=0;b<g.length;b++){a.append(g[b]).append("\t:");
var h=f.get(g[b]),k=new JU.SB;J.script.SV.sValueArray(k,h,c,d+1,e);h=k.toString();a.append(0<=h.indexOf("\n")?"\n":"\t");a.append(h).append("\n")}break;case 7:if(c.containsKey(b)){a.append(e?"[]":null==b.myName?"<circular reference>":"<"+b.myName+">");break}c.put(b,Boolean.TRUE);e&&a.append("[");f=b.getList();for(b=0;b<f.size();b++)e&&0<b&&a.append(","),g=f.get(b),J.script.SV.sValueArray(a,g,c,d+1,e),e||a.append("\n");e&&a.append("]");break;default:if(!e)for(c=0;c<d-1;c++)a.append("\t");a.append(e?
b.escape():J.script.SV.sValue(b))}},$fz.isPrivate=!0,$fz),"JU.SB,J.script.SV,java.util.Map,~N,~B");c$.ptValue=$_M(c$,"ptValue",function(a){switch(a.tok){case 8:return a.value;case 4:if(a=J.util.Escape.uP(a.value),Clazz.instanceOf(a,JU.P3))return a}return null},"J.script.SV");c$.pt4Value=$_M(c$,"pt4Value",function(a){switch(a.tok){case 9:return a.value;case 4:a=J.util.Escape.uP(a.value);if(!Clazz.instanceOf(a,JU.P4))break;return a}return null},"J.script.SV");c$.toFloat=$_M(c$,"toFloat",($fz=function(a){return a.equalsIgnoreCase("true")?
1:a.equalsIgnoreCase("false")||0==a.length?0:JU.ParserJS.parseFloatStrict(a)},$fz.isPrivate=!0,$fz),"~S");c$.concatList=$_M(c$,"concatList",function(a,b,c){var d=a.getList(),e=b.getList();if(!c){if(null==e)d.addLast(J.script.SV.newScriptVariableToken(b));else for(c=0;c<e.size();c++)d.addLast(e.get(c));return a}var f=new JU.List;if(null==d)f.addLast(a);else for(c=0;c<d.size();c++)f.addLast(d.get(c));if(null==e)f.addLast(b);else for(c=0;c<e.size();c++)f.addLast(e.get(c));return J.script.SV.getVariableList(f)},
"J.script.SV,J.script.SV,~B");c$.bsSelectToken=$_M(c$,"bsSelectToken",function(a){a=J.script.SV.selectItemTok2(a,-2147483648);return a.value},"J.script.T");c$.bsSelectVar=$_M(c$,"bsSelectVar",function(a){2147483647==a.index&&(a=J.script.SV.selectItemVar(a));return a.value},"J.script.SV");c$.bsSelectRange=$_M(c$,"bsSelectRange",function(a,b){a=J.script.SV.selectItemTok(a);a=J.script.SV.selectItemTok2(a,0>=b?b:1);a=J.script.SV.selectItemTok2(a,0>=b?2147483646:b);return a.value},"J.script.T,~N");c$.selectItemVar=
$_M(c$,"selectItemVar",function(a){return 2147483647!=a.index||7==a.tok&&2147483647==a.intValue?a:J.script.SV.selectItemVar2(a,-2147483648)},"J.script.SV");c$.selectItemTok=$_M(c$,"selectItemTok",function(a){return J.script.SV.selectItemTok2(a,-2147483648)},"J.script.T");c$.selectItemVar2=$_M(c$,"selectItemVar2",function(a,b){return J.script.SV.selectItemTok2(a,b)},"J.script.SV,~N");c$.selectItemTok2=$_M(c$,"selectItemTok2",function(a,b){switch(a.tok){case 11:case 12:case 10:case 7:case 4:break;default:return a}var c=
null,d=null,e=a.intValue;if(2147483647==e)return-2147483648==b&&(b=e),J.script.SV.newScriptVariableIntValue(a.tok,b,a.value);var f=0,g=Clazz.instanceOf(a,J.script.SV)&&2147483647!=a.index,h=J.script.SV.newScriptVariableIntValue(a.tok,2147483647,null);switch(a.tok){case 10:Clazz.instanceOf(a.value,J.modelset.Bond.BondSet)?(c=new J.modelset.Bond.BondSet(a.value,a.value.getAssociatedAtoms()),f=J.util.BSUtil.cardinalityOf(c)):(c=J.util.BSUtil.copy(a.value),f=g?1:J.util.BSUtil.cardinalityOf(c));break;
case 7:f=a.getList().size();break;case 4:d=a.value;f=d.length;break;case 11:f=-3;break;case 12:f=-4}if(0>f){f=-f;if(0<e&&Math.abs(e)>f)return h=e%10,e=Clazz.doubleToInt((e-h)/10),0<h&&h<=f&&e<=f?J.script.SV.newVariable(3,Float.$valueOf(a.value.getElement(e-1,h-1))):J.script.SV.newVariable(4,"");if(Math.abs(e)>f)return J.script.SV.newVariable(4,"");h=Clazz.newFloatArray(f,0);0>e?a.value.getColumn(-1-e,h):a.value.getRow(e-1,h);return-2147483648==b?J.script.SV.getVariableAF(h):1>b||b>f?J.script.SV.newVariable(4,
""):J.script.SV.newVariable(3,Float.$valueOf(h[b-1]))}0>=e&&(e=f+e);1>e&&(e=1);0==b?b=f:0>b&&(b=f+b);b>f?b=f:b<e&&(b=e);switch(a.tok){case 10:h.value=c;if(g){1<e&&c.clearAll();break}f=0;for(d=c.nextSetBit(0);0<=d;d=c.nextSetBit(d+1))(++f<e||f>b)&&c.clear(d);break;case 4:h.value=1>e||e>f?"":d.substring(e-1,b);break;case 7:if(1>e||e>f||b>f)return J.script.SV.newVariable(4,"");if(b==e)return a.getList().get(e-1);c=new JU.List;d=a.getList();f=b-e+1;for(g=0;g<f;g++)c.addLast(J.script.SV.newScriptVariableToken(d.get(g+
e-1)));h.value=c}return h},"J.script.T,~N");$_M(c$,"setSelectedValue",function(a,b){if(2147483647==a)return!1;var c;switch(this.tok){case 11:case 12:c=11==this.tok?3:4;if(10<a){var d=a%10,e=Clazz.doubleToInt((a-d)/10);if(0<d&&d<=c&&e<=c)return this.value.setElement(e-1,d-1,J.script.SV.fValue(b)),!0}if(0!=a&&(Math.abs(a)<=c&&7==b.tok)&&(d=b.getList(),d.size()==c)){for(var e=Clazz.newFloatArray(c,0),f=0;f<c;f++)e[f]=J.script.SV.fValue(d.get(f));0<a?11==this.tok?this.value.setRowA(a-1,e):this.value.setRow(a-
1,e):11==this.tok?this.value.setColumnA(-1-a,e):this.value.setColumn(-1-a,e);return!0}break;case 4:c=this.value;d=c.length;0>=a&&(a=d+a);for(0>--a&&(a=0);a>=c.length;)c+=" ";this.value=c.substring(0,a)+J.script.SV.sValue(b)+c.substring(a+1);return!0;case 7:c=this.getList().size();0>=a&&(a=c+a);0>--a&&(a=0);if(c<=a)for(f=c;f<=a;f++)this.getList().addLast(J.script.SV.newVariable(4,""));this.getList().set(a,b);return!0}return!1},"~N,J.script.SV");$_M(c$,"escape",function(){switch(this.tok){case 4:return J.util.Escape.eS(this.value);
case 7:case 6:var a=new JU.SB,b=new java.util.Hashtable;J.script.SV.sValueArray(a,this,b,0,!0);return a.toString();default:return J.script.SV.sValue(this)}});c$.unescapePointOrBitsetAsVariable=$_M(c$,"unescapePointOrBitsetAsVariable",function(a){if(null==a)return a;var b=null,c=null;if(Clazz.instanceOf(a,J.script.SV))switch(a.tok){case 8:case 9:case 11:case 12:case 10:b=a.value;break;case 4:c=a.value;break;default:c=J.script.SV.sValue(a)}else Clazz.instanceOf(a,String)&&(c=a);if(null!=c&&0==c.length)return c;
null==b&&(b=J.util.Escape.unescapePointOrBitsetOrMatrixOrArray(c));return Clazz.instanceOf(b,JU.P3)?J.script.SV.newVariable(8,b):Clazz.instanceOf(b,JU.P4)?J.script.SV.newVariable(9,b):Clazz.instanceOf(b,JU.BS)?(null!=c&&0==c.indexOf("[{")&&(b=new J.modelset.Bond.BondSet(b)),J.script.SV.newVariable(10,b)):Clazz.instanceOf(b,JU.M3)?J.script.SV.newVariable(11,b):Clazz.instanceOf(b,JU.M4)?J.script.SV.newVariable(12,b):a},"~O");c$.getBoolean=$_M(c$,"getBoolean",function(a){return J.script.SV.newScriptVariableToken(a?
J.script.SV.vT:J.script.SV.vF)},"~B");c$.sprintf=$_M(c$,"sprintf",function(a,b){if(null==b)return a;var c=0<=a.indexOf("d")||0<=a.indexOf("i")?Clazz.newIntArray(1,0):null,d=0<=a.indexOf("f")?Clazz.newFloatArray(1,0):null,e=0<=a.indexOf("e")?Clazz.newDoubleArray(1,0):null,f=0<=a.indexOf("s"),g=0<=a.indexOf("p")&&8==b.tok,h=0<=a.indexOf("q")&&9==b.tok,k=[c,d,e,null,null,null];if(7!=b.tok)return J.script.SV.sprintf(a,b,k,c,d,e,f,g,h);for(var l=b.getList(),m=Array(l.size()),n=0;n<m.length;n++)m[n]=J.script.SV.sprintf(a,
l.get(n),k,c,d,e,f,g,h);return m},"~S,J.script.SV");c$.sprintf=$_M(c$,"sprintf",($fz=function(a,b,c,d,e,f,g,h,k){null!=d&&(d[0]=J.script.SV.iValue(b));null!=e&&(e[0]=J.script.SV.fValue(b));null!=f&&(f[0]=J.script.SV.fValue(b));g&&(c[3]=J.script.SV.sValue(b));h&&(c[4]=b.value);k&&(c[5]=b.value);return J.util.Txt.sprintf(a,"IFDspq",c)},$fz.isPrivate=!0,$fz),"~S,J.script.SV,~A,~A,~A,~A,~B,~B,~B");c$.sprintfArray=$_M(c$,"sprintfArray",function(a){switch(a.length){case 0:return"";case 1:return J.script.SV.sValue(a[0])}var b=
J.util.Txt.split(J.util.Txt.simpleReplace(J.script.SV.sValue(a[0]),"%%","\u0001"),"%"),c=new JU.SB;c.append(b[0]);for(var d=1;d<b.length;d++){var e=J.script.SV.sprintf(J.util.Txt.formatCheck("%"+b[d]),d<a.length?a[d]:null);if(J.util.Escape.isAS(e))for(var f=0;f<e.length;f++)c.append(e[f]).append("\n");else c.append(e)}return c.toString()},"~A");Clazz.overrideMethod(c$,"toString",function(){return this.toString2()+"["+this.myName+" index ="+this.index+" intValue="+this.intValue+"]"});c$.getBitSet=
$_M(c$,"getBitSet",function(a,b){switch(a.tok){case 10:return J.script.SV.bsSelectVar(a);case 7:for(var c=new JU.BS,d=a.value,e=0;e<d.size();e++)if(!d.get(e).unEscapeBitSetArray(c)&&b)return null;return c}return b?null:new JU.BS},"J.script.SV,~B");c$.areEqual=$_M(c$,"areEqual",function(a,b){return null==a||null==b?!1:4==a.tok&&4==b.tok?J.script.SV.sValue(a).equalsIgnoreCase(J.script.SV.sValue(b)):8==a.tok&&8==b.tok||9==a.tok&&9==b.tok?1E-6>a.value.distance(b.value):1E-6>Math.abs(J.script.SV.fValue(a)-
J.script.SV.fValue(b))},"J.script.SV,J.script.SV");$_M(c$,"sortOrReverse",function(a){var b=this.getList();if(null==b||2>b.size())return this;if(-2147483648==a){a=b.size();for(var c=0;c<a;c++){var d=b.get(c);b.set(c,b.get(--a));b.set(a,d)}}else java.util.Collections.sort(this.getList(),Clazz.innerTypeInstance(J.script.SV.Sort,this,null,--a));return this},"~N");$_M(c$,"unEscapeBitSetArray",function(a){switch(this.tok){case 4:var b=J.util.Escape.uB(this.value);if(null==b)break;a.or(b);return!0;case 10:return a.or(this.value),
!0}return!1},"JU.BS");c$.unEscapeBitSetArray=$_M(c$,"unEscapeBitSetArray",function(a,b){for(var c=new JU.BS,d=0;d<a.size();d++)if(!a.get(d).unEscapeBitSetArray(c)&&b)return null;return c},"java.util.ArrayList,~B");c$.listValue=$_M(c$,"listValue",function(a){if(7!=a.tok)return[J.script.SV.sValue(a)];a=a.getList();for(var b=Array(a.size()),c=a.size();0<=--c;)b[c]=J.script.SV.sValue(a.get(c));return b},"J.script.T");c$.listAny=$_M(c$,"listAny",function(a){var b=new JU.List;a=a.getList();for(var c=0;c<
a.size();c++){var d=a.get(c),e=d.getList();if(null==e)b.addLast(d.value);else{for(var d=new JU.List,f=0;f<e.size();f++)e.get(f);b.addLast(d)}}return b},"J.script.SV");c$.flistValue=$_M(c$,"flistValue",function(a,b){if(7!=a.tok)return[J.script.SV.fValue(a)];var c=a.getList(),d;d=Clazz.newFloatArray(Math.max(b,c.size()),0);0==b&&(b=d.length);for(var e=Math.min(c.size(),b);0<=--e;)d[e]=J.script.SV.fValue(c.get(e));return d},"J.script.T,~N");$_M(c$,"toArray",function(){var a,b=null,c=null;switch(this.tok){case 11:b=
this.value;a=3;break;case 12:c=this.value;a=4;break;default:return}this.tok=7;for(var d=new JU.List,e=0;e<a;e++){var f=Clazz.newFloatArray(a,0);null==b?c.getRow(e,f):b.getRow(e,f);d.set(e,J.script.SV.getVariableAF(f))}this.value=d});$_M(c$,"mapValue",function(a){return 6==this.tok?this.value.get(a):null},"~S");$_M(c$,"getList",function(){return 7==this.tok?this.value:null});c$.$SV$Sort$=function(){Clazz.pu$h();c$=Clazz.decorateAsClass(function(){Clazz.prepareCallback(this,arguments);this.arrayPt=
0;Clazz.instantialize(this,arguments)},J.script.SV,"Sort",null,java.util.Comparator);Clazz.makeConstructor(c$,function(a){this.arrayPt=a},"~N");Clazz.overrideMethod(c$,"compare",function(a,b){if(a.tok!=b.tok){if(3==a.tok||2==a.tok||3==b.tok||2==b.tok){var c=J.script.SV.fValue(a),d=J.script.SV.fValue(b);return c<d?-1:c>d?1:0}if(4==a.tok||4==b.tok)return J.script.SV.sValue(a).compareTo(J.script.SV.sValue(b))}switch(a.tok){case 4:return J.script.SV.sValue(a).compareTo(J.script.SV.sValue(b));case 7:c=
a.getList();d=b.getList();if(c.size()!=d.size())return c.size()<d.size()?-1:1;var e=this.arrayPt;0>e&&(e+=c.size());return 0>e||e>=c.size()?0:this.compare(c.get(e),d.get(e));default:return c=J.script.SV.fValue(a),d=J.script.SV.fValue(b),c<d?-1:c>d?1:0}},"J.script.SV,J.script.SV");c$=Clazz.p0p()};c$.vT=c$.prototype.vT=J.script.SV.newScriptVariableIntValue(1048589,1,"true");c$.vF=c$.prototype.vF=J.script.SV.newScriptVariableIntValue(1048588,0,"false");Clazz.defineStatics(c$,"FLAG_CANINCREMENT",1,"FLAG_LOCALVAR",
2);c$.pt0=c$.prototype.pt0=new JU.P3}),Clazz.declarePackage("J.io"),Clazz.load(["java.lang.Enum"],"J.io.Encoding",null,function(){c$=Clazz.declareType(J.io,"Encoding",Enum);Clazz.defineEnumConstant(c$,"NONE",0,[]);Clazz.defineEnumConstant(c$,"UTF8",1,[]);Clazz.defineEnumConstant(c$,"UTF_16BE",2,[]);Clazz.defineEnumConstant(c$,"UTF_16LE",3,[]);Clazz.defineEnumConstant(c$,"UTF_32BE",4,[]);Clazz.defineEnumConstant(c$,"UTF_32LE",5,[])}),$_L(["java.util.Hashtable"],"java.util.Properties",["java.lang.NullPointerException",
"$.StringBuffer"],function(){c$=$_C(function(){this.defaults=this.builder=null;$_Z(this,arguments)},java.util,"Properties",java.util.Hashtable);$_K(c$,function(a){$_R(this,java.util.Properties,[]);this.defaults=a},"java.util.Properties");$_M(c$,"dumpString",($fz=function(a,b,c){var d=0;!c&&(d<b.length&&32==b.charAt(d).charCodeAt(0))&&(a.append("\\ "),d++);for(;d<b.length;d++){var e=b.charAt(d);switch(e){case "\t":a.append("\\t");break;case "\n":a.append("\\n");break;case "\f":a.append("\\f");break;
case "\r":a.append("\\r");break;default:(0<="\\#!=:".indexOf(e)||c&&32==e.charCodeAt(0))&&a.append("\\");if(!(32<=e.charCodeAt(0)&&126>=e.charCodeAt(0))){e=Integer.toHexString(e.charCodeAt(0));a.append("\\u");for(var f=0;f<4-e.length;f++)a.append("0")}a.append(e)}}},$fz.isPrivate=!0,$fz),"StringBuilder,~S,~B");$_M(c$,"getProperty",function(a){var b=this.get(a),b=$_O(b,String)?b:null;null==b&&null!=this.defaults&&(b=this.defaults.getProperty(a));return b},"~S");$_M(c$,"getProperty",function(a,b){var c=
this.get(a),c=$_O(c,String)?c:null;null==c&&null!=this.defaults&&(c=this.defaults.getProperty(a));return null==c?b:c},"~S,~S");$_M(c$,"list",function(a){if(null==a)throw new NullPointerException;for(var b=new StringBuffer(80),c=this.propertyNames();c.hasMoreElements();){var d=c.nextElement();b.append(d);b.append("=");for(var e=this.get(d),f=this.defaults;null==e;)e=f.get(d),f=f.defaults;40<e.length?(b.append(e.substring(0,37)),b.append("...")):b.append(e);a.println(b.toString());b.setLength(0)}},
"java.io.PrintStream");$_M(c$,"list",function(a){if(null==a)throw new NullPointerException;for(var b=new StringBuffer(80),c=this.propertyNames();c.hasMoreElements();){var d=c.nextElement();b.append(d);b.append("=");for(var e=this.get(d),f=this.defaults;null==e;)e=f.get(d),f=f.defaults;40<e.length?(b.append(e.substring(0,37)),b.append("...")):b.append(e);a.println(b.toString());b.setLength(0)}},"java.io.PrintWriter");$_M(c$,"load",function(){},"java.io.InputStream");$_M(c$,"propertyNames",function(){if(null==
this.defaults)return this.keys();for(var a=new java.util.Hashtable(this.defaults.size()+this.size()),b=this.defaults.propertyNames();b.hasMoreElements();)a.put(b.nextElement(),a);for(b=this.keys();b.hasMoreElements();)a.put(b.nextElement(),a);return a.keys()});$_M(c$,"save",function(a,b){try{this.store(a,b)}catch(c){if(!$_O(c,java.io.IOException))throw c;}},"java.io.OutputStream,~S");$_M(c$,"setProperty",function(a,b){return this.put(a,b)},"~S,~S");$_M(c$,"store",function(){},"java.io.OutputStream,~S");
$_M(c$,"loadFromXML",function(){},"java.io.InputStream");$_M(c$,"storeToXML",function(){},"java.io.OutputStream,~S");$_M(c$,"storeToXML",function(){},"java.io.OutputStream,~S,~S");$_M(c$,"substitutePredefinedEntries",($fz=function(a){return a.replaceAll("&","&amp;").replaceAll("<","&lt;").replaceAll(">","&gt;").replaceAll("'","&apos;").replaceAll('"',"&quot;")},$fz.isPrivate=!0,$fz),"~S");$_S(c$,"PROP_DTD_NAME","http://java.sun.com/dtd/properties.dtd","PROP_DTD",'<?xml version="1.0" encoding="UTF-8"?>    <!ELEMENT properties (comment?, entry*) >    <!ATTLIST properties version CDATA #FIXED "1.0" >    <!ELEMENT comment (#PCDATA) >    <!ELEMENT entry (#PCDATA) >    <!ATTLIST entry key CDATA #REQUIRED >',
"NONE",0,"SLASH",1,"UNICODE",2,"CONTINUE",3,"KEY_DONE",4,"IGNORE",5,"lineSeparator",null)}),Clazz.declarePackage("J.util"),Clazz.load(["JU.BS"],"J.util.Elements",["java.lang.Character","java.util.Hashtable","JU.ParserJS","J.util.Logger"],function(){c$=Clazz.declareType(J.util,"Elements");c$.getAtomicMass=$_M(c$,"getAtomicMass",function(a){return 1>a||a>=J.util.Elements.atomicMass.length?0:J.util.Elements.atomicMass[a]},"~N");c$.elementNumberFromSymbol=$_M(c$,"elementNumberFromSymbol",function(a,c){if(null==
J.util.Elements.htElementMap){for(var d=new java.util.Hashtable,e=J.util.Elements.elementNumberMax;0<=--e;){var f=J.util.Elements.elementSymbols[e],g=Integer.$valueOf(e);d.put(f,g);2==f.length&&d.put(f.toUpperCase(),g)}for(e=J.util.Elements.altElementMax;4<=--e;)f=J.util.Elements.altElementSymbols[e],g=Integer.$valueOf(J.util.Elements.altElementNumbers[e]),d.put(f,g),2==f.length&&d.put(f.toUpperCase(),g);$t$=J.util.Elements.htElementMap=d;J.util.Elements.prototype.htElementMap=J.util.Elements.htElementMap;
$t$}if(null==a)return 0;d=J.util.Elements.htElementMap.get(a);if(null!=d)return d.intValue();if(Character.isDigit(a.charAt(0))&&(f=a.length-2,0<=f&&Character.isDigit(a.charAt(f))&&f++,d=0<f?JU.ParserJS.parseInt(a.substring(0,f)):0,0<d&&(f=J.util.Elements.elementNumberFromSymbol(a.substring(f),!0),0<f)))return d=J.util.Elements.getAtomicAndIsotopeNumber(f,d),J.util.Elements.htElementMap.put(a.toUpperCase(),Integer.$valueOf(d)),d;c||J.util.Logger.error("'"+a+"' is not a recognized symbol");return 0},
"~S,~B");c$.elementSymbolFromNumber=$_M(c$,"elementSymbolFromNumber",function(a){var c=0;if(a>=J.util.Elements.elementNumberMax){for(c=J.util.Elements.altElementMax;0<=--c;)if(a==J.util.Elements.altElementNumbers[c])return J.util.Elements.altElementSymbols[c];c=J.util.Elements.getIsotopeNumber(a);return""+c+J.util.Elements.getElementSymbol(a%128)}return J.util.Elements.getElementSymbol(a)},"~N");c$.getElementSymbol=$_M(c$,"getElementSymbol",($fz=function(a){if(0>a||a>=J.util.Elements.elementNumberMax)a=
0;return J.util.Elements.elementSymbols[a]},$fz.isPrivate=!0,$fz),"~N");c$.elementNameFromNumber=$_M(c$,"elementNameFromNumber",function(a){if(a>=J.util.Elements.elementNumberMax){for(var c=J.util.Elements.altElementMax;0<=--c;)if(a==J.util.Elements.altElementNumbers[c])return J.util.Elements.altElementNames[c];a%=128}if(0>a||a>=J.util.Elements.elementNumberMax)a=0;return J.util.Elements.elementNames[a]},"~N");c$.altElementNameFromIndex=$_M(c$,"altElementNameFromIndex",function(a){return J.util.Elements.altElementNames[a]},
"~N");c$.altElementNumberFromIndex=$_M(c$,"altElementNumberFromIndex",function(a){return J.util.Elements.altElementNumbers[a]},"~N");c$.altElementSymbolFromIndex=$_M(c$,"altElementSymbolFromIndex",function(a){return J.util.Elements.altElementSymbols[a]},"~N");c$.altIsotopeSymbolFromIndex=$_M(c$,"altIsotopeSymbolFromIndex",function(a){a=J.util.Elements.altElementNumbers[a];return(a>>7)+J.util.Elements.elementSymbolFromNumber(a&127)},"~N");c$.altIsotopeSymbolFromIndex2=$_M(c$,"altIsotopeSymbolFromIndex2",
function(a){a=J.util.Elements.altElementNumbers[a];return J.util.Elements.elementSymbolFromNumber(a&127)+(a>>7)},"~N");c$.getElementNumber=$_M(c$,"getElementNumber",function(a){return a&127},"~N");c$.getIsotopeNumber=$_M(c$,"getIsotopeNumber",function(a){return a>>7},"~N");c$.getAtomicAndIsotopeNumber=$_M(c$,"getAtomicAndIsotopeNumber",function(a,c){return(0>a?0:a)+(0>=c?0:c<<7)},"~N,~N");c$.altElementIndexFromNumber=$_M(c$,"altElementIndexFromNumber",function(a){for(var c=0;c<J.util.Elements.altElementMax;c++)if(J.util.Elements.altElementNumbers[c]==
a)return c;return 0},"~N");c$.getNaturalIsotope=$_M(c$,"getNaturalIsotope",function(a){for(var c=0;c<J.util.Elements.naturalIsotopeMasses.length;c+=2)if(J.util.Elements.naturalIsotopeMasses[c]==a)return J.util.Elements.naturalIsotopeMasses[++c];return 0},"~N");c$.isNaturalIsotope=$_M(c$,"isNaturalIsotope",function(a){return 0<="1H,12C,14N,".indexOf(a+",")},"~S");c$.getBondingRadiusFloat=$_M(c$,"getBondingRadiusFloat",function(a,c){var d=a&127;return 0<c&&J.util.Elements.bsCations.get(d)?J.util.Elements.getBondingRadFromTable(d,
c,J.util.Elements.cationLookupTable):0>c&&J.util.Elements.bsAnions.get(d)?J.util.Elements.getBondingRadFromTable(d,c,J.util.Elements.anionLookupTable):J.util.Elements.covalentMars[d]/1E3},"~N,~N");c$.getBondingRadFromTable=$_M(c$,"getBondingRadFromTable",function(a,c,d){c=(a<<4)+(c+4);for(var e=0,f=0,g=0,h=Clazz.doubleToInt(d.length/2);g!=h;)if(f=Clazz.doubleToInt((g+h)/2),e=d[f<<1],e>c)h=f;else if(e<c)g=f+1;else return d[(f<<1)+1]/1E3;e>c&&f--;e=d[f<<1];a!=e>>4&&f++;return d[(f<<1)+1]/1E3},"~N,~N,~A");
c$.getVanderwaalsMar=$_M(c$,"getVanderwaalsMar",function(a,c){return J.util.Elements.vanderwaalsMars[((a&127)<<2)+c.pt%4]},"~N,J.constant.EnumVdw");c$.getHydrophobicity=$_M(c$,"getHydrophobicity",function(a){return 1>a||a>=J.util.Elements.hydrophobicities.length?0:J.util.Elements.hydrophobicities[a]},"~N");c$.getAllredRochowElectroNeg=$_M(c$,"getAllredRochowElectroNeg",function(a){return 0<a&&a<J.util.Elements.electroNegativities.length?J.util.Elements.electroNegativities[a]:0},"~N");c$.isElement=
$_M(c$,"isElement",function(a,c){return(a&127)==c},"~N,~N");Clazz.defineStatics(c$,"elementSymbols","Xx H He Li Be B C N O F Ne Na Mg Al Si P S Cl Ar K Ca Sc Ti V Cr Mn Fe Co Ni Cu Zn Ga Ge As Se Br Kr Rb Sr Y Zr Nb Mo Tc Ru Rh Pd Ag Cd In Sn Sb Te I Xe Cs Ba La Ce Pr Nd Pm Sm Eu Gd Tb Dy Ho Er Tm Yb Lu Hf Ta W Re Os Ir Pt Au Hg Tl Pb Bi Po At Rn Fr Ra Ac Th Pa U Np Pu Am Cm Bk Cf Es Fm Md No Lr Rf Db Sg Bh Hs Mt".split(" "),"atomicMass",[0,1.008,4.003,6.941,9.012,10.81,12.011,14.007,15.999,18.998,
20.18,22.99,24.305,26.981,28.086,30.974,32.07,35.453,39.948,39.1,40.08,44.956,47.88,50.941,52,54.938,55.847,58.93,58.69,63.55,65.39,69.72,72.61,74.92,78.96,79.9,83.8,85.47,87.62,88.91,91.22,92.91,95.94,98.91,101.07,102.91,106.42,107.87,112.41,114.82,118.71,121.75,127.6,126.91,131.29,132.91,137.33,138.91,140.12,140.91,144.24,144.9,150.36,151.96,157.25,158.93,162.5,164.93,167.26,168.93,173.04,174.97,178.49,180.95,183.85,186.21,190.2,192.22,195.08,196.97,200.59,204.38,207.2,208.98,210,210,222,223,226.03,
227.03,232.04,231.04,238.03,237.05,239.1,243.1,247.1,247.1,252.1,252.1,257.1,256.1,259.1,260.1,261,262,263,262,265,268]);c$.elementNumberMax=c$.prototype.elementNumberMax=J.util.Elements.elementSymbols.length;Clazz.defineStatics(c$,"htElementMap",null,"elementNames","unknown hydrogen helium lithium beryllium boron carbon nitrogen oxygen fluorine neon sodium magnesium aluminum silicon phosphorus sulfur chlorine argon potassium calcium scandium titanium vanadium chromium manganese iron cobalt nickel copper zinc gallium germanium arsenic selenium bromine krypton rubidium strontium yttrium zirconium niobium molybdenum technetium ruthenium rhodium palladium silver cadmium indium tin antimony tellurium iodine xenon cesium barium lanthanum cerium praseodymium neodymium promethium samarium europium gadolinium terbium dysprosium holmium erbium thulium ytterbium lutetium hafnium tantalum tungsten rhenium osmium iridium platinum gold mercury thallium lead bismuth polonium astatine radon francium radium actinium thorium protactinium uranium neptunium plutonium americium curium berkelium californium einsteinium fermium mendelevium nobelium lawrencium rutherfordium dubnium seaborgium bohrium hassium meitnerium".split(" "),
"naturalIsotopeMasses",[1,1,6,12,7,14,8,16],"naturalIsotopes","1H,12C,14N,","firstIsotope",4,"altElementNumbers",[0,13,16,55,257,385,1414,1670,1798,1927]);c$.altElementMax=c$.prototype.altElementMax=J.util.Elements.altElementNumbers.length;Clazz.defineStatics(c$,"altElementSymbols","Xx Al S Cs D T 11C 13C 14C 15N".split(" "),"altElementNames","dummy aluminium sulphur caesium deuterium tritium    ".split(" "),"VdwPROBE","#VDW radii for PROBE;{_H}.vdw = 1.0;{_H and connected(_C) and not connected(within(smiles,'[a]'))}.vdw = 1.17;{_C}.vdw = 1.75;{_C and connected(3) and connected(_O)}.vdw = 1.65;{_N}.vdw = 1.55;{_O}.vdw = 1.4;{_P}.vdw = 1.8;{_S}.vdw = 1.8;message VDW radii for H, C, N, O, P, and S set according to Word, et al., J. Mol. Biol. (1999) 285, 1711-1733",
"vanderwaalsMars",[1E3,1E3,1E3,1E3,1200,1100,1100,1200,1400,1400,2200,1400,1820,1810,1220,2200,1700,1530,628,1900,2080,1920,1548,1800,1950,1700,1548,1700,1850,1550,1400,1600,1700,1520,1348,1550,1730,1470,1300,1500,1540,1540,2020,1540,2270,2270,2200,2400,1730,1730,1500,2200,2050,1840,1500,2100,2100,2100,2200,2100,2080,1800,1880,1950,2E3,1800,1808,1800,1970,1750,1748,1800,1880,1880,2768,1880,2750,2750,2388,2800,1973,2310,1948,2400,1700,2300,1320,2300,1700,2150,1948,2150,1700,2050,1060,2050,1700,2050,
1128,2050,1700,2050,1188,2050,1700,2050,1948,2050,1700,2E3,1128,2E3,1630,2E3,1240,2E3,1400,2E3,1148,2E3,1390,2100,1148,2100,1870,1870,1548,2100,1700,2110,3996,2100,1850,1850,828,2050,1900,1900,900,1900,2100,1830,1748,1900,2020,2020,1900,2020,1700,3030,2648,2900,1700,2490,2020,2550,1700,2400,1608,2400,1700,2300,1420,2300,1700,2150,1328,2150,1700,2100,1748,2100,1700,2050,1800,2050,1700,2050,1200,2050,1700,2E3,1220,2E3,1630,2050,1440,2050,1720,2100,1548,2100,1580,2200,1748,2200,1930,2200,1448,2200,2170,
1930,1668,2250,2200,2170,1120,2200,2060,2060,1260,2100,2150,1980,1748,2100,2160,2160,2100,2160,1700,3430,3008,3E3,1700,2680,2408,2700,1700,2500,1828,2500,1700,2480,1860,2480,1700,2470,1620,2470,1700,2450,1788,2450,1700,2430,1760,2430,1700,2420,1740,2420,1700,2400,1960,2400,1700,2380,1688,2380,1700,2370,1660,2370,1700,2350,1628,2350,1700,2330,1608,2330,1700,2320,1588,2320,1700,2300,1568,2300,1700,2280,1540,2280,1700,2270,1528,2270,1700,2250,1400,2250,1700,2200,1220,2200,1700,2100,1260,2100,1700,2050,
1300,2050,1700,2E3,1580,2E3,1700,2E3,1220,2E3,1720,2050,1548,2050,1660,2100,1448,2100,1550,2050,1980,2050,1960,1960,1708,2200,2020,2020,2160,2300,1700,2070,1728,2300,1700,1970,1208,2E3,1700,2020,1120,2E3,1700,2200,2300,2E3,1700,3480,3240,2E3,1700,2830,2568,2E3,1700,2E3,2120,2E3,1700,2400,1840,2400,1700,2E3,1600,2E3,1860,2300,1748,2300,1700,2E3,1708,2E3,1700,2E3,1668,2E3,1700,2E3,1660,2E3,1700,2E3,1648,2E3,1700,2E3,1640,2E3,1700,2E3,1628,2E3,1700,2E3,1620,2E3,1700,2E3,1608,2E3,1700,2E3,1600,2E3,1700,
2E3,1588,2E3,1700,2E3,1580,2E3,1700,2E3,1600,2E3,1700,2E3,1600,2E3,1700,2E3,1600,2E3,1700,2E3,1600,2E3,1700,2E3,1600,2E3,1700,2E3,1600,2E3],"covalentMars",[0,230,930,680,350,830,680,680,680,640,1120,970,1100,1350,1200,750,1020,990,1570,1330,990,1440,1470,1330,1350,1350,1340,1330,1500,1520,1450,1220,1170,1210,1220,1210,1910,1470,1120,1780,1560,1480,1470,1350,1400,1450,1500,1590,1690,1630,1460,1460,1470,1400,1980,1670,1340,1870,1830,1820,1810,1800,1800,1990,1790,1760,1750,1740,1730,1720,1940,1720,1570,
1430,1370,1350,1370,1320,1500,1500,1700,1550,1540,1540,1680,1700,2400,2E3,1900,1880,1790,1610,1580,1550,1530,1510,1500,1500,1500,1500,1500,1500,1500,1500,1600,1600,1600,1600,1600,1600],"FORMAL_CHARGE_MIN",-4,"FORMAL_CHARGE_MAX",7,"cationLookupTable",[53,680,69,440,70,350,85,350,87,230,104,160,117,680,119,160,121,130,133,220,138,90,155,80,165,1120,181,970,197,820,198,660,215,510,229,650,232,420,247,440,249,350,262,2190,264,370,266,300,281,340,283,270,293,1540,309,1330,325,1180,326,990,343,732,357,
960,358,940,359,760,360,680,374,880,375,740,376,630,377,590,389,810,390,890,391,630,394,520,406,800,407,660,408,600,411,460,422,740,423,640,438,720,439,630,454,690,469,960,470,720,485,880,486,740,501,810,503,620,518,730,520,530,535,580,537,460,549,660,552,500,554,420,569,470,571,390,597,1470,614,1120,631,893,645,1090,648,790,661,1E3,664,740,665,690,677,930,680,700,682,620,699,979,712,670,727,680,742,800,744,650,757,1260,758,890,773,1140,774,970,791,810,806,930,808,710,823,760,825,620,837,820,840,
700,842,560,857,620,859,500,885,1670,901,1530,902,1340,917,1390,919,1016,933,1270,935,1034,936,920,951,1013,952,900,967,995,983,979,999,964,1014,1090,1015,950,1031,938,1047,923,1048,840,1063,908,1079,894,1095,881,1111,870,1126,930,1127,858,1143,850,1160,780,1177,680,1192,700,1194,620,1208,720,1211,560,1224,880,1226,690,1240,680,1254,800,1256,650,1269,1370,1271,850,1285,1270,1286,1100,1301,1470,1303,950,1318,1200,1320,840,1333,980,1335,960,1337,740,1354,670,1371,620,1397,1800,1414,1430,1431,1180,1448,
1020,1463,1130,1464,980,1465,890,1480,970,1482,800,1495,1100,1496,950,1499,710,1511,1080,1512,930,1527,1070,1528,920],"anionLookupTable",[19,1540,96,2600,113,1710,130,1360,131,680,147,1330,241,2120,258,1840,275,1810,512,2720,529,2220,546,1980,563,1960,800,2940,803,3700,817,2450,834,2110,835,2500,851,2200]);c$.bsCations=c$.prototype.bsCations=new JU.BS;c$.bsAnions=c$.prototype.bsAnions=new JU.BS;for(var a=0;a<J.util.Elements.anionLookupTable.length;a+=2)J.util.Elements.bsAnions.set(J.util.Elements.anionLookupTable[a]>>
4);for(a=0;a<J.util.Elements.cationLookupTable.length;a+=2)J.util.Elements.bsCations.set(J.util.Elements.cationLookupTable[a]>>4);Clazz.defineStatics(c$,"hydrophobicities",[0,0.62,-2.53,-0.78,-0.9,0.29,-0.85,-0.74,0.48,-0.4,1.38,1.06,-1.5,0.64,1.19,0.12,-0.18,-0.05,0.81,0.26,1.08]);(J.util.Elements.elementNames.length!=J.util.Elements.elementNumberMax||Clazz.doubleToInt(J.util.Elements.vanderwaalsMars.length/4)!=J.util.Elements.elementNumberMax||J.util.Elements.covalentMars.length!=J.util.Elements.elementNumberMax)&&
J.util.Logger.error("ERROR!!! Element table length mismatch:\n elementSymbols.length="+J.util.Elements.elementSymbols.length+"\n elementNames.length="+J.util.Elements.elementNames.length+"\n vanderwaalsMars.length="+J.util.Elements.vanderwaalsMars.length+"\n covalentMars.length="+J.util.Elements.covalentMars.length);Clazz.defineStatics(c$,"electroNegativities",[0,2.2,0,0.97,1.47,2.01,2.5,3.07,3.5,4.1,0,1.01,1.23,1.47,1.74,2.06,2.44,2.83,0,0.91,1.04,1.2,1.32,1.45,1.56,1.6,1.64,1.7,1.75,1.75,1.66,1.82,
2.02,2.2,2.48,2.74,0,0.89,0.99,1.11,1.22,1.23,1.3,1.36,1.42,1.45,1.35,1.42,1.46,1.49,1.72,1.82,2.01,2.21])}),Clazz.declarePackage("J.util"),Clazz.load(["JU.V3"],"J.util.Vibration",null,function(){c$=Clazz.declareType(J.util,"Vibration",JU.V3);$_M(c$,"setTempPoint",function(a,b,c){a.scaleAdd2(Math.cos(6.283185307179586*b)*c,this,a)},"JU.P3,~N,~N");Clazz.defineStatics(c$,"twoPI",6.283185307179586)}),Clazz.declarePackage("J.viewer"),Clazz.load(["JU.SB","$.V3","J.util.Elements","$.Txt"],"J.viewer.JC",
["java.lang.NullPointerException","java.util.Hashtable","JU.ParserJS","J.util.Logger"],function(){c$=Clazz.declareType(J.viewer,"JC");c$.embedScript=$_M(c$,"embedScript",function(a){return"\n/****** Jmol Embedded Script **** \n"+a+"\n**/"},"~S");c$.getSpecialAtomName=$_M(c$,"getSpecialAtomName",function(a){return J.viewer.JC.specialAtomNames[a]},"~N");c$.getSpecialAtomNames=$_M(c$,"getSpecialAtomNames",($fz=function(){$t$=J.viewer.JC.htSpecialAtoms=new java.util.Hashtable;J.viewer.JC.prototype.htSpecialAtoms=
J.viewer.JC.htSpecialAtoms;$t$;for(var a=J.viewer.JC.specialAtomNames.length;0<=--a;){var b=J.viewer.JC.specialAtomNames[a];null!=b&&J.viewer.JC.htSpecialAtoms.put(b,Integer.$valueOf(a))}},$fz.isPrivate=!0,$fz));c$.lookupSpecialAtomID=$_M(c$,"lookupSpecialAtomID",function(a){null==J.viewer.JC.htSpecialAtoms&&J.viewer.JC.getSpecialAtomNames();a=J.viewer.JC.htSpecialAtoms.get(a);return null!=a?a.intValue():0},"~S");c$.getAminoAcidValenceAndCharge=$_M(c$,"getAminoAcidValenceAndCharge",function(a,b,e){if(null==
a||0==a.length||3<a.length||b.equals("CA")||b.equals("CB"))return!1;var f=b.charAt(0),g=1==b.length?"\x00":b.charAt(1),h=!1,k=e[3];switch(a.length){case 3:if(1==b.length)switch(f){case "N":if(1<k)return!1;e[1]=1;break;case "O":h=0>"HOH;DOD;WAT".indexOf(a);break;default:h=!0}else a+=f,h=0<="ARGN;ASNN;ASNO;ASPO;GLNN;GLNO;GLUO;HISN;HISC;PHECTRPC;TRPN;TYRC".indexOf(a),0<="LYSN".indexOf(a)?e[1]=1:"O"==f&&"X"==g&&(e[1]=-1);break;case 1:case 2:if(2<b.length&&"'"==b.charAt(2))return!1;switch(f){case "C":if("7"==
g)return!1;break;case "N":switch(g){case "1":case "3":0<="A3;A1;C3;G3;I3".indexOf(""+a.charAt(a.length-1)+g)&&e[0]--;break;case "7":e[0]--}}h=!0}if(h)switch(f){case "N":e[2]=2;break;case "C":e[2]=2;e[0]--;break;case "O":e[0]--}return!0},"~S,~S,~A");c$.getStandardPdbHydrogenCount=$_M(c$,"getStandardPdbHydrogenCount",function(a){return 0>a||a>=J.viewer.JC.pdbHydrogenCount.length?-1:J.viewer.JC.pdbHydrogenCount[a]},"~N");c$.getPdbBondInfo=$_M(c$,"getPdbBondInfo",function(a,b){if(0>a||a>J.viewer.JC.pdbBondInfo.length)return null;
var e=J.viewer.JC.pdbBondInfo[a];if(b&&0<=(a=e.indexOf("O3'")))e=e.substring(0,a);for(var f=JU.ParserJS.getTokens(e),g=Array(Clazz.doubleToInt(f.length/2)),h=0,k=0;h<g.length;h++){var l=f[k++],m=f[k++];if(1==m.length)switch(m.charAt(0)){case "N":m="H@H2";break;case "B":m="HB3@HB2";break;case "D":m="HD2@HD3";break;case "G":m="HG3@HG2";break;case "2":m="H2''@H2'";break;case "5":m="H5''@H5'"}"H"!=m.charAt(0)&&0<l.compareTo(m)&&(e=m,m=l,l=e);g[h]=[l,m,m.startsWith("H")?"1":"2"]}return g},"~N,~B");c$.checkCarbohydrate=
$_M(c$,"checkCarbohydrate",function(a){return null!=a&&0<=",[AHR],[ALL],[AMU],[ARA],[ARB],[BDF],[BDR],[BGC],[BMA],[FCA],[FCB],[FRU],[FUC],[FUL],[GAL],[GLA],[GLC],[GXL],[GUP],[LXC],[MAN],[RAM],[RIB],[RIP],[XYP],[XYS],[CBI],[CT3],[CTR],[CTT],[LAT],[MAB],[MAL],[MLR],[MTT],[SUC],[TRE],[GCU],[MTL],[NAG],[NDG],[RHA],[SOR],[SOL],[SOE],[XYL],[A2G],[LBT],[NGA],[SIA],[SLB],[AFL],[AGC],[GLB],[NAN],[RAA]".indexOf("["+a.toUpperCase()+"]")},"~S");c$.getGroup3List=$_M(c$,"getGroup3List",function(){if(null!=J.viewer.JC.group3List)return J.viewer.JC.group3List;
for(var a=new JU.SB,b=1;42>b;b++)a.append(",[").append((J.viewer.JC.predefinedGroup3Names[b]+"   ").substring(0,3)+"]");a.append(",[AHR],[ALL],[AMU],[ARA],[ARB],[BDF],[BDR],[BGC],[BMA],[FCA],[FCB],[FRU],[FUC],[FUL],[GAL],[GLA],[GLC],[GXL],[GUP],[LXC],[MAN],[RAM],[RIB],[RIP],[XYP],[XYS],[CBI],[CT3],[CTR],[CTT],[LAT],[MAB],[MAL],[MLR],[MTT],[SUC],[TRE],[GCU],[MTL],[NAG],[NDG],[RHA],[SOR],[SOL],[SOE],[XYL],[A2G],[LBT],[NGA],[SIA],[SLB],[AFL],[AGC],[GLB],[NAN],[RAA]");$t$=J.viewer.JC.group3Count=Clazz.doubleToInt(a.length()/
6);J.viewer.JC.prototype.group3Count=J.viewer.JC.group3Count;$t$;return $t$=J.viewer.JC.group3List=a.toString(),J.viewer.JC.prototype.group3List=J.viewer.JC.group3List,$t$});c$.isHetero=$_M(c$,"isHetero",function(a){return 42<=J.viewer.JC.getGroup3Pt(a)},"~S");c$.getGroup3Pt=$_M(c$,"getGroup3Pt",($fz=function(a){J.viewer.JC.getGroup3List();var b=(new JU.SB).append("[");b.append(a);switch(a.length){case 1:b.append("  ");break;case 2:b.append(" ")}a=J.viewer.JC.group3List.indexOf(b.toString());return 0>
a?2147483647:Clazz.doubleToInt(a/6)+1},$fz.isPrivate=!0,$fz),"~S");c$.getGroup3Count=$_M(c$,"getGroup3Count",function(){if(0<J.viewer.JC.group3Count)return J.viewer.JC.group3Count;J.viewer.JC.getGroup3List();return $t$=J.viewer.JC.group3Count=Clazz.doubleToInt(J.viewer.JC.group3List.length/6),J.viewer.JC.prototype.group3Count=J.viewer.JC.group3Count,$t$});c$.isShapeSecondary=$_M(c$,"isShapeSecondary",function(a){return 9<=a&&16>a},"~N");c$.shapeTokenIndex=$_M(c$,"shapeTokenIndex",function(a){switch(a){case 1141899265:case 1073741860:return 0;
case 1678770178:case 659488:return 1;case 1612189718:return 2;case 1611141176:return 3;case 1708058:return 4;case 1826248715:return 5;case 1746538509:case 537006096:return 6;case 1113200652:return 7;case 1113200646:return 8;case 1115297793:return 9;case 1113200654:return 10;case 1113200642:return 11;case 1650071565:return 12;case 1113200647:return 13;case 1113200649:return 14;case 1113200650:return 15;case 1113198595:return 16;case 135175:return 17;case 135198:return 18;case 1113198597:return 19;
case 1113198596:return 20;case 135192:return 21;case 135174:return 23;case 135176:return 22;case 135180:return 24;case 135402505:return 25;case 135182:return 26;case 1183762:return 27;case 135188:return 28;case 135190:return 29;case 537022465:return 30;case 1611272194:return 31;case 1679429641:return 32;case 1614417948:return 33;case 544771:return 34;case 1611272202:return 35}return-1},"~N");c$.getShapeClassName=$_M(c$,"getShapeClassName",function(a,b){return 0>a?J.viewer.JC.shapeClassBases[~a]:"J."+
(b?"render":"shape")+(9<=a&&16>a?"bio.":16<=a&&23>a?"special.":24<=a&&29>a?"surface.":23==a?"cgo.":".")+J.viewer.JC.shapeClassBases[a]},"~N,~B");c$.getShapeVisibilityFlag=$_M(c$,"getShapeVisibilityFlag",function(a){return 4<<a},"~N");c$.getOffset=$_M(c$,"getOffset",function(a,b){a=Math.min(Math.max(a,-127),127);b=Math.min(Math.max(b,-127),127);return(a&255)<<8|b&255},"~N,~N");c$.getXOffset=$_M(c$,"getXOffset",function(a){switch(a){case 0:return 4;case 32767:return 0;default:return a<<48>>56}},"~N");
c$.getYOffset=$_M(c$,"getYOffset",function(a){switch(a){case 0:return-4;case 32767:return 0;default:return-(a<<56>>56)}},"~N");c$.getAlignmentName=$_M(c$,"getAlignmentName",function(a){return J.viewer.JC.hAlignNames[a&3]},"~N");c$.getPointer=$_M(c$,"getPointer",function(a){return 0==(a&1)?"":0<(a&2)?"background":"on"},"~N");Clazz.defineStatics(c$,"copyright","(C) 2012 Jmol Development","version",null,"date",null);var a=null,b=null,a=___JmolVersion,b=___JmolDate;null!=b&&(b=b.substring(7,24));$t$=
J.viewer.JC.version=null!=a?a:"(Unknown version)";J.viewer.JC.prototype.version=J.viewer.JC.version;$t$;$t$=J.viewer.JC.date=null!=b?b:"(Unknown date)";J.viewer.JC.prototype.date=J.viewer.JC.date;$t$;Clazz.defineStatics(c$,"officialRelease",!1,"DEFAULT_HELP_PATH","http://chemapps.stolaf.edu/jmol/docs/index.htm","STATE_VERSION_STAMP","# Jmol state version ","EMBEDDED_SCRIPT_TAG","**** Jmol Embedded Script ****","NOTE_SCRIPT_FILE","NOTE: file recognized as a script file: ","SCRIPT_EDITOR_IGNORE","\u0001## EDITOR_IGNORE ##",
"REPAINT_IGNORE","\u0001## REPAINT_IGNORE ##","LOAD_ATOM_DATA_TYPES",";xyz;vxyz;vibration;temperature;occupancy;partialcharge;","radiansPerDegree",0.017453292519943295,"allowedQuaternionFrames","RC;RP;a;b;c;n;p;q;x;","EXPORT_DRIVER_LIST","Idtf;Maya;Povray;Vrml;X3d;Tachyon;Obj");c$.center=c$.prototype.center=JU.V3.new3(0,0,0);c$.axisX=c$.prototype.axisX=JU.V3.new3(1,0,0);c$.axisY=c$.prototype.axisY=JU.V3.new3(0,1,0);c$.axisZ=c$.prototype.axisZ=JU.V3.new3(0,0,1);c$.axisNX=c$.prototype.axisNX=JU.V3.new3(-1,
0,0);c$.axisNY=c$.prototype.axisNY=JU.V3.new3(0,-1,0);c$.axisNZ=c$.prototype.axisNZ=JU.V3.new3(0,0,-1);c$.unitAxisVectors=c$.prototype.unitAxisVectors=[J.viewer.JC.axisX,J.viewer.JC.axisY,J.viewer.JC.axisZ,J.viewer.JC.axisNX,J.viewer.JC.axisNY,J.viewer.JC.axisNZ];Clazz.defineStatics(c$,"XY_ZTOP",100,"DEFAULT_PERCENT_VDW_ATOM",23,"DEFAULT_BOND_RADIUS",0.15,"DEFAULT_BOND_MILLIANGSTROM_RADIUS",Clazz.floatToShort(150),"DEFAULT_STRUT_RADIUS",0.3,"DEFAULT_BOND_TOLERANCE",0.45,"DEFAULT_MIN_BOND_DISTANCE",
0.4,"DEFAULT_MAX_CONNECT_DISTANCE",1E8,"DEFAULT_MIN_CONNECT_DISTANCE",0.1,"MINIMIZATION_ATOM_MAX",200,"MINIMIZE_FIXED_RANGE",5,"ENC_CALC_MAX_DIST",3,"ENV_CALC_MAX_LEVEL",3,"LABEL_FRONT_FLAG",32,"LABEL_GROUP_FLAG",16,"LABEL_POINTER_FLAGS",3,"LABEL_ALIGN_FLAGS",12,"LABEL_ZPOS_FLAGS",48,"LABEL_SCALE_FLAG",64,"LABEL_EXACT_OFFSET_FLAG",128,"LABEL_FLAGS",255,"LABEL_FLAG_OFFSET",8,"MOUSE_NONE",-1,"MULTIBOND_NEVER",0,"MULTIBOND_WIREFRAME",1,"MULTIBOND_NOTSMALL",2,"MULTIBOND_ALWAYS",3,"MAXIMUM_AUTO_BOND_COUNT",
20,"madMultipleBondSmallMaximum",500,"ANGSTROMS_PER_BOHR",0.5291772,"altArgbsCpk",[4294907027,4290750118,4294967088,4283897743,4294967232,4294967200,4292401368,4283453520,4282400832,4279259216],"argbsAmino",[4290682990,4291348680,4279524095,4278246620,4293265930,4293322240,4278246620,4293265930,4293651435,4286743250,4279206415,4279206415,4279524095,4293322240,4281479850,4292646530,4294612480,4294612480,4290009780,4281479850,4279206415,4294928820,4294928820,4290682990],"argbShapelyBackbone",4290295992,
"argbShapelySpecial",4284350558,"argbShapelyDefault",4294902015,"argbsChainAtom",[4294967295,4290826495,4289789872,4294951112,4294967168,4294951167,4289786096,4294955120,4293951616,4294303411,4278239231,4291648604,4284927402,4288335154,4293821166,4278243025,4278255487,4282168177,4278190219,4290623339,4278215680,4286578688,4286611456,4286578816,4278222976,4290283019,4289864226],"argbsChainHetero",[4294967295,-7298865,-8335464,-3174224,-3158160,-3174193,-8339264,-3170208,-4173712,-3821949,-16734257,
-4895668,-11094638,-7686870,-4296002,-16730463,-16724113,-13329567,-16777029,-5922981,-16739328,-5242880,-5197824,-5242704,-16731984,-1526253,-4050382],"argbsFormalCharge",[4294901760,4294918208,4294934656,4294951104,4294967295,4292401407,4290032895,4287664383,4285295871,4282927359,4280558847,4278190335],"argbsRwbScale",[4294901760,4294905872,4294909984,4294914096,4294918208,4294922320,4294926432,4294930544,4294934656,4294938768,4294942880,4294946992,4294951104,4294955216,4294959328,4294967295,4292927743,
4291875071,4290822399,4289769727,4288717055,4287664383,4286611711,4285559039,4284506367,4283453695,4282401023,4281348351,4280295679,4279243007,4278190335]);c$.FORMAL_CHARGE_COLIX_RED=c$.prototype.FORMAL_CHARGE_COLIX_RED=J.util.Elements.elementSymbols.length;c$.PARTIAL_CHARGE_COLIX_RED=c$.prototype.PARTIAL_CHARGE_COLIX_RED=J.util.Elements.elementSymbols.length+J.viewer.JC.argbsFormalCharge.length;c$.PARTIAL_CHARGE_RANGE_SIZE=c$.prototype.PARTIAL_CHARGE_RANGE_SIZE=J.viewer.JC.argbsRwbScale.length;Clazz.defineStatics(c$,
"argbsRoygbScale",[4294901760,4294909952,4294918144,4294926336,4294934528,4294942720,4294950912,4294959104,4294963200,4294967040,4293980160,4292935424,4290838272,4288741120,4286643968,4284546816,4282449664,4280352512,4278255360,4278255392,4278255424,4278255456,4278255488,4278255520,4278255552,4278255584,4278255615,4278247679,4278239487,4278231295,4278223103,4278214911,4278206719,4278198527,4278190335],"argbsIsosurfacePositive",4283441312,"argbsIsosurfaceNegative",4288684112,"specialAtomNames",[null,
"N","CA","C","O","O1","O5'","C5'","C4'","C3'","O3'","C2'","C1'","P","OD1","OD2","OE1","OE2","SG",null,null,null,null,null,null,null,null,null,null,null,null,null,"N1","C2","N3","C4","C5","C6","O2","N7","C8","N9","N4","N2","N6","C5M","O6","O4","S4","C7","H1","H2","H3",null,null,null,null,null,null,null,null,null,null,null,"OXT","H","1H","2H","3H","HA","1HA","2HA","H5T","O5T","O1P","OP1","O2P","OP2","O4'","O2'","1H5'","2H5'","H4'","H3'","1H2'","2H2'","2HO'","H1'","H3T","HO3'","HO5'","HA2","HA3","HA2",
"H5'","H5''","H2'","H2''","HO2'","O3P","OP3"]);c$.ATOMID_MAX=c$.prototype.ATOMID_MAX=J.viewer.JC.specialAtomNames.length;Clazz.defineStatics(c$,"ATOMID_AMINO_NITROGEN",1,"ATOMID_ALPHA_CARBON",2,"ATOMID_CARBONYL_CARBON",3,"ATOMID_CARBONYL_OXYGEN",4,"ATOMID_O1",5,"ATOMID_ALPHA_ONLY_MASK",4,"ATOMID_PROTEIN_MASK",14,"ATOMID_O5_PRIME",6,"ATOMID_C4_PRIME",8,"ATOMID_C3_PRIME",9,"ATOMID_O3_PRIME",10,"ATOMID_C1_PRIME",12,"ATOMID_NUCLEIC_MASK",8128,"ATOMID_NUCLEIC_PHOSPHORUS",13,"ATOMID_PHOSPHORUS_ONLY_MASK",
8192,"ATOMID_DISTINGUISHING_ATOM_MAX",14,"ATOMID_CARBONYL_OD1",14,"ATOMID_CARBONYL_OD2",15,"ATOMID_CARBONYL_OE1",16,"ATOMID_CARBONYL_OE2",17,"ATOMID_SG",18,"ATOMID_N1",32,"ATOMID_C2",33,"ATOMID_N3",34,"ATOMID_C4",35,"ATOMID_C5",36,"ATOMID_C6",37,"ATOMID_O2",38,"ATOMID_N7",39,"ATOMID_C8",40,"ATOMID_N9",41,"ATOMID_N4",42,"ATOMID_N2",43,"ATOMID_N6",44,"ATOMID_C5M",45,"ATOMID_O6",46,"ATOMID_O4",47,"ATOMID_S4",48,"ATOMID_C7",49,"ATOMID_TERMINATING_OXT",64,"ATOMID_H5T_TERMINUS",72,"ATOMID_O5T_TERMINUS",
73,"ATOMID_O1P",74,"ATOMID_OP1",75,"ATOMID_O2P",76,"ATOMID_OP2",77,"ATOMID_O2_PRIME",79,"ATOMID_H3T_TERMINUS",88,"ATOMID_HO3_PRIME",89,"ATOMID_HO5_PRIME",90,"htSpecialAtoms",null,"GROUPID_ARGININE",2,"GROUPID_ASPARAGINE",3,"GROUPID_ASPARTATE",4,"GROUPID_CYSTEINE",5,"GROUPID_GLUTAMINE",6,"GROUPID_GLUTAMATE",7,"GROUPID_HISTIDINE",9,"GROUPID_LYSINE",12,"GROUPID_PROLINE",15,"GROUPID_TRYPTOPHAN",19,"GROUPID_AMINO_MAX",24,"GROUPID_NUCLEIC_MAX",42,"GROUPID_WATER",42,"GROUPID_SOLVENT_MIN",45,"GROUPID_ION_MIN",
46,"GROUPID_ION_MAX",48,"predefinedGroup3Names"," ALA ARG ASN ASP CYS GLN GLU GLY HIS ILE LEU LYS MET PHE PRO SER THR TRP TYR VAL ASX GLX UNK G C A T U I DG DC DA DT DU DI +G +C +A +T +U +I HOH DOD WAT UREA PO4 SO4 UNL".split(" "),"naNoH","A3;A1;C3;G3;I3","aaSp2","ARGN;ASNN;ASNO;ASPO;GLNN;GLNO;GLUO;HISN;HISC;PHECTRPC;TRPN;TYRC","aaPlus","LYSN","pdbBondInfo",";N N CA HA C O CB HB?;N N CA HA C O CB HB2@HB3 CG HG2@HG3 CD D NE HE CZ NH1 NH1 HH11@HH12 NH2 HH21@HH22;N N CA HA C O CB B CG OD1 ND2 HD21@HD22;N N CA HA C O CB B CG OD1;N N CA HA C O CB B SG HG;N N CA HA C O CB B CG G CD OE1 NE2 HE21@HE22;N N CA HA C O CB B CG G CD OE1;N N CA HA2@HA3 C O;N N CA HA C O CB B CG CD2 ND1 CE1 ND1 HD1 CD2 HD2 CE1 HE1 NE2 HE2;N N CA HA C O CB HB CG1 HG12@HG13 CG2 HG2? CD1 HD1?;N N CA HA C O CB HB2@HB3 CG HG CD1 HD1? CD2 HD2?;N N CA HA C O CB B CG G CD HD2@HD3 CE HE3@HE2 NZ HZ?;N N CA HA C O CB HB2@HB3 CG HG2@HG3 CE HE?;N N CA HA C O CB B CG CD1 CD1 HD1 CD2 CE2 CD2 HD2 CE1 CZ CE1 HE1 CE2 HE2 CZ HZ;N H CA HA C O CB B CG G CD HD2@HD3;N N CA HA C O CB B OG HG;N N CA HA C O CB HB OG1 HG1 CG2 HG2?;N N CA HA C O CB B CG CD1 CD1 HD1 CD2 CE2 NE1 HE1 CE3 CZ3 CE3 HE3 CZ2 CH2 CZ2 HZ2 CZ3 HZ3 CH2 HH2;N N CA HA C O CB B CG CD1 CD1 HD1 CD2 CE2 CD2 HD2 CE1 CZ CE1 HE1 CE2 HE2 OH HH;N N CA HA C O CB HB CG1 HG1? CG2 HG2?;CA HA C O CB HB2@HB1 C H;CA HA C O CB HB1 CB HB2 CG HG1 CG HG2;;P OP1 C5' 5 C4' H4' C3' H3' C2' H2' O2' HO2' C1' H1' C8 N7 C8 H8 C5 C4 C6 O6 N1 H1 C2 N3 N2 H21@H22 O3' HO3' O5' HO5';P OP1 C5' 5 C4' H4' C3' H3' C2' H2' O2' HO2' C1' H1' C2 O2 N3 C4 N4 H41@H42 C5 C6 C5 H5 C6 H6 O3' HO3' O5' HO5';P OP1 C5' 5 C4' H4' C3' H3' C2' H2' O2' HO2' C1' H1' C8 N7 C8 H8 C5 C4 C6 N1 N6 H61@H62 C2 N3 C2 H2 O3' HO3' O5' HO5';P OP1 C5' 5 C4' H4' C3' H3' C2' 2 C1' H1' C2 O2 N3 H3 C4 O4 C5 C6 C7 H7? C6 H6 O3' HO3' O5' HO5';P OP1 C5' 5 C4' H4' C3' H3' C2' H2' O2' HO2' C1' H1' C2 O2 N3 H3 C4 O4 C5 C6 C5 H5 C6 H6 O3' HO3' O5' HO5';P OP1 C5' 5 C4' H4' C3' H3' C2' H2' O2' HO2' C1' H1' C8 N7 C8 H8 C5 C4 C6 O6 N1 H1 C2 N3 C2 H2 O3' HO3' O5' HO5';P OP1 C5' 5 C4' H4' C3' H3' C2' 2 C1' H1' C8 N7 C8 H8 C5 C4 C6 O6 N1 H1 C2 N3 N2 H21@H22 O3' HO3' O5' HO5';P OP1 C5' 5 C4' H4' C3' H3' C2' 2 C1' H1' C2 O2 N3 C4 N4 H41@H42 C5 C6 C5 H5 C6 H6 O3' HO3' O5' HO5';P OP1 C5' 5 C4' H4' C3' H3' C2' 2 C1' H1' C8 N7 C8 H8 C5 C4 C6 N1 N6 H61@H62 C2 N3 C2 H2 O3' HO3' O5' HO5';P OP1 C5' H5'@H5'' C4' H4' C3' H3' C2' H2'@H2'' C1' H1' C2 O2 N3 H3 C4 O4 C5 C6 C7 H7? C6 H6 O3' HO3' O5' HO5';P OP1 C5' 5 C4' H4' C3' H3' C2' H2'@H2'' C1' H1' C2 O2 N3 H3 C4 O4 C5 C6 C5 H5 C6 H6 O3' HO3' O5' HO5';P OP1 C5' 5 C4' H4' C3' H3' C2' 2 C1' H1' C8 N7 C8 H8 C5 C4 C6 O6 N1 H1 C2 N3 C2 H2 O3' HO3' O5' HO5'".split(";"),
"pdbHydrogenCount",[0,6,16,7,6,6,9,8,4,9,12,12,14,10,10,8,6,8,11,10,10,3,5,0,13,13,13,-1,12,12,13,13,13,14,12,12],"argbsShapely",[4294902015,4278190204,4294933616,4287430540,4288675906,4294967152,4294921292,4284874752,4294967295,4285559039,4278209536,4282736197,4282861496,4283649106,4290289730,4283585106,4294930498,4290268160,4283385344,4287393868,4294937855,4294902015,4294902015,4294902015,4294930544,4294937675,4288717055,4288741280,4294934656,4286644223,4294930544,4294937675,4288717055,4288741280,
4294934656,4286644223,4294930544,4294937675,4288717055,4288741280,4294934656,4286644223],"allCarbohydrates",",[AHR],[ALL],[AMU],[ARA],[ARB],[BDF],[BDR],[BGC],[BMA],[FCA],[FCB],[FRU],[FUC],[FUL],[GAL],[GLA],[GLC],[GXL],[GUP],[LXC],[MAN],[RAM],[RIB],[RIP],[XYP],[XYS],[CBI],[CT3],[CTR],[CTT],[LAT],[MAB],[MAL],[MLR],[MTT],[SUC],[TRE],[GCU],[MTL],[NAG],[NDG],[RHA],[SOR],[SOL],[SOE],[XYL],[A2G],[LBT],[NGA],[SIA],[SLB],[AFL],[AGC],[GLB],[NAN],[RAA]","group3List",null,"group3Count",0,"predefinedGroup1Names",
"\x00ARNDCQEGHILKMFPSTWYVAG?GCATUIGCATUIGCATUII".split(""),"predefinedVariable","@_1H _H & !(_2H,_3H);@_12C _C & !(_13C,_14C);@_14N _N & !(_15N);@water _g>=42 & _g<45, oxygen & connected(2) & connected(2, hydrogen), (hydrogen) & connected(oxygen & connected(2) & connected(2, hydrogen));@solvent water, (_g>=45 & _g<48);@ligand _g=0|!(_g<46,protein,nucleic,water);@turn structure=1;@sheet structure=2;@helix structure=3;@helix310 substructure=7;@helixalpha substructure=8;@helixpi substructure=9;@bonded bondcount>0".split(";"),
"predefinedStatic","@amino _g>0 & _g<=23;@acidic asp,glu;@basic arg,his,lys;@charged acidic,basic;@negative acidic;@positive basic;@neutral amino&!(acidic,basic);@polar amino&!hydrophobic;@cyclic his,phe,pro,trp,tyr;@acyclic amino&!cyclic;@aliphatic ala,gly,ile,leu,val;@aromatic his,phe,trp,tyr;@cystine within(group, (cys.sg or cyx.sg) and connected(cys.sg or cyx.sg));@buried ala,cys,ile,leu,met,phe,trp,val;@surface amino&!buried;@hydrophobic ala,gly,ile,leu,met,phe,pro,trp,tyr,val;@mainchain backbone;@small ala,gly,ser;@medium asn,asp,cys,pro,thr,val;@large arg,glu,gln,his,ile,leu,lys,met,phe,trp,tyr;@c nucleic & ([C] or [DC] or within(group,_a=42));@g nucleic & ([G] or [DG] or within(group,_a=43));@cg c,g;@a nucleic & ([A] or [DA] or within(group,_a=44));@t nucleic & ([T] or [DT] or within(group,_a=45 | _a=49));@at a,t;@i nucleic & ([I] or [DI] or within(group,_a=46) & !g);@u nucleic & ([U] or [DU] or within(group,_a=47) & !t);@tu nucleic & within(group,_a=48);@ions _g>=46&_g<48;@alpha _a=2;@backbone protein&(_a>=1&_a<6|_a>=64&_a<72)|nucleic&(_a>=6&_a<14|_a>=72);@spine protein&_a>=1&_a<4|nucleic&_a>=6&_a<14&_a!=12;@sidechain (protein,nucleic) & !backbone;@base nucleic & !backbone;@dynamic_flatring search('[a]')".split(";"),
"databases","ligand http://www.rcsb.org/pdb/files/ligand/%FILE.cif mp http://www.materialsproject.org/materials/%FILE/cif nci http://cactus.nci.nih.gov/chemical/structure/%FILE nmr http://www.nmrdb.org/predictor?POST?molfile= nmrdb http://www.nmrdb.org/service/predictor?POST?molfile= pdb http://www.rcsb.org/pdb/files/%FILE.pdb.gz pubchem http://pubchem.ncbi.nlm.nih.gov/rest/pug/compound/%FILE/SDF?record_type=3d".split(" "),"MODELKIT_ZAP_STRING","5\n\nC 0 0 0\nH .63 .63 .63\nH -.63 -.63 .63\nH -.63 .63 -.63\nH .63 -.63 -.63",
"MODELKIT_ZAP_TITLE","Jmol Model Kit","ADD_HYDROGEN_TITLE","Viewer.AddHydrogens","DEFAULT_FONTFACE","SansSerif","DEFAULT_FONTSTYLE","Plain","LABEL_MINIMUM_FONTSIZE",6,"LABEL_MAXIMUM_FONTSIZE",63,"LABEL_DEFAULT_FONTSIZE",13,"LABEL_DEFAULT_X_OFFSET",4,"LABEL_DEFAULT_Y_OFFSET",4,"MEASURE_DEFAULT_FONTSIZE",15,"AXES_DEFAULT_FONTSIZE",14,"SHAPE_BALLS",0,"SHAPE_STICKS",1,"SHAPE_HSTICKS",2,"SHAPE_SSSTICKS",3,"SHAPE_STRUTS",4,"SHAPE_LABELS",5,"SHAPE_MEASURES",6,"SHAPE_STARS",7,"SHAPE_HALOS",8,"SHAPE_MIN_SECONDARY",
9,"SHAPE_BACKBONE",9,"SHAPE_TRACE",10,"SHAPE_CARTOON",11,"SHAPE_STRANDS",12,"SHAPE_MESHRIBBON",13,"SHAPE_RIBBONS",14,"SHAPE_ROCKETS",15,"SHAPE_MAX_SECONDARY",16,"SHAPE_MIN_SPECIAL",16,"SHAPE_DOTS",16,"SHAPE_DIPOLES",17,"SHAPE_VECTORS",18,"SHAPE_GEOSURFACE",19,"SHAPE_ELLIPSOIDS",20,"SHAPE_MAX_SIZE_ZERO_ON_RESTRICT",21,"SHAPE_POLYHEDRA",21,"SHAPE_MIN_HAS_ID",22,"SHAPE_MIN_MESH_COLLECTION",22,"SHAPE_DRAW",22,"SHAPE_MAX_SPECIAL",23,"SHAPE_CGO",23,"SHAPE_MIN_SURFACE",24,"SHAPE_ISOSURFACE",24,"SHAPE_CONTACT",
25,"SHAPE_LCAOCARTOON",26,"SHAPE_MO",27,"SHAPE_PMESH",28,"SHAPE_PLOT3D",29,"SHAPE_MAX_SURFACE",29,"SHAPE_MAX_MESH_COLLECTION",29,"SHAPE_ECHO",30,"SHAPE_MAX_HAS_ID",31,"SHAPE_AXES",31,"SHAPE_BBCAGE",32,"SHAPE_UCCAGE",33,"SHAPE_HOVER",34,"SHAPE_FRANK",35,"SHAPE_MAX",36,"shapeClassBases","Balls Sticks Hsticks Sssticks Struts Labels Measures Stars Halos Backbone Trace Cartoon Strands MeshRibbon Ribbons Rockets Dots Dipoles Vectors GeoSurface Ellipsoids Polyhedra Draw CGO Isosurface Contact LcaoCartoon MolecularOrbital Pmesh Plot3D Echo Axes Bbcage Uccage Hover Frank".split(" "),
"ATOM_IN_FRAME",1,"ATOM_SLABBED",2,"binaryExtensions",";pse=PyMOL;","SCRIPT_COMPLETED","Script completed","JPEG_EXTENSIONS",";jpg;jpeg;jpg64;jpeg64;");c$.IMAGE_TYPES=c$.prototype.IMAGE_TYPES=";jpg;jpeg;jpg64;jpeg64;gif;ppm;png;pngj;pngt;";c$.IMAGE_OR_SCENE=c$.prototype.IMAGE_OR_SCENE=";jpg;jpeg;jpg64;jpeg64;gif;ppm;png;pngj;pngt;scene;";if(12!=J.viewer.JC.argbsFormalCharge.length)throw J.util.Logger.error("formal charge color table length"),new NullPointerException;if(36!=J.viewer.JC.shapeClassBases.length)throw J.util.Logger.error("shapeClassBases wrong length"),
new NullPointerException;if(24!=J.viewer.JC.argbsAmino.length)throw J.util.Logger.error("argbsAmino wrong length"),new NullPointerException;if(42!=J.viewer.JC.argbsShapely.length)throw J.util.Logger.error("argbsShapely wrong length"),new NullPointerException;if(J.viewer.JC.argbsChainHetero.length!=J.viewer.JC.argbsChainAtom.length)throw J.util.Logger.error("argbsChainHetero wrong length"),new NullPointerException;if(36!=J.viewer.JC.shapeClassBases.length)throw J.util.Logger.error("the shapeClassBases array has the wrong length"),
new NullPointerException;Clazz.defineStatics(c$,"hAlignNames",["","left","center","right",""],"vAlignNames",["xy","top","bottom","middle"],"POINTER_NONE",0,"POINTER_ON",1,"POINTER_BACKGROUND",2,"VALIGN_XY",0,"VALIGN_TOP",1,"VALIGN_BOTTOM",2,"VALIGN_MIDDLE",3,"VALIGN_XYZ",4,"ALIGN_NONE",0,"ALIGN_LEFT",1,"ALIGN_CENTER",2,"ALIGN_RIGHT",3)}),Clazz.declarePackage("J.util"),c$=Clazz.decorateAsClass(function(){this.entryCount=0;this.entries=null;Clazz.instantialize(this,arguments)},J.util,"Int2IntHash"),
Clazz.makeConstructor(c$,function(a){this.entries=Array(a)},"~N"),$_M(c$,"get",function(a){for(var b=this.entries,b=b[(a&2147483647)%b.length];null!=b;b=b.next)if(b.key==a)return b.value;return-2147483648},"~N"),$_M(c$,"put",function(a,b){for(var c=this.entries,d=(a&2147483647)%c.length,d=c[d];null!=d;d=d.next)if(d.key==a){d.value=b;return}this.entryCount>c.length&&this.rehash();c=this.entries;d=(a&2147483647)%c.length;c[d]=new J.util.Int2IntHash.Entry(a,b,c[d]);++this.entryCount},"~N,~N"),$_M(c$,
"rehash",($fz=function(){for(var a=this.entries,b=a.length,c=2*b+1,d=Array(c);0<=--b;)for(var e=a[b];null!=e;){var f=e,e=e.next,g=(f.key&2147483647)%c;f.next=d[g];d[g]=f}this.entries=d},$fz.isPrivate=!0,$fz)),Clazz.pu$h(),c$=Clazz.decorateAsClass(function(){this.value=this.key=0;this.next=null;Clazz.instantialize(this,arguments)},J.util.Int2IntHash,"Entry"),Clazz.makeConstructor(c$,function(a,b,c){this.key=a;this.value=b;this.next=c},"~N,~N,J.util.Int2IntHash.Entry"),c$=Clazz.p0p(),Clazz.declarePackage("J.util"),
Clazz.load(["J.util.Int2IntHash"],"J.util.C","java.lang.Float JU.ArrayUtil $.ParserJS $.SB J.constant.EnumPalette J.util.ColorUtil $.Escape $.Logger".split(" "),function(){c$=Clazz.declareType(J.util,"C");Clazz.makeConstructor(c$,function(){});c$.getColix=$_M(c$,"getColix",function(a){if(0==a)return 0;var c=0;-16777216!=(a&4278190080)&&(c=J.util.C.getTranslucentFlag(a>>24&255),a|=4278190080);var d=J.util.C.colixHash.get(a);3==(d&3)&&(c=0);return(0<d?d:J.util.C.allocateColix(a))|c},"~N");c$.allocateColix=
$_M(c$,"allocateColix",function(a){for(var c=J.util.C.colixMax;4<=--c;)if((a&16777215)==(J.util.C.argbs[c]&16777215))return c;J.util.C.colixMax==J.util.C.argbs.length&&(c=2*J.util.C.colixMax,2048<c&&(c=2048),$t$=J.util.C.argbs=JU.ArrayUtil.arrayCopyI(J.util.C.argbs,c),J.util.C.prototype.argbs=J.util.C.argbs,$t$,null!=J.util.C.argbsGreyscale&&($t$=J.util.C.argbsGreyscale=JU.ArrayUtil.arrayCopyI(J.util.C.argbsGreyscale,c),J.util.C.prototype.argbsGreyscale=J.util.C.argbsGreyscale,$t$));J.util.C.argbs[J.util.C.colixMax]=
a;null!=J.util.C.argbsGreyscale&&(J.util.C.argbsGreyscale[J.util.C.colixMax]=J.util.ColorUtil.calcGreyscaleRgbFromRgb(a));J.util.C.colixHash.put(a,J.util.C.colixMax);return 2047>J.util.C.colixMax?($t$=J.util.C.colixMax++,J.util.C.prototype.colixMax=J.util.C.colixMax,$t$):J.util.C.colixMax},"~N");c$.setLastGrey=$_M(c$,"setLastGrey",function(a){J.util.C.calcArgbsGreyscale();J.util.C.argbsGreyscale[2047]=J.util.ColorUtil.calcGreyscaleRgbFromRgb(a)},"~N");c$.calcArgbsGreyscale=$_M(c$,"calcArgbsGreyscale",
function(){if(null==J.util.C.argbsGreyscale){for(var a=Clazz.newIntArray(J.util.C.argbs.length,0),c=J.util.C.argbs.length;4<=--c;)a[c]=J.util.ColorUtil.calcGreyscaleRgbFromRgb(J.util.C.argbs[c]);$t$=J.util.C.argbsGreyscale=a;J.util.C.prototype.argbsGreyscale=J.util.C.argbsGreyscale;$t$}});c$.getArgbGreyscale=$_M(c$,"getArgbGreyscale",function(a){null==J.util.C.argbsGreyscale&&J.util.C.calcArgbsGreyscale();return J.util.C.argbsGreyscale[a&-30721]},"~N");c$.getColixO=$_M(c$,"getColixO",function(a){if(null==
a)return 0;if(Clazz.instanceOf(a,J.constant.EnumPalette))return a===J.constant.EnumPalette.NONE?0:2;if(Clazz.instanceOf(a,Integer))return J.util.C.getColix(a.intValue());if(Clazz.instanceOf(a,String))return J.util.C.getColixS(a);if(Clazz.instanceOf(a,Byte))return 0==a.byteValue()?0:2;J.util.Logger.debugging&&J.util.Logger.debug("?? getColix("+a+")");return 22},"~O");c$.getTranslucentFlag=$_M(c$,"getTranslucentFlag",($fz=function(a){return 0==a?0:0>a?30720:Float.isNaN(a)||255<=a||1==a?16384:(Clazz.doubleToInt(Math.floor(1>
a?256*a:9>=a?Clazz.doubleToInt(Math.floor(a-1))<<5:15>a?256:a))>>5&15)<<11},$fz.isPrivate=!0,$fz),"~N");c$.isColixLastAvailable=$_M(c$,"isColixLastAvailable",function(a){return 0<a&&2047==(a&2047)},"~N");c$.getArgb=$_M(c$,"getArgb",function(a){return J.util.C.argbs[a&-30721]},"~N");c$.isColixColorInherited=$_M(c$,"isColixColorInherited",function(a){switch(a){case 0:case 1:return!0;default:return 1==(a&-30721)}},"~N");c$.getColixInherited=$_M(c$,"getColixInherited",function(a,c){switch(a){case 0:return c;
case 1:return c&-30721;default:return 1==(a&-30721)?c&-30721|a&30720:a}},"~N,~N");c$.isColixTranslucent=$_M(c$,"isColixTranslucent",function(a){return 0!=(a&30720)},"~N");c$.getChangeableColixIndex=$_M(c$,"getChangeableColixIndex",function(a){return 0<=a?-1:a&2047},"~N");c$.getColixTranslucent3=$_M(c$,"getColixTranslucent3",function(a,c,d){a&=-30721;0==a&&(a=1);return c?a|J.util.C.getTranslucentFlag(d):a},"~N,~B,~N");c$.copyColixTranslucency=$_M(c$,"copyColixTranslucency",function(a,c){return J.util.C.getColixTranslucent3(c,
J.util.C.isColixTranslucent(a),J.util.C.getColixTranslucencyLevel(a))},"~N,~N");c$.getColixTranslucencyFractional=$_M(c$,"getColixTranslucencyFractional",function(a){a=J.util.C.getColixTranslucencyLevel(a);return-1==a?0.5:0==a?0:255==a?1:a/256},"~N");c$.getColixTranslucencyLevel=$_M(c$,"getColixTranslucencyLevel",function(a){a=a>>11&15;switch(a){case 0:return 0;case 1:case 2:case 3:case 4:case 5:case 6:case 7:return a<<5;case 15:return-1;default:return 255}},"~N");c$.getColixS=$_M(c$,"getColixS",
function(a){var c=J.util.ColorUtil.getArgbFromString(a);return 0!=c?J.util.C.getColix(c):"none".equalsIgnoreCase(a)?0:"opaque".equalsIgnoreCase(a)?1:2},"~S");c$.getColixArray=$_M(c$,"getColixArray",function(a){if(null==a||0==a.length)return null;a=JU.ParserJS.getTokens(a);for(var c=Clazz.newShortArray(a.length,0),d=0;d<a.length;d++)if(c[d]=J.util.C.getColix(J.util.ColorUtil.getArgbFromString(a[d])),0==c[d])return null;return c},"~S");c$.getHexCode=$_M(c$,"getHexCode",function(a){return J.util.Escape.escapeColor(J.util.C.getArgb(a))},
"~N");c$.getHexCodes=$_M(c$,"getHexCodes",function(a){if(null==a)return null;for(var c=new JU.SB,d=0;d<a.length;d++)c.append(0==d?"":" ").append(J.util.C.getHexCode(a[d]));return c.toString()},"~A");c$.getColixTranslucent=$_M(c$,"getColixTranslucent",function(a){var c=a>>24&255;return 255==c?J.util.C.getColix(a):J.util.C.getColixTranslucent3(J.util.C.getColix(a),!0,c/255)},"~N");Clazz.defineStatics(c$,"INHERIT_ALL",0,"INHERIT_COLOR",1,"USE_PALETTE",2,"RAW_RGB",3,"SPECIAL_COLIX_MAX",4,"colixMax",4,
"argbs",Clazz.newIntArray(128,0),"argbsGreyscale",null);c$.colixHash=c$.prototype.colixHash=new J.util.Int2IntHash(256);Clazz.defineStatics(c$,"RAW_RGB_INT",3,"UNMASK_CHANGEABLE_TRANSLUCENT",2047,"CHANGEABLE_MASK",32768,"LAST_AVAILABLE_COLIX",2047,"TRANSLUCENT_SHIFT",11,"ALPHA_SHIFT",13,"TRANSLUCENT_MASK",30720,"TRANSLUCENT_SCREENED",30720,"TRANSPARENT",16384,"OPAQUE_MASK",-30721,"BLACK",4,"ORANGE",5,"PINK",6,"BLUE",7,"WHITE",8,"CYAN",9,"RED",10,"GREEN",11,"GRAY",12,"SILVER",13,"LIME",14,"MAROON",
15,"NAVY",16,"OLIVE",17,"PURPLE",18,"TEAL",19,"MAGENTA",20,"YELLOW",21,"HOTPINK",22,"GOLD",23,"predefinedArgbs",[4278190080,4294944E3,4294951115,4278190335,4294967295,4278255615,4294901760,4278222848,4286611584,4290822336,4278255360,4286578688,4278190208,4286611456,4286578816,4278222976,4294902015,4294967040,4294928820,4294956800]);for(var a=0;a<J.util.C.predefinedArgbs.length;++a)J.util.C.getColix(J.util.C.predefinedArgbs[a])}),Clazz.declarePackage("J.util"),Clazz.load(["JU.P4"],"J.util.Quaternion",
"java.lang.Float JU.A4 $.M3 $.P3 $.V3 J.util.Escape $.Logger $.Txt".split(" "),function(){c$=Clazz.decorateAsClass(function(){this.q3=this.q2=this.q1=this.q0=0;this.mat=null;Clazz.instantialize(this,arguments)},J.util,"Quaternion");Clazz.makeConstructor(c$,function(){this.q0=1});c$.newQ=$_M(c$,"newQ",function(a){var b=new J.util.Quaternion;b.set(a);return b},"J.util.Quaternion");c$.newVA=$_M(c$,"newVA",function(a,b){var c=new J.util.Quaternion;c.setTA(a,b);return c},"JU.T3,~N");c$.newM=$_M(c$,"newM",
function(a){var b=new J.util.Quaternion;b.setM(a);return b},"JU.M3");c$.newAA=$_M(c$,"newAA",function(a){var b=new J.util.Quaternion;b.setAA(a);return b},"JU.A4");c$.newP4=$_M(c$,"newP4",function(a){var b=new J.util.Quaternion;b.setP4(a);return b},"JU.P4");c$.new4=$_M(c$,"new4",function(a,b,c,d){var e=new J.util.Quaternion;if(-1>a)return e.q0=-1,e;if(1<a)return e.q0=1,e;e.q0=a;e.q1=b;e.q2=c;e.q3=d;return e},"~N,~N,~N,~N");$_M(c$,"set",function(a){this.q0=a.q0;this.q1=a.q1;this.q2=a.q2;this.q3=a.q3},
"J.util.Quaternion");$_M(c$,"setP4",($fz=function(a){var b=null==a?0:a.distance(J.util.Quaternion.qZero);0==b?this.q0=1:(this.q0=a.w/b,this.q1=a.x/b,this.q2=a.y/b,this.q3=a.z/b)},$fz.isPrivate=!0,$fz),"JU.P4");$_M(c$,"setTA",function(a,b){if(0==a.x&&0==a.y&&0==a.z)this.q0=1;else{var c=Math.sin(0.017453292519943295*(b/2))/Math.sqrt(a.x*a.x+a.y*a.y+a.z*a.z);this.q0=Math.cos(0.017453292519943295*(b/2));this.q1=a.x*c;this.q2=a.y*c;this.q3=a.z*c}},"JU.T3,~N");$_M(c$,"setAA",function(a){a=JU.A4.newAA(a);
0==a.angle&&(a.y=1);var b=new JU.M3;b.setAA(a);this.setM(b)},"JU.A4");$_M(c$,"setM",function(a){this.mat=a;var b=a.m00+a.m11+a.m22,c,d,e;0.5<=b?(b=Math.sqrt(1+b),c=(a.m21-a.m12)/b,d=(a.m02-a.m20)/b,e=(a.m10-a.m01)/b):0.5<=(c=a.m00+a.m00-b)?(c=Math.sqrt(1+c),b=(a.m21-a.m12)/c,d=(a.m10+a.m01)/c,e=(a.m20+a.m02)/c):0.5<=(c=a.m11+a.m11-b)||a.m11>a.m22?(d=Math.sqrt(1+c),b=(a.m02-a.m20)/d,c=(a.m10+a.m01)/d,e=(a.m21+a.m12)/d):(e=Math.sqrt(1+a.m22+a.m22-b),b=(a.m10-a.m01)/e,c=(a.m20+a.m02)/e,d=(a.m21+a.m12)/
e);this.q0=0.5*b;this.q1=0.5*c;this.q2=0.5*d;this.q3=0.5*e},"JU.M3");$_M(c$,"setRef",function(a){null==a?this.mul(this.getFixFactor()):0<=this.dot(a)||(this.q0*=-1,this.q1*=-1,this.q2*=-1,this.q3*=-1)},"J.util.Quaternion");c$.getQuaternionFrame=$_M(c$,"getQuaternionFrame",function(a,b,c){b=JU.V3.newV(b);c=JU.V3.newV(c);null!=a&&(b.sub(a),c.sub(a));return J.util.Quaternion.getQuaternionFrameV(b,c,null,!1)},"JU.P3,JU.T3,JU.T3");c$.getQuaternionFrameV=$_M(c$,"getQuaternionFrameV",function(a,b,c,d){null==
c&&(c=new JU.V3,c.cross(a,b),d&&a.cross(b,c));b=new JU.V3;b.cross(c,a);a.normalize();b.normalize();c.normalize();d=new JU.M3;d.setColumnV(0,a);d.setColumnV(1,b);d.setColumnV(2,c);return J.util.Quaternion.newM(d)},"JU.V3,JU.V3,JU.V3,~B");$_M(c$,"getMatrix",function(){null==this.mat&&this.setMatrix();return this.mat});$_M(c$,"setMatrix",($fz=function(){this.mat=new JU.M3;this.mat.m00=this.q0*this.q0+this.q1*this.q1-this.q2*this.q2-this.q3*this.q3;this.mat.m01=2*this.q1*this.q2-2*this.q0*this.q3;this.mat.m02=
2*this.q1*this.q3+2*this.q0*this.q2;this.mat.m10=2*this.q1*this.q2+2*this.q0*this.q3;this.mat.m11=this.q0*this.q0-this.q1*this.q1+this.q2*this.q2-this.q3*this.q3;this.mat.m12=2*this.q2*this.q3-2*this.q0*this.q1;this.mat.m20=2*this.q1*this.q3-2*this.q0*this.q2;this.mat.m21=2*this.q2*this.q3+2*this.q0*this.q1;this.mat.m22=this.q0*this.q0-this.q1*this.q1-this.q2*this.q2+this.q3*this.q3},$fz.isPrivate=!0,$fz));$_M(c$,"add",function(a){return J.util.Quaternion.newVA(this.getNormal(),this.getTheta()+a)},
"~N");$_M(c$,"mul",function(a){return 1==a?J.util.Quaternion.new4(this.q0,this.q1,this.q2,this.q3):J.util.Quaternion.newVA(this.getNormal(),this.getTheta()*a)},"~N");$_M(c$,"mulQ",function(a){return J.util.Quaternion.new4(this.q0*a.q0-this.q1*a.q1-this.q2*a.q2-this.q3*a.q3,this.q0*a.q1+this.q1*a.q0+this.q2*a.q3-this.q3*a.q2,this.q0*a.q2+this.q2*a.q0+this.q3*a.q1-this.q1*a.q3,this.q0*a.q3+this.q3*a.q0+this.q1*a.q2-this.q2*a.q1)},"J.util.Quaternion");$_M(c$,"div",function(a){return this.mulQ(a.inv())},
"J.util.Quaternion");$_M(c$,"divLeft",function(a){return this.inv().mulQ(a)},"J.util.Quaternion");$_M(c$,"dot",function(a){return this.q0*a.q0+this.q1*a.q1+this.q2*a.q2+this.q3*a.q3},"J.util.Quaternion");$_M(c$,"inv",function(){return J.util.Quaternion.new4(this.q0,-this.q1,-this.q2,-this.q3)});$_M(c$,"negate",function(){return J.util.Quaternion.new4(-this.q0,-this.q1,-this.q2,-this.q3)});$_M(c$,"getFixFactor",($fz=function(){return 0>this.q0||0==this.q0&&(0>this.q1||0==this.q1&&(0>this.q2||0==this.q2&&
0>this.q3))?-1:1},$fz.isPrivate=!0,$fz));$_M(c$,"getVector",function(a){return this.getVectorS(a,1)},"~N");$_M(c$,"getVectorS",($fz=function(a,b){if(-1==a)return b*=this.getFixFactor(),JU.V3.new3(this.q1*b,this.q2*b,this.q3*b);null==this.mat&&this.setMatrix();var c=new JU.V3;this.mat.getColumnV(a,c);1!=b&&c.scale(b);return c},$fz.isPrivate=!0,$fz),"~N,~N");$_M(c$,"getNormal",function(){var a=J.util.Quaternion.getRawNormal(this);a.scale(this.getFixFactor());return a});c$.getRawNormal=$_M(c$,"getRawNormal",
($fz=function(a){a=JU.V3.new3(a.q1,a.q2,a.q3);if(0==a.length())return JU.V3.new3(0,0,1);a.normalize();return a},$fz.isPrivate=!0,$fz),"J.util.Quaternion");$_M(c$,"getTheta",function(){return 360*Math.acos(Math.abs(this.q0))/3.141592653589793});$_M(c$,"getThetaRadians",function(){return 2*Math.acos(Math.abs(this.q0))});$_M(c$,"getNormalDirected",function(a){var b=this.getNormal();0>b.x*a.x+b.y*a.y+b.z*a.z&&b.scale(-1);return b},"JU.V3");$_M(c$,"get3dProjection",function(a){a.set(this.q1,this.q2,this.q3);
return a},"JU.V3");$_M(c$,"getThetaDirected",function(a){var b=this.getTheta(),c=this.getNormal();0>a.x*this.q1+a.y*this.q2+a.z*this.q3&&(c.scale(-1),b=-b);a.set(c.x,c.y,c.z,b);return a},"JU.P4");$_M(c$,"getThetaDirectedV",function(a){var b=this.getTheta(),c=this.getNormal();0>a.x*this.q1+a.y*this.q2+a.z*this.q3&&(c.scale(-1),b=-b);return b},"JU.V3");$_M(c$,"toPoint4f",function(){return JU.P4.new4(this.q1,this.q2,this.q3,this.q0)});$_M(c$,"toAxisAngle4f",function(){var a=2*Math.acos(Math.abs(this.q0)),
b=Math.sin(a/2),c=this.getNormal();0>b&&(c.scale(-1),a=3.141592653589793-a);return JU.A4.newVA(c,a)});$_M(c$,"transformPt",function(a){null==this.mat&&this.setMatrix();a=JU.P3.newP(a);this.mat.transform(a);return a},"JU.P3");$_M(c$,"transformP2",function(a,b){null==this.mat&&this.setMatrix();this.mat.transform2(a,b);return b},"JU.T3,JU.T3");$_M(c$,"transform",function(a){null==this.mat&&this.setMatrix();a=JU.V3.newV(a);this.mat.transform(a);return a},"JU.V3");$_M(c$,"leftDifference",function(a){a=
0>this.dot(a)?a.negate():a;return this.inv().mulQ(a)},"J.util.Quaternion");$_M(c$,"rightDifference",function(a){a=0>this.dot(a)?a.negate():a;return this.mulQ(a.inv())},"J.util.Quaternion");$_M(c$,"getInfo",function(){var a=this.toAxisAngle4f();return J.util.Txt.sprintf("%10.6f%10.6f%10.6f%10.6f  %6.2f  %10.5f %10.5f %10.5f","F",[[this.q0,this.q1,this.q2,this.q3,180*a.angle/3.141592653589793,a.x,a.y,a.z]])});$_M(c$,"draw",function(a,b,c,d){c=" VECTOR "+J.util.Escape.eP(c)+" ";0==d&&(d=1);return"draw "+
a+"x"+b+c+J.util.Escape.eP(this.getVectorS(0,d))+" color red\ndraw "+a+"y"+b+c+J.util.Escape.eP(this.getVectorS(1,d))+" color green\ndraw "+a+"z"+b+c+J.util.Escape.eP(this.getVectorS(2,d))+" color blue\n"},"~S,~S,JU.P3,~N");Clazz.overrideMethod(c$,"toString",function(){return"{"+this.q1+" "+this.q2+" "+this.q3+" "+this.q0+"}"});c$.div=$_M(c$,"div",function(a,b,c,d){var e;if(null==a||null==b||0==(e=Math.min(a.length,b.length)))return null;0<c&&e>c&&(e=c);c=Array(e);for(var f=0;f<e;f++){if(null==a[f]||
null==b[f])return null;c[f]=d?a[f].divLeft(b[f]):a[f].div(b[f])}return c},"~A,~A,~N,~B");c$.sphereMean=$_M(c$,"sphereMean",function(a,b,c){if(null==a||0==a.length)return new J.util.Quaternion;null==b&&(b=Clazz.newFloatArray(1,0));if(1==a.length)return b[0]=0,J.util.Quaternion.newQ(a[0]);for(var d=3.4028235E38,e=3.4028235E38,f=J.util.Quaternion.simpleAverage(a),g=0;d>c&&0!=e&&100>g;)f=J.util.Quaternion.newMean(a,f),b[0]=J.util.Quaternion.stdDev(a,f),d=Math.abs(b[0]-e),e=b[0],J.util.Logger.info(++g+
" sphereMean "+f+" stddev="+e+" diff="+d);return f},"~A,~A,~N");c$.simpleAverage=$_M(c$,"simpleAverage",($fz=function(a){var b=JU.V3.new3(0,0,1),c=a[0].getNormal();b.add(c);for(var d=a.length;0<=--d;)b.add(a[d].getNormalDirected(b));b.sub(c);b.normalize();for(var e=0,d=a.length;0<=--d;)e+=Math.abs(a[d].get3dProjection(c).dot(b));0!=e&&b.scale(e/a.length);e=Math.sqrt(1-b.lengthSquared());Float.isNaN(e)&&(e=0);return J.util.Quaternion.newP4(JU.P4.new4(b.x,b.y,b.z,e))},$fz.isPrivate=!0,$fz),"~A");c$.newMean=
$_M(c$,"newMean",($fz=function(a,b){for(var c=new JU.V3,d,e,f=a.length;0<=--f;)d=a[f],e=d.div(b),d=e.getNormal(),d.scale(e.getTheta()),c.add(d);c.scale(1/a.length);return J.util.Quaternion.newVA(c,c.length()).mulQ(b)},$fz.isPrivate=!0,$fz),"~A,J.util.Quaternion");c$.stdDev=$_M(c$,"stdDev",($fz=function(a,b){for(var c=0,d=0,e=a.length,f=e;0<=--f;)var g=a[f].div(b).getTheta(),c=c+g,d=d+g*g;d-=c*c/e;0>d&&(d=0);return Math.sqrt(d/(e-1))},$fz.isPrivate=!0,$fz),"~A,J.util.Quaternion");$_M(c$,"getEulerZYZ",
function(){var a,b,c;a=Math.atan2(2*(this.q2*this.q3-this.q0*this.q1),2*(this.q1*this.q3+this.q0*this.q2));b=Math.acos(this.q3*this.q3-this.q2*this.q2-this.q1*this.q1+this.q0*this.q0);c=Math.atan2(2*(this.q2*this.q3+this.q0*this.q1),2*(this.q0*this.q2-this.q1*this.q3));return[a/0.017453292519943295,b/0.017453292519943295,c/0.017453292519943295]});$_M(c$,"getEulerZXZ",function(){var a,b,c;a=Math.atan2(2*(this.q1*this.q3+this.q0*this.q2),2*(this.q0*this.q1-this.q2*this.q3));b=Math.acos(this.q3*this.q3-
this.q2*this.q2-this.q1*this.q1+this.q0*this.q0);c=Math.atan2(2*(this.q1*this.q3-this.q0*this.q2),2*(this.q2*this.q3+this.q0*this.q1));return[a/0.017453292519943295,b/0.017453292519943295,c/0.017453292519943295]});c$.qZero=c$.prototype.qZero=new JU.P4;Clazz.defineStatics(c$,"RAD_PER_DEG",0.017453292519943295)}),Clazz.declarePackage("J.constant"),Clazz.load(["java.lang.Enum"],"J.constant.EnumPalette",null,function(){c$=Clazz.decorateAsClass(function(){this.$$name=null;this.id=0;Clazz.instantialize(this,
arguments)},J.constant,"EnumPalette",Enum);Clazz.makeConstructor(c$,($fz=function(a,b){this.$$name=a;this.id=b},$fz.isPrivate=!0,$fz),"~S,~N");c$.pidOf=$_M(c$,"pidOf",function(a){return Clazz.instanceOf(a,J.constant.EnumPalette)?a.id:Clazz.instanceOf(a,Byte)?a.byteValue():J.constant.EnumPalette.UNKNOWN.id},"~O");c$.isPaletteVariable=$_M(c$,"isPaletteVariable",function(a){return 0!=(a&64)},"~N");c$.getPalette=$_M(c$,"getPalette",function(a){if(0>a.indexOf("_"))for(var b,c=0,d=J.constant.EnumPalette.values();c<
d.length&&((b=d[c])||1);c++)if(a.equalsIgnoreCase(b.$$name))return b;return 0==a.indexOf("property_")?J.constant.EnumPalette.PROPERTY:J.constant.EnumPalette.UNKNOWN},"~S");c$.getPaletteID=$_M(c$,"getPaletteID",function(a){if(0>a.indexOf("_"))for(var b,c=0,d=J.constant.EnumPalette.values();c<d.length&&((b=d[c])||1);c++)if(a.equalsIgnoreCase(b.$$name))return b.id;return 0==a.indexOf("property_")?J.constant.EnumPalette.PROPERTY.id:J.constant.EnumPalette.UNKNOWN.id},"~S");c$.getPaletteName=$_M(c$,"getPaletteName",
function(a){for(var b,c=0,d=J.constant.EnumPalette.values();c<d.length&&((b=d[c])||1);c++)if(b.id==a)return b.$$name;return null},"~N");c$.argbsCpkRasmol=[16716947,33554431,50315467,62005794,83951360,113821896,126849023,149946368,165324064,184549631,203590434,226525328,249210144,268412160,285198386,285277952,343965840,377520272,411074704,427851920,452961536,480586282,497363498,514140714,598026794,796950672,899686640,956278016,1339729184];c$.argbsCpk=[4294907027,4294967295,4292476927,4291592447,4290969344,
4294948277,4287664272,4281356536,4294905101,4287684688,4289979381,4289420530,4287299328,4290750118,4293970080,4294934528,4294967088,4280283167,4286632419,4287578324,4282253056,4293322470,4290757319,4289111723,4287273415,4288445127,4292896307,4293955744,4283486288,4291330099,4286415024,4290940815,4284911503,4290609379,4294942976,4289079593,4284266705,4285542064,4278255360,4287954943,4287946976,4285776585,4283741621,4282097310,4280586127,4278877580,4278217093,4290822336,4294957455,4289099123,4284907648,
4288570293,4292114944,4287889556,4282556080,4283897743,4278241536,4285584639,4294967239,4292476871,4291297223,4288937927,4287627207,4284612551,4282777543,4281401287,4280287175,4278255516,4278249077,4278244434,4278239032,4278233892,4283286271,4283279103,4280390870,4280712619,4280706710,4279719047,4291875040,4294955299,4290296016,4289090637,4283914593,4288565173,4289420288,4285878085,4282548886,4282515558,4278222080,4285574138,4278237951,4278231551,4278226943,4278223103,4278217727,4283718898,4286078179,
4287254499,4288755412,4289929172,4289929146,4289924518,4290579847,4291231846,4291559513,4291887183,4292411461,4292870200,4293263406,4293591078];Clazz.defineEnumConstant(c$,"UNKNOWN",0,[null,255]);Clazz.defineEnumConstant(c$,"NONE",1,["none",0]);Clazz.defineEnumConstant(c$,"CPK",2,["cpk",1]);Clazz.defineEnumConstant(c$,"PARTIAL_CHARGE",3,["partialcharge",2]);Clazz.defineEnumConstant(c$,"FORMAL_CHARGE",4,["formalcharge",3]);Clazz.defineEnumConstant(c$,"TEMP",5,["temperature",68]);Clazz.defineEnumConstant(c$,
"FIXEDTEMP",6,["fixedtemperature",5]);Clazz.defineEnumConstant(c$,"SURFACE",7,["surfacedistance",70]);Clazz.defineEnumConstant(c$,"STRUCTURE",8,["structure",7]);Clazz.defineEnumConstant(c$,"AMINO",9,["amino",8]);Clazz.defineEnumConstant(c$,"SHAPELY",10,["shapely",9]);Clazz.defineEnumConstant(c$,"CHAIN",11,["chain",10]);Clazz.defineEnumConstant(c$,"GROUP",12,["group",75]);Clazz.defineEnumConstant(c$,"MONOMER",13,["monomer",76]);Clazz.defineEnumConstant(c$,"MOLECULE",14,["molecule",77]);Clazz.defineEnumConstant(c$,
"ALTLOC",15,["altloc",14]);Clazz.defineEnumConstant(c$,"INSERTION",16,["insertion",15]);Clazz.defineEnumConstant(c$,"JMOL",17,["jmol",16]);Clazz.defineEnumConstant(c$,"RASMOL",18,["rasmol",17]);Clazz.defineEnumConstant(c$,"TYPE",19,["type",18]);Clazz.defineEnumConstant(c$,"ENERGY",20,["energy",19]);Clazz.defineEnumConstant(c$,"PROPERTY",21,["property",84]);Clazz.defineEnumConstant(c$,"VARIABLE",22,["variable",85]);Clazz.defineEnumConstant(c$,"STRAIGHTNESS",23,["straightness",86]);Clazz.defineEnumConstant(c$,
"POLYMER",24,["polymer",87])}),Clazz.declarePackage("J.util"),Clazz.load(["java.util.Hashtable"],"J.util.ColorUtil",["JU.P3","$.ParserJS","J.util.Txt"],function(){c$=Clazz.declareType(J.util,"ColorUtil");c$.getArgbFromString=$_M(c$,"getArgbFromString",function(a){var c=0;if(null==a||0==(c=a.length))return 0;if("["==a.charAt(0)&&"]"==a.charAt(c-1)){var d;if(0<=a.indexOf(",")){d=J.util.Txt.split(a.substring(1,a.length-1),",");if(3!=d.length)return 0;a=JU.ParserJS.parseFloat(d[0]);c=JU.ParserJS.parseFloat(d[1]);
d=JU.ParserJS.parseFloat(d[2]);return J.util.ColorUtil.colorTriadToInt(a,c,d)}switch(c){case 9:d="x";break;case 10:d="0x";break;default:return 0}if(1!=a.indexOf(d))return 0;a="#"+a.substring(c-7,c-1);c=7}if(7==c&&"#"==a.charAt(0))try{return JU.ParserJS.parseIntRadix(a.substring(1,7),16)|4278190080}catch(e){if(Clazz.exceptionOf(e,Exception))return 0;throw e;}a=J.util.ColorUtil.mapJavaScriptColors.get(a.toLowerCase());return null==a?0:a.intValue()},"~S");c$.colorTriadToInt=$_M(c$,"colorTriadToInt",
function(a,c,d){1>=a&&(1>=c&&1>=d)&&(0<a&&(a=256*a-1),0<c&&(c=256*c-1),0<d&&(d=256*d-1));return J.util.ColorUtil.rgb(Clazz.floatToInt(a),Clazz.floatToInt(c),Clazz.floatToInt(d))},"~N,~N,~N");c$.rgb=$_M(c$,"rgb",function(a,c,d){return 4278190080|a<<16|c<<8|d},"~N,~N,~N");c$.colorPointFromString=$_M(c$,"colorPointFromString",function(a,c){return J.util.ColorUtil.colorPointFromInt(J.util.ColorUtil.getArgbFromString(a),c)},"~S,JU.P3");c$.colorPointFromInt2=$_M(c$,"colorPointFromInt2",function(a){return JU.P3.new3(a>>
16&255,a>>8&255,a&255)},"~N");c$.colorPtToInt=$_M(c$,"colorPtToInt",function(a){return J.util.ColorUtil.colorTriadToInt(a.x,a.y,a.z)},"JU.T3");c$.colorPointFromInt=$_M(c$,"colorPointFromInt",function(a,c){c.z=a&255;c.y=a>>8&255;c.x=a>>16&255;return c},"~N,JU.P3");c$.calcGreyscaleRgbFromRgb=$_M(c$,"calcGreyscaleRgbFromRgb",function(a){a=Clazz.doubleToInt((2989*(a>>16&255)+5870*(a>>8&255)+1140*(a&255)+5E3)/1E4)&16777215;return J.util.ColorUtil.rgb(a,a,a)},"~N");c$.getBgContrast=$_M(c$,"getBgContrast",
function(a){return 128>(J.util.ColorUtil.calcGreyscaleRgbFromRgb(a)&255)?8:4},"~N");Clazz.defineStatics(c$,"colorNames","black pewhite pecyan pepurple pegreen peblue peviolet pebrown pepink peyellow pedarkgreen peorange pelightblue pedarkcyan pedarkgray aliceblue antiquewhite aqua aquamarine azure beige bisque blanchedalmond blue blueviolet brown burlywood cadetblue chartreuse chocolate coral cornflowerblue cornsilk crimson cyan darkblue darkcyan darkgoldenrod darkgray darkgreen darkkhaki darkmagenta darkolivegreen darkorange darkorchid darkred darksalmon darkseagreen darkslateblue darkslategray darkturquoise darkviolet deeppink deepskyblue dimgray dodgerblue firebrick floralwhite forestgreen fuchsia gainsboro ghostwhite gold goldenrod gray green greenyellow honeydew hotpink indianred indigo ivory khaki lavender lavenderblush lawngreen lemonchiffon lightblue lightcoral lightcyan lightgoldenrodyellow lightgreen lightgrey lightpink lightsalmon lightseagreen lightskyblue lightslategray lightsteelblue lightyellow lime limegreen linen magenta maroon mediumaquamarine mediumblue mediumorchid mediumpurple mediumseagreen mediumslateblue mediumspringgreen mediumturquoise mediumvioletred midnightblue mintcream mistyrose moccasin navajowhite navy oldlace olive olivedrab orange orangered orchid palegoldenrod palegreen paleturquoise palevioletred papayawhip peachpuff peru pink plum powderblue purple red rosybrown royalblue saddlebrown salmon sandybrown seagreen seashell sienna silver skyblue slateblue slategray snow springgreen steelblue tan teal thistle tomato turquoise violet wheat white whitesmoke yellow yellowgreen bluetint greenblue greentint grey pinktint redorange yellowtint".split(" "),
"colorArgbs",[4278190080,4294967295,4278255615,4291830015,4278255360,4284506367,4294934720,4288946216,4294957272,4294967040,4278239232,4294946816,4289769727,4278231200,4284506208,4293982463,4294634455,4278255615,4286578644,4293984255,4294309340,4294960324,4294962125,4278190335,4287245282,4289014314,4292786311,4284456608,4286578432,4291979550,4294934352,4284782061,4294965468,4292613180,4278255615,4278190219,4278225803,4290283019,4289309097,4278215680,4290623339,4287299723,4283788079,4294937600,4288230092,
4287299584,4293498490,4287609999,4282924427,4281290575,4278243025,4287889619,4294907027,4278239231,4285098345,4280193279,4289864226,4294966E3,4280453922,4294902015,4292664540,4294506751,4294956800,4292519200,4286611584,4278222848,4289593135,4293984240,4294928820,4291648604,4283105410,4294967280,4293977740,4293322490,4294963445,4286381056,4294965965,4289583334,4293951616,4292935679,4294638290,4287688336,4292072403,4294948545,4294942842,4280332970,4287090426,4286023833,4289774814,4294967264,4278255360,
4281519410,4294635750,4294902015,4286578688,4284927402,4278190285,4290401747,4287852763,4282168177,4286277870,4278254234,4282962380,4291237253,4279834992,4294311930,4294960353,4294960309,4294958765,4278190208,4294833638,4286611456,4285238819,4294944E3,4294919424,4292505814,4293847210,4288215960,4289720046,4292571283,4294963157,4294957753,4291659071,4294951115,4292714717,4289781990,4286578816,4294901760,4290547599,4282477025,4287317267,4294606962,4294222944,4281240407,4294964718,4288696877,4290822336,
4287090411,4285160141,4285563024,4294966010,4278255487,4282811060,4291998860,4278222976,4292394968,4294927175,4282441936,4293821166,4294303411,4294967295,4294309365,4294967040,4288335154,4289714175,4281240407,4288217011,4286611584,4294945723,4294919424,4294375029]);c$.mapJavaScriptColors=c$.prototype.mapJavaScriptColors=new java.util.Hashtable;for(var a=J.util.ColorUtil.colorNames.length;0<=--a;)J.util.ColorUtil.mapJavaScriptColors.put(J.util.ColorUtil.colorNames[a],Integer.$valueOf(J.util.ColorUtil.colorArgbs[a]))}),
Clazz.declarePackage("J.util"),Clazz.load(["JU.ArrayUtil","$.V3"],"J.util.Shader",["J.util.C","$.ColorUtil"],function(){c$=Clazz.decorateAsClass(function(){this.zLight=this.yLight=this.xLight=0;this.lightSource=null;this.specularOn=!0;this.usePhongExponent=!1;this.ambientPercent=45;this.diffusePercent=84;this.specularExponent=6;this.specularPercent=22;this.specularPower=40;this.phongExponent=64;this.specularFactor=this.intenseFraction=this.diffuseFactor=this.ambientFraction=0;this.ashadesGreyscale=
this.ashades=null;this.rgbContrast=0;this.sphereShadingCalculated=!1;this.sphereShadeIndexes=null;this.seed=305419897;this.ellipsoidShades=this.sphereShapeCache=null;this.nIn=this.nOut=0;this.celOn=!1;Clazz.instantialize(this,arguments)},J.util,"Shader");Clazz.prepareFields(c$,function(){this.lightSource=new JU.V3;this.ambientFraction=this.ambientPercent/100;this.diffuseFactor=this.diffusePercent/100;this.intenseFraction=this.specularPower/100;this.specularFactor=this.specularPercent/100;this.ashades=
JU.ArrayUtil.newInt2(128);this.sphereShadeIndexes=Clazz.newByteArray(65536,0);this.sphereShapeCache=JU.ArrayUtil.newInt2(128)});Clazz.makeConstructor(c$,function(){this.setLightSource(-1,-1,2.5)});$_M(c$,"setLightSource",($fz=function(a,b,c){this.lightSource.set(a,b,c);this.lightSource.normalize();this.xLight=this.lightSource.x;this.yLight=this.lightSource.y;this.zLight=this.lightSource.z},$fz.isPrivate=!0,$fz),"~N,~N,~N");$_M(c$,"setCel",function(a,b){b=J.util.C.getArgb(J.util.ColorUtil.getBgContrast(b));
4278190080==b&&(b=4278453252);this.celOn==a&&this.rgbContrast==b||(this.celOn=a,this.rgbContrast=b,this.flushCaches())},"~B,~N");$_M(c$,"flushCaches",function(){this.flushShades();this.flushSphereCache()});$_M(c$,"getCelOn",function(){return this.celOn});$_M(c$,"setLastColix",function(a,b){J.util.C.allocateColix(a);this.checkShades();b&&J.util.C.setLastGrey(a);this.ashades[2047]=this.getShades2(a,!1)},"~N,~B");$_M(c$,"getShades",function(a){this.checkShades();a&=-30721;var b=this.ashades[a];null==
b&&(b=this.ashades[a]=this.getShades2(J.util.C.argbs[a],!1));return b},"~N");$_M(c$,"getShadesG",function(a){this.checkShades();a&=-30721;null==this.ashadesGreyscale&&(this.ashadesGreyscale=JU.ArrayUtil.newInt2(this.ashades.length));var b=this.ashadesGreyscale[a];null==b&&(b=this.ashadesGreyscale[a]=this.getShades2(J.util.C.argbs[a],!0));return b},"~N");$_M(c$,"checkShades",($fz=function(){null!=this.ashades&&this.ashades.length==J.util.C.colixMax||(this.ashades=JU.ArrayUtil.arrayCopyII(this.ashades,
J.util.C.colixMax),null!=this.ashadesGreyscale&&(this.ashadesGreyscale=JU.ArrayUtil.arrayCopyII(this.ashadesGreyscale,J.util.C.colixMax)))},$fz.isPrivate=!0,$fz));$_M(c$,"flushShades",function(){this.checkShades();for(var a=J.util.C.colixMax;0<=--a;)this.ashades[a]=null;this.sphereShadingCalculated=!1});$_M(c$,"getShades2",($fz=function(a,b){var c=Clazz.newIntArray(J.util.Shader.shadeIndexMax,0);if(0==a)return c;for(var d=a>>16&255,e=a>>8&255,f=a&255,g=0,h=0,k=0,l=this.ambientFraction;;)if(g=d*l+
0.5,h=e*l+0.5,k=f*l+0.5,0<l&&4>g&&4>h&&4>k)d++,e++,f++,0.1>l&&(l+=0.1),a=J.util.ColorUtil.rgb(Clazz.doubleToInt(Math.floor(d)),Clazz.doubleToInt(Math.floor(e)),Clazz.doubleToInt(Math.floor(f)));else break;if(this.celOn){for(var m=Clazz.doubleToInt(J.util.Shader.shadeIndexMax/2),l=(1-l)/J.util.Shader.shadeIndexNormal,d=d*l,e=e*l,l=f*l,n=J.util.ColorUtil.rgb(Clazz.doubleToInt(Math.floor(g)),Clazz.doubleToInt(Math.floor(h)),Clazz.doubleToInt(Math.floor(k))),f=0;f<m;++f)c[f]=n;h+=e*m;k+=l*m;for(n=J.util.ColorUtil.rgb(Clazz.doubleToInt(Math.floor(g+
d*m)),Clazz.doubleToInt(Math.floor(h)),Clazz.doubleToInt(Math.floor(k)));f<J.util.Shader.shadeIndexMax;f++)c[f]=n;c[0]=c[1]=this.rgbContrast}else{l=(1-l)/J.util.Shader.shadeIndexNormal;d*=l;e*=l;l*=f;for(f=0;f<J.util.Shader.shadeIndexNormal;++f)c[f]=J.util.ColorUtil.rgb(Clazz.doubleToInt(Math.floor(g)),Clazz.doubleToInt(Math.floor(h)),Clazz.doubleToInt(Math.floor(k))),g+=d,h+=e,k+=l;c[f++]=a;l=this.intenseFraction/(J.util.Shader.shadeIndexMax-f);d=(255.5-g)*l;e=(255.5-h)*l;for(l*=255.5-k;f<J.util.Shader.shadeIndexMax;f++)g+=
d,h+=e,k+=l,c[f]=J.util.ColorUtil.rgb(Clazz.doubleToInt(Math.floor(g)),Clazz.doubleToInt(Math.floor(h)),Clazz.doubleToInt(Math.floor(k)))}if(b)for(;0<=--f;)c[f]=J.util.ColorUtil.calcGreyscaleRgbFromRgb(c[f]);return c},$fz.isPrivate=!0,$fz),"~N,~B");$_M(c$,"getShadeIndex",function(a,b,c){var d=Math.sqrt(a*a+b*b+c*c);return Math.round(this.getShadeF(a/d,b/d,c/d)*J.util.Shader.shadeIndexLast)},"~N,~N,~N");$_M(c$,"getShadeB",function(a,b,c){return Math.round(this.getShadeF(a,b,c)*J.util.Shader.shadeIndexLast)},
"~N,~N,~N");$_M(c$,"getShadeFp8",function(a,b,c){var d=Math.sqrt(a*a+b*b+c*c);return Clazz.doubleToInt(Math.floor(256*this.getShadeF(a/d,b/d,c/d)*J.util.Shader.shadeIndexLast))},"~N,~N,~N");$_M(c$,"getShadeF",($fz=function(a,b,c){b=a*this.xLight+b*this.yLight+c*this.zLight;if(0>=b)return 0;a=b*this.diffuseFactor;if(this.specularOn&&(b=2*b*c-this.zLight,0<b)){if(this.usePhongExponent)b=Math.pow(b,this.phongExponent);else for(var d=this.specularExponent;0<=--d&&1E-4<b;)b*=b;a+=b*this.specularFactor}return this.celOn&&
0.5>c?0:1<a?1:a},$fz.isPrivate=!0,$fz),"~N,~N,~N");$_M(c$,"getShadeN",function(a,b,c,d){b=Clazz.doubleToInt(Math.floor(256*this.getShadeF(a/d,b/d,c/d)*J.util.Shader.shadeIndexLast));a=b>>8;(b&255)>this.nextRandom8Bit()&&++a;b=this.seed&65535;21845>b&&0<a?--a:43690<b&&a<J.util.Shader.shadeIndexLast&&++a;return a},"~N,~N,~N,~N");$_M(c$,"calcSphereShading",function(){for(var a=-127.5,b=0;256>b;++a,++b)for(var c=-127.5,d=0;256>d;++c,++d){var e=0,f=16900-a*a-c*c;0<f&&(e=Math.sqrt(f),e=this.getShadeN(a,
c,e,130));this.sphereShadeIndexes[(d<<8)+b]=e}this.sphereShadingCalculated=!0});$_M(c$,"nextRandom8Bit",function(){var a=this.seed;this.seed=a=(a<<16)+(a<<1)+a&2147483647;return a>>23});$_M(c$,"getEllipsoidShade",function(a,b,c,d,e){var f=e.m00*a+e.m01*b+e.m02*c+e.m03,g=e.m10*a+e.m11*b+e.m12*c+e.m13;a=e.m20*a+e.m21*b+e.m22*c+e.m23;d=Math.min(d/2,45)/Math.sqrt(f*f+g*g+a*a);f=Clazz.floatToInt(-f*d);g=Clazz.floatToInt(-g*d);d=Clazz.floatToInt(a*d);if(a=-20>f||20<=f||-20>g||20<=g||0>d||40<=d){for(;0==
f%2&&0==g%2&&0==d%2&&0<f+g+d;)f>>=1,g>>=1,d>>=1;a=-20>f||20<=f||-20>g||20<=g||0>d||40<=d}a?this.nOut++:this.nIn++;return a?this.getShadeIndex(f,g,d):this.ellipsoidShades[f+20][g+20][d]},"~N,~N,~N,~N,JU.M4");$_M(c$,"createEllipsoidShades",function(){this.ellipsoidShades=Clazz.newByteArray(40,40,40,0);for(var a=0;40>a;a++)for(var b=0;40>b;b++)for(var c=0;40>c;c++)this.ellipsoidShades[a][b][c]=this.getShadeIndex(a-20,b-20,c)});$_M(c$,"flushSphereCache",function(){for(var a=128;0<=--a;)this.sphereShapeCache[a]=
null;this.ellipsoidShades=null});Clazz.defineStatics(c$,"shadeIndexMax",64);c$.shadeIndexLast=c$.prototype.shadeIndexLast=J.util.Shader.shadeIndexMax-1;Clazz.defineStatics(c$,"shadeIndexNormal",52,"shadeIndexNoisyLimit",56,"SLIM",20,"SDIM",40,"maxSphereCache",128)}),Clazz.declarePackage("J.api"),Clazz.load(null,"J.api.JmolViewer",["java.util.Hashtable"],function(){c$=Clazz.decorateAsClass(function(){this.apiPlatform=this.menuStructure=null;Clazz.instantialize(this,arguments)},J.api,"JmolViewer");
c$.allocateViewer=$_M(c$,"allocateViewer",function(a,b,c,d,e,f,g,h){var k=new java.util.Hashtable;null!=a&&k.put("display",a);null!=b&&k.put("adapter",b);null!=g&&k.put("statusListener",g);null!=h&&k.put("platform",h);null!=f&&k.put("options",f);null!=c&&k.put("fullName",c);null!=d&&k.put("documentBase",d);null!=e&&k.put("codeBase",e);return new J.viewer.Viewer(k)},"~O,J.api.JmolAdapter,~S,java.net.URL,java.net.URL,~S,J.api.JmolStatusListener,J.api.ApiPlatform");c$.allocateViewer=$_M(c$,"allocateViewer",
function(a,b){return J.api.JmolViewer.allocateViewer(a,b,null,null,null,null,null,null)},"~O,J.api.JmolAdapter");c$.allocateViewer=$_M(c$,"allocateViewer",function(a,b,c,d,e,f,g){return J.api.JmolViewer.allocateViewer(a,b,c,d,e,f,g,null)},"~O,J.api.JmolAdapter,~S,java.net.URL,java.net.URL,~S,J.api.JmolStatusListener");$_M(c$,"setConsole",function(a){this.getProperty("DATA_API","getAppConsole",a)},"J.api.JmolAppConsoleInterface");c$.getJmolVersion=$_M(c$,"getJmolVersion",function(){return J.viewer.Viewer.getJmolVersion()});
c$.checkOption=$_M(c$,"checkOption",function(a,b){var c=a.getParameter(b);return Clazz.instanceOf(c,Boolean)&&c.booleanValue()||Clazz.instanceOf(c,Integer)&&0!=c.intValue()},"J.api.JmolViewer,~S");$_M(c$,"openFileAsync",function(a){this.openFileAsyncPDB(a,!1)},"~S");$_M(c$,"mouseEvent",function(a,b,c,d,e){this.handleOldJvm10Event(a,b,c,d,e)},"~N,~N,~N,~N,~N");$_M(c$,"renderScreenImage",function(a,b){this.apiPlatform.renderScreenImage(a,b)},"~O,~O,~O");$_M(c$,"getJsObjectInfo",function(a,b,c){return this.apiPlatform.getJsObjectInfo(a,
b,c)},"~A,~S,~A");c$.getJmolValueAsString=$_M(c$,"getJmolValueAsString",function(a,b){return null==a?"":""+a.getParameter(b)},"J.api.JmolViewer,~S")}),Clazz.declarePackage("J.atomdata"),Clazz.declareInterface(J.atomdata,"AtomDataServer"),Clazz.declarePackage("J.constant"),Clazz.load(["java.lang.Enum"],"J.constant.EnumVdw",null,function(){c$=Clazz.decorateAsClass(function(){this.pt=0;this.type2=this.type=null;Clazz.instantialize(this,arguments)},J.constant,"EnumVdw",Enum);Clazz.makeConstructor(c$,
($fz=function(a,b,c){this.pt=a;this.type=b;this.type2=c},$fz.isPrivate=!0,$fz),"~N,~S,~S");$_M(c$,"getVdwLabel",function(){return null==this.type?this.type2:this.type});c$.getVdwType=$_M(c$,"getVdwType",function(a){if(null!=a)for(var b,c=0,d=J.constant.EnumVdw.values();c<d.length&&((b=d[c])||1);c++)if(a.equalsIgnoreCase(b.type))return b;return null},"~S");c$.getVdwType2=$_M(c$,"getVdwType2",function(a){if(null!=a)for(var b,c=0,d=J.constant.EnumVdw.values();c<d.length&&((b=d[c])||1);c++)if(a.equalsIgnoreCase(b.type2))return b;
return null},"~S");Clazz.defineEnumConstant(c$,"JMOL",0,[0,"Jmol",null]);Clazz.defineEnumConstant(c$,"BABEL",1,[1,"Babel",null]);Clazz.defineEnumConstant(c$,"RASMOL",2,[2,"RasMol",null]);Clazz.defineEnumConstant(c$,"BABEL21",3,[3,"Babel21",null]);Clazz.defineEnumConstant(c$,"AUTO_JMOL",4,[0,null,"Jmol"]);Clazz.defineEnumConstant(c$,"AUTO_BABEL",5,[1,null,"Babel"]);Clazz.defineEnumConstant(c$,"AUTO_RASMOL",6,[2,null,"RasMol"]);Clazz.defineEnumConstant(c$,"AUTO",7,[0,"Auto",null]);Clazz.defineEnumConstant(c$,
"USER",8,[-1,"User",null]);Clazz.defineEnumConstant(c$,"ADPMAX",9,[-1,null,"adpmax"]);Clazz.defineEnumConstant(c$,"ADPMIN",10,[-1,null,"adpmin"]);Clazz.defineEnumConstant(c$,"HYDRO",11,[-1,null,"hydrophobic"]);Clazz.defineEnumConstant(c$,"IONIC",12,[-1,null,"ionic"]);Clazz.defineEnumConstant(c$,"TEMP",13,[-1,null,"temperature"]);Clazz.defineEnumConstant(c$,"NOJMOL",14,[-1,null,null]);Clazz.defineEnumConstant(c$,"NADA",15,[-1,null,null])}),Clazz.declarePackage("J.atomdata"),Clazz.load(["java.lang.Enum",
"J.constant.EnumVdw"],"J.atomdata.RadiusData",["java.lang.Float","JU.SB"],function(){c$=Clazz.decorateAsClass(function(){this.vdwType=this.factorType=this.info=null;this.value=NaN;this.valueExtended=0;this.values=null;Clazz.instantialize(this,arguments)},J.atomdata,"RadiusData");Clazz.prepareFields(c$,function(){this.factorType=J.atomdata.RadiusData.EnumType.ABSOLUTE;this.vdwType=J.constant.EnumVdw.AUTO});Clazz.makeConstructor(c$,function(a,b,c,d){null!=a?(this.values=a,this.value=2147483647):null!=
c&&(this.factorType=c,this.value=b,null!=d&&(this.vdwType=d))},"~A,~N,J.atomdata.RadiusData.EnumType,J.constant.EnumVdw");Clazz.overrideMethod(c$,"toString",function(){if(Float.isNaN(this.value))return"";var a=new JU.SB;switch(this.factorType){case J.atomdata.RadiusData.EnumType.ABSOLUTE:a.appendF(this.value);break;case J.atomdata.RadiusData.EnumType.OFFSET:a.append(0<this.value?"+":"").appendF(this.value);break;case J.atomdata.RadiusData.EnumType.FACTOR:a.appendI(Clazz.floatToInt(100*this.value)).append("%");
this.vdwType!==J.constant.EnumVdw.AUTO&&a.append(this.vdwType.getVdwLabel());break;case J.atomdata.RadiusData.EnumType.SCREEN:a.appendI(Clazz.floatToInt(this.value))}return a.toString()});Clazz.pu$h();c$=Clazz.declareType(J.atomdata.RadiusData,"EnumType",Enum);Clazz.defineEnumConstant(c$,"ABSOLUTE",0,[]);Clazz.defineEnumConstant(c$,"OFFSET",1,[]);Clazz.defineEnumConstant(c$,"FACTOR",2,[]);Clazz.defineEnumConstant(c$,"SCREEN",3,[]);c$=Clazz.p0p()}),Clazz.declarePackage("J.util"),Clazz.load(null,"J.util.CommandHistory",
["JU.List"],function(){c$=Clazz.decorateAsClass(function(){this.commandList=null;this.maxSize=100;this.cursorPos=this.nextCommand=0;this.isOn=!0;Clazz.instantialize(this,arguments)},J.util,"CommandHistory");Clazz.makeConstructor(c$,function(){this.reset(100)});Clazz.makeConstructor(c$,function(a){this.reset(a)},"~N");$_M(c$,"clear",function(){this.reset(this.maxSize)});$_M(c$,"reset",function(a){this.maxSize=a;this.commandList=new JU.List;this.nextCommand=0;this.commandList.addLast("");this.cursorPos=
0},"~N");$_M(c$,"setMaxSize",function(a){if(a!=this.maxSize){for(2>a&&(a=2);this.nextCommand>a;)this.commandList.remove(0),this.nextCommand--;this.nextCommand>a&&(this.nextCommand=a-1);this.cursorPos=this.nextCommand;this.maxSize=a}},"~N");$_M(c$,"getCommandUp",function(){if(0>=this.cursorPos)return null;this.cursorPos--;var a=this.getCommand();a.endsWith("#??")&&this.removeCommand(this.cursorPos--);0>this.cursorPos&&(this.cursorPos=0);return a});$_M(c$,"getCommandDown",function(){if(this.cursorPos>=
this.nextCommand)return null;this.cursorPos++;return this.getCommand()});$_M(c$,"getCommand",($fz=function(){return this.commandList.get(this.cursorPos)},$fz.isPrivate=!0,$fz));$_M(c$,"addCommand",function(a){if((this.isOn||a.endsWith("#??"))&&!a.endsWith("#----")){for(var b;0<=(b=a.indexOf("\n"));){var c=a.substring(0,b);0<c.length&&this.addCommandLine(c);a=a.substring(b+1)}0<a.length&&this.addCommandLine(a)}},"~S");$_M(c$,"getSetHistory",function(a){this.isOn=-2==a?this.isOn:!0;switch(a){case 0:return this.isOn=
!1,this.clear(),"";case -2147483648:case -2:return this.clear(),"";case -1:return this.getCommandUp();case 1:return this.getCommandDown();default:if(0>a)return this.setMaxSize(-2-a),"";a=Math.max(this.nextCommand-a,0)}for(var b="";a<this.nextCommand;a++)this.commandList.get(a).toUpperCase().startsWith("WRITE HISTORY")||(b+=this.commandList.get(a)+"\n");return b},"~N");$_M(c$,"removeCommand",function(){return this.removeCommand(this.nextCommand-1)});$_M(c$,"removeCommand",function(a){if(0>a||a>=this.nextCommand)return"";
a=this.commandList.remove(a);this.nextCommand--;return a},"~N");$_M(c$,"addCommandLine",($fz=function(a){if(!(null==a||0==a.length)&&!a.endsWith("#--"))this.nextCommand>=this.maxSize&&(this.commandList.remove(0),this.nextCommand=this.maxSize-1),this.commandList.add(this.nextCommand,a),this.nextCommand++,this.cursorPos=this.nextCommand,this.commandList.add(this.nextCommand,"")},$fz.isPrivate=!0,$fz),"~S");Clazz.defineStatics(c$,"ERROR_FLAG","#??","NOHISTORYLINE_FLAG","#--","NOHISTORYATALL_FLAG","#----",
"DEFAULT_MAX_SIZE",100)}),Clazz.declarePackage("javajs.awt"),c$=Clazz.decorateAsClass(function(){this.height=this.width=0;Clazz.instantialize(this,arguments)},javajs.awt,"Dimension"),Clazz.makeConstructor(c$,function(a,b){this.set(a,b)},"~N,~N"),$_M(c$,"set",function(a,b){this.width=a;this.height=b;return this},"~N,~N"),Clazz.declarePackage("J.api"),Clazz.declareInterface(J.api,"JSmolInterface"),Clazz.declarePackage("J.viewer"),Clazz.load("java.lang.Enum J.api.JSmolInterface $.JmolViewer $.PlatformViewer J.atomdata.AtomDataServer java.util.Hashtable javajs.awt.Dimension JU.List J.atomdata.RadiusData J.i18n.GT J.util.CommandHistory".split(" "),
"J.viewer.Viewer","java.io.BufferedReader $.StringReader java.lang.Boolean $.Character $.Float JU.ArrayUtil $.BS $.DecimalFormat $.P3 $.P3i $.ParserJS $.SB $.V3 J.adapter.smarter.SmarterJmolAdapter J.api.Interface J.constant.EnumAnimationMode $.EnumAxesMode $.EnumFileStatus $.EnumStereoMode $.EnumVdw J.io.CifDataReader $.JmolBinary J.modelset.Group J.script.SV $.T J.thread.TimeoutThread J.util.BSUtil $.C $.ColorUtil $.Elements $.Escape $.GData $.JmolMolecule $.Logger $.Measure $.Parser $.ParserBS $.TempArray $.Txt J.viewer.ActionManager $.AnimationManager $.ColorManager $.DataManager $.FileManager $.JC $.ModelManager $.SelectionManager $.ShapeManager $.StateManager $.StatusManager $.TransformManager J.viewer.binding.Binding".split(" "),
function(){c$=Clazz.decorateAsClass(function(){this.queueOnHold=this.isSingleThreaded=this.isWebGL=this.isJS=this.haveDisplay=this.autoExit=!1;this.appletCodeBase=this.appletDocumentBase=this.fullName="";this.fileManager=this.modelSet=this.definedAtomSets=this.compiler=null;this.mustRender=this.listCommands=this.isSyntaxCheck=this.isSyntaxAndFileCheck=this.$isApplet=!1;this.insertedCommand=this.htmlName="";this.transformManager=this.statusManager=this.global=this.repaintManager=this.selectionManager=
this.shapeManager=this.dataManager=this.colorManager=this.animationManager=this.actionManager=this.applet=this.gdata=null;this.logFilePath=this.syncId="";this.useCommandThread=this.$noGraphicsAllowed=this.multiTouch=this.isSilent=this.isSignedAppletLocal=this.$isSignedApplet=this.isPrintOnly=this.allowScripting=!1;this.tempArray=this.eval=this.scriptManager=this.stateManager=this.modelManager=this.smilesMatcher=this.symmetry=this.commandHistory=this.access=this.modelAdapter=this.display=this.viewerOptions=
this.commandOptions=null;this.$isPreviewOnly=!1;this.mouse=null;this.mouseEnabled=!0;this.noneSelected=!1;this.frameOffsets=this.bsFrameOffsets=this.sc=this.ligandModelSet=this.ligandModels=null;this.motionEventNumber=0;this.inMotion=!1;this.refreshing=!0;this.axesAreTainted=!1;this.dimScreen=null;this.maximumSize=2147483647;this.imageFontScaling=1;this.captureParams=null;this.antialiasDisplay=!1;this.hoverAtomIndex=-1;this.hoverText=null;this.hoverEnabled=!0;this.currentCursor=0;this.prevFrame=-2147483648;
this.haveJDX=!1;this.rd=this.language=this.jsv=null;this.frankOn=!0;this.scriptEditorVisible=!1;this.pm=this.headlessImageParams=this.modelkitPopup=this.jmolpopup=this.scriptEditor=this.appConsole=null;this.isTainted=!0;this.showSelected=this.movingSelected=!1;this.rotatePrev2=this.rotatePrev1=this.rotateBondIndex=-1;this.bsRotateBranch=null;this.creatingImage=!1;this.errorMessageUntranslated=this.errorMessage=this.outputManager=null;this.currentShapeID=-1;this.localFunctions=this.currentShapeState=
null;this.privateKey=0;this.$isKiosk=!1;this.executor=this.minimizer=null;this.displayLoadErrors=!0;this.$isParallel=!1;this.actionStatesRedo=this.actionStates=null;this.stateScriptVersionInt=0;this.logFileName=this.nmrCalculation=this.chainList=this.chainMap=this.timeouts=this.htPdbBondInfo=this.jsExporter3D=null;Clazz.instantialize(this,arguments)},J.viewer,"Viewer",J.api.JmolViewer,[J.atomdata.AtomDataServer,J.api.PlatformViewer,J.api.JSmolInterface]);Clazz.prepareFields(c$,function(){this.commandHistory=
new J.util.CommandHistory;this.dimScreen=new javajs.awt.Dimension(0,0);this.language=J.i18n.GT.getLanguage();this.rd=new J.atomdata.RadiusData(null,0,null,null);this.localFunctions=new java.util.Hashtable;this.privateKey=Math.random();this.actionStates=new JU.List;this.actionStatesRedo=new JU.List;this.chainMap=new java.util.Hashtable;this.chainList=new JU.List});$_M(c$,"finalize",function(){J.util.Logger.debugging&&J.util.Logger.debug("viewer finalize "+this);Clazz.superCall(this,J.viewer.Viewer,
"finalize",[])});$_M(c$,"hasDisplay",function(){return this.haveDisplay});Clazz.overrideMethod(c$,"isApplet",function(){return this.$isApplet});$_M(c$,"setInsertedCommand",function(a){this.insertedCommand=a},"~S");$_M(c$,"getActionManager",function(){return this.actionManager});$_M(c$,"getLogFilePath",function(){return this.logFilePath});$_M(c$,"isSignedApplet",function(){return this.$isSignedApplet});c$.getJmolVersion=Clazz.overrideMethod(c$,"getJmolVersion",function(){return null==J.viewer.Viewer.version_date?
($t$=J.viewer.Viewer.version_date=J.viewer.JC.version+"  "+J.viewer.JC.date,J.viewer.Viewer.prototype.version_date=J.viewer.Viewer.version_date,$t$):J.viewer.Viewer.version_date});c$.allocateViewer=$_M(c$,"allocateViewer",function(a,b,c,d,e,f,g,h){var k=new java.util.Hashtable;k.put("display",a);k.put("adapter",b);k.put("statusListener",g);k.put("platform",h);k.put("options",f);k.put("fullName",c);k.put("documentBase",d);k.put("codeBase",e);return new J.viewer.Viewer(k)},"~O,J.api.JmolAdapter,~S,java.net.URL,java.net.URL,~S,J.api.JmolStatusListener,J.api.ApiPlatform");
Clazz.makeConstructor(c$,function(a){Clazz.superConstructor(this,J.viewer.Viewer,[]);this.setOptions(a)},"java.util.Map");$_M(c$,"getGlobalSettings",function(){return this.global});$_M(c$,"getStatusManager",function(){return this.statusManager});$_M(c$,"haveAccess",function(a){return this.access===a},"J.viewer.Viewer.ACCESS");Clazz.overrideMethod(c$,"getModelAdapter",function(){null==this.modelAdapter&&(this.modelAdapter=new J.adapter.smarter.SmarterJmolAdapter);return this.modelAdapter});$_M(c$,
"getSymmetry",function(){null==this.symmetry&&(this.symmetry=J.api.Interface.getOptionInterface("symmetry.Symmetry"));return this.symmetry});$_M(c$,"getSymmetryInfo",function(a,b,c,d,e,f,g){return this.getPropertyManager().getSymmetryInfo(a,b,c,d,e,f,g)},"JU.BS,~S,~N,JU.P3,JU.P3,~S,~N");$_M(c$,"getSmilesMatcher",function(){null==this.smilesMatcher&&(this.smilesMatcher=J.api.Interface.getOptionInterface("smiles.SmilesMatcher"));return this.smilesMatcher});Clazz.overrideMethod(c$,"getSmartsMatch",function(a,
b){null==b&&(b=this.getSelectionSet(!1));return this.getSmilesMatcher().getSubstructureSet(a,this.modelSet.atoms,this.getAtomCount(),b,!0,!1)},"~S,JU.BS");$_M(c$,"getViewerOptions",function(){return this.viewerOptions});$_M(c$,"setOptions",($fz=function(a){this.viewerOptions=a;J.util.Logger.debugging&&J.util.Logger.debug("Viewer constructor "+this);this.modelAdapter=a.get("adapter");var b=a.get("statusListener");this.fullName=a.get("fullName");null==this.fullName&&(this.fullName="");var c=a.get("codeBase");
this.appletCodeBase=null==c?"":c.toString();c=a.get("documentBase");this.appletDocumentBase=null==c?"":c.toString();c=a.get("options");this.commandOptions=null==c?"":c.toString();(a.containsKey("debug")||0<=this.commandOptions.indexOf("-debug"))&&J.util.Logger.setLogLevel(5);this.$isApplet=(this.$isSignedApplet=this.checkOption2("signedApplet","-signed"))||this.checkOption2("applet","-applet");this.allowScripting=!this.checkOption2("noscripting","-noscripting");c=this.fullName.indexOf("__");this.htmlName=
0>c?this.fullName:this.fullName.substring(0,c);this.syncId=0>c?"":this.fullName.substring(c+2,this.fullName.length-2);this.$isApplet&&("undefined"!=typeof Jmol&&(this.applet=Jmol._applets[this.htmlName.split("_object")[0]]),a.containsKey("maximumSize")&&this.setMaximumSize(a.get("maximumSize").intValue()));this.access=this.checkOption2("access:READSPT","-r")?J.viewer.Viewer.ACCESS.READSPT:this.checkOption2("access:NONE","-R")?J.viewer.Viewer.ACCESS.NONE:J.viewer.Viewer.ACCESS.ALL;(this.$isPreviewOnly=
a.containsKey("previewOnly"))&&a.remove("previewOnly");this.isPrintOnly=this.checkOption2("printOnly","-p");var c=a.get("platform"),d="unknown";null==c&&(c=this.commandOptions.contains("platform=")?this.commandOptions.substring(this.commandOptions.indexOf("platform=")+9):"J.awt.Platform");Clazz.instanceOf(c,String)&&(d=c,this.isJS=(this.isWebGL=0<=d.indexOf(".awtjs."))||0<=d.indexOf(".awtjs2d."),c=J.api.Interface.getInterface(d));this.apiPlatform=c;this.display=a.get("display");this.isSingleThreaded=
this.apiPlatform.isSingleThreaded();this.$noGraphicsAllowed=this.checkOption2("noGraphics","-n");this.haveDisplay=this.isWebGL||null!=this.display&&!this.$noGraphicsAllowed&&!this.isHeadless()&&!this.checkOption2("isDataOnly","\x00");this.$noGraphicsAllowed=(new Boolean(this.$noGraphicsAllowed&null==this.display)).valueOf();this.haveDisplay?(this.mustRender=!0,this.multiTouch=this.checkOption2("multiTouch","-multitouch"),this.isWebGL||(this.display=document.getElementById(this.display))):this.display=
null;this.apiPlatform.setViewer(this,this.display);c=a.get("graphicsAdapter");null==c&&!this.isWebGL&&(c=J.api.Interface.getInterface("J.g3d.Graphics3D"));this.gdata=null==c?new J.util.GData:c;this.gdata.initialize(this.apiPlatform);this.stateManager=new J.viewer.StateManager(this);this.colorManager=new J.viewer.ColorManager(this,this.gdata);this.statusManager=new J.viewer.StatusManager(this);this.transformManager=new J.viewer.TransformManager(this,2147483647,0);this.selectionManager=new J.viewer.SelectionManager(this);
this.haveDisplay&&(this.actionManager=this.multiTouch?J.api.Interface.getOptionInterface("multitouch.ActionManagerMT"):new J.viewer.ActionManager,this.actionManager.setViewer(this,this.commandOptions+"-multitouch-"+a.get("multiTouch")),this.mouse=this.apiPlatform.getMouseManager(this.privateKey,this.display),this.multiTouch&&!this.checkOption2("-simulated","-simulated")&&this.apiPlatform.setTransparentCursor(this.display));this.modelManager=new J.viewer.ModelManager(this);this.shapeManager=new J.viewer.ShapeManager(this);
this.tempArray=new J.util.TempArray;this.dataManager=new J.viewer.DataManager(this);this.animationManager=new J.viewer.AnimationManager(this);c=a.get("repaintManager");null==c&&(c=J.api.Interface.getOptionInterface("render.RepaintManager"));null!=c&&!c.equals("")&&(this.repaintManager=c).set(this,this.shapeManager);this.initialize(!0);this.fileManager=new J.viewer.FileManager(this);this.definedAtomSets=new java.util.Hashtable;this.setJmolStatusListener(b);this.$isApplet?(J.util.Logger.info("viewerOptions: \n"+
J.util.Escape.escapeMap(this.viewerOptions)),$t$=J.viewer.Viewer.jsDocumentBase=this.appletDocumentBase,J.viewer.Viewer.prototype.jsDocumentBase=J.viewer.Viewer.jsDocumentBase,$t$,c=J.viewer.Viewer.jsDocumentBase.indexOf("#"),0<=c&&($t$=J.viewer.Viewer.jsDocumentBase=J.viewer.Viewer.jsDocumentBase.substring(0,c),J.viewer.Viewer.prototype.jsDocumentBase=J.viewer.Viewer.jsDocumentBase,$t$),c=J.viewer.Viewer.jsDocumentBase.lastIndexOf("?"),0<=c&&($t$=J.viewer.Viewer.jsDocumentBase=J.viewer.Viewer.jsDocumentBase.substring(0,
c),J.viewer.Viewer.prototype.jsDocumentBase=J.viewer.Viewer.jsDocumentBase,$t$),c=J.viewer.Viewer.jsDocumentBase.lastIndexOf("/"),0<=c&&($t$=J.viewer.Viewer.jsDocumentBase=J.viewer.Viewer.jsDocumentBase.substring(0,c),J.viewer.Viewer.prototype.jsDocumentBase=J.viewer.Viewer.jsDocumentBase,$t$),this.fileManager.setAppletContext(this.appletDocumentBase),b=a.get("appletProxy"),null!=b&&this.setStringProperty("appletProxy",b),this.$isSignedApplet?(this.logFilePath=J.util.Txt.simpleReplace(this.appletCodeBase,
"file://",""),this.logFilePath=J.util.Txt.simpleReplace(this.logFilePath,"file:/",""),0<=this.logFilePath.indexOf("//")?this.logFilePath=null:this.isSignedAppletLocal=!0):this.isJS||(this.logFilePath=null)):(this.gdata.setBackgroundTransparent(this.checkOption2("backgroundTransparent","-b")),(this.isSilent=this.checkOption2("silent","-i"))&&J.util.Logger.setLogLevel(3),this.isSyntaxCheck=(this.isSyntaxAndFileCheck=this.checkOption2("checkLoad","-C"))||this.checkOption2("check","-c"),this.listCommands=
this.checkOption2("listCommands","-l"),this.autoExit=this.checkOption2("exit","-x"),this.cd("."),this.isHeadless()&&(this.headlessImageParams=a.get("headlessImage"),c=a.get("headlistMaxTimeMs"),null==c&&(c=Integer.$valueOf(6E4)),this.setTimeout(""+Math.random(),c.intValue(),"exitJmol")));this.useCommandThread=!this.isHeadless()&&this.checkOption2("useCommandThread","-threaded");this.setStartupBooleans();this.setIntProperty("_nProcessors",J.viewer.Viewer.nProcessors);c=a.get("menuFile");null!=c&&this.getProperty("DATA_API",
"setMenu",this.getFileAsString(c));this.isSilent||J.util.Logger.info("(C) 2012 Jmol Development\nJmol Version: "+J.viewer.Viewer.getJmolVersion()+"\njava.vendor: "+J.viewer.Viewer.strJavaVendor+"\njava.version: "+J.viewer.Viewer.strJavaVersion+"\nos.name: "+J.viewer.Viewer.strOSName+"\nAccess: "+this.access+"\nmemory: "+this.getParameter("_memory")+"\nprocessors available: "+J.viewer.Viewer.nProcessors+"\nuseCommandThread: "+this.useCommandThread+(!this.$isApplet?"":"\nappletId:"+this.htmlName+(this.$isSignedApplet?
" (signed)":"")));this.zap(!1,!0,!1);this.global.setS("language",J.i18n.GT.getLanguage());this.stateManager.setJmolDefaults()},$fz.isPrivate=!0,$fz),"java.util.Map");$_M(c$,"setDisplay",function(a){this.display=a;this.apiPlatform.setViewer(this,a)},"~O");$_M(c$,"getScriptManager",($fz=function(){this.allowScripting&&null==this.scriptManager&&(this.scriptManager=J.api.Interface.getOptionInterface("script.ScriptManager"),this.scriptManager.setViewer(this),this.eval=this.scriptManager.getEval(),this.useCommandThread&&
this.scriptManager.startCommandWatcher(!0));return this.scriptManager},$fz.isPrivate=!0,$fz));$_M(c$,"checkOption2",($fz=function(a,b){return this.viewerOptions.containsKey(a)||0<=this.commandOptions.indexOf(b)},$fz.isPrivate=!0,$fz),"~S,~S");$_M(c$,"isPreviewOnly",function(){return this.$isPreviewOnly});$_M(c$,"isHeadless",function(){return this.apiPlatform.isHeadless()});$_M(c$,"setStartupBooleans",($fz=function(){this.setBooleanProperty("_applet",this.$isApplet);this.setBooleanProperty("_jspecview",
!1);this.setBooleanProperty("_signedApplet",this.$isSignedApplet);this.setBooleanProperty("_headless",this.apiPlatform.isHeadless());this.setStringProperty("_restrict",'"'+this.access+'"');this.setBooleanProperty("_useCommandThread",this.useCommandThread)},$fz.isPrivate=!0,$fz));$_M(c$,"noGraphicsAllowed",function(){return this.$noGraphicsAllowed});$_M(c$,"getExportDriverList",function(){return this.haveAccess(J.viewer.Viewer.ACCESS.ALL)?this.global.getParameter("exportDrivers"):""});$_M(c$,"getHtmlName",
function(){return this.htmlName});Clazz.overrideMethod(c$,"getDisplay",function(){return this.display});$_M(c$,"clearMouse",function(){this.mouse.clear()});$_M(c$,"disposeMouse",function(){this.actionManager.dispose();this.mouse.dispose();this.mouse=null});Clazz.overrideMethod(c$,"processTwoPointGesture",function(a){this.mouse.processTwoPointGesture(a)},"~A");Clazz.overrideMethod(c$,"handleOldJvm10Event",function(a,b,c,d,e){return this.mouse.handleOldJvm10Event(a,b,c,d,e)},"~N,~N,~N,~N,~N");$_M(c$,
"reset",function(a){this.modelSet.calcBoundBoxDimensions(null,1);this.axesAreTainted=!0;this.transformManager.homePosition(a);this.modelSet.setCrystallographicDefaults()?this.stateManager.setCrystallographicDefaults():this.setAxesModeMolecular(!1);this.prevFrame=-2147483648;this.getSpinOn()||this.refresh(-1,"Viewer:homePosition()")},"~B");Clazz.overrideMethod(c$,"homePosition",function(){this.evalString("reset spin")});$_M(c$,"getAppletInfo",function(){var a=new java.util.Hashtable;a.put("htmlName",
this.htmlName);a.put("syncId",this.syncId);a.put("fullName",this.fullName);this.$isApplet&&(a.put("documentBase",this.appletDocumentBase),a.put("codeBase",this.appletCodeBase),a.put("registry",this.statusManager.getRegistryInfo()));a.put("version",J.viewer.JC.version);a.put("date",J.viewer.JC.date);a.put("javaVendor",J.viewer.Viewer.strJavaVendor);a.put("javaVersion",J.viewer.Viewer.strJavaVersion+(!this.isJS?"":this.isWebGL?"(WebGL)":"(HTML5)"));a.put("operatingSystem",J.viewer.Viewer.strOSName);
return a});$_M(c$,"initialize",function(a){this.global=this.stateManager.getGlobalSettings(this.global,a);this.setStartupBooleans();this.global.setI("_width",this.dimScreen.width);this.global.setI("_height",this.dimScreen.height);this.haveDisplay&&(this.global.setB("_is2D",this.isJS&&!this.isWebGL),this.global.setB("_multiTouchClient",this.actionManager.isMTClient()),this.global.setB("_multiTouchServer",this.actionManager.isMTServer()));this.colorManager.resetElementColors();this.setObjectColor("background",
"black");this.setObjectColor("axis1","red");this.setObjectColor("axis2","green");this.setObjectColor("axis3","blue");this.gdata.setAmbientPercent(this.global.ambientPercent);this.gdata.setDiffusePercent(this.global.diffusePercent);this.gdata.setSpecular(this.global.specular);this.gdata.setCel(this.global.celShading);this.gdata.setSpecularPercent(this.global.specularPercent);this.gdata.setSpecularPower(-this.global.specularExponent);this.gdata.setPhongExponent(this.global.phongExponent);this.gdata.setSpecularPower(this.global.specularPower);
null!=this.modelSet&&this.animationManager.setAnimationOn(!1);this.animationManager.setAnimationFps(this.global.animationFps);this.statusManager.setAllowStatusReporting(this.global.statusReporting);this.setBooleanProperty("antialiasDisplay",this.global.antialiasDisplay);this.setTransformManagerDefaults()},"~B");$_M(c$,"listSavedStates",function(){return this.stateManager.listSavedStates()});$_M(c$,"saveOrientation",function(a,b){this.stateManager.saveOrientation(a,b)},"~S,~A");$_M(c$,"saveScene",
function(a,b){this.stateManager.saveScene(a,b)},"~S,java.util.Map");$_M(c$,"restoreScene",function(a,b){this.stateManager.restoreScene(a,b)},"~S,~N");$_M(c$,"restoreOrientation",function(a,b){return this.stateManager.restoreOrientation(a,b,!0)},"~S,~N");$_M(c$,"restoreRotation",function(a,b){this.stateManager.restoreOrientation(a,b,!1)},"~S,~N");$_M(c$,"saveModelOrientation",function(){this.modelSet.saveModelOrientation(this.animationManager.currentModelIndex,this.stateManager.getOrientation())});
$_M(c$,"getOrientation",function(){return this.stateManager.getOrientation()});$_M(c$,"restoreModelOrientation",function(a){a=this.modelSet.getModelOrientation(a);null!=a&&a.restore(-1,!0)},"~N");$_M(c$,"restoreModelRotation",function(a){a=this.modelSet.getModelOrientation(a);null!=a&&a.restore(-1,!1)},"~N");$_M(c$,"saveBonds",function(a){this.stateManager.saveBonds(a)},"~S");$_M(c$,"restoreBonds",function(a){this.clearModelDependentObjects();return this.stateManager.restoreBonds(a)},"~S");$_M(c$,
"saveState",function(a){this.stateManager.saveState(a)},"~S");$_M(c$,"deleteSavedState",function(a){this.stateManager.deleteSaved("State_"+a)},"~S");$_M(c$,"getSavedState",function(a){return this.stateManager.getSavedState(a)},"~S");$_M(c$,"saveStructure",function(a){this.stateManager.saveStructure(a)},"~S");$_M(c$,"getSavedStructure",function(a){return this.stateManager.getSavedStructure(a)},"~S");$_M(c$,"saveCoordinates",function(a,b){this.stateManager.saveCoordinates(a,b)},"~S,JU.BS");$_M(c$,"getSavedCoordinates",
function(a){return this.stateManager.getSavedCoordinates(a)},"~S");$_M(c$,"saveSelection",function(a){this.stateManager.saveSelection(a,this.getSelectionSet(!1));this.stateManager.restoreSelection(a)},"~S");$_M(c$,"restoreSelection",function(a){return this.stateManager.restoreSelection(a)},"~S");$_M(c$,"getMatrixtransform",function(){return this.transformManager.getMatrixtransform()});$_M(c$,"getRotationQuaternion",function(){return this.transformManager.getRotationQuaternion()});$_M(c$,"setRotationRadius",
function(a,b){b&&(a=this.transformManager.setRotationRadius(a,!1));this.modelSet.setRotationRadius(this.animationManager.currentModelIndex,a)&&this.global.setF("rotationRadius",a)},"~N,~B");$_M(c$,"getRotationCenter",function(){return this.transformManager.getRotationCenter()});$_M(c$,"setCenterAt",function(a,b){this.isJmolDataFrame()||this.transformManager.setCenterAt(a,b)},"~S,JU.P3");$_M(c$,"setCenterBitSet",function(a,b){var c=0<J.util.BSUtil.cardinalityOf(a)?this.getAtomSetCenter(a):null;this.isJmolDataFrame()||
this.transformManager.setNewRotationCenter(c,b)},"JU.BS,~B");$_M(c$,"setNewRotationCenter",function(a){this.isJmolDataFrame()||this.transformManager.setNewRotationCenter(a,!0)},"JU.P3");$_M(c$,"getNavigationCenter",function(){return this.transformManager.getNavigationCenter()});$_M(c$,"getNavigationDepthPercent",function(){return this.transformManager.getNavigationDepthPercent()});$_M(c$,"navigate",function(a,b){this.isJmolDataFrame()||(this.transformManager.navigateKey(a,b),!this.transformManager.vibrationOn&&
0!=a&&this.refresh(1,"Viewer:navigate()"))},"~N,~N");$_M(c$,"getNavigationOffset",function(){return this.transformManager.getNavigationOffset()});$_M(c$,"getNavigationOffsetPercent",function(a){return this.transformManager.getNavigationOffsetPercent(a)},"~S");$_M(c$,"isNavigating",function(){return this.transformManager.isNavigating()});$_M(c$,"isInPosition",function(a,b){return this.transformManager.isInPosition(a,b)},"JU.V3,~N");$_M(c$,"move",function(a,b,c,d,e,f,g){this.transformManager.move(a,
b,c,d,e,f,g);this.moveUpdate(f)},"J.api.JmolScriptEvaluator,JU.V3,~N,JU.V3,~N,~N,~N");$_M(c$,"stopMotion",function(){this.transformManager.stopMotion()});$_M(c$,"setRotationMatrix",function(a){this.transformManager.setRotation(a)},"JU.M3");$_M(c$,"moveTo",function(a,b,c,d,e,f,g,h,k,l,m,n,q,p,r,s,t){this.haveDisplay||(b=0);this.setTainted(!0);this.transformManager.moveTo(a,b,c,d,e,f,g,h,k,l,m,n,q,p,r,s,t)},"J.api.JmolScriptEvaluator,~N,JU.P3,JU.V3,~N,JU.M3,~N,~N,~N,~N,JU.P3,~N,~N,~N,~N,~N,~N");$_M(c$,
"moveUpdate",function(a){0<a?this.requestRepaintAndWait("moveUpdate"):0==a&&this.setSync()},"~N");$_M(c$,"getMoveToText",function(a){return this.transformManager.getMoveToText(a,!1)},"~N");$_M(c$,"navigateList",function(a,b){this.isJmolDataFrame()||this.transformManager.navigateList(a,b)},"J.api.JmolScriptEvaluator,JU.List");$_M(c$,"navigatePt",function(a){this.transformManager.setNavigatePt(a);this.setSync()},"JU.P3");$_M(c$,"navigateAxis",function(a,b){this.transformManager.navigateAxis(a,b);this.setSync()},
"JU.V3,~N");$_M(c$,"navTranslatePercent",function(a,b){this.isJmolDataFrame()||(this.transformManager.navTranslatePercentOrTo(0,a,b),this.setSync())},"~N,~N");$_M(c$,"setMouseEnabled",function(a){this.mouseEnabled=a},"~B");Clazz.overrideMethod(c$,"processMultitouchEvent",function(a,b,c,d,e,f){this.actionManager.processMultitouchEvent(a,b,c,d,e,f)},"~N,~N,~N,~N,JU.P3,~N");$_M(c$,"zoomBy",function(a){this.mouseEnabled&&this.transformManager.zoomBy(a);this.refresh(2,this.statusManager.syncingMouse?"Mouse: zoomBy "+
a:"")},"~N");$_M(c$,"zoomByFactor",function(a,b,c){this.mouseEnabled&&this.transformManager.zoomByFactor(a,b,c);this.refresh(2,!this.statusManager.syncingMouse?"":"Mouse: zoomByFactor "+a+(2147483647==b?"":" "+b+" "+c))},"~N,~N,~N");$_M(c$,"rotateXYBy",function(a,b){this.mouseEnabled&&this.transformManager.rotateXYBy(a,b,null);this.refresh(2,this.statusManager.syncingMouse?"Mouse: rotateXYBy "+a+" "+b:"")},"~N,~N");$_M(c$,"spinXYBy",function(a,b,c){this.mouseEnabled&&this.transformManager.spinXYBy(a,
b,c);0==a&&0==b||this.refresh(2,this.statusManager.syncingMouse?"Mouse: spinXYBy "+a+" "+b+" "+c:"")},"~N,~N,~N");$_M(c$,"rotateZBy",function(a,b,c){this.mouseEnabled&&this.transformManager.rotateZBy(a,b,c);this.refresh(2,this.statusManager.syncingMouse?"Mouse: rotateZBy "+a+(2147483647==b?"":" "+b+" "+c):"")},"~N,~N,~N");$_M(c$,"rotateSelected",function(a,b,c){this.isJmolDataFrame()||(this.mouseEnabled&&(this.transformManager.rotateXYBy(a,b,this.setMovableBitSet(c,!1)),this.refreshMeasures(!0)),
this.refresh(2,this.statusManager.syncingMouse?"Mouse: rotateMolecule "+a+" "+b:""))},"~N,~N,JU.BS");$_M(c$,"setMovableBitSet",($fz=function(a,b){null==a&&(a=this.getSelectionSet(!1));a=J.util.BSUtil.copy(a);J.util.BSUtil.andNot(a,this.getMotionFixedAtoms());b&&!this.global.allowMoveAtoms&&(a=this.modelSet.getMoleculeBitSet(a));return a},$fz.isPrivate=!0,$fz),"JU.BS,~B");$_M(c$,"translateXYBy",function(a,b){this.mouseEnabled&&this.transformManager.translateXYBy(a,b);this.refresh(2,this.statusManager.syncingMouse?
"Mouse: translateXYBy "+a+" "+b:"")},"~N,~N");Clazz.overrideMethod(c$,"rotateFront",function(){this.transformManager.rotateFront();this.refresh(1,"Viewer:rotateFront()")});Clazz.overrideMethod(c$,"rotateX",function(a){this.transformManager.rotateX(a);this.refresh(1,"Viewer:rotateX()")},"~N");Clazz.overrideMethod(c$,"rotateY",function(a){this.transformManager.rotateY(a);this.refresh(1,"Viewer:rotateY()")},"~N");Clazz.overrideMethod(c$,"rotateZ",function(a){this.transformManager.rotateZ(a);this.refresh(1,
"Viewer:rotateZ()")},"~N");Clazz.overrideMethod(c$,"rotateXDeg",function(a){this.rotateX(0.017453292*a)},"~N");Clazz.overrideMethod(c$,"rotateYDeg",function(a){this.rotateY(0.017453292*a)},"~N");$_M(c$,"translate",function(a,b,c,d){var e="\x00"==c?Clazz.floatToInt(b):"%"==c?this.transformManager.percentToPixels(a,b):this.transformManager.angstromsToPixels(b*("n"==c?10:1));if(null!=d){if(0==e)return;this.transformManager.setSelectedTranslation(d,a,e)}else switch(a){case "X":case "x":"\x00"==c?this.transformManager.translateToPercent("x",
b):this.transformManager.translateXYBy(e,0);break;case "Y":case "y":"\x00"==c?this.transformManager.translateToPercent("y",b):this.transformManager.translateXYBy(0,e);break;case "Z":case "z":"\x00"==c?this.transformManager.translateToPercent("z",b):this.transformManager.translateZBy(e)}this.refresh(1,"Viewer:translate()")},"~S,~N,~S,JU.BS");$_M(c$,"getTranslationXPercent",function(){return this.transformManager.getTranslationXPercent()});$_M(c$,"getTranslationYPercent",function(){return this.transformManager.getTranslationYPercent()});
$_M(c$,"getTranslationZPercent",function(){return this.transformManager.getTranslationZPercent()});$_M(c$,"getTranslationScript",function(){return this.transformManager.getTranslationScript()});$_M(c$,"getZShadeStart",function(){return this.transformManager.getZShadeStart()});$_M(c$,"isWindowCentered",function(){return this.transformManager.isWindowCentered()});Clazz.overrideMethod(c$,"getZoomPercent",function(){return Clazz.floatToInt(this.getZoomSetting())});$_M(c$,"getZoomSetting",function(){return this.transformManager.getZoomSetting()});
Clazz.overrideMethod(c$,"getZoomPercentFloat",function(){return this.transformManager.getZoomPercentFloat()});$_M(c$,"getMaxZoomPercent",function(){return 2E5});$_M(c$,"slabReset",function(){this.transformManager.slabReset()});$_M(c$,"getZoomEnabled",function(){return this.transformManager.zoomEnabled});$_M(c$,"getSlabEnabled",function(){return this.transformManager.slabEnabled});$_M(c$,"slabByPixels",function(a){this.transformManager.slabByPercentagePoints(a);this.refresh(3,"slabByPixels")},"~N");
$_M(c$,"depthByPixels",function(a){this.transformManager.depthByPercentagePoints(a);this.refresh(3,"depthByPixels")},"~N");$_M(c$,"slabDepthByPixels",function(a){this.transformManager.slabDepthByPercentagePoints(a);this.refresh(3,"slabDepthByPixels")},"~N");$_M(c$,"slabInternal",function(a,b){this.transformManager.slabInternal(a,b)},"JU.P4,~B");$_M(c$,"slabToPercent",function(a){this.transformManager.slabToPercent(a)},"~N");$_M(c$,"depthToPercent",function(a){this.transformManager.depthToPercent(a)},
"~N");$_M(c$,"setSlabDepthInternal",function(a){this.transformManager.setSlabDepthInternal(a)},"~B");$_M(c$,"zValueFromPercent",function(a){return this.transformManager.zValueFromPercent(a)},"~N");Clazz.overrideMethod(c$,"getUnscaledTransformMatrix",function(){return this.transformManager.getUnscaledTransformMatrix()});$_M(c$,"finalizeTransformParameters",function(){this.transformManager.finalizeTransformParameters();this.gdata.setSlab(this.transformManager.slabValue);this.gdata.setDepth(this.transformManager.depthValue);
this.gdata.setZShade(this.transformManager.zShadeEnabled,this.transformManager.zSlabValue,this.transformManager.zDepthValue,this.global.zShadePower)});$_M(c$,"rotatePoint",function(a,b){this.transformManager.rotatePoint(a,b)},"JU.P3,JU.P3");$_M(c$,"transformPt",function(a){return this.transformManager.transformPoint(a)},"JU.P3");$_M(c$,"transformPtVib",function(a,b){return this.transformManager.transformPointVib(a,b)},"JU.P3,J.util.Vibration");$_M(c$,"transformPtScr",function(a,b){this.transformManager.transformPointScr(a,
b)},"JU.P3,JU.P3i");$_M(c$,"transformPtNoClip",function(a,b){this.transformManager.transformPointNoClip2(a,b)},"JU.P3,JU.P3");$_M(c$,"transformPt3f",function(a,b){this.transformManager.transformPoint2(a,b)},"JU.P3,JU.P3");$_M(c$,"transformPoints",function(a,b){this.transformManager.transformPoints(a.length,a,b)},"~A,~A");$_M(c$,"transformVector",function(a,b){this.transformManager.transformVector(a,b)},"JU.V3,JU.V3");$_M(c$,"unTransformPoint",function(a,b){this.transformManager.unTransformPoint(a,
b)},"JU.P3,JU.P3");$_M(c$,"getScalePixelsPerAngstrom",function(a){return this.transformManager.scalePixelsPerAngstrom*(a||!this.antialiasDisplay?1:0.5)},"~B");$_M(c$,"scaleToScreen",function(a,b){return this.transformManager.scaleToScreen(a,b)},"~N,~N");$_M(c$,"unscaleToScreen",function(a,b){return this.transformManager.unscaleToScreen(a,b)},"~N,~N");$_M(c$,"scaleToPerspective",function(a,b){return this.transformManager.scaleToPerspective(a,b)},"~N,~N");$_M(c$,"setSpin",function(a,b){if(J.util.Parser.isOneOf(a,
"x;y;z;fps;X;Y;Z;FPS")){var c="x;y;z;fps;X;Y;Z;FPS".indexOf(a);switch(c){case 0:this.transformManager.setSpinXYZ(b,NaN,NaN);break;case 2:this.transformManager.setSpinXYZ(NaN,b,NaN);break;case 4:this.transformManager.setSpinXYZ(NaN,NaN,b);break;default:this.transformManager.setSpinFps(b);break;case 10:this.transformManager.setNavXYZ(b,NaN,NaN);break;case 12:this.transformManager.setNavXYZ(NaN,b,NaN);break;case 14:this.transformManager.setNavXYZ(NaN,NaN,b);break;case 16:this.transformManager.setNavFps(b)}this.global.setI((10>
c?"spin":"nav")+a,b)}},"~S,~N");$_M(c$,"getSpinState",function(){return this.getStateCreator().getSpinState(!1)});$_M(c$,"setSpinOn",function(a){a?this.transformManager.setSpinOn():this.transformManager.setSpinOff()},"~B");$_M(c$,"getSpinOn",function(){return this.transformManager.getSpinOn()});$_M(c$,"setNavOn",function(a){this.transformManager.setNavOn(a)},"~B");$_M(c$,"getNavOn",function(){return this.transformManager.getNavOn()});$_M(c$,"setNavXYZ",function(a,b,c){this.transformManager.setNavXYZ(Clazz.floatToInt(a),
Clazz.floatToInt(b),Clazz.floatToInt(c))},"~N,~N,~N");$_M(c$,"getOrientationText",function(a,b){switch(a){case 1313866247:case 1073741863:case 1112541205:case 1112541206:case 1112541207:case 135270417:return this.modelSet.getBoundBoxOrientation(a,this.getSelectionSet(!1));case 1073742035:return this.stateManager.getSavedOrientationText(b);default:return this.transformManager.getOrientationText(a)}},"~N,~S");$_M(c$,"getOrientationInfo",function(){return this.transformManager.getOrientationInfo()});
$_M(c$,"getMatrixRotate",function(){return this.transformManager.getMatrixRotate()});$_M(c$,"getAxisAngle",function(a){this.transformManager.getAxisAngle(a)},"JU.A4");$_M(c$,"getTransformText",function(){return this.transformManager.getTransformText()});$_M(c$,"getRotation",function(a){this.transformManager.getRotation(a)},"JU.M3");$_M(c$,"getCurrentColorRange",function(){return this.colorManager.getPropertyColorRange()});$_M(c$,"setDefaultColors",($fz=function(a){this.colorManager.setDefaultColors(a);
this.global.setB("colorRasmol",a);this.global.setS("defaultColorScheme",a?"rasmol":"jmol")},$fz.isPrivate=!0,$fz),"~B");$_M(c$,"getColorArgbOrGray",function(a){return this.gdata.getColorArgbOrGray(a)},"~N");$_M(c$,"setRubberbandArgb",function(a){this.colorManager.setRubberbandArgb(a)},"~N");$_M(c$,"getColixRubberband",function(){return this.colorManager.colixRubberband});$_M(c$,"setElementArgb",function(a,b){this.global.setS("=color "+J.util.Elements.elementNameFromNumber(a),J.util.Escape.escapeColor(b));
this.colorManager.setElementArgb(a,b)},"~N,~N");Clazz.overrideMethod(c$,"setVectorScale",function(a){this.global.setF("vectorScale",a);this.global.vectorScale=a},"~N");$_M(c$,"isVibrationOn",function(){return this.transformManager.vibrationOn});Clazz.overrideMethod(c$,"setVibrationScale",function(a){this.transformManager.setVibrationScale(a);this.global.vibrationScale=a;this.global.setF("vibrationScale",a)},"~N");$_M(c$,"setVibrationOff",function(){this.transformManager.setVibrationPeriod(0)});Clazz.overrideMethod(c$,
"setVibrationPeriod",function(a){this.transformManager.setVibrationPeriod(a);a=Math.abs(a);this.global.vibrationPeriod=a;this.global.setF("vibrationPeriod",a)},"~N");$_M(c$,"setObjectColor",function(a,b){null==b||0==b.length||this.setObjectArgb(a,J.util.ColorUtil.getArgbFromString(b))},"~S,~S");$_M(c$,"setObjectVisibility",function(a,b){var c=J.viewer.StateManager.getObjectIdFromName(a);0<=c&&this.setShapeProperty(c,"display",b?Boolean.TRUE:Boolean.FALSE)},"~S,~B");$_M(c$,"setObjectArgb",function(a,
b){var c=J.viewer.StateManager.getObjectIdFromName(a);if(0>c)a.equalsIgnoreCase("axes")&&(this.setObjectArgb("axis1",b),this.setObjectArgb("axis2",b),this.setObjectArgb("axis3",b));else{this.global.objColors[c]=b;switch(c){case 0:this.gdata.setBackgroundArgb(b),this.colorManager.setColixBackgroundContrast(b)}this.global.setS(a+"Color",J.util.Escape.escapeColor(b))}},"~S,~N");$_M(c$,"setBackgroundImage",function(a,b){this.global.backgroundImageFileName=a;this.gdata.setBackgroundImage(b)},"~S,~O");
$_M(c$,"getObjectArgb",function(a){return this.global.objColors[a]},"~N");$_M(c$,"getObjectColix",function(a){a=this.getObjectArgb(a);return 0==a?this.getColixBackgroundContrast():J.util.C.getColix(a)},"~N");$_M(c$,"getFontState",function(a,b){return this.getStateCreator().getFontState(a,b)},"~S,J.util.JmolFont");Clazz.overrideMethod(c$,"setColorBackground",function(a){this.setObjectColor("background",a)},"~S");Clazz.overrideMethod(c$,"getBackgroundArgb",function(){return this.getObjectArgb(0)});
$_M(c$,"setObjectMad",function(a,b,c){var d=J.viewer.StateManager.getObjectIdFromName(b.equalsIgnoreCase("axes")?"axis":b);if(!(0>d)){if(-2==c||-4==c){var e=c+3;c=this.getObjectMad(d);0==c&&(c=e)}this.global.setB("show"+b,0!=c);this.global.objStateOn[d]=0!=c;0!=c&&(this.global.objMad[d]=c,this.setShapeSize(a,c,null))}},"~N,~S,~N");$_M(c$,"getObjectMad",function(a){return this.global.objStateOn[a]?this.global.objMad[a]:0},"~N");$_M(c$,"setPropertyColorScheme",function(a,b,c){this.global.propertyColorScheme=
a;a.startsWith("translucent ")&&(b=!0,a=a.substring(12).trim());this.colorManager.setPropertyColorScheme(a,b,c)},"~S,~B,~B");$_M(c$,"getPropertyColorScheme",function(){return this.global.propertyColorScheme});$_M(c$,"getColixBackgroundContrast",function(){return this.colorManager.colixBackgroundContrast});$_M(c$,"getSpecularState",function(){return this.getStateCreator().getSpecularState()});$_M(c$,"getColixAtomPalette",function(a,b){return this.colorManager.getColixAtomPalette(a,b)},"J.modelset.Atom,~N");
$_M(c$,"getColixBondPalette",function(a,b){return this.colorManager.getColixBondPalette(a,b)},"J.modelset.Bond,~N");$_M(c$,"getColorSchemeList",function(a){return this.colorManager.getColorSchemeList(a)},"~S");$_M(c$,"setUserScale",function(a){this.colorManager.setUserScale(a)},"~A");$_M(c$,"getColixForPropertyValue",function(a){return this.colorManager.getColixForPropertyValue(a)},"~N");$_M(c$,"getColorPointForPropertyValue",function(a){return J.util.ColorUtil.colorPointFromInt2(this.gdata.getColorArgbOrGray(this.colorManager.getColixForPropertyValue(a)))},
"~N");$_M(c$,"select",function(a,b,c,d){b&&(a=this.getUndeletedGroupAtomBits(a));this.selectionManager.select(a,c,d);this.shapeManager.setShapeSizeBs(1,2147483647,null,null)},"JU.BS,~B,~N,~B");Clazz.overrideMethod(c$,"setSelectionSet",function(a){this.select(a,!1,0,!0)},"JU.BS");$_M(c$,"selectBonds",function(a){this.shapeManager.setShapeSizeBs(1,2147483647,null,a)},"JU.BS");$_M(c$,"displayAtoms",function(a,b,c,d,e){c&&(a=this.getUndeletedGroupAtomBits(a));b?this.selectionManager.display(this.modelSet,
a,d,e):this.selectionManager.hide(this.modelSet,a,d,e)},"JU.BS,~B,~B,~N,~B");$_M(c$,"getUndeletedGroupAtomBits",($fz=function(a){a=this.getAtomBits(1087373318,a);J.util.BSUtil.andNot(a,this.selectionManager.getDeletedAtoms());return a},$fz.isPrivate=!0,$fz),"JU.BS");$_M(c$,"getHiddenSet",function(){return this.selectionManager.getHiddenSet()});$_M(c$,"isSelected",function(a){return this.selectionManager.isSelected(a)},"~N");$_M(c$,"isInSelectionSubset",function(a){return this.selectionManager.isInSelectionSubset(a)},
"~N");$_M(c$,"reportSelection",function(a){this.modelSet.getSelectionHaloEnabled()&&this.setTainted(!0);(this.isScriptQueued()||this.global.debugScript)&&this.scriptStatus(a)},"~S");$_M(c$,"getAtomSetCenter",function(a){return this.modelSet.getAtomSetCenter(a)},"JU.BS");$_M(c$,"clearAtomSets",($fz=function(){this.setSelectionSubset(null);this.definedAtomSets.clear()},$fz.isPrivate=!0,$fz));$_M(c$,"getDefinedAtomSet",function(a){a=this.definedAtomSets.get(a.toLowerCase());return Clazz.instanceOf(a,
JU.BS)?a:new JU.BS},"~S");Clazz.overrideMethod(c$,"selectAll",function(){this.selectionManager.selectAll(!1)});$_M(c$,"setNoneSelected",function(a){this.noneSelected=a},"~B");$_M(c$,"getNoneSelected",function(){return this.noneSelected?Boolean.TRUE:Boolean.FALSE});Clazz.overrideMethod(c$,"clearSelection",function(){this.selectionManager.clearSelection(!0);this.global.setB("hideNotSelected",!1)});$_M(c$,"setSelectionSubset",function(a){this.selectionManager.setSelectionSubset(a)},"JU.BS");$_M(c$,"getSelectionSubset",
function(){return this.selectionManager.getSelectionSubset()});$_M(c$,"invertSelection",function(){this.selectionManager.invertSelection()});$_M(c$,"getSelectionSet",function(a){return this.selectionManager.getSelectionSet(a)},"~B");$_M(c$,"setSelectedAtom",function(a,b){this.selectionManager.setSelectedAtom(a,b)},"~N,~B");$_M(c$,"isAtomSelected",function(a){return this.selectionManager.isAtomSelected(a)},"~N");Clazz.overrideMethod(c$,"getSelectionCount",function(){return this.selectionManager.getSelectionCount()});
$_M(c$,"setFormalCharges",function(a){this.modelSet.setFormalCharges(this.getSelectionSet(!1),a)},"~N");Clazz.overrideMethod(c$,"addSelectionListener",function(a){this.selectionManager.addListener(a)},"J.api.JmolSelectionListener");Clazz.overrideMethod(c$,"removeSelectionListener",function(a){this.selectionManager.addListener(a)},"J.api.JmolSelectionListener");$_M(c$,"getAtomBitSetEval",function(a,b){return!this.allowScripting?(System.out.println("viewer.getAtomBitSetEval not allowed"),new JU.BS):
this.getScriptManager().getAtomBitSetEval(a,b)},"J.api.JmolScriptEvaluator,~O");Clazz.overrideMethod(c$,"setModeMouse",function(a){if(-1==a){null!=this.mouse&&this.disposeMouse();this.clearScriptQueue();this.clearThreads();this.haltScriptExecution();null!=this.scriptManager&&this.scriptManager.clear(!0);this.gdata.destroy();null!=this.jmolpopup&&this.jmolpopup.jpiDispose();null!=this.modelkitPopup&&this.modelkitPopup.jpiDispose();try{null!=this.appConsole&&(this.appConsole.dispose(),this.appConsole=
null),null!=this.scriptEditor&&(this.scriptEditor.dispose(),this.scriptEditor=null)}catch(b){if(!Clazz.exceptionOf(b,Exception))throw b;}}},"~N");$_M(c$,"getRubberBandSelection",function(){return this.haveDisplay?this.actionManager.getRubberBand():null});$_M(c$,"isBound",function(a,b){return this.haveDisplay&&this.actionManager.isBound(a,b)},"~N,~N");$_M(c$,"getCursorX",function(){return this.haveDisplay?this.actionManager.getCurrentX():0});$_M(c$,"getCursorY",function(){return this.haveDisplay?this.actionManager.getCurrentY():
0});$_M(c$,"getDefaultDirectory",function(){return this.global.defaultDirectory});$_M(c$,"getLocalUrl",function(a){return this.fileManager.getLocalUrl(a)},"~S");Clazz.overrideMethod(c$,"getBufferedInputStream",function(a){return this.fileManager.getBufferedInputStream(a)},"~S");$_M(c$,"getBufferedReaderOrErrorMessageFromName",function(a,b,c){return this.fileManager.getBufferedReaderOrErrorMessageFromName(a,b,c,!0)},"~S,~A,~B");$_M(c$,"setLoadParameters",($fz=function(a,b){null==a&&(a=new java.util.Hashtable);
a.put("viewer",this);0<this.global.atomTypes.length&&a.put("atomTypes",this.global.atomTypes);a.containsKey("lattice")||a.put("lattice",this.global.getDefaultLattice());this.global.applySymmetryToBonds&&a.put("applySymmetryToBonds",Boolean.TRUE);this.global.pdbGetHeader&&a.put("getHeader",Boolean.TRUE);this.global.pdbSequential&&a.put("isSequential",Boolean.TRUE);a.put("stateScriptVersionInt",Integer.$valueOf(this.stateScriptVersionInt));if(!a.containsKey("filter")){var c=this.getDefaultLoadFilter();
0<c.length&&a.put("filter",c)}c=b&&!this.global.appendNew&&0<this.getAtomCount();a.put("baseAtomIndex",Integer.$valueOf(b?this.getAtomCount():0));a.put("baseModelIndex",Integer.$valueOf(0==this.getAtomCount()?0:this.getModelCount()+(c?-1:0)));c&&a.put("merging",Boolean.TRUE);return a},$fz.isPrivate=!0,$fz),"java.util.Map,~B");Clazz.overrideMethod(c$,"openFileAsyncPDB",function(a,b){this.getScriptManager().openFileAsync(a,b)},"~S,~B");Clazz.overrideMethod(c$,"openFile",function(a){this.zap(!0,!0,!1);
return this.loadModelFromFileRepaint(null,a,null,null)},"~S");Clazz.overrideMethod(c$,"openFiles",function(a){this.zap(!0,!0,!1);return this.loadModelFromFileRepaint(null,null,a,null)},"~A");Clazz.overrideMethod(c$,"openReader",function(a,b,c){this.zap(!0,!0,!1);return this.loadModelFromFileRepaint(a,b,null,c)},"~S,~S,java.io.Reader");Clazz.overrideMethod(c$,"openDOM",function(a){this.zap(!0,!0,!1);return this.loadModelFromFileRepaint("?","?",null,a)},"~O");$_M(c$,"loadModelFromFileRepaint",($fz=
function(a,b,c,d){a=this.loadModelFromFile(a,b,c,d,!1,null,null,0);this.refresh(1,"loadModelFromFileRepaint");return a},$fz.isPrivate=!0,$fz),"~S,~S,~A,~O");$_M(c$,"loadModelFromFile",function(a,b,c,d,e,f,g,h){null==f&&(f=this.setLoadParameters(null,e));var k=this.fileManager.getFileInfo();if(null!=c){if(null==g){g=(new JU.SB).append("load files");for(b=0;b<c.length;b++)g.append(" /*file*/$FILENAME"+(b+1)+"$")}b=System.currentTimeMillis();a=this.fileManager.createAtomSetCollectionFromFiles(c,this.setLoadParameters(f,
e),e);d=System.currentTimeMillis()-b;for(b=0;b<c.length;b++);J.util.Logger.info("openFiles("+c.length+") "+d+" ms");c=f.get("fullPathNames");d=f.get("fileTypes");g=g.toString();for(b=0;b<c.length;b++){var l=c[b];null!=d&&null!=d[b]&&(l=d[b]+"::"+l);g=J.util.Txt.simpleReplace(g,"$FILENAME"+(b+1)+"$",J.util.Escape.eS(l.$replace("\\","/")))}g=(new JU.SB).append(g)}else null==d?(null==g&&(g=(new JU.SB).append("load /*file*/$FILENAME$")),a=this.openFileFull(b,e,f,g)):a=Clazz.instanceOf(d,java.io.Reader)?
this.fileManager.createAtomSetCollectionFromReader(a,b,d,f):this.fileManager.createAtomSetCollectionFromDOM(d,f);if(0!=h)return this.fileManager.setFileInfo(k),this.loadAtomDataAndReturnError(a,h);if(f.containsKey("isData"))return a;null!=g&&(l=f.get("fullPathName"),null==l&&(l=""),f.containsKey("loadScript")&&(g=f.get("loadScript")),f.put("loadScript",g=(new JU.SB).append(J.util.Txt.simpleReplace(g.toString(),"$FILENAME$",J.util.Escape.eS(l.$replace("\\","/"))))));return this.createModelSetAndReturnError(a,
e,g,f)},"~S,~S,~A,~O,~B,java.util.Map,JU.SB,~N");$_M(c$,"setLigandModel",function(a,b){null==this.ligandModels&&(this.ligandModels=new java.util.Hashtable);this.ligandModels.put(a,b)},"~S,~S");$_M(c$,"getLigandModel",function(a,b,c,d){if(null==a){if(null!=this.ligandModelSet)for(a=this.ligandModels.entrySet().iterator();a.hasNext();){var e=a.next();Clazz.instanceOf(e.getValue(),Boolean)&&a.remove()}return null}var f=b.equals("ligand_");f&&(a=a.toUpperCase());null==this.ligandModelSet&&(this.ligandModelSet=
new java.util.Hashtable);this.ligandModelSet.put(a,Boolean.TRUE);null==this.ligandModels&&(this.ligandModels=new java.util.Hashtable);var g=this.ligandModels.get(a),e=null;if(Clazz.instanceOf(g,Boolean))return null;null==g&&(g=this.ligandModels.get(a+c));var h=!1;if(null==g){if(f){e=this.setLoadFormat("#"+a,"#",!1);if(0==e.length)return null;this.scriptEcho("fetching "+e);g=this.getFileAsString(e)}else g=this.getFileAsString(b),h=null==d?-1:g.indexOf(d),0<=h&&(g=g.substring(0,h));(h=0==g.indexOf("java."))||
this.ligandModels.put(a+c,g)}if(!f)return g;!h&&Clazz.instanceOf(g,String)&&(c=g,0!=c.length&&(f=new java.util.Hashtable,f.put("modelOnly",Boolean.TRUE),g=this.getModelAdapter().getAtomSetCollectionReader("ligand",null,J.io.JmolBinary.getBufferedReaderForString(c),f),h=Clazz.instanceOf(g,String),h||(g=this.getModelAdapter().getAtomSetCollection(g),h=Clazz.instanceOf(g,String),null!=e&&!h&&this.scriptEcho(this.getModelAdapter().getAtomSetCollectionAuxiliaryInfo(g).get("modelLoadNote")))));return h?
(this.scriptEcho(g.toString()),this.ligandModels.put(a,Boolean.FALSE),null):g},"~S,~S,~S,~S");$_M(c$,"openFileFull",($fz=function(a,b,c,d){if(null==a||0<=a.indexOf("[]"))return null;var e="openFile("+a+")";J.util.Logger.startTimer(e);c=this.setLoadParameters(c,b);var f=a.startsWith("@"),g=c.containsKey("fileData");0==a.indexOf("$")&&c.put("smilesString",a.substring(1));var h=a.equalsIgnoreCase("string")||a.equals("Jmol Model Kit"),k=null;if(g){if(k=c.get("fileData"),c.containsKey("isData"))return this.loadInlineScript(k,
"\x00",b,c)}else if(h){k=this.modelSet.getInlineData(-1);if(null==k)if(this.global.modelKitMode)k="5\n\nC 0 0 0\nH .63 .63 .63\nH -.63 -.63 .63\nH -.63 .63 -.63\nH .63 -.63 -.63";else return"cannot find string data";null!=d&&c.put("loadScript",d=(new JU.SB).append(J.util.Txt.simpleReplace(d.toString(),"$FILENAME$",'data "model inline"\n'+k+'end "model inline"')))}null!=k?(b||this.zap(!0,!1,!1),a=this.fileManager.createAtomSetCollectionFromString(k,d,c,b,f||g&&!h)):a=this.fileManager.createAtomSetCollectionFromFile(a,
c,b);J.util.Logger.checkTimer(e,!1);return a},$fz.isPrivate=!0,$fz),"~S,~B,java.util.Map,JU.SB");Clazz.overrideMethod(c$,"openStringInline",function(a){a=this.openStringInlineParamsAppend(a,null,!1);this.refresh(1,"openStringInline");return a},"~S");$_M(c$,"loadInline",function(a){return this.loadInlineScriptRepaint(a,this.global.inlineNewlineChar,!1)},"~S");$_M(c$,"loadInline",function(a,b){return this.loadInlineScriptRepaint(a,b,!1)},"~S,~S");Clazz.overrideMethod(c$,"loadInlineAppend",function(a,
b){return this.loadInlineScriptRepaint(a,"\x00",b)},"~S,~B");$_M(c$,"loadInlineScriptRepaint",($fz=function(a,b,c){a=this.loadInlineScript(a,b,c,null);this.refresh(1,"loadInlineScript");return a},$fz.isPrivate=!0,$fz),"~S,~S,~B");$_M(c$,"loadInline",function(a){return this.loadInline(a,!1)},"~A");$_M(c$,"loadInline",function(a,b){if(null==a||0==a.length)return null;var c=this.openStringsInlineParamsAppend(a,null,b);this.refresh(1,"loadInline String[]");return c},"~A,~B");$_M(c$,"loadInline",function(a,
b){if(null==a||0==a.size())return null;b||this.zap(!0,!1,!1);for(var c=new JU.List,d=0;d<a.size();d++)c.addLast(a.get(d));c=this.fileManager.createAtomSeCollectionFromArrayData(c,this.setLoadParameters(null,b),b);c=this.createModelSetAndReturnError(c,b,null,null);this.refresh(1,"loadInline");return c},"java.util.List,~B");$_M(c$,"loadInlineScript",($fz=function(a,b,c,d){if(null==a||0==a.length)return null;a=J.viewer.Viewer.fixInlineString(a,b);0!=b.charCodeAt(0)&&J.util.Logger.info("loading model inline, "+
a.length+" bytes, with newLine character "+b.charCodeAt(0)+" isAppend="+c);J.util.Logger.debugging&&J.util.Logger.debug(a);b=this.getDataSeparator();var e;if(null!=b&&""!==b&&0<=(e=a.indexOf(b))&&0>a.indexOf("# Jmol state")){for(var f=2;0<=(e=a.indexOf(b,e+1));)f++;var g=Array(f),h=0,k=0;for(e=0;e<f;e++)h=a.indexOf(b,k),0>h&&(h=a.length),g[e]=a.substring(k,h),k=h+b.length;return this.openStringsInlineParamsAppend(g,d,c)}return this.openStringInlineParamsAppend(a,d,c)},$fz.isPrivate=!0,$fz),"~S,~S,~B,java.util.Map");
c$.fixInlineString=$_M(c$,"fixInlineString",function(a,b){var c;0<=a.indexOf("\\/n")&&(a=J.util.Txt.simpleReplace(a,"\n",""),a=J.util.Txt.simpleReplace(a,"\\/n","\n"),b=String.fromCharCode(0));if(0!=b.charCodeAt(0)&&"\n"!=b){var d=0<=a.indexOf("\n"),e=a.length;for(c=0;c<e&&" "==a.charAt(c);++c);c<e&&a.charAt(c)==b&&(a=a.substring(c+1));a=d?J.util.Txt.simpleReplace(a,""+b,""):a.$replace(b,"\n")}return a},"~S,~S");$_M(c$,"openStringInlineParamsAppend",function(a,b,c){var d=new java.io.BufferedReader(new java.io.StringReader(a)),
d=this.getModelAdapter().getFileTypeName(d);if(null==d)return"unknown file type";if(d.equals("spt"))return"cannot open script inline";b=this.setLoadParameters(b,c);var d=b.get("loadScript"),e=b.containsKey("isData");null==d&&(d=new JU.SB);c||this.zap(!0,!1,!1);a=this.fileManager.createAtomSetCollectionFromString(a,d,b,c,e);return this.createModelSetAndReturnError(a,c,d,null)},"~S,java.util.Map,~B");$_M(c$,"openStringsInlineParamsAppend",($fz=function(a,b,c){var d=new JU.SB;c||this.zap(!0,!1,!1);a=
this.fileManager.createAtomSeCollectionFromStrings(a,d,this.setLoadParameters(b,c),c);return this.createModelSetAndReturnError(a,c,d,null)},$fz.isPrivate=!0,$fz),"~A,java.util.Map,~B");$_M(c$,"getInlineChar",function(){return this.global.inlineNewlineChar});$_M(c$,"getDataSeparator",function(){return this.global.getParameter("dataseparator")});$_M(c$,"createModelSetAndReturnError",($fz=function(a,b,c,d){var e=this.fileManager.getFullPathName(),f=this.fileManager.getFileName();null==c&&(this.setBooleanProperty("preserveState",
!1),c=(new JU.SB).append('load "???"'));if(Clazz.instanceOf(a,String))return this.setFileLoadStatus(J.constant.EnumFileStatus.NOT_LOADED,e,null,null,a,null),this.displayLoadErrors&&(!b&&!a.equals("#CANCELED#"))&&this.zapMsg(a),a;b?this.clearAtomSets():this.global.modelKitMode&&!f.equals("Jmol Model Kit")&&this.setModelKitMode(!1);this.setFileLoadStatus(J.constant.EnumFileStatus.CREATING_MODELSET,e,f,null,null,null);this.pushHoldRepaint("createModelSet");this.setErrorMessage(null,null);try{var g=new JU.BS;
this.modelManager.createModelSet(e,f,c,a,g,b);if(0<g.cardinality()){var h=this.modelSet.getModelSetAuxiliaryInfoValue("jmolscript");this.modelSet.getModelSetAuxiliaryInfoBoolean("doMinimize")?this.minimize(2147483647,0,g,null,0,!0,!0,!0):this.addHydrogens(g,!1,!0);null!=h&&this.modelSet.getModelSetAuxiliaryInfo().put("jmolscript",h)}this.initializeModel(b)}catch(k){if(Clazz.exceptionOf(k,Error))this.handleError(k,!0),a=this.getShapeErrorState(),a="ERROR creating model: "+k+(0==a.length?"":"|"+a),
this.zapMsg(a),this.setErrorMessage(a,null);else throw k;}this.popHoldRepaint("createModelSet \u0001## REPAINT_IGNORE ##");a=this.getErrorMessage();this.setFileLoadStatus(J.constant.EnumFileStatus.CREATED,e,f,this.getModelSetName(),a,null==d?null:d.get("async"));b&&(this.selectAll(),this.setTainted(!0),this.axesAreTainted=!0);System.gc();return a},$fz.isPrivate=!0,$fz),"~O,~B,JU.SB,java.util.Map");$_M(c$,"loadAtomDataAndReturnError",($fz=function(a,b){if(Clazz.instanceOf(a,String))return a;this.setErrorMessage(null,
null);try{switch(this.modelManager.createAtomDataSet(a,b),b){case 4166:this.setStatusFrameChanged(!0);break;case 1649412120:this.shapeManager.deleteVdwDependentShapes(null)}}catch(c){if(Clazz.exceptionOf(c,Error)){this.handleError(c,!0);var d=this.getShapeErrorState(),d="ERROR adding atom data: "+c+(0==d.length?"":"|"+d);this.zapMsg(d);this.setErrorMessage(d,null);this.setParallel(!1)}else throw c;}return this.getErrorMessage()},$fz.isPrivate=!0,$fz),"~O,~N");Clazz.overrideMethod(c$,"getEmbeddedFileState",
function(a){return this.fileManager.getEmbeddedFileState(a)},"~S");Clazz.overrideMethod(c$,"getFileAsBytes",function(a,b){return this.fileManager.getFileAsBytes(a,b,!0)},"~S,J.io.JmolOutputChannel");$_M(c$,"getCurrentFileAsString",function(){var a=this.getFullPathName();if(a.equals("string")||a.equals("Jmol Model Kit"))return this.modelSet.getInlineData(this.getCurrentModelIndex());if(0<=a.indexOf("[]"))return a;if("JSNode"===a)return"<DOM NODE>";a=this.modelManager.getModelSetPathName();return null==
a?null:this.getFileAsString4(a,-1,!0,!1)});$_M(c$,"getFullPathName",function(){return this.fileManager.getFullPathName()});$_M(c$,"getFileName",function(){return this.fileManager.getFileName()});$_M(c$,"getFullPathNameOrError",function(a){return this.fileManager.getFullPathNameOrError(a)},"~S");Clazz.overrideMethod(c$,"getFileAsString",function(a){return this.getFileAsString4(a,-1,!1,!1)},"~S");$_M(c$,"getFileAsString4",function(a,b,c,d){if(null==a)return this.getCurrentFileAsString();var e=Array(2);
e[0]=a;this.fileManager.getFileDataOrErrorAsString(e,b,c,d);return e[1]},"~S,~N,~B,~B");$_M(c$,"getFileAsStringBin",function(a){return this.fileManager.getFileDataOrErrorAsString(a,-1,!1,!0)},"~A");$_M(c$,"getFilePath",function(a,b){return this.fileManager.getFilePath(a,!1,b)},"~S,~B");$_M(c$,"getFileInfo",function(){return this.fileManager.getFileInfo()});$_M(c$,"setFileInfo",function(a){this.fileManager.setFileInfo(a)},"~A");$_M(c$,"autoCalculate",function(a){switch(a){case 1112539151:this.modelSet.getSurfaceDistanceMax();
break;case 1112539150:this.modelSet.calculateStraightness()}},"~N");$_M(c$,"getSurfaceDistanceMax",function(){return this.modelSet.getSurfaceDistanceMax()});$_M(c$,"calculateStraightness",function(){this.modelSet.setHaveStraightness(!1);this.modelSet.calculateStraightness()});$_M(c$,"calculateSurface",function(a,b){null==a&&(a=this.getSelectionSet(!1));if(3.4028235E38==b||-1==b)this.addStateScriptRet("calculate surfaceDistance "+(3.4028235E38==b?"FROM":"WITHIN"),null,a,null,"",!1,!0);return this.modelSet.calculateSurface(a,
b)},"JU.BS,~N");$_M(c$,"getStructureList",function(){return this.global.getStructureList()});$_M(c$,"setStructureList",function(a,b){this.global.setStructureList(a,b);this.modelSet.setStructureList(this.getStructureList())},"~A,J.constant.EnumStructure");$_M(c$,"getDefaultStructure",function(a,b){null==a&&(a=this.getSelectionSet(!1));return this.modelSet.getDefaultStructure(a,b)},"JU.BS,JU.BS");$_M(c$,"calculateStructures",function(a,b,c){null==a&&(a=this.getSelectionSet(!1));return this.modelSet.calculateStructures(a,
b,this.global.dsspCalcHydrogen,c)},"JU.BS,~B,~B");Clazz.overrideMethod(c$,"getSelectedAtomIterator",function(a,b,c,d){return this.modelSet.getSelectedAtomIterator(a,b,c,!1,d)},"JU.BS,~B,~B,~B");Clazz.overrideMethod(c$,"setIteratorForAtom",function(a,b,c){this.modelSet.setIteratorForAtom(a,-1,b,c,null)},"J.api.AtomIndexIterator,~N,~N");Clazz.overrideMethod(c$,"setIteratorForPoint",function(a,b,c,d){this.modelSet.setIteratorForPoint(a,b,c,d)},"J.api.AtomIndexIterator,~N,JU.P3,~N");Clazz.overrideMethod(c$,
"fillAtomData",function(a,b){a.programInfo="Jmol Version "+J.viewer.Viewer.getJmolVersion();a.fileName=this.getFileName();this.modelSet.fillAtomData(a,b)},"J.atomdata.AtomData,~N");$_M(c$,"addStateScript",function(a,b,c){return this.addStateScriptRet(a,null,null,null,null,b,c)},"~S,~B,~B");$_M(c$,"addStateScriptRet",function(a,b,c,d,e,f,g){return this.modelSet.addStateScript(a,b,c,d,e,f,g)},"~S,JU.BS,JU.BS,JU.BS,~S,~B,~B");$_M(c$,"getEchoStateActive",function(){return this.modelSet.getEchoStateActive()});
$_M(c$,"setEchoStateActive",function(a){this.modelSet.setEchoStateActive(a)},"~B");$_M(c$,"clearModelDependentObjects",($fz=function(){this.setFrameOffsets(null);this.stopMinimization();this.minimizer=null;null!=this.smilesMatcher&&(this.smilesMatcher=null);null!=this.symmetry&&(this.symmetry=null)},$fz.isPrivate=!0,$fz));$_M(c$,"zap",function(a,b,c){this.clearThreads();null!=this.modelSet?(this.ligandModelSet=null,this.clearModelDependentObjects(),this.fileManager.clear(),this.clearRepaintManager(-1),
this.animationManager.clear(),this.transformManager.clear(),this.selectionManager.clear(),this.clearAllMeasurements(),this.clearMinimization(),this.gdata.clear(),this.modelManager.zap(),null!=this.scriptManager&&this.scriptManager.clear(!1),null!=this.nmrCalculation&&this.getNMRCalculation().setChemicalShiftReference(null,0),this.haveDisplay&&(this.mouse.clear(),this.clearTimeouts(),this.actionManager.clear()),this.stateManager.clear(this.global),this.tempArray.clear(),this.chainMap.clear(),this.chainList.clear(),
this.colorManager.clear(),this.definedAtomSets.clear(),this.dataManager.clear(),b&&(c&&this.global.modelKitMode&&(this.openStringInlineParamsAppend("5\n\nC 0 0 0\nH .63 .63 .63\nH -.63 -.63 .63\nH -.63 .63 -.63\nH .63 -.63 -.63",null,!0),this.setRotationRadius(5,!0),this.setStringProperty("picking","assignAtom_C"),this.setStringProperty("picking","assignBond_p")),this.undoClear()),System.gc()):this.modelManager.zap();this.initializeModel(!1);a&&this.setFileLoadStatus(J.constant.EnumFileStatus.ZAPPED,
null,b?"resetUndo":this.getZapName(),null,null,null);J.util.Logger.debugging&&J.util.Logger.checkMemory()},"~B,~B,~B");$_M(c$,"zapMsg",($fz=function(a){this.zap(!0,!0,!1);this.echoMessage(a)},$fz.isPrivate=!0,$fz),"~S");$_M(c$,"echoMessage",function(a){this.loadShape(30);this.setShapeProperty(30,"font",this.getFont3D("SansSerif","Plain",9));this.setShapeProperty(30,"target","error");this.setShapeProperty(30,"text",a)},"~S");$_M(c$,"initializeModel",($fz=function(a){this.clearThreads();a?this.animationManager.initializePointers(1):
(this.reset(!0),this.selectAll(),this.rotatePrev1=this.rotateBondIndex=-1,this.noneSelected=this.movingSelected=!1,this.hoverEnabled=!0,this.transformManager.setCenter(),this.animationManager.initializePointers(1),this.modelSet.getModelSetAuxiliaryInfoBoolean("isPyMOL")||(this.clearAtomSets(),this.setCurrentModelIndex(0)),this.setBackgroundModelIndex(-1),this.setFrankOn(this.getShowFrank()),this.startHoverWatcher(!0),this.setTainted(!0),this.finalizeTransformParameters())},$fz.isPrivate=!0,$fz),"~B");
Clazz.overrideMethod(c$,"startHoverWatcher",function(a){this.haveDisplay&&(!a||this.hoverEnabled&&!this.animationManager.animationOn)&&this.actionManager.startHoverWatcher(a)},"~B");Clazz.overrideMethod(c$,"getModelSetName",function(){return null==this.modelSet?null:this.modelSet.modelSetName});Clazz.overrideMethod(c$,"getModelSetFileName",function(){return this.modelManager.getModelSetFileName()});$_M(c$,"getUnitCellInfoText",function(){return this.modelSet.getUnitCellInfoText()});$_M(c$,"getUnitCellInfo",
function(a){var b=this.getCurrentUnitCell();return null==b?NaN:b.getUnitCellInfoType(a)},"~N");$_M(c$,"getSpaceGroupInfo",function(a){return this.modelSet.getSymTemp(!0).getSpaceGroupInfo(this.modelSet,-1,a,0,null,null,null)},"~S");$_M(c$,"getPolymerPointsAndVectors",function(a,b){this.modelSet.getPolymerPointsAndVectors(a,b,this.global.traceAlpha,this.global.sheetSmoothing)},"JU.BS,JU.List");$_M(c$,"getModelSetProperty",function(a){return this.modelSet.getModelSetProperty(a)},"~S");$_M(c$,"getModelSetAuxiliaryInfoValue",
function(a){return this.modelSet.getModelSetAuxiliaryInfoValue(a)},"~S");Clazz.overrideMethod(c$,"getModelSetPathName",function(){return this.modelManager.getModelSetPathName()});$_M(c$,"getModelSetTypeName",function(){return this.modelSet.getModelSetTypeName()});Clazz.overrideMethod(c$,"haveFrame",function(){return this.haveModelSet()});$_M(c$,"haveModelSet",function(){return null!=this.modelSet});$_M(c$,"clearBfactorRange",function(){this.modelSet.clearBfactorRange()});$_M(c$,"getHybridizationAndAxes",
function(a,b,c,d){return this.modelSet.getHybridizationAndAxes(a,0,b,c,d,!0,!0)},"~N,JU.V3,JU.V3,~S");$_M(c$,"getMoleculeBitSet",function(a){return this.modelSet.getMoleculeBitSetForAtom(a)},"~N");$_M(c$,"getModelUndeletedAtomsBitSet",function(a){a=this.modelSet.getModelAtomBitSetIncludingDeleted(a,!0);this.excludeAtoms(a,!1);return a},"~N");$_M(c$,"getModelBitSet",function(a,b){return this.modelSet.getModelBitSet(a,b)},"JU.BS,~B");$_M(c$,"getModelUndeletedAtomsBitSetBs",function(a){a=this.modelSet.getModelAtomBitSetIncludingDeletedBs(a);
this.excludeAtoms(a,!1);return a},"JU.BS");$_M(c$,"excludeAtoms",function(a,b){this.selectionManager.excludeAtoms(a,b)},"JU.BS,~B");$_M(c$,"getModelSet",function(){return this.modelSet});$_M(c$,"getBoundBoxCommand",function(a){return this.modelSet.getBoundBoxCommand(a)},"~B");$_M(c$,"setBoundBox",function(a,b,c,d){this.modelSet.setBoundBox(a,b,c,d)},"JU.P3,JU.P3,~B,~N");Clazz.overrideMethod(c$,"getBoundBoxCenter",function(){return this.modelSet.getBoundBoxCenter(this.animationManager.currentModelIndex)});
$_M(c$,"getAverageAtomPoint",function(){return this.modelSet.getAverageAtomPoint()});$_M(c$,"calcBoundBoxDimensions",function(a,b){this.modelSet.calcBoundBoxDimensions(a,b);this.axesAreTainted=!0},"JU.BS,~N");$_M(c$,"getBoxInfo",function(a,b){return this.modelSet.getBoxInfo(a,b)},"JU.BS,~N");$_M(c$,"calcRotationRadius",function(a){return this.modelSet.calcRotationRadius(this.animationManager.currentModelIndex,a)},"JU.P3");$_M(c$,"calcRotationRadiusBs",function(a){return this.modelSet.calcRotationRadiusBs(a)},
"JU.BS");Clazz.overrideMethod(c$,"getBoundBoxCornerVector",function(){return this.modelSet.getBoundBoxCornerVector()});$_M(c$,"getBoundBoxVertices",function(){return this.modelSet.getBboxVertices()});$_M(c$,"getBoundBoxInfo",function(){return this.modelSet.getBoundBoxInfo()});$_M(c$,"getBoundBoxModels",function(){return this.modelSet.getBoundBoxModels()});$_M(c$,"getBoundBoxCenterX",function(){return Clazz.doubleToInt(this.dimScreen.width/2)});$_M(c$,"getBoundBoxCenterY",function(){return Clazz.doubleToInt(this.dimScreen.height/
2)});Clazz.overrideMethod(c$,"getModelCount",function(){return null==this.modelSet?0:this.modelSet.modelCount});$_M(c$,"getModelInfoAsString",function(){return this.modelSet.getModelInfoAsString()});$_M(c$,"getSymmetryInfoAsString",function(){return this.modelSet.getSymmetryInfoAsString()});$_M(c$,"getSymmetryOperation",function(a,b,c,d,e){return this.modelSet.getSymmetryOperation(this.animationManager.currentModelIndex,a,b,c,d,null,e)},"~S,~N,JU.P3,JU.P3,~B");Clazz.overrideMethod(c$,"getModelSetProperties",
function(){return this.modelSet.getModelSetProperties()});Clazz.overrideMethod(c$,"getModelSetAuxiliaryInfo",function(){return this.modelSet.getModelSetAuxiliaryInfo()});Clazz.overrideMethod(c$,"getModelNumber",function(a){return 0>a?a:this.modelSet.getModelNumber(a)},"~N");$_M(c$,"getModelFileNumber",function(a){return 0>a?0:this.modelSet.getModelFileNumber(a)},"~N");Clazz.overrideMethod(c$,"getModelNumberDotted",function(a){return 0>a?"0":null==this.modelSet?null:this.modelSet.getModelNumberDotted(a)},
"~N");Clazz.overrideMethod(c$,"getModelName",function(a){return null==this.modelSet?null:this.modelSet.getModelName(a)},"~N");Clazz.overrideMethod(c$,"getModelProperties",function(a){return this.modelSet.getModelProperties(a)},"~N");Clazz.overrideMethod(c$,"getModelProperty",function(a,b){return this.modelSet.getModelProperty(a,b)},"~N,~S");$_M(c$,"getModelFileInfo",function(){return this.getPropertyManager().getModelFileInfo(this.getVisibleFramesBitSet())});$_M(c$,"getModelFileInfoAll",function(){return this.getPropertyManager().getModelFileInfo(null)});
Clazz.overrideMethod(c$,"getModelAuxiliaryInfo",function(a){return this.modelSet.getModelAuxiliaryInfo(a)},"~N");Clazz.overrideMethod(c$,"getModelAuxiliaryInfoValue",function(a,b){return this.modelSet.getModelAuxiliaryInfoValue(a,b)},"~N,~S");$_M(c$,"getModelNumberIndex",function(a,b,c){return this.modelSet.getModelNumberIndex(a,b,c)},"~N,~B,~B");$_M(c$,"modelSetHasVibrationVectors",function(){return this.modelSet.modelSetHasVibrationVectors()});Clazz.overrideMethod(c$,"modelGetLastVibrationIndex",
function(a,b){return this.modelSet.getLastVibrationVector(a,b)},"~N,~N");Clazz.overrideMethod(c$,"modelHasVibrationVectors",function(a){return 0<=this.modelSet.getLastVibrationVector(a,4166)},"~N");Clazz.overrideMethod(c$,"getChainCount",function(){return this.modelSet.getChainCount(!0)});Clazz.overrideMethod(c$,"getChainCountInModel",function(a){return this.modelSet.getChainCountInModel(a,!1)},"~N");$_M(c$,"getChainCountInModelWater",function(a,b){return this.modelSet.getChainCountInModel(a,b)},
"~N,~B");Clazz.overrideMethod(c$,"getGroupCount",function(){return this.modelSet.getGroupCount()});Clazz.overrideMethod(c$,"getGroupCountInModel",function(a){return this.modelSet.getGroupCountInModel(a)},"~N");Clazz.overrideMethod(c$,"getPolymerCount",function(){return this.modelSet.getBioPolymerCount()});Clazz.overrideMethod(c$,"getPolymerCountInModel",function(a){return this.modelSet.getBioPolymerCountInModel(a)},"~N");Clazz.overrideMethod(c$,"getAtomCount",function(){return this.modelSet.getAtomCount()});
Clazz.overrideMethod(c$,"getAtomCountInModel",function(a){return this.modelSet.getAtomCountInModel(a)},"~N");Clazz.overrideMethod(c$,"getBondCount",function(){return this.modelSet.bondCount});Clazz.overrideMethod(c$,"getBondCountInModel",function(a){return this.modelSet.getBondCountInModel(a)},"~N");$_M(c$,"getBondsForSelectedAtoms",function(a){return this.modelSet.getBondsForSelectedAtoms(a,this.global.bondModeOr||1==J.util.BSUtil.cardinalityOf(a))},"JU.BS");$_M(c$,"frankClicked",function(a,b){return!this.global.disablePopupMenu&&
this.getShowFrank()&&this.shapeManager.checkFrankclicked(a,b)},"~N,~N");$_M(c$,"frankClickedModelKit",function(a,b){return!this.global.disablePopupMenu&&this.global.modelKitMode&&0<=a&&0<=b&&40>a&&80>b},"~N,~N");Clazz.overrideMethod(c$,"findNearestAtomIndex",function(a,b){return this.findNearestAtomIndexMovable(a,b,!1)},"~N,~N");$_M(c$,"findNearestAtomIndexMovable",function(a,b,c){return null==this.modelSet||!this.global.atomPicking?-1:this.modelSet.findNearestAtomIndex(a,b,c?this.selectionManager.getMotionFixedAtoms():
null,this.global.minPixelSelRadius)},"~N,~N,~B");$_M(c$,"findAtomsInRectangle",function(a){return this.modelSet.findAtomsInRectangle(a,this.getVisibleFramesBitSet())},"J.util.Rectangle");$_M(c$,"toCartesian",function(a,b){var c=this.getCurrentUnitCell();null!=c&&c.toCartesian(a,b)},"JU.P3,~B");$_M(c$,"toFractional",function(a,b){var c=this.getCurrentUnitCell();null!=c&&c.toFractional(a,b)},"JU.P3,~B");$_M(c$,"toUnitCell",function(a,b){var c=this.getCurrentUnitCell();null!=c&&c.toUnitCell(a,b)},"JU.P3,JU.P3");
$_M(c$,"setCurrentCage",function(a){a=[a,null];this.shapeManager.getShapePropertyData(24,"unitCell",a);this.modelSet.setModelCage(this.getCurrentModelIndex(),a[1])},"~S");$_M(c$,"setCurrentCagePts",function(a){this.modelSet.setModelCage(this.getCurrentModelIndex(),this.getSymmetry().getUnitCell(a))},"~A");$_M(c$,"setCurrentUnitCellOffset",function(a){this.modelSet.setUnitCellOffset(this.animationManager.currentModelIndex,null,a)},"~N");$_M(c$,"setCurrentUnitCellOffsetPt",function(a){this.modelSet.setUnitCellOffset(this.animationManager.currentModelIndex,
a,0)},"JU.P3");$_M(c$,"addUnitCellOffset",function(a){var b=this.getCurrentUnitCell();null!=b&&a.add(b.getCartesianOffset())},"JU.P3");$_M(c$,"setAtomData",function(a,b,c,d){this.modelSet.setAtomData(a,b,c,d);2==a&&this.checkCoordinatesChanged();this.refreshMeasures(!0)},"~N,~S,~S,~B");Clazz.overrideMethod(c$,"setCenterSelected",function(){this.setCenterBitSet(this.getSelectionSet(!1),!0)});$_M(c$,"setApplySymmetryToBonds",function(a){this.global.applySymmetryToBonds=a},"~B");Clazz.overrideMethod(c$,
"setBondTolerance",function(a){this.global.setF("bondTolerance",a);this.global.bondTolerance=a},"~N");Clazz.overrideMethod(c$,"setMinBondDistance",function(a){this.global.setF("minBondDistance",a);this.global.minBondDistance=a},"~N");$_M(c$,"getAtomIndices",function(a){return this.modelSet.getAtomIndices(a)},"JU.BS");$_M(c$,"getAtomBits",function(a,b){return this.modelSet.getAtomBits(a,b)},"~N,~O");$_M(c$,"getSequenceBits",function(a,b){return this.modelSet.getSequenceBits(a,b)},"~S,JU.BS");$_M(c$,
"getAtomsNearPt",function(a,b){var c=new JU.BS;this.modelSet.getAtomsWithin(a,b,c,-1);return c},"~N,JU.P3");$_M(c$,"getAtomsNearPts",function(a,b,c){return this.modelSet.getAtomsWithinBs(a,b,c)},"~N,~A,JU.BS");$_M(c$,"getAtomsNearPlane",function(a,b){return this.modelSet.getAtomsWithin(a,b)},"~N,JU.P4");$_M(c$,"getAtomsWithinRadius",function(a,b,c,d){return this.modelSet.getAtomsWithinRD(a,b,c,d)},"~N,JU.BS,~B,J.atomdata.RadiusData");$_M(c$,"getAtomsConnected",function(a,b,c,d){return this.modelSet.getAtomsConnected(a,
b,c,d)},"~N,~N,~N,JU.BS");$_M(c$,"getBranchBitSet",function(a,b,c){return 0>a||a>=this.getAtomCount()?new JU.BS:J.util.JmolMolecule.getBranchBitSet(this.modelSet.atoms,a,this.getModelUndeletedAtomsBitSet(this.modelSet.atoms[a].modelIndex),null,b,c,!0)},"~N,~N,~B");$_M(c$,"getAtomIndexFromAtomNumber",function(a){return this.modelSet.getAtomIndexFromAtomNumber(a,this.getVisibleFramesBitSet())},"~N");Clazz.overrideMethod(c$,"getElementsPresentBitSet",function(a){return this.modelSet.getElementsPresentBitSet(a)},
"~N");Clazz.overrideMethod(c$,"getHeteroList",function(a){return this.modelSet.getHeteroList(a)},"~N");$_M(c$,"getVisibleSet",function(){return this.modelSet.getVisibleSet()});$_M(c$,"getClickableSet",function(){return this.modelSet.getClickableSet()});$_M(c$,"calcSelectedGroupsCount",function(){this.modelSet.calcSelectedGroupsCount(this.getSelectionSet(!1))});$_M(c$,"calcSelectedMonomersCount",function(){this.modelSet.calcSelectedMonomersCount(this.getSelectionSet(!1))});$_M(c$,"calcSelectedMoleculesCount",
function(){this.modelSet.calcSelectedMoleculesCount(this.getSelectionSet(!1))});$_M(c$,"getFileHeader",function(){return this.modelSet.getFileHeader(this.animationManager.currentModelIndex)});$_M(c$,"getFileData",function(){return this.modelSet.getFileData(this.animationManager.currentModelIndex)});$_M(c$,"getCifData",function(a){a=this.getModelFileName(a);a=this.getFileAsString(a);return null==a?null:J.io.CifDataReader.readCifData(new java.io.BufferedReader(new java.io.StringReader(a)))},"~N");$_M(c$,
"getPDBHeader",function(){return this.modelSet.getPDBHeader(this.animationManager.currentModelIndex)});$_M(c$,"getAuxiliaryInfo",function(a){return this.modelSet.getAuxiliaryInfo(this.getModelBitSet(this.getAtomBitSet(a),!1))},"~O");$_M(c$,"getChimeInfo",function(a){return this.getPropertyManager().getChimeInfo(a,this.getSelectionSet(!1))},"~N");$_M(c$,"getStateCreator",function(){null==this.sc&&(this.sc=J.api.Interface.getOptionInterface("viewer.StateCreator")).setViewer(this);return this.sc});$_M(c$,
"getWrappedStateScript",function(){return this.getOutputManager().getWrappedState(null,null,null,null)});Clazz.overrideMethod(c$,"getStateInfo",function(){return this.getStateInfo3(null,0,0)});$_M(c$,"getStateInfo3",function(a,b,c){return this.global.preserveState?this.getStateCreator().getStateScript(a,b,c):""},"~S,~N,~N");$_M(c$,"getStructureState",function(){return this.getStateCreator().getModelState(null,!1,!0)});$_M(c$,"getProteinStructureState",function(){return this.modelSet.getProteinStructureState(this.getSelectionSet(!1),
!1,!1,3)});$_M(c$,"getCoordinateState",function(a){return this.getStateCreator().getAtomicPropertyState(2,a)},"JU.BS");$_M(c$,"setCurrentColorRange",function(a){var b=this.getDataFloat(a);a=null==b?null:this.dataManager.getData(a)[2];null!=a&&this.global.rangeSelected&&a.and(this.getSelectionSet(!1));this.setCurrentColorRangeData(b,a)},"~S");$_M(c$,"setCurrentColorRangeData",function(a,b){this.colorManager.setPropertyColorRangeData(a,b,this.global.propertyColorScheme)},"~A,JU.BS");$_M(c$,"setCurrentColorRange",
function(a,b){this.colorManager.setPropertyColorRange(a,b)},"~N,~N");$_M(c$,"setData",function(a,b,c,d,e,f,g){this.dataManager.setData(a,b,c,this.getAtomCount(),d,e,f,g)},"~S,~A,~N,~N,~N,~N,~N");$_M(c$,"getData",function(a){return this.dataManager.getData(a)},"~S");$_M(c$,"getDataFloat",function(a){return this.dataManager.getDataFloatA(a)},"~S");$_M(c$,"getDataFloat2D",function(a){return this.dataManager.getDataFloat2D(a)},"~S");$_M(c$,"getDataFloat3D",function(a){return this.dataManager.getDataFloat3D(a)},
"~S");$_M(c$,"getDataFloatAt",function(a,b){return this.dataManager.getDataFloat(a,b)},"~S,~N");Clazz.overrideMethod(c$,"getAltLocListInModel",function(a){return this.modelSet.getAltLocListInModel(a)},"~N");$_M(c$,"setConformation",function(){return this.modelSet.setConformation(this.getSelectionSet(!1))});$_M(c$,"getConformation",function(a,b,c){return this.modelSet.getConformation(a,b,c)},"~N,~N,~B");$_M(c$,"autoHbond",function(a,b,c){null==a&&(a=b=this.getSelectionSet(!1));return this.modelSet.autoHbond(a,
b,c)},"JU.BS,JU.BS,~B");Clazz.overrideMethod(c$,"havePartialCharges",function(){return null!=this.modelSet.getPartialCharges()});$_M(c$,"getCurrentUnitCell",function(){if(0<=this.animationManager.currentModelIndex)return this.modelSet.getUnitCell(this.animationManager.currentModelIndex);for(var a=this.getVisibleFramesBitSet(),b=null,c=a.nextSetBit(0);0<=c;c=a.nextSetBit(c+1)){var d=this.modelSet.getUnitCell(c);if(null!=d)if(null==b)b=d;else if(!b.unitCellEquals(d))return null}return b});$_M(c$,"getModelUnitCell",
function(a){return this.modelSet.getUnitCell(a)},"~N");$_M(c$,"getDefaultMeasurementLabel",function(a){switch(a){case 2:return this.global.defaultDistanceLabel;case 3:return this.global.defaultAngleLabel;default:return this.global.defaultTorsionLabel}},"~N");Clazz.overrideMethod(c$,"getMeasurementCount",function(){var a=this.getShapePropertyAsInt(6,"count");return 0>=a?0:a});Clazz.overrideMethod(c$,"getMeasurementStringValue",function(a){return""+this.getShapePropertyIndex(6,"stringValue",a)},"~N");
$_M(c$,"getMeasurementInfo",function(){return this.getShapeProperty(6,"info")});$_M(c$,"getMeasurementInfoAsString",function(){return this.getShapeProperty(6,"infostring")});Clazz.overrideMethod(c$,"getMeasurementCountPlusIndices",function(a){return this.getShapePropertyIndex(6,"countPlusIndices",a)},"~N");$_M(c$,"setPendingMeasurement",function(a){this.loadShape(6);this.setShapeProperty(6,"pending",a)},"J.modelset.MeasurementPending");$_M(c$,"getPendingMeasurement",function(){return this.getShapeProperty(6,
"pending")});$_M(c$,"clearAllMeasurements",function(){this.setShapeProperty(6,"clear",null)});Clazz.overrideMethod(c$,"clearMeasurements",function(){this.evalString("measures delete")});$_M(c$,"setAnimation",function(a){switch(a){case 1073742098:this.animationManager.reverseAnimation();case 1073742096:case 266287:this.animationManager.animationOn||this.animationManager.resumeAnimation();break;case 20487:this.animationManager.animationOn&&!this.animationManager.animationPaused&&this.animationManager.pauseAnimation();
break;case 1073742037:this.animationManager.setAnimationNext();break;case 1073742108:this.animationManager.setAnimationPrevious();break;case 1073741942:case 1073742126:this.animationManager.rewindAnimation();break;case 1073741993:this.animationManager.setAnimationLast()}},"~N");$_M(c$,"setAnimationDirection",function(a){this.animationManager.setAnimationDirection(a)},"~N");$_M(c$,"getAnimationDirection",function(){return this.animationManager.animationDirection});$_M(c$,"getAnimationInfo",function(){return this.getStateCreator().getInfo(this.animationManager)});
Clazz.overrideMethod(c$,"setAnimationFps",function(a){1>a&&(a=1);50<a&&(a=50);this.animationManager.setAnimationFps(a)},"~N");$_M(c$,"setAnimationMode",($fz=function(a){a.equalsIgnoreCase("once")?this.setAnimationReplayMode(J.constant.EnumAnimationMode.ONCE,0,0):a.equalsIgnoreCase("loop")?this.setAnimationReplayMode(J.constant.EnumAnimationMode.LOOP,1,1):a.startsWith("pal")&&this.setAnimationReplayMode(J.constant.EnumAnimationMode.PALINDROME,1,1)},$fz.isPrivate=!0,$fz),"~S");$_M(c$,"setAnimationReplayMode",
function(a,b,c){this.animationManager.setAnimationReplayMode(a,b,c)},"J.constant.EnumAnimationMode,~N,~N");$_M(c$,"getAnimationReplayMode",function(){return this.animationManager.animationReplayMode});$_M(c$,"setAnimationOn",function(a){a!=this.animationManager.animationOn&&this.animationManager.setAnimationOn(a)},"~B");$_M(c$,"setAnimationRange",function(a,b){this.animationManager.setAnimationRange(a,b)},"~N,~N");Clazz.overrideMethod(c$,"getVisibleFramesBitSet",function(){return this.modelSet.selectDisplayedTrajectories(J.util.BSUtil.copy(this.animationManager.bsVisibleModels))});
$_M(c$,"isAnimationOn",function(){return this.animationManager.animationOn});$_M(c$,"setMovie",function(a){this.animationManager.setMovie(a)},"java.util.Map");$_M(c$,"setAnimMorphCount",function(a){this.animationManager.setMorphCount(a)},"~N");$_M(c$,"isMovie",function(){return this.animationManager.isMovie});$_M(c$,"getFrameCount",function(){return this.animationManager.getFrameCount()});$_M(c$,"defineAtomSets",function(a){this.definedAtomSets.putAll(a)},"java.util.Map");$_M(c$,"morph",function(a){this.animationManager.morph(a)},
"~N");$_M(c$,"setAnimDisplay",function(a){this.animationManager.setDisplay(a);this.isAnimationOn()||this.animationManager.morph(this.animationManager.currentMorphModel+1)},"JU.BS");$_M(c$,"setCurrentModelIndex",function(a){-2147483648==a?(this.prevFrame=-2147483648,this.setCurrentModelIndexClear(this.animationManager.currentModelIndex,!0)):this.animationManager.setModel(a,!0)},"~N");$_M(c$,"setTrajectory",function(a){this.modelSet.setTrajectory(a)},"~N");$_M(c$,"setTrajectoryBs",function(a){this.modelSet.setTrajectoryBs(a)},
"JU.BS");$_M(c$,"isTrajectory",function(a){return this.modelSet.isTrajectory(a)},"~N");$_M(c$,"getBitSetTrajectories",function(){return this.modelSet.getBitSetTrajectories()});$_M(c$,"getTrajectoryState",function(){return this.getStateCreator().getTrajectoryState()});$_M(c$,"setFrameOffset",function(a){this.transformManager.setFrameOffset(a)},"~N");$_M(c$,"setFrameOffsets",function(a){this.bsFrameOffsets=a;this.transformManager.setFrameOffsets(this.frameOffsets=this.modelSet.getFrameOffsets(this.bsFrameOffsets))},
"JU.BS");$_M(c$,"getFrameOffsets",function(){return this.bsFrameOffsets});$_M(c$,"setCurrentModelIndexClear",function(a,b){this.animationManager.setModel(a,b)},"~N,~B");$_M(c$,"getCurrentModelIndex",function(){return this.animationManager.currentModelIndex});Clazz.overrideMethod(c$,"getDisplayModelIndex",function(){return this.animationManager.currentModelIndex});$_M(c$,"haveFileSet",function(){return 1<this.getModelCount()&&2E6<this.getModelNumber(2147483647)});$_M(c$,"setBackgroundModelIndex",function(a){this.animationManager.setBackgroundModelIndex(a);
this.global.setS("backgroundModel",this.modelSet.getModelNumberDotted(a))},"~N");$_M(c$,"setFrameVariables",function(){this.global.setS("animationMode",this.animationManager.animationReplayMode.name());this.global.setI("animationFps",this.animationManager.animationFps);this.global.setS("_firstFrame",this.animationManager.getModelSpecial(-1));this.global.setS("_lastFrame",this.animationManager.getModelSpecial(1));this.global.setF("_animTimeSec",this.animationManager.getAnimRunTimeSeconds());this.global.setB("_animMovie",
this.animationManager.isMovie)});$_M(c$,"getInMotion",function(a){return this.inMotion||a&&this.animationManager.animationOn},"~B");Clazz.overrideMethod(c$,"getMotionEventNumber",function(){return this.motionEventNumber});Clazz.overrideMethod(c$,"setInMotion",function(a){(new Boolean(this.inMotion^a)).valueOf()&&(this.inMotion=a,this.resizeImage(0,0,!1,!1,!0),a?(this.startHoverWatcher(!1),++this.motionEventNumber):(this.startHoverWatcher(!0),this.refresh(3,"viewer setInMotion "+a)))},"~B");$_M(c$,
"setRefreshing",($fz=function(a){this.refreshing=a},$fz.isPrivate=!0,$fz),"~B");$_M(c$,"getRefreshing",function(){return this.refreshing});$_M(c$,"pushHoldRepaint",function(){this.pushHoldRepaint(null)});$_M(c$,"pushHoldRepaint",function(a){null!=this.repaintManager&&this.repaintManager.pushHoldRepaint(a)},"~S");Clazz.overrideMethod(c$,"popHoldRepaint",function(a){null!=this.repaintManager&&this.repaintManager.popHoldRepaint(0>a.indexOf("\u0001## REPAINT_IGNORE ##"),a)},"~S");Clazz.overrideMethod(c$,
"refresh",function(a,b){if(null!=this.repaintManager&&this.refreshing&&!(6==a&&this.getInMotion(!0))&&"undefined"!=typeof Jmol){if(this.isWebGL){if(2==a||7==a)if(this.transformManager.finalizeTransformParameters(),Jmol._refresh&&Jmol._refresh(this.applet,a,b,[this.transformManager.fixedRotationCenter,this.transformManager.getRotationQuaternion(),this.transformManager.xTranslationFraction,this.transformManager.yTranslationFraction,this.transformManager.modelRadius,this.transformManager.scalePixelsPerAngstrom,
this.transformManager.zoomPercent]),7==a)return}else{if(7==a)return;0<a&&this.repaintManager.repaintIfReady()}0!=a%3&&this.statusManager.doSync()&&this.statusManager.setSync(2==a?b:null)}},"~N,~S");$_M(c$,"requestRepaintAndWait",function(a){this.haveDisplay&&null!=this.repaintManager&&(this.repaintManager.requestRepaintAndWait(a),this.setSync())},"~S");$_M(c$,"clearShapeRenderers",function(){this.clearRepaintManager(-1)});$_M(c$,"isRepaintPending",function(){return null==this.repaintManager?!1:this.repaintManager.isRepaintPending()});
Clazz.overrideMethod(c$,"notifyViewerRepaintDone",function(){null!=this.repaintManager&&this.repaintManager.repaintDone();this.animationManager.repaintDone()});$_M(c$,"areAxesTainted",function(){var a=this.axesAreTainted;this.axesAreTainted=!1;return a});$_M(c$,"setMaximumSize",($fz=function(a){this.maximumSize=Math.max(a,100)},$fz.isPrivate=!0,$fz),"~N");Clazz.overrideMethod(c$,"setScreenDimension",function(a,b){b=Math.min(b,this.maximumSize);a=Math.min(a,this.maximumSize);this.isStereoDouble()&&
(a=Clazz.doubleToInt((a+1)/2));this.dimScreen.width==a&&this.dimScreen.height==b||this.resizeImage(a,b,!1,!1,!0)},"~N,~N");$_M(c$,"getImageFontScaling",function(){return this.imageFontScaling});$_M(c$,"resizeImage",function(a,b,c,d,e){if(c||!this.creatingImage)!d&&!c&&this.setShapeProperty(5,"clearBoxes",null),this.antialiasDisplay=e?this.global.antialiasDisplay&&this.checkMotionRendering(603979786):c&&!d?this.global.antialiasImages:!1,this.imageFontScaling=(e||0>=a?1:Clazz.doubleToInt((this.global.zoomLarge==
b>a?b:a)/this.getScreenDim()))*(this.antialiasDisplay?2:1),0<a?(this.dimScreen.width=a,this.dimScreen.height=b,c||(this.global.setI("_width",a),this.global.setI("_height",b),this.setStatusResized(a,b))):(a=0==this.dimScreen.width?this.dimScreen.width=500:this.dimScreen.width,b=0==this.dimScreen.height?this.dimScreen.height=500:this.dimScreen.height),this.transformManager.setScreenParameters(a,b,c||e?this.global.zoomLarge:!1,this.antialiasDisplay,!1,!1),this.gdata.setWindowParameters(a,b,this.antialiasDisplay)},
"~N,~N,~B,~B,~B");Clazz.overrideMethod(c$,"getScreenWidth",function(){return this.dimScreen.width});Clazz.overrideMethod(c$,"getScreenHeight",function(){return this.dimScreen.height});$_M(c$,"getScreenDim",function(){return this.global.zoomLarge==this.dimScreen.height>this.dimScreen.width?this.dimScreen.height:this.dimScreen.width});Clazz.overrideMethod(c$,"generateOutputForExport",function(a){return this.$noGraphicsAllowed||null==this.repaintManager?null:this.getOutputManager().getOutputFromExport(a)},
"java.util.Map");$_M(c$,"clearRepaintManager",($fz=function(a){null!=this.repaintManager&&this.repaintManager.clear(a)},$fz.isPrivate=!0,$fz),"~N");Clazz.overrideMethod(c$,"renderScreenImageStereo",function(a,b,c,d){this.updateWindow(c,d)&&(null==b?this.getScreenImageBuffer(a,!1):(this.render1(b,this.getImage(!0,!1),0,0),this.render1(a,this.getImage(!1,!1),0,0)));null!=this.captureParams&&Boolean.FALSE!==this.captureParams.get("captureEnabled")&&this.processWriteOrCapture(this.captureParams);this.notifyViewerRepaintDone()},
"~O,~O,~N,~N");Clazz.overrideMethod(c$,"updateJS",function(a,b){this.isWebGL?(this.updateWindow(a,b)&&this.render(),this.notifyViewerRepaintDone()):this.renderScreenImageStereo(this.apiPlatform.context,null,a,b)},"~N,~N");$_M(c$,"updateWindow",($fz=function(a,b){if(!this.refreshing||this.creatingImage)return!1;(this.isTainted||this.getSlabEnabled())&&this.setModelVisibility();this.isTainted=!1;null!=this.repaintManager&&0!=a&&this.setScreenDimension(a,b);return!0},$fz.isPrivate=!0,$fz),"~N,~N");$_M(c$,
"renderScreenImage",function(a,b,c){this.renderScreenImageStereo(a,null,b,c)},"~O,~N,~N");$_M(c$,"getImage",($fz=function(a,b){if(this.isWebGL)return null;var c=null;try{this.beginRendering(a,b),this.render(),this.gdata.endRendering(),c=this.gdata.getScreenImage(b)}catch(d){if(Clazz.exceptionOf(d,Error))this.gdata.getScreenImage(b),this.handleError(d,!1),this.setErrorMessage("Error during rendering: "+d,null);else throw d;}return c},$fz.isPrivate=!0,$fz),"~B,~B");$_M(c$,"beginRendering",($fz=function(a,
b){this.gdata.beginRendering(this.transformManager.getStereoRotationMatrix(a),this.global.translucent,b,!this.checkMotionRendering(603979967))},$fz.isPrivate=!0,$fz),"~B,~B");$_M(c$,"isAntialiased",function(){return this.antialiasDisplay});$_M(c$,"render",($fz=function(){if(!(null==this.modelSet||!this.mustRender||!this.refreshing&&!this.creatingImage||null==this.repaintManager)){var a=this.antialiasDisplay&&this.global.antialiasTranslucent;this.finalizeTransformParameters();this.shapeManager.finalizeAtoms(this.transformManager.bsSelectedAtoms,
this.transformManager.ptOffset);var b=this.shapeManager.transformAtoms();this.transformManager.bsSelectedAtoms=null;this.isWebGL?(this.repaintManager.renderExport("JS",this.gdata,this.modelSet,null),this.notifyViewerRepaintDone()):(this.repaintManager.render(this.gdata,this.modelSet,!0,b),this.gdata.setPass2(a)&&(this.transformManager.setAntialias(a),this.repaintManager.render(this.gdata,this.modelSet,!1,null),this.transformManager.setAntialias(this.antialiasDisplay)))}},$fz.isPrivate=!0,$fz));$_M(c$,
"render1",($fz=function(a,b,c,d){null!=a&&null!=b&&this.apiPlatform.drawImage(a,b,c,d,this.dimScreen.width,this.dimScreen.height);this.gdata.releaseScreenImage()},$fz.isPrivate=!0,$fz),"~O,~O,~N,~N");Clazz.overrideMethod(c$,"getScreenImageBuffer",function(a,b){if(this.isWebGL)return null;var c=null==a&&this.isStereoDouble(),d;this.transformManager.stereoMode.isBiColor()?(this.beginRendering(!0,b),this.render(),this.gdata.endRendering(),this.gdata.snapshotAnaglyphChannelBytes(),this.beginRendering(!1,
b),this.render(),this.gdata.endRendering(),this.gdata.applyAnaglygh(this.transformManager.stereoMode,this.transformManager.stereoColors),d=this.gdata.getScreenImage(b)):d=this.getImage(this.isStereoDouble(),b);var e=null;c&&(e=this.apiPlatform.newBufferedImage(d,this.dimScreen.width<<1,this.dimScreen.height),a=this.apiPlatform.getGraphics(e));null!=a&&(this.isStereoDouble()&&(this.render1(a,d,this.dimScreen.width,0),d=this.getImage(!1,!1)),this.render1(a,d,0,0));return c?e:d},"~O,~B");Clazz.overrideMethod(c$,
"getImageAsBytes",function(a,b,c,d,e){return this.isWebGL?null:this.getOutputManager().getImageAsBytes(a,b,c,d,e)},"~S,~N,~N,~N,~A");Clazz.overrideMethod(c$,"releaseScreenImage",function(){this.gdata.releaseScreenImage()});Clazz.overrideMethod(c$,"evalFile",function(a){if(!this.allowScripting)return null;var b=a.indexOf(" -noqueue");return 0<=b?this.evalStringWaitStatusQueued("String",a.substring(0,b),"",!0,!1,!1):this.getScriptManager().addScript(a,!0,!1)},"~S");$_M(c$,"getInsertedCommand",function(){var a=
this.insertedCommand;this.insertedCommand="";J.util.Logger.debugging&&""!==a&&J.util.Logger.debug("inserting: "+a);return a});Clazz.overrideMethod(c$,"script",function(a){return this.evalStringQuietSync(a,!1,!0)},"~S");Clazz.overrideMethod(c$,"evalString",function(a){return this.evalStringQuietSync(a,!1,!0)},"~S");Clazz.overrideMethod(c$,"evalStringQuiet",function(a){return this.evalStringQuietSync(a,!0,!0)},"~S");$_M(c$,"evalStringQuietSync",function(a,b,c){return null==this.getScriptManager()?null:
this.scriptManager.evalStringQuietSync(a,b,c)},"~S,~B,~B");$_M(c$,"clearScriptQueue",function(){null!=this.scriptManager&&this.scriptManager.clearQueue()});$_M(c$,"setScriptQueue",($fz=function(a){(this.global.useScriptQueue=a)||this.clearScriptQueue()},$fz.isPrivate=!0,$fz),"~B");Clazz.overrideMethod(c$,"checkHalt",function(a,b){return null!=this.scriptManager&&this.scriptManager.checkHalt(a,b)},"~S,~B");Clazz.overrideMethod(c$,"scriptWait",function(a){return this.evalWait("JSON",a,"+scriptStarted,+scriptStatus,+scriptEcho,+scriptTerminated")},
"~S");Clazz.overrideMethod(c$,"scriptWaitStatus",function(a,b){return this.evalWait("object",a,b)},"~S,~S");$_M(c$,"evalWait",($fz=function(a,b,c){if(null==this.getScriptManager())return null;this.scriptManager.waitForQueue();var d=J.i18n.GT.setDoTranslate(!1);a=this.evalStringWaitStatusQueued(a,b,c,!1,!1,!1);J.i18n.GT.setDoTranslate(d);return a},$fz.isPrivate=!0,$fz),"~S,~S,~S");$_M(c$,"evalStringWaitStatusQueued",function(a,b,c,d,e,f){return 0==b.indexOf("JSCONSOLE")?(this.applet._showInfo(!0),
null):null==this.getScriptManager()?null:this.scriptManager.evalStringWaitStatusQueued(a,b,c,d,e,f)},"~S,~S,~S,~B,~B,~B");$_M(c$,"exitJmol",function(){if(!this.$isApplet){if(null!=this.headlessImageParams)try{this.isHeadless()&&this.outputToFile(this.headlessImageParams)}catch(a){if(!Clazz.exceptionOf(a,Exception))throw a;}J.util.Logger.debugging&&J.util.Logger.debug("exitJmol -- exiting");System.out.flush();System.exit(0)}});$_M(c$,"scriptCheckRet",($fz=function(a,b){return null==this.getScriptManager()?
null:this.scriptManager.scriptCheckRet(a,b)},$fz.isPrivate=!0,$fz),"~S,~B");Clazz.overrideMethod(c$,"scriptCheck",function(a){return null==this.getScriptManager()?null:this.scriptCheckRet(a,!1)},"~S");Clazz.overrideMethod(c$,"isScriptExecuting",function(){return null!=this.eval&&this.eval.isExecuting()});Clazz.overrideMethod(c$,"haltScriptExecution",function(){null!=this.eval&&(this.eval.haltExecution(),this.eval.stopScriptThreads());this.setStringPropertyTok("pathForAllFiles",545259571,"");this.clearTimeouts()});
$_M(c$,"pauseScriptExecution",function(){null!=this.eval&&this.eval.pauseExecution(!0)});$_M(c$,"getDefaultLoadFilter",function(){return this.global.defaultLoadFilter});$_M(c$,"getDefaultLoadScript",function(){return this.global.defaultLoadScript});$_M(c$,"resolveDatabaseFormat",function(a){J.viewer.Viewer.hasDatabasePrefix(a)&&(a=this.setLoadFormat(a,a.charAt(0),!1));return a},"~S");c$.isDatabaseCode=$_M(c$,"isDatabaseCode",function(a){return"$"==a||"="==a||":"==a},"~S");c$.hasDatabasePrefix=$_M(c$,
"hasDatabasePrefix",function(a){return 0!=a.length&&J.viewer.Viewer.isDatabaseCode(a.charAt(0))},"~S");$_M(c$,"setLoadFormat",function(a,b,c){var d=a.substring(1);switch(b){case "=":if(a.startsWith("=="))d=d.substring(1),b="#";else if(0<d.indexOf("/"))try{var e=d.indexOf("/"),f=d.substring(0,e),d=this.global.resolveDataBase(f,d.substring(e+1));return null==d?a:d}catch(g){if(Clazz.exceptionOf(g,Exception))return a;throw g;}case "#":return c="="==b?this.global.loadFormat:this.global.loadLigandFormat,
0<d.indexOf(".")&&0<=c.indexOf("%FILE.")&&(c=c.substring(0,c.indexOf("%FILE")+5)),J.util.Txt.formatStringS(c,"FILE",d);case ":":a=this.global.pubChemFormat;c=d.toLowerCase();b=-2147483648;try{b=Integer.parseInt(d)}catch(h){if(!Clazz.exceptionOf(h,Exception))throw h;}-2147483648!=b?d="cid/"+b:c.startsWith("smiles:")?(a+="?POST?smiles="+d.substring(7),d="smiles"):c.startsWith("cid:")?d="cid/"+d.substring(4):(c.startsWith("name:")&&(d=d.substring(5)),c.startsWith("cas:")&&(d=d.substring(4)),d="name/"+
J.util.Escape.escapeUrl(d));return J.util.Txt.formatStringS(a,"FILE",d);case "$":if(a.startsWith("$$"))return d=d.substring(1),a=J.util.Txt.simpleReplace(this.global.smilesUrlFormat,"&get3d=True",""),J.util.Txt.formatStringS(a,"FILE",J.util.Escape.escapeUrl(d));case "N":case "2":case "I":case "K":case "/":d=J.util.Escape.escapeUrl(d);switch(b){case "N":a=this.global.nihResolverFormat+"/names";break;case "2":a=this.global.nihResolverFormat+"/image";break;case "I":a=this.global.nihResolverFormat+"/stdinchi";
break;case "K":a=this.global.nihResolverFormat+"/inchikey";break;case "/":a=this.global.nihResolverFormat+"/";break;default:a=this.global.smilesUrlFormat}return(c?"MOL3D::":"")+J.util.Txt.formatStringS(a,"FILE",d);case "_":return c=J.viewer.FileManager.fixFileNameVariables(this.global.edsUrlFormat,d),d=J.viewer.FileManager.fixFileNameVariables(this.global.edsUrlCutoff,d),[c,d]}return d},"~S,~S,~B");$_M(c$,"getElectronDensityLoadInfo",function(){return[this.global.edsUrlFormat,this.global.edsUrlCutoff,
this.global.edsUrlOptions]});$_M(c$,"getStandardLabelFormat",function(a){switch(a){default:case 0:return"%[identify]";case 1:return this.global.defaultLabelXYZ;case 2:return this.global.defaultLabelPDB}},"~N");$_M(c$,"getAdditionalHydrogens",function(a,b,c,d){null==a&&(a=this.getSelectionSet(!1));var e=Clazz.newIntArray(1,0);a=this.modelSet.calculateHydrogens(a,e,b,c,d);e=Array(e[0]);for(c=b=0;b<a.length;b++)if(null!=a[b])for(d=0;d<a[b].length;d++)e[c++]=a[b][d];return e},"JU.BS,~B,~B,JU.List");Clazz.overrideMethod(c$,
"setMarBond",function(a){this.global.bondRadiusMilliAngstroms=a;this.global.setI("bondRadiusMilliAngstroms",a);this.setShapeSize(1,2*a,J.util.BSUtil.setAll(this.getAtomCount()))},"~N");$_M(c$,"setHoverLabel",function(a){this.loadShape(34);this.setShapeProperty(34,"label",a);(this.hoverEnabled=null!=a)||this.startHoverWatcher(!1)},"~S");$_M(c$,"hoverOn",function(a,b){this.setStatusAtomHovered(a,this.getAtomInfoXYZ(a,!1));if(this.hoverEnabled)if(this.global.modelKitMode)this.isAtomAssignable(a)&&this.highlight(J.util.BSUtil.newAndSetBit(a)),
this.refresh(3,"hover on atom");else if(!(null!=this.eval&&this.isScriptExecuting()||a==this.hoverAtomIndex||0==this.global.hoverDelayMs)&&this.isInSelectionSubset(a))this.loadShape(34),b&&this.modelSet.atoms[a].isShapeVisible(J.viewer.JC.getShapeVisibilityFlag(5))&&this.setShapeProperty(34,"specialLabel",J.i18n.GT._("Drag to move label")),this.setShapeProperty(34,"text",null),this.setShapeProperty(34,"target",Integer.$valueOf(a)),this.hoverText=null,this.hoverAtomIndex=a,this.refresh(3,"hover on atom")},
"~N,~B");$_M(c$,"hoverOnPt",function(a,b,c,d,e){this.hoverEnabled&&!(null!=this.eval&&this.isScriptExecuting())&&(this.loadShape(34),this.setShapeProperty(34,"xy",JU.P3i.new3(a,b,0)),this.setShapeProperty(34,"target",null),this.setShapeProperty(34,"specialLabel",null),this.setShapeProperty(34,"text",c),this.hoverAtomIndex=-1,this.hoverText=c,null!=d&&null!=e&&this.setStatusObjectHovered(d,c,e),this.refresh(3,"hover on point"))},"~N,~N,~S,~S,JU.P3");$_M(c$,"hoverOff",function(){try{if(this.global.modelKitMode&&
this.highlight(null),this.hoverEnabled){var a=null!=this.hoverText||0<=this.hoverAtomIndex;0<=this.hoverAtomIndex&&(this.setShapeProperty(34,"target",null),this.hoverAtomIndex=-1);null!=this.hoverText&&(this.setShapeProperty(34,"text",null),this.hoverText=null);this.setShapeProperty(34,"specialLabel",null);a&&this.refresh(3,"hover off")}}catch(b){if(!Clazz.exceptionOf(b,Exception))throw b;}});$_M(c$,"getBfactor100Hi",function(){return this.modelSet.getBfactor100Hi()});$_M(c$,"getColix",function(a){return J.util.C.getColixO(a)},
"~O");Clazz.overrideMethod(c$,"setDebugScript",function(a){this.global.debugScript=a;this.global.setB("debugScript",a);null!=this.eval&&this.eval.setDebugging()},"~B");$_M(c$,"clearClickCount",function(){this.setTainted(!0)});$_M(c$,"getCursor",function(){return this.currentCursor});$_M(c$,"setCursor",function(a){if(!this.$isKiosk&&!(this.currentCursor==a||this.multiTouch||!this.haveDisplay))this.apiPlatform.setCursor(this.currentCursor=a,this.display)},"~N");$_M(c$,"setPickingMode",function(a,b){if(this.haveDisplay){this.showSelected=
!1;var c=null;if(null!=a){var d=a.indexOf("_");0<=d&&(c=a.substring(d+1),a=a.substring(0,d));b=J.viewer.ActionManager.getPickingMode(a)}0>b&&(b=1);this.actionManager.setPickingMode(b);this.global.setS("picking",J.viewer.ActionManager.getPickingModeName(this.actionManager.getAtomPickingMode()));if(!(null==c||0==c.length))switch(c=Character.toUpperCase(c.charAt(0))+(1==c.length?"":c.substring(1,2)),b){case 32:this.setAtomPickingOption(c);break;case 33:this.setBondPickingOption(c);break;default:J.util.Logger.error("Bad picking mode: "+
a+"_"+c)}}},"~S,~N");$_M(c$,"getPickingMode",function(){return this.haveDisplay?this.actionManager.getAtomPickingMode():0});$_M(c$,"setPickingStyle",function(a,b){this.haveDisplay&&(null!=a&&(b=J.viewer.ActionManager.getPickingStyleIndex(a)),0>b&&(b=0),this.actionManager.setPickingStyle(b),this.global.setS("pickingStyle",J.viewer.ActionManager.getPickingStyleName(this.actionManager.getPickingStyle())))},"~S,~N");$_M(c$,"getDrawHover",function(){return this.haveDisplay&&this.global.drawHover});Clazz.overrideMethod(c$,
"getAtomInfo",function(a){return 0<=a?this.modelSet.getAtomInfo(a,null):this.shapeManager.getShapePropertyIndex(6,"pointInfo",-a)},"~N");$_M(c$,"getAtomInfoXYZ",function(a,b){return this.modelSet.getAtomInfoXYZ(a,b)},"~N,~B");$_M(c$,"setSync",($fz=function(){this.statusManager.doSync()&&this.statusManager.setSync(null)},$fz.isPrivate=!0,$fz));Clazz.overrideMethod(c$,"setJmolCallbackListener",function(a){this.statusManager.setJmolCallbackListener(a)},"J.api.JmolCallbackListener");Clazz.overrideMethod(c$,
"setJmolStatusListener",function(a){this.statusManager.setJmolStatusListener(a,null)},"J.api.JmolStatusListener");$_M(c$,"getMessageQueue",function(){return this.statusManager.getMessageQueue()});$_M(c$,"getStatusChanged",function(a){return null==a?null:this.statusManager.getStatusChanged(a)},"~S");$_M(c$,"menuEnabled",function(){return!this.global.disablePopupMenu&&null!=this.getPopupMenu()});$_M(c$,"popupMenu",function(a,b,c){if(this.haveDisplay&&this.refreshing&&!this.$isPreviewOnly&&!this.global.disablePopupMenu)switch(c){case "j":try{this.getPopupMenu(),
this.jmolpopup.jpiShow(a,b)}catch(d){this.global.disablePopupMenu=!0}break;case "a":case "b":case "m":this.modelkitPopup=this.apiPlatform.getMenuPopup(null,c),null!=this.modelkitPopup&&this.modelkitPopup.jpiShow(a,b)}},"~N,~N,~S");$_M(c$,"getMenu",function(a){this.getPopupMenu();return a.equals("\x00")?(this.popupMenu(this.dimScreen.width-120,0,"j"),"OK"):null==this.jmolpopup?"":this.jmolpopup.jpiGetMenuAsString("Jmol version "+J.viewer.Viewer.getJmolVersion()+"|_GET_MENU|"+a)},"~S");$_M(c$,"getPopupMenu",
($fz=function(){return null==this.jmolpopup&&(this.jmolpopup=this.allowScripting?this.apiPlatform.getMenuPopup(this.menuStructure,"j"):null,null==this.jmolpopup)?(this.global.disablePopupMenu=!0,null):this.jmolpopup.jpiGetMenuAsObject()},$fz.isPrivate=!0,$fz));$_M(c$,"setMenu",function(a,b){b&&J.util.Logger.info("Setting menu "+(0==a.length?"to Jmol defaults":"from file "+a));0==a.length?a=null:b&&(a=this.getFileAsString(a));this.getProperty("DATA_API","setMenu",a);this.statusManager.setCallbackFunction("menu",
a)},"~S,~B");$_M(c$,"setStatusFrameChanged",function(a){a&&(this.prevFrame=-2147483648);a=this.animationManager.getCurrentModelIndex();this.transformManager.setVibrationPeriod(NaN);var b=this.animationManager.firstFrameIndex,c=this.animationManager.lastFrameIndex,d=this.isMovie(),e=this.animationManager.currentModelIndex;b==c&&!d&&(e=b);var f=this.getModelFileNumber(e),g=this.animationManager.getCurrentModelIndex(),h=f,k=f%1E6,l=d?b:this.getModelFileNumber(b),m=d?c:this.getModelFileNumber(c),n;d?
n=""+(a+1):0==h?(n=this.getModelNumberDotted(b),b!=c&&(n+=" - "+this.getModelNumberDotted(c)),Clazz.doubleToInt(l/1E6)==Clazz.doubleToInt(m/1E6)&&(h=l)):n=this.getModelNumberDotted(e);0!=h&&(h=1E6>h?1:Clazz.doubleToInt(h/1E6));d||(this.global.setI("_currentFileNumber",h),this.global.setI("_currentModelNumberInFile",k));this.global.setI("_currentFrame",g);this.global.setI("_morphCount",this.animationManager.morphCount);this.global.setF("_currentMorphFrame",this.animationManager.currentMorphModel);
this.global.setI("_frameID",f);this.global.setS("_modelNumber",n);this.global.setS("_modelName",0>e?"":this.getModelName(e));this.global.setS("_modelTitle",0>e?"":this.getModelTitle(e));this.global.setS("_modelFile",0>e?"":this.modelSet.getModelFileName(e));this.global.setS("_modelType",0>e?"":this.modelSet.getModelFileType(e));g!=this.prevFrame&&(this.prevFrame=g,d?b=""+(this.animationManager.getCurrentModelIndex()+1):(b=this.getModelName(a),c=""+this.getModelNumberDotted(a),b.equals(c)||(b=c+": "+
b),50<b.length&&(b=b.substring(0,45)+"...")),this.statusManager.setStatusFrameChanged(a,h,k,0>this.animationManager.animationDirection?-l:l,0>this.animationManager.currentDirection?-m:m,g,b),this.doHaveJDX()&&this.getJSV().setModel(e))},"~B");$_M(c$,"doHaveJDX",($fz=function(){return this.haveJDX||(this.haveJDX=this.getBooleanProperty("_jspecview"))},$fz.isPrivate=!0,$fz));$_M(c$,"getJSV",($fz=function(){null==this.jsv&&(this.jsv=J.api.Interface.getOptionInterface("viewer.JSpecView"),this.jsv.setViewer(this));
return this.jsv},$fz.isPrivate=!0,$fz));$_M(c$,"getJDXBaseModelIndex",function(a){return!this.doHaveJDX()?a:this.getJSV().getBaseModelIndex(a)},"~N");$_M(c$,"getJspecViewProperties",function(a){a=this.statusManager.getJspecViewProperties(""+a);null!=a&&(this.haveJDX=!0);return a},"~O");$_M(c$,"scriptEcho",function(a){J.util.Logger.isActiveLevel(4)&&(System.out.println(a),this.statusManager.setScriptEcho(a,this.isScriptQueued()),this.listCommands&&(null!=a&&0==a.indexOf("$["))&&J.util.Logger.info(a))},
"~S");$_M(c$,"isScriptQueued",($fz=function(){return null!=this.scriptManager&&this.scriptManager.isScriptQueued()},$fz.isPrivate=!0,$fz));$_M(c$,"notifyError",function(a,b,c){this.global.setS("_errormessage",c);this.statusManager.notifyError(a,b,c)},"~S,~S,~S");$_M(c$,"jsEval",function(a){return this.statusManager.jsEval(a)},"~S");$_M(c$,"setStatusAtomHovered",function(a,b){this.global.setI("_atomhovered",a);this.statusManager.setStatusAtomHovered(a,b)},"~N,~S");$_M(c$,"setStatusObjectHovered",function(a,
b,c){this.global.setS("_objecthovered",a);this.statusManager.setStatusObjectHovered(a,b,c)},"~S,~S,JU.P3");$_M(c$,"setFileLoadStatus",($fz=function(a,b,c,d,e,f){this.setErrorMessage(e,null);this.global.setI("_loadPoint",a.getCode());var g=a!==J.constant.EnumFileStatus.CREATING_MODELSET;this.statusManager.setFileLoadStatus(b,c,d,e,a.getCode(),g,f);g&&this.doHaveJDX()&&this.getJSV().setModel(this.getCurrentModelIndex())},$fz.isPrivate=!0,$fz),"J.constant.EnumFileStatus,~S,~S,~S,~S,Boolean");$_M(c$,
"getZapName",function(){return this.global.modelKitMode?"Jmol Model Kit":"zapped"});$_M(c$,"setStatusMeasuring",function(a,b,c,d){this.statusManager.setStatusMeasuring(a,b,c,d)},"~S,~N,~S,~N");$_M(c$,"notifyMinimizationStatus",function(){var a=this.getParameter("_minimizationStep"),b=this.getParameter("_minimizationForceField");this.statusManager.notifyMinimizationStatus(this.getParameter("_minimizationStatus"),Clazz.instanceOf(a,String)?Integer.$valueOf(0):a,this.getParameter("_minimizationEnergy"),
a.toString().equals("0")?Float.$valueOf(0):this.getParameter("_minimizationEnergyDiff"),b)});$_M(c$,"setStatusAtomPicked",function(a,b){null==b&&(b=this.global.pickLabel,b=0==b.length?this.getAtomInfoXYZ(a,this.global.messageStyleChime):this.modelSet.getAtomInfo(a,b));this.global.setPicked(a);this.global.setS("_pickinfo",b);this.statusManager.setStatusAtomPicked(a,b);1==this.statusManager.getSyncMode()&&this.doHaveJDX()&&this.getJSV().atomPicked(a)},"~N,~S");$_M(c$,"setStatusResized",function(a,b){this.statusManager.setStatusResized(a,
b)},"~N,~N");$_M(c$,"scriptStatus",function(a){this.setScriptStatus(a,"",0,null)},"~S");$_M(c$,"scriptStatusMsg",function(a,b){this.setScriptStatus(a,b,0,null)},"~S,~S");$_M(c$,"setScriptStatus",function(a,b,c,d){this.statusManager.setScriptStatus(a,b,c,d)},"~S,~S,~N,~S");$_M(c$,"getModelTitle",($fz=function(a){return null==this.modelSet?null:this.modelSet.getModelTitle(a)},$fz.isPrivate=!0,$fz),"~N");Clazz.overrideMethod(c$,"getModelFileName",function(a){return null==this.modelSet?null:this.modelSet.getModelFileName(a)},
"~N");$_M(c$,"dialogAsk",function(a,b){return prompt(a,b)},"~S,~S");Clazz.overrideMethod(c$,"showUrl",function(a){if(null!=a){if(0>a.indexOf(":")){var b=this.fileManager.getAppletDocumentBase();""===b&&(b=this.fileManager.getFullPathName());0<=b.indexOf("/")?b=b.substring(0,b.lastIndexOf("/")+1):0<=b.indexOf("\\")&&(b=b.substring(0,b.lastIndexOf("\\")+1));a=b+a}J.util.Logger.info("showUrl:"+a);this.statusManager.showUrl(a)}},"~S");$_M(c$,"setMeshCreator",function(a){this.loadShape(24);this.setShapeProperty(24,
"meshCreator",a)},"~O");$_M(c$,"showConsole",function(a){if(this.haveDisplay)try{null==this.appConsole&&a&&this.getProperty("DATA_API","getAppConsole",Boolean.TRUE),this.appConsole.setVisible(!0)}catch(b){}},"~B");$_M(c$,"clearConsole",function(){this.statusManager.clearConsole()});$_M(c$,"getParameterEscaped",function(a){return this.global.getParameterEscaped(a,0)},"~S");Clazz.overrideMethod(c$,"getParameter",function(a){return this.global.getParameter(a)},"~S");$_M(c$,"getOrSetNewVariable",function(a,
b){return this.global.getOrSetNewVariable(a,b)},"~S,~B");$_M(c$,"setUserVariable",function(a,b){return this.global.setUserVariable(a,b)},"~S,J.script.SV");$_M(c$,"unsetProperty",function(a){a=a.toLowerCase();(a.equals("all")||a.equals("variables"))&&this.fileManager.setPathForAllFiles("");this.global.unsetUserVariable(a)},"~S");$_M(c$,"getVariableList",function(){return this.global.getVariableList()});Clazz.overrideMethod(c$,"getBooleanProperty",function(a){a=a.toLowerCase();if(this.global.htBooleanParameterFlags.containsKey(a))return this.global.htBooleanParameterFlags.get(a).booleanValue();
if(a.endsWith("p!")){if(null==this.actionManager)return!1;var b=this.actionManager.getPickingState().toLowerCase();a=a.substring(0,a.length-2)+";";return 0<=b.indexOf(a)}if(a.equalsIgnoreCase("__appletReady"))return this.statusManager.setStatusAppletReady(this.fullName,!0),!0;if(a.equalsIgnoreCase("__appletDestroyed"))return this.statusManager.setStatusAppletReady(this.htmlName,!1),!0;if(a.equalsIgnoreCase("executionPaused"))return null!=this.eval&&this.eval.isPaused();if(a.equalsIgnoreCase("executionStepping"))return null!=
this.eval&&this.eval.isStepping();if(a.equalsIgnoreCase("haveBFactors"))return null!=this.modelSet.getBFactors();if(a.equalsIgnoreCase("colorRasmol"))return this.colorManager.getDefaultColorRasmol();if(a.equalsIgnoreCase("frank"))return this.getShowFrank();if(a.equalsIgnoreCase("spinOn"))return this.getSpinOn();if(a.equalsIgnoreCase("isNavigating"))return this.isNavigating();if(a.equalsIgnoreCase("showSelections"))return this.modelSet.getSelectionHaloEnabled();if(this.global.htUserVariables.containsKey(a)){b=
this.global.getUserVariable(a);if(1048589==b.tok)return!0;if(1048588==b.tok)return!1}J.util.Logger.error("viewer.getBooleanProperty("+a+") - unrecognized");return!1},"~S");Clazz.overrideMethod(c$,"getInt",function(a){switch(a){case 553648132:return this.animationManager.animationFps;case 553648143:return this.global.dotDensity;case 553648144:return this.global.dotScale;case 553648146:return this.global.helixStep;case 553648151:return this.global.meshScale;case 553648153:return this.global.minPixelSelRadius;
case 553648154:return this.global.percentVdwAtom;case 553648157:return this.global.pickingSpinRate;case 553648158:return this.global.platformSpeed;case 553648166:return this.global.ribbonAspectRatio;case 536870922:return this.global.scriptDelay;case 553648170:return this.global.smallMoleculeMaxAtoms;case 553648184:return this.global.strutSpacing}J.util.Logger.error("viewer.getInt("+J.script.T.nameOf(a)+") - not listed");return 0},"~N");$_M(c$,"getDelayMaximumMs",function(){return this.haveDisplay?
this.global.delayMaximumMs:1});$_M(c$,"getHermiteLevel",function(){return this.getSpinOn()?0:this.global.hermiteLevel});$_M(c$,"getHoverDelay",function(){return this.global.modelKitMode?20:this.global.hoverDelayMs});Clazz.overrideMethod(c$,"getBoolean",function(a){switch(a){case 1074790662:return this.modelSet.getModelSetAuxiliaryInfoBoolean("isPDB");case 603979780:return this.global.allowGestures;case 603979784:return this.global.allowMultiTouch;case 603979785:return this.global.allowRotateSelected;
case 603979792:return this.global.appendNew;case 603979794:return this.global.applySymmetryToBonds;case 603979796:return this.global.atomPicking;case 603979798:return this.global.autoBond;case 603979800:return this.global.autoFps;case 603979806:return this.global.axesOrientationRasmol;case 603979812:return this.global.bondModeOr;case 603979817:return this.global.cartoonBaseEdges;case 603979819:return this.global.cartoonFancy;case 603979820:return this.global.cartoonLadders;case 603979818:return this.global.cartoonRockets;
case 603979822:return this.global.chainCaseSensitive||0<this.chainList.size();case 603979824:return this.global.debugScript;case 603979825:return this.global.defaultStructureDSSP;case 603979826:return this.global.disablePopupMenu;case 603979828:return this.global.displayCellParameters;case 603979830:return this.global.dotSurface;case 603979829:return this.global.dotsSelectedOnly;case 603979833:return this.global.drawPicking;case 603979835:return this.global.dynamicMeasurements;case 603979844:return this.global.fontCaching;
case 603979845:return this.global.fontScaling;case 603979846:return this.global.forceAutoBond;case 603979848:return this.global.fractionalRelative;case 603979850:return this.global.greyscaleRendering;case 603979852:return this.global.hbondsBackbone;case 603979853:return this.global.hbondsRasmol;case 603979854:return this.global.hbondsSolid;case 1613758470:return this.global.rasmolHeteroSetting;case 603979858:return this.global.hideNameInPopup;case 603979864:return this.global.highResolutionFlag;case 1613758476:return this.global.rasmolHydrogenSetting;
case 603979870:return this.global.isosurfaceKey;case 603979872:return this.global.justifyMeasurements;case 603979874:return this.global.legacyAutoBonding;case 603979875:return this.global.legacyHAddition;case 603979877:return this.global.logGestures;case 603979878:return this.global.measureAllModels;case 603979879:return this.global.measurementLabels;case 603979880:return this.global.messageStyleChime;case 603979883:return this.global.modelKitMode;case 603979887:return this.global.navigationMode;
case 603979888:return this.global.navigationPeriodic;case 603979889:return this.global.partialDots;case 603979892:return this.global.pdbSequential;case 603979894:return this.global.preserveState;case 603979898:return this.global.ribbonBorder;case 603979900:return this.global.rocketBarrels;case 603979906:return this.global.selectAllModels;case 603979920:return this.global.showHiddenSelectionHalos;case 603979922:return this.global.showHydrogens;case 603979926:return this.global.showMeasurements;case 603979928:return this.global.showMultipleBonds;
case 603979934:return this.global.showTiming;case 603979938:return this.global.slabByAtom;case 603979940:return this.global.slabByMolecule;case 603979944:return this.global.smartAromatic;case 1613758488:return this.global.solventOn;case 603979952:return this.global.ssbondsBackbone;case 603979955:return this.global.strutsMultiple;case 603979966:return this.global.traceAlpha;case 603979967:return this.global.translucent;case 603979968:return this.global.twistedSheets;case 603979973:return this.global.vectorSymmetry;
case 603979974:return this.global.waitForMoveTo;case 603979978:return this.global.zeroBasedXyzRasmol}J.util.Logger.error("viewer.getBoolean("+J.script.T.nameOf(a)+") - not listed");return!1},"~N");$_M(c$,"allowEmbeddedScripts",function(){return this.global.allowEmbeddedScripts&&!this.$isPreviewOnly});$_M(c$,"getDragSelected",function(){return this.global.dragSelected&&!this.global.modelKitMode});$_M(c$,"getBondPicking",function(){return this.global.bondPicking||this.global.modelKitMode});$_M(c$,"useMinimizationThread",
function(){return this.global.useMinimizationThread&&!this.autoExit});Clazz.overrideMethod(c$,"getFloat",function(a){switch(a){case 570425346:return this.global.axesScale;case 570425348:return this.global.bondTolerance;case 570425354:return this.global.defaultTranslucent;case 570425352:return this.global.defaultDrawArrowScale;case 570425355:return this.global.dipoleScale;case 570425356:return this.global.drawFontSize;case 570425358:return this.global.exportScale;case 570425360:return this.global.hbondsAngleMinimum;
case 570425361:return this.global.hbondsDistanceMaximum;case 570425363:return this.global.loadAtomDataTolerance;case 570425364:return this.global.minBondDistance;case 570425369:return this.global.multipleBondSpacing;case 570425368:return this.global.multipleBondRadiusFactor;case 570425374:return this.global.navigationSpeed;case 570425382:return this.global.pointGroupDistanceTolerance;case 570425384:return this.global.pointGroupLinearTolerance;case 570425388:return this.transformManager.getRotationRadius();
case 570425392:return this.global.sheetSmoothing;case 570425394:return this.global.solventProbeRadius;case 570425403:return this.global.starScale;case 570425406:return this.global.strutDefaultRadius;case 570425408:return this.global.strutLengthMaximum;case 1649410049:return this.global.vectorScale;case 570425412:return this.global.vibrationPeriod}J.util.Logger.error("viewer.getFloat("+J.script.T.nameOf(a)+") - not listed");return 0},"~N");Clazz.overrideMethod(c$,"setStringProperty",function(a,b){if(null!=
b)if("_"==a.charAt(0))this.global.setS(a,b);else{var c=J.script.T.getTokFromName(a);switch(J.script.T.getParamType(c)){case 603979776:this.setBooleanPropertyTok(a,c,J.script.SV.newVariable(4,b).asBoolean());break;case 553648128:this.setIntPropertyTok(a,c,J.script.SV.newVariable(4,b).asInt());break;case 570425344:this.setFloatPropertyTok(a,c,JU.ParserJS.parseFloat(b));break;default:this.setStringPropertyTok(a,c,b)}}},"~S,~S");$_M(c$,"setStringPropertyTok",($fz=function(a,b,c){switch(b){case 545259521:this.setAnimationMode(c);
return;case 545259569:this.global.nmrPredictFormat=c;break;case 545259548:this.global.defaultDropScript=c;break;case 545259571:c=this.fileManager.setPathForAllFiles(c);break;case 545259558:this.setUnits(c,!1);return;case 545259560:this.global.forceField=c="UFF".equalsIgnoreCase(c)?"UFF":"MMFF";this.minimizer=null;break;case 545259570:this.global.nmrUrlFormat=c;break;case 545259568:this.setUnits(c,!0);return;case 545259566:this.global.loadLigandFormat=c;break;case 545259543:this.global.defaultLabelPDB=
c;break;case 545259544:this.global.defaultLabelXYZ=c;break;case 545259549:this.global.defaultLoadFilter=c;break;case 545259567:c=this.getOutputManager().setLogFile(c);if(null==c)return;break;case 545259559:break;case 545259524:this.global.atomTypes=c;break;case 545259538:break;case 545259576:this.global.pickLabel=c;break;case 545259580:this.global.quaternionFrame=2==c.length&&c.startsWith("R")?c.substring(0,2):""+(c.toLowerCase()+"p").charAt(0);J.util.Parser.isOneOf(this.global.quaternionFrame,"RC;RP;a;b;c;n;p;q;x;")||
(this.global.quaternionFrame="p");this.modelSet.setHaveStraightness(!1);break;case 545259555:this.setDefaultVdw(c);return;case 545259564:new J.i18n.GT(c);this.language=J.i18n.GT.getLanguage();this.modelkitPopup=null;null!=this.jmolpopup&&(this.jmolpopup.jpiDispose(),this.jmolpopup=null,this.getPopupMenu());this.statusManager.setCallbackFunction("language",this.language);c=J.i18n.GT.getLanguage();break;case 545259565:this.global.loadFormat=c;break;case 545259534:this.setObjectColor("background",c);
return;case 545259528:this.setObjectColor("axis1",c);return;case 545259530:this.setObjectColor("axis2",c);return;case 545259532:this.setObjectColor("axis3",c);return;case 545259536:this.setObjectColor("boundbox",c);return;case 545259586:this.setObjectColor("unitcell",c);return;case 545259578:this.setPropertyColorScheme(c,!1,!1);break;case 545259562:this.setShapeProperty(34,"atomLabel",c);break;case 545259547:this.global.defaultDistanceLabel=c;break;case 545259542:this.global.defaultAngleLabel=c;break;
case 545259554:this.global.defaultTorsionLabel=c;break;case 545259550:this.global.defaultLoadScript=c;break;case 545259522:this.fileManager.setAppletProxy(c);break;case 545259546:null==c&&(c="");c=c.$replace("\\","/");this.global.defaultDirectory=c;break;case 545259561:this.global.helpPath=c;break;case 545259552:!c.equalsIgnoreCase("RasMol")&&!c.equalsIgnoreCase("PyMOL")&&(c="Jmol");this.setDefaultsType(c);break;case 545259545:this.setDefaultColors(c.equalsIgnoreCase("rasmol"));return;case 545259572:this.setPickingMode(c,
0);return;case 545259574:this.setPickingStyle(c,0);return;case 545259540:break;default:if(a.toLowerCase().endsWith("callback")){this.statusManager.setCallbackFunction(a,0==c.length||c.equalsIgnoreCase("none")?null:c);break}if(!this.global.htNonbooleanParameterValues.containsKey(a.toLowerCase())){this.global.setUserVariable(a,J.script.SV.newVariable(4,c));return}}this.global.setS(a,c)},$fz.isPrivate=!0,$fz),"~S,~N,~S");Clazz.overrideMethod(c$,"setFloatProperty",function(a,b){if(!Float.isNaN(b))if("_"==
a.charAt(0))this.global.setF(a,b);else{var c=J.script.T.getTokFromName(a);switch(J.script.T.getParamType(c)){case 545259520:this.setStringPropertyTok(a,c,""+b);break;case 603979776:this.setBooleanPropertyTok(a,c,0!=b);break;case 553648128:this.setIntPropertyTok(a,c,Clazz.floatToInt(b));break;default:this.setFloatPropertyTok(a,c,b)}}},"~S,~N");$_M(c$,"setFloatPropertyTok",($fz=function(a,b,c){switch(b){case 570425356:this.global.drawFontSize=c;break;case 570425358:this.global.exportScale=c;break;case 570425403:this.global.starScale=
c;break;case 570425368:this.global.multipleBondRadiusFactor=c;break;case 570425369:this.global.multipleBondSpacing=c;break;case 570425393:this.transformManager.setSlabRange(c);break;case 570425365:this.global.minimizationCriterion=c;break;case 570425359:this.haveDisplay&&this.actionManager.setGestureSwipeFactor(c);break;case 570425366:this.haveDisplay&&this.actionManager.setMouseDragFactor(c);break;case 570425367:this.haveDisplay&&this.actionManager.setMouseWheelFactor(c);break;case 570425408:this.global.strutLengthMaximum=
c;break;case 570425406:this.global.strutDefaultRadius=c;break;case 570425376:this.setSpin("X",Clazz.floatToInt(c));break;case 570425378:this.setSpin("Y",Clazz.floatToInt(c));break;case 570425380:this.setSpin("Z",Clazz.floatToInt(c));break;case 570425370:if(Float.isNaN(c))return;this.setSpin("FPS",Clazz.floatToInt(c));break;case 570425363:this.global.loadAtomDataTolerance=c;break;case 570425360:this.global.hbondsAngleMinimum=c;break;case 570425361:this.global.hbondsDistanceMaximum=c;break;case 570425382:this.global.pointGroupDistanceTolerance=
c;break;case 570425384:this.global.pointGroupLinearTolerance=c;break;case 570425357:this.global.ellipsoidAxisDiameter=c;break;case 570425398:this.setSpin("x",Clazz.floatToInt(c));break;case 570425400:this.setSpin("y",Clazz.floatToInt(c));break;case 570425402:this.setSpin("z",Clazz.floatToInt(c));break;case 570425396:this.setSpin("fps",Clazz.floatToInt(c));break;case 570425352:this.global.defaultDrawArrowScale=c;break;case 570425354:this.global.defaultTranslucent=c;break;case 570425346:this.setAxesScale(c);
break;case 570425416:this.transformManager.setVisualRange(c);this.refresh(1,"set visualRange");break;case 570425371:this.setNavigationDepthPercent(c);break;case 570425374:this.global.navigationSpeed=c;break;case 570425372:this.transformManager.setNavigationSlabOffsetPercent(c);break;case 570425350:this.transformManager.setCameraDepthPercent(c,!1);this.refresh(1,"set cameraDepth");return;case 570425388:this.setRotationRadius(c,!0);return;case 570425362:this.global.hoverDelayMs=Clazz.floatToInt(1E3*
c);break;case 570425392:this.global.sheetSmoothing=c;break;case 570425355:c=J.viewer.Viewer.checkFloatRange(c,-10,10);this.global.dipoleScale=c;break;case 570425404:this.transformManager.setStereoDegrees(c);break;case 1649410049:this.setVectorScale(c);return;case 570425412:this.setVibrationPeriod(c);return;case 570425414:this.setVibrationScale(c);return;case 570425348:this.setBondTolerance(c);return;case 570425364:this.setMinBondDistance(c);return;case 570425390:this.transformManager.setScaleAngstromsPerInch(c);
break;case 570425394:c=J.viewer.Viewer.checkFloatRange(c,0,10);this.global.solventProbeRadius=c;break;default:if(!this.global.htNonbooleanParameterValues.containsKey(a.toLowerCase())){this.global.setUserVariable(a,J.script.SV.newVariable(3,Float.$valueOf(c)));return}}this.global.setF(a,c)},$fz.isPrivate=!0,$fz),"~S,~N,~N");Clazz.overrideMethod(c$,"setIntProperty",function(a,b){if(-2147483648!=b)if("_"==a.charAt(0))this.global.setI(a,b);else{var c=J.script.T.getTokFromName(a);switch(J.script.T.getParamType(c)){case 545259520:this.setStringPropertyTok(a,
c,""+b);break;case 603979776:this.setBooleanPropertyTok(a,c,0!=b);break;case 570425344:this.setFloatPropertyTok(a,c,b);break;default:this.setIntPropertyTok(a,c,b)}}},"~S,~N");$_M(c$,"setIntPropertyTok",($fz=function(a,b,c){switch(b){case 553648158:this.global.platformSpeed=Math.min(Math.max(c,0),10);break;case 553648151:this.global.meshScale=c;break;case 553648153:this.global.minPixelSelRadius=c;break;case 553648149:this.global.isosurfacePropertySmoothingPower=c;break;case 553648165:this.global.repaintWaitMs=
c;break;case 553648170:this.global.smallMoleculeMaxAtoms=c;break;case 553648152:this.global.minimizationSteps=c;break;case 553648184:this.global.strutSpacing=c;break;case 553648156:c=J.viewer.Viewer.checkIntRange(c,0,1E3);this.gdata.setPhongExponent(c);break;case 553648146:this.global.helixStep=c;this.modelSet.setHaveStraightness(!1);break;case 553648144:this.global.dotScale=c;break;case 553648143:this.global.dotDensity=c;break;case 553648138:this.global.delayMaximumMs=c;break;case 553648150:J.util.Logger.setLogLevel(c);
J.util.Logger.info("logging level set to "+c);this.global.setI("logLevel",c);null!=this.eval&&this.eval.setDebugging();return;case 553648134:switch(J.constant.EnumAxesMode.getAxesMode(c)){case J.constant.EnumAxesMode.MOLECULAR:this.setAxesModeMolecular(!0);break;case J.constant.EnumAxesMode.BOUNDBOX:this.setAxesModeMolecular(!1);break;case J.constant.EnumAxesMode.UNITCELL:this.setAxesModeUnitCell(!0)}return;case 553648178:this.setStrandCount(0,c);return;case 553648182:this.setStrandCount(12,c);return;
case 553648180:this.setStrandCount(13,c);return;case 553648155:return;case 536870922:this.global.scriptDelay=c;break;case 553648176:c=0>c?J.viewer.Viewer.checkIntRange(c,-10,-1):J.viewer.Viewer.checkIntRange(c,0,100);this.gdata.setSpecularPower(c);break;case 553648172:c=J.viewer.Viewer.checkIntRange(-c,-10,-1);this.gdata.setSpecularPower(c);break;case 553648136:this.setMarBond(c);return;case 536870924:this.setBooleanPropertyTok(a,b,1==c);return;case 553648174:c=J.viewer.Viewer.checkIntRange(c,0,100);
this.gdata.setSpecularPercent(c);break;case 553648142:c=J.viewer.Viewer.checkIntRange(c,0,100);this.gdata.setDiffusePercent(c);break;case 553648130:c=J.viewer.Viewer.checkIntRange(c,0,100);this.gdata.setAmbientPercent(c);break;case 553648186:this.transformManager.zDepthToPercent(c);break;case 553648188:this.transformManager.zSlabToPercent(c);break;case 554176526:this.transformManager.depthToPercent(c);break;case 554176565:this.transformManager.slabToPercent(c);break;case 553648190:this.global.zShadePower=
Math.max(c,1);break;case 553648166:this.global.ribbonAspectRatio=c;break;case 553648157:this.global.pickingSpinRate=1>c?1:c;break;case 553648132:this.setAnimationFps(c);return;case 553648154:this.setPercentVdwAtom(c);break;case 553648147:this.global.hermiteLevel=c;break;case 553648145:case 553648148:case 553648160:case 553648159:case 553648162:case 553648164:break;default:if(!this.global.htNonbooleanParameterValues.containsKey(a)){this.global.setUserVariable(a,J.script.SV.newScriptVariableInt(c));
return}}this.global.setI(a,c)},$fz.isPrivate=!0,$fz),"~S,~N,~N");c$.checkIntRange=$_M(c$,"checkIntRange",($fz=function(a,b,c){return a<b?b:a>c?c:a},$fz.isPrivate=!0,$fz),"~N,~N,~N");c$.checkFloatRange=$_M(c$,"checkFloatRange",($fz=function(a,b,c){return a<b?b:a>c?c:a},$fz.isPrivate=!0,$fz),"~N,~N,~N");Clazz.overrideMethod(c$,"setBooleanProperty",function(a,b){if("_"==a.charAt(0))this.global.setB(a,b);else{var c=J.script.T.getTokFromName(a);switch(J.script.T.getParamType(c)){case 545259520:this.setStringPropertyTok(a,
c,"");break;case 553648128:this.setIntPropertyTok(a,c,b?1:0);break;case 570425344:this.setFloatPropertyTok(a,c,b?1:0);break;default:this.setBooleanPropertyTok(a,c,b)}}},"~S,~B");$_M(c$,"setBooleanPropertyTok",($fz=function(a,b,c){var d=!0;switch(b){case 603979837:this.global.ellipsoidArrows=c;break;case 603979967:this.global.translucent=c;break;case 603979820:this.global.cartoonLadders=c;break;case 603979968:b=this.global.twistedSheets;this.global.twistedSheets=c;b!=c&&this.checkCoordinatesChanged();
break;case 603979821:this.global.celShading=c;this.gdata.setCel(c);break;case 603979819:this.global.cartoonFancy=c;break;case 603979934:this.global.showTiming=c;break;case 603979973:this.global.vectorSymmetry=c;break;case 603979870:this.global.isosurfaceKey=c;break;case 603979889:this.global.partialDots=c;break;case 603979874:this.global.legacyAutoBonding=c;break;case 603979825:this.global.defaultStructureDSSP=c;break;case 603979834:this.global.dsspCalcHydrogen=c;break;case 603979782:(this.global.allowModelkit=
c)||this.setModelKitMode(!1);break;case 603979883:this.setModelKitMode(c);break;case 603979885:this.global.multiProcessor=c&&1<J.viewer.Viewer.nProcessors;break;case 603979884:this.global.monitorEnergy=c;break;case 603979853:this.global.hbondsRasmol=c;break;case 603979881:this.global.minimizationRefresh=c;break;case 603979882:this.global.minimizationSilent=c;break;case 603979969:this.global.useArcBall=c;break;case 603979869:c&&(this.$isKiosk=!0,this.global.disablePopupMenu=!0,null!=this.display&&
this.apiPlatform.setTransparentCursor(this.display));break;case 603979974:this.global.waitForMoveTo=c;break;case 603979876:this.global.logCommands=!0;break;case 603979877:this.global.logGestures=!0;break;case 603979784:this.global.allowMultiTouch=c;break;case 603979894:this.global.preserveState=c;this.modelSet.setPreserveState(c);this.undoClear();break;case 603979955:this.global.strutsMultiple=c;break;case 603979842:break;case 603979938:this.global.slabByAtom=c;break;case 603979940:this.global.slabByMolecule=
c;break;case 603979902:this.global.saveProteinStructureState=c;break;case 603979780:this.global.allowGestures=c;break;case 603979868:this.global.imageState=c;break;case 603979970:this.global.useMinimizationThread=c;break;case 603979781:this.global.disablePopupMenu&&(c=!1);this.global.allowKeyStrokes=c;break;case 603979831:this.global.dragSelected=c;this.showSelected=!1;break;case 603979924:this.global.showKeyStrokes=c;break;case 603979844:this.global.fontCaching=c;break;case 603979796:this.global.atomPicking=
c;break;case 603979814:this.highlight(null);this.global.bondPicking=c;break;case 603979906:this.global.selectAllModels=c;break;case 603979880:this.global.messageStyleChime=c;break;case 603979892:this.global.pdbSequential=c;break;case 603979890:this.global.pdbAddHydrogens=c;break;case 603979891:this.global.pdbGetHeader=c;break;case 603979838:this.global.ellipsoidAxes=c;break;case 603979836:this.global.ellipsoidArcs=c;break;case 603979839:this.global.ellipsoidBall=c;break;case 603979840:this.global.ellipsoidDots=
c;break;case 603979841:this.global.ellipsoidFill=c;break;case 603979845:this.global.fontScaling=c;break;case 603979956:this.setSyncTarget(0,c);break;case 603979958:this.setSyncTarget(1,c);break;case 603979976:this.global.wireframeRotation=c;break;case 603979871:this.global.isosurfacePropertySmoothing=c;break;case 603979833:this.global.drawPicking=c;break;case 603979786:case 603979790:case 603979788:this.setAntialias(b,c);break;case 603979944:this.global.smartAromatic=c;break;case 603979794:this.setApplySymmetryToBonds(c);
break;case 603979792:this.setAppendNew(c);break;case 603979800:this.global.autoFps=c;break;case 603979972:JU.DecimalFormat.setUseNumberLocalization(this.global.useNumberLocalization=c);break;case 1611272202:a="showFrank";this.setFrankOn(c);break;case 603979918:this.setFrankOn(c);break;case 1613758488:a="solventProbe";this.global.solventOn=c;break;case 603979948:this.global.solventOn=c;break;case 603979835:this.setDynamicMeasurements(c);break;case 603979785:this.global.allowRotateSelected=c;break;
case 603979783:this.global.allowMoveAtoms=c;this.global.allowRotateSelected=c;this.global.dragSelected=c;this.showSelected=!1;break;case 536870922:this.setIntPropertyTok("showScript",b,c?1:0);return;case 603979778:this.global.allowEmbeddedScripts=c;break;case 603979888:this.global.navigationPeriodic=c;break;case 603979984:this.transformManager.setZShadeEnabled(c);return;case 603979832:this.haveDisplay&&(this.global.drawHover=c);break;case 603979887:this.setNavigationMode(c);break;case 603979886:return;
case 603979860:this.global.hideNavigationPoint=c;break;case 603979930:this.global.showNavigationPointAlways=c;break;case 603979896:this.setRefreshing(c);break;case 603979872:this.global.justifyMeasurements=c;break;case 603979952:this.global.ssbondsBackbone=c;break;case 603979852:this.global.hbondsBackbone=c;break;case 603979854:this.global.hbondsSolid=c;break;case 536870924:this.gdata.setSpecular(c);break;case 603979942:this.transformManager.setSlabEnabled(c);return;case 603979980:this.transformManager.setZoomEnabled(c);
return;case 603979864:this.global.highResolutionFlag=c;break;case 603979966:this.global.traceAlpha=c;break;case 603979983:this.global.zoomLarge=c;this.transformManager.setZoomHeight(this.global.zoomHeight,c);break;case 603979982:this.global.zoomHeight=c;this.transformManager.setZoomHeight(c,this.global.zoomLarge);break;case 603979873:J.i18n.GT.setDoTranslate(c);break;case 603979862:this.selectionManager.setHideNotSelected(c);break;case 603979904:this.setScriptQueue(c);break;case 603979830:this.global.dotSurface=
c;break;case 603979829:this.global.dotsSelectedOnly=c;break;case 1611141171:this.setSelectionHalos(c);break;case 603979910:this.global.rasmolHydrogenSetting=c;break;case 603979908:this.global.rasmolHeteroSetting=c;break;case 603979928:this.global.showMultipleBonds=c;break;case 603979920:this.global.showHiddenSelectionHalos=c;break;case 603979975:this.transformManager.setWindowCentered(c);break;case 603979828:this.global.displayCellParameters=c;break;case 603979960:this.global.testFlag1=c;break;case 603979962:this.global.testFlag2=
c;break;case 603979964:this.global.testFlag3=c;break;case 603979965:this.jmolTest();this.global.testFlag4=c;break;case 603979898:this.global.ribbonBorder=c;break;case 603979817:this.global.cartoonBaseEdges=c;break;case 603979818:this.global.cartoonRockets=c;break;case 603979900:this.global.rocketBarrels=c;break;case 603979850:this.gdata.setGreyscaleMode(this.global.greyscaleRendering=c);break;case 603979879:this.global.measurementLabels=c;break;case 603979810:this.setAxesModeMolecular(!c);return;
case 603979804:this.setAxesModeMolecular(c);return;case 603979808:this.setAxesModeUnitCell(c);return;case 603979806:this.setAxesOrientationRasmol(c);return;case 603979823:this.setStringPropertyTok("defaultcolorscheme",545259545,c?"rasmol":"jmol");return;case 603979824:this.setDebugScript(c);return;case 603979893:this.setPerspectiveDepth(c);return;case 603979798:this.setAutoBond(c);return;case 603979914:this.setShowAxes(c);return;case 603979916:this.setShowBbcage(c);return;case 603979922:this.setShowHydrogens(c);
return;case 603979926:this.setShowMeasurements(c);return;case 603979936:this.setShowUnitCell(c);return;case 603979812:d=!1;this.global.bondModeOr=c;break;case 603979978:d=!1;this.global.zeroBasedXyzRasmol=c;this.reset(!0);break;case 603979895:d=!1;this.global.rangeSelected=c;break;case 603979878:d=!1;this.global.measureAllModels=c;break;case 603979954:d=!1;this.statusManager.setAllowStatusReporting(c);break;case 603979822:d=!1;this.global.chainCaseSensitive=c;break;case 603979858:d=!1;this.global.hideNameInPopup=
c;break;case 603979826:d=!1;this.global.disablePopupMenu=c;break;case 603979846:d=!1;this.global.forceAutoBond=c;break;case 603979848:d=!1;this.global.fractionalRelative=c;break;default:if(!this.global.htBooleanParameterFlags.containsKey(a.toLowerCase())){this.global.setUserVariable(a,J.script.SV.getBoolean(c));return}}this.global.setB(a,c);d&&this.setTainted(!0)},$fz.isPrivate=!0,$fz),"~S,~N,~B");$_M(c$,"setModelKitMode",($fz=function(a){if(null!=this.actionManager&&this.allowScripting){if(a||this.global.modelKitMode)this.setPickingMode(null,
a?33:1),this.setPickingMode(null,a?32:1);var b=this.global.modelKitMode!=a;this.global.modelKitMode=a;this.highlight(null);a?(this.setNavigationMode(!1),this.selectAll(),this.setAtomPickingOption("C"),this.setBondPickingOption("p"),this.$isApplet||this.popupMenu(0,0,"m"),b&&this.statusManager.setCallbackFunction("modelkit","ON"),this.global.modelKitMode=!0,0==this.getAtomCount()&&this.zap(!1,!0,!0)):(this.actionManager.setPickingMode(-1),this.setStringProperty("pickingStyle","toggle"),this.setBooleanProperty("bondPicking",
!1),b&&this.statusManager.setCallbackFunction("modelkit","OFF"))}},$fz.isPrivate=!0,$fz),"~B");$_M(c$,"getLanguage",function(){return this.language});$_M(c$,"setSmilesString",function(a){null==a?this.global.removeParam("_smilesString"):this.global.setS("_smilesString",a)},"~S");$_M(c$,"removeUserVariable",function(a){this.global.removeUserVariable(a);a.endsWith("callback")&&this.statusManager.setCallbackFunction(a,null)},"~S");$_M(c$,"isJmolVariable",function(a){return this.global.isJmolVariable(a)},
"~S");$_M(c$,"jmolTest",($fz=function(){},$fz.isPrivate=!0,$fz));$_M(c$,"showParameter",function(a,b,c){c=""+this.global.getParameterEscaped(a,c);(b||0>c.indexOf("<not defined>"))&&this.showString(a+" = "+c,!1)},"~S,~B,~N");$_M(c$,"showString",function(a,b){this.isScriptQueued()&&((!this.isSilent||b)&&!this.isJS)&&J.util.Logger.warn(a);this.scriptEcho(a)},"~S,~B");$_M(c$,"getAllSettings",function(a){return this.getStateCreator().getAllSettings(a)},"~S");$_M(c$,"getBindingInfo",function(a){return this.haveDisplay?
this.actionManager.getBindingInfo(a):""},"~S");$_M(c$,"getIsosurfacePropertySmoothing",function(a){return a?this.global.isosurfacePropertySmoothingPower:this.global.isosurfacePropertySmoothing?1:0},"~B");$_M(c$,"setNavigationDepthPercent",function(a){this.transformManager.setNavigationDepthPercent(a);this.refresh(1,"set navigationDepth")},"~N");$_M(c$,"getShowNavigationPoint",function(){return!this.global.navigationMode||!this.transformManager.canNavigate()?!1:this.isNavigating()&&!this.global.hideNavigationPoint||
this.global.showNavigationPointAlways||this.getInMotion(!0)});$_M(c$,"getCurrentSolventProbeRadius",function(){return this.global.solventOn?this.global.solventProbeRadius:0});$_M(c$,"getTestFlag",function(a){switch(a){case 1:return this.global.testFlag1;case 2:return this.global.testFlag2;case 3:return this.global.testFlag3;case 4:return this.global.testFlag4}return!1},"~N");Clazz.overrideMethod(c$,"setPerspectiveDepth",function(a){this.transformManager.setPerspectiveDepth(a)},"~B");Clazz.overrideMethod(c$,
"setAxesOrientationRasmol",function(a){this.global.setB("axesOrientationRasmol",a);this.global.axesOrientationRasmol=a;this.reset(!0)},"~B");$_M(c$,"setAxesScale",function(a){a=J.viewer.Viewer.checkFloatRange(a,-100,100);this.global.axesScale=a;this.axesAreTainted=!0},"~N");$_M(c$,"getAxisPoints",function(){return 0==this.getObjectMad(1)||this.getAxesMode()!==J.constant.EnumAxesMode.UNITCELL||this.getShapeProperty(31,"axesTypeXY").booleanValue()||null!=this.getShapeProperty(31,"origin")?null:this.getShapeProperty(31,
"axisPoints")});$_M(c$,"resetError",function(){this.global.removeParam("_errormessage")});$_M(c$,"setAxesModeMolecular",($fz=function(a){this.global.axesMode=a?J.constant.EnumAxesMode.MOLECULAR:J.constant.EnumAxesMode.BOUNDBOX;this.axesAreTainted=!0;this.global.removeParam("axesunitcell");this.global.removeParam(a?"axeswindow":"axesmolecular");this.global.setI("axesMode",this.global.axesMode.getCode());this.global.setB(a?"axesMolecular":"axesWindow",!0)},$fz.isPrivate=!0,$fz),"~B");$_M(c$,"setAxesModeUnitCell",
function(a){this.global.axesMode=a?J.constant.EnumAxesMode.UNITCELL:J.constant.EnumAxesMode.BOUNDBOX;this.axesAreTainted=!0;this.global.removeParam("axesmolecular");this.global.removeParam(a?"axeswindow":"axesunitcell");this.global.setB(a?"axesUnitcell":"axesWindow",!0);this.global.setI("axesMode",this.global.axesMode.getCode())},"~B");$_M(c$,"getAxesMode",function(){return this.global.axesMode});Clazz.overrideMethod(c$,"getPerspectiveDepth",function(){return this.transformManager.getPerspectiveDepth()});
Clazz.overrideMethod(c$,"setSelectionHalos",function(a){null==this.modelSet||a==this.modelSet.getSelectionHaloEnabled()||(this.global.setB("selectionHalos",a),this.loadShape(8),this.modelSet.setSelectionHaloEnabled(a))},"~B");$_M(c$,"getSelectionHaloEnabled",function(a){var b=this.modelSet.getSelectionHaloEnabled()||a&&this.showSelected;a&&(this.showSelected=!1);return b},"~B");$_M(c$,"setStrandCount",($fz=function(a,b){b=J.viewer.Viewer.checkIntRange(b,0,20);switch(a){case 12:this.global.strandCountForStrands=
b;break;case 13:this.global.strandCountForMeshRibbon=b;break;default:this.global.strandCountForStrands=b,this.global.strandCountForMeshRibbon=b}this.global.setI("strandCount",b);this.global.setI("strandCountForStrands",this.global.strandCountForStrands);this.global.setI("strandCountForMeshRibbon",this.global.strandCountForMeshRibbon)},$fz.isPrivate=!0,$fz),"~N,~N");$_M(c$,"getStrandCount",function(a){return 12==a?this.global.strandCountForStrands:this.global.strandCountForMeshRibbon},"~N");$_M(c$,
"setNavigationMode",function(a){this.global.navigationMode=a;this.transformManager.setNavigationMode(a)},"~B");$_M(c$,"setTransformManagerDefaults",($fz=function(){this.transformManager.setCameraDepthPercent(this.global.defaultCameraDepth,!0);this.transformManager.setPerspectiveDepth(this.global.defaultPerspectiveDepth);this.transformManager.setStereoDegrees(-5);this.transformManager.setVisualRange(this.global.visualRange);this.transformManager.setSpinOff();this.transformManager.setVibrationPeriod(0);
this.transformManager.setFrameOffsets(this.frameOffsets)},$fz.isPrivate=!0,$fz));$_M(c$,"getCameraFactors",function(){return this.transformManager.getCameraFactors()});$_M(c$,"getCameraDepth",function(){return this.transformManager.getCameraDepth()});$_M(c$,"getLoadState",function(a){return this.getStateCreator().getLoadState(a)},"java.util.Map");Clazz.overrideMethod(c$,"setAutoBond",function(a){this.global.setB("autobond",a);this.global.autoBond=a},"~B");$_M(c$,"makeConnections",function(a,b,c,d,
e,f,g,h,k,l){this.clearModelDependentObjects();this.clearMinimization();return this.modelSet.makeConnections(a,b,c,d,e,f,g,h,k,l)},"~N,~N,~N,~N,JU.BS,JU.BS,JU.BS,~B,~B,~N");Clazz.overrideMethod(c$,"rebond",function(){this.rebondState(!1)});$_M(c$,"rebondState",function(a){this.clearModelDependentObjects();this.modelSet.deleteAllBonds();a=a&&this.global.legacyAutoBonding;this.modelSet.autoBondBs4(null,null,null,null,this.getMadBond(),a);this.addStateScript(a?"set legacyAutoBonding TRUE;connect;set legacyAutoBonding FALSE;":
"connect;",!1,!0)},"~B");$_M(c$,"setPdbConectBonding",function(a,b){this.clearModelDependentObjects();this.modelSet.deleteAllBonds();var c=new JU.BS;this.modelSet.setPdbConectBonding(0,0,c);if(a){var d=b&&this.global.legacyAutoBonding;this.modelSet.autoBondBs4(null,null,c,null,this.getMadBond(),d);this.addStateScript(d?"set legacyAutoBonding TRUE;connect PDB AUTO;set legacyAutoBonding FALSE;":"connect PDB auto;",!1,!0)}else this.addStateScript("connect PDB;",!1,!0)},"~B,~B");Clazz.overrideMethod(c$,
"setPercentVdwAtom",function(a){this.global.setI("percentVdwAtom",a);this.global.percentVdwAtom=a;this.rd.value=a/100;this.rd.factorType=J.atomdata.RadiusData.EnumType.FACTOR;this.rd.vdwType=J.constant.EnumVdw.AUTO;this.setShapeSizeRD(0,this.rd,null)},"~N");$_M(c$,"getDefaultRadiusData",function(){return this.rd});Clazz.overrideMethod(c$,"getMadBond",function(){return 2*this.global.bondRadiusMilliAngstroms});$_M(c$,"getMarBond",function(){return this.global.bondRadiusMilliAngstroms});$_M(c$,"getModeMultipleBond",
function(){return this.global.modeMultipleBond});Clazz.overrideMethod(c$,"setShowHydrogens",function(a){this.global.setB("showHydrogens",a);this.global.showHydrogens=a},"~B");Clazz.overrideMethod(c$,"setShowBbcage",function(a){this.setObjectMad(32,"boundbox",a?-4:0);this.global.setB("showBoundBox",a)},"~B");Clazz.overrideMethod(c$,"getShowBbcage",function(){return 0!=this.getObjectMad(4)});$_M(c$,"setShowUnitCell",function(a){this.setObjectMad(33,"unitcell",a?-2:0);this.global.setB("showUnitCell",
a)},"~B");$_M(c$,"getShowUnitCell",function(){return 0!=this.getObjectMad(5)});Clazz.overrideMethod(c$,"setShowAxes",function(a){this.setObjectMad(31,"axes",a?-2:0);this.global.setB("showAxes",a)},"~B");Clazz.overrideMethod(c$,"getShowAxes",function(){return 0!=this.getObjectMad(1)});Clazz.overrideMethod(c$,"setFrankOn",function(a){this.$isPreviewOnly&&(a=!1);this.frankOn=a;this.setObjectMad(35,"frank",a?1:0)},"~B");$_M(c$,"getShowFrank",function(){return this.$isPreviewOnly||this.$isApplet&&this.creatingImage?
!1:!this.isJS&&this.$isSignedApplet&&!this.isSignedAppletLocal||this.frankOn});Clazz.overrideMethod(c$,"setShowMeasurements",function(a){this.global.setB("showMeasurements",a);this.global.showMeasurements=a},"~B");$_M(c$,"setUnits",function(a,b){this.global.setUnits(a);b&&(this.global.setUnits(a),this.setShapeProperty(6,"reformatDistances",null))},"~S,~B");$_M(c$,"getMeasureDistanceUnits",function(){return this.global.measureDistanceUnits});$_M(c$,"getEnergyUnits",function(){return this.global.energyUnits});
$_M(c$,"setAppendNew",function(a){this.global.appendNew=a},"~B");Clazz.overrideMethod(c$,"setRasmolDefaults",function(){this.setDefaultsType("RasMol")});Clazz.overrideMethod(c$,"setJmolDefaults",function(){this.setDefaults()});$_M(c$,"setDefaultsType",($fz=function(a){a.equalsIgnoreCase("RasMol")?this.stateManager.setRasMolDefaults():a.equalsIgnoreCase("PyMOL")?this.stateManager.setPyMOLDefaults():this.setDefaults()},$fz.isPrivate=!0,$fz),"~S");$_M(c$,"setDefaults",($fz=function(){this.setShapeSizeRD(0,
this.rd,this.getModelUndeletedAtomsBitSet(-1))},$fz.isPrivate=!0,$fz));$_M(c$,"setAntialias",($fz=function(a,b){switch(a){case 603979786:this.global.antialiasDisplay=b;break;case 603979790:this.global.antialiasTranslucent=b;break;case 603979788:this.global.antialiasImages=b;return}this.resizeImage(0,0,!1,!1,!0)},$fz.isPrivate=!0,$fz),"~N,~B");$_M(c$,"allocTempPoints",function(a){return this.tempArray.allocTempPoints(a)},"~N");$_M(c$,"freeTempPoints",function(a){this.tempArray.freeTempPoints(a)},"~A");
$_M(c$,"allocTempScreens",function(a){return this.tempArray.allocTempScreens(a)},"~N");$_M(c$,"freeTempScreens",function(a){this.tempArray.freeTempScreens(a)},"~A");$_M(c$,"allocTempEnum",function(a){return this.tempArray.allocTempEnum(a)},"~N");$_M(c$,"freeTempEnum",function(a){this.tempArray.freeTempEnum(a)},"~A");$_M(c$,"getFont3D",function(a,b,c){return this.gdata.getFont3DFSS(a,b,c)},"~S,~S,~N");$_M(c$,"formatText",function(a){if(0>a.indexOf("@{")&&0>a.indexOf("%{"))return a;var b=a,c=0<=b.indexOf("\\");
c&&(b=J.util.Txt.simpleReplace(b,"\\%","\u0001"),b=J.util.Txt.simpleReplace(b,"\\@","\u0002"),c=!b.equals(a));for(var b=J.util.Txt.simpleReplace(b,"%{","@{"),d;0<=(a=b.indexOf("@{"));){a++;var e=a+1;d=b.length;a=J.util.Txt.ichMathTerminator(b,a,d);if(a>=d)return b;d=b.substring(e,a);if(0==d.length)return b;d=this.evaluateExpression(d);Clazz.instanceOf(d,JU.P3)&&(d=J.util.Escape.eP(d));b=b.substring(0,e-2)+d.toString()+b.substring(a+1)}c&&(b=J.util.Txt.simpleReplace(b,"\u0002","@"),b=J.util.Txt.simpleReplace(b,
"\u0001","%"));return b},"~S");$_M(c$,"getElementSymbol",function(a){return this.modelSet.getElementSymbol(a)},"~N");$_M(c$,"getElementNumber",function(a){return this.modelSet.getElementNumber(a)},"~N");Clazz.overrideMethod(c$,"getAtomName",function(a){return this.modelSet.getAtomName(a)},"~N");Clazz.overrideMethod(c$,"getAtomNumber",function(a){return this.modelSet.getAtomNumber(a)},"~N");$_M(c$,"getAtomGroupQuaternions",function(a,b){return this.modelSet.getAtomGroupQuaternions(a,b,this.getQuaternionFrame())},
"JU.BS,~N");$_M(c$,"getAtomQuaternion",function(a){return this.modelSet.getQuaternion(a,this.getQuaternionFrame())},"~N");Clazz.overrideMethod(c$,"getAtomPoint3f",function(a){return this.modelSet.atoms[a]},"~N");$_M(c$,"getAtomPointVector",function(a){return this.modelSet.getAtomPointVector(a)},"JU.BS");Clazz.overrideMethod(c$,"getAtomRadius",function(a){return this.modelSet.getAtomRadius(a)},"~N");Clazz.overrideMethod(c$,"getAtomArgb",function(a){return this.gdata.getColorArgbOrGray(this.modelSet.getAtomColix(a))},
"~N");Clazz.overrideMethod(c$,"getAtomModelIndex",function(a){return this.modelSet.atoms[a].modelIndex},"~N");Clazz.overrideMethod(c$,"getBondRadius",function(a){return this.modelSet.getBondRadius(a)},"~N");Clazz.overrideMethod(c$,"getBondOrder",function(a){return this.modelSet.getBondOrder(a)},"~N");$_M(c$,"assignAromaticBonds",function(){this.modelSet.assignAromaticBonds()});$_M(c$,"resetAromatic",function(){this.modelSet.resetAromatic()});Clazz.overrideMethod(c$,"getBondArgb1",function(a){return this.gdata.getColorArgbOrGray(this.modelSet.getBondColix1(a))},
"~N");Clazz.overrideMethod(c$,"getBondModelIndex",function(a){return this.modelSet.getBondModelIndex(a)},"~N");Clazz.overrideMethod(c$,"getBondArgb2",function(a){return this.gdata.getColorArgbOrGray(this.modelSet.getBondColix2(a))},"~N");Clazz.overrideMethod(c$,"getPolymerLeadMidPoints",function(a,b){return this.modelSet.getPolymerLeadMidPoints(a,b)},"~N,~N");$_M(c$,"setStereoMode",function(a,b,c){this.setFloatProperty("stereoDegrees",c);this.setBooleanProperty("greyscaleRendering",b.isBiColor());
null!=a?this.transformManager.setStereoMode2(a):this.transformManager.setStereoMode(b)},"~A,J.constant.EnumStereoMode,~N");$_M(c$,"isStereoDouble",function(){return this.transformManager.stereoMode===J.constant.EnumStereoMode.DOUBLE});Clazz.overrideMethod(c$,"getOperatingSystemName",function(){return J.viewer.Viewer.strOSName+(!this.isJS?"":this.isWebGL?"(WebGL)":"(HTML5)")});Clazz.overrideMethod(c$,"getJavaVendor",function(){return J.viewer.Viewer.strJavaVendor});Clazz.overrideMethod(c$,"getJavaVersion",
function(){return J.viewer.Viewer.strJavaVersion});$_M(c$,"getGraphicsData",function(){return this.gdata});Clazz.overrideMethod(c$,"getProperty",function(a,b,c){if(!"DATA_API".equals(a))return this.getPropertyManager().getProperty(a,b,c);switch("scriptCheck.........consoleText.........scriptEditor........scriptEditorState...getAppConsole.......getScriptEditor.....setMenu.............spaceGroupInfo......disablePopupMenu....defaultDirectory....getPopupMenu........shapeManager........".indexOf(b)){case 0:return this.scriptCheckRet(c,
!0);case 20:return null==this.appConsole?"":this.appConsole.getText();case 40:return this.showEditor(c),null;case 60:return this.scriptEditorVisible=c.booleanValue(),null;case 80:if(this.$isKiosk)this.appConsole=null;else if(Clazz.instanceOf(c,J.api.JmolAppConsoleInterface))this.appConsole=c;else if(null!=c&&!c.booleanValue())this.appConsole=null;else if(null==this.appConsole&&null!=c&&c.booleanValue()){this.appConsole=J.api.Interface.getOptionInterface("consolejs.AppletConsole");if(null!=this.appConsole)return this.appConsole.start(this),
this.appConsole;null!=this.appConsole&&this.appConsole.start(this)}this.scriptEditor=null==this.appConsole?null:this.appConsole.getScriptEditor();return this.appConsole;case 100:return null==this.appConsole&&(null!=c&&c.booleanValue())&&(this.getProperty("DATA_API","getAppConsole",Boolean.TRUE),this.scriptEditor=null==this.appConsole?null:this.appConsole.getScriptEditor()),this.scriptEditor;case 120:return null!=this.jmolpopup&&this.jmolpopup.jpiDispose(),this.jmolpopup=null,this.menuStructure=c;
case 140:return this.getSpaceGroupInfo(null);case 160:return this.global.disablePopupMenu=!0,null;case 180:return this.global.defaultDirectory;case 200:return Clazz.instanceOf(c,String)?this.getMenu(c):this.getPopupMenu();case 220:return this.shapeManager.getProperty(c)}J.util.Logger.error("ERROR in getProperty DATA_API: "+b);return null},"~S,~S,~O");$_M(c$,"showEditor",function(a){var b=this.getProperty("DATA_API","getScriptEditor",Boolean.TRUE);null!=b&&b.show(a)},"~A");$_M(c$,"getPropertyManager",
($fz=function(){null==this.pm&&(this.pm=J.api.Interface.getOptionInterface("viewer.PropertyManager")).setViewer(this);return this.pm},$fz.isPrivate=!0,$fz));$_M(c$,"getModelExtract",function(a,b,c,d){return this.getPropertyManager().getModelExtract(this.getAtomBitSet(a),b,c,d)},"~O,~B,~B,~S");$_M(c$,"setTainted",function(a){this.isTainted=this.axesAreTainted=a&&(this.refreshing||this.creatingImage)},"~B");$_M(c$,"notifyMouseClicked",function(a,b,c,d){var e=J.viewer.binding.Binding.getButtonMods(c),
f=J.viewer.binding.Binding.getClickCount(c);this.global.setI("_mouseX",a);this.global.setI("_mouseY",this.dimScreen.height-b);this.global.setI("_mouseAction",c);this.global.setI("_mouseModifiers",e);this.global.setI("_clickCount",f);return this.statusManager.setStatusClicked(a,this.dimScreen.height-b,c,f,d)},"~N,~N,~N,~N");$_M(c$,"checkObjectClicked",function(a,b,c){return this.shapeManager.checkObjectClicked(a,b,c,this.getVisibleFramesBitSet(),this.global.drawPicking)},"~N,~N,~N");$_M(c$,"checkObjectHovered",
function(a,b){return 0<=a&&null!=this.shapeManager&&this.shapeManager.checkObjectHovered(a,b,this.getVisibleFramesBitSet(),this.getBondPicking())},"~N,~N");$_M(c$,"checkObjectDragged",function(a,b,c,d,e){var f=0;switch(this.getPickingMode()){case 2:f=5;break;case 4:f=22}this.shapeManager.checkObjectDragged(a,b,c,d,e,this.getVisibleFramesBitSet(),f)&&(this.refresh(1,"checkObjectDragged"),22==f&&this.scriptEcho(this.getShapeProperty(22,"command")))},"~N,~N,~N,~N,~N");$_M(c$,"rotateAxisAngleAtCenter",
function(a,b,c,d,e,f,g){(a=this.transformManager.rotateAxisAngleAtCenter(a,b,c,d,e,f,g))&&this.refresh(-1,"rotateAxisAngleAtCenter");return a},"J.api.JmolScriptEvaluator,JU.P3,JU.V3,~N,~N,~B,JU.BS");$_M(c$,"rotateAboutPointsInternal",function(a,b,c,d,e,f,g,h,k,l){(a=this.transformManager.rotateAboutPointsInternal(a,b,c,d,e,!1,f,g,!1,h,k,l))&&this.refresh(-1,"rotateAxisAboutPointsInternal");return a},"J.api.JmolScriptEvaluator,JU.P3,JU.P3,~N,~N,~B,JU.BS,JU.V3,JU.List,~A");$_M(c$,"startSpinningAxis",
function(a,b,c){this.getSpinOn()||this.getNavOn()?(this.setSpinOn(!1),this.setNavOn(!1)):this.transformManager.rotateAboutPointsInternal(null,a,b,this.global.pickingSpinRate,3.4028235E38,c,!0,null,!1,null,null,null)},"JU.P3,JU.P3,~B");$_M(c$,"getModelDipole",function(){return this.modelSet.getModelDipole(this.animationManager.currentModelIndex)});$_M(c$,"calculateMolecularDipole",function(){return this.modelSet.calculateMolecularDipole(this.animationManager.currentModelIndex)});$_M(c$,"getAtomIdentityInfo",
function(a,b){this.modelSet.getAtomIdentityInfo(a,b)},"~N,java.util.Map");$_M(c$,"setDefaultLattice",function(a){this.global.setDefaultLattice(a);this.global.setS("defaultLattice",J.util.Escape.eP(a))},"JU.P3");$_M(c$,"getDefaultLattice",function(){return this.global.getDefaultLattice()});$_M(c$,"getTaintedAtoms",function(a){return this.modelSet.getTaintedAtoms(a)},"~N");$_M(c$,"setTaintedAtoms",function(a,b){this.modelSet.setTaintedAtoms(a,b)},"JU.BS,~N");$_M(c$,"getData",function(a,b){var c="";
if(b.equalsIgnoreCase("MOL")||b.equalsIgnoreCase("SDF")||b.equalsIgnoreCase("V2000")||b.equalsIgnoreCase("V3000")||b.equalsIgnoreCase("XYZVIB")||b.equalsIgnoreCase("CD"))return this.getModelExtract(a,!1,!1,b);if(0==b.toLowerCase().indexOf("property_"))c='{selected}.label("%{'+b+'}")';else{if(b.equalsIgnoreCase("CML"))return this.getModelCml(this.getAtomBitSet(a),2147483647,!0);c=b.equalsIgnoreCase("PDB")?'{selected and not hetero}.label("ATOM  %5i %-4a%1A%3.3n %1c%4R%1E   %8.3x%8.3y%8.3z%6.2Q%6.2b          %2e  ").lines+{selected and hetero}.label("HETATM%5i %-4a%1A%3.3n %1c%4R%1E   %8.3x%8.3y%8.3z%6.2Q%6.2b          %2e  ").lines':
b.equalsIgnoreCase("XYZRN")?'"" + {selected}.size + "\n\n"+{selected}.label("%-2e %8.3x %8.3y %8.3z %4.2[vdw] 1 [%n]%r.%a#%i").lines':b.startsWith("USER:")?'{selected}.label("'+b.substring(5)+'").lines':'"" + {selected}.size + "\n\n"+{selected}.label("%-2e %10.5x %10.5y %10.5z").lines'}a.equals("selected")||(c=J.util.Txt.simpleReplace(c,"selected",a));return this.evaluateExpression(c)},"~S,~S");$_M(c$,"getModelCml",function(a,b,c){return this.modelSet.getModelCml(a,b,c)},"JU.BS,~N,~B");$_M(c$,"getHelixData",
function(a,b){return this.modelSet.getHelixData(a,b)},"JU.BS,~N");$_M(c$,"getPdbAtomData",function(a,b){return this.modelSet.getPdbAtomData(null==a?this.getSelectionSet(!0):a,b)},"JU.BS,J.io.JmolOutputChannel");$_M(c$,"isJmolDataFrameForModel",function(a){return this.modelSet.isJmolDataFrameForModel(a)},"~N");$_M(c$,"isJmolDataFrame",function(){return this.modelSet.isJmolDataFrameForModel(this.animationManager.currentModelIndex)});$_M(c$,"getJmolDataFrameIndex",function(a,b){return this.modelSet.getJmolDataFrameIndex(a,
b)},"~N,~S");$_M(c$,"setJmolDataFrame",function(a,b,c){this.modelSet.setJmolDataFrame(a,b,c)},"~S,~N,~N");$_M(c$,"setFrameTitle",function(a,b){this.modelSet.setFrameTitle(J.util.BSUtil.newAndSetBit(a),b)},"~N,~S");$_M(c$,"setFrameTitleObj",function(a){this.loadShape(30);this.modelSet.setFrameTitle(this.getVisibleFramesBitSet(),a)},"~O");$_M(c$,"getFrameTitle",function(){return this.modelSet.getFrameTitle(this.animationManager.currentModelIndex)});$_M(c$,"getJmolFrameType",function(a){return this.modelSet.getJmolFrameType(a)},
"~N");$_M(c$,"getJmolDataSourceFrame",function(a){return this.modelSet.getJmolDataSourceFrame(a)},"~N");$_M(c$,"setAtomProperty",function(a,b,c,d,e,f,g){1649412120==b&&this.shapeManager.deleteVdwDependentShapes(a);this.clearMinimization();this.modelSet.setAtomProperty(a,b,c,d,e,f,g);switch(b){case 1112541185:case 1112541186:case 1112541187:case 1112541188:case 1112541189:case 1112541190:case 1112539153:case 1112539154:case 1112539155:case 1087375365:this.refreshMeasures(!0)}},"JU.BS,~N,~N,~N,~S,~A,~A");
$_M(c$,"checkCoordinatesChanged",function(){this.modelSet.recalculatePositionDependentQuantities(null,null);this.refreshMeasures(!0)});$_M(c$,"setAtomCoord",function(a,b,c,d){this.modelSet.setAtomCoord(a,b,c,d)},"~N,~N,~N,~N");$_M(c$,"setAtomCoordRelative",function(a,b,c,d){this.modelSet.setAtomCoordRelative(a,b,c,d)},"~N,~N,~N,~N");$_M(c$,"setAtomCoords",function(a,b,c){0!=a.cardinality()&&(this.modelSet.setAtomCoords(a,b,c),this.checkMinimization(),this.statusManager.setStatusAtomMoved(a))},"JU.BS,~N,~O");
$_M(c$,"setAtomCoordsRelative",function(a,b){null==b&&(b=this.getSelectionSet(!1));0!=b.cardinality()&&(this.modelSet.setAtomCoordsRelative(a,b),this.checkMinimization(),this.statusManager.setStatusAtomMoved(b))},"JU.T3,JU.BS");$_M(c$,"invertAtomCoordPt",function(a,b){this.modelSet.invertSelected(a,null,-1,null,b);this.checkMinimization();this.statusManager.setStatusAtomMoved(b)},"JU.P3,JU.BS");$_M(c$,"invertAtomCoordPlane",function(a,b){this.modelSet.invertSelected(null,a,-1,null,b);this.checkMinimization();
this.statusManager.setStatusAtomMoved(b)},"JU.P4,JU.BS");$_M(c$,"invertSelected",function(a,b,c,d){var e=this.getSelectionSet(!1);0!=e.cardinality()&&(this.modelSet.invertSelected(a,b,c,d,e),this.checkMinimization(),this.statusManager.setStatusAtomMoved(e))},"JU.P3,JU.P4,~N,JU.BS");$_M(c$,"moveAtoms",function(a,b,c,d,e,f){0!=f.cardinality()&&(this.modelSet.moveAtoms(a,b,c,f,d,e),this.checkMinimization(),this.statusManager.setStatusAtomMoved(f))},"JU.M3,JU.M3,JU.V3,JU.P3,~B,JU.BS");$_M(c$,"moveSelected",
function(a,b,c,d,e,f,g,h){0!=c&&(-2147483648==d&&(this.rotateBondIndex=-1),this.isJmolDataFrame()||(-2147483648==a?(this.showSelected=!0,this.loadShape(8),this.refresh(6,"moveSelected")):2147483647==a?this.showSelected&&(this.showSelected=!1,this.refresh(6,"moveSelected")):this.movingSelected||(this.movingSelected=!0,this.stopMinimization(),0<=this.rotateBondIndex&&-2147483648!=d?this.actionRotateBond(a,b,d,e):(f=this.setMovableBitSet(f,!h),0!=f.cardinality()&&(g?(d=this.getAtomSetCenter(f),this.transformManager.finalizeTransformParameters(),
e=this.global.antialiasDisplay?2:1,g=this.transformPt(d),a=-2147483648!=c?JU.P3.new3(g.x,g.y,g.z+c+0.5):JU.P3.new3(g.x+a*e+0.5,g.y+b*e+0.5,g.z),b=new JU.P3,this.unTransformPoint(a,b),b.sub(d),this.setAtomCoordsRelative(b,f)):this.transformManager.rotateXYBy(a,b,f))),this.refresh(2,""),this.movingSelected=!1)))},"~N,~N,~N,~N,~N,JU.BS,~B,~B");$_M(c$,"highlightBond",function(a,b){if(!b||this.hoverEnabled){var c=null;if(0<=a){var d=this.modelSet.bonds[a],c=d.getAtomIndex2();if(!this.isAtomAssignable(c))return;
c=J.util.BSUtil.newAndSetBit(c);c.set(d.getAtomIndex1())}this.highlight(c);this.refresh(3,"highlightBond")}},"~N,~B");$_M(c$,"highlight",function(a){null!=a&&this.loadShape(8);this.setShapeProperty(8,"highlight",a)},"JU.BS");$_M(c$,"setRotateBondIndex",function(a){if(0<=this.rotateBondIndex||!(0>a))this.rotatePrev1=-1,this.bsRotateBranch=null,-2147483648!=a&&(this.rotateBondIndex=a,this.highlightBond(a,!1))},"~N");$_M(c$,"getRotateBondIndex",function(){return this.rotateBondIndex});$_M(c$,"actionRotateBond",
function(a,b,c,d){if(!(0>this.rotateBondIndex)){var e=this.bsRotateBranch,f,g;if(null==e){g=this.modelSet.bonds[this.rotateBondIndex];f=g.getAtom1();g=g.getAtom2();this.undoMoveActionClear(f.index,2,!0);c=JU.P3.new3(c,d,Clazz.doubleToInt((f.screenZ+g.screenZ)/2));this.transformManager.unTransformPoint(c,c);if(1==g.getCovalentBondCount()||c.distance(f)<c.distance(g)&&1!=f.getCovalentBondCount())d=f,f=g,g=d;if(90<J.util.Measure.computeAngleABC(c,f,g,!0)||90<J.util.Measure.computeAngleABC(c,g,f,!0))e=
this.getBranchBitSet(g.index,f.index,!0);if(null!=e){c=0;for(d=f.getBonds().length;0<=--d;)if(e.get(f.getBondedAtomIndex(d))&&2==++c){e=null;break}}null==e&&(e=this.getMoleculeBitSet(f.index));this.bsRotateBranch=e;this.rotatePrev1=f.index;this.rotatePrev2=g.index}else f=this.modelSet.atoms[this.rotatePrev1],g=this.modelSet.atoms[this.rotatePrev2];c=JU.V3.new3(g.screenX-f.screenX,g.screenY-f.screenY,0);a=JU.V3.new3(a,b,0);c.cross(c,a);a=(0<c.z?1:-1)*a.length();e=J.util.BSUtil.copy(e);e.andNot(this.selectionManager.getMotionFixedAtoms());
this.rotateAboutPointsInternal(this.eval,f,g,0,a,!1,e,null,null,null)}},"~N,~N,~N,~N");$_M(c$,"refreshMeasures",function(a){this.setShapeProperty(6,"refresh",null);a&&this.stopMinimization()},"~B");$_M(c$,"setDynamicMeasurements",function(a){this.global.dynamicMeasurements=a},"~B");$_M(c$,"functionXY",function(a,b,c){var d=null;if(0==a.indexOf("file:"))d=this.getFileAsString(a.substring(5));else if(0!=a.indexOf("data2d_"))return this.statusManager.functionXY(a,b,c);b=Math.abs(b);c=Math.abs(c);if(null==
d){a=this.getDataFloat2D(a);if(null!=a)return a;d=""}a=Clazz.newFloatArray(b,c,0);var e=Clazz.newFloatArray(b*c,0);J.util.ParserBS.parseStringInfestedFloatArray(d,null,e);for(var f=d=0;d<b;d++)for(var g=0;g<c;g++)a[d][g]=e[f++];return a},"~S,~N,~N");$_M(c$,"functionXYZ",function(a,b,c,d){var e=null;if(0==a.indexOf("file:"))e=this.getFileAsString(a.substring(5));else if(0!=a.indexOf("data3d_"))return this.statusManager.functionXYZ(a,b,c,d);b=Math.abs(b);c=Math.abs(c);d=Math.abs(d);if(null==e){a=this.getDataFloat3D(a);
if(null!=a)return a;e=""}a=Clazz.newFloatArray(b,c,d,0);var f=Clazz.newFloatArray(b*c*d,0);J.util.ParserBS.parseStringInfestedFloatArray(e,null,f);for(var g=e=0;e<b;e++)for(var h=0;h<c;h++)for(var k=0;k<d;k++)a[e][h][k]=f[g++];return a},"~S,~N,~N,~N");Clazz.overrideMethod(c$,"extractMolData",function(a){if(null==a){a=this.getCurrentModelIndex();if(0>a)return null;a=this.getModelNumberDotted(a)}return this.getModelExtract(a,!0,!1,"V2000")},"~S");$_M(c$,"getNMRPredict",function(a){var b=this.getModelExtract("selected",
!0,!1,"V2000"),c=b.indexOf("\n"),b="Jmol "+J.viewer.Viewer.version_date+b.substring(c);return a?(this.$isApplet?this.showUrl(this.global.nmrUrlFormat+b):(this.syncScript("true","*",0),this.syncScript("JSpecView:",".",0)),null):this.getFileAsString(this.global.nmrPredictFormat+b)},"~B");$_M(c$,"getHelp",function(a){0>this.global.helpPath.indexOf("?")?(0<a.length&&0!=a.indexOf("?")&&(a="?search="+J.util.Txt.simpleReplace(a," ","%20")),a+=(0==a.length?"?ver=":"&ver=")+J.viewer.JC.version):a="&"+a;this.showUrl(this.global.helpPath+
a)},"~S");$_M(c$,"show2D",function(a){this.showUrl(this.setLoadFormat("_"+a,"2",!1))},"~S");$_M(c$,"getChemicalInfo",function(a,b,c){a=this.setLoadFormat("_"+a,b,!1);"/"==b&&(a+=J.util.Txt.simpleReplace(c," ","%20"));return this.getFileAsString4(a,-1,!1,!1)},"~S,~S,~S");$_M(c$,"addCommand",function(a){!this.autoExit&&(this.haveDisplay&&this.getPreserveState())&&this.commandHistory.addCommand(J.util.Txt.replaceAllCharacters(a,"\r\n\t"," "))},"~S");$_M(c$,"removeCommand",function(){return this.commandHistory.removeCommand()});
Clazz.overrideMethod(c$,"getSetHistory",function(a){return this.commandHistory.getSetHistory(a)},"~N");$_M(c$,"getOutputChannel",function(a,b){return this.getOutputManager().getOutputChannel(a,b)},"~S,~A");Clazz.overrideMethod(c$,"writeTextFile",function(a,b){var c=new java.util.Hashtable;c.put("fileName",a);c.put("type","txt");c.put("text",b);this.outputToFile(c)},"~S,~S");Clazz.overrideMethod(c$,"clipImageOrPasteText",function(a){return!this.haveAccess(J.viewer.Viewer.ACCESS.ALL)?"no":this.getOutputManager().clipImageOrPasteText(a)},
"~S");Clazz.overrideMethod(c$,"getClipboardText",function(){if(!this.haveAccess(J.viewer.Viewer.ACCESS.ALL))return"no";try{return this.getOutputManager().getClipboardText()}catch(a){if(Clazz.exceptionOf(a,Error))return J.i18n.GT._("clipboard is not accessible -- use signed applet");throw a;}});$_M(c$,"processWriteOrCapture",function(a){return this.getOutputManager().processWriteOrCapture(a)},"java.util.Map");$_M(c$,"createZip",function(a,b,c){var d=new java.util.Hashtable;d.put("fileName",a);d.put("type",
b);d.put("text",this.getStateInfo());null!=c&&d.put("scripts",c);return this.getOutputManager().outputToFile(d)},"~S,~S,~A");Clazz.overrideMethod(c$,"outputToFile",function(a){return this.getOutputManager().outputToFile(a)},"java.util.Map");$_M(c$,"getOutputManager",($fz=function(){return null!=this.outputManager?this.outputManager:(this.outputManager=J.api.Interface.getOptionInterface(this.isJS&&!this.isWebGL?"viewer.OutputManagerJS":"viewer.OutputManagerAwt")).setViewer(this,this.privateKey)},$fz.isPrivate=
!0,$fz));$_M(c$,"setSyncTarget",($fz=function(a,b){switch(a){case 0:this.statusManager.syncingMouse=b;break;case 1:this.statusManager.syncingScripts=b;break;case 2:this.statusManager.syncSend(b?"GET_GRAPHICS":"SET_GRAPHICS_OFF","*",0);Float.isNaN(this.transformManager.stereoDegrees)&&this.setFloatProperty("stereoDegrees",-5);b&&(this.setBooleanProperty("_syncMouse",!1),this.setBooleanProperty("_syncScript",!1));return}!this.statusManager.syncingScripts&&!this.statusManager.syncingMouse&&this.refresh(-1,
"set sync")},$fz.isPrivate=!0,$fz),"~N,~B");Clazz.overrideMethod(c$,"syncScript",function(a,b,c){this.getStateCreator().syncScript(a,b,c)},"~S,~S,~N");$_M(c$,"getModelIndexFromId",function(a){return this.modelSet.getModelIndexFromId(a)},"~S");$_M(c$,"setSyncDriver",function(a){this.statusManager.setSyncDriver(a)},"~N");$_M(c$,"getPartialCharges",function(){return this.modelSet.getPartialCharges()});$_M(c$,"getAtomicPotentials",function(a,b,c,d){a=Clazz.newFloatArray(this.getAtomCount(),0);var e=J.api.Interface.getOptionInterface("quantum.MlpCalculation");
d=null==d?null:this.getFileAsString(d);e.assignPotentials(this.modelSet.atoms,a,this.getSmartsMatch("a",b),this.getSmartsMatch("/noAromatic/[$(C=O),$(O=C),$(NC=O)]",b),c,d);return a},"~B,JU.BS,JU.BS,~S");$_M(c$,"setProteinType",function(a,b){this.modelSet.setProteinType(null==b?this.getSelectionSet(!1):b,a)},"J.constant.EnumStructure,JU.BS");Clazz.overrideMethod(c$,"getBondPoint3f1",function(a){return this.modelSet.getBondAtom1(a)},"~N");Clazz.overrideMethod(c$,"getBondPoint3f2",function(a){return this.modelSet.getBondAtom2(a)},
"~N");$_M(c$,"getVibration",function(a){return this.modelSet.getVibration(a,!1)},"~N");$_M(c$,"getVanderwaalsMar",function(a){return this.dataManager.defaultVdw===J.constant.EnumVdw.USER?this.dataManager.userVdwMars[a]:J.util.Elements.getVanderwaalsMar(a,this.dataManager.defaultVdw)},"~N");$_M(c$,"getVanderwaalsMarType",function(a,b){if(null==b)b=this.dataManager.defaultVdw;else switch(b){case J.constant.EnumVdw.USER:if(null==this.dataManager.bsUserVdws)b=this.dataManager.defaultVdw;else return this.dataManager.userVdwMars[a&
127];break;case J.constant.EnumVdw.AUTO:case J.constant.EnumVdw.JMOL:case J.constant.EnumVdw.BABEL:case J.constant.EnumVdw.RASMOL:this.dataManager.defaultVdw!==J.constant.EnumVdw.AUTO&&(b=this.dataManager.defaultVdw)}return J.util.Elements.getVanderwaalsMar(a,b)},"~N,J.constant.EnumVdw");$_M(c$,"setDefaultVdw",function(a){a=J.constant.EnumVdw.getVdwType(a);null==a&&(a=J.constant.EnumVdw.AUTO);this.dataManager.setDefaultVdw(a);this.global.setS("defaultVDW",this.getDefaultVdwTypeNameOrData(-2147483648,
null))},"~S");$_M(c$,"getDefaultVdwTypeNameOrData",function(a,b){return this.dataManager.getDefaultVdwNameOrData(a,b,null)},"~N,J.constant.EnumVdw");$_M(c$,"deleteAtoms",function(a,b){var c=null==a?-1:a.nextSetBit(0);if(0>c)return 0;this.clearModelDependentObjects();if(!b){this.statusManager.modifySend(c,this.modelSet.atoms[c].modelIndex,4);this.modelSet.deleteAtoms(a);var d=this.selectionManager.deleteAtoms(a);this.setTainted(!0);this.statusManager.modifySend(c,this.modelSet.atoms[c].modelIndex,
-4);return d}this.statusManager.modifySend(-1,this.modelSet.atoms[c].modelIndex,5);this.setCurrentModelIndexClear(0,!1);this.animationManager.setAnimationOn(!1);var d=J.util.BSUtil.copy(this.getDeletedAtoms()),e=this.modelSet.deleteModels(a);this.selectionManager.processDeletedModelAtoms(e);this.setAnimationRange(0,0);null!=this.eval&&this.eval.deleteAtomsInVariables(e);this.clearRepaintManager(-1);this.animationManager.clear();this.animationManager.initializePointers(1);this.setCurrentModelIndexClear(1<
this.getModelCount()?-1:0,1<this.getModelCount());this.hoverAtomIndex=-1;this.setFileLoadStatus(J.constant.EnumFileStatus.DELETED,null,null,null,null,null);this.refreshMeasures(!0);null!=d&&e.andNot(d);this.statusManager.modifySend(-1,this.modelSet.atoms[c].modelIndex,-5);return J.util.BSUtil.cardinalityOf(e)},"JU.BS,~B");$_M(c$,"deleteBonds",function(a){this.modelSet.deleteBonds(a,!1)},"JU.BS");$_M(c$,"deleteModelAtoms",function(a,b,c){this.selectionManager.deleteModelAtoms(c);J.util.BSUtil.deleteBits(this.getFrameOffsets(),
c);this.setFrameOffsets(this.getFrameOffsets());this.dataManager.deleteModelAtoms(a,b,c)},"~N,~N,JU.BS");$_M(c$,"getDeletedAtoms",function(){return this.selectionManager.getDeletedAtoms()});$_M(c$,"getQuaternionFrame",function(){return this.global.quaternionFrame.charAt(2==this.global.quaternionFrame.length?1:0)});$_M(c$,"calculatePointGroup",function(){return this.modelSet.calculatePointGroup(this.getSelectionSet(!1))});$_M(c$,"getPointGroupInfo",function(a){return this.modelSet.getPointGroupInfo(this.getAtomBitSet(a))},
"~O");$_M(c$,"getPointGroupAsString",function(a,b,c,d){return this.modelSet.getPointGroupAsString(this.getSelectionSet(!1),a,b,c,d)},"~B,~S,~N,~N");$_M(c$,"loadImage",function(a,b){this.fileManager.loadImage(a,b)},"~S,~S");$_M(c$,"loadImageData",function(a,b,c,d){null==a&&J.util.Logger.info(b);null==c?this.setBackgroundImage(null==a?null:b,a):(this.loadShape(30),this.setShapeProperty(30,"text",b),null!=a&&this.setShapeProperty(30,"image",a));null!=d&&(d.mustResumeEval=!0,this.eval.resumeEval(d))},
"~O,~S,~S,J.script.ScriptContext");$_M(c$,"cd",function(a){null==a?a=".":0==a.length&&(this.setStringProperty("defaultDirectory",""),a=".");a=this.fileManager.getDefaultDirectory(a+(a.equals("=")?"":a.endsWith("/")?"X.spt":"/X.spt"));0<a.length&&this.setStringProperty("defaultDirectory",a);this.fileManager.getFilePath(a+"/",!0,!1).startsWith("file:/")&&J.viewer.FileManager.setLocalPath(this,a,!1);return a},"~S");$_M(c$,"setErrorMessage",function(a,b){this.errorMessageUntranslated=b;null!=a&&this.eval.stopScriptThreads();
return this.errorMessage=a},"~S,~S");Clazz.overrideMethod(c$,"getErrorMessage",function(){return this.errorMessage});Clazz.overrideMethod(c$,"getErrorMessageUn",function(){return null==this.errorMessageUntranslated?this.errorMessage:this.errorMessageUntranslated});$_M(c$,"setShapeErrorState",function(a,b){this.currentShapeID=a;this.currentShapeState=b},"~N,~S");$_M(c$,"getShapeErrorState",function(){if(0>this.currentShapeID)return"";null!=this.modelSet&&this.shapeManager.releaseShape(this.currentShapeID);
this.clearRepaintManager(this.currentShapeID);return J.viewer.JC.getShapeClassName(this.currentShapeID,!1)+" "+this.currentShapeState});$_M(c$,"handleError",function(a,b){try{b&&this.zapMsg(""+a),this.undoClear(),0==J.util.Logger.getLogLevel()&&J.util.Logger.setLogLevel(4),this.setCursor(0),this.setBooleanProperty("refreshing",!0),this.fileManager.setPathForAllFiles(""),J.util.Logger.error("viewer handling error condition: "+a+"  "),this.isJS||a.printStackTrace(),this.notifyError("Error","doClear="+
b+"; "+a,""+a)}catch(c){try{J.util.Logger.error("Could not notify error "+a+": due to "+c)}catch(d){}}},"Error,~B");$_M(c$,"getAtomicCharges",function(){return this.modelSet.getAtomicCharges()});$_M(c$,"getFunctions",function(a){return a?J.viewer.Viewer.staticFunctions:this.localFunctions},"~B");$_M(c$,"removeFunction",function(a){null!=this.getFunction(a)&&(J.viewer.Viewer.staticFunctions.remove(a),this.localFunctions.remove(a))},"~S");$_M(c$,"getFunction",function(a){if(null==a)return null;a=(J.viewer.Viewer.isStaticFunction(a)?
J.viewer.Viewer.staticFunctions:this.localFunctions).get(a);return null==a||null==a.geTokens()?null:a},"~S");c$.isStaticFunction=$_M(c$,"isStaticFunction",($fz=function(a){return a.startsWith("static_")},$fz.isPrivate=!0,$fz),"~S");$_M(c$,"isFunction",function(a){return(J.viewer.Viewer.isStaticFunction(a)?J.viewer.Viewer.staticFunctions:this.localFunctions).containsKey(a)},"~S");$_M(c$,"clearFunctions",function(){J.viewer.Viewer.staticFunctions.clear();this.localFunctions.clear()});$_M(c$,"addFunction",
function(a){var b=a.getName();(J.viewer.Viewer.isStaticFunction(b)?J.viewer.Viewer.staticFunctions:this.localFunctions).put(b,a)},"J.api.JmolScriptFunction");$_M(c$,"getFunctionCalls",function(a){return this.getStateCreator().getFunctionCalls(a)},"~S");$_M(c$,"showMessage",function(a){this.isPrintOnly||J.util.Logger.warn(a)},"~S");$_M(c$,"getMoInfo",function(a){return this.modelSet.getMoInfo(a)},"~N");$_M(c$,"checkPrivateKey",function(a){return a==this.privateKey},"~N");$_M(c$,"bindAction",function(a,
b){this.haveDisplay&&this.actionManager.bindAction(a,b)},"~S,~S");$_M(c$,"unBindAction",function(a,b){this.haveDisplay&&this.actionManager.unbindAction(a,b)},"~S,~S");$_M(c$,"getMouseInfo",function(){return this.haveDisplay?this.actionManager.getMouseInfo():null});$_M(c$,"getFrontPlane",function(){return this.transformManager.getFrontPlane()});$_M(c$,"getPlaneIntersection",function(a,b,c,d){return this.modelSet.getPlaneIntersection(a,b,c,d,this.animationManager.currentModelIndex)},"~N,JU.P4,~N,~N");
$_M(c$,"calculateStruts",function(a,b){return this.modelSet.calculateStruts(null==a?this.getSelectionSet(!1):a,null==b?this.getSelectionSet(!1):b)},"JU.BS,JU.BS");$_M(c$,"getPreserveState",function(){return this.global.preserveState&&null!=this.scriptManager});$_M(c$,"isKiosk",function(){return this.$isKiosk});$_M(c$,"hasFocus",function(){return this.haveDisplay&&(this.$isKiosk||this.apiPlatform.hasFocus(this.display))});$_M(c$,"setFocus",function(){this.haveDisplay&&!this.apiPlatform.hasFocus(this.display)&&
this.apiPlatform.requestFocusInWindow(this.display)});$_M(c$,"getMinimizer",function(a){null==this.minimizer&&a&&(this.minimizer=J.api.Interface.getOptionInterface("minimize.Minimizer"),this.minimizer.setProperty("viewer",this));return this.minimizer},"~B");$_M(c$,"stopMinimization",function(){null!=this.minimizer&&this.minimizer.setProperty("stop",null)});$_M(c$,"clearMinimization",function(){null!=this.minimizer&&this.minimizer.setProperty("clear",null)});$_M(c$,"getMinimizationInfo",function(){return null==
this.minimizer?"":this.minimizer.getProperty("log",0)});$_M(c$,"checkMinimization",($fz=function(){this.refreshMeasures(!0);this.global.monitorEnergy&&(this.minimize(0,0,this.getModelUndeletedAtomsBitSet(-1),null,0,!1,!0,!1),this.echoMessage(this.getParameter("_minimizationForceField")+" Energy = "+this.getParameter("_minimizationEnergy")))},$fz.isPrivate=!0,$fz));$_M(c$,"minimize",function(a,b,c,d,e,f,g,h){var k=this.global.forceField,l=this.getModelUndeletedAtomsBitSetBs(this.getVisibleFramesBitSet());
null==c?c=this.getModelUndeletedAtomsBitSet(this.getVisibleFramesBitSet().length()-1):c.and(l);0>=e&&(e=5);d=J.util.BSUtil.copy(null==d?this.selectionManager.getMotionFixedAtoms():d);var m=0<d.cardinality();m&&c.andNot(d);e=this.getAtomsWithinRadius(e,c,!0,null);e.andNot(c);m?d.and(e):d=e;d.and(l);f&&c.or(this.addHydrogens(c,h,g));if(200<c.cardinality())J.util.Logger.error("Too many atoms for minimization (>200)");else try{g||J.util.Logger.info("Minimizing "+c.cardinality()+" atoms"),this.getMinimizer(!0).minimize(a,
b,c,d,m,g,k)}catch(n){if(Clazz.exceptionOf(n,Exception))J.util.Logger.error("Minimization error: "+n.toString()),this.isJS||n.printStackTrace();else throw n;}},"~N,~N,JU.BS,JU.BS,~N,~B,~B,~B");$_M(c$,"setMotionFixedAtoms",function(a){this.selectionManager.setMotionFixedAtoms(a)},"JU.BS");$_M(c$,"getMotionFixedAtoms",function(){return this.selectionManager.getMotionFixedAtoms()});$_M(c$,"rotateArcBall",function(a,b,c){this.transformManager.rotateArcBall(a,b,c);this.refresh(2,this.statusManager.syncingMouse?
"Mouse: rotateArcBall "+a+" "+b+" "+c:"")},"~N,~N,~N");$_M(c$,"getAtomicPropertyState",function(a,b,c,d,e){this.getStateCreator().getAtomicPropertyStateBuffer(a,b,c,d,e)},"JU.SB,~N,JU.BS,~S,~A");$_M(c$,"getCenterAndPoints",function(a,b){return this.modelSet.getCenterAndPoints(a,b)},"JU.List,~B");$_M(c$,"writeFileData",function(a,b,c,d){return this.getOutputManager().writeFileData(a,b,c,d)},"~S,~S,~N,~A");$_M(c$,"getPdbData",function(a,b,c){return this.modelSet.getPdbData(a,b,this.getSelectionSet(!1),
c,null)},"~N,~S,~A");$_M(c$,"getGroupsWithin",function(a,b){return this.modelSet.getGroupsWithin(a,b)},"~N,JU.BS");$_M(c$,"getExecutor",function(){if(null!=this.executor||2>J.viewer.Viewer.nProcessors)return this.executor;try{this.executor=J.api.Interface.getOptionInterface("parallel.ScriptParallelProcessor").getExecutor()}catch(a){if(Clazz.exceptionOf(a,Exception))this.executor=null;else if(Clazz.exceptionOf(a,Error))this.executor=null;else throw a;}null==this.executor&&J.util.Logger.error("parallel processing is not available");
return this.executor});$_M(c$,"getShapeInfo",function(){return this.shapeManager.getShapeInfo()});$_M(c$,"togglePickingLabel",function(a){null==a&&(a=this.getSelectionSet(!1));this.loadShape(5);this.shapeManager.setShapePropertyBs(5,"toggleLabel",null,a)},"JU.BS");$_M(c$,"loadShape",function(a){this.shapeManager.loadShape(a)},"~N");$_M(c$,"setShapeSize",function(a,b,c){null==c&&(c=this.getSelectionSet(!1));this.shapeManager.setShapeSizeBs(a,b,null,c)},"~N,~N,JU.BS");$_M(c$,"setShapeSizeRD",function(a,
b,c){this.shapeManager.setShapeSizeBs(a,0,b,c)},"~N,J.atomdata.RadiusData,JU.BS");$_M(c$,"setShapeProperty",function(a,b,c){0>a||this.shapeManager.setShapePropertyBs(a,b,c,null)},"~N,~S,~O");$_M(c$,"getShapeProperty",function(a,b){return this.shapeManager.getShapePropertyIndex(a,b,-2147483648)},"~N,~S");$_M(c$,"getShapePropertyData",function(a,b,c){return this.shapeManager.getShapePropertyData(a,b,c)},"~N,~S,~A");$_M(c$,"getShapePropertyIndex",function(a,b,c){return this.shapeManager.getShapePropertyIndex(a,
b,c)},"~N,~S,~N");$_M(c$,"getShapePropertyAsInt",($fz=function(a,b){var c=this.getShapeProperty(a,b);return null==c||!Clazz.instanceOf(c,Integer)?-2147483648:c.intValue()},$fz.isPrivate=!0,$fz),"~N,~S");$_M(c$,"setModelVisibility",function(){null!=this.shapeManager&&this.shapeManager.setModelVisibility()});$_M(c$,"resetShapes",function(a){this.shapeManager.resetShapes();a&&(this.shapeManager.loadDefaultShapes(this.modelSet),this.clearRepaintManager(-1))},"~B");$_M(c$,"setAtomLabel",function(a,b){this.shapeManager.setAtomLabel(a,
b)},"~S,~N");$_M(c$,"deleteShapeAtoms",function(a,b){this.shapeManager.deleteShapeAtoms(a,b)},"~A,JU.BS");$_M(c$,"resetBioshapes",function(a){this.shapeManager.resetBioshapes(a)},"JU.BS");$_M(c$,"getAtomShapeValue",function(a,b,c){return this.shapeManager.getAtomShapeValue(a,b,c)},"~N,J.modelset.Group,~N");$_M(c$,"mergeShapes",function(a){this.shapeManager.mergeShapes(a)},"~A");$_M(c$,"getShapeManager",function(){return this.shapeManager});$_M(c$,"setParallel",function(a){return this.$isParallel=
this.global.multiProcessor&&a},"~B");$_M(c$,"isParallel",function(){return this.global.multiProcessor&&this.$isParallel});$_M(c$,"getRenderableBitSet",function(){return this.shapeManager.getRenderableBitSet()});$_M(c$,"setAtomPickingOption",($fz=function(a){this.haveDisplay&&this.actionManager.setAtomPickingOption(a)},$fz.isPrivate=!0,$fz),"~S");$_M(c$,"setBondPickingOption",($fz=function(a){this.haveDisplay&&this.actionManager.setBondPickingOption(a)},$fz.isPrivate=!0,$fz),"~S");$_M(c$,"undoClear",
function(){this.actionStates.clear();this.actionStatesRedo.clear()});$_M(c$,"undoMoveAction",function(a,b){this.getStateCreator().undoMoveAction(a,b)},"~N,~N");$_M(c$,"undoMoveActionClear",function(a,b,c){this.global.preserveState&&this.getStateCreator().undoMoveActionClear(a,b,c)},"~N,~N,~B");$_M(c$,"assignBond",function(a,b){try{var c=this.modelSet.setBondOrder(a,b);null==c||"0"==b?this.refresh(3,"setBondOrder"):this.addHydrogens(c,!1,!0)}catch(d){if(Clazz.exceptionOf(d,Exception))J.util.Logger.error("assignBond failed");
else throw d;}},"~N,~S");$_M(c$,"assignAtom",function(a,b,c){c.equals("X")&&this.setRotateBondIndex(-1);if(this.modelSet.atoms[a].modelIndex==this.modelSet.modelCount-1)if(this.clearModelDependentObjects(),null==b){this.statusManager.modifySend(a,this.modelSet.atoms[a].modelIndex,1);var d=this.modelSet.getAtomCount();this.modelSet.assignAtom(a,c,!0);J.util.Parser.isOneOf(c,";Mi;Pl;X;")||this.modelSet.setAtomNamesAndNumbers(a,-d,null);this.statusManager.modifySend(a,this.modelSet.atoms[a].modelIndex,
-1);this.refresh(3,"assignAtom")}else{var e=this.modelSet.atoms[a],d=J.util.BSUtil.newAndSetBit(a);b=[b];var f=new JU.List;f.addLast(e);e=e.modelIndex;this.statusManager.modifySend(a,e,3);try{d=this.addHydrogensInline(d,f,b),a=d.nextSetBit(0),this.modelSet.assignAtom(a,c,!1)}catch(g){if(!Clazz.exceptionOf(g,Exception))throw g;}this.modelSet.setAtomNamesAndNumbers(a,-1,null);this.statusManager.modifySend(a,e,-3)}},"~N,JU.P3,~S");$_M(c$,"assignConnect",function(a,b){this.clearModelDependentObjects();
var c=JU.ArrayUtil.newFloat2(1);c[0]=[a,b];var d=this.modelSet.atoms[a].modelIndex;this.statusManager.modifySend(a,d,2);this.modelSet.connect(c);this.modelSet.assignAtom(a,".",!0);this.modelSet.assignAtom(b,".",!0);this.statusManager.modifySend(a,d,-2);this.refresh(3,"assignConnect")},"~N,~N");$_M(c$,"moveAtomWithHydrogens",function(a,b,c,d,e){this.stopMinimization();if(null==e){var f=this.modelSet.atoms[a];e=J.util.BSUtil.newAndSetBit(a);a=f.getBonds();if(null!=a)for(var g=0;g<a.length;g++){var h=
a[g].getOtherAtom(f);1==h.getElementNumber()&&e.set(h.index)}}this.moveSelected(b,c,d,-2147483648,-2147483648,e,!0,!0)},"~N,~N,~N,~N,JU.BS");c$.getInlineData=$_M(c$,"getInlineData",function(a,b,c){J.viewer.DataManager.getInlineData(a,b,c,null)},"JU.SB,~S,~B");$_M(c$,"isAtomPDB",function(a){return this.modelSet.isAtomPDB(a)},"~N");$_M(c$,"isModelPDB",function(a){return this.modelSet.models[a].isBioModel},"~N");$_M(c$,"isAtomAssignable",function(a){return this.modelSet.isAtomAssignable(a)},"~N");Clazz.overrideMethod(c$,
"deleteMeasurement",function(a){this.setShapeProperty(6,"delete",Integer.$valueOf(a))},"~N");$_M(c$,"haveModelKit",function(){return this.modelSet.haveModelKit()});$_M(c$,"getModelKitStateBitSet",function(a,b){return this.modelSet.getModelKitStateBitset(a,b)},"JU.BS,JU.BS");$_M(c$,"getSmiles",function(a,b,c,d,e,f,g){var h=this.modelSet.atoms;null==c&&(0>a||0>b?c=this.getSelectionSet(!0):(d&&(a>b&&(c=a,a=b,b=c),a=h[a].getGroup().firstAtomIndex,b=h[b].getGroup().lastAtomIndex),c=new JU.BS,c.setBits(a,
b+1)));a=g?J.viewer.Viewer.getJmolVersion()+" "+this.getModelName(this.getCurrentModelIndex()):null;return this.getSmilesMatcher().getSmiles(h,this.getAtomCount(),c,d,e,f,a)},"~N,~N,JU.BS,~B,~B,~B,~B");$_M(c$,"connect",function(a){this.modelSet.connect(a)},"~A");$_M(c$,"prompt",function(a,b,c,d){return this.$isKiosk?"null":this.apiPlatform.prompt(a,b,c,d)},"~S,~S,~A,~B");$_M(c$,"getColorEncoder",function(a){return this.colorManager.getColorEncoder(a)},"~S");$_M(c$,"displayBonds",function(a,b){this.modelSet.displayBonds(a,
b)},"J.modelset.Bond.BondSet,~B");$_M(c$,"getModelAtomProperty",function(a,b){return this.modelSet.getModelAtomProperty(a,b)},"J.modelset.Atom,~S");$_M(c$,"setStateScriptVersion",function(a){if(null!=a){a=JU.ParserJS.getTokens(a.$replace("."," ").$replace("_"," "));try{var b=JU.ParserJS.parseInt(a[0]),c=JU.ParserJS.parseInt(a[1]),d=JU.ParserJS.parseInt(a[2]);-2147483648==d&&(d=0);if(-2147483648!=b&&-2147483648!=c){this.stateScriptVersionInt=1E4*b+100*c+d;this.global.legacyAutoBonding=110924>this.stateScriptVersionInt;
this.global.legacyHAddition=130117>this.stateScriptVersionInt;return}}catch(e){if(!Clazz.exceptionOf(e,Exception))throw e;}}this.setBooleanProperty("legacyautobonding",!1);this.stateScriptVersionInt=2147483647},"~S");$_M(c$,"initializeExporter",function(a){var b=a.get("type").equals("JS"),c;if(b){if(null!=this.jsExporter3D)return this.jsExporter3D.initializeOutput(this,this.privateKey,this.gdata,a),this.jsExporter3D;c="J.exportjs.Export3D"}else{var d=a.get("fileName");c=a.get("fullPath");d=this.getOutputChannel(d,
c);if(null==d)return null;a.put("outputChannel",d);c="J.export.Export3D"}d=null;try{d=Class.forName(c).newInstance()}catch(e){if(Clazz.exceptionOf(e,Exception))return null;throw e;}a=d.initializeExporter(this,this.privateKey,this.gdata,a);b&&null!=a&&(this.jsExporter3D=d);return null==a?null:d},"java.util.Map");$_M(c$,"getMouseEnabled",function(){return this.refreshing&&!this.creatingImage});$_M(c$,"setZslabPoint",function(a){this.transformManager.setZslabPoint(a)},"JU.P3");Clazz.overrideMethod(c$,
"calcAtomsMinMax",function(a,b){this.modelSet.calcAtomsMinMax(a,b)},"JU.BS,J.util.BoxInfo");$_M(c$,"getObjectMap",function(a,b){switch(b){case "{":if(null!=this.getScriptManager()){var c=this.eval.getDefinedAtomSets();null!=c&&a.putAll(c);J.script.T.getTokensType(a,3145728)}break;case "$":case "0":this.shapeManager.getObjectMap(a,"$"==b)}},"java.util.Map,~S");$_M(c$,"getPdbBondInfo",function(a){null==this.htPdbBondInfo&&(this.htPdbBondInfo=new java.util.Hashtable);var b=this.htPdbBondInfo.get(a);
if(null!=b)return b;b=J.viewer.JC.getPdbBondInfo(J.modelset.Group.lookupGroupID(a),this.global.legacyHAddition);this.htPdbBondInfo.put(a,b);return b},"~S");$_M(c$,"setPicked",function(a){this.global.setPicked(a)},"~N");Clazz.overrideMethod(c$,"runScript",function(a){var b=new JU.SB;try{if(null==this.getScriptManager())return null;this.eval.runScriptBuffer(a,b)}catch(c){if(Clazz.exceptionOf(c,Exception))return this.eval.getErrorMessage();throw c;}return b.toString()},"~S");$_M(c$,"allowSpecAtom",function(){return this.modelSet.allowSpecAtom()});
$_M(c$,"setFrameDelayMs",function(a){this.modelSet.setFrameDelayMs(a,this.getVisibleFramesBitSet())},"~N");$_M(c$,"getFrameDelayMs",function(a){return this.modelSet.getFrameDelayMs(a)},"~N");$_M(c$,"getBaseModelBitSet",function(){return this.modelSet.getModelAtomBitSetIncludingDeleted(this.getJDXBaseModelIndex(this.getCurrentModelIndex()),!0)});$_M(c$,"getTimeouts",function(){return this.timeouts});$_M(c$,"clearTimeouts",function(){null!=this.timeouts&&J.thread.TimeoutThread.clear(this.timeouts)});
$_M(c$,"setTimeout",function(a,b,c){this.haveDisplay&&(!this.isHeadless()&&!this.autoExit)&&(null==a?this.clearTimeouts():(null==this.timeouts&&(this.timeouts=new java.util.Hashtable),J.thread.TimeoutThread.setTimeout(this,this.timeouts,a,b,c)))},"~S,~N,~S");$_M(c$,"triggerTimeout",function(a){this.haveDisplay&&null!=this.timeouts&&J.thread.TimeoutThread.trigger(this.timeouts,a)},"~S");$_M(c$,"clearTimeout",function(a){this.setTimeout(a,0,null)},"~S");$_M(c$,"showTimeout",function(a){return this.haveDisplay?
J.thread.TimeoutThread.showTimeout(this.timeouts,a):""},"~S");$_M(c$,"calculatePartialCharges",function(a){if(null==a||0==a.cardinality())a=this.getModelUndeletedAtomsBitSetBs(this.getVisibleFramesBitSet());this.getMinimizer(!0).calculatePartialCharges(this.modelSet.bonds,this.modelSet.bondCount,this.modelSet.atoms,a)},"JU.BS");$_M(c$,"setCurrentModelID",function(a){var b=this.getCurrentModelIndex();0<=b&&this.modelSet.setModelAuxiliaryInfo(b,"modelID",a)},"~S");$_M(c$,"setCentroid",function(a,b){this.modelSet.setCentroid(a,
b)},"JU.BS,~A");$_M(c$,"getPathForAllFiles",function(){return this.fileManager.getPathForAllFiles()});$_M(c$,"cacheGet",function(a){return this.fileManager.cacheGet(a,!1)},"~S");$_M(c$,"cacheClear",function(){this.fileManager.cacheClear()});Clazz.overrideMethod(c$,"cachePut",function(a,b){J.util.Logger.info("Viewer cachePut "+a);this.fileManager.cachePut(a,b)},"~S,~O");Clazz.overrideMethod(c$,"cacheFileByName",function(a,b){return this.fileManager.cacheFileByNameAdd(a,b)},"~S,~B");$_M(c$,"cacheList",
function(){return this.fileManager.cacheList()});$_M(c$,"clearThreads",function(){null!=this.eval&&this.eval.stopScriptThreads();this.stopMinimization();this.setVibrationOff();this.setSpinOn(!1);this.setNavOn(!1);this.setAnimationOn(!1)});$_M(c$,"getEvalContextAndHoldQueue",function(a){if(null==a||!this.isJS)return null;a.pushContextDown("getEvalContextAndHoldQueue");for(var b=a=a.getThisContext();null!=b;)b.mustResumeEval=!0,b=b.parentContext;this.queueOnHold=a.isJSThread=!0;return a},"J.api.JmolScriptEvaluator");
$_M(c$,"checkInheritedShapes",function(){this.shapeManager.checkInheritedShapes()});Clazz.overrideMethod(c$,"resizeInnerPanel",function(a,b){return this.autoExit||!this.haveDisplay?(this.setScreenDimension(a,b),this.dimScreen):this.statusManager.resizeInnerPanel(a,b)},"~N,~N");$_M(c$,"getFontLineShapeState",function(a,b,c){return this.getStateCreator().getFontLineShapeState(a,b,c)},"~S,~S,~A");$_M(c$,"getShapeSetState",function(a,b,c,d,e,f,g){this.getStateCreator().getShapeSetState(a,b,c,d,e,f,g)},
"J.shape.AtomShape,J.shape.Shape,~N,~A,JU.BS,java.util.Map,java.util.Map");$_M(c$,"getMeasurementState",function(a,b,c,d,e){return this.getStateCreator().getMeasurementState(a,b,c,d,e)},"J.shape.Measures,JU.List,~N,J.util.JmolFont,J.modelset.TickInfo");$_M(c$,"getBondState",function(a,b,c){return this.getStateCreator().getBondState(a,b,c)},"J.shape.Shape,JU.BS,~B");$_M(c$,"getAtomShapeSetState",function(a,b){return this.getStateCreator().getAtomShapeSetState(a,b)},"J.shape.Shape,~A");$_M(c$,"getShapeState",
function(a){return this.getStateCreator().getShapeState(a)},"J.shape.Shape");$_M(c$,"getAtomShapeState",function(a){return this.getStateCreator().getAtomShapeState(a)},"J.shape.AtomShape");$_M(c$,"getDefaultPropertyParam",function(a){return this.getPropertyManager().getDefaultPropertyParam(a)},"~N");$_M(c$,"getPropertyNumber",function(a){return this.getPropertyManager().getPropertyNumber(a)},"~S");$_M(c$,"checkPropertyParameter",function(a){return this.getPropertyManager().checkPropertyParameter(a)},
"~S");$_M(c$,"extractProperty",function(a,b,c){return this.getPropertyManager().extractProperty(a,b,c)},"~O,~A,~N");$_M(c$,"addHydrogens",function(a,b,c){var d=null==a;null==a&&(a=this.getModelUndeletedAtomsBitSet(this.getVisibleFramesBitSet().length()-1));var e=new JU.BS;if(0==a.cardinality()||this.modelSet.atoms[a.nextSetBit(0)].modelIndex!=this.modelSet.modelCount-1)return e;var f=new JU.List,d=this.getAdditionalHydrogens(a,d,!1,f),g=!1,g=this.global.appendNew;if(0<d.length){this.clearModelDependentObjects();
try{e=b?this.modelSet.addHydrogens(f,d):this.addHydrogensInline(a,f,d)}catch(h){if(Clazz.exceptionOf(h,Exception))System.out.println(h.toString());else throw h;}g&&this.setAppendNew(!0)}c||this.scriptStatus(J.i18n.GT._("{0} hydrogens added",d.length));return e},"JU.BS,~B,~B");$_M(c$,"addHydrogensInline",($fz=function(a,b,c){return null==this.getScriptManager()?null:this.eval.addHydrogensInline(a,b,c)},$fz.isPrivate=!0,$fz),"JU.BS,JU.List,~A");Clazz.overrideMethod(c$,"evalFunctionFloat",function(a,
b,c){return null==this.getScriptManager()?0:this.eval.evalFunctionFloat(a,b,c)},"~O,~O,~A");$_M(c$,"evalParallel",function(a,b){this.displayLoadErrors=!1;var c=null!=this.getScriptManager()&&this.eval.evaluateParallel(a,null==b?this.shapeManager:b);this.displayLoadErrors=!0;return c},"J.script.ScriptContext,J.viewer.ShapeManager");Clazz.overrideMethod(c$,"evaluateExpression",function(a){return null==this.getScriptManager()?null:this.eval.evaluateExpression(a,!1)},"~O");$_M(c$,"evaluateExpressionAsVariable",
function(a){return null==this.getScriptManager()?null:this.eval.evaluateExpression(a,!0)},"~O");$_M(c$,"getAtomBitSet",function(a){if(Clazz.instanceOf(a,JU.BS))return a;this.getScriptManager();return this.getAtomBitSetEval(this.eval,a)},"~O");$_M(c$,"getAtomBitSetVector",function(a){return null==this.getScriptManager()?null:this.eval.getAtomBitSetVector(this.getAtomCount(),a)},"~O");$_M(c$,"getContextVariables",function(){return null==this.getScriptManager()?null:this.eval.getContextVariables()});
$_M(c$,"getScriptContext",function(a){return null==this.getScriptManager()?null:this.eval.getScriptContext(a)},"~S");Clazz.overrideMethod(c$,"getAtomDefs",function(a){return this.getStateCreator().getAtomDefs(a)},"java.util.Map");$_M(c$,"createModels",function(a){this.modelSet.createModels(a)},"~N");$_M(c$,"setCGO",function(a){this.shapeManager.loadShape(23);this.shapeManager.setShapePropertyBs(23,"setCGO",a,null)},"JU.List");$_M(c$,"setFrame",function(a){this.animationManager.setFrame(a-1)},"~N");
$_M(c$,"movePyMOL",function(a,b,c){this.transformManager.moveToPyMOL(a,b,c);return!0},"J.api.JmolScriptEvaluator,~N,~A");$_M(c$,"getCamera",function(){return this.transformManager.camera});$_M(c$,"setModelSet",function(a){this.modelSet=this.modelManager.modelSet=a},"J.modelset.ModelSet");$_M(c$,"setObjectProp",function(a,b){this.getScriptManager();null==a&&(a="*");return null==this.eval?null:this.eval.setObjectPropSafe(a,b,-1)},"~S,~N");$_M(c$,"getSceneList",function(){try{return this.getModelSetAuxiliaryInfoValue("scenes")}catch(a){if(Clazz.exceptionOf(a,
Exception))return null;throw a;}});$_M(c$,"setBondParameters",function(a,b,c,d,e,f,g){this.modelSet.setBondParametersBS(a,b,c,d,e,f,g)},"~N,~N,JU.BS,~N,~N,~N,~N");$_M(c$,"getDihedralMap",function(a){return this.modelSet.getDihedralMap(a)},"~A");$_M(c$,"setDihedrals",function(a,b,c){null==b&&(b=this.getBsBranches(a));this.modelSet.setDihedrals(a,b,c)},"~A,~A,~N");$_M(c$,"getBsBranches",function(a){return this.modelSet.getBsBranches(a)},"~A");$_M(c$,"getChainID",function(a){var b=this.chainMap.get(a);
if(null!=b)return b.intValue();var c=a.charCodeAt(0);1<a.length&&(c=256+this.chainList.size(),this.chainList.addLast(a));b=Integer.$valueOf(c);this.chainMap.put(b,a);this.chainMap.put(a,b);return c},"~S");$_M(c$,"getChainIDStr",function(a){return this.chainMap.get(Integer.$valueOf(a))},"~N");$_M(c$,"getScriptQueueInfo",function(){return null!=this.scriptManager&&this.scriptManager.isQueueProcessing()?Boolean.TRUE:Boolean.FALSE});$_M(c$,"getNMRCalculation",function(){return null==this.nmrCalculation?
(this.nmrCalculation=J.api.Interface.getOptionInterface("quantum.NMRCalculation")).setViewer(this):this.nmrCalculation});$_M(c$,"getDistanceUnits",function(a){null==a&&(a=this.getDefaultMeasurementLabel(2));var b=a.indexOf("//");return 0>b?this.getMeasureDistanceUnits():a.substring(b+2)},"~S");$_M(c$,"calculateFormalCharges",function(a){null==a&&(a=this.getSelectionSet(!1));return this.modelSet.fixFormalCharges(a)},"JU.BS");$_M(c$,"cachePngFiles",function(){return!this.getTestFlag(1)});$_M(c$,"setModulation",
function(a,b,c,d){var e=null==b?2147483647:b[0];2147483647==c?(d||this.animationManager.setModulationPlay(2147483647,0),null!=b&&this.global.setI("_modt",b[0]),this.modelSet.setModulation(this.getSelectionSet(!1),a,e)):this.animationManager.setModulationPlay(e,c);this.refreshMeasures(!0)},"~B,~A,~N,~B");$_M(c$,"setModulationFps",function(a){this.animationManager.setModulationFps(a)},"~N");$_M(c$,"checkInMotion",function(a){switch(a){case 0:this.setTimeout("_SET_IN_MOTION_",0,null);break;case 1:this.inMotion||
this.setTimeout("_SET_IN_MOTION_",2*this.global.hoverDelayMs,"!setInMotion");break;case 2:this.setInMotion(!0),this.refresh(3,"timeoutThread set in motion")}},"~N");$_M(c$,"checkMotionRendering",function(a){if(!this.getInMotion(!0)&&!this.transformManager.spinOn&&!this.transformManager.vibrationOn&&!this.animationManager.animationOn)return!0;if(this.global.wireframeRotation)return!1;var b=0;switch(a){case 1678770178:case 1141899265:b=2;break;case 1113198596:b=3;break;case 1113198597:b=4;break;case 1113200642:b=
5;break;case 1073742018:b=6;break;case 603979967:b=7;break;case 603979786:b=8}return this.global.platformSpeed>=b},"~N");$_M(c$,"openExportChannel",function(a,b,c){return this.getOutputManager().openOutputChannel(a,b,c,!1)},"~N,~S,~B");Clazz.overrideMethod(c$,"log",function(a){null!=a&&this.getOutputManager().logToFile(a)},"~S");$_M(c$,"getLogFileName",function(){return null==this.logFileName?"":this.logFileName});$_M(c$,"getCommands",function(a,b,c){return this.getStateCreator().getCommands(a,b,
c)},"java.util.Map,java.util.Map,~S");$_M(c$,"allowCapture",function(){return!this.$isApplet||this.$isSignedApplet});$_M(c$,"getMP",function(){return J.api.Interface.getOptionInterface("modelset.MeasurementPending").set(this.modelSet)});Clazz.overrideMethod(c$,"getApplet",function(){return this.applet});Clazz.pu$h();c$=Clazz.declareType(J.viewer.Viewer,"ACCESS",Enum);Clazz.defineEnumConstant(c$,"NONE",0,[]);Clazz.defineEnumConstant(c$,"READSPT",1,[]);Clazz.defineEnumConstant(c$,"ALL",2,[]);c$=Clazz.p0p();
Clazz.defineStatics(c$,"jsDocumentBase","");c$.strJavaVendor=c$.prototype.strJavaVendor=System.getProperty("java.vendor","j2s");c$.strOSName=c$.prototype.strOSName=System.getProperty("os.name","j2s");c$.strJavaVersion=c$.prototype.strJavaVersion=System.getProperty("java.version","0.0");Clazz.defineStatics(c$,"version_date",null,"SYNC_GRAPHICS_MESSAGE","GET_GRAPHICS","SYNC_NO_GRAPHICS_MESSAGE","SET_GRAPHICS_OFF");c$.staticFunctions=c$.prototype.staticFunctions=new java.util.Hashtable;Clazz.defineStatics(c$,
"nProcessors",1)}),$_L(null,"java.lang.Thread",["java.lang.IllegalArgumentException","$.ThreadGroup","java.util.Date"],function(){c$=$_C(function(){this.name=this.group=this.target=null;this.priority=0;$_Z(this,arguments)},java.lang,"Thread",null,Runnable);c$.currentThread=$_M(c$,"currentThread",function(){null==Thread.J2S_THREAD&&($t$=Thread.J2S_THREAD=new Thread,Thread.prototype.J2S_THREAD=Thread.J2S_THREAD,$t$);return Thread.J2S_THREAD});c$.sleep=$_M(c$,"sleep",function(){Clazz.alert("Thread.sleep is not implemented in Java2Script!")},
"~N");$_K(c$,function(){});$_K(c$,function(a){this.init(null,a,"Thread-"+(new java.util.Date).getTime()+Math.random(),0)},"Runnable");$_K(c$,function(a,b){this.init(a,b,"Thread-"+(new java.util.Date).getTime()+Math.random(),0)},"ThreadGroup,Runnable");$_K(c$,function(a){this.init(null,null,a,0)},"~S");$_K(c$,function(a,b){this.init(a,null,b,0)},"ThreadGroup,~S");$_K(c$,function(a,b){this.init(null,a,b,0)},"Runnable,~S");$_K(c$,function(a,b,c){this.init(a,b,c,0)},"ThreadGroup,Runnable,~S");$_K(c$,
function(a,b,c,d){this.init(a,b,c,d)},"ThreadGroup,Runnable,~S,~N");$_M(c$,"init",($fz=function(a,b,c){null==a&&(a=new ThreadGroup);this.group=a;this.target=b;this.name=c;this.priority=5},$fz.isPrivate=!0,$fz),"ThreadGroup,Runnable,~S,~N");$_M(c$,"start",function(){window.setTimeout(function(a){return function(){a.run()}}(this),0)});$_M(c$,"run",function(){null!=this.target&&this.target.run()});$_M(c$,"setPriority",function(a){if(10<a||1>a)throw new IllegalArgumentException;this.priority=a},"~N");
$_M(c$,"getPriority",function(){return this.priority});$_M(c$,"interrupt",function(){});$_M(c$,"setName",function(a){this.name=a},"~S");$_M(c$,"getName",function(){return String.valueOf(this.name)});$_M(c$,"getThreadGroup",function(){return this.group});$_V(c$,"toString",function(){var a=this.getThreadGroup();return null!=a?"Thread["+this.getName()+","+this.getPriority()+","+a.getName()+"]":"Thread["+this.getName()+","+this.getPriority()+",]"});$_S(c$,"MIN_PRIORITY",1,"NORM_PRIORITY",5,"MAX_PRIORITY",
10,"J2S_THREAD",null)}),Clazz.declarePackage("J.constant"),Clazz.load(["java.lang.Enum"],"J.constant.EnumQuantumShell",["JU.SB"],function(){c$=Clazz.decorateAsClass(function(){this.tag2=this.tag=null;this.idSpherical=this.id=0;Clazz.instantialize(this,arguments)},J.constant,"EnumQuantumShell",Enum);Clazz.makeConstructor(c$,($fz=function(a,b,c,d){this.tag=a;this.tag2=b;this.id=c;this.idSpherical=d},$fz.isPrivate=!0,$fz),"~S,~S,~N,~N");c$.getNewDfCoefMap=$_M(c$,"getNewDfCoefMap",function(){return[Clazz.newIntArray(1,
0),Clazz.newIntArray(3,0),Clazz.newIntArray(4,0),Clazz.newIntArray(5,0),Clazz.newIntArray(6,0),Clazz.newIntArray(7,0),Clazz.newIntArray(10,0),Clazz.newIntArray(9,0),Clazz.newIntArray(15,0),Clazz.newIntArray(11,0),Clazz.newIntArray(21,0),Clazz.newIntArray(13,0),Clazz.newIntArray(28,0)]});c$.getQuantumShellTagID=$_M(c$,"getQuantumShellTagID",function(a){if(a.equals("L"))return J.constant.EnumQuantumShell.SP.id;a=J.constant.EnumQuantumShell.getQuantumShell(a);return null==a?-1:a.id},"~S");c$.getQuantumShell=
$_M(c$,"getQuantumShell",($fz=function(a){for(var b,c=0,d=J.constant.EnumQuantumShell.values();c<d.length&&((b=d[c])||1);c++)if(b.tag.equals(a)||b.tag2.equals(a))return b;return null},$fz.isPrivate=!0,$fz),"~S");c$.getQuantumShellTagIDSpherical=$_M(c$,"getQuantumShellTagIDSpherical",function(a){if(a.equals("L"))return J.constant.EnumQuantumShell.SP.idSpherical;a=J.constant.EnumQuantumShell.getQuantumShell(a);return null==a?-1:a.idSpherical},"~S");c$.getItem=$_M(c$,"getItem",function(a){switch(a){case 0:return J.constant.EnumQuantumShell.S;
case 1:return J.constant.EnumQuantumShell.P;case 2:return J.constant.EnumQuantumShell.SP;case 3:return J.constant.EnumQuantumShell.D_SPHERICAL;case 4:return J.constant.EnumQuantumShell.D_CARTESIAN;case 5:return J.constant.EnumQuantumShell.F_SPHERICAL;case 6:return J.constant.EnumQuantumShell.F_CARTESIAN;case 7:return J.constant.EnumQuantumShell.G_SPHERICAL;case 8:return J.constant.EnumQuantumShell.G_CARTESIAN;case 9:return J.constant.EnumQuantumShell.H_SPHERICAL;case 10:return J.constant.EnumQuantumShell.H_CARTESIAN;
case 11:return J.constant.EnumQuantumShell.I_SPHERICAL;case 12:return J.constant.EnumQuantumShell.I_CARTESIAN}return null},"~N");c$.getQuantumShellTag=$_M(c$,"getQuantumShellTag",function(a){for(var b,c=0,d=J.constant.EnumQuantumShell.values();c<d.length&&((b=d[c])||1);c++)if(b.id==a)return b.tag;return""+a},"~N");c$.getMOString=$_M(c$,"getMOString",function(a){var b=new JU.SB;if(2==a.length)return""+Clazz.floatToInt(0>a[0]?-a[1]:a[1]);b.appendC("[");for(var c=0;c<a.length;c+=2)0<c&&b.append(", "),
b.appendF(a[c]).append(" ").appendI(Clazz.floatToInt(a[c+1]));b.appendC("]");return b.toString()},"~A");c$.SUPPORTED_BASIS_FUNCTIONS="SPLDF";Clazz.defineEnumConstant(c$,"S",0,["S","S",0,0]);Clazz.defineEnumConstant(c$,"P",1,["P","X",1,1]);Clazz.defineEnumConstant(c$,"SP",2,["SP","SP",2,2]);Clazz.defineEnumConstant(c$,"D_SPHERICAL",3,["5D","5D",3,3]);Clazz.defineEnumConstant(c$,"D_CARTESIAN",4,["D","XX",4,3]);Clazz.defineEnumConstant(c$,"F_SPHERICAL",5,["7F","7F",5,5]);Clazz.defineEnumConstant(c$,
"F_CARTESIAN",6,["F","XXX",6,5]);Clazz.defineEnumConstant(c$,"G_SPHERICAL",7,["9G","9G",7,7]);Clazz.defineEnumConstant(c$,"G_CARTESIAN",8,["G","XXXX",8,7]);Clazz.defineEnumConstant(c$,"H_SPHERICAL",9,["11H","11H",9,9]);Clazz.defineEnumConstant(c$,"H_CARTESIAN",10,["H","XXXXX",10,9]);Clazz.defineEnumConstant(c$,"I_SPHERICAL",11,["13I","13I",11,11]);Clazz.defineEnumConstant(c$,"I_CARTESIAN",12,["I","XXXXXX",12,11])}),Clazz.declarePackage("J.api"),Clazz.load(["J.constant.EnumQuantumShell"],"J.api.JmolAdapter",
["java.util.Hashtable","J.api.JmolViewer","J.modelset.Group","J.util.Elements","J.viewer.JC"],function(){c$=Clazz.decorateAsClass(function(){this.adapterName=null;Clazz.instantialize(this,arguments)},J.api,"JmolAdapter");c$.getShellEnumeration=$_M(c$,"getShellEnumeration",function(a){return J.constant.EnumQuantumShell.getItem(a)},"~N");c$.getNewDfCoefMap=$_M(c$,"getNewDfCoefMap",function(){return J.constant.EnumQuantumShell.getNewDfCoefMap()});c$.getElementSymbol=$_M(c$,"getElementSymbol",function(a){return J.util.Elements.elementSymbolFromNumber(a)},
"~N");c$.getElementNumber=$_M(c$,"getElementNumber",function(a){return J.util.Elements.elementNumberFromSymbol(a,!1)},"~S");c$.getNaturalIsotope=$_M(c$,"getNaturalIsotope",function(a){return J.util.Elements.getNaturalIsotope(a)},"~N");c$.isHetero=$_M(c$,"isHetero",function(a){return J.viewer.JC.isHetero(a)},"~S");c$.getQuantumShellTag=$_M(c$,"getQuantumShellTag",function(a){return J.constant.EnumQuantumShell.getQuantumShellTag(a)},"~N");c$.getQuantumShellTagID=$_M(c$,"getQuantumShellTagID",function(a){return J.constant.EnumQuantumShell.getQuantumShellTagID(a)},
"~S");c$.getQuantumShellTagIDSpherical=$_M(c$,"getQuantumShellTagIDSpherical",function(a){return J.constant.EnumQuantumShell.getQuantumShellTagIDSpherical(a)},"~S");c$.lookupGroupID=$_M(c$,"lookupGroupID",function(a){return J.modelset.Group.lookupGroupID(a)},"~S");c$.getBondingRadiusFloat=$_M(c$,"getBondingRadiusFloat",function(a,b){return J.util.Elements.getBondingRadiusFloat(a,b)},"~N,~N");Clazz.makeConstructor(c$,function(a){this.adapterName=a},"~S");$_M(c$,"getAdapterName",function(){return this.adapterName});
$_M(c$,"getAtomSetCollectionFromReader",function(a,b,c,d){null==d&&(d=new java.util.Hashtable);d.containsKey("viewer")||d.put("viewer",J.api.JmolViewer.allocateViewer(null,this));a=this.getAtomSetCollectionReader(a,b,c,d);return Clazz.instanceOf(a,String)?a:this.getAtomSetCollection(a)},"~S,~S,~O,java.util.Map");$_M(c$,"openBufferedReader",function(a,b){return this.getAtomSetCollectionFromReader(a,null,b,null)},"~S,java.io.BufferedReader");$_M(c$,"openBufferedReader",function(a,b,c){return this.getAtomSetCollectionFromReader(a,
null,b,c)},"~S,java.io.BufferedReader,java.util.Map");$_M(c$,"openBufferedReader",function(a,b,c){return this.getAtomSetCollectionFromReader(a,b,c,null)},"~S,~S,java.io.BufferedReader");c$.canonizeAlphaDigit=$_M(c$,"canonizeAlphaDigit",($fz=function(a){return"A"<=a&&"Z">=a||"a"<=a&&"z">=a||"0"<=a&&"9">=a?a:"\x00"},$fz.isPrivate=!0,$fz),"~S");c$.canonizeInsertionCode=$_M(c$,"canonizeInsertionCode",function(a){return J.api.JmolAdapter.canonizeAlphaDigit(a)},"~S");c$.canonizeAlternateLocationID=$_M(c$,
"canonizeAlternateLocationID",function(a){return J.api.JmolAdapter.canonizeAlphaDigit(a)},"~S");Clazz.defineStatics(c$,"ORDER_COVALENT_SINGLE",1,"ORDER_COVALENT_DOUBLE",2,"ORDER_COVALENT_TRIPLE",3,"ORDER_AROMATIC",515,"ORDER_AROMATIC_SINGLE",513,"ORDER_AROMATIC_DOUBLE",514,"ORDER_HBOND",2048,"ORDER_STEREO_NEAR",1025,"ORDER_STEREO_FAR",1041,"ORDER_PARTIAL01",33,"ORDER_PARTIAL12",66,"ORDER_PARTIAL23",97,"ORDER_PARTIAL32",100,"ORDER_UNSPECIFIED",17,"ORDER_AS_SINGLE",65536);c$.SHELL_S=c$.prototype.SHELL_S=
J.constant.EnumQuantumShell.S.id;c$.SHELL_P=c$.prototype.SHELL_P=J.constant.EnumQuantumShell.P.id;c$.SHELL_SP=c$.prototype.SHELL_SP=J.constant.EnumQuantumShell.SP.id;c$.SHELL_L=c$.prototype.SHELL_L=J.constant.EnumQuantumShell.SP.id;c$.SHELL_D_SPHERICAL=c$.prototype.SHELL_D_SPHERICAL=J.constant.EnumQuantumShell.D_SPHERICAL.id;c$.SHELL_D_CARTESIAN=c$.prototype.SHELL_D_CARTESIAN=J.constant.EnumQuantumShell.D_CARTESIAN.id;c$.SHELL_F_SPHERICAL=c$.prototype.SHELL_F_SPHERICAL=J.constant.EnumQuantumShell.F_SPHERICAL.id;
c$.SHELL_F_CARTESIAN=c$.prototype.SHELL_F_CARTESIAN=J.constant.EnumQuantumShell.F_CARTESIAN.id;c$.SHELL_G_SPHERICAL=c$.prototype.SHELL_G_SPHERICAL=J.constant.EnumQuantumShell.G_SPHERICAL.id;c$.SHELL_G_CARTESIAN=c$.prototype.SHELL_G_CARTESIAN=J.constant.EnumQuantumShell.G_CARTESIAN.id;c$.SHELL_H_SPHERICAL=c$.prototype.SHELL_H_SPHERICAL=J.constant.EnumQuantumShell.H_SPHERICAL.id;c$.SHELL_H_CARTESIAN=c$.prototype.SHELL_H_CARTESIAN=J.constant.EnumQuantumShell.H_CARTESIAN.id;c$.SUPPORTED_BASIS_FUNCTIONS=
c$.prototype.SUPPORTED_BASIS_FUNCTIONS="SPLDF";c$.NOTE_SCRIPT_FILE=c$.prototype.NOTE_SCRIPT_FILE="NOTE: file recognized as a script file: ";Clazz.defineStatics(c$,"cellParamNames","_cell_length_a _cell_length_b _cell_length_c _cell_angle_alpha _cell_angle_beta _cell_angle_gamma".split(" "))}),Clazz.declarePackage("J.adapter.smarter"),Clazz.load(["J.api.JmolAdapter"],"J.adapter.smarter.SmarterJmolAdapter","J.adapter.smarter.AtomIterator $.AtomSetCollection $.BondIterator $.Resolver $.StructureIterator J.util.Logger".split(" "),
function(){c$=Clazz.declareType(J.adapter.smarter,"SmarterJmolAdapter",J.api.JmolAdapter);Clazz.makeConstructor(c$,function(){Clazz.superConstructor(this,J.adapter.smarter.SmarterJmolAdapter,["SmarterJmolAdapter"])});Clazz.overrideMethod(c$,"getFileTypeName",function(a){return Clazz.instanceOf(a,J.adapter.smarter.AtomSetCollection)?a.getFileTypeName():Clazz.instanceOf(a,java.io.BufferedReader)?J.adapter.smarter.Resolver.getFileType(a):null},"~O");Clazz.overrideMethod(c$,"getAtomSetCollectionReader",
function(a,b,c,d){return J.adapter.smarter.SmarterJmolAdapter.staticGetAtomSetCollectionReader(a,b,c,d)},"~S,~S,~O,java.util.Map");c$.staticGetAtomSetCollectionReader=$_M(c$,"staticGetAtomSetCollectionReader",function(a,b,c,d){try{var e=J.adapter.smarter.Resolver.getAtomCollectionReader(a,b,c,d,-1);if(Clazz.instanceOf(e,String))try{J.adapter.smarter.SmarterJmolAdapter.close(c)}catch(f){if(!Clazz.exceptionOf(f,Exception))throw f;}else e.setup(a,d,c);return e}catch(g){try{J.adapter.smarter.SmarterJmolAdapter.close(c)}catch(h){if(!Clazz.exceptionOf(h,
Exception))throw h;}J.util.Logger.error(""+g);return""+g}},"~S,~S,~O,java.util.Map");$_M(c$,"getAtomSetCollectionFromReader",function(a,b,c){var d=J.adapter.smarter.Resolver.getAtomCollectionReader(a,null,b,c,-1);return Clazz.instanceOf(d,J.adapter.smarter.AtomSetCollectionReader)?(d.setup(a,c,b),d.readData()):""+d},"~S,~O,java.util.Map");Clazz.overrideMethod(c$,"getAtomSetCollection",function(a){return J.adapter.smarter.SmarterJmolAdapter.staticGetAtomSetCollection(a)},"~O");c$.staticGetAtomSetCollection=
$_M(c$,"staticGetAtomSetCollection",function(a){var b=null;try{var b=a.reader,c=a.readData();return!Clazz.instanceOf(c,J.adapter.smarter.AtomSetCollection)?c:null!=c.errorMessage?c.errorMessage:c}catch(d){try{System.out.println(d.toString())}catch(e){if(Clazz.exceptionOf(e,Exception))J.util.Logger.error(d.toString());else throw e;}try{b.close()}catch(f){if(!Clazz.exceptionOf(f,Exception))throw f;}J.util.Logger.error(""+d);return""+d}},"J.adapter.smarter.AtomSetCollectionReader");Clazz.overrideMethod(c$,
"getAtomSetCollectionReaders",function(a,b,c,d,e){for(var f=b.length,g=e?Array(f):null,h=e?null:Array(f),k=null,l=d.get("viewer"),m=0;m<f;m++)try{null!=k&&d.put("viewer",l);var n=a.getBufferedReaderOrBinaryDocument(m,!1);if(!Clazz.instanceOf(n,java.io.BufferedReader)&&!Clazz.instanceOf(n,J.api.JmolDocument))return n;var q=J.adapter.smarter.Resolver.getAtomCollectionReader(b[m],null==c?null:c[m],n,d,m);if(!Clazz.instanceOf(q,J.adapter.smarter.AtomSetCollectionReader))return q;k=q;k.setup(null,null,
null);k.isBinary?k.setup(b[m],d,a.getBufferedReaderOrBinaryDocument(m,!0)):k.setup(b[m],d,n);if(e)g[m]=k;else{q=k.readData();if(!Clazz.instanceOf(q,J.adapter.smarter.AtomSetCollection))return q;h[m]=q;if(null!=h[m].errorMessage)return h[m].errorMessage}}catch(p){return J.util.Logger.error(""+p),l.isJS||p.printStackTrace(),""+p}return e?g:this.getAtomSetCollectionFromSet(g,h,d)},"J.api.JmolFilesReaderInterface,~A,~A,java.util.Map,~B");Clazz.overrideMethod(c$,"getAtomSetCollectionFromSet",function(a,
b,c){var d=null==b?Array(a.length):b;if(null==b)for(b=0;b<a.length;b++)try{var e=a[b].readData();if(!Clazz.instanceOf(e,J.adapter.smarter.AtomSetCollection))return e;d[b]=e;if(null!=d[b].errorMessage)return d[b].errorMessage}catch(f){return J.util.Logger.error(""+f),""+f}if(c.containsKey("trajectorySteps")){a=d[0];try{a.finalizeTrajectoryAs(c.get("trajectorySteps"),c.get("vibrationSteps"))}catch(g){if(Clazz.exceptionOf(g,Exception))null==a.errorMessage&&(a.errorMessage=""+g);else throw g;}}else if(d[0].isTrajectory){a=
d[0];for(b=1;b<d.length;b++)d[0].mergeTrajectories(d[b])}else a=new J.adapter.smarter.AtomSetCollection("Array",null,d,null);return null==a.errorMessage?a:a.errorMessage},"~O,~O,java.util.Map");Clazz.overrideMethod(c$,"getAtomSetCollectionFromDOM",function(a,b){try{var c=J.adapter.smarter.Resolver.DOMResolve(a,b);if(!Clazz.instanceOf(c,J.adapter.smarter.AtomSetCollectionReader))return c;var d=c;d.setup("DOM node",b,null);c=d.readDataObject(a);return!Clazz.instanceOf(c,J.adapter.smarter.AtomSetCollection)?
c:null!=c.errorMessage?c.errorMessage:c}catch(e){return J.util.Logger.error(""+e),""+e}},"~O,java.util.Map");Clazz.overrideMethod(c$,"finish",function(a){a.finish()},"~O");Clazz.overrideMethod(c$,"getAtomSetCollectionName",function(a){return a.getCollectionName()},"~O");Clazz.overrideMethod(c$,"getAtomSetCollectionAuxiliaryInfo",function(a){return a.getAtomSetCollectionAuxiliaryInfoMap()},"~O");Clazz.overrideMethod(c$,"getAtomSetCount",function(a){return a.getAtomSetCount()},"~O");Clazz.overrideMethod(c$,
"getAtomSetNumber",function(a,b){return a.getAtomSetNumber(b)},"~O,~N");Clazz.overrideMethod(c$,"getAtomSetName",function(a,b){return a.getAtomSetName(b)},"~O,~N");Clazz.overrideMethod(c$,"getAtomSetAuxiliaryInfo",function(a,b){return a.getAtomSetAuxiliaryInfo(b)},"~O,~N");Clazz.overrideMethod(c$,"getHydrogenAtomCount",function(a){return a.getHydrogenAtomCount()},"~O");Clazz.overrideMethod(c$,"getBondList",function(a){return a.getBondList()},"~O");Clazz.overrideMethod(c$,"getAtomCount",function(a){return null==
a.bsAtoms?a.getAtomCount():a.bsAtoms.cardinality()},"~O");Clazz.overrideMethod(c$,"coordinatesAreFractional",function(a){return a.coordinatesAreFractional},"~O");Clazz.overrideMethod(c$,"getNotionalUnitcell",function(a){return a.notionalUnitCell},"~O");Clazz.overrideMethod(c$,"getPdbScaleMatrix",function(a){a=a.notionalUnitCell;if(22>a.length)return null;for(var b=Clazz.newFloatArray(16,0),c=0;16>c;c++)b[c]=a[6+c];return b},"~O");Clazz.overrideMethod(c$,"getPdbScaleTranslate",function(a){a=a.notionalUnitCell;
if(22>a.length)return null;var b=Clazz.newFloatArray(3,0);b[0]=a[9];b[1]=a[13];b[2]=a[17];return b},"~O");Clazz.overrideMethod(c$,"getAtomIterator",function(a){return new J.adapter.smarter.AtomIterator(a)},"~O");Clazz.overrideMethod(c$,"getBondIterator",function(a){return new J.adapter.smarter.BondIterator(a)},"~O");Clazz.overrideMethod(c$,"getStructureIterator",function(a){return 0==a.getStructureCount()?null:new J.adapter.smarter.StructureIterator(a)},"~O");c$.close=$_M(c$,"close",function(a){Clazz.instanceOf(a,
java.io.BufferedReader);a.close()},"~O");Clazz.defineStatics(c$,"PATH_KEY",".PATH");c$.PATH_SEPARATOR=c$.prototype.PATH_SEPARATOR=System.getProperty("path.separator","/")}),Clazz.declarePackage("J.api"),Clazz.load(null,"J.api.Interface",["J.util.Logger"],function(){c$=Clazz.declareType(J.api,"Interface");c$.getOptionInterface=$_M(c$,"getOptionInterface",function(a){return J.api.Interface.getInterface("J."+a)},"~S");c$.getApplicationInterface=$_M(c$,"getApplicationInterface",function(a){return J.api.Interface.getInterface("org.openscience.jmol.app."+
a)},"~S");c$.getInterface=$_M(c$,"getInterface",function(a){try{var b=Class.forName(a);return null==b?null:b.newInstance()}catch(c){if(Clazz.exceptionOf(c,Exception))return J.util.Logger.error("Interface.java Error creating instance for "+a+": \n"+c),null;throw c;}},"~S")}),$_L(null,"java.lang.ThreadGroup",["java.lang.NullPointerException","$.Thread"],function(){c$=$_C(function(){this.name=this.parent=null;this.maxPriority=0;$_Z(this,arguments)},java.lang,"ThreadGroup");$_K(c$,function(){this.name=
"system";this.maxPriority=10});$_K(c$,function(a){this.construct(Thread.currentThread().getThreadGroup(),a)},"~S");$_K(c$,function(a,b){if(null==a)throw new NullPointerException;this.name=b;this.parent=a;this.maxPriority=10},"ThreadGroup,~S");$_M(c$,"getName",function(){return this.name});$_M(c$,"getParent",function(){return this.parent});$_M(c$,"getMaxPriority",function(){return this.maxPriority})}),Clazz.declarePackage("J.constant"),Clazz.load(["java.lang.Enum"],"J.constant.EnumAxesMode",null,function(){c$=
Clazz.decorateAsClass(function(){this.code=0;Clazz.instantialize(this,arguments)},J.constant,"EnumAxesMode",Enum);Clazz.makeConstructor(c$,($fz=function(a){this.code=a},$fz.isPrivate=!0,$fz),"~N");$_M(c$,"getCode",function(){return this.code});c$.getAxesMode=$_M(c$,"getAxesMode",function(a){for(var b,c=0,d=J.constant.EnumAxesMode.values();c<d.length&&((b=d[c])||1);c++)if(b.getCode()==a)return b;return null},"~N");Clazz.defineEnumConstant(c$,"BOUNDBOX",0,[0]);Clazz.defineEnumConstant(c$,"MOLECULAR",
1,[1]);Clazz.defineEnumConstant(c$,"UNITCELL",2,[2])}),Clazz.declarePackage("J.constant"),Clazz.load(["java.lang.Enum"],"J.constant.EnumFileStatus",null,function(){c$=Clazz.decorateAsClass(function(){this.code=0;Clazz.instantialize(this,arguments)},J.constant,"EnumFileStatus",Enum);$_M(c$,"getCode",function(){return this.code});Clazz.makeConstructor(c$,($fz=function(a){this.code=a},$fz.isPrivate=!0,$fz),"~N");Clazz.defineEnumConstant(c$,"DELETED",0,[5]);Clazz.defineEnumConstant(c$,"CREATED",1,[3]);
Clazz.defineEnumConstant(c$,"CREATING_MODELSET",2,[2]);Clazz.defineEnumConstant(c$,"ZAPPED",3,[0]);Clazz.defineEnumConstant(c$,"NOT_LOADED",4,[-1])}),Clazz.declarePackage("J.api"),Clazz.declareInterface(J.api,"JmolAdapterAtomIterator"),Clazz.declarePackage("J.adapter.smarter"),Clazz.load(["J.api.JmolAdapterAtomIterator"],"J.adapter.smarter.AtomIterator",["java.lang.Float","J.api.JmolAdapter"],function(){c$=Clazz.decorateAsClass(function(){this.iatom=0;this.atom=null;this.atomCount=0;this.bsAtoms=
this.atoms=null;Clazz.instantialize(this,arguments)},J.adapter.smarter,"AtomIterator",null,J.api.JmolAdapterAtomIterator);Clazz.makeConstructor(c$,function(a){this.atomCount=a.getAtomCount();this.atoms=a.getAtoms();this.bsAtoms=a.bsAtoms;this.iatom=0},"J.adapter.smarter.AtomSetCollection");Clazz.overrideMethod(c$,"hasNext",function(){if(this.iatom==this.atomCount)return!1;for(;null==(this.atom=this.atoms[this.iatom++])||null!=this.bsAtoms&&!this.bsAtoms.get(this.atom.index);)if(this.iatom==this.atomCount)return!1;
this.atoms[this.iatom-1]=null;return!0});Clazz.overrideMethod(c$,"getAtomSetIndex",function(){return this.atom.atomSetIndex});Clazz.overrideMethod(c$,"getAtomSymmetry",function(){return this.atom.bsSymmetry});Clazz.overrideMethod(c$,"getAtomSite",function(){return this.atom.atomSite+1});Clazz.overrideMethod(c$,"getUniqueID",function(){return Integer.$valueOf(this.atom.index)});Clazz.overrideMethod(c$,"getElementNumber",function(){return 0<this.atom.elementNumber?this.atom.elementNumber:J.api.JmolAdapter.getElementNumber(this.atom.getElementSymbol())});
Clazz.overrideMethod(c$,"getAtomName",function(){return this.atom.atomName});Clazz.overrideMethod(c$,"getFormalCharge",function(){return this.atom.formalCharge});Clazz.overrideMethod(c$,"getPartialCharge",function(){return this.atom.partialCharge});Clazz.overrideMethod(c$,"getTensors",function(){return this.atom.tensors});Clazz.overrideMethod(c$,"getRadius",function(){return this.atom.radius});Clazz.overrideMethod(c$,"getVib",function(){return null==this.atom.vib||Float.isNaN(this.atom.vib.z)?null:
this.atom.vib});Clazz.overrideMethod(c$,"getBfactor",function(){return Float.isNaN(this.atom.bfactor)&&null!=this.atom.anisoBorU?100*this.atom.anisoBorU[7]:this.atom.bfactor});Clazz.overrideMethod(c$,"getOccupancy",function(){return Clazz.floatToInt(100*this.atom.foccupancy)});Clazz.overrideMethod(c$,"getIsHetero",function(){return this.atom.isHetero});Clazz.overrideMethod(c$,"getAtomSerial",function(){return this.atom.atomSerial});Clazz.overrideMethod(c$,"getChainID",function(){return this.atom.chainID});
Clazz.overrideMethod(c$,"getAlternateLocationID",function(){return J.api.JmolAdapter.canonizeAlternateLocationID(this.atom.alternateLocationID)});Clazz.overrideMethod(c$,"getGroup3",function(){return this.atom.group3});Clazz.overrideMethod(c$,"getSequenceNumber",function(){return this.atom.sequenceNumber});Clazz.overrideMethod(c$,"getInsertionCode",function(){return J.api.JmolAdapter.canonizeInsertionCode(this.atom.insertionCode)});Clazz.overrideMethod(c$,"getXYZ",function(){return this.atom})}),
Clazz.declarePackage("J.adapter.smarter"),Clazz.load(["java.util.Hashtable","JU.P3"],"J.adapter.smarter.AtomSetCollection","java.lang.Boolean $.Float java.util.Collections $.Properties JU.ArrayUtil $.BS $.List $.M3 $.M4 $.P3i $.ParserJS $.SB $.V3 J.adapter.smarter.Atom $.Bond $.SmarterJmolAdapter J.api.Interface J.util.BSUtil $.Escape $.Logger $.Txt".split(" "),function(){c$=Clazz.decorateAsClass(function(){this.atomSetCollectionAuxiliaryInfo=this.collectionName=this.fileTypeName=this.bsAtoms=null;
this.atomCount=0;this.atoms=null;this.bondCount=0;this.bonds=null;this.structureCount=0;this.structures=null;this.atomSetCount=0;this.currentAtomSetIndex=-1;this.errorMessage=this.latticeCells=this.atomSetAuxiliaryInfo=this.atomSetBondCounts=this.atomSetAtomCounts=this.atomSetAtomIndexes=this.atomSetNumbers=null;this.isTrajectory=this.coordinatesAreFractional=!1;this.trajectoryStepCount=0;this.trajectoryNames=this.vibrationSteps=this.trajectorySteps=null;this.doFixPeriodic=!1;this.notionalUnitCell=
null;this.allowMultiple=!1;this.vConnect=this.readerList=this.reader=null;this.connectNextAtomSet=this.connectNextAtomIndex=0;this.bsStructuredModels=this.connectLast=null;this.symmetryRange=0;this.centroidPacked=this.doCentroidUnitCell=!1;this.symmetry=this.fmatSupercell=this.ptSupercell=null;this.haveUnitCell=!1;this.doNormalize=!0;this.doPackUnitCell=!1;this.rmaxz=this.rmaxy=this.rmaxx=this.rminz=this.rminy=this.rminx=0;this.maxXYZ0=this.minXYZ0=this.maxXYZ=this.minXYZ=this.unitCellOffset=this.ptOffset=
null;this.haveAnisou=!1;this.dtype=3;this.unitCellTranslations=null;this.baseSymmetryAtomCount=0;this.checkLatticeOnly=!1;this.latticeOp=0;this.latticeOnly=!1;this.bondIndex0=this.bondCount0=0;this.applySymmetryToBonds=!1;this.checkSpecial=!0;this.checkAll=!1;this.atomSymbolicMap=this.mTemp=this.ptTemp=null;this.haveMappedSerials=!1;Clazz.instantialize(this,arguments)},J.adapter.smarter,"AtomSetCollection");Clazz.prepareFields(c$,function(){this.atomSetCollectionAuxiliaryInfo=new java.util.Hashtable;
this.atoms=Array(256);this.bonds=Array(256);this.structures=Array(16);this.atomSetNumbers=Clazz.newIntArray(16,0);this.atomSetAtomIndexes=Clazz.newIntArray(16,0);this.atomSetAtomCounts=Clazz.newIntArray(16,0);this.atomSetBondCounts=Clazz.newIntArray(16,0);this.atomSetAuxiliaryInfo=Array(16);this.notionalUnitCell=Clazz.newFloatArray(6,0);this.ptOffset=new JU.P3;this.atomSymbolicMap=new java.util.Hashtable});$_M(c$,"getFileTypeName",function(){return this.fileTypeName});$_M(c$,"getCollectionName",function(){return this.collectionName});
$_M(c$,"setCollectionName",function(a){null!=a&&(a=a.trim(),0!=a.length&&(this.collectionName=a))},"~S");$_M(c$,"getAtomSetCollectionAuxiliaryInfoMap",function(){return this.atomSetCollectionAuxiliaryInfo});$_M(c$,"clearGlobalBoolean",function(a){this.atomSetCollectionAuxiliaryInfo.remove(J.adapter.smarter.AtomSetCollection.globalBooleans[a])},"~N");$_M(c$,"setGlobalBoolean",function(a){this.setAtomSetCollectionAuxiliaryInfo(J.adapter.smarter.AtomSetCollection.globalBooleans[a],Boolean.TRUE)},"~N");
$_M(c$,"getGlobalBoolean",function(a){return this.getAtomSetCollectionAuxiliaryInfo(J.adapter.smarter.AtomSetCollection.globalBooleans[a])===Boolean.TRUE},"~N");$_M(c$,"getAtomCount",function(){return this.atomCount});$_M(c$,"getHydrogenAtomCount",function(){for(var a=0,b=0;b<this.atomCount;b++)(1==this.atoms[b].elementNumber||this.atoms[b].elementSymbol.equals("H"))&&a++;return a});$_M(c$,"getAtoms",function(){return this.atoms});$_M(c$,"getAtom",function(a){return this.atoms[a]},"~N");$_M(c$,"getBondCount",
function(){return this.bondCount});$_M(c$,"getBonds",function(){return this.bonds});$_M(c$,"getBond",function(a){return this.bonds[a]},"~N");$_M(c$,"getStructureCount",function(){return this.structureCount});$_M(c$,"getStructures",function(){return this.structures});$_M(c$,"getAtomSetCount",function(){return this.atomSetCount});$_M(c$,"getCurrentAtomSetIndex",function(){return this.currentAtomSetIndex});$_M(c$,"setCurrentAtomSetIndex",function(a){this.currentAtomSetIndex=a},"~N");$_M(c$,"setDoFixPeriodic",
function(){this.doFixPeriodic=!0});Clazz.makeConstructor(c$,function(a,b,c,d){this.fileTypeName=a;this.reader=b;this.allowMultiple=null==b||0>b.desiredVibrationNumber;a=new java.util.Properties;a.put("PATH_KEY",".PATH");a.put("PATH_SEPARATOR",J.adapter.smarter.SmarterJmolAdapter.PATH_SEPARATOR);this.setAtomSetCollectionAuxiliaryInfo("properties",a);if(null!=c){d=0;this.readerList=new JU.List;for(a=0;a<c.length;a++)(0<c[a].atomCount||null!=c[a].reader&&c[a].reader.mustFinalizeModelSet)&&this.appendAtomSetCollection(d++,
c[a]);1<d&&this.setAtomSetCollectionAuxiliaryInfo("isMultiFile",Boolean.TRUE)}else null!=d&&(this.setAtomSetCollectionAuxiliaryInfo("isMultiFile",Boolean.TRUE),this.appendAtomSetCollectionList(d))},"~S,J.adapter.smarter.AtomSetCollectionReader,~A,JU.List");$_M(c$,"appendAtomSetCollectionList",($fz=function(a){var b=a.size();if(0==b)this.errorMessage="No file found!";else for(var c=0;c<b;c++){var d=a.get(c);Clazz.instanceOf(d,JU.List)?this.appendAtomSetCollectionList(d):this.appendAtomSetCollection(c,
d)}},$fz.isPrivate=!0,$fz),"JU.List");$_M(c$,"setTrajectory",function(){this.isTrajectory||(this.trajectorySteps=new JU.List);this.isTrajectory=!0;this.addTrajectoryStep()});$_M(c$,"appendAtomSetCollection",function(a,b){null!=b.reader&&b.reader.mustFinalizeModelSet&&this.readerList.addLast(b.reader);var c=this.atomCount;this.setAtomSetCollectionAuxiliaryInfo("loadState",b.getAtomSetCollectionAuxiliaryInfo("loadState"));if(null!=b.bsAtoms){null==this.bsAtoms&&(this.bsAtoms=new JU.BS);for(var d=b.bsAtoms.nextSetBit(0);0<=
d;d=b.bsAtoms.nextSetBit(d+1))this.bsAtoms.set(c+d)}for(var d=0,e=this.atomSetCount,f=0;f<b.atomSetCount;f++){this.newAtomSet();var g=(this.atomSetAuxiliaryInfo[this.currentAtomSetIndex]=b.atomSetAuxiliaryInfo[f]).get("PDB_CONECT_firstAtom_count_max");null!=g&&(g[0]+=c);this.setAtomSetAuxiliaryInfo("title",b.collectionName);this.setAtomSetName(b.getAtomSetName(f));for(g=0;g<b.atomSetAtomCounts[f];g++){try{null!=this.bsAtoms&&this.bsAtoms.set(this.atomCount),this.newCloneAtom(b.atoms[d])}catch(h){if(Clazz.exceptionOf(h,
Exception))this.errorMessage="appendAtomCollection error: "+h;else throw h;}d++}this.atomSetNumbers[this.currentAtomSetIndex]=0>a?this.currentAtomSetIndex+1:1E6*(a+1)+b.atomSetNumbers[f]}for(d=0;d<b.bondCount;d++)f=b.bonds[d],this.addNewBondWithOrder(f.atomIndex1+c,f.atomIndex2+c,f.order);for(d=J.adapter.smarter.AtomSetCollection.globalBooleans.length;0<=--d;)b.getGlobalBoolean(d)&&this.setGlobalBoolean(d);for(d=0;d<b.structureCount;d++)c=b.structures[d],this.addStructure(c),c.modelStartEnd[0]+=e,
c.modelStartEnd[1]+=e},"~N,J.adapter.smarter.AtomSetCollection");$_M(c$,"setNoAutoBond",function(){this.setAtomSetCollectionAuxiliaryInfo("noAutoBond",Boolean.TRUE)});$_M(c$,"freeze",function(a){1==this.atomSetCount&&null==this.collectionName&&(this.collectionName=this.getAtomSetAuxiliaryInfoValue(0,"name"));a&&this.reverseAtomSets();1<this.trajectoryStepCount&&this.finalizeTrajectory();this.getList(!0);this.getList(!1);for(a=0;a<this.atomSetCount;a++)this.setAtomSetAuxiliaryInfoForSet("initialAtomCount",
Integer.$valueOf(this.atomSetAtomCounts[a]),a),this.setAtomSetAuxiliaryInfoForSet("initialBondCount",Integer.$valueOf(this.atomSetBondCounts[a]),a)},"~B");$_M(c$,"reverseAtomSets",($fz=function(){this.reverseArray(this.atomSetAtomIndexes);this.reverseArray(this.atomSetNumbers);this.reverseArray(this.atomSetAtomCounts);this.reverseArray(this.atomSetBondCounts);J.adapter.smarter.AtomSetCollection.reverseList(this.trajectorySteps);J.adapter.smarter.AtomSetCollection.reverseList(this.trajectoryNames);
J.adapter.smarter.AtomSetCollection.reverseList(this.vibrationSteps);this.reverseObject(this.atomSetAuxiliaryInfo);for(var a=0;a<this.atomCount;a++)this.atoms[a].atomSetIndex=this.atomSetCount-1-this.atoms[a].atomSetIndex;for(a=0;a<this.structureCount;a++){var b=this.structures[a].modelStartEnd[0];0<=b&&(this.structures[a].modelStartEnd[0]=this.atomSetCount-1-this.structures[a].modelStartEnd[1],this.structures[a].modelStartEnd[1]=this.atomSetCount-1-b)}for(a=0;a<this.bondCount;a++)this.bonds[a].atomSetIndex=
this.atomSetCount-1-this.atoms[this.bonds[a].atomIndex1].atomSetIndex;this.reverseSets(this.bonds,this.bondCount);for(var c=JU.ArrayUtil.createArrayOfArrayList(this.atomSetCount),a=0;a<this.atomSetCount;a++)c[a]=new JU.List;for(a=0;a<this.atomCount;a++)c[this.atoms[a].atomSetIndex].addLast(this.atoms[a]);for(var b=Clazz.newIntArray(this.atomCount,0),d=this.atomCount,a=this.atomSetCount;0<=--a;)for(var e=c[a].size();0<=--e;){var f=this.atoms[--d]=c[a].get(e);b[f.index]=d;f.index=d}for(a=0;a<this.bondCount;a++)this.bonds[a].atomIndex1=
b[this.bonds[a].atomIndex1],this.bonds[a].atomIndex2=b[this.bonds[a].atomIndex2];for(a=0;a<this.atomSetCount;a++)c=this.getAtomSetAuxiliaryInfoValue(a,"PDB_CONECT_firstAtom_count_max"),null!=c&&(c[0]=b[c[0]],c[1]=this.atomSetAtomCounts[a])},$fz.isPrivate=!0,$fz));$_M(c$,"reverseSets",($fz=function(a,b){for(var c=JU.ArrayUtil.createArrayOfArrayList(this.atomSetCount),d=0;d<this.atomSetCount;d++)c[d]=new JU.List;for(d=0;d<b;d++){if(0>a[d].atomSetIndex)return;c[a[d].atomSetIndex].addLast(a[d])}for(d=
this.atomSetCount;0<=--d;)for(var e=c[d].size();0<=--e;)a[--b]=c[d].get(e)},$fz.isPrivate=!0,$fz),"~A,~N");$_M(c$,"reverseObject",($fz=function(a){for(var b=this.atomSetCount,c=Clazz.doubleToInt(b/2);0<=--c;)JU.ArrayUtil.swap(a,c,b-1-c)},$fz.isPrivate=!0,$fz),"~A");c$.reverseList=$_M(c$,"reverseList",($fz=function(a){null!=a&&java.util.Collections.reverse(a)},$fz.isPrivate=!0,$fz),"JU.List");$_M(c$,"reverseArray",($fz=function(a){for(var b=this.atomSetCount,c=Clazz.doubleToInt(b/2);0<=--c;)JU.ArrayUtil.swapInt(a,
c,b-1-c)},$fz.isPrivate=!0,$fz),"~A");$_M(c$,"getList",($fz=function(a){var b;for(b=this.atomCount;0<=--b&&!(null!=this.atoms[b]&&"\x00"!=(a?this.atoms[b].alternateLocationID:this.atoms[b].insertionCode)););if(!(0>b)){var c=Array(this.atomSetCount);for(b=0;b<this.atomSetCount;b++)c[b]="";var d;for(b=0;b<this.atomCount;b++)if(null!=this.atoms[b]){var e=a?this.atoms[b].alternateLocationID:this.atoms[b].insertionCode;if("\x00"!=e&&0>c[d=this.atoms[b].atomSetIndex].indexOf(e))c[d]+=e}a=a?"altLocs":"insertionCodes";
for(b=0;b<this.atomSetCount;b++)0<c[b].length&&this.setAtomSetAuxiliaryInfoForSet(a,c[b],b)}},$fz.isPrivate=!0,$fz),"~B");$_M(c$,"finish",function(){if(null!=this.reader)this.reader.finalizeModelSet();else if(null!=this.readerList)for(var a=0;a<this.readerList.size();a++)this.readerList.get(a).finalizeModelSet();this.atoms=null;this.atomSetAtomCounts=Clazz.newIntArray(16,0);this.atomSetAuxiliaryInfo=Array(16);this.atomSetCollectionAuxiliaryInfo=new java.util.Hashtable;this.atomSetCount=0;this.atomSetNumbers=
Clazz.newIntArray(16,0);this.atomSymbolicMap=new java.util.Hashtable;this.connectLast=this.bonds=null;this.currentAtomSetIndex=-1;this.symmetry=this.readerList=this.notionalUnitCell=this.latticeCells=null;this.structures=Array(16);this.structureCount=0;this.vConnect=this.vibrationSteps=this.trajectorySteps=null});$_M(c$,"discardPreviousAtoms",function(){for(var a=this.atomCount;0<=--a;)this.atoms[a]=null;this.atomCount=0;this.clearSymbolicMap();this.atomSetCount=0;this.currentAtomSetIndex=-1;for(a=
this.atomSetAuxiliaryInfo.length;0<=--a;)this.atomSetAtomCounts[a]=0,this.atomSetBondCounts[a]=0,this.atomSetAuxiliaryInfo[a]=null});$_M(c$,"removeAtomSet",function(a){null==this.bsAtoms&&(this.bsAtoms=new JU.BS,this.bsAtoms.setBits(0,this.atomCount));var b=this.atomSetAtomIndexes[a],c=b+this.atomSetAtomCounts[a];this.bsAtoms.clearBits(b,c);for(b=c;b<this.atomCount;b++)this.atoms[b].atomSetIndex--;for(b=a+1;b<this.atomSetCount;b++)this.atomSetAuxiliaryInfo[b-1]=this.atomSetAuxiliaryInfo[b],this.atomSetAtomIndexes[b-
1]=this.atomSetAtomIndexes[b],this.atomSetBondCounts[b-1]=this.atomSetBondCounts[b],this.atomSetAtomCounts[b-1]=this.atomSetAtomCounts[b],this.atomSetNumbers[b-1]=this.atomSetNumbers[b];for(b=c=0;b<this.structureCount;b++){var d=this.structures[b];d.modelStartEnd[0]==a&&d.modelStartEnd[1]==a&&(this.structures[b]=null,c++)}if(0<c){a=Array(this.structureCount-c);for(c=b=0;b<this.structureCount;b++)null!=this.structures[b]&&(a[c++]=this.structures[b]);this.structures=a}for(b=0;b<this.bondCount;b++)this.bonds[b].atomSetIndex=
this.atoms[this.bonds[b].atomIndex1].atomSetIndex;this.atomSetAuxiliaryInfo[--this.atomSetCount]=null},"~N");$_M(c$,"removeCurrentAtomSet",function(){0>this.currentAtomSetIndex||(this.currentAtomSetIndex--,this.atomSetCount--)});$_M(c$,"newCloneAtom",function(a){a=a.getClone();this.addAtom(a);return a},"J.adapter.smarter.Atom");$_M(c$,"cloneFirstAtomSet",function(a){if(this.allowMultiple){this.newAtomSet();0==a&&(a=this.atomSetAtomCounts[0]);for(var b=0;b<a;++b)this.newCloneAtom(this.atoms[b])}},
"~N");$_M(c$,"cloneFirstAtomSetWithBonds",function(a){if(this.allowMultiple){this.cloneFirstAtomSet(0);for(var b=this.atomSetAtomCounts[0],c=0;c<a;c++){var d=this.bonds[this.bondCount-a];this.addNewBondWithOrder(d.atomIndex1+b,d.atomIndex2+b,d.order)}}},"~N");$_M(c$,"cloneLastAtomSet",function(){this.cloneLastAtomSetFromPoints(0,null)});$_M(c$,"cloneLastAtomSetFromPoints",function(a,b){if(this.allowMultiple){var c=0<a?a:this.getLastAtomSetAtomCount(),d=this.getLastAtomSetAtomIndex();this.newAtomSet();
for(var e=0;e<c;++e){var f=this.newCloneAtom(this.atoms[d++]);null!=b&&f.setT(b[e])}}},"~N,~A");$_M(c$,"getFirstAtomSetAtomCount",function(){return this.atomSetAtomCounts[0]});$_M(c$,"getLastAtomSetAtomCount",function(){return this.atomSetAtomCounts[this.currentAtomSetIndex]});$_M(c$,"getLastAtomSetAtomIndex",function(){return this.atomCount-this.atomSetAtomCounts[this.currentAtomSetIndex]});$_M(c$,"addNewAtom",function(){var a=new J.adapter.smarter.Atom;this.addAtom(a);return a});$_M(c$,"addAtom",
function(a){this.atomCount==this.atoms.length&&(this.atoms=2E5<this.atomCount?JU.ArrayUtil.ensureLength(this.atoms,this.atomCount+5E4):JU.ArrayUtil.doubleLength(this.atoms));0==this.atomSetCount&&this.newAtomSet();a.index=this.atomCount;this.atoms[this.atomCount++]=a;a.atomSetIndex=this.currentAtomSetIndex;a.atomSite=this.atomSetAtomCounts[this.currentAtomSetIndex]++},"J.adapter.smarter.Atom");$_M(c$,"addAtomWithMappedName",function(a){this.addAtom(a);this.mapMostRecentAtomName()},"J.adapter.smarter.Atom");
$_M(c$,"addAtomWithMappedSerialNumber",function(a){this.addAtom(a);this.mapMostRecentAtomSerialNumber()},"J.adapter.smarter.Atom");$_M(c$,"addNewBondWithOrder",function(a,b,c){if(0>a||a>=this.atomCount||0>b||b>=this.atomCount)return null;a=new J.adapter.smarter.Bond(a,b,c);this.addBond(a);return a},"~N,~N,~N");$_M(c$,"addNewBondFromNames",function(a,b,c){return this.addNewBondWithOrder(this.getAtomIndexFromName(a),this.getAtomIndexFromName(b),c)},"~S,~S,~N");$_M(c$,"addNewBondWithMappedSerialNumbers",
function(a,b,c){return this.addNewBondWithOrder(this.getAtomIndexFromSerial(a),this.getAtomIndexFromSerial(b),c)},"~N,~N,~N");$_M(c$,"addConnection",function(a){null==this.vConnect&&(this.connectLast=null,this.vConnect=new JU.List);null!=this.connectLast&&a[0]==this.connectLast[0]&&a[1]==this.connectLast[1]&&2048!=a[2]?this.connectLast[2]++:this.vConnect.addLast(this.connectLast=a)},"~A");$_M(c$,"connectAllBad",($fz=function(a){for(var b=this.connectNextAtomIndex,c=this.connectNextAtomSet;c<this.atomSetCount;c++)this.setAtomSetAuxiliaryInfoForSet("PDB_CONECT_firstAtom_count_max",
[b,this.atomSetAtomCounts[c],a],c),null!=this.vConnect&&(this.setAtomSetAuxiliaryInfoForSet("PDB_CONECT_bonds",this.vConnect,c),this.setGlobalBoolean(3)),b+=this.atomSetAtomCounts[c];this.vConnect=null;this.connectNextAtomSet=this.currentAtomSetIndex+1;this.connectNextAtomIndex=b},$fz.isPrivate=!0,$fz),"~N");$_M(c$,"connectAll",function(a,b){if(!(0>this.currentAtomSetIndex))if(b)this.connectAllBad(a);else if(this.setAtomSetAuxiliaryInfo("PDB_CONECT_firstAtom_count_max",[this.atomSetAtomIndexes[this.currentAtomSetIndex],
this.atomSetAtomCounts[this.currentAtomSetIndex],a]),null!=this.vConnect){for(var c=this.connectNextAtomIndex,d=this.connectNextAtomSet;d<this.atomSetCount;d++)this.setAtomSetAuxiliaryInfoForSet("PDB_CONECT_bonds",this.vConnect,d),this.setGlobalBoolean(3),c+=this.atomSetAtomCounts[d];this.vConnect=null;this.connectNextAtomSet=this.currentAtomSetIndex+1;this.connectNextAtomIndex=c}},"~N,~B");$_M(c$,"addBond",function(a){0<this.trajectoryStepCount||(0>a.atomIndex1||0>a.atomIndex2||0>a.order||this.atoms[a.atomIndex1].atomSetIndex!=
this.atoms[a.atomIndex2].atomSetIndex?J.util.Logger.debugging&&J.util.Logger.debug(">>>>>>BAD BOND:"+a.atomIndex1+"-"+a.atomIndex2+" order="+a.order):(this.bondCount==this.bonds.length&&(this.bonds=JU.ArrayUtil.arrayCopyObject(this.bonds,this.bondCount+1024)),this.bonds[this.bondCount++]=a,this.atomSetBondCounts[this.currentAtomSetIndex]++))},"J.adapter.smarter.Bond");$_M(c$,"finalizeStructures",function(){if(0!=this.structureCount){this.bsStructuredModels=new JU.BS;for(var a=new java.util.Hashtable,
b=0;b<this.structureCount;b++){var c=this.structures[b];-1==c.modelStartEnd[0]&&(c.modelStartEnd[0]=0,c.modelStartEnd[1]=this.atomSetCount-1);this.bsStructuredModels.setBits(c.modelStartEnd[0],c.modelStartEnd[1]+1);if(0!=c.strandCount){var c=c.structureID+" "+c.modelStartEnd[0],d=a.get(c),d=(null==d?0:d.intValue())+1;a.put(c,Integer.$valueOf(d))}}for(b=0;b<this.structureCount;b++)c=this.structures[b],1==c.strandCount&&(c.strandCount=a.get(c.structureID+" "+c.modelStartEnd[0]).intValue())}});$_M(c$,
"addStructure",function(a){this.structureCount==this.structures.length&&(this.structures=JU.ArrayUtil.arrayCopyObject(this.structures,this.structureCount+32));this.structures[this.structureCount++]=a},"J.adapter.smarter.Structure");$_M(c$,"addVibrationVectorWithSymmetry",function(a,b,c,d,e){if(e){e=this.atoms[a].atomSite;for(var f=this.atoms[a].atomSetIndex;a<this.atomCount&&this.atoms[a].atomSetIndex==f;a++)this.atoms[a].atomSite==e&&this.addVibrationVector(a,b,c,d)}else this.addVibrationVector(a,
b,c,d)},"~N,~N,~N,~N,~B");$_M(c$,"addVibrationVector",function(a,b,c,d){this.allowMultiple||(a%=this.atomCount);this.atoms[a].vib=JU.V3.new3(b,c,d)},"~N,~N,~N,~N");$_M(c$,"setAtomSetSpaceGroupName",function(a){this.setAtomSetAuxiliaryInfo("spaceGroup",a+"")},"~S");$_M(c$,"setCoordinatesAreFractional",function(a){this.coordinatesAreFractional=a;this.setAtomSetAuxiliaryInfo("coordinatesAreFractional",Boolean.$valueOf(a));a&&this.setGlobalBoolean(0)},"~B");$_M(c$,"setSymmetryRange",function(a){this.symmetryRange=
a;this.setAtomSetCollectionAuxiliaryInfo("symmetryRange",Float.$valueOf(a))},"~N");$_M(c$,"setLatticeCells",function(a,b,c,d,e,f,g){this.latticeCells=a;var h=555>=a[0]&&555<=a[1]&&(0==a[2]||1==a[2]||-1==a[2]);this.doNormalize=0!=a[0]&&(!h||1==a[2]);this.applySymmetryToBonds=b;this.doPackUnitCell=c;this.doCentroidUnitCell=d;this.centroidPacked=e;null!=f?this.setSuperCell(f):this.ptSupercell=g},"~A,~B,~B,~B,~B,~S,JU.P3");$_M(c$,"setSupercellFromPoint",function(a){this.ptSupercell=a;J.util.Logger.info("Using supercell "+
J.util.Escape.eP(a))},"JU.P3");$_M(c$,"setSuperCell",($fz=function(a){null==this.fmatSupercell&&(this.fmatSupercell=Clazz.newFloatArray(16,0),null==this.getSymmetry().getMatrixFromString(a,this.fmatSupercell,!0)?this.fmatSupercell=null:J.util.Logger.info("Using supercell \n"+JU.M4.newA(this.fmatSupercell)))},$fz.isPrivate=!0,$fz),"~S");$_M(c$,"getSymmetry",function(){null==this.symmetry&&(this.symmetry=J.api.Interface.getOptionInterface("symmetry.Symmetry"));return this.symmetry});$_M(c$,"setNotionalUnitCell",
function(a,b,c){this.notionalUnitCell=Clazz.newFloatArray(a.length,0);this.unitCellOffset=c;for(var d=0;d<a.length;d++)this.notionalUnitCell[d]=a[d];this.haveUnitCell=!0;this.setAtomSetAuxiliaryInfo("notionalUnitcell",this.notionalUnitCell);this.setGlobalBoolean(2);this.getSymmetry().setUnitCell(this.notionalUnitCell);null!=c&&(this.symmetry.setOffsetPt(c),this.setAtomSetAuxiliaryInfo("unitCellOffset",c));null!=b&&(this.symmetry.setUnitCellOrientation(b),this.setAtomSetAuxiliaryInfo("matUnitCellOrientation",
b))},"~A,JU.M3,JU.P3");$_M(c$,"addSpaceGroupOperation",function(a){this.getSymmetry().setSpaceGroup(this.doNormalize);return this.symmetry.addSpaceGroupOperation(a,0)},"~S");$_M(c$,"setLatticeParameter",function(a){this.getSymmetry().setSpaceGroup(this.doNormalize);this.symmetry.setLattice(a)},"~N");$_M(c$,"applySymmetry",function(a){null!=a&&this.getSymmetry().setSpaceGroupS(a);this.applySymmetryLattice(this.latticeCells[0],this.latticeCells[1],Math.abs(this.latticeCells[2]))},"J.api.SymmetryInterface");
$_M(c$,"applySymmetryLattice",($fz=function(a,b,c){if(this.coordinatesAreFractional&&this.getSymmetry().haveSpaceGroup()){if(null!=this.fmatSupercell){this.rminz=this.rminy=this.rminx=3.4028235E38;this.rmaxz=this.rmaxy=this.rmaxx=-3.4028235E38;var d=this.setSym(0,1,2),e=this.setSym(4,5,6),f=this.setSym(8,9,10);this.minXYZ=JU.P3i.new3(Clazz.floatToInt(this.rminx),Clazz.floatToInt(this.rminy),Clazz.floatToInt(this.rminz));this.maxXYZ=JU.P3i.new3(Clazz.floatToInt(this.rmaxx),Clazz.floatToInt(this.rmaxy),
Clazz.floatToInt(this.rmaxz));this.applyAllSymmetry();for(var g=this.getLastAtomSetAtomIndex(),h=g;h<this.atomCount;h++)this.symmetry.toCartesian(this.atoms[h],!0);this.symmetry=null;this.setNotionalUnitCell([0,0,0,0,0,0,d.x,d.y,d.z,e.x,e.y,e.z,f.x,f.y,f.z],null,this.getAtomSetAuxiliaryInfoValue(-1,"unitCellOffset"));this.setAtomSetSpaceGroupName("P1");this.getSymmetry().setSpaceGroup(this.doNormalize);this.symmetry.addSpaceGroupOperation("x,y,z",0);for(h=g;h<this.atomCount;h++)this.symmetry.toFractional(this.atoms[h],
!0);this.haveAnisou=!1;this.atomSetAuxiliaryInfo[this.currentAtomSetIndex].remove("matUnitCellOrientation");this.doPackUnitCell=!1}this.minXYZ=new JU.P3i;this.maxXYZ=JU.P3i.new3(a,b,c);this.applyAllSymmetry();this.fmatSupercell=null}},$fz.isPrivate=!0,$fz),"~N,~N,~N");$_M(c$,"setSym",($fz=function(a,b,c){var d=new JU.P3;d.set(this.fmatSupercell[a],this.fmatSupercell[b],this.fmatSupercell[c]);this.setSymmetryMinMax(d);this.symmetry.toCartesian(d,!1);return d},$fz.isPrivate=!0,$fz),"~N,~N,~N");$_M(c$,
"setSymmetryMinMax",($fz=function(a){this.rminx>a.x&&(this.rminx=a.x);this.rminy>a.y&&(this.rminy=a.y);this.rminz>a.z&&(this.rminz=a.z);this.rmaxx<a.x&&(this.rmaxx=a.x);this.rmaxy<a.y&&(this.rmaxy=a.y);this.rmaxz<a.z&&(this.rmaxz=a.z)},$fz.isPrivate=!0,$fz),"JU.P3");$_M(c$,"isInSymmetryRange",($fz=function(a){return a.x>=this.rminx&&a.y>=this.rminy&&a.z>=this.rminz&&a.x<=this.rmaxx&&a.y<=this.rmaxy&&a.z<=this.rmaxz},$fz.isPrivate=!0,$fz),"JU.P3");c$.isWithinCell=$_M(c$,"isWithinCell",($fz=function(a,
b,c,d,e,f,g,h){return b.x>c-0.02&&b.x<d+0.02&&(2>a||b.y>e-0.02&&b.y<f+0.02)&&(3>a||b.z>g-0.02&&b.z<h+0.02)},$fz.isPrivate=!0,$fz),"~N,JU.P3,~N,~N,~N,~N,~N,~N");$_M(c$,"setAnisoBorU",function(a,b,c){this.haveAnisou=!0;a.anisoBorU=b;b[6]=c},"J.adapter.smarter.Atom,~A,~N");$_M(c$,"getAnisoBorU",function(a){return a.anisoBorU},"J.adapter.smarter.Atom");$_M(c$,"setTensors",function(){if(this.haveAnisou){this.getSymmetry();for(var a=this.getLastAtomSetAtomIndex();a<this.atomCount;a++)this.atoms[a].addTensor(this.symmetry.getTensor(this.atoms[a].anisoBorU),
null,!1)}});$_M(c$,"setLatticeOnly",function(a){this.checkLatticeOnly=a},"~B");$_M(c$,"setBaseSymmetryAtomCount",function(a){this.baseSymmetryAtomCount=a},"~N");$_M(c$,"applyAllSymmetry",($fz=function(){var a=0==this.baseSymmetryAtomCount?this.getLastAtomSetAtomCount():this.baseSymmetryAtomCount,b=this.getLastAtomSetAtomIndex();this.setTensors();this.bondCount0=this.bondCount;this.finalizeSymmetry(b,a);var c=this.symmetry.getSpaceGroupOperationCount();this.getSymmetry().setMinMaxLatticeParameters(this.minXYZ,
this.maxXYZ);this.dtype=Clazz.floatToInt(this.getSymmetry().getUnitCellInfoType(6));this.doCentroidUnitCell&&this.setAtomSetCollectionAuxiliaryInfo("centroidMinMax",[this.minXYZ.x,this.minXYZ.y,this.minXYZ.z,this.maxXYZ.x,this.maxXYZ.y,this.maxXYZ.z,this.centroidPacked?1:0]);if(null!=this.ptSupercell)switch(this.setAtomSetAuxiliaryInfo("supercell",this.ptSupercell),this.dtype){case 3:this.minXYZ.z*=Clazz.floatToInt(Math.abs(this.ptSupercell.z)),this.maxXYZ.z*=Clazz.floatToInt(Math.abs(this.ptSupercell.z));
case 2:this.minXYZ.y*=Clazz.floatToInt(Math.abs(this.ptSupercell.y)),this.maxXYZ.y*=Clazz.floatToInt(Math.abs(this.ptSupercell.y));case 1:this.minXYZ.x*=Clazz.floatToInt(Math.abs(this.ptSupercell.x)),this.maxXYZ.x*=Clazz.floatToInt(Math.abs(this.ptSupercell.x))}if(this.doCentroidUnitCell||this.doPackUnitCell||0!=this.symmetryRange&&1==this.maxXYZ.x-this.minXYZ.x&&1==this.maxXYZ.y-this.minXYZ.y&&1==this.maxXYZ.z-this.minXYZ.z)switch(this.minXYZ0=JU.P3i.new3(this.minXYZ.x,this.minXYZ.y,this.minXYZ.z),
this.maxXYZ0=JU.P3i.new3(this.maxXYZ.x,this.maxXYZ.y,this.maxXYZ.z),this.dtype){case 3:this.minXYZ.z--,this.maxXYZ.z++;case 2:this.minXYZ.y--,this.maxXYZ.y++;case 1:this.minXYZ.x--,this.maxXYZ.x++}for(var d=(this.maxXYZ.x-this.minXYZ.x)*(this.maxXYZ.y-this.minXYZ.y)*(this.maxXYZ.z-this.minXYZ.z),e=this.checkSpecial?a*c*d:0<this.symmetryRange?a*c:1,f=Array(e),g=0;g<a;g++)this.atoms[g+b].bsSymmetry=J.util.BSUtil.newBitSet(c*(d+1));var g=0,h=Clazz.newIntArray(d,0);this.unitCellTranslations=Array(d);
var k=d=0,l=Math.abs(this.symmetryRange),m=0!=this.symmetryRange,n=0>this.symmetryRange,q=0<this.symmetryRange;m&&(this.rminz=this.rminy=this.rminx=3.4028235E38,this.rmaxz=this.rmaxy=this.rmaxx=-3.4028235E38);this.latticeOp=this.symmetry.getLatticeOp();this.checkAll=1==this.atomSetCount&&this.checkSpecial&&0<=this.latticeOp;this.latticeOnly=this.checkLatticeOnly&&0<=this.latticeOp;var p=this.symmetry.getSpaceGroupOperation(0);this.doPackUnitCell&&this.ptOffset.set(0,0,0);for(var r=this.minXYZ.x;r<
this.maxXYZ.x;r++)for(var s=this.minXYZ.y;s<this.maxXYZ.y;s++)for(var t=this.minXYZ.z;t<this.maxXYZ.z;t++)if(this.unitCellTranslations[d]=JU.V3.new3(r,s,t),h[d++]=555+100*r+10*s+t,!(0!=r||0!=s||0!=t||0==f.length)){for(g=0;g<a;g++){var k=this.atoms[b+g],u=JU.P3.newP(k);p.transform(u);this.symmetry.toCartesian(u,!1);this.doPackUnitCell&&(this.symmetry.toUnitCell(u,this.ptOffset),k.setT(u),this.symmetry.toFractional(k,!1));k.bsSymmetry.set(d*c);k.bsSymmetry.set(0);m&&this.setSymmetryMinMax(u);g<e&&(f[g]=
u)}n&&(this.rminx-=l,this.rminy-=l,this.rminz-=l,this.rmaxx+=l,this.rmaxy+=l,this.rmaxz+=l);k=g=this.symmetryAddAtoms(b,a,0,0,0,0,g,d*c,f)}q&&(this.rminx-=l,this.rminy-=l,this.rminz-=l,this.rmaxx+=l,this.rmaxy+=l,this.rmaxz+=l);d=0;for(r=this.minXYZ.x;r<this.maxXYZ.x;r++)for(s=this.minXYZ.y;s<this.maxXYZ.y;s++)for(t=this.minXYZ.z;t<this.maxXYZ.z;t++)if(d++,0!=r||0!=s||0!=t)g=this.symmetryAddAtoms(b,a,r,s,t,k,g,d*c,f);d*a==this.atomCount-b&&this.appendAtomProperties(d);this.setSymmetryOps();this.setAtomSetAuxiliaryInfo("presymmetryAtomIndex",
Integer.$valueOf(b));this.setAtomSetAuxiliaryInfo("presymmetryAtomCount",Integer.$valueOf(a));this.setAtomSetAuxiliaryInfo("latticeDesignation",this.symmetry.getLatticeDesignation());this.setAtomSetAuxiliaryInfo("unitCellRange",h);this.setAtomSetAuxiliaryInfo("unitCellTranslations",this.unitCellTranslations);this.notionalUnitCell=Clazz.newFloatArray(6,0);this.coordinatesAreFractional=!1;this.setAtomSetAuxiliaryInfo("hasSymmetry",Boolean.TRUE);this.setGlobalBoolean(1)},$fz.isPrivate=!0,$fz));$_M(c$,
"finalizeSymmetry",($fz=function(a,b){this.symmetry.setFinalOperations(this.atoms,a,b,this.doNormalize);var c=this.getAtomSetAuxiliaryInfoValue(-1,"spaceGroup");(null==c||c.equals("unspecified!"))&&this.setAtomSetSpaceGroupName(this.symmetry.getSpaceGroupName())},$fz.isPrivate=!0,$fz),"~N,~N");$_M(c$,"setSymmetryOps",($fz=function(){var a=this.symmetry.getSpaceGroupOperationCount();if(0<a){for(var b=Array(a),c=0;c<a;c++)b[c]=""+this.symmetry.getSpaceGroupXyz(c,this.doNormalize);this.setAtomSetAuxiliaryInfo("symmetryOperations",
b)}this.setAtomSetAuxiliaryInfo("symmetryCount",Integer.$valueOf(a))},$fz.isPrivate=!0,$fz));$_M(c$,"setCheckSpecial",function(a){this.checkSpecial=a},"~B");$_M(c$,"symmetryAddAtoms",($fz=function(a,b,c,d,e,f,g,h,k){var l=0==f,m=this.bondCount0>this.bondIndex0&&this.applySymmetryToBonds,n=m?Clazz.newIntArray(b,0):null;this.doPackUnitCell&&this.ptOffset.set(c,d,e);var q=this.symmetryRange*this.symmetryRange,p=0>this.symmetryRange,r=0<this.symmetryRange,s=l&&r,r=(new Boolean(r&!l)).valueOf(),t=this.symmetry.getSpaceGroupOperationCount();
1==t&&(this.checkSpecial=!1);var u=p||r,v=this.checkSpecial||u,y=this.checkSpecial||s;p&&(f=b);b=a+b;for(var p=new JU.P3,A=0;A<t;A++)if(!(l&&0==A||this.latticeOnly&&0<A&&A!=this.latticeOp)){for(var B=this.checkSpecial?g:r?f:0,w=a;w<b;w++)if(!this.atoms[w].ignoreSymmetry&&(null==this.bsAtoms||this.bsAtoms.get(w))){this.symmetry.newSpaceGroupPoint(A,this.atoms[w],p,c,d,e);var x=null,z=JU.P3.newP(p);this.symmetry.toCartesian(z,!1);if(this.doPackUnitCell&&(this.symmetry.toUnitCell(z,this.ptOffset),p.setT(z),
this.symmetry.toFractional(p,!1),!J.adapter.smarter.AtomSetCollection.isWithinCell(this.dtype,p,this.minXYZ0.x,this.maxXYZ0.x,this.minXYZ0.y,this.maxXYZ0.y,this.minXYZ0.z,this.maxXYZ0.z)))continue;s&&this.setSymmetryMinMax(z);if(v){var D=3.4028235E38;if(u&&!this.isInSymmetryRange(z))continue;for(var C=this.checkAll?this.atomCount:B;0<=--C;){var E=z.distanceSquared(k[C]);if(this.checkSpecial&&1E-4>E){x=this.atoms[a+C];if(null==x.atomName||x.atomName.equals(this.atoms[w].atomName))break;x=null}r&&(C<
f&&E<D)&&(D=E)}if(r&&D>q)continue}C=this.atoms[w].atomSite;if(null!=x)m&&(n[C]=x.index),x.bsSymmetry.set(h+A),x.bsSymmetry.set(A);else if(m&&(n[C]=this.atomCount),x=this.newCloneAtom(this.atoms[w]),x.setT(p),x.atomSite=C,x.bsSymmetry=J.util.BSUtil.newAndSetBit(h+A),x.bsSymmetry.set(A),y&&(k[g++]=z),null!=this.atoms[w].tensors){x.tensors=null;for(C=this.atoms[w].tensors.size();0<=--C;)z=this.atoms[w].tensors.get(C),null!=z&&(1==t?x.addTensor(z.copyTensor(),null,!1):this.addRotatedTensor(x,z,A,!1))}}if(m)for(B=
this.bondIndex0;B<this.bondCount0;B++)w=this.bonds[B],x=this.atoms[w.atomIndex1],z=this.atoms[w.atomIndex2],null==x||null==z||(x=n[x.atomSite],z=n[z.atomSite],(x>=b||z>=b)&&this.addNewBondWithOrder(x,z,w.order))}return g},$fz.isPrivate=!0,$fz),"~N,~N,~N,~N,~N,~N,~N,~N,~A");$_M(c$,"addRotatedTensor",function(a,b,c,d){null==this.ptTemp&&(this.ptTemp=new JU.P3,this.mTemp=new JU.M3);return a.addTensor(J.api.Interface.getOptionInterface("util.Tensor").setFromEigenVectors(this.symmetry.rotateAxes(c,b.eigenVectors,
this.ptTemp,this.mTemp),b.eigenValues,b.isIsotropic?"iso":b.type,b.id),null,d)},"J.adapter.smarter.Atom,J.util.Tensor,~N,~B");$_M(c$,"applySymmetryBio",function(a,b,c,d){if(null!=this.latticeCells&&0!=this.latticeCells[0])J.util.Logger.error("Cannot apply biomolecule when lattice cells are indicated");else{this.doNormalize=!1;this.symmetry=null;this.getSymmetry();this.setNotionalUnitCell(b,null,this.unitCellOffset);this.getSymmetry().setSpaceGroup(this.doNormalize);this.addSpaceGroupOperation("x,y,z");
this.setAtomSetSpaceGroupName("biomolecule");var e=a.size();this.applySymmetryToBonds=c;this.bondCount0=this.bondCount;var f=this.bondCount0>this.bondIndex0&&c,g=f?Clazz.newIntArray(this.atomCount,0):null;c=this.getLastAtomSetAtomIndex();var h=this.atomCount;0<=d.indexOf("#<")&&(e=Math.min(e,JU.ParserJS.parseInt(d.substring(d.indexOf("#<")+2))-1),d=J.util.Txt.simpleReplace(d,"#<","_<"));for(var k=c;k<h;k++)this.atoms[k].bsSymmetry=J.util.BSUtil.newAndSetBit(0);for(var l=1;l<e;l++){if(0<=d.indexOf("!#")){if(0<=
d.indexOf("!#"+(l+1)+";"))continue}else if(0<=d.indexOf("#")&&0>d.indexOf("#"+(l+1)+";"))continue;for(var m=a.get(l),k=c;k<h;k++)if(null==this.bsAtoms||this.bsAtoms.get(k))try{var n=this.atoms[k].atomSite,q;f&&(g[n]=this.atomCount);q=this.newCloneAtom(this.atoms[k]);null!=this.bsAtoms&&this.bsAtoms.set(q.index);q.atomSite=n;m.transform(q);q.bsSymmetry=J.util.BSUtil.newAndSetBit(l);if(f)for(var p=this.bondIndex0;p<this.bondCount0;p++){var r=this.bonds[p],s=g[this.atoms[r.atomIndex1].atomSite],t=g[this.atoms[r.atomIndex2].atomSite];
(s>=h||t>=h)&&this.addNewBondWithOrder(s,t,r.order)}}catch(u){if(Clazz.exceptionOf(u,Exception))this.errorMessage="appendAtomCollection error: "+u;else throw u;}m.m03/=b[0];m.m13/=b[1];m.m23/=b[2];null!=this.symmetry&&0<l&&this.symmetry.addSpaceGroupOperationM(m)}a=h-c;this.setAtomSetAuxiliaryInfo("presymmetryAtomIndex",Integer.$valueOf(c));this.setAtomSetAuxiliaryInfo("presymmetryAtomCount",Integer.$valueOf(a));this.setAtomSetAuxiliaryInfo("biosymmetryCount",Integer.$valueOf(e));null!=this.symmetry&&
(this.finalizeSymmetry(c,a),this.setSymmetryOps());this.symmetry=null;this.coordinatesAreFractional=!1;this.setAtomSetAuxiliaryInfo("hasSymmetry",Boolean.TRUE);this.setGlobalBoolean(1)}},"JU.List,~A,~B,~S");$_M(c$,"mapMostRecentAtomName",($fz=function(){if(0<this.atomCount){var a=this.atomCount-1,b=this.atoms[a].atomName;null!=b&&this.atomSymbolicMap.put(b,Integer.$valueOf(a))}},$fz.isPrivate=!0,$fz));$_M(c$,"clearSymbolicMap",function(){this.atomSymbolicMap.clear();this.haveMappedSerials=!1});$_M(c$,
"mapMostRecentAtomSerialNumber",($fz=function(){if(0!=this.atomCount){var a=this.atomCount-1,b=this.atoms[a].atomSerial;-2147483648!=b&&this.atomSymbolicMap.put(Integer.$valueOf(b),Integer.$valueOf(a));this.haveMappedSerials=!0}},$fz.isPrivate=!0,$fz));$_M(c$,"createAtomSerialMap",function(){if(!(this.haveMappedSerials||0>this.currentAtomSetIndex)){for(var a=this.getLastAtomSetAtomCount();a<this.atomCount;a++){var b=this.atoms[a].atomSerial;-2147483648!=b&&this.atomSymbolicMap.put(Integer.$valueOf(b),
Integer.$valueOf(a))}this.haveMappedSerials=!0}});$_M(c$,"getAtomIndexFromName",function(a){return this.getMapIndex(a)},"~S");$_M(c$,"getAtomIndexFromSerial",function(a){return this.getMapIndex(Integer.$valueOf(a))},"~N");$_M(c$,"getMapIndex",($fz=function(a){a=this.atomSymbolicMap.get(a);return null==a?-1:a.intValue()},$fz.isPrivate=!0,$fz),"~O");$_M(c$,"setAtomSetCollectionAuxiliaryInfo",function(a,b){null==b?this.atomSetCollectionAuxiliaryInfo.remove(a):this.atomSetCollectionAuxiliaryInfo.put(a,
b)},"~S,~O");$_M(c$,"setAtomSetCollectionPartialCharges",function(a){if(!this.atomSetCollectionAuxiliaryInfo.containsKey(a))return!1;for(var b=this.atomSetCollectionAuxiliaryInfo.get(a),c=b.size();0<=--c;)this.atoms[c].partialCharge=b.get(c).floatValue();J.util.Logger.info("Setting partial charges type "+a);return!0},"~S");$_M(c$,"mapPartialCharge",function(a,b){this.atoms[this.getAtomIndexFromName(a)].partialCharge=b},"~S,~N");$_M(c$,"getAtomSetCollectionAuxiliaryInfo",function(a){return this.atomSetCollectionAuxiliaryInfo.get(a)},
"~S");$_M(c$,"addTrajectoryStep",($fz=function(){for(var a=Array(this.atomCount),b=0<this.atomCount&&null!=this.atoms[0].vib&&!Float.isNaN(this.atoms[0].vib.z),c=b?Array(this.atomCount):null,d=0==this.trajectoryStepCount?null:this.trajectorySteps.get(this.trajectoryStepCount-1),e=0;e<this.atomCount;e++){var f=JU.P3.newP(this.atoms[e]);this.doFixPeriodic&&null!=d&&(f=J.adapter.smarter.AtomSetCollection.fixPeriodic(f,d[e]));a[e]=f;b&&(c[e]=this.atoms[e].vib)}if(b){if(null==this.vibrationSteps){this.vibrationSteps=
new JU.List;for(e=0;e<this.trajectoryStepCount;e++)this.vibrationSteps.addLast(null)}this.vibrationSteps.addLast(c)}this.trajectorySteps.addLast(a);this.trajectoryStepCount++},$fz.isPrivate=!0,$fz));c$.fixPeriodic=$_M(c$,"fixPeriodic",($fz=function(a,b){a.x=J.adapter.smarter.AtomSetCollection.fixPoint(a.x,b.x);a.y=J.adapter.smarter.AtomSetCollection.fixPoint(a.y,b.y);a.z=J.adapter.smarter.AtomSetCollection.fixPoint(a.z,b.z);return a},$fz.isPrivate=!0,$fz),"JU.P3,JU.P3");c$.fixPoint=$_M(c$,"fixPoint",
($fz=function(a,b){for(;0.9<a-b;)a-=1;for(;-0.9>a-b;)a+=1;return a},$fz.isPrivate=!0,$fz),"~N,~N");$_M(c$,"finalizeTrajectoryAs",function(a,b){this.trajectorySteps=a;this.vibrationSteps=b;this.trajectoryStepCount=a.size();this.finalizeTrajectory()},"JU.List,JU.List");$_M(c$,"finalizeTrajectory",($fz=function(){if(0!=this.trajectoryStepCount){var a=this.trajectorySteps.get(0),b=null==this.vibrationSteps?null:this.vibrationSteps.get(0),c=new JU.V3;if(null!=this.vibrationSteps&&null!=b&&b.length<this.atomCount||
a.length<this.atomCount)this.errorMessage="File cannot be loaded as a trajectory";else{for(var d=0;d<this.atomCount;d++)null!=this.vibrationSteps&&(this.atoms[d].vib=null==b?c:b[d]),null!=a[d]&&this.atoms[d].setT(a[d]);this.setAtomSetCollectionAuxiliaryInfo("trajectorySteps",this.trajectorySteps);null!=this.vibrationSteps&&this.setAtomSetCollectionAuxiliaryInfo("vibrationSteps",this.vibrationSteps)}}},$fz.isPrivate=!0,$fz));$_M(c$,"newAtomSet",function(){this.newAtomSetClear(!0)});$_M(c$,"newAtomSetClear",
function(a){!this.allowMultiple&&0<=this.currentAtomSetIndex&&this.discardPreviousAtoms();this.bondIndex0=this.bondCount;this.isTrajectory&&this.discardPreviousAtoms();this.currentAtomSetIndex=this.atomSetCount++;this.atomSetCount>this.atomSetNumbers.length&&(this.atomSetAtomIndexes=JU.ArrayUtil.doubleLengthI(this.atomSetAtomIndexes),this.atomSetAtomCounts=JU.ArrayUtil.doubleLengthI(this.atomSetAtomCounts),this.atomSetBondCounts=JU.ArrayUtil.doubleLengthI(this.atomSetBondCounts),this.atomSetAuxiliaryInfo=
JU.ArrayUtil.doubleLength(this.atomSetAuxiliaryInfo));this.atomSetAtomIndexes[this.currentAtomSetIndex]=this.atomCount;this.atomSetCount+this.trajectoryStepCount>this.atomSetNumbers.length&&(this.atomSetNumbers=JU.ArrayUtil.doubleLengthI(this.atomSetNumbers));this.isTrajectory?this.atomSetNumbers[this.currentAtomSetIndex+this.trajectoryStepCount]=this.atomSetCount+this.trajectoryStepCount:this.atomSetNumbers[this.currentAtomSetIndex]=this.atomSetCount;a&&this.atomSymbolicMap.clear();this.setAtomSetAuxiliaryInfo("title",
this.collectionName)},"~B");$_M(c$,"getAtomSetAtomIndex",function(a){return this.atomSetAtomIndexes[a]},"~N");$_M(c$,"getAtomSetAtomCount",function(a){return this.atomSetAtomCounts[a]},"~N");$_M(c$,"getAtomSetBondCount",function(a){return this.atomSetBondCounts[a]},"~N");$_M(c$,"setAtomSetName",function(a){this.isTrajectory?this.setTrajectoryName(a):(this.setAtomSetAuxiliaryInfoForSet("name",a,this.currentAtomSetIndex),this.allowMultiple||this.setCollectionName(a))},"~S");$_M(c$,"setTrajectoryName",
($fz=function(a){if(0!=this.trajectoryStepCount){null==this.trajectoryNames&&(this.trajectoryNames=new JU.List);for(var b=this.trajectoryNames.size();b<this.trajectoryStepCount;b++)this.trajectoryNames.addLast(null);this.trajectoryNames.set(this.trajectoryStepCount-1,a)}},$fz.isPrivate=!0,$fz),"~S");$_M(c$,"setAtomSetNames",function(a,b,c){for(var d=this.currentAtomSetIndex;0<=--b&&0<=d;--d)(null==c||!c.get(d))&&this.setAtomSetAuxiliaryInfoForSet("name",a,d)},"~S,~N,JU.BS");$_M(c$,"setCurrentAtomSetNumber",
function(a){this.setAtomSetNumber(this.currentAtomSetIndex+(this.isTrajectory?this.trajectoryStepCount:0),a)},"~N");$_M(c$,"setAtomSetNumber",function(a,b){this.atomSetNumbers[a]=b},"~N,~N");$_M(c$,"setAtomSetModelProperty",function(a,b){this.setAtomSetModelPropertyForSet(a,b,this.currentAtomSetIndex)},"~S,~S");$_M(c$,"setAtomSetModelPropertyForSet",function(a,b,c){var d=this.getAtomSetAuxiliaryInfoValue(c,"modelProperties");null==d&&this.setAtomSetAuxiliaryInfoForSet("modelProperties",d=new java.util.Properties,
c);d.put(a,b)},"~S,~S,~N");$_M(c$,"setAtomSetAtomProperty",function(a,b,c){b.endsWith("\n")||(b+="\n");0>c&&(c=this.currentAtomSetIndex);var d=this.getAtomSetAuxiliaryInfoValue(c,"atomProperties");null==d&&this.setAtomSetAuxiliaryInfoForSet("atomProperties",d=new java.util.Hashtable,c);d.put(a,b)},"~S,~S,~N");$_M(c$,"appendAtomProperties",($fz=function(a){var b=this.getAtomSetAuxiliaryInfoValue(-1,"atomProperties");if(null!=b)for(var c,d=b.entrySet().iterator();d.hasNext()&&((c=d.next())||1);){for(var e=
c.getKey(),f=c.getValue(),g=new JU.SB,h=a;0<=--h;)g.append(f);b.put(e,g.toString())}},$fz.isPrivate=!0,$fz),"~N");$_M(c$,"setAtomSetPartialCharges",function(a){if(!this.atomSetAuxiliaryInfo[this.currentAtomSetIndex].containsKey(a))return!1;a=this.getAtomSetAuxiliaryInfoValue(this.currentAtomSetIndex,a);for(var b=a.size();0<=--b;)this.atoms[b].partialCharge=a.get(b).floatValue();return!0},"~S");$_M(c$,"getAtomSetAuxiliaryInfoValue",function(a,b){return this.atomSetAuxiliaryInfo[0<=a?a:this.currentAtomSetIndex].get(b)},
"~N,~S");$_M(c$,"setAtomSetAuxiliaryInfo",function(a,b){this.setAtomSetAuxiliaryInfoForSet(a,b,this.currentAtomSetIndex)},"~S,~O");$_M(c$,"setAtomSetAuxiliaryInfoForSet",function(a,b,c){0>c||(null==this.atomSetAuxiliaryInfo[c]&&(this.atomSetAuxiliaryInfo[c]=new java.util.Hashtable),null==b?this.atomSetAuxiliaryInfo[c].remove(a):this.atomSetAuxiliaryInfo[c].put(a,b))},"~S,~O,~N");$_M(c$,"setAtomSetPropertyForSets",function(a,b,c){for(var d=this.currentAtomSetIndex;0<=--c&&0<=d;--d)this.setAtomSetModelPropertyForSet(a,
b,d)},"~S,~S,~N");$_M(c$,"cloneLastAtomSetProperties",function(){this.cloneAtomSetProperties(this.currentAtomSetIndex-1)});$_M(c$,"cloneAtomSetProperties",function(a){a=this.getAtomSetAuxiliaryInfoValue(a,"modelProperties");null!=a&&this.setAtomSetAuxiliaryInfoForSet("modelProperties",a.clone(),this.currentAtomSetIndex)},"~N");$_M(c$,"getAtomSetNumber",function(a){return this.atomSetNumbers[a>=this.atomSetCount?0:a]},"~N");$_M(c$,"getAtomSetName",function(a){if(null!=this.trajectoryNames&&a<this.trajectoryNames.size())return this.trajectoryNames.get(a);
a>=this.atomSetCount&&(a=this.atomSetCount-1);return this.getAtomSetAuxiliaryInfoValue(a,"name")},"~N");$_M(c$,"getAtomSetAuxiliaryInfo",function(a){return this.atomSetAuxiliaryInfo[a>=this.atomSetCount?this.atomSetCount-1:a]},"~N");$_M(c$,"setAtomNames",function(a){if(null==a)return null;for(var b,c=0;c<this.atomCount;c++)if(null!=(b=a.getProperty(this.atoms[c].atomName)))this.atoms[c].atomName=b;return null},"java.util.Properties");$_M(c$,"setAtomSetEnergy",function(a,b){0>this.currentAtomSetIndex||
(J.util.Logger.info("Energy for model "+(this.currentAtomSetIndex+1)+" = "+a),this.setAtomSetAuxiliaryInfo("EnergyString",a),this.setAtomSetAuxiliaryInfo("Energy",Float.$valueOf(b)),this.setAtomSetModelProperty("Energy",""+b))},"~S,~N");$_M(c$,"setAtomSetFrequency",function(a,b,c,d){c+=" "+(null==d?"cm^-1":d);d=(null==b?"":b+" ")+c;this.setAtomSetName(d);this.setAtomSetModelProperty("Frequency",c);null!=b&&this.setAtomSetModelProperty("FrequencyLabel",b);this.setAtomSetModelProperty(".PATH",(null==
a?"":a+J.adapter.smarter.SmarterJmolAdapter.PATH_SEPARATOR+"Frequencies")+"Frequencies");return d},"~S,~S,~S,~S");$_M(c$,"toCartesian",function(a){for(var b=this.getLastAtomSetAtomIndex();b<this.atomCount;b++)a.toCartesian(this.atoms[b],!0)},"J.api.SymmetryInterface");$_M(c$,"getBondList",function(){for(var a=Array(this.bondCount),b=0;b<this.bondCount;b++)a[b]=[this.atoms[this.bonds[b].atomIndex1].atomName,this.atoms[this.bonds[b].atomIndex2].atomName,""+this.bonds[b].order];return a});$_M(c$,"centralize",
function(){for(var a=new JU.P3,b=0;b<this.atomSetCount;b++){var c=this.atomSetAtomCounts[b],d=this.atomSetAtomIndexes[b];a.set(0,0,0);for(var e=d+c;--e>=d;)a.x+=this.atoms[e].x,a.y+=this.atoms[e].y,a.z+=this.atoms[e].z;a.scale(1/c);for(e=d+c;--e>=d;)this.atoms[e].x-=a.x,this.atoms[e].y-=a.y,this.atoms[e].z-=a.z}});$_M(c$,"mergeTrajectories",function(a){if(this.isTrajectory&&a.isTrajectory&&null==this.vibrationSteps){for(var b=0;b<a.trajectoryStepCount;b++)this.trajectorySteps.add(this.trajectoryStepCount++,
a.trajectorySteps.get(b));this.setAtomSetCollectionAuxiliaryInfo("trajectorySteps",this.trajectorySteps)}},"J.adapter.smarter.AtomSetCollection");Clazz.defineStatics(c$,"globalBooleans",["someModelsHaveFractionalCoordinates","someModelsHaveSymmetry","someModelsHaveUnitcells","someModelsHaveCONECT","isPDB"],"GLOBAL_FRACTCOORD",0,"GLOBAL_SYMMETRY",1,"GLOBAL_UNITCELLS",2,"GLOBAL_CONECT",3,"GLOBAL_ISPDB",4,"notionalUnitcellTags","a b c alpha beta gamma".split(" "))}),Clazz.declarePackage("J.api"),c$=
Clazz.declareType(J.api,"JmolAdapterBondIterator"),Clazz.declarePackage("J.adapter.smarter"),Clazz.load(["J.api.JmolAdapterBondIterator"],"J.adapter.smarter.BondIterator",null,function(){c$=Clazz.decorateAsClass(function(){this.bonds=this.bsAtoms=null;this.ibond=0;this.bond=null;this.bondCount=0;Clazz.instantialize(this,arguments)},J.adapter.smarter,"BondIterator",J.api.JmolAdapterBondIterator);Clazz.makeConstructor(c$,function(a){Clazz.superConstructor(this,J.adapter.smarter.BondIterator,[]);this.bsAtoms=
a.bsAtoms;this.bonds=a.getBonds();this.bondCount=a.getBondCount();this.ibond=0},"J.adapter.smarter.AtomSetCollection");Clazz.overrideMethod(c$,"hasNext",function(){if(this.ibond==this.bondCount)return!1;for(;null==(this.bond=this.bonds[this.ibond++])||null!=this.bsAtoms&&(!this.bsAtoms.get(this.bond.atomIndex1)||!this.bsAtoms.get(this.bond.atomIndex2));)if(this.ibond==this.bondCount)return!1;return!0});Clazz.overrideMethod(c$,"getAtomUniqueID1",function(){return Integer.$valueOf(this.bond.atomIndex1)});
Clazz.overrideMethod(c$,"getAtomUniqueID2",function(){return Integer.$valueOf(this.bond.atomIndex2)});Clazz.overrideMethod(c$,"getEncodedOrder",function(){return this.bond.order});Clazz.overrideMethod(c$,"getRadius",function(){return this.bond.radius});Clazz.overrideMethod(c$,"getColix",function(){return this.bond.colix})}),Clazz.declarePackage("J.adapter.smarter"),Clazz.load(null,"J.adapter.smarter.Resolver","java.lang.Character $.Float java.util.StringTokenizer JU.ParserJS J.adapter.smarter.AtomSetCollectionReader $.SmarterJmolAdapter J.io.LimitedLineReader J.util.Logger".split(" "),
function(){c$=Clazz.declareType(J.adapter.smarter,"Resolver");c$.getReaderClassBase=$_M(c$,"getReaderClassBase",function(a){var b=a+"Reader";if(a.startsWith("Xml"))return"J.adapter.readers.xml."+b;a=";"+a+";";for(var c=1;c<J.adapter.smarter.Resolver.readerSets.length;c+=2)if(0<=J.adapter.smarter.Resolver.readerSets[c].indexOf(a))return"J.adapter.readers."+J.adapter.smarter.Resolver.readerSets[c-1]+b;return"J.adapter.readers.???."+b},"~S");c$.getFileType=$_M(c$,"getFileType",function(a){try{return J.adapter.smarter.Resolver.determineAtomSetCollectionReader(a,
!1)}catch(b){if(Clazz.exceptionOf(b,Exception))return null;throw b;}},"java.io.BufferedReader");c$.getAtomCollectionReader=$_M(c$,"getAtomCollectionReader",function(a,b,c,d,e){var f=null,g;a=a.$replace("\\","/");var h=null;null!=b?(g=J.adapter.smarter.Resolver.getReaderFromType(b),null==g?h="unrecognized file format type "+b:J.util.Logger.info("The Resolver assumes "+g)):(g=J.adapter.smarter.Resolver.determineAtomSetCollectionReader(c,!0),"\n"==g.charAt(0)&&(b=d.get("defaultType"),null!=b&&(b=J.adapter.smarter.Resolver.getReaderFromType(b),
null!=b&&(g=b))),"\n"==g.charAt(0)?h="unrecognized file format for file "+a+"\n"+g:g.equals("spt")?h="NOTE: file recognized as a script file: "+a+"\n":a.equals("ligand")||J.util.Logger.info("The Resolver thinks "+g));if(null!=h)return J.adapter.smarter.SmarterJmolAdapter.close(c),h;d.put("ptFile",Integer.$valueOf(e));0>=e&&d.put("readerName",g);0==g.indexOf("Xml")&&(g="Xml");a=null;var k;b=null;try{try{a=J.adapter.smarter.Resolver.getReaderClassBase(g),k=Class.forName(a),f=k.newInstance()}catch(l){if(Clazz.exceptionOf(l,
Exception))return b="File reader was not found:"+a,J.util.Logger.error(b),b;throw l;}return f}catch(m){if(Clazz.exceptionOf(m,Exception))return b="uncaught error in file loading for "+a,J.util.Logger.error(b),System.out.println(m.getMessage()),b;throw m;}},"~S,~S,~O,java.util.Map,~N");c$.DOMResolve=$_M(c$,"DOMResolve",function(a,b){var c=null,d,e,f=J.adapter.smarter.Resolver.getXmlType(b.get("nameSpaceInfo"));J.util.Logger.debugging&&J.util.Logger.debug("The Resolver thinks "+f);b.put("readerName",
f);try{return c="J.adapter.readers.xml.XmlReader",d=Class.forName(c),e=d.newInstance()}catch(g){if(Clazz.exceptionOf(g,Exception))return c="File reader was not found:"+c,J.util.Logger.errorEx(c,g),c;throw g;}},"~O,java.util.Map");c$.determineAtomSetCollectionReader=$_M(c$,"determineAtomSetCollectionReader",($fz=function(a,b){if(Clazz.instanceOf(a,J.api.JmolDocument))return"PyMOL";for(var c=new J.io.LimitedLineReader(a,16384),d=c.getHeader(64).trim(),e=0;e<J.adapter.smarter.Resolver.fileStartsWithRecords.length;++e)for(var f=
J.adapter.smarter.Resolver.fileStartsWithRecords[e],g=1;g<f.length;++g)if(d.startsWith(f[g]))return f[0];if(1==d.indexOf("PNG")&&0<=d.indexOf("PNGJ"))return"pngj";if(1==d.indexOf("PNG")||1==d.indexOf("JPG")||6==d.indexOf("JFIF"))return"spt";if(d.startsWith("##TITLE"))return"Jcampdx";d=Array(16);for(e=f=0;e<d.length;++e)d[e]=c.readLineWithNewline(),0<d[e].length&&f++;return null!=(e=J.adapter.smarter.Resolver.checkSpecial(f,d,!1))?e:null!=(e=J.adapter.smarter.Resolver.checkLineStarts(d))?(e.equals("Cif")&&
c.getHeader(0).contains("mmcif_pdbx.dic")&&(e="MMCIF_PDBX"),e):null!=(e=J.adapter.smarter.Resolver.checkHeaderContains(c.getHeader(0)))||null!=(e=J.adapter.smarter.Resolver.checkSpecial(f,d,!0))?e:b?"\n"+d[0]+"\n"+d[1]+"\n"+d[2]+"\n":null},$fz.isPrivate=!0,$fz),"~O,~B");c$.checkHeaderContains=$_M(c$,"checkHeaderContains",($fz=function(a){for(var b=0;b<J.adapter.smarter.Resolver.headerContainsRecords.length;++b)for(var c=J.adapter.smarter.Resolver.headerContainsRecords[b],d=1;d<c.length;++d)if(!(0>
a.indexOf(c[d])))return b=c[0],!b.equals("Xml")?b:0>a.indexOf("<!DOCTYPE HTML PUBLIC")&&0>a.indexOf("XHTML")&&(0>a.indexOf("xhtml")||0<=a.indexOf("<cml"))?J.adapter.smarter.Resolver.getXmlType(a):null;return null},$fz.isPrivate=!0,$fz),"~S");c$.checkLineStarts=$_M(c$,"checkLineStarts",($fz=function(a){for(var b=0;b<J.adapter.smarter.Resolver.lineStartsWithRecords.length;++b)for(var c=J.adapter.smarter.Resolver.lineStartsWithRecords[b],d=1;d<c.length;++d)for(var e=c[d],f=0;f<a.length;++f)if(a[f].startsWith(e))return c[0];
return null},$fz.isPrivate=!0,$fz),"~A");c$.getXmlType=$_M(c$,"getXmlType",($fz=function(a){return 0<=a.indexOf("http://www.molpro.net/")?J.adapter.smarter.Resolver.specialTags[19][0]:0<=a.indexOf("odyssey")?J.adapter.smarter.Resolver.specialTags[20][0]:0<=a.indexOf("C3XML")?J.adapter.smarter.Resolver.specialTags[18][0]:0<=a.indexOf("arguslab")?J.adapter.smarter.Resolver.specialTags[16][0]:0<=a.indexOf("jvxl")||0<=a.indexOf("http://www.xml-cml.org/schema")||0<=a.indexOf("cml:")?J.adapter.smarter.Resolver.specialTags[17][0]:
0<=a.indexOf("XSD")?J.adapter.smarter.Resolver.specialTags[21][0]:0<=a.indexOf(">vasp")?J.adapter.smarter.Resolver.specialTags[22][0]:0<=a.indexOf("<GEOMETRY_INFO>")?J.adapter.smarter.Resolver.specialTags[23][0]:J.adapter.smarter.Resolver.specialTags[17][0]+"(unidentified)"},$fz.isPrivate=!0,$fz),"~S");c$.getReaderFromType=$_M(c$,"getReaderFromType",($fz=function(a){a=a.toLowerCase();var b=null;return null!=(b=J.adapter.smarter.Resolver.checkType(J.adapter.smarter.Resolver.specialTags,a))||null!=
(b=J.adapter.smarter.Resolver.checkType(J.adapter.smarter.Resolver.fileStartsWithRecords,a))||null!=(b=J.adapter.smarter.Resolver.checkType(J.adapter.smarter.Resolver.lineStartsWithRecords,a))?b:J.adapter.smarter.Resolver.checkType(J.adapter.smarter.Resolver.headerContainsRecords,a)},$fz.isPrivate=!0,$fz),"~S");c$.checkType=$_M(c$,"checkType",($fz=function(a,b){for(var c=0;c<a.length;++c)if(a[c][0].toLowerCase().equals(b))return a[c][0];return null},$fz.isPrivate=!0,$fz),"~A,~S");c$.checkSpecial=
$_M(c$,"checkSpecial",($fz=function(a,b,c){if(c){if(J.adapter.smarter.Resolver.checkGromacs(b))return J.adapter.smarter.Resolver.specialTags[14][0];if(J.adapter.smarter.Resolver.checkCrystal(b))return J.adapter.smarter.Resolver.specialTags[12][0];if(J.adapter.smarter.Resolver.checkCastep(b))return J.adapter.smarter.Resolver.specialTags[10][0];if(J.adapter.smarter.Resolver.checkVaspposcar(b))return J.adapter.smarter.Resolver.specialTags[13][0]}else{if(1==a&&0<b[0].length&&Character.isDigit(b[0].charAt(0)))return J.adapter.smarter.Resolver.specialTags[0][0];
if(J.adapter.smarter.Resolver.checkMopacGraphf(b))return J.adapter.smarter.Resolver.specialTags[1][0];if(J.adapter.smarter.Resolver.checkOdyssey(b))return J.adapter.smarter.Resolver.specialTags[3][0];if(J.adapter.smarter.Resolver.checkMol(b))return J.adapter.smarter.Resolver.specialTags[4][0];if(J.adapter.smarter.Resolver.checkXyz(b))return J.adapter.smarter.Resolver.specialTags[5][0];if(J.adapter.smarter.Resolver.checkAlchemy(b[0]))return J.adapter.smarter.Resolver.specialTags[8][0];if(J.adapter.smarter.Resolver.checkFoldingXyz(b))return J.adapter.smarter.Resolver.specialTags[6][0];
if(J.adapter.smarter.Resolver.checkCube(b))return J.adapter.smarter.Resolver.specialTags[7][0];if(J.adapter.smarter.Resolver.checkWien2k(b))return J.adapter.smarter.Resolver.specialTags[9][0];if(J.adapter.smarter.Resolver.checkAims(b))return J.adapter.smarter.Resolver.specialTags[11][0];if(J.adapter.smarter.Resolver.checkGenNBO(b))return J.adapter.smarter.Resolver.specialTags[15][0]}return null},$fz.isPrivate=!0,$fz),"~N,~A,~B");c$.checkAims=$_M(c$,"checkAims",($fz=function(a){for(var b=0;b<a.length&&
!a[b].startsWith("mol 1");b++){var c=JU.ParserJS.getTokens(a[b]);if(0!=c.length&&(c[0].startsWith("atom")&&5<=c.length||c[0].startsWith("multipole")&&6<=c.length||c[0].startsWith("lattice_vector")&&4<=c.length))return!0}return!1},$fz.isPrivate=!0,$fz),"~A");c$.checkAlchemy=$_M(c$,"checkAlchemy",($fz=function(a){var b;if(0<=(b=a.indexOf("ATOMS"))&&a.indexOf("BONDS")>b)try{return 0<Integer.parseInt(a.substring(0,b).trim())}catch(c){if(!Clazz.exceptionOf(c,NumberFormatException))throw c;}return!1},$fz.isPrivate=
!0,$fz),"~S");c$.checkCastep=$_M(c$,"checkCastep",($fz=function(a){for(var b=0;b<a.length;b++)if(1==a[b].indexOf("Frequencies in         cm-1")||a[b].contains("CASTEP")||a[b].toUpperCase().startsWith("%BLOCK LATTICE_ABC")||a[b].toUpperCase().startsWith("%BLOCK LATTICE_CART")||a[b].toUpperCase().startsWith("%BLOCK POSITIONS_FRAC")||a[b].toUpperCase().startsWith("%BLOCK POSITIONS_ABS")||a[b].contains("<-- E"))return!0;return!1},$fz.isPrivate=!0,$fz),"~A");c$.checkVaspposcar=$_M(c$,"checkVaspposcar",
($fz=function(a){var b=a[8].trim().toLowerCase();if(b.contains("direct")||b.contains("cartesian")||b.contains("selective"))return!0;a=a[7].trim().toLowerCase();return a.contains("direct")||a.contains("cartesian")?!0:!1},$fz.isPrivate=!0,$fz),"~A");c$.checkCrystal=$_M(c$,"checkCrystal",($fz=function(a){var b=a[1].trim();if(b.equals("SLAB")||b.equals("MOLECULE")||b.equals("CRYSTAL")||b.equals("POLYMER")||(b=a[3]).equals("SLAB")||b.equals("MOLECULE")||b.equals("POLYMER"))return!0;for(b=0;b<a.length;b++)if(a[b].trim().equals("OPTGEOM"))return!0;
return!1},$fz.isPrivate=!0,$fz),"~A");c$.checkCube=$_M(c$,"checkCube",($fz=function(a){try{for(var b=2;5>=b;b++){var c=new java.util.StringTokenizer(a[b]),d=c.countTokens();if(!(4==d||2==b&&5==d))return!1;Integer.parseInt(c.nextToken());for(var e=3;0<=--e;)JU.ParserJS.fVal(c.nextToken());5==d&&Integer.parseInt(c.nextToken())}return!0}catch(f){if(!Clazz.exceptionOf(f,NumberFormatException))throw f;}return!1},$fz.isPrivate=!0,$fz),"~A");c$.checkFoldingXyz=$_M(c$,"checkFoldingXyz",($fz=function(a){var b=
new java.util.StringTokenizer(a[0].trim()," \t");if(2>b.countTokens())return!1;try{Integer.parseInt(b.nextToken().trim())}catch(c){if(Clazz.exceptionOf(c,NumberFormatException))return!1;throw c;}b=a[1].trim();0==b.length&&(b=a[2].trim());b=new java.util.StringTokenizer(b," \t");if(0==b.countTokens())return!1;try{Integer.parseInt(b.nextToken().trim())}catch(d){if(Clazz.exceptionOf(d,NumberFormatException))return!1;throw d;}return!0},$fz.isPrivate=!0,$fz),"~A");c$.checkGenNBO=$_M(c$,"checkGenNBO",($fz=
function(a){return a[1].startsWith(" Basis set information needed for plotting orbitals")||0<=a[1].indexOf("s in the AO basis:")||0<=a[2].indexOf(" N A T U R A L   A T O M I C   O R B I T A L")},$fz.isPrivate=!0,$fz),"~A");c$.checkGromacs=$_M(c$,"checkGromacs",($fz=function(a){if(-2147483648==JU.ParserJS.parseInt(a[1]))return!1;for(var b=-1,c=2;16>c&&0!=b;c++)if(69!=(b=a[c].length)&&45!=b&&0!=b)return!1;return!0},$fz.isPrivate=!0,$fz),"~A");c$.checkMol=$_M(c$,"checkMol",($fz=function(a){var b=("X"+
a[3]).trim().toUpperCase();if(7>b.length||0<=b.indexOf("."))return!1;if(b.endsWith("V2000")||b.endsWith("V3000"))return!0;try{var c=Integer.parseInt(a[3].substring(0,3).trim()),d=Integer.parseInt(a[3].substring(3,6).trim());return 0<c&&0<=d&&0!=a[0].indexOf("@<TRIPOS>")&&0!=a[1].indexOf("@<TRIPOS>")&&0!=a[2].indexOf("@<TRIPOS>")}catch(e){if(!Clazz.exceptionOf(e,NumberFormatException))throw e;}return!1},$fz.isPrivate=!0,$fz),"~A");c$.checkMopacGraphf=$_M(c$,"checkMopacGraphf",($fz=function(a){return 2<
a[0].indexOf("MOPAC-Graphical data")},$fz.isPrivate=!0,$fz),"~A");c$.checkOdyssey=$_M(c$,"checkOdyssey",($fz=function(a){var b;for(b=0;b<a.length&&(a[b].startsWith("C ")||0==a[b].length);b++);if(b>=a.length||" "!=a[b].charAt(0)||(b+=2)+1>=a.length)return!1;try{var c=Integer.parseInt(a[b].substring(2).trim()),d=Integer.parseInt(a[b].substring(0,2).trim()),e=Integer.parseInt(a[++b].substring(0,2).trim());if(0>c||5<c||0>=e||5<d)return!1;var f=J.adapter.smarter.AtomSetCollectionReader.getTokensFloat(a[b],
null,5);return!Float.isNaN(f[1])&&!Float.isNaN(f[2])&&!Float.isNaN(f[3])&&Float.isNaN(f[4])}catch(g){if(!Clazz.exceptionOf(g,Exception))throw g;}return!1},$fz.isPrivate=!0,$fz),"~A");c$.checkWien2k=$_M(c$,"checkWien2k",($fz=function(a){return a[2].startsWith("MODE OF CALC=")||a[2].startsWith("             RELA")||a[2].startsWith("             NREL")},$fz.isPrivate=!0,$fz),"~A");c$.checkXyz=$_M(c$,"checkXyz",($fz=function(a){try{return Integer.parseInt(a[0].trim()),!0}catch(b){if(!Clazz.exceptionOf(b,
NumberFormatException))throw b;}return!1},$fz.isPrivate=!0,$fz),"~A");Clazz.defineStatics(c$,"classBase","J.adapter.readers.");c$.readerSets=c$.prototype.readerSets="cif. ;Cif;MMCIF_PDBX; molxyz. ;Mol3D;Mol;Xyz; more. ;BinaryDcd;Gromacs;Jcampdx;MdCrd;MdTop;Mol2;Pqr;P2n;TlsDataOnly; quantum. ;Adf;Csf;Dgrid;GamessUK;GamessUS;Gaussian;GausianWfn;Jaguar;Molden;MopacGraphf;GenNBO;NWChem;Odyssey;Psi;Qchem;Spartan;SpartanSmol;WebMO; pdb. ;Pdb; pymol. ;PyMOL; simple. ;Alchemy;Ampac;Cube;FoldingXyz;GhemicalMM;HyperChem;Jme;Mopac;MopacArchive;ZMatrix; xtal. ;Abinit;Aims;Castep;Crystal;Dmol;Espresso;Gulp;Jana;Magres;Shelx;Siesta;VaspOutcar;VaspPoscar;Wien2k;Xcrysden;".split(" ");
Clazz.defineStatics(c$,"CML_NAMESPACE_URI","http://www.xml-cml.org/schema","SPECIAL_JME",0,"SPECIAL_MOPACGRAPHF",1,"SPECIAL_ODYSSEY",3,"SPECIAL_MOL",4,"SPECIAL_XYZ",5,"SPECIAL_FOLDINGXYZ",6,"SPECIAL_CUBE",7,"SPECIAL_ALCHEMY",8,"SPECIAL_WIEN",9,"SPECIAL_CASTEP",10,"SPECIAL_AIMS",11,"SPECIAL_CRYSTAL",12,"SPECIAL_VASPPOSCAR",13,"SPECIAL_GROMACS",14,"SPECIAL_GENNBO",15,"SPECIAL_ARGUS_XML",16,"SPECIAL_CML_XML",17,"SPECIAL_CHEM3D_XML",18,"SPECIAL_MOLPRO_XML",19,"SPECIAL_ODYSSEY_XML",20,"SPECIAL_XSD_XML",
21,"SPECIAL_VASP_XML",22,"SPECIAL_QE_XML",23,"SPECIAL_ARGUS_DOM",24,"SPECIAL_CML_DOM",25,"SPECIAL_CHEM3D_DOM",26,"SPECIAL_MOLPRO_DOM",27,"SPECIAL_ODYSSEY_DOM",28,"SPECIAL_XSD_DOM",29,"SPECIAL_VASP_DOM",30,"specialTags",[["Jme"],["MopacGraphf"],["Mol3D"],["Odyssey"],["Mol"],["Xyz"],["FoldingXyz"],["Cube"],["Alchemy"],["Wien2k"],["Castep"],["Aims"],["Crystal"],["VaspPoscar"],["Gromacs"],["GenNBO"],["XmlArgus"],["XmlCml"],["XmlChem3d"],["XmlMolpro"],["XmlOdyssey"],["XmlXsd"],["XmlVasp"],["XmlQE"],["XmlArgus(DOM)"],
["XmlCml(DOM)"],["XmlChem3d(DOM)"],["XmlMolpro(DOM)"],["XmlOdyssey(DOM)"],["XmlXsd(DOM)"],["XmlVasp(DOM)"],["MdCrd"]],"LEADER_CHAR_MAX",64,"sptContainsRecords",["spt","# Jmol state","# Jmol script","JmolManifest"],"cubeFileStartRecords",["Cube","JVXL","#JVXL"],"mol2Records",["Mol2","mol2","@<TRIPOS>"],"webmoFileStartRecords",["WebMO","[HEADER]"],"moldenFileStartRecords",["Molden","[Molden"],"dcdFileStartRecords",["BinaryDcd","T\x00\x00\x00CORD","\x00\x00\x00TCORD"],"tlsDataOnlyFileStartRecords",["TlsDataOnly",
"REFMAC\n\nTL","REFMAC\r\n\r\n","REFMAC\r\rTL"],"zMatrixFileStartRecords",["ZMatrix","#ZMATRIX"],"magresFileStartRecords",["Magres","#$magres","# magres"],"pymolStartRecords",["PyMOL","}q"],"janaStartRecords",["Jana","Version Jana"]);c$.fileStartsWithRecords=c$.prototype.fileStartsWithRecords=[J.adapter.smarter.Resolver.sptContainsRecords,J.adapter.smarter.Resolver.cubeFileStartRecords,J.adapter.smarter.Resolver.mol2Records,J.adapter.smarter.Resolver.webmoFileStartRecords,J.adapter.smarter.Resolver.moldenFileStartRecords,
J.adapter.smarter.Resolver.dcdFileStartRecords,J.adapter.smarter.Resolver.tlsDataOnlyFileStartRecords,J.adapter.smarter.Resolver.zMatrixFileStartRecords,J.adapter.smarter.Resolver.magresFileStartRecords,J.adapter.smarter.Resolver.pymolStartRecords,J.adapter.smarter.Resolver.janaStartRecords];Clazz.defineStatics(c$,"pqrLineStartRecords",["Pqr","REMARK   1 PQR"],"p2nLineStartRecords",["P2n","REMARK   1 P2N"],"pdbLineStartRecords","Pdb;HEADER;OBSLTE;TITLE ;CAVEAT;COMPND;SOURCE;KEYWDS;EXPDTA;AUTHOR;REVDAT;SPRSDE;JRNL  ;REMARK ;DBREF ;SEQADV;SEQRES;MODRES;HELIX ;SHEET ;TURN  ;CRYST1;ORIGX1;ORIGX2;ORIGX3;SCALE1;SCALE2;SCALE3;ATOM  ;HETATM;MODEL ;LINK  ".split(";"),
"shelxLineStartRecords","Shelx;TITL ;ZERR ;LATT ;SYMM ;CELL ".split(";"),"cifLineStartRecords",["Cif","data_","_publ"],"ghemicalMMLineStartRecords",["GhemicalMM","!Header mm1gp","!Header gpr"],"jaguarLineStartRecords",["Jaguar","  |  Jaguar version"],"mdlLineStartRecords",["Mol","$MDL "],"spartanSmolLineStartRecords",["SpartanSmol","INPUT="],"csfLineStartRecords",["Csf","local_transform"],"mdTopLineStartRecords",["MdTop","%FLAG TITLE"],"hyperChemLineStartRecords",["HyperChem","mol 1"],"vaspOutcarLineStartRecords",
["VaspOutcar"," vasp."," INCAR:"]);c$.lineStartsWithRecords=c$.prototype.lineStartsWithRecords=[J.adapter.smarter.Resolver.cifLineStartRecords,J.adapter.smarter.Resolver.pqrLineStartRecords,J.adapter.smarter.Resolver.p2nLineStartRecords,J.adapter.smarter.Resolver.pdbLineStartRecords,J.adapter.smarter.Resolver.shelxLineStartRecords,J.adapter.smarter.Resolver.ghemicalMMLineStartRecords,J.adapter.smarter.Resolver.jaguarLineStartRecords,J.adapter.smarter.Resolver.mdlLineStartRecords,J.adapter.smarter.Resolver.spartanSmolLineStartRecords,
J.adapter.smarter.Resolver.csfLineStartRecords,J.adapter.smarter.Resolver.mol2Records,J.adapter.smarter.Resolver.mdTopLineStartRecords,J.adapter.smarter.Resolver.hyperChemLineStartRecords,J.adapter.smarter.Resolver.vaspOutcarLineStartRecords];Clazz.defineStatics(c$,"xmlContainsRecords",'Xml <?xml <atom <molecule <reaction <cml <bond .dtd" <list> <entry <identifier http://www.xml-cml.org/schema/cml2/core'.split(" "),"gaussianContainsRecords",["Gaussian","Entering Gaussian System","Entering Link 1",
"1998 Gaussian, Inc."],"ampacContainsRecords",["Ampac","AMPAC Version"],"mopacContainsRecords","Mopac;MOPAC 93 (c) Fujitsu;MOPAC FOR LINUX (PUBLIC DOMAIN VERSION);MOPAC:  VERSION  6;MOPAC   7;MOPAC2;MOPAC (PUBLIC".split(";"),"qchemContainsRecords",["Qchem","Welcome to Q-Chem","A Quantum Leap Into The Future Of Chemistry"],"gamessUKContainsRecords",["GamessUK","GAMESS-UK","G A M E S S - U K"],"gamessUSContainsRecords",["GamessUS","GAMESS"],"spartanBinaryContainsRecords",["SpartanSmol","|PropertyArchive",
"_spartan","spardir","BEGIN Directory Entry Molecule"],"spartanContainsRecords",["Spartan","Spartan"],"adfContainsRecords",["Adf","Amsterdam Density Functional"],"dgridContainsRecords",["Dgrid","BASISFILE   created by DGrid"],"dmolContainsRecords",["Dmol","DMol^3"],"gulpContainsRecords",["Gulp","GENERAL UTILITY LATTICE PROGRAM"],"psiContainsRecords",["Psi","    PSI  3","PSI3:"],"nwchemContainsRecords",["NWChem"," argument  1 = "],"uicrcifContainsRecords",["Cif","Crystallographic Information File"],
"crystalContainsRecords",["Crystal","*                                CRYSTAL"],"espressoContainsRecords",["Espresso","Program PWSCF","Program PHONON"],"siestaContainsRecords",["Siesta","MD.TypeOfRun","SolutionMethod","MeshCutoff","WELCOME TO SIESTA"],"xcrysDenContainsRecords",["Xcrysden","PRIMVEC","CONVVEC","PRIMCOORD"],"mopacArchiveContainsRecords",["MopacArchive","SUMMARY OF PM"],"abinitContainsRecords",["Abinit","http://www.abinit.org","Catholique","Louvain"]);c$.headerContainsRecords=c$.prototype.headerContainsRecords=
[J.adapter.smarter.Resolver.sptContainsRecords,J.adapter.smarter.Resolver.xmlContainsRecords,J.adapter.smarter.Resolver.gaussianContainsRecords,J.adapter.smarter.Resolver.ampacContainsRecords,J.adapter.smarter.Resolver.mopacContainsRecords,J.adapter.smarter.Resolver.qchemContainsRecords,J.adapter.smarter.Resolver.gamessUKContainsRecords,J.adapter.smarter.Resolver.gamessUSContainsRecords,J.adapter.smarter.Resolver.spartanBinaryContainsRecords,J.adapter.smarter.Resolver.spartanContainsRecords,J.adapter.smarter.Resolver.mol2Records,
J.adapter.smarter.Resolver.adfContainsRecords,J.adapter.smarter.Resolver.psiContainsRecords,J.adapter.smarter.Resolver.nwchemContainsRecords,J.adapter.smarter.Resolver.uicrcifContainsRecords,J.adapter.smarter.Resolver.dgridContainsRecords,J.adapter.smarter.Resolver.crystalContainsRecords,J.adapter.smarter.Resolver.dmolContainsRecords,J.adapter.smarter.Resolver.gulpContainsRecords,J.adapter.smarter.Resolver.espressoContainsRecords,J.adapter.smarter.Resolver.siestaContainsRecords,J.adapter.smarter.Resolver.xcrysDenContainsRecords,
J.adapter.smarter.Resolver.mopacArchiveContainsRecords,J.adapter.smarter.Resolver.abinitContainsRecords]}),Clazz.declarePackage("J.api"),c$=Clazz.declareType(J.api,"JmolAdapterStructureIterator"),Clazz.declarePackage("J.adapter.smarter"),Clazz.load(["J.api.JmolAdapterStructureIterator"],"J.adapter.smarter.StructureIterator",["J.api.JmolAdapter"],function(){c$=Clazz.decorateAsClass(function(){this.structureCount=0;this.structure=this.structures=null;this.istructure=0;this.bsModelsDefined=null;Clazz.instantialize(this,
arguments)},J.adapter.smarter,"StructureIterator",J.api.JmolAdapterStructureIterator);Clazz.makeConstructor(c$,function(a){Clazz.superConstructor(this,J.adapter.smarter.StructureIterator,[]);this.structureCount=a.getStructureCount();this.structures=a.getStructures();this.istructure=0;this.bsModelsDefined=a.bsStructuredModels},"J.adapter.smarter.AtomSetCollection");Clazz.overrideMethod(c$,"hasNext",function(){if(this.istructure==this.structureCount)return!1;this.structure=this.structures[this.istructure++];
return!0});Clazz.overrideMethod(c$,"getStructureType",function(){return this.structure.structureType});Clazz.overrideMethod(c$,"getSubstructureType",function(){return this.structure.substructureType});Clazz.overrideMethod(c$,"getStructureID",function(){return this.structure.structureID});Clazz.overrideMethod(c$,"getSerialID",function(){return this.structure.serialID});Clazz.overrideMethod(c$,"getStartChainID",function(){return this.structure.startChainID});Clazz.overrideMethod(c$,"getStartSequenceNumber",
function(){return this.structure.startSequenceNumber});Clazz.overrideMethod(c$,"getStartInsertionCode",function(){return J.api.JmolAdapter.canonizeInsertionCode(this.structure.startInsertionCode)});Clazz.overrideMethod(c$,"getEndChainID",function(){return this.structure.endChainID});Clazz.overrideMethod(c$,"getEndSequenceNumber",function(){return this.structure.endSequenceNumber});Clazz.overrideMethod(c$,"getEndInsertionCode",function(){return this.structure.endInsertionCode});Clazz.overrideMethod(c$,
"getStrandCount",function(){return this.structure.strandCount});Clazz.overrideMethod(c$,"getStructuredModels",function(){return this.bsModelsDefined});Clazz.overrideMethod(c$,"getAtomIndices",function(){return this.structure.atomStartEnd});Clazz.overrideMethod(c$,"getModelIndices",function(){return this.structure.modelStartEnd})}),Clazz.declarePackage("J.modelset"),Clazz.load(["java.lang.Short","java.util.Hashtable","J.viewer.JC"],"J.modelset.Group","java.lang.Float JU.ArrayUtil $.BS $.P3 $.V3 J.constant.EnumStructure J.util.BSUtil $.Logger $.Quaternion".split(" "),
function(){c$=Clazz.decorateAsClass(function(){this.groupIndex=0;this.chain=null;this.leadAtomIndex=this.firstAtomIndex=-1;this.groupID=this.seqcode=this.lastAtomIndex=0;this.$isProtein=!1;this.shapeVisibilityFlags=this.selectedIndex=0;this.theta=this.mu=this.straightness=this.omega=this.psi=this.phi=NaN;this.bsAdded=null;Clazz.instantialize(this,arguments)},J.modelset,"Group");$_M(c$,"getGroupIndex",function(){return this.groupIndex});$_M(c$,"setGroupIndex",function(a){this.groupIndex=a},"~N");Clazz.makeConstructor(c$,
function(){});$_M(c$,"setGroup",function(a,c,d,e,f){this.chain=a;this.seqcode=d;null==c&&(c="");this.groupID=J.modelset.Group.getGroupIdFor(c);this.$isProtein=1<=this.groupID&&24>this.groupID;this.firstAtomIndex=e;this.lastAtomIndex=f;return this},"J.modelset.Chain,~S,~N,~N,~N");$_M(c$,"calcBioParameters",function(){return!1});$_M(c$,"haveParameters",function(){return!0});$_M(c$,"setGroupParameter",function(a,c){switch(a){case 1112539145:this.phi=c;break;case 1112539146:this.psi=c;break;case 1112539144:this.omega=
c;break;case 1112539141:this.mu=c;break;case 1112539152:this.theta=c;break;case 1112539150:this.straightness=c}},"~N,~N");$_M(c$,"getGroupParameter",function(a){this.haveParameters()||this.calcBioParameters();switch(a){case 1112539144:return this.omega;case 1112539145:return this.phi;case 1112539146:return this.psi;case 1112539141:return this.mu;case 1112539152:return this.theta;case 1112539150:return this.straightness}return NaN},"~N");$_M(c$,"setModelSet",function(a){this.chain.model.modelSet=a},
"J.modelset.ModelSet");$_M(c$,"setShapeVisibility",function(a,c){this.shapeVisibilityFlags=c?this.shapeVisibilityFlags|a:this.shapeVisibilityFlags&~a},"~N,~B");$_M(c$,"getGroup3",function(){return J.modelset.Group.group3Names[this.groupID]});c$.getGroup3For=$_M(c$,"getGroup3For",function(a){return J.modelset.Group.group3Names[a]},"~N");$_M(c$,"getGroup1",function(){return this.groupID>=J.viewer.JC.predefinedGroup1Names.length?"?":J.viewer.JC.predefinedGroup1Names[this.groupID]});$_M(c$,"getGroupID",
function(){return this.groupID});$_M(c$,"getChainID",function(){return this.chain.chainID});$_M(c$,"getBioPolymerLength",function(){return 0});$_M(c$,"getMonomerIndex",function(){return-1});$_M(c$,"getGroups",function(){return null});$_M(c$,"getStructure",function(){return null});$_M(c$,"getStrucNo",function(){return 0});$_M(c$,"getProteinStructureType",function(){return J.constant.EnumStructure.NOT});$_M(c$,"getProteinStructureSubType",function(){return this.getProteinStructureType()});$_M(c$,"setProteinStructureType",
function(){return-1},"J.constant.EnumStructure,~N");$_M(c$,"isProtein",function(){return this.$isProtein});$_M(c$,"isNucleic",function(){return 24<=this.groupID&&42>this.groupID});$_M(c$,"isDna",function(){return!1});$_M(c$,"isRna",function(){return!1});$_M(c$,"isPurine",function(){return!1});$_M(c$,"isPyrimidine",function(){return!1});$_M(c$,"isCarbohydrate",function(){return!1});c$.addGroup3Name=$_M(c$,"addGroup3Name",function(a){J.modelset.Group.group3NameCount==J.modelset.Group.group3Names.length&&
($t$=J.modelset.Group.group3Names=JU.ArrayUtil.doubleLengthS(J.modelset.Group.group3Names),J.modelset.Group.prototype.group3Names=J.modelset.Group.group3Names,$t$);var c=($t$=J.modelset.Group.group3NameCount++,J.modelset.Group.prototype.group3NameCount=J.modelset.Group.group3NameCount,$t$);J.modelset.Group.group3Names[c]=a;J.modelset.Group.htGroup.put(a,Short.$valueOf(c));return c},"~S");c$.getGroupIdFor=$_M(c$,"getGroupIdFor",function(a){if(null==a)return-1;var c=J.modelset.Group.lookupGroupID(a);
return-1!=c?c:J.modelset.Group.addGroup3Name(a)},"~S");c$.lookupGroupID=$_M(c$,"lookupGroupID",function(a){return null!=a&&(a=J.modelset.Group.htGroup.get(a),null!=a)?a.shortValue():-1},"~S");$_M(c$,"getResno",function(){return-2147483648==this.seqcode?0:this.seqcode>>8});c$.getSeqNumberFor=$_M(c$,"getSeqNumberFor",function(a){return J.modelset.Group.haveSequenceNumber(a)?a>>8:2147483647},"~N");c$.haveSequenceNumber=$_M(c$,"haveSequenceNumber",function(a){return 0!=(a&128)},"~N");$_M(c$,"getSeqcodeString",
function(){return J.modelset.Group.getSeqcodeStringFor(this.seqcode)});c$.getSeqcodeFor=$_M(c$,"getSeqcodeFor",function(a,c){if(-2147483648==a)return a;"A"<=c&&"Z">=c||("a"<=c&&"z">=c||"0"<=c&&"9">=c||"?"==c||"*"==c)||(" "!=c&&"\x00"!=c&&J.util.Logger.warn("unrecognized insertionCode:"+c),c="\x00");return(2147483647==a?0:a<<8|128)+c.charCodeAt(0)},"~N,~S");c$.getSeqcodeStringFor=$_M(c$,"getSeqcodeStringFor",function(a){return-2147483648==a?null:0==(a&127)?""+(a>>8):""+(a>>8)+"^"+String.fromCharCode(a&
127)},"~N");$_M(c$,"getInsertionCode",function(){return-2147483648==this.seqcode?"\x00":String.fromCharCode(this.seqcode&127)});c$.getInsertionCodeFor=$_M(c$,"getInsertionCodeFor",function(a){return a&127},"~N");c$.getInsertionCodeChar=$_M(c$,"getInsertionCodeChar",function(a){return-2147483648==a?"\x00":String.fromCharCode(a&127)},"~N");$_M(c$,"isAdded",function(a){return null!=this.bsAdded&&this.bsAdded.get(a)},"~N");$_M(c$,"addAtoms",function(a){null==this.bsAdded&&(this.bsAdded=new JU.BS);this.bsAdded.set(a)},
"~N");$_M(c$,"selectAtoms",function(a){a.setBits(this.firstAtomIndex,this.lastAtomIndex+1);null!=this.bsAdded&&a.or(this.bsAdded);return this.lastAtomIndex},"JU.BS");$_M(c$,"isSelected",function(a){var c=a.nextSetBit(this.firstAtomIndex);return 0<=c&&c<=this.lastAtomIndex||null!=this.bsAdded&&this.bsAdded.intersects(a)},"JU.BS");$_M(c$,"isHetero",function(){return this.chain.getAtom(this.firstAtomIndex).isHetero()});Clazz.overrideMethod(c$,"toString",function(){return"["+this.getGroup3()+"-"+this.getSeqcodeString()+
"]"});$_M(c$,"scaleToScreen",function(a,c){return this.chain.model.modelSet.viewer.scaleToScreen(a,c)},"~N,~N");$_M(c$,"isCursorOnTopOf",function(a,c,d,e,f){return this.chain.model.modelSet.isCursorOnTopOf(a,c,d,e,f)},"J.modelset.Atom,~N,~N,~N,J.modelset.Atom");$_M(c$,"isAtomHidden",function(a){return this.chain.model.modelSet.isAtomHidden(a)},"~N");$_M(c$,"getModel",function(){return this.chain.model});$_M(c$,"getModelIndex",function(){return this.chain.model.modelIndex});$_M(c$,"getSelectedMonomerCount",
function(){return 0});$_M(c$,"getSelectedMonomerIndex",function(){return-1});$_M(c$,"getSelectedGroupIndex",function(){return this.selectedIndex});$_M(c$,"isLeadAtom",function(){return!1},"~N");$_M(c$,"getLeadAtomOr",function(a){var c=this.getLeadAtom();return null==c?a:c},"J.modelset.Atom");$_M(c$,"getLeadAtom",function(){return null});$_M(c$,"getQuaternion",function(){return null},"~S");$_M(c$,"getQuaternionFrame",function(a){if(3>this.lastAtomIndex-this.firstAtomIndex)return null;var c=this.firstAtomIndex;
return J.util.Quaternion.getQuaternionFrame(a[c],a[++c],a[++c])},"~A");$_M(c$,"setStrucNo",function(){},"~N");$_M(c$,"getHelixData",function(a){switch(a){case 135266320:return new JU.P3;case 1073741854:case 1666189314:return new JU.V3;case 135266305:return Float.$valueOf(NaN);case 135266306:case 1073742001:return[]}return""},"~N,~S,~N");$_M(c$,"isWithinStructure",function(){return!1},"J.constant.EnumStructure");$_M(c$,"getProteinStructureTag",function(){return null});$_M(c$,"getStructureId",function(){return""});
$_M(c$,"getBioPolymerIndexInModel",function(){return-1});$_M(c$,"isCrossLinked",function(){return!1},"J.modelset.Group");$_M(c$,"getCrossLinkLead",function(){return!1},"JU.List");$_M(c$,"isConnectedPrevious",function(){return!1});$_M(c$,"getNitrogenAtom",function(){return null});$_M(c$,"getCarbonylOxygenAtom",function(){return null});$_M(c$,"fixIndices",function(a,c){this.firstAtomIndex-=a;this.leadAtomIndex-=a;this.lastAtomIndex-=a;null!=this.bsAdded&&J.util.BSUtil.deleteBits(this.bsAdded,c)},"~N,JU.BS");
$_M(c$,"getGroupInfo",function(a){var c=new java.util.Hashtable;c.put("groupIndex",Integer.$valueOf(a));c.put("groupID",Short.$valueOf(this.groupID));a=this.getSeqcodeString();null!=a&&c.put("seqCode",a);c.put("_apt1",Integer.$valueOf(this.firstAtomIndex));c.put("_apt2",Integer.$valueOf(this.lastAtomIndex));null!=this.bsAdded&&c.put("addedAtoms",this.bsAdded);c.put("atomInfo1",this.chain.model.modelSet.getAtomInfo(this.firstAtomIndex,null));c.put("atomInfo2",this.chain.model.modelSet.getAtomInfo(this.lastAtomIndex,
null));c.put("visibilityFlags",Integer.$valueOf(this.shapeVisibilityFlags));return c},"~N");$_M(c$,"getMinZ",function(a,c){c[0]=2147483647;for(var d=this.firstAtomIndex;d<=this.lastAtomIndex;d++)this.checkMinZ(a[d],c);if(null!=this.bsAdded)for(d=this.bsAdded.nextSetBit(0);0<=d;d=this.bsAdded.nextSetBit(d+1))this.checkMinZ(a[d],c)},"~A,~A");$_M(c$,"checkMinZ",($fz=function(a,c){var d=a.screenZ-Clazz.doubleToInt(a.screenDiameter/2)-2;d<c[0]&&(c[0]=Math.max(1,d))},$fz.isPrivate=!0,$fz),"J.modelset.Atom,~A");
Clazz.defineStatics(c$,"SEQUENCE_NUMBER_FLAG",128,"INSERTION_CODE_MASK",127,"SEQUENCE_NUMBER_SHIFT",8);c$.htGroup=c$.prototype.htGroup=new java.util.Hashtable;c$.group3Names=c$.prototype.group3Names=Array(128);Clazz.defineStatics(c$,"group3NameCount",0);for(var a=0;a<J.viewer.JC.predefinedGroup3Names.length;++a)J.modelset.Group.addGroup3Name(J.viewer.JC.predefinedGroup3Names[a])}),Clazz.declarePackage("J.adapter.smarter"),Clazz.load(["JU.P3"],"J.adapter.smarter.Atom",["java.lang.Float","JU.ArrayUtil",
"$.List","$.V3"],function(){c$=Clazz.decorateAsClass(function(){this.index=this.atomSetIndex=0;this.bsSymmetry=null;this.atomSite=0;this.elementSymbol=null;this.elementNumber=-1;this.atomName=null;this.formalCharge=-2147483648;this.partialCharge=NaN;this.vib=null;this.bfactor=NaN;this.foccupancy=1;this.radius=NaN;this.isHetero=!1;this.atomSerial=-2147483648;this.chainID=0;this.alternateLocationID="\x00";this.group3=null;this.sequenceNumber=-2147483648;this.insertionCode="\x00";this.tensors=this.anisoBorU=
null;this.ignoreSymmetry=!1;Clazz.instantialize(this,arguments)},J.adapter.smarter,"Atom",JU.P3,Cloneable);$_M(c$,"addTensor",function(a,b,c){if(null==a)return null;if(c||null==this.tensors)this.tensors=new JU.List;this.tensors.addLast(a);null!=b&&a.setType(b);return a},"J.util.Tensor,~S,~B");Clazz.overrideConstructor(c$,function(){this.set(NaN,NaN,NaN)});$_M(c$,"getClone",function(){var a=this.clone();null!=this.vib&&(a.vib=JU.V3.newV(a.vib));null!=this.anisoBorU&&(a.anisoBorU=JU.ArrayUtil.arrayCopyF(this.anisoBorU,
-1));if(null!=this.tensors){a.tensors=new JU.List;for(var b=this.tensors.size();0<=--b;)a.tensors.addLast(this.tensors.get(b).copyTensor())}return a});$_M(c$,"getElementSymbol",function(){if(null==this.elementSymbol&&null!=this.atomName){for(var a=this.atomName.length,b=0,c=String.fromCharCode(0);b<a&&!J.adapter.smarter.Atom.isValidFirstSymbolChar(c=this.atomName.charAt(b));)++b;switch(a-b){case 0:break;default:if(a=this.atomName.charAt(b+1),J.adapter.smarter.Atom.isValidElementSymbolNoCaseSecondChar2(c,
a)){this.elementSymbol=""+c+a;break}case 1:J.adapter.smarter.Atom.isValidElementSymbol(c)&&(this.elementSymbol=""+c)}}return this.elementSymbol});c$.isValidElementSymbol=$_M(c$,"isValidElementSymbol",function(a){return"A"<=a&&"Z">=a&&0>J.adapter.smarter.Atom.elementCharMasks[a.charCodeAt(0)-65]},"~S");c$.isValidElementSymbol2=$_M(c$,"isValidElementSymbol2",function(a,b){return"A">a||"Z"<a||"a">b||"z"<b?!1:0!=(J.adapter.smarter.Atom.elementCharMasks[a.charCodeAt(0)-65]>>b.charCodeAt(0)-97&1)},"~S,~S");
c$.isValidElementSymbolNoCaseSecondChar2=$_M(c$,"isValidElementSymbolNoCaseSecondChar2",function(a,b){"A"<=b&&"Z">=b&&(b=String.fromCharCode(b.charCodeAt(0)+32));return"A">a||"Z"<a||"a">b||"z"<b?!1:0!=(J.adapter.smarter.Atom.elementCharMasks[a.charCodeAt(0)-65]>>b.charCodeAt(0)-97&1)},"~S,~S");c$.isValidFirstSymbolChar=$_M(c$,"isValidFirstSymbolChar",function(a){return"A"<=a&&"Z">=a&&0!=J.adapter.smarter.Atom.elementCharMasks[a.charCodeAt(0)-65]},"~S");c$.isValidElementSymbolNoCaseSecondChar=$_M(c$,
"isValidElementSymbolNoCaseSecondChar",function(a){if(null==a)return!1;var b=a.length;if(0==b)return!1;var c=a.charAt(0);if(1==b)return J.adapter.smarter.Atom.isValidElementSymbol(c);if(2<b)return!1;a=a.charAt(1);return J.adapter.smarter.Atom.isValidElementSymbolNoCaseSecondChar2(c,a)},"~S");$_M(c$,"scaleVector",function(a){null==this.vib||Float.isNaN(this.vib.z)||this.vib.scale(a)},"~N");Clazz.defineStatics(c$,"elementCharMasks",[1972292,-2147351151,-2146019271,-2130706430,1441792,-2147348464,25,
-2147205008,-2147344384,0,-2147352576,1179905,548936,-2147434213,-2147221504,-2145759221,0,1056947,-2147339946,-2147477097,-2147483648,-2147483648,-2147483648,8388624,-2147483646,139264])}),Clazz.declarePackage("J.adapter.smarter"),c$=Clazz.decorateAsClass(function(){this.atomSetIndex=0;Clazz.instantialize(this,arguments)},J.adapter.smarter,"AtomSetObject"),Clazz.declarePackage("J.adapter.smarter"),Clazz.load(["J.adapter.smarter.AtomSetObject"],"J.adapter.smarter.Bond",null,function(){c$=Clazz.decorateAsClass(function(){this.order=
this.atomIndex2=this.atomIndex1=0;this.uniqueID=this.colix=this.radius=-1;Clazz.instantialize(this,arguments)},J.adapter.smarter,"Bond",J.adapter.smarter.AtomSetObject);Clazz.makeConstructor(c$,function(a,b,c){Clazz.superConstructor(this,J.adapter.smarter.Bond,[]);this.atomIndex1=a;this.atomIndex2=b;this.order=c},"~N,~N,~N")}),Clazz.declarePackage("J.constant"),Clazz.load(["java.lang.Enum"],"J.constant.EnumStructure",null,function(){c$=Clazz.decorateAsClass(function(){this.color=this.id=0;Clazz.instantialize(this,
arguments)},J.constant,"EnumStructure",Enum);Clazz.makeConstructor(c$,($fz=function(a,b){this.id=a;this.color=b},$fz.isPrivate=!0,$fz),"~N,~N");$_M(c$,"getId",function(){return this.id});$_M(c$,"getColor",function(){return this.color});c$.getProteinStructureType=$_M(c$,"getProteinStructureType",function(a){for(var b,c=0,d=J.constant.EnumStructure.values();c<d.length&&((b=d[c])||1);c++)if(a.equalsIgnoreCase(b.name()))return b.isProtein()?b:J.constant.EnumStructure.NOT;return J.constant.EnumStructure.NOT},
"~S");$_M(c$,"getBioStructureTypeName",function(a){return 0>this.id?"":a&&this.isProtein()?"protein":this.name()},"~B");$_M(c$,"isProtein",($fz=function(){return 0<=this.id&&3>=this.id||7<=this.id},$fz.isPrivate=!0,$fz));Clazz.defineEnumConstant(c$,"NOT",0,[-1,4286611584]);Clazz.defineEnumConstant(c$,"NONE",1,[0,4294967295]);Clazz.defineEnumConstant(c$,"TURN",2,[1,4284514559]);Clazz.defineEnumConstant(c$,"SHEET",3,[2,4294952960]);Clazz.defineEnumConstant(c$,"HELIX",4,[3,4294901888]);Clazz.defineEnumConstant(c$,
"DNA",5,[4,4289593598]);Clazz.defineEnumConstant(c$,"RNA",6,[5,4294771042]);Clazz.defineEnumConstant(c$,"CARBOHYDRATE",7,[6,4289111802]);Clazz.defineEnumConstant(c$,"HELIX310",8,[7,4288675968]);Clazz.defineEnumConstant(c$,"HELIXALPHA",9,[8,4294901888]);Clazz.defineEnumConstant(c$,"HELIXPI",10,[9,4284481664])}),$_L(["java.util.Enumeration"],"java.util.StringTokenizer",["java.lang.NullPointerException","java.util.NoSuchElementException"],function(){c$=$_C(function(){this.delimiters=this.string=null;
this.returnDelimiters=!1;this.position=0;$_Z(this,arguments)},java.util,"StringTokenizer",null,java.util.Enumeration);$_K(c$,function(a){this.construct(a," \t\n\r\f",!1)},"~S");$_K(c$,function(a,b){this.construct(a,b,!1)},"~S,~S");$_K(c$,function(a,b,c){if(null!=a)this.string=a,this.delimiters=b,this.returnDelimiters=c,this.position=0;else throw new NullPointerException;},"~S,~S,~B");$_M(c$,"countTokens",function(){for(var a=0,b=!1,c=this.position,d=this.string.length;c<d;c++)0<=this.delimiters.indexOf(this.string.charAt(c),
0)?(this.returnDelimiters&&a++,b&&(a++,b=!1)):b=!0;b&&a++;return a});$_V(c$,"hasMoreElements",function(){return this.hasMoreTokens()});$_M(c$,"hasMoreTokens",function(){var a=this.string.length;if(this.position<a){if(this.returnDelimiters)return!0;for(var b=this.position;b<a;b++)if(-1==this.delimiters.indexOf(this.string.charAt(b),0))return!0}return!1});$_V(c$,"nextElement",function(){return this.nextToken()});$_M(c$,"nextToken",function(){var a=this.position,b=this.string.length;if(a<b){if(this.returnDelimiters){if(0<=
this.delimiters.indexOf(this.string.charAt(this.position),0))return String.valueOf(this.string.charAt(this.position++));for(this.position++;this.position<b;this.position++)if(0<=this.delimiters.indexOf(this.string.charAt(this.position),0))return this.string.substring(a,this.position);return this.string.substring(a)}for(;a<b&&0<=this.delimiters.indexOf(this.string.charAt(a),0);)a++;this.position=a;if(a<b){for(this.position++;this.position<b;this.position++)if(0<=this.delimiters.indexOf(this.string.charAt(this.position),
0))return this.string.substring(a,this.position);return this.string.substring(a)}}throw new java.util.NoSuchElementException;});$_M(c$,"nextToken",function(a){this.delimiters=a;return this.nextToken()},"~S")}),Clazz.declarePackage("J.adapter.smarter"),Clazz.load(["JU.SB"],"J.adapter.smarter.AtomSetCollectionReader","java.lang.Boolean $.Character $.Float JU.BS $.List $.M3 $.P3 $.ParserJS $.V3 J.adapter.smarter.Atom $.AtomSetCollection J.api.Interface $.JmolAdapter J.util.BSUtil $.Logger $.ParserBS $.Quaternion $.Txt".split(" "),
function(){c$=Clazz.decorateAsClass(function(){this.isBinary=!1;this.next=this.prevline=this.line=this.trajectorySteps=this.htParams=this.readerName=this.doc=this.reader=this.atomSetCollection=null;this.ptLine=0;this.latticeCells=null;this.iHaveSymmetryOperators=this.iHaveUnitCell=this.doProcessLines=!1;this.continuing=!0;this.viewer=null;this.isSequential=this.getHeader=this.doCheckUnitCell=this.applySymmetryToBonds=this.isTrajectory=this.ignoreFileSymmetryOperators=this.doApplySymmetry=!1;this.vibrationNumber=
this.modelNumber=this.templateAtomCount=0;this.desiredVibrationNumber=-2147483648;this.bsModels=null;this.havePartialChargeFilter=!1;this.calculationType="?";this.spaceGroup=null;this.ignoreFileSpaceGroupName=this.ignoreFileUnitCell=!1;this.notionalUnitCell=null;this.desiredModelNumber=-2147483648;this.out=this.symmetry=null;this.doPackUnitCell=this.iHaveFractionalCoordinates=!1;this.ptSupercell=this.strSupercell=null;this.forcePacked=this.mustFinalizeModelSet=!1;this.loadNote=null;this.merging=this.fileCoordinatesAreFractional=
this.doConvertToFractional=!1;this.symmetryRange=0;this.firstLastStep=null;this.lastModelNumber=2147483647;this.desiredSpaceGroupIndex=-1;this.unitCellOffset=this.fileOffsetFractional=this.fileOffset=this.fileScaling=null;this.unitCellOffsetFractional=!1;this.fileName=this.filePath=null;this.stateScriptVersionInt=2147483647;this.haveModel=!1;this.previousUnitCell=this.previousSpaceGroup=null;this.nMatrixElements=0;this.filter=this.bsFilter=this.matUnitCellOrientation=null;this.filterAtomType=this.filterAtomName=
this.filterChain=this.filterGroup3=this.filterAltLoc=this.haveAtomFilter=!1;this.filterAtomTypeStr=null;this.filterAtomNameTerminator=";";this.filterEveryNth=this.filterHetero=this.filterElement=!1;this.nFiltered=this.filterN=0;this.reverseModels=this.doReadMolecularOrbitals=this.useAltNames=this.addVibrations=this.doCentralize=this.doSetOrientation=!1;this.nameRequired=null;this.centroidPacked=this.doCentroidUnitCell=!1;this.siteScript=this.previousScript=this.matrixRotate=this.filter2=this.filter1=
null;Clazz.instantialize(this,arguments)},J.adapter.smarter,"AtomSetCollectionReader");Clazz.prepareFields(c$,function(){this.next=Clazz.newIntArray(1,0);this.loadNote=new JU.SB});$_M(c$,"setup",function(a,b,c){this.setupASCR(a,b,c)},"~S,java.util.Map,~O");$_M(c$,"setupASCR",function(a,b,c){null!=a&&(this.htParams=b,this.filePath=a.$replace("\\","/"),a=this.filePath.lastIndexOf("/"),this.fileName=this.filePath.substring(a+1),Clazz.instanceOf(c,java.io.BufferedReader)?this.reader=c:Clazz.instanceOf(c,
J.api.JmolDocument)&&(this.doc=c))},"~S,java.util.Map,~O");$_M(c$,"readData",function(){this.initialize();this.atomSetCollection=new J.adapter.smarter.AtomSetCollection(this.readerName,this,null,null);try{this.initializeReader();if(null==this.doc)for(null==this.line&&this.continuing&&this.readLine();null!=this.line&&this.continuing;)this.checkLine()&&this.readLine();else this.doc.setOutputChannel(this.out),this.processBinaryDocument(this.doc);this.finalizeReader()}catch(a){J.util.Logger.info("Reader error: "+
a),this.viewer.isJS||a.printStackTrace(),this.setError(a)}null!=this.reader&&this.reader.close();null!=this.doc&&this.doc.close();return this.finish()});$_M(c$,"fixBaseIndices",($fz=function(){try{var a=this.htParams.get("baseAtomIndex").intValue(),b=this.htParams.get("baseModelIndex").intValue(),a=a+this.atomSetCollection.getAtomCount(),b=b+this.atomSetCollection.getAtomSetCount();this.htParams.put("baseAtomIndex",Integer.$valueOf(a));this.htParams.put("baseModelIndex",Integer.$valueOf(b))}catch(c){if(!Clazz.exceptionOf(c,
Exception))throw c;}},$fz.isPrivate=!0,$fz));$_M(c$,"readDataObject",function(a){this.initialize();this.atomSetCollection=new J.adapter.smarter.AtomSetCollection(this.readerName,this,null,null);this.initializeReader();this.processDOM(a);return this.finish()},"~O");$_M(c$,"processDOM",function(){},"~O");$_M(c$,"processBinaryDocument",function(){},"J.api.JmolDocument");$_M(c$,"initializeReader",function(){});$_M(c$,"checkLine",function(){return!0});$_M(c$,"checkLastModel",function(){if(this.isLastModel(this.modelNumber)&&
this.doProcessLines)return this.continuing=!1;this.doProcessLines=!1;return!0});$_M(c$,"isLastModel",function(a){return 0<this.desiredModelNumber||a>=this.lastModelNumber},"~N");$_M(c$,"appendLoadNote",function(a){this.loadNote.append(a).append("\n");J.util.Logger.info(a);return a},"~S");$_M(c$,"initializeTrajectoryFile",function(){this.atomSetCollection.addAtom(new J.adapter.smarter.Atom);this.trajectorySteps=this.htParams.get("trajectorySteps");null==this.trajectorySteps&&this.htParams.put("trajectorySteps",
this.trajectorySteps=new JU.List)});$_M(c$,"finalizeReader",function(){this.finalizeReaderASCR()});$_M(c$,"finalizeReaderASCR",function(){this.applySymmetryAndSetTrajectory();this.setLoadNote();this.atomSetCollection.finalizeStructures();this.doCentralize&&this.atomSetCollection.centralize()});$_M(c$,"setLoadNote",function(){0<this.loadNote.length()&&this.atomSetCollection.setAtomSetCollectionAuxiliaryInfo("modelLoadNote",this.loadNote.toString())});$_M(c$,"setIsPDB",function(){this.atomSetCollection.setGlobalBoolean(4);
this.atomSetCollection.setAtomSetAuxiliaryInfo("isPDB",Boolean.TRUE);null!=this.htParams.get("pdbNoHydrogens")&&this.atomSetCollection.setAtomSetCollectionAuxiliaryInfo("pdbNoHydrogens",this.htParams.get("pdbNoHydrogens"))});$_M(c$,"setPdb",function(){});$_M(c$,"finish",($fz=function(){var a=this.htParams.get("loadState");this.atomSetCollection.setAtomSetCollectionAuxiliaryInfo("loadState",null==a?"":a);a=this.htParams.get("smilesString");null!=a&&this.atomSetCollection.setAtomSetCollectionAuxiliaryInfo("smilesString",
a);this.htParams.containsKey("templateAtomCount")||this.htParams.put("templateAtomCount",Integer.$valueOf(this.atomSetCollection.getAtomCount()));this.htParams.containsKey("bsFilter")&&this.htParams.put("filteredAtomCount",Integer.$valueOf(J.util.BSUtil.cardinalityOf(this.htParams.get("bsFilter"))));this.calculationType.equals("?")||this.atomSetCollection.setAtomSetCollectionAuxiliaryInfo("calculationType",this.calculationType);var b=a=this.atomSetCollection.getFileTypeName();0<=b.indexOf("(")&&(b=
b.substring(0,b.indexOf("(")));for(var c=this.atomSetCollection.getAtomSetCount();0<=--c;)this.atomSetCollection.setAtomSetAuxiliaryInfoForSet("fileName",this.filePath,c),this.atomSetCollection.setAtomSetAuxiliaryInfoForSet("fileType",b,c);this.atomSetCollection.freeze(this.reverseModels);if(null!=this.atomSetCollection.errorMessage)return this.atomSetCollection.errorMessage+"\nfor file "+this.filePath+"\ntype "+a;if(0==(null==this.atomSetCollection.bsAtoms?this.atomSetCollection.getAtomCount():this.atomSetCollection.bsAtoms.cardinality())&&
0>b.indexOf("DataOnly")&&null==this.atomSetCollection.getAtomSetCollectionAuxiliaryInfo("dataOnly"))return"No atoms found\nfor file "+this.filePath+"\ntype "+a;this.fixBaseIndices();return this.atomSetCollection},$fz.isPrivate=!0,$fz));$_M(c$,"setError",($fz=function(a){var b;b=a.getMessage?a.getMessage():a.toString();this.atomSetCollection.errorMessage=null==this.line?"Error reading file at end of file \n"+b:"Error reading file at line "+this.ptLine+":\n"+this.line+"\n"+b;this.viewer.isJS||a.printStackTrace()},
$fz.isPrivate=!0,$fz),"Throwable");$_M(c$,"initialize",($fz=function(){var a=this.htParams.get("supercell");Clazz.instanceOf(a,String)?this.strSupercell=a:this.ptSupercell=a;this.initializeSymmetry();this.viewer=this.htParams.remove("viewer");this.htParams.containsKey("stateScriptVersionInt")&&(this.stateScriptVersionInt=this.htParams.get("stateScriptVersionInt").intValue());this.merging=this.htParams.containsKey("merging");this.getHeader=this.htParams.containsKey("getHeader");this.isSequential=this.htParams.containsKey("isSequential");
this.readerName=this.htParams.get("readerName");this.htParams.containsKey("outputChannel")&&(this.out=this.htParams.get("outputChannel"));this.htParams.containsKey("vibrationNumber")?this.desiredVibrationNumber=this.htParams.get("vibrationNumber").intValue():this.htParams.containsKey("modelNumber")&&(this.desiredModelNumber=this.htParams.get("modelNumber").intValue());this.applySymmetryToBonds=this.htParams.containsKey("applySymmetryToBonds");this.bsFilter=this.htParams.get("bsFilter");this.setFilter(null);
a=this.htParams.containsKey("ptFile")?this.htParams.get("ptFile").intValue():-1;this.isTrajectory=this.htParams.containsKey("isTrajectory");0<a&&this.htParams.containsKey("firstLastSteps")?(a=this.htParams.get("firstLastSteps").get(a-1),Clazz.instanceOf(a,JU.BS)?this.bsModels=a:this.firstLastStep=a):this.htParams.containsKey("firstLastStep")?this.firstLastStep=this.htParams.get("firstLastStep"):this.htParams.containsKey("bsModels")&&(this.bsModels=this.htParams.get("bsModels"));this.htParams.containsKey("templateAtomCount")&&
(this.templateAtomCount=this.htParams.get("templateAtomCount").intValue());if(null!=this.bsModels||null!=this.firstLastStep)this.desiredModelNumber=-2147483648;if(null==this.bsModels&&null!=this.firstLastStep){0>this.firstLastStep[0]&&(this.firstLastStep[0]=0);if(0==this.firstLastStep[2]||this.firstLastStep[1]<this.firstLastStep[0])this.firstLastStep[1]=-1;1>this.firstLastStep[2]&&(this.firstLastStep[2]=1);this.bsModels=J.util.BSUtil.newAndSetBit(this.firstLastStep[0]);if(this.firstLastStep[1]>this.firstLastStep[0])for(a=
this.firstLastStep[0];a<=this.firstLastStep[1];a+=this.firstLastStep[2])this.bsModels.set(a)}if(null!=this.bsModels&&(null==this.firstLastStep||-1!=this.firstLastStep[1]))this.lastModelNumber=this.bsModels.length();this.symmetryRange=this.htParams.containsKey("symmetryRange")?this.htParams.get("symmetryRange").floatValue():0;this.initializeSymmetryOptions();this.htParams.containsKey("spaceGroupIndex")&&(this.desiredSpaceGroupIndex=this.htParams.get("spaceGroupIndex").intValue(),-2==this.desiredSpaceGroupIndex&&
(this.spaceGroup=this.htParams.get("spaceGroupName")),this.ignoreFileSpaceGroupName=-2==this.desiredSpaceGroupIndex||0<=this.desiredSpaceGroupIndex,this.ignoreFileSymmetryOperators=-1!=this.desiredSpaceGroupIndex);this.htParams.containsKey("unitCellOffset")&&(this.fileScaling=JU.P3.new3(1,1,1),this.fileOffset=this.htParams.get("unitCellOffset"),this.fileOffsetFractional=JU.P3.newP(this.fileOffset),this.unitCellOffsetFractional=this.htParams.containsKey("unitCellOffsetFractional"));this.htParams.containsKey("unitcell")&&
(a=this.htParams.get("unitcell"),this.merging&&this.setFractionalCoordinates(!0),9==a.length?(this.addPrimitiveLatticeVector(0,a,0),this.addPrimitiveLatticeVector(1,a,3),this.addPrimitiveLatticeVector(2,a,6)):this.setUnitCell(a[0],a[1],a[2],a[3],a[4],a[5]),this.ignoreFileUnitCell=this.iHaveUnitCell,this.merging&&!this.iHaveUnitCell&&this.setFractionalCoordinates(!1))},$fz.isPrivate=!0,$fz));$_M(c$,"initializeSymmetryOptions",function(){this.latticeCells=Clazz.newIntArray(3,0);var a=this.htParams.get("lattice");
this.forcePacked&&null==a&&(a=JU.P3.new3(1,1,1));if(null!=a){this.latticeCells[0]=Clazz.floatToInt(a.x);this.latticeCells[1]=Clazz.floatToInt(a.y);this.latticeCells[2]=Clazz.floatToInt(a.z);if((this.doCentroidUnitCell=this.htParams.containsKey("centroid"))&&(-1==this.latticeCells[2]||0==this.latticeCells[2]))this.latticeCells[2]=1;a=this.forcePacked||this.htParams.containsKey("packed");this.centroidPacked=this.doCentroidUnitCell&&a;this.doPackUnitCell=!this.doCentroidUnitCell&&(a||0>this.latticeCells[2])}this.doApplySymmetry=
0<this.latticeCells[0]&&0<this.latticeCells[1];this.doApplySymmetry||(this.latticeCells[0]=0,this.latticeCells[1]=0,this.latticeCells[2]=0)});$_M(c$,"doGetModel",function(a,b){if(null!=b&&null!=this.nameRequired&&0<this.nameRequired.length&&0>b.toUpperCase().indexOf(this.nameRequired))return!1;var c=null==this.bsModels?1>this.desiredModelNumber||a==this.desiredModelNumber:a>this.lastModelNumber?!1:0<a&&this.bsModels.get(a-1)||this.haveModel&&null!=this.firstLastStep&&0>this.firstLastStep[1]&&(2>this.firstLastStep[2]||
0==(a-1-this.firstLastStep[0])%this.firstLastStep[2]);c&&0==this.desiredModelNumber&&this.atomSetCollection.discardPreviousAtoms();this.haveModel=(new Boolean(this.haveModel|c)).valueOf();c&&(this.doProcessLines=!0);return c},"~N,~S");$_M(c$,"initializeSymmetry",function(){this.previousSpaceGroup=this.spaceGroup;this.previousUnitCell=this.notionalUnitCell;this.iHaveUnitCell=this.ignoreFileUnitCell;if(!this.ignoreFileUnitCell){this.notionalUnitCell=Clazz.newFloatArray(25,0);for(var a=25;0<=--a;)this.notionalUnitCell[a]=
NaN;null!=this.ptSupercell&&(this.notionalUnitCell[22]=Math.max(1,Clazz.floatToInt(this.ptSupercell.x)),this.notionalUnitCell[23]=Math.max(1,Clazz.floatToInt(this.ptSupercell.y)),this.notionalUnitCell[24]=Math.max(1,Clazz.floatToInt(this.ptSupercell.z)));this.symmetry=null}this.ignoreFileSpaceGroupName||(this.spaceGroup="unspecified!");this.doCheckUnitCell=!1});$_M(c$,"newAtomSet",function(a){0<=this.atomSetCollection.getCurrentAtomSetIndex()?(this.atomSetCollection.newAtomSet(),this.atomSetCollection.setCollectionName("<collection of "+
(this.atomSetCollection.getCurrentAtomSetIndex()+1)+" models>")):this.atomSetCollection.setCollectionName(a);this.atomSetCollection.setAtomSetAuxiliaryInfoForSet("name",a,Math.max(0,this.atomSetCollection.getCurrentAtomSetIndex()))},"~S");$_M(c$,"cloneLastAtomSet",function(a,b){var c=this.atomSetCollection.getLastAtomSetAtomCount();this.atomSetCollection.cloneLastAtomSetFromPoints(a,b);this.atomSetCollection.haveUnitCell&&(this.doCheckUnitCell=this.iHaveUnitCell=!0,this.spaceGroup=this.previousSpaceGroup,
this.notionalUnitCell=this.previousUnitCell);return c},"~N,~A");$_M(c$,"setSpaceGroupName",function(a){this.ignoreFileSpaceGroupName||(this.spaceGroup=a.trim(),J.util.Logger.info("Setting space group name to "+this.spaceGroup))},"~S");$_M(c$,"setSymmetryOperator",function(a){if(this.ignoreFileSymmetryOperators)return-1;this.setLatticeCells(!1);var b=this.atomSetCollection.addSpaceGroupOperation(a);0>b&&J.util.Logger.warn("Skipping symmetry operation "+a);this.iHaveSymmetryOperators=!0;return b},"~S");
$_M(c$,"initializeCartesianToFractional",($fz=function(){for(var a=0;16>a;a++)if(!Float.isNaN(this.notionalUnitCell[6+a]))return;for(a=0;16>a;a++)this.notionalUnitCell[6+a]=0==a%5?1:0;this.nMatrixElements=0},$fz.isPrivate=!0,$fz));$_M(c$,"clearUnitCell",function(){if(!this.ignoreFileUnitCell){for(var a=6;22>a;a++)this.notionalUnitCell[a]=NaN;this.checkUnitCell(6)}});$_M(c$,"setUnitCellItem",function(a,b){if(!this.ignoreFileUnitCell&&!(0==a&&1==b||3==a&&0==b))!Float.isNaN(b)&&(6<=a&&Float.isNaN(this.notionalUnitCell[6]))&&
this.initializeCartesianToFractional(),this.notionalUnitCell[a]=b,J.util.Logger.debugging&&J.util.Logger.debug("setunitcellitem "+a+" "+b),6>a||Float.isNaN(b)?this.iHaveUnitCell=this.checkUnitCell(6):12==++this.nMatrixElements&&this.checkUnitCell(22)},"~N,~N");$_M(c$,"setUnitCell",function(a,b,c,d,e,f){this.ignoreFileUnitCell||(this.clearUnitCell(),this.notionalUnitCell[0]=a,this.notionalUnitCell[1]=b,this.notionalUnitCell[2]=c,0!=d&&(this.notionalUnitCell[3]=d),0!=e&&(this.notionalUnitCell[4]=e),
0!=f&&(this.notionalUnitCell[5]=f),this.iHaveUnitCell=this.checkUnitCell(6))},"~N,~N,~N,~N,~N,~N");$_M(c$,"addPrimitiveLatticeVector",function(a,b,c){if(!this.ignoreFileUnitCell){if(0==a)for(var d=0;6>d;d++)this.notionalUnitCell[d]=0;a=6+3*a;this.notionalUnitCell[a++]=b[c++];this.notionalUnitCell[a++]=b[c++];this.notionalUnitCell[a]=b[c];if(Float.isNaN(this.notionalUnitCell[0]))for(a=0;6>a;a++)this.notionalUnitCell[a]=-1;this.iHaveUnitCell=this.checkUnitCell(15)}},"~N,~A,~N");$_M(c$,"checkUnitCell",
($fz=function(a){for(var b=0;b<a;b++)if(Float.isNaN(this.notionalUnitCell[b]))return!1;this.getSymmetry().setUnitCell(this.notionalUnitCell);this.doApplySymmetry&&(this.doConvertToFractional=!this.fileCoordinatesAreFractional);this.checkUnitCellOffset();return!0},$fz.isPrivate=!0,$fz),"~N");$_M(c$,"checkUnitCellOffset",($fz=function(){null==this.symmetry||null==this.fileOffsetFractional||(this.fileOffset.setT(this.fileOffsetFractional),this.unitCellOffsetFractional!=this.fileCoordinatesAreFractional&&
(this.unitCellOffsetFractional?this.symmetry.toCartesian(this.fileOffset,!1):this.symmetry.toFractional(this.fileOffset,!1)))},$fz.isPrivate=!0,$fz));$_M(c$,"getSymmetry",function(){return this.symmetry=J.api.Interface.getOptionInterface("symmetry.Symmetry")});$_M(c$,"setFractionalCoordinates",function(a){this.iHaveFractionalCoordinates=this.fileCoordinatesAreFractional=a;this.checkUnitCellOffset()},"~B");$_M(c$,"setFilterAtomTypeStr",function(a){this.filterAtomTypeStr=a;this.filterAtomNameTerminator=
"\x00"},"~S");$_M(c$,"setFilter",function(a){null==a?a=this.htParams.get("filter"):this.bsFilter=null;null!=a&&(a=a.toUpperCase());this.filter=a;this.doSetOrientation=!this.checkFilterKey("NOORIENT");this.doCentralize=!this.checkFilterKey("NOCENTER")&&this.checkFilterKey("CENTER");this.addVibrations=!this.checkFilterKey("NOVIB");this.doReadMolecularOrbitals=!this.checkFilterKey("NOMO");this.useAltNames=this.checkFilterKey("ALTNAME");this.reverseModels=this.checkFilterKey("REVERSEMODELS");this.checkFilterKey("NAME=")&&
(this.nameRequired=this.filter.substring(this.filter.indexOf("NAME=")+5),this.nameRequired.startsWith("'")?this.nameRequired=J.util.Txt.split(this.nameRequired,"'")[1]:this.nameRequired.startsWith('"')&&(this.nameRequired=J.util.Txt.split(this.nameRequired,'"')[1]),this.filter=J.util.Txt.simpleReplace(this.filter,this.nameRequired,""),this.filter=J.util.Txt.simpleReplace(this.filter,"NAME=",""));if(null!=this.filter&&(this.filterAtomName=this.checkFilterKey("*.")||this.checkFilterKey("!."),this.filterElement=
this.checkFilterKey("_"),this.filterHetero=this.checkFilterKey("HETATM"),this.filterGroup3=this.checkFilterKey("["),this.filterChain=this.checkFilterKey(":"),this.filterAltLoc=this.checkFilterKey("%"),(this.filterEveryNth=this.checkFilterKey("/="))?this.filterN=this.parseIntStr(this.filter.substring(this.filter.indexOf("/=")+2)):this.filterAtomType=this.checkFilterKey("="),-2147483648==this.filterN&&(this.filterEveryNth=!1),this.haveAtomFilter=this.filterAtomName||this.filterAtomType||this.filterElement||
this.filterGroup3||this.filterChain||this.filterAltLoc||this.filterHetero||this.filterEveryNth||this.checkFilterKey("/="),null==this.bsFilter&&(this.bsFilter=new JU.BS,this.htParams.put("bsFilter",this.bsFilter),this.filter=(";"+this.filter+";").$replace(",",";"),J.util.Logger.info("filtering with "+this.filter),this.haveAtomFilter&&(this.filter1=this.filter,0<=(a=this.filter.indexOf("|"))))))this.filter1=this.filter.substring(0,a).trim()+";",this.filter2=";"+this.filter.substring(a).trim()},"~S");
$_M(c$,"getFilter",function(a){var b=null==this.filter?-1:this.filter.indexOf(a);return 0>b?null:this.filter.substring(b+a.length,this.filter.indexOf(";",b))},"~S");$_M(c$,"checkFilterKey",function(a){return null!=this.filter&&0<=this.filter.indexOf(a)},"~S");$_M(c$,"filterAtom",function(a,b){if(!this.haveAtomFilter)return!0;var c=this.checkFilter(a,this.filter1);null!=this.filter2&&(c=(new Boolean(c|this.checkFilter(a,this.filter2))).valueOf());c&&this.filterEveryNth&&(c=0==this.nFiltered++%this.filterN);
this.bsFilter.setBitTo(0<=b?b:this.atomSetCollection.getAtomCount(),c);return c},"J.adapter.smarter.Atom,~N");$_M(c$,"checkFilter",($fz=function(a,b){return(!this.filterGroup3||null==a.group3||!this.filterReject(b,"[",a.group3.toUpperCase()+"]"))&&(!this.filterAtomName||this.allowAtomName(a.atomName,b))&&(null==this.filterAtomTypeStr||null==a.atomName||0<=a.atomName.toUpperCase().indexOf("\x00"+this.filterAtomTypeStr))&&(!this.filterElement||null==a.elementSymbol||!this.filterReject(b,"_",a.elementSymbol.toUpperCase()+
";"))&&(!this.filterChain||0==a.chainID||!this.filterReject(b,":",""+this.viewer.getChainIDStr(a.chainID)))&&(!this.filterAltLoc||"\x00"==a.alternateLocationID||!this.filterReject(b,"%",""+a.alternateLocationID))&&(!this.filterHetero||!this.filterReject(b,"HETATM",a.isHetero?"HETATM":"ATOM"))},$fz.isPrivate=!0,$fz),"J.adapter.smarter.Atom,~S");$_M(c$,"rejectAtomName",function(a){return this.filterAtomName&&!this.allowAtomName(a,this.filter)},"~S");$_M(c$,"allowAtomName",($fz=function(a,b){return null==
a||!this.filterReject(b,".",a.toUpperCase()+this.filterAtomNameTerminator)},$fz.isPrivate=!0,$fz),"~S,~S");$_M(c$,"filterReject",function(a,b,c){return 0<=a.indexOf(b)&&(0<=a.indexOf("!"+b)?0<=a.indexOf(b+c):0>a.indexOf(b+c))},"~S,~S,~S");$_M(c$,"set2D",function(){this.atomSetCollection.setAtomSetCollectionAuxiliaryInfo("is2D",Boolean.TRUE);this.checkFilterKey("NOMIN")||this.atomSetCollection.setAtomSetCollectionAuxiliaryInfo("doMinimize",Boolean.TRUE)});$_M(c$,"doGetVibration",function(a){return this.addVibrations&&
(0>=this.desiredVibrationNumber||a==this.desiredVibrationNumber)},"~N");$_M(c$,"setTransform",function(a,b,c,d,e,f,g,h,k){if(null==this.matrixRotate&&this.doSetOrientation){this.matrixRotate=new JU.M3;var l=new JU.V3;l.set(a,b,c);l.normalize();this.matrixRotate.setColumnV(0,l);l.set(d,e,f);l.normalize();this.matrixRotate.setColumnV(1,l);l.set(g,h,k);l.normalize();this.matrixRotate.setColumnV(2,l);this.atomSetCollection.setAtomSetCollectionAuxiliaryInfo("defaultOrientationMatrix",JU.M3.newM(this.matrixRotate));
a=J.util.Quaternion.newM(this.matrixRotate);this.atomSetCollection.setAtomSetCollectionAuxiliaryInfo("defaultOrientationQuaternion",a);J.util.Logger.info("defaultOrientationMatrix = "+this.matrixRotate)}},"~N,~N,~N,~N,~N,~N,~N,~N,~N");$_M(c$,"setAtomCoordXYZ",function(a,b,c,d){a.set(b,c,d);this.setAtomCoord(a)},"J.adapter.smarter.Atom,~N,~N,~N");$_M(c$,"setAtomCoord",function(a){null!=this.fileScaling&&(a.x=a.x*this.fileScaling.x+this.fileOffset.x,a.y=a.y*this.fileScaling.y+this.fileOffset.y,a.z=
a.z*this.fileScaling.z+this.fileOffset.z);this.doConvertToFractional&&(!this.fileCoordinatesAreFractional&&null!=this.symmetry)&&(this.symmetry.haveUnitCell()||this.symmetry.setUnitCell(this.notionalUnitCell),this.symmetry.toFractional(a,!1),this.iHaveFractionalCoordinates=!0);this.doCheckUnitCell=!0},"J.adapter.smarter.Atom");$_M(c$,"addSites",function(a){this.atomSetCollection.setAtomSetAuxiliaryInfo("pdbSites",a);var b="",c;for(a=a.entrySet().iterator();a.hasNext()&&((c=a.next())||1);){for(var d=
c.getKey(),e=c.getValue(),f,g=d.length;0<=--g;)if(!Character.isLetterOrDigit(f=d.charAt(g))&&"'"!=f)d=d.substring(0,g)+"_"+d.substring(g+1);e=e.get("groups");0!=e.length&&(this.addSiteScript("@site_"+d+" "+e),this.addSiteScript("site_"+d+' = "'+e+'".split(",")'),b+=(""===b?"":",")+"site_"+d)}this.addSiteScript('site_list = "'+b+'".split(",")')},"java.util.Map");$_M(c$,"applySymmetryAndSetTrajectory",function(){this.applySymTrajASCR()});$_M(c$,"applySymTrajASCR",function(){this.forcePacked&&this.initializeSymmetryOptions();
var a=null;if(this.iHaveUnitCell&&this.doCheckUnitCell){this.atomSetCollection.setCoordinatesAreFractional(this.iHaveFractionalCoordinates);this.atomSetCollection.setNotionalUnitCell(this.notionalUnitCell,this.matUnitCellOrientation,this.unitCellOffset);a=this.atomSetCollection.symmetry;this.atomSetCollection.setAtomSetSpaceGroupName(this.spaceGroup);this.atomSetCollection.setSymmetryRange(this.symmetryRange);if(this.doConvertToFractional||this.fileCoordinatesAreFractional)if(this.setLatticeCells(!1),
this.ignoreFileSpaceGroupName||!this.iHaveSymmetryOperators){if((!this.merging||null==this.symmetry)&&this.getSymmetry(),this.symmetry.createSpaceGroup(this.desiredSpaceGroupIndex,0<=this.spaceGroup.indexOf("!")?"P1":this.spaceGroup,this.notionalUnitCell))this.atomSetCollection.applySymmetry(this.symmetry),this.atomSetCollection.setAtomSetSpaceGroupName(this.symmetry.getSpaceGroupName())}else this.atomSetCollection.applySymmetry(null);this.iHaveFractionalCoordinates&&(this.merging&&null!=this.symmetry)&&
(this.atomSetCollection.toCartesian(this.symmetry),this.atomSetCollection.setCoordinatesAreFractional(!1),this.addVibrations=!1)}this.isTrajectory&&this.atomSetCollection.setTrajectory();this.initializeSymmetry();return a});$_M(c$,"finalizeMOData",function(a){this.atomSetCollection.setAtomSetAuxiliaryInfo("moData",a);null!=a&&(a=a.get("mos"),null!=a&&J.util.Logger.info(a.size()+" molecular orbitals read in model "+this.atomSetCollection.getAtomSetCount()))},"java.util.Map");c$.getElementSymbol=$_M(c$,
"getElementSymbol",function(a){return J.api.JmolAdapter.getElementSymbol(a)},"~N");$_M(c$,"fillDataBlockFixed",function(a,b,c,d){if(0==c)this.fillDataBlock(a,d);else{d=a.length;for(var e=0;e<d;e++){this.discardLinesUntilNonBlank();var f=Clazz.doubleToInt((this.line.length-b+1)/c);a[e]=Array(f);for(var g=0,h=b;g<f;g++,h+=c)a[e][g]=this.line.substring(h,Math.min(this.line.length,h+c))}}},"~A,~N,~N,~N");$_M(c$,"fillDataBlock",function(a,b){for(var c=a.length,d=0;d<c;d++)a[d]=J.adapter.smarter.AtomSetCollectionReader.getTokensStr(this.discardLinesUntilNonBlank()),
a[d].length<b&&--d},"~A,~N");$_M(c$,"fillFloatArray",function(a,b,c){for(var d=[],e=0,f=0;f<c.length;f++){for(;null!=d&&e>=d.length;){null==a&&(a=this.readLine());if(0==b)d=J.adapter.smarter.AtomSetCollectionReader.getTokensStr(a);else{d=Array(Clazz.doubleToInt(a.length/b));for(e=0;e<d.length;e++)d[e]=a.substring(e*b,(e+1)*b)}a=null;e=0}if(null==d)break;c[f]=this.parseFloatStr(d[e++])}return c},"~S,~N,~A");$_M(c$,"fillFrequencyData",function(a,b,c,d,e,f,g,h,k){var l=c!=b;null!=h&&(b=h.length);b=e?
b:3*b;var m=d.length,n=Array(b);this.fillDataBlockFixed(n,f,g,k);for(g=f=0;f<b;f++,g++){k=n[f];for(var q=e?null:n[++f],p=e?null:n[++f],r=k.length-(e?3*m:m)-1,s=0,t=0;t<m;t++){++r;var u=k[r];")"==u.charAt(0)&&(u=u.substring(1));var u=this.parseFloatStr(u),v=this.parseFloatStr(e?k[++r]:q[r]),y=this.parseFloatStr(e?k[++r]:p[r]);if(!d[t]){var A=null==h?g:h[g];0>A||(J.util.Logger.debugging&&J.util.Logger.debug("atom "+A+" vib"+s+": "+u+" "+v+" "+y),this.atomSetCollection.addVibrationVectorWithSymmetry(a+
c*s++ +A,u,v,y,l))}}}},"~N,~N,~N,~A,~B,~N,~N,~A,~N");$_M(c$,"readLines",function(a){for(;0<=--a;)this.readLine();return this.line},"~N");$_M(c$,"discardLinesUntilStartsWith",function(a){for(;null!=this.readLine()&&!this.line.startsWith(a););return this.line},"~S");$_M(c$,"discardLinesUntilContains",function(a){for(;null!=this.readLine()&&0>this.line.indexOf(a););return this.line},"~S");$_M(c$,"discardLinesUntilContains2",function(a,b){for(;null!=this.readLine()&&0>this.line.indexOf(a)&&0>this.line.indexOf(b););
return this.line},"~S,~S");$_M(c$,"discardLinesUntilBlank",function(){for(;null!=this.readLine()&&0!=this.line.trim().length;);});$_M(c$,"discardLinesUntilNonBlank",function(){for(;null!=this.readLine()&&0==this.line.trim().length;);return this.line});$_M(c$,"checkLineForScript",function(a){this.line=a;this.checkCurrentLineForScript()},"~S");$_M(c$,"checkCurrentLineForScript",function(){if(0<=this.line.indexOf("Jmol")&&(0<=this.line.indexOf("Jmol PDB-encoded data")&&(this.atomSetCollection.setAtomSetCollectionAuxiliaryInfo("jmolData",
this.line),this.line.endsWith("#noautobond")||(this.line+="#noautobond")),0<=this.line.indexOf("Jmol data min"))){J.util.Logger.info(this.line);var a=Clazz.newFloatArray(15,0);this.parseStringInfestedFloatArray(this.line.substring(10).$replace("="," ").$replace("{"," ").$replace("}"," "),a);var b=JU.P3.new3(a[0],a[1],a[2]),c=JU.P3.new3(a[3],a[4],a[5]);this.fileScaling=JU.P3.new3(a[6],a[7],a[8]);this.fileOffset=JU.P3.new3(a[9],a[10],a[11]);a=JU.P3.new3(a[12],a[13],a[14]);0>=a.x&&(a.x=100);0>=a.y&&
(a.y=100);0>=a.z&&(a.z=100);0==this.fileScaling.y&&(this.fileScaling.y=1);0==this.fileScaling.z&&(this.fileScaling.z=1);this.setFractionalCoordinates(!0);this.latticeCells=Clazz.newIntArray(3,0);this.setLatticeCells(!0);this.setUnitCell(2*a.x/(c.x-b.x),2*a.y/(c.y-b.y),2*a.z/(c.z==b.z?1:c.z-b.z),90,90,90);this.unitCellOffset=JU.P3.newP(a);this.unitCellOffset.scale(-1);this.symmetry.toFractional(this.unitCellOffset,!1);this.unitCellOffset.scaleAdd2(-1,b,this.unitCellOffset);this.symmetry.setOffsetPt(this.unitCellOffset);
this.atomSetCollection.setAtomSetCollectionAuxiliaryInfo("jmolDataScaling",[b,c,a])}this.line.endsWith("#noautobond")&&(this.line=this.line.substring(0,this.line.lastIndexOf("#")).trim(),this.atomSetCollection.setNoAutoBond());b=this.line.indexOf("jmolscript:");0<=b&&(c=this.line.substring(b+11,this.line.length),0<=c.indexOf("#")&&(c=c.substring(0,c.indexOf("#"))),this.addJmolScript(c),this.line=this.line.substring(0,b).trim())});$_M(c$,"setLatticeCells",($fz=function(a){a?this.atomSetCollection.setLatticeCells(this.latticeCells,
!0,!1,!1,!1,null,null):this.atomSetCollection.setLatticeCells(this.latticeCells,this.applySymmetryToBonds,this.doPackUnitCell,this.doCentroidUnitCell,this.centroidPacked,this.strSupercell,this.ptSupercell)},$fz.isPrivate=!0,$fz),"~B");$_M(c$,"addJmolScript",function(a){J.util.Logger.info("#jmolScript: "+a);null==this.previousScript?this.previousScript="":this.previousScript.endsWith(";")||(this.previousScript+=";");this.previousScript+=a;this.atomSetCollection.setAtomSetCollectionAuxiliaryInfo("jmolscript",
this.previousScript)},"~S");$_M(c$,"addSiteScript",function(a){null==this.siteScript?this.siteScript="":this.siteScript.endsWith(";")||(this.siteScript+=";");this.siteScript+=a;this.atomSetCollection.setAtomSetCollectionAuxiliaryInfo("sitescript",this.siteScript)},"~S");$_M(c$,"readLine",function(){return this.RL()});$_M(c$,"RL",function(){this.prevline=this.line;this.line=this.reader.readLine();if(null!=this.out&&null!=this.line){var a=this.line.getBytes();this.out.write(a,0,a.length);this.out.writeByteAsInt(10)}this.ptLine++;
J.util.Logger.debugging&&J.util.Logger.debug(this.line);return this.line});c$.getStrings=$_M(c$,"getStrings",function(a,b,c){for(var d=Array(b),e=0,f=0;e<b;e++,f+=c)d[e]=a.substring(f,f+c);return d},"~S,~N,~N");$_M(c$,"getTokens",function(){return JU.ParserJS.getTokens(this.line)});$_M(c$,"parseStringInfestedFloatArray",function(a,b){J.util.ParserBS.parseStringInfestedFloatArray(a,null,b)},"~S,~A");c$.getTokensFloat=$_M(c$,"getTokensFloat",function(a,b,c){null==b&&(b=Clazz.newFloatArray(c,0));JU.ParserJS.parseFloatArrayDataN(J.adapter.smarter.AtomSetCollectionReader.getTokensStr(a),
b,c);return b},"~S,~A,~N");c$.getTokensStr=$_M(c$,"getTokensStr",function(a){return JU.ParserJS.getTokens(a)},"~S");c$.getTokensAt=$_M(c$,"getTokensAt",function(a,b){return JU.ParserJS.getTokensAt(a,b)},"~S,~N");$_M(c$,"parseFloat",function(){return JU.ParserJS.parseFloatNext(this.line,this.next)});$_M(c$,"parseFloatStr",function(a){this.next[0]=0;return JU.ParserJS.parseFloatNext(a,this.next)},"~S");$_M(c$,"parseFloatRange",function(a,b,c){this.next[0]=b;return JU.ParserJS.parseFloatRange(a,c,this.next)},
"~S,~N,~N");$_M(c$,"parseInt",function(){return JU.ParserJS.parseIntNext(this.line,this.next)});$_M(c$,"parseIntStr",function(a){this.next[0]=0;return JU.ParserJS.parseIntNext(a,this.next)},"~S");$_M(c$,"parseIntAt",function(a,b){this.next[0]=b;return JU.ParserJS.parseIntNext(a,this.next)},"~S,~N");$_M(c$,"parseIntRange",function(a,b,c){this.next[0]=b;return JU.ParserJS.parseIntRange(a,c,this.next)},"~S,~N,~N");$_M(c$,"parseToken",function(){return JU.ParserJS.parseTokenNext(this.line,this.next)});
$_M(c$,"parseTokenStr",function(a){this.next[0]=0;return JU.ParserJS.parseTokenNext(a,this.next)},"~S");$_M(c$,"parseTokenNext",function(a){return JU.ParserJS.parseTokenNext(a,this.next)},"~S");$_M(c$,"parseTokenRange",function(a,b,c){this.next[0]=b;return JU.ParserJS.parseTokenRange(a,c,this.next)},"~S,~N,~N");c$.parseTrimmedAt=$_M(c$,"parseTrimmedAt",function(a,b){return JU.ParserJS.parseTrimmedAt(a,b)},"~S,~N");c$.parseTrimmedRange=$_M(c$,"parseTrimmedRange",function(a,b,c){return JU.ParserJS.parseTrimmedRange(a,
b,c)},"~S,~N,~N");c$.getFortranFormatLengths=$_M(c$,"getFortranFormatLengths",function(a){var b=new JU.List,c=0,d=0,e=1,f=!1,g=!0;a+=",";for(var h=0;h<a.length;h++){var k=a.charAt(h);switch(k){case ".":f=!1;continue;case ",":for(f=0;f<d;f++)b.addLast(Integer.$valueOf(c*e));f=!1;g=!0;d=0;continue;case "X":c=d;d=1;e=-1;continue}Character.isDigit(k)?f?c=10*c+k.charCodeAt(0)-48:g&&(d=10*d+k.charCodeAt(0)-48):Character.isLetter(k)?(c=0,f=!0,g=!1,e=1):f=!1}return b},"~S");$_M(c$,"read3Vectors",function(a){for(var b=
Array(3),c=Clazz.newFloatArray(3,0),d=0;3>d;d++){if(0<d||Float.isNaN(this.parseFloatStr(this.line)))if(this.readLine(),0==d&&null!=this.line){d=-1;continue}this.fillFloatArray(this.line,0,c);b[d]=new JU.V3;b[d].setA(c);a&&b[d].scale(0.5291772)}return b},"~B");$_M(c$,"setElementAndIsotope",function(a,b){var c=this.parseIntStr(b);-2147483648==c?a.elementSymbol=b:(b=b.substring((""+c).length),a.elementNumber=0==b.length?c:(c<<7)+J.api.JmolAdapter.getElementNumber(b))},"J.adapter.smarter.Atom,~S");$_M(c$,
"finalizeModelSet",function(){});$_M(c$,"setChainID",function(a,b){a.chainID=this.viewer.getChainID(""+b)},"J.adapter.smarter.Atom,~S");Clazz.defineStatics(c$,"ANGSTROMS_PER_BOHR",0.5291772)}),Clazz.declarePackage("J.thread"),Clazz.load(["java.lang.Thread"],"J.thread.JmolThread",["J.util.Logger"],function(){c$=Clazz.decorateAsClass(function(){this.$name="JmolThread";this.sc=this.eval=this.viewer=null;this.hoverEnabled=!1;this.sleepTime=this.currentTime=this.lastRepaintTime=this.targetTime=this.startTime=
0;this.isReset=this.stopped=this.isJS=!1;this.useTimeout=!0;this.junk=0;Clazz.instantialize(this,arguments)},J.thread,"JmolThread",Thread);$_M(c$,"setManager",function(){return 0},"~O,J.viewer.Viewer,~O");$_M(c$,"setViewer",function(a,b){this.setName(b);this.$name=b+"_"+($t$=++J.thread.JmolThread.threadIndex,J.thread.JmolThread.prototype.threadIndex=J.thread.JmolThread.threadIndex,$t$);this.viewer=a;this.isJS=a.isSingleThreaded},"J.viewer.Viewer,~S");$_M(c$,"setEval",function(a){this.eval=a;this.sc=
this.viewer.getEvalContextAndHoldQueue(a);null!=this.sc&&(this.useTimeout=a.getAllowJSThreads())},"J.api.JmolScriptEvaluator");$_M(c$,"resumeEval",function(){null==this.eval||(!this.isJS||!this.useTimeout)||(this.sc.mustResumeEval=!this.stopped,this.eval.resumeEval(this.sc),this.sc=this.eval=null)});$_M(c$,"start",function(){this.isJS?(J.util.Logger.info("starting "+this.$name),this.run()):Clazz.superCall(this,J.thread.JmolThread,"start",[])});Clazz.overrideMethod(c$,"run",function(){this.startTime=
System.currentTimeMillis();try{this.run1(-1)}catch(a){if(Clazz.exceptionOf(a,InterruptedException)){var b=a;J.util.Logger.debugging&&!Clazz.instanceOf(this,J.thread.HoverWatcherThread)&&this.oops(b)}else if(Clazz.exceptionOf(a,Exception))this.oops(a);else throw a;}});$_M(c$,"oops",function(a){J.util.Logger.debug(this.$name+" exception "+a);this.viewer.isJS||a.printStackTrace();this.viewer.queueOnHold=!1},"Exception");$_M(c$,"runSleep",function(a,b){if(this.isJS&&!this.useTimeout)return!0;var c=this;
setTimeout(function(){c.run1(b)},Math.max(a,0));return!1},"~N,~N");$_M(c$,"interrupt",function(){this.stopped=!0;this.viewer.startHoverWatcher(!0);this.isJS||Clazz.superCall(this,J.thread.JmolThread,"interrupt",[])});$_M(c$,"checkInterrupted",function(){return this.stopped});$_M(c$,"reset",function(){this.isReset=!0;this.interrupt()});Clazz.defineStatics(c$,"threadIndex",0,"INIT",-1,"MAIN",0,"FINISH",-2,"CHECK1",1,"CHECK2",2,"CHECK3",3)}),Clazz.declarePackage("J.io"),c$=Clazz.decorateAsClass(function(){this.buf=
null;this.ichCurrent=this.cchBuf=0;Clazz.instantialize(this,arguments)},J.io,"LimitedLineReader"),Clazz.makeConstructor(c$,function(a,b){a.mark(b+1);this.buf=Clazz.newCharArray(b,"\x00");this.cchBuf=Math.max(a.read(this.buf,0,b),0);this.ichCurrent=0;a.reset()},"java.io.BufferedReader,~N"),$_M(c$,"getHeader",function(a){return 0==a?String.instantialize(this.buf):String.instantialize(this.buf,0,Math.min(this.cchBuf,a))},"~N"),$_M(c$,"readLineWithNewline",function(){for(;this.ichCurrent<this.cchBuf;){for(var a=
this.ichCurrent,b=String.fromCharCode(0);this.ichCurrent<this.cchBuf&&"\r"!=(b=this.buf[this.ichCurrent++])&&"\n"!=b;);"\r"==b&&(this.ichCurrent<this.cchBuf&&"\n"==this.buf[this.ichCurrent])&&++this.ichCurrent;b=this.ichCurrent-a;if("#"!=this.buf[a])return String.instantialize(this.buf,a,b)}return""}),Clazz.declarePackage("J.constant"),Clazz.load(["java.lang.Enum"],"J.constant.EnumStereoMode",null,function(){c$=Clazz.decorateAsClass(function(){this.$$name=null;this.$isBiColor=!1;Clazz.instantialize(this,
arguments)},J.constant,"EnumStereoMode",Enum);Clazz.makeConstructor(c$,($fz=function(a,b){this.$$name=a;this.$isBiColor=b},$fz.isPrivate=!0,$fz),"~S,~B");$_M(c$,"getName",function(){return this.$$name});$_M(c$,"isBiColor",function(){return this.$isBiColor});c$.getStereoMode=$_M(c$,"getStereoMode",function(a){for(var b,c=0,d=J.constant.EnumStereoMode.values();c<d.length&&((b=d[c])||1);c++)if(b.$$name.equalsIgnoreCase(a))return b;return null},"~S");c$.DEFAULT_STEREO_DEGREES=-5;Clazz.defineEnumConstant(c$,
"NONE",0,["OFF",!1]);Clazz.defineEnumConstant(c$,"DOUBLE",1,["",!1]);Clazz.defineEnumConstant(c$,"REDCYAN",2,["REDCYAN",!0]);Clazz.defineEnumConstant(c$,"REDBLUE",3,["REDBLUE",!0]);Clazz.defineEnumConstant(c$,"REDGREEN",4,["REDGREEN",!0]);Clazz.defineEnumConstant(c$,"CUSTOM",5,["",!0])}),Clazz.declarePackage("J.io"),Clazz.load(null,"J.io.Base64",["JU.SB"],function(){c$=Clazz.declareType(J.io,"Base64");c$.getBytes64=$_M(c$,"getBytes64",function(a){return J.io.Base64.getBase64(a).toBytes(0,-1)},"~A");
c$.getBase64=$_M(c$,"getBase64",function(a){var b=a.length,c=new JU.SB;if(0==b)return c;for(var d=0,e=0;d<b&&0==e;){0==d%75&&0!=d&&c.append("\r\n");var e=d+2==b?1:d+1==b?2:0,f=a[d++]<<16&16711680|(2==e?0:a[d++]<<8)&65280|(1<=e?0:a[d++])&255;c.appendC(J.io.Base64.base64.charAt(f>>18&63));c.appendC(J.io.Base64.base64.charAt(f>>12&63));c.appendC(2==e?"=":J.io.Base64.base64.charAt(f>>6&63));c.appendC(1<=e?"=":J.io.Base64.base64.charAt(f&63))}return c},"~A");c$.decodeBase64=$_M(c$,"decodeBase64",function(a){var b=
0,c;a=a.toCharArray();var d=a.length;if(0==d)return Clazz.newByteArray(0,0);for(var e=d;0<=--e;)b+=65==(c=a[e].charCodeAt(0)&127)||0<J.io.Base64.decode64[c]?3:0;for(var b=b>>2,f=Clazz.newByteArray(b,0),g=18,h=e=0,k=0;e<d;e++)if(0<J.io.Base64.decode64[c=a[e].charCodeAt(0)&127]||65==c||61==c)k|=J.io.Base64.decode64[c]<<g,g-=6,0>g&&(f[h++]=(k&16711680)>>16,h<b&&(f[h++]=(k&65280)>>8),h<b&&(f[h++]=k&255),g=18,k=0);return f},"~S");Clazz.defineStatics(c$,"base64","ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",
"decode64",[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,62,0,62,0,63,52,53,54,55,56,57,58,59,60,61,0,0,0,0,0,0,0,0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,0,0,0,0,63,0,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,0,0,0,0,0])}),Clazz.declarePackage("J.io"),Clazz.load(["JU.SB"],"J.io.CifDataReader",["java.util.Hashtable","JU.List","J.util.Logger"],function(){c$=Clazz.decorateAsClass(function(){this.str=
this.line=this.br=this.reader=null;this.cch=this.ich=0;this.wasUnQuoted=!1;this.strPeeked=null;this.fieldCount=this.ichPeeked=0;this.fileHeader=this.loopData=null;this.isHeader=!0;this.allData=this.data=null;Clazz.instantialize(this,arguments)},J.io,"CifDataReader");Clazz.prepareFields(c$,function(){this.fileHeader=new JU.SB});Clazz.makeConstructor(c$,function(a){this.reader=a},"J.api.JmolLineReader");Clazz.makeConstructor(c$,function(a){this.br=a},"java.io.BufferedReader");$_M(c$,"getFileHeader",
function(){return this.fileHeader.toString()});c$.readCifData=$_M(c$,"readCifData",function(a){return(new J.io.CifDataReader(a)).getAllCifData()},"java.io.BufferedReader");$_M(c$,"getAllCifData",($fz=function(){this.line="";var a;this.allData=new java.util.Hashtable;var b=new JU.List;this.allData.put("models",b);try{for(;null!=(a=this.getNextToken());)if(a.startsWith("global_")||a.startsWith("data_"))b.addLast(this.data=new java.util.Hashtable),this.data.put("name",a);else if(a.startsWith("loop_"))this.getCifLoopData();
else if(0!=a.indexOf("_"))J.util.Logger.warn("CIF ERROR ? should be an underscore: "+a);else{var c=this.getNextToken();null==c?J.util.Logger.warn("CIF ERROR ? end of file; data missing: "+a):this.data.put(a,c)}}catch(d){if(!Clazz.exceptionOf(d,Exception))throw d;}try{null!=this.br&&this.br.close()}catch(e){if(!Clazz.exceptionOf(e,Exception))throw e;}return this.allData},$fz.isPrivate=!0,$fz));$_M(c$,"readLine",function(){try{this.line=null!=this.reader?this.reader.readNextLine():this.br.readLine();
if(null==this.line)return null;this.isHeader&&(this.line.startsWith("#")?this.fileHeader.append(this.line).appendC("\n"):this.isHeader=!1);return this.line}catch(a){if(Clazz.exceptionOf(a,Exception))return null;throw a;}});$_M(c$,"getData",function(){for(var a=0;a<this.fieldCount;++a)if(null==(this.loopData[a]=this.getNextDataToken()))return!1;return!0});$_M(c$,"getNextToken",function(){for(;!this.hasMoreTokens();)if(null==this.setStringNextLine())return null;return this.nextToken()});$_M(c$,"setString",
($fz=function(a){this.str=this.line=a;this.cch=null==a?0:a.length;this.ich=0},$fz.isPrivate=!0,$fz),"~S");$_M(c$,"setStringNextLine",($fz=function(){this.setString(this.readLine());if(null==this.line||0==this.line.length)return this.line;if(";"!=this.line.charAt(0))return this.str.startsWith("###non-st#")&&(this.ich=10),this.line;this.ich=1;for(var a="\u0001"+this.line.substring(1)+"\n";null!=this.readLine();){if(this.line.startsWith(";")){a=a.substring(0,a.length-1)+"\u0001"+this.line.substring(1);
break}a+=this.line+"\n"}this.setString(a);return a},$fz.isPrivate=!0,$fz));$_M(c$,"hasMoreTokens",($fz=function(){if(null==this.str)return!1;for(var a="#";this.ich<this.cch&&(" "==(a=this.str.charAt(this.ich))||"\t"==a);)++this.ich;return this.ich<this.cch&&"#"!=a},$fz.isPrivate=!0,$fz));$_M(c$,"nextToken",($fz=function(){if(this.ich==this.cch)return null;var a=this.ich,b=this.str.charAt(a);if("'"!=b&&'"'!=b&&"\u0001"!=b){for(this.wasUnQuoted=!0;this.ich<this.cch&&" "!=(b=this.str.charAt(this.ich))&&
"\t"!=b;)++this.ich;return this.ich==a+1&&("."==this.str.charAt(a)||"?"==this.str.charAt(a))?"\x00":this.str.substring(a,this.ich)}this.wasUnQuoted=!1;for(var c=b,d=!1;++this.ich<this.cch;){b=this.str.charAt(this.ich);if(d&&(" "==b||"\t"==b))break;d=b==c}if(this.ich==this.cch)return d?this.str.substring(a+1,this.ich-1):this.str.substring(a,this.ich);++this.ich;return this.str.substring(a+1,this.ich-2)},$fz.isPrivate=!0,$fz));$_M(c$,"getNextDataToken",function(){var a=this.peekToken();return null==
a||this.wasUnQuoted&&("_"==a.charAt(0)||a.startsWith("loop_")||a.startsWith("data_")||a.startsWith("stop_")||a.startsWith("global_"))?null:this.getTokenPeeked()});$_M(c$,"peekToken",function(){for(;!this.hasMoreTokens();)if(null==this.setStringNextLine())return null;var a=this.ich;this.strPeeked=this.nextToken();this.ichPeeked=this.ich;this.ich=a;return this.strPeeked});$_M(c$,"getTokenPeeked",function(){this.ich=this.ichPeeked;return this.strPeeked});$_M(c$,"fullTrim",function(a){for(var b=0,c=a.length;b<
c&&!(0>"\n\t ".indexOf(a.charAt(b)));b++);for(;b<c&&!(0>"\n\t ".indexOf(a.charAt(c-1)));c--);return a.substring(b,c)},"~S");$_M(c$,"getCifLoopData",($fz=function(){for(var a,b=new JU.List;null!=(a=this.peekToken())&&"_"==a.charAt(0);)a=this.getTokenPeeked(),b.addLast(a),this.data.put(a,new JU.List);this.fieldCount=b.size();if(0!=this.fieldCount)for(this.loopData=Array(this.fieldCount);this.getData();)for(a=0;a<this.fieldCount;a++)this.data.get(b.get(a)).addLast(this.loopData[a])},$fz.isPrivate=!0,
$fz))}),Clazz.declarePackage("J.io"),Clazz.load(null,"J.io.JmolBinary","java.io.BufferedInputStream $.BufferedReader $.ByteArrayInputStream $.InputStreamReader $.StringReader JU.ArrayUtil $.ParserJS $.SB J.api.Interface J.io.Base64 $.Encoding $.LimitedLineReader J.util.Logger $.Parser $.Txt J.viewer.FileManager".split(" "),function(){c$=Clazz.declareType(J.io,"JmolBinary");c$.determineSurfaceTypeIs=$_M(c$,"determineSurfaceTypeIs",function(a){var b;try{b=J.io.JmolBinary.getBufferedReader(new java.io.BufferedInputStream(a),
"ISO-8859-1")}catch(c){if(Clazz.exceptionOf(c,java.io.IOException))return null;throw c;}return J.io.JmolBinary.determineSurfaceFileType(b)},"java.io.InputStream");c$.determineSurfaceFileType=$_M(c$,"determineSurfaceFileType",function(a){var b=null,c=null;try{c=new J.io.LimitedLineReader(a,16E3),b=c.getHeader(0)}catch(d){if(!Clazz.exceptionOf(d,Exception))throw d;}if(null==c||null==b||0==b.length)return null;switch(b.charAt(0)){case "@":if(0==b.indexOf("@text"))return"Kinemage";break;case "#":if(0<=
b.indexOf(".obj"))return"Obj";if(0<=b.indexOf("MSMS"))return"Msms";break;case "&":if(0==b.indexOf("&plot"))return"Jaguar";break;case "\r":case "\n":if(0<=b.indexOf("ZYX"))return"Xplor"}if(0<=b.indexOf("Here is your gzipped map"))return"UPPSALA"+b;if(0<=b.indexOf("! nspins"))return"CastepDensity";if(0<=b.indexOf("<jvxl")&&0<=b.indexOf("<?xml"))return"JvxlXml";if(0<=b.indexOf("#JVXL+"))return"Jvxl+";if(0<=b.indexOf("#JVXL"))return"Jvxl";if(0<=b.indexOf("<efvet "))return"Efvet";if(0<=b.indexOf("usemtl"))return"Obj";
if(0==b.indexOf("# object with"))return"Nff";if(0<=b.indexOf("BEGIN_DATAGRID_3D")||0<=b.indexOf("BEGIN_BANDGRID_3D"))return"Xsf";if(0<=b.indexOf("\x00")){if(0==b.indexOf("PM\u0001\x00"))return"Pmesh";if(0==b.indexOf("\u0014\x00\x00\x00"))return"DelPhi";if(208==b.indexOf("MAP "))return"Mrc";if(37<b.length&&(0==b.charCodeAt(36)&&100==b.charCodeAt(37)||0==b.charCodeAt(36)&&100==b.charCodeAt(37)))return"Dsn6"}if(0<=b.indexOf(" 0.00000e+00 0.00000e+00      0      0\n"))return"Uhbd";b=c.readLineWithNewline();
if(0==b.indexOf("object 1 class gridpositions counts"))return"Apbs";var e=JU.ParserJS.getTokens(b);a=c.readLineWithNewline();if(2==e.length&&(3==JU.ParserJS.parseInt(e[0])&&-2147483648!=JU.ParserJS.parseInt(e[1]))&&(e=JU.ParserJS.getTokens(a),3==e.length&&-2147483648!=JU.ParserJS.parseInt(e[0])&&-2147483648!=JU.ParserJS.parseInt(e[1])&&-2147483648!=JU.ParserJS.parseInt(e[2])))return"PltFormatted";e=c.readLineWithNewline();if(b.startsWith("v ")&&a.startsWith("v ")&&e.startsWith("v "))return"Obj";a=
JU.ParserJS.parseInt(e);if(-2147483648==a)return 0==e.indexOf("+")?"Jvxl+":null;if(0<=a)return"Cube";for(a=4+-a;0<=--a;)if(null==(b=c.readLineWithNewline()))return null;b=JU.ParserJS.parseInt(b);return-2147483648==b?null:0>b?"Jvxl":"Cube"},"java.io.BufferedReader");c$.getUTFEncodingForStream=$_M(c$,"getUTFEncodingForStream",($fz=function(a){a.resetStream();var b=Clazz.newByteArray(4,0);b[3]=1;try{a.mark(5)}catch(c){if(Clazz.exceptionOf(c,Exception))return J.io.Encoding.NONE;throw c;}a.read(b,0,4);
a.reset();return J.io.JmolBinary.getUTFEncoding(b)},$fz.isPrivate=!0,$fz),"java.io.BufferedInputStream");c$.fixUTF=$_M(c$,"fixUTF",function(a){var b=J.io.JmolBinary.getUTFEncoding(a);if(b!==J.io.Encoding.NONE)try{var c=String.instantialize(a,b.name().$replace("_","-"));switch(b){case J.io.Encoding.UTF8:case J.io.Encoding.UTF_16BE:case J.io.Encoding.UTF_16LE:c=c.substring(1)}return c}catch(d){if(Clazz.exceptionOf(d,java.io.UnsupportedEncodingException))System.out.println(d);else throw d;}return String.instantialize(a)},
"~A");c$.getUTFEncoding=$_M(c$,"getUTFEncoding",($fz=function(a){return 3<=a.length&&239==a[0]&&187==a[1]&&191==a[2]?J.io.Encoding.UTF8:4<=a.length&&0==a[0]&&0==a[1]&&254==a[2]&&255==a[3]?J.io.Encoding.UTF_32BE:4<=a.length&&255==a[0]&&254==a[1]&&0==a[2]&&0==a[3]?J.io.Encoding.UTF_32LE:2<=a.length&&255==a[0]&&254==a[1]?J.io.Encoding.UTF_16LE:2<=a.length&&254==a[0]&&255==a[1]?J.io.Encoding.UTF_16BE:J.io.Encoding.NONE},$fz.isPrivate=!0,$fz),"~A");c$.getMagic=$_M(c$,"getMagic",($fz=function(a,b){var c=
Clazz.newByteArray(b,0);a.resetStream();try{a.mark(b+1),a.read(c,0,b)}catch(d){if(!Clazz.exceptionOf(d,java.io.IOException))throw d;}try{a.reset()}catch(e){if(!Clazz.exceptionOf(e,java.io.IOException))throw e;}return c},$fz.isPrivate=!0,$fz),"java.io.InputStream,~N");c$.isCompoundDocumentS=$_M(c$,"isCompoundDocumentS",function(a){return J.io.JmolBinary.isCompoundDocumentB(J.io.JmolBinary.getMagic(a,8))},"java.io.InputStream");c$.isCompoundDocumentB=$_M(c$,"isCompoundDocumentB",function(a){return 8<=
a.length&&208==a[0]&&207==a[1]&&17==a[2]&&224==a[3]&&161==a[4]&&177==a[5]&&26==a[6]&&225==a[7]},"~A");c$.isGzipS=$_M(c$,"isGzipS",function(a){return J.io.JmolBinary.isGzipB(J.io.JmolBinary.getMagic(a,2))},"java.io.InputStream");c$.isGzipB=$_M(c$,"isGzipB",function(a){return null!=a&&2<=a.length&&31==a[0]&&139==a[1]},"~A");c$.isPickleS=$_M(c$,"isPickleS",function(a){return J.io.JmolBinary.isPickleB(J.io.JmolBinary.getMagic(a,2))},"java.io.InputStream");c$.isPickleB=$_M(c$,"isPickleB",function(a){return null!=
a&&2<=a.length&&125==a[0]&&113==a[1]},"~A");c$.isZipS=$_M(c$,"isZipS",function(a){return J.io.JmolBinary.isZipB(J.io.JmolBinary.getMagic(a,4))},"java.io.InputStream");c$.isZipB=$_M(c$,"isZipB",function(a){return 4<=a.length&&80==a[0]&&75==a[1]&&3==a[2]&&4==a[3]},"~A");c$.isPngZipStream=$_M(c$,"isPngZipStream",function(a){if(J.io.JmolBinary.isZipS(a))return!1;a=J.io.JmolBinary.getMagic(a,55);return 80==a[51]&&78==a[52]&&71==a[53]&&74==a[54]},"java.io.InputStream");c$.getZipRoot=$_M(c$,"getZipRoot",
function(a){var b=a.indexOf("|");return 0>b?a:a.substring(0,b)},"~S");c$.getStreamBytes=$_M(c$,"getStreamBytes",function(a,b){for(var c=0<b&&1024>b?b:1024,d=Clazz.newByteArray(c,0),e=Clazz.newByteArray(0>b?4096:b,0),f=0,g=0;(0>b||g<b)&&0<(f=a.read(d,0,c));)g+=f,g>e.length&&(e=JU.ArrayUtil.ensureLengthByte(e,2*g)),System.arraycopy(d,0,e,g-f,f);if(g==e.length)return e;d=Clazz.newByteArray(g,0);System.arraycopy(e,0,d,0,g);return d},"java.io.InputStream,~N");c$.getEmbeddedScript=$_M(c$,"getEmbeddedScript",
function(a){if(null==a)return a;var b=a.indexOf("**** Jmol Embedded Script ****");if(0>b)return a;var c=a.lastIndexOf("/*",b),d=a.indexOf(("*"==a.charAt(c+2)?"*":"")+"*/",b);for(0<=c&&d>=b&&(a=a.substring(b+30,d)+"\n");0<=(c=a.indexOf(" #Jmol...\x00"));)a=a.substring(0,c)+a.substring(c+10+4);J.util.Logger.debugging&&J.util.Logger.debug(a);return a},"~S");c$.getJzu=$_M(c$,"getJzu",($fz=function(){return null==J.io.JmolBinary.jzu?($t$=J.io.JmolBinary.jzu=J.api.Interface.getOptionInterface("io2.ZipUtil"),
J.io.JmolBinary.prototype.jzu=J.io.JmolBinary.jzu,$t$):J.io.JmolBinary.jzu},$fz.isPrivate=!0,$fz));c$.getZipDirectoryAsStringAndClose=$_M(c$,"getZipDirectoryAsStringAndClose",function(a){return J.io.JmolBinary.getJzu().getZipDirectoryAsStringAndClose(a)},"java.io.BufferedInputStream");c$.newGZIPInputStream=$_M(c$,"newGZIPInputStream",function(a){return J.io.JmolBinary.getJzu().newGZIPInputStream(a)},"java.io.BufferedInputStream");c$.getGzippedBytesAsString=$_M(c$,"getGzippedBytesAsString",function(a){return J.io.JmolBinary.getJzu().getGzippedBytesAsString(a)},
"~A");c$.newZipInputStream=$_M(c$,"newZipInputStream",function(a){return J.io.JmolBinary.getJzu().newZipInputStream(a)},"java.io.InputStream");c$.getZipFileContents=$_M(c$,"getZipFileContents",function(a,b,c,d){return J.io.JmolBinary.getJzu().getZipFileContents(a,b,c,d)},"java.io.BufferedInputStream,~A,~N,~B");c$.getZipDirectoryAndClose=$_M(c$,"getZipDirectoryAndClose",function(a,b){return J.io.JmolBinary.getJzu().getZipDirectoryAndClose(a,b)},"java.io.BufferedInputStream,~B");c$.getAllZipData=$_M(c$,
"getAllZipData",function(a,b,c,d,e){J.io.JmolBinary.getJzu().getAllZipData(a,b,c,d,e)},"java.io.BufferedInputStream,~A,~S,~S,java.util.Map");c$.getZipFileContentsAsBytes=$_M(c$,"getZipFileContentsAsBytes",function(a,b,c){return J.io.JmolBinary.getJzu().getZipFileContentsAsBytes(a,b,c)},"java.io.BufferedInputStream,~A,~N");c$.getStreamAsBytes=$_M(c$,"getStreamAsBytes",function(a,b){for(var c=Clazz.newByteArray(1024,0),d=null==b?Clazz.newByteArray(4096,0):null,e=0,f=0;0<(e=a.read(c,0,1024));)f+=e,null==
b?(f>=d.length&&(d=JU.ArrayUtil.ensureLengthByte(d,2*f)),System.arraycopy(c,0,d,f-e,e)):b.write(c,0,e);a.close();return null==b?JU.ArrayUtil.arrayCopyByte(d,f):f+" bytes"},"java.io.BufferedInputStream,J.io.JmolOutputChannel");c$.isBase64=$_M(c$,"isBase64",function(a){return 0==a.indexOf(";base64,")},"JU.SB");c$.getBytesFromSB=$_M(c$,"getBytesFromSB",function(a){return J.io.JmolBinary.isBase64(a)?J.io.Base64.decodeBase64(a.substring(8)):a.toBytes(0,-1)},"JU.SB");c$.getBISForStringXBuilder=$_M(c$,"getBISForStringXBuilder",
function(a){return new java.io.BufferedInputStream(new java.io.ByteArrayInputStream(J.io.JmolBinary.getBytesFromSB(a)))},"JU.SB");c$.getBufferedReaderForString=$_M(c$,"getBufferedReaderForString",function(a){return new java.io.BufferedReader(new java.io.StringReader(a))},"~S");c$.getCachedPngjBytes=$_M(c$,"getCachedPngjBytes",function(a,b){return 0>b.indexOf(".png")?null:J.io.JmolBinary.getJzu().getCachedPngjBytes(a,b)},"J.viewer.FileManager,~S");c$.cachePngjFile=$_M(c$,"cachePngjFile",function(a,
b){return J.io.JmolBinary.getJzu().cachePngjFile(a,b)},"J.viewer.FileManager,~A");c$.getAtomSetCollectionOrBufferedReaderFromZip=$_M(c$,"getAtomSetCollectionOrBufferedReaderFromZip",function(a,b,c,d,e,f){return J.io.JmolBinary.getJzu().getAtomSetCollectionOrBufferedReaderFromZip(a,b,c,d,e,1,f)},"J.api.JmolAdapter,java.io.InputStream,~S,~A,java.util.Map,~B");c$.spartanFileList=$_M(c$,"spartanFileList",function(a,b){return J.io.JmolBinary.getJzu().spartanFileList(a,b)},"~S,~S");c$.getFileReferences=
$_M(c$,"getFileReferences",function(a,b){for(var c=0;c<J.viewer.FileManager.scriptFilePrefixes.length;c++)for(var d=J.viewer.FileManager.scriptFilePrefixes[c],e=-1;0<=(e=a.indexOf(d,e+1));){var f=J.util.Parser.getQuotedStringAt(a,e);0<=f.indexOf("::")&&(f=J.util.Txt.split(f,"::")[1]);b.addLast(f)}},"~S,JU.List");c$.checkPngZipStream=$_M(c$,"checkPngZipStream",function(a){if(!J.io.JmolBinary.isPngZipStream(a))return a;var b=null;a.mark(75);try{b=J.io.JmolBinary.getStreamBytes(a,74);a.reset();for(var c=
0,d=64,e=1;54<--d;e*=10)c+=(b[d]-48)*e;for(var f=0,d=74,e=1;64<--d;e*=10)f+=(b[d]-48)*e;for(;0<c;)c-=a.skip(c);b=J.io.JmolBinary.getStreamBytes(a,f);a.close()}catch(g){b=Clazz.newByteArray(0,0)}return new java.io.BufferedInputStream(new java.io.ByteArrayInputStream(b))},"java.io.BufferedInputStream");c$.getBufferedReader=$_M(c$,"getBufferedReader",function(a,b){if(J.io.JmolBinary.getUTFEncodingForStream(a)===J.io.Encoding.NONE)return new java.io.BufferedReader(new java.io.InputStreamReader(a,null==
b?"UTF-8":b));var c=J.io.JmolBinary.getStreamBytes(a,-1);a.close();return J.io.JmolBinary.getBufferedReaderForString(null==b?J.io.JmolBinary.fixUTF(c):String.instantialize(c,b))},"java.io.BufferedInputStream,~S");c$.getManifestScriptPath=$_M(c$,"getManifestScriptPath",function(a){if(0<=a.indexOf("$SCRIPT_PATH$"))return"";var b=0<=a.indexOf("\n")?"\n":"\r";if(0<=a.indexOf(".spt")){a=J.util.Txt.split(a,b);for(b=a.length;0<=--b;)if(0<=a[b].indexOf(".spt"))return"|"+J.util.Txt.trim(a[b],"\r\n \t")}return null},
"~S");c$.getBinaryType=$_M(c$,"getBinaryType",function(a){if(null==a)return null;var b=a.lastIndexOf(".");if(0>b||0>(b=";pse=PyMOL;".indexOf(";"+a.substring(b+1)+"=")))return null;b=";pse=PyMOL;".indexOf("=",b);a=";pse=PyMOL;".substring(b+1);return a.substring(0,a.indexOf(";"))},"~S");c$.checkBinaryType=$_M(c$,"checkBinaryType",function(a){return 0<=";pse=PyMOL;".indexOf("="+a+";")},"~S");c$.StreamToString=$_M(c$,"StreamToString",function(a){var b=Array(1);try{J.io.JmolBinary.readAll(J.io.JmolBinary.getBufferedReader(a,
"UTF-8"),-1,!0,b,0)}catch(c){if(!Clazz.exceptionOf(c,java.io.IOException))throw c;}return b[0]},"java.io.BufferedInputStream");c$.readAll=$_M(c$,"readAll",function(a,b,c,d,e){try{var f=JU.SB.newN(8192),g;if(0>b){if(g=a.readLine(),c||null!=g&&0>g.indexOf("\x00")&&(4!=g.length||65533!=g.charCodeAt(0)||1!=g.indexOf("PNG")))for(f.append(g).appendC("\n");null!=(g=a.readLine());)f.append(g).appendC("\n")}else{c=0;for(var h;c<b&&null!=(g=a.readLine());){if(b-c<(h=g.length)+1)g=g.substring(0,b-c-1);f.append(g).appendC("\n");
c+=h+1}}a.close();d[e]=f.toString();return!0}catch(k){if(Clazz.exceptionOf(k,Exception))return d[e]=k.toString(),!1;throw k;}},"java.io.BufferedReader,~N,~B,~A,~N");c$.addZipEntry=$_M(c$,"addZipEntry",function(a,b){J.io.JmolBinary.getJzu().addZipEntry(a,b)},"~O,~S");c$.closeZipEntry=$_M(c$,"closeZipEntry",function(a){J.io.JmolBinary.getJzu().closeZipEntry(a)},"~O");c$.getZipOutputStream=$_M(c$,"getZipOutputStream",function(a){return J.io.JmolBinary.getJzu().getZipOutputStream(a)},"~O");c$.getCrcValue=
$_M(c$,"getCrcValue",function(a){return J.io.JmolBinary.getJzu().getCrcValue(a)},"~A");Clazz.defineStatics(c$,"JPEG_CONTINUE_STRING"," #Jmol...\x00","PMESH_BINARY_MAGIC_NUMBER","PM\u0001\x00","DELPHI_BINARY_MAGIC_NUMBER","\u0014\x00\x00\x00","jzu",null)}),Clazz.declarePackage("J.shape"),Clazz.load(null,"J.shape.Shape",["J.constant.EnumPalette","J.util.C","$.Logger","J.viewer.JC"],function(){c$=Clazz.decorateAsClass(function(){this.gdata=this.modelSet=this.viewer=null;this.translucentLevel=this.myVisibilityFlag=
this.shapeID=0;this.translucentAllowed=!0;this.isBioShape=!1;this.bsColixSet=this.bsSizeSet=null;Clazz.instantialize(this,arguments)},J.shape,"Shape");$_M(c$,"getViewer",function(){return this.viewer});$_M(c$,"initializeShape",function(a,b,c,d){this.viewer=a;this.gdata=b;this.shapeID=d;this.myVisibilityFlag=J.viewer.JC.getShapeVisibilityFlag(d);this.setModelSet(c);this.initShape()},"J.viewer.Viewer,J.util.GData,J.modelset.ModelSet,~N");$_M(c$,"getSize",function(){return 0},"~N");$_M(c$,"getSizeG",
function(){return 0},"J.modelset.Group");$_M(c$,"setModelSet",function(a){this.modelSet=a;this.initModelSet()},"J.modelset.ModelSet");$_M(c$,"initModelSet",function(){});$_M(c$,"initShape",function(){});$_M(c$,"merge",function(){},"J.shape.Shape");$_M(c$,"setShapeSizeRD",function(a,b,c){null==b?this.setSize(a,c):this.setSizeRD(b,c)},"~N,J.atomdata.RadiusData,JU.BS");$_M(c$,"setSize",function(){},"~N,JU.BS");$_M(c$,"setSizeRD",function(){},"J.atomdata.RadiusData,JU.BS");$_M(c$,"getPropertyData",function(){return!1},
"~S,~A");$_M(c$,"setPropS",function(a,b,c){if("setProperties"===a)for(null==c&&(c=this.viewer.getSelectionSet(!1));0<b.size();)a=b.remove(0),this.setProperty(a[0].intern(),a[1],c);else"translucentLevel"===a?this.translucentLevel=b.floatValue():"refreshTrajectories"!==a&&J.util.Logger.warn("unassigned "+J.viewer.JC.shapeClassBases[this.shapeID]+" + shape setProperty:"+a+":"+b)},"~S,~O,JU.BS");$_M(c$,"getProperty",function(){return null},"~S,~N");$_M(c$,"getIndexFromName",function(){return-1},"~S");
$_M(c$,"wasClicked",function(){return!1},"~N,~N");$_M(c$,"findNearestAtomIndex",function(){},"~N,~N,~A,JU.BS");$_M(c$,"checkBoundsMinMax",function(){},"JU.P3,JU.P3");$_M(c$,"setModelClickability",function(){});$_M(c$,"checkObjectClicked",function(){return null},"~N,~N,~N,JU.BS,~B");$_M(c$,"checkObjectHovered",function(){return!1},"~N,~N,JU.BS");$_M(c$,"checkObjectDragged",function(){return!1},"~N,~N,~N,~N,~N,JU.BS");$_M(c$,"coordinateInRange",function(a,b,c,d,e){this.viewer.transformPtScr(c,e);a=
(a-e.x)*(a-e.x)+(b-e.y)*(b-e.y);return a<d?a:-1},"~N,~N,JU.P3,~N,JU.P3i");$_M(c$,"getColixI",function(a,b,c){return this.getColixA(a,b,this.modelSet.atoms[c])},"~N,~N,~N");$_M(c$,"getColixA",function(a,b,c){return 2==a?this.viewer.getColixAtomPalette(c,b):a},"~N,~N,J.modelset.Atom");$_M(c$,"getColixB",function(a,b,c){return 2==a?this.viewer.getColixBondPalette(c,b):a},"~N,~N,J.modelset.Bond");$_M(c$,"getShapeDetail",function(){return null});$_M(c$,"setVisibilityFlags",function(){},"JU.BS");c$.getColix=
$_M(c$,"getColix",function(a,b,c){return J.util.C.getColixInherited(null==a||b>=a.length?0:a[b],c.getColix())},"~A,~N,J.modelset.Atom");c$.getFontCommand=$_M(c$,"getFontCommand",function(a,b){return null==b?"":"font "+a+" "+b.getInfo()},"~S,J.util.JmolFont");c$.getColorCommandUnk=$_M(c$,"getColorCommandUnk",function(a,b,c){return J.shape.Shape.getColorCommand(a,J.constant.EnumPalette.UNKNOWN.id,b,c)},"~S,~N,~B");c$.getColorCommand=$_M(c$,"getColorCommand",function(a,b,c,d){if(b==J.constant.EnumPalette.UNKNOWN.id&&
0==c)return"";b=b==J.constant.EnumPalette.UNKNOWN.id&&0==c?"":(d?J.shape.Shape.getTranslucentLabel(c)+" ":"")+(b!=J.constant.EnumPalette.UNKNOWN.id&&!J.constant.EnumPalette.isPaletteVariable(b)?J.constant.EnumPalette.getPaletteName(b):J.shape.Shape.encodeColor(c));return"color "+a+" "+b},"~S,~N,~N,~B");c$.encodeColor=$_M(c$,"encodeColor",function(a){return J.util.C.isColixColorInherited(a)?"none":J.util.C.getHexCode(a)},"~N");c$.getTranslucentLabel=$_M(c$,"getTranslucentLabel",function(a){return J.util.C.isColixTranslucent(a)?
"translucent "+J.util.C.getColixTranslucencyFractional(a):"opaque"},"~N");c$.appendCmd=$_M(c$,"appendCmd",function(a,b){0!=b.length&&a.append("  ").append(b).append(";\n")},"JU.SB,~S");Clazz.defineStatics(c$,"RADIUS_MAX",4)}),Clazz.declarePackage("J.api"),Clazz.declareInterface(J.api,"BytePoster"),Clazz.declarePackage("J.viewer"),Clazz.load(["J.api.BytePoster","java.util.Hashtable"],"J.viewer.FileManager","java.io.BufferedInputStream $.ByteArrayInputStream java.lang.Boolean java.net.URL $.URLEncoder JU.ArrayUtil $.List $.SB J.api.Interface J.io.Base64 $.FileReader $.JmolBinary J.util.Escape $.Logger $.Txt J.viewer.DataManager $.Viewer".split(" "),
function(){c$=Clazz.decorateAsClass(function(){this.viewer=null;this.pathForAllFiles="";this.nameAsGiven="zapped";this.cache=this.spardirCache=this.pngjCache=this.appletProxy=this.appletDocumentBaseURL=this.fileName=this.fullPathName=null;Clazz.instantialize(this,arguments)},J.viewer,"FileManager",null,J.api.BytePoster);Clazz.prepareFields(c$,function(){this.cache=new java.util.Hashtable});Clazz.makeConstructor(c$,function(a){this.viewer=a;this.clear()},"J.viewer.Viewer");$_M(c$,"clear",function(){this.fullPathName=
this.fileName=this.nameAsGiven=this.viewer.getZapName();this.spardirCache=null});$_M(c$,"setLoadState",($fz=function(a){this.viewer.getPreserveState()&&a.put("loadState",this.viewer.getLoadState(a))},$fz.isPrivate=!0,$fz),"java.util.Map");$_M(c$,"getPathForAllFiles",function(){return this.pathForAllFiles});$_M(c$,"setPathForAllFiles",function(a){0<a.length&&(!a.endsWith("/")&&!a.endsWith("|"))&&(a+="/");return this.pathForAllFiles=a},"~S");$_M(c$,"setFileInfo",function(a){this.fullPathName=a[0];this.fileName=
a[1];this.nameAsGiven=a[2]},"~A");$_M(c$,"getFileInfo",function(){return[this.fullPathName,this.fileName,this.nameAsGiven]});$_M(c$,"getFullPathName",function(){return null!=this.fullPathName?this.fullPathName:this.nameAsGiven});$_M(c$,"getFileName",function(){return null!=this.fileName?this.fileName:this.nameAsGiven});$_M(c$,"getAppletDocumentBase",function(){return null==this.appletDocumentBaseURL?"":this.appletDocumentBaseURL.toString()});$_M(c$,"setAppletContext",function(a){try{this.appletDocumentBaseURL=
0==a.length?null:new java.net.URL(Clazz.castNullAs("java.net.URL"),a,null)}catch(b){if(!Clazz.exceptionOf(b,java.net.MalformedURLException))throw b;}},"~S");$_M(c$,"setAppletProxy",function(a){this.appletProxy=null==a||0==a.length?null:a},"~S");$_M(c$,"createAtomSetCollectionFromFile",function(a,b,c){null==b.get("atomDataOnly")&&this.setLoadState(b);a=this.viewer.resolveDatabaseFormat(a);var d=a.indexOf("::"),e=0<=d?a.substring(d+2):a,d=0<=d?a.substring(0,d):null;J.util.Logger.info("\nFileManager.getAtomSetCollectionFromFile("+
e+")"+(a.equals(e)?"":" //"+a));var f=this.classifyName(e,!0);if(1==f.length)return f[0];a=f[0];f=f[1];b.put("fullPathName",(null==d?"":d+"::")+a.$replace("\\","/"));this.viewer.getBoolean(603979880)&&this.viewer.getBoolean(603979824)&&this.viewer.scriptStatus("Requesting "+a);b=new J.io.FileReader(this,this.viewer,f,a,e,d,null,b,c);b.run();return b.getAtomSetCollection()},"~S,java.util.Map,~B");$_M(c$,"createAtomSetCollectionFromFiles",function(a,b,c){this.setLoadState(b);for(var d=Array(a.length),
e=Array(a.length),f=Array(a.length),g=0;g<a.length;g++){var h=a[g].indexOf("::"),k=0<=h?a[g].substring(h+2):a[g],h=0<=h?a[g].substring(0,h):null,l=this.classifyName(k,!0);if(1==l.length)return l[0];d[g]=l[0];a[g]=l[0].$replace("\\","/");f[g]=h;e[g]=k}b.put("fullPathNames",d);b.put("fileTypes",f);a=this.newFilesReader(d,e,f,null,b,c);a.run();return a.getAtomSetCollection()},"~A,java.util.Map,~B");$_M(c$,"createAtomSetCollectionFromString",function(a,b,c,d,e){e||J.viewer.DataManager.getInlineData(b,
a,d,this.viewer.getDefaultLoadFilter());this.setLoadState(c);b=0<=a.indexOf("Viewer.AddHydrogens")?this.getFileInfo():null;c=new J.io.FileReader(this,this.viewer,"string","string","string",null,J.io.JmolBinary.getBufferedReaderForString(a),c,d);c.run();null!=b&&this.setFileInfo(b);!d&&!Clazz.instanceOf(c.getAtomSetCollection(),String)&&(this.viewer.zap(!1,!0,!1),this.fullPathName=this.fileName="5\n\nC 0 0 0\nH .63 .63 .63\nH -.63 -.63 .63\nH -.63 .63 -.63\nH .63 -.63 -.63"===a?"Jmol Model Kit":"string");
return c.getAtomSetCollection()},"~S,JU.SB,java.util.Map,~B,~B");$_M(c$,"createAtomSeCollectionFromStrings",function(a,b,c,d){if(!c.containsKey("isData")){var e='"'+this.viewer.getDataSeparator()+'"',f='"'+(d?"append":"model")+' inline"',g=new JU.SB;g.append('set dataSeparator "~~~next file~~~";\ndata ').append(f);for(var h=0;h<a.length;h++)0<h&&g.append("~~~next file~~~"),g.append(a[h]);g.append("end ").append(f).append(";set dataSeparator ").append(e);b.appendSB(g)}this.setLoadState(c);J.util.Logger.info("FileManager.getAtomSetCollectionFromStrings(string[])");
b=Array(a.length);e=Array(a.length);for(h=0;h<a.length;h++)b[h]="string["+h+"]",e[h]=this.newDataReader(a[h]);a=this.newFilesReader(b,b,null,e,c,d);a.run();return a.getAtomSetCollection()},"~A,JU.SB,java.util.Map,~B");$_M(c$,"createAtomSeCollectionFromArrayData",function(a,b,c){J.util.Logger.info("FileManager.getAtomSetCollectionFromArrayData(Vector)");for(var d=a.size(),e=Array(d),f=Array(d),g=0;g<d;g++)e[g]="String["+g+"]",f[g]=this.newDataReader(a.get(g));a=this.newFilesReader(e,e,null,f,b,c);
a.run();return a.getAtomSetCollection()},"JU.List,java.util.Map,~B");$_M(c$,"newFilesReader",($fz=function(a,b,c,d,e,f){var g=J.api.Interface.getOptionInterface("io2.FilesReader");g.set(this,this.viewer,a,b,c,d,e,f);return g},$fz.isPrivate=!0,$fz),"~A,~A,~A,~A,java.util.Map,~B");$_M(c$,"newDataReader",($fz=function(a){var b=Clazz.instanceOf(a,String)?"String":J.util.Escape.isAS(a)?"Array":Clazz.instanceOf(a,JU.List)?"List":null;return null==b?null:J.api.Interface.getOptionInterface("io2."+b+"DataReader").setData(a)},
$fz.isPrivate=!0,$fz),"~O");$_M(c$,"createAtomSetCollectionFromDOM",function(a,b){var c=J.api.Interface.getOptionInterface("io2.DOMReadaer");c.set(this,this.viewer,a,b);c.run();return c.getAtomSetCollection()},"~O,java.util.Map");$_M(c$,"createAtomSetCollectionFromReader",function(a,b,c,d){a=new J.io.FileReader(this,this.viewer,b,a,b,null,c,d,!1);a.run();return a.getAtomSetCollection()},"~S,~S,~O,java.util.Map");$_M(c$,"getBufferedInputStream",function(a){a=this.getBufferedReaderOrErrorMessageFromName(a,
Array(2),!0,!0);return Clazz.instanceOf(a,java.io.BufferedInputStream)?a:null},"~S");$_M(c$,"getBufferedInputStreamOrErrorMessageFromName",function(a,b,c,d,e,f){var g=null;null==e&&(g=null==b||null==this.pngjCache?null:J.io.JmolBinary.getCachedPngjBytes(this,b),null==g&&(g=this.cacheGet(a,!0)));var h=b=null;try{if(null==g){var k=0<=a.indexOf("?POST?_PNGJBIN_"),l=k||0<=a.indexOf("?POST?_PNGJ_");if(0<a.indexOf("?POST?_PNG_")||l){var m=Array(1),n=this.viewer.getImageAsBytes(l?"PNGJ":"PNG",0,0,-1,m);
if(null!=m[0])return m[0];k?(e=n,a=J.util.Txt.simpleReplace(a,"?_","=_")):a=(new JU.SB).append(a).append("=").appendSB(J.io.Base64.getBase64(n)).toString()}var q=J.viewer.FileManager.urlTypeIndex(a),k=0<=q,l=null;if(k&&0<=(q=a.indexOf("?POST?")))l=a.substring(q+6),a=a.substring(0,q);var p=null!=this.appletDocumentBaseURL;0<=a.indexOf(".png")&&(null==this.pngjCache&&this.viewer.cachePngFiles())&&J.io.JmolBinary.cachePngjFile(this,null);if(p||k){p&&(k&&null!=this.appletProxy)&&(a=this.appletProxy+"?url="+
this.urlEncode(a));var r=p?new java.net.URL(this.appletDocumentBaseURL,a,null):new java.net.URL(Clazz.castNullAs("java.net.URL"),a,null);if(d)return null;a=r.toString();c&&0>a.toLowerCase().indexOf("password")&&J.util.Logger.info("FileManager opening 1 "+a);h=this.viewer.apiPlatform.getBufferedURLInputStream(r,e,l);if(Clazz.instanceOf(h,JU.SB)){a=h;if(f&&!J.io.JmolBinary.isBase64(a))return J.io.JmolBinary.getBufferedReaderForString(a.toString());h=J.io.JmolBinary.getBISForStringXBuilder(a)}else J.util.Escape.isAB(h)&&
(h=new java.io.BufferedInputStream(new java.io.ByteArrayInputStream(h)))}else if(null==(g=this.cacheGet(a,!0)))c&&J.util.Logger.info("FileManager opening 2 "+a),h=this.viewer.apiPlatform.getBufferedFileInputStream(a);if(Clazz.instanceOf(h,String))return h}b=null==g?h:new java.io.BufferedInputStream(new java.io.ByteArrayInputStream(g));d&&(b.close(),b=null);return b}catch(s){if(Clazz.exceptionOf(s,Exception))try{null!=b&&b.close()}catch(t){if(!Clazz.exceptionOf(t,java.io.IOException))throw t;}else throw s;
}return""+s},"~S,~S,~B,~B,~A,~B");$_M(c$,"urlEncode",($fz=function(a){try{return java.net.URLEncoder.encode(a,"utf-8")}catch(b){if(Clazz.exceptionOf(b,java.io.UnsupportedEncodingException))return a;throw b;}},$fz.isPrivate=!0,$fz),"~S");$_M(c$,"getEmbeddedFileState",function(a){var b=null,b=this.getZipDirectory(a,!1);if(0==b.length)return a=this.viewer.getFileAsString4(a,-1,!1,!0),0>a.indexOf("**** Jmol Embedded Script ****")?"":J.io.JmolBinary.getEmbeddedScript(a);for(var c=0;c<b.length;c++)if(0<=
b[c].indexOf(".spt"))return a=[a+"|"+b[c],null],this.getFileDataOrErrorAsString(a,-1,!1,!1),a[1];return""},"~S");$_M(c$,"getFullPathNameOrError",function(a){var b=this.classifyName(a,!0);if(null==b||null==b[0]||2>b.length)return[null,"cannot read file name: "+a];a=b[0];b=b[0].$replace("\\","/");a=J.io.JmolBinary.getZipRoot(a);a=this.getBufferedInputStreamOrErrorMessageFromName(a,b,!1,!0,null,!1);return[b,Clazz.instanceOf(a,String)?a:null]},"~S");$_M(c$,"getBufferedReaderOrErrorMessageFromName",function(a,
b,c,d){var e=this.cacheGet(a,!1),f=J.util.Escape.isAB(e),g=f?e:null;if(a.startsWith("cache://")){if(null==e)return"cannot read "+a;if(f)g=e;else return J.io.JmolBinary.getBufferedReaderForString(e)}e=this.classifyName(a,!0);if(null==e)return"cannot read file name: "+a;null!=b&&(b[0]=e[0].$replace("\\","/"));return this.getUnzippedReaderOrStreamFromName(e[0],g,!1,c,!1,d,null)},"~S,~A,~B,~B");$_M(c$,"getUnzippedReaderOrStreamFromName",function(a,b,c,d,e,f,g){var h=null;f=null==b&&f?this.getSpartanFileList(a):
null;var k=a;if(null!=f){if(e)return f;if(null!=f[2]){c=f[1];d=new java.util.Hashtable;if(3==f.length){var l=this.getObjectAsSections(f[2],c,d);d.put("OUTPUT",l);f=J.io.JmolBinary.spartanFileList(a,d.get(l));3==f.length&&(l=this.getObjectAsSections(f[2],c,d),d.put("OUTPUT",l),f=J.io.JmolBinary.spartanFileList(f[1],d.get(l)))}h=new JU.SB;null!=d.get("OUTPUT")&&h.append(d.get(d.get("OUTPUT")));for(var m=2;m<f.length;m++)a=f[m],a=this.getObjectAsSections(a,c,d),J.util.Logger.info("reading "+a),l=d.get(a),
h.append(l);l=h.toString();null==this.spardirCache&&(this.spardirCache=new java.util.Hashtable);this.spardirCache.put(k.$replace("\\","/"),l.getBytes());return J.io.JmolBinary.getBufferedReaderForString(l)}}null==b&&null!=this.pngjCache&&(b=J.io.JmolBinary.getCachedPngjBytes(this,a),null!=b&&null!=g&&g.put("sourcePNGJ",Boolean.TRUE));f=a;0<=a.indexOf("|")&&(h=J.util.Txt.split(a,"|"),null==b&&J.util.Logger.info("FileManager opening 3 "+a),a=h[0]);a=null==b?this.getBufferedInputStreamOrErrorMessageFromName(a,
f,!0,!1,null,!d):new java.io.BufferedInputStream(new java.io.ByteArrayInputStream(b));try{if(Clazz.instanceOf(a,String)||Clazz.instanceOf(a,java.io.BufferedReader))return a;if(J.io.JmolBinary.isGzipS(a)){do a=new java.io.BufferedInputStream(J.io.JmolBinary.newGZIPInputStream(a));while(J.io.JmolBinary.isGzipS(a))}if(J.io.JmolBinary.isCompoundDocumentS(a))return m=J.api.Interface.getOptionInterface("io2.CompoundDocument"),m.setStream(a,!0),J.io.JmolBinary.getBufferedReaderForString(m.getAllDataFiles("Molecule",
"Input").toString());if(J.io.JmolBinary.isPickleS(a))return a;a=J.io.JmolBinary.checkPngZipStream(a);if(J.io.JmolBinary.isZipS(a)){if(c)return J.io.JmolBinary.newZipInputStream(a);if(d)return J.io.JmolBinary.getZipFileContents(a,h,1,!0);l=J.io.JmolBinary.getZipFileContents(a,h,1,!1);a.close();return J.io.JmolBinary.getBufferedReaderForString(l)}return d?a:J.io.JmolBinary.getBufferedReader(a,null)}catch(n){if(Clazz.exceptionOf(n,Exception))return n.toString();throw n;}},"~S,~A,~B,~B,~B,~B,java.util.Map");
$_M(c$,"getSpartanFileList",($fz=function(a){if(a.endsWith(".spt"))return[null,null,null];if(a.endsWith(".spardir.zip"))return["SpartanSmol","Directory Entry ",a+"|output"];a=a.$replace("\\","/");if(!a.endsWith(".spardir")&&0>a.indexOf(".spardir/"))return null;var b=a.lastIndexOf(".spardir");return 0>b?null:a.lastIndexOf("/")>b?["SpartanSmol","Directory Entry ",a+"/input",a+"/archive",a+"/Molecule:asBinaryString",a+"/proparc"]:["SpartanSmol","Directory Entry ",a+"/output"]},$fz.isPrivate=!0,$fz),
"~S");$_M(c$,"getObjectAsSections",($fz=function(a,b,c){if(null==a)return null;var d=null,e=!1,f=a.$replace("\\","/");0<=a.indexOf(":asBinaryString")&&(e=!0,a=a.substring(0,a.indexOf(":asBinaryString")));var g=null;if(c.containsKey(f))return f;if(0<=a.indexOf("#JMOL_MODEL "))return c.put(f,f+"\n"),f;var h=a;0<=a.indexOf("|")&&(d=J.util.Txt.split(a,"|"),a=d[0]);var k=null;try{var l=this.getBufferedInputStreamOrErrorMessageFromName(a,h,!1,!1,null,!1);if(Clazz.instanceOf(l,String))return c.put(f,l+"\n"),
f;k=l;if(J.io.JmolBinary.isCompoundDocumentS(k)){var m=J.api.Interface.getOptionInterface("io2.CompoundDocument");m.setStream(k,!0);m.getAllDataMapped(a.$replace("\\","/"),"Molecule",c)}else if(J.io.JmolBinary.isZipS(k))J.io.JmolBinary.getAllZipData(k,d,a.$replace("\\","/"),"Molecule",c);else{if(e){var n=J.api.Interface.getOptionInterface("io2.BinaryDocument");n.setStream(k,!1);g=new JU.SB;null!=b&&g.append("BEGIN Directory Entry "+f+"\n");try{for(;;)g.append(Integer.toHexString(n.readByte()&255)).appendC(" ")}catch(q){if(Clazz.exceptionOf(q,
Exception))g.appendC("\n");else throw q;}}else{var p=J.io.JmolBinary.getBufferedReader(J.io.JmolBinary.isGzipS(k)?new java.io.BufferedInputStream(J.io.JmolBinary.newGZIPInputStream(k)):k,null),r,g=new JU.SB;for(null!=b&&g.append("BEGIN Directory Entry "+f+"\n");null!=(r=p.readLine());)g.append(r),g.appendC("\n");p.close()}null!=b&&g.append("\nEND Directory Entry "+f+"\n");c.put(f,g.toString())}}catch(s){if(Clazz.exceptionOf(s,Exception))c.put(f,s.toString());else throw s;}if(null!=k)try{k.close()}catch(t){if(!Clazz.exceptionOf(t,
Exception))throw t;}c.containsKey(f)||c.put(f,"FILE NOT FOUND: "+f+"\n");return f},$fz.isPrivate=!0,$fz),"~S,~S,java.util.Map");$_M(c$,"getZipDirectory",function(a,b){var c=this.getBufferedInputStreamOrErrorMessageFromName(a,a,!1,!1,null,!1);return J.io.JmolBinary.getZipDirectoryAndClose(c,b)},"~S,~B");$_M(c$,"getFileAsBytes",function(a,b,c){if(null==a)return null;var d=a,e=null;0<=a.indexOf("|")&&(e=J.util.Txt.split(a,"|"),a=e[0],c=!0);a=this.getBufferedInputStreamOrErrorMessageFromName(a,d,!1,!1,
null,!1);if(Clazz.instanceOf(a,String))return"Error:"+a;try{var f=null!=b||!c||null==e||1>=e.length||!J.io.JmolBinary.isZipS(a)&&!J.io.JmolBinary.isPngZipStream(a)?J.io.JmolBinary.getStreamAsBytes(a,b):J.io.JmolBinary.getZipFileContentsAsBytes(a,e,1);a.close();return f}catch(g){if(Clazz.exceptionOf(g,Exception))return g.toString();throw g;}},"~S,J.io.JmolOutputChannel,~B");$_M(c$,"getFileDataOrErrorAsString",function(a,b,c,d){a[1]="";var e=a[0];if(null==e)return!1;c=this.getBufferedReaderOrErrorMessageFromName(e,
a,!1,c);if(Clazz.instanceOf(c,String))return a[1]=c,!1;try{return J.io.JmolBinary.readAll(c,b,d,a,1)}catch(f){if(Clazz.exceptionOf(f,Exception))return!1;throw f;}},"~A,~N,~B,~B");$_M(c$,"loadImage",function(a,b){for(var c=null,d=null,e="";null!=a;){e=this.classifyName(a,!0);if(null==e){e="cannot read file name: "+a;break}var f=this.viewer.apiPlatform,e=e[0].$replace("\\","/");if(0<e.indexOf("|")){d=this.getFileAsBytes(e,null,!0);if(!J.util.Escape.isAB(d)){e=""+d;break}c=this.viewer.isJS?d:f.createImage(d)}else if(!this.viewer.isJS)if(0<=
J.viewer.FileManager.urlTypeIndex(e))try{c=f.createImage(new java.net.URL(Clazz.castNullAs("java.net.URL"),e,null))}catch(g){if(Clazz.exceptionOf(g,Exception)){e="bad URL: "+e;break}else throw g;}else c=f.createImage(e);d=[b,e];try{if(!f.waitForDisplay(d,c)){c=null;break}return}catch(h){if(Clazz.exceptionOf(h,Exception)){System.out.println(h.toString());e=h.toString()+" opening 4 "+e;c=null;break}else throw h;}}this.viewer.loadImageData(c,e,b,null)},"~S,~S");c$.urlTypeIndex=$_M(c$,"urlTypeIndex",
function(a){for(var b=0;b<J.viewer.FileManager.urlPrefixes.length;++b)if(a.startsWith(J.viewer.FileManager.urlPrefixes[b]))return b;return-1},"~S");c$.isLocal=$_M(c$,"isLocal",function(a){if(null==a)return!1;a=J.viewer.FileManager.urlTypeIndex(a);return 0>a||3==a},"~S");$_M(c$,"classifyName",function(a,b){if(null==a)return[null];var c=0<this.pathForAllFiles.length;if(a.startsWith("?")){if(null==(a=this.viewer.dialogAsk("Load",a.substring(1))))return[b?"#CANCELED#":null];c=!1}var d=null,e=null,f=null;
if(a.startsWith("cache://"))return f=Array(3),f[0]=f[2]=a,f[1]=J.viewer.FileManager.stripPath(f[0]),f;a=this.viewer.resolveDatabaseFormat(a);0>a.indexOf(":")&&0!=a.indexOf("/")&&(a=J.viewer.FileManager.addDirectory(this.viewer.getDefaultDirectory(),a));if(null!=this.appletDocumentBaseURL)try{if(1==a.indexOf(":\\")||1==a.indexOf(":/"))a="file:/"+a;e=new java.net.URL(this.appletDocumentBaseURL,a,null)}catch(g){if(Clazz.exceptionOf(g,java.net.MalformedURLException))return[b?g.toString():null];throw g;
}else if(0<=J.viewer.FileManager.urlTypeIndex(a)||this.viewer.haveAccess(J.viewer.Viewer.ACCESS.NONE)||this.viewer.haveAccess(J.viewer.Viewer.ACCESS.READSPT)&&!a.endsWith(".spt")&&!a.endsWith("/"))try{e=new java.net.URL(Clazz.castNullAs("java.net.URL"),a,null)}catch(h){if(Clazz.exceptionOf(h,java.net.MalformedURLException))return[b?h.toString():null];throw h;}else d=this.viewer.apiPlatform.newFile(a),f=[d.getAbsolutePath(),d.getName(),"file:/"+d.getAbsolutePath().$replace("\\","/")];null!=e&&(f=Array(3),
f[0]=f[2]=e.toString(),f[1]=J.viewer.FileManager.stripPath(f[0]));c&&(c=f[0],f[0]=this.pathForAllFiles+f[1],J.util.Logger.info("FileManager substituting "+c+" --\x3e "+f[0]));if(b&&(null!=d||3==J.viewer.FileManager.urlTypeIndex(f[0])))d=null==d?J.util.Txt.trim(f[0].substring(5),"/"):f[0],c=d.length-f[1].length-1,0<c&&(d=d.substring(0,c),J.viewer.FileManager.setLocalPath(this.viewer,d,!0));return f},"~S,~B");c$.addDirectory=$_M(c$,"addDirectory",($fz=function(a,b){if(0==a.length)return b;var c=0<b.length?
b.charAt(0):" ",d=a.toLowerCase();if((d.endsWith(".zip")||d.endsWith(".tar"))&&"|"!=c&&"/"!=c)a+="|";return a+("/"==c||"/"==c||"|"==(c=a.charAt(a.length-1))||"/"==c?"":"/")+b},$fz.isPrivate=!0,$fz),"~S,~S");$_M(c$,"getDefaultDirectory",function(a){a=this.classifyName(a,!0);if(null==a)return"";a=J.viewer.FileManager.fixPath(a[0]);return null==a?"":a.substring(0,a.lastIndexOf("/"))},"~S");c$.fixPath=$_M(c$,"fixPath",($fz=function(a){a=a.$replace("\\","/");a=J.util.Txt.simpleReplace(a,"/./","/");var b=
a.lastIndexOf("//")+1;1>b&&(b=a.indexOf(":/")+1);1>b&&(b=a.indexOf("/"));if(0>b)return null;var c=a.substring(0,b);for(a=a.substring(b);0<=(b=a.lastIndexOf("/../"));){var d=a.substring(0,b).lastIndexOf("/");if(0>d)return J.util.Txt.simpleReplace(c+a,"/../","/");a=a.substring(0,d)+a.substring(b+3)}0==a.length&&(a="/");return c+a},$fz.isPrivate=!0,$fz),"~S");$_M(c$,"getFilePath",function(a,b,c){a=this.classifyName(a,!1);return null==a||1==a.length?"":c?a[1]:b?a[2]:null==a[0]?"":a[0].$replace("\\","/")},
"~S,~B,~B");$_M(c$,"getLocalUrl",function(a){a=this.viewer.apiPlatform.newFile(a);if(a.getName().startsWith("="))return a.getName();a=a.getAbsolutePath().$replace("\\","/");for(var b=0;b<J.viewer.FileManager.urlPrefixPairs.length;b++)if(0==a.indexOf(J.viewer.FileManager.urlPrefixPairs[b]))return null;for(b=0;b<J.viewer.FileManager.urlPrefixPairs.length;b+=2)if(0<a.indexOf(J.viewer.FileManager.urlPrefixPairs[b]))return J.viewer.FileManager.urlPrefixPairs[b+1]+J.util.Txt.trim(a.substring(a.indexOf(J.viewer.FileManager.urlPrefixPairs[b])+
J.viewer.FileManager.urlPrefixPairs[b].length),"/");return null},"~S");c$.getLocalDirectory=$_M(c$,"getLocalDirectory",function(a,b){var c=a.getParameter(b?"currentLocalPath":"defaultDirectoryLocal");b&&0==c.length&&(c=a.getParameter("defaultDirectoryLocal"));if(0==c.length)return a.isApplet()?null:a.apiPlatform.newFile(System.getProperty("user.dir","."));a.isApplet()&&0==c.indexOf("file:/")&&(c=c.substring(6));c=a.apiPlatform.newFile(c);return c.isDirectory()?c:c.getParentAsFile()},"J.viewer.Viewer,~B");
c$.setLocalPath=$_M(c$,"setLocalPath",function(a,b,c){for(;b.endsWith("/")||b.endsWith("\\");)b=b.substring(0,b.length-1);a.setStringProperty("currentLocalPath",b);c||a.setStringProperty("defaultDirectoryLocal",b)},"J.viewer.Viewer,~S,~B");c$.getLocalPathForWritingFile=$_M(c$,"getLocalPathForWritingFile",function(a,b){if(0==b.indexOf("file:/"))return b.substring(6);if(0==b.indexOf("/")||0<=b.indexOf(":"))return b;var c=J.viewer.FileManager.getLocalDirectory(a,!1);return null==c?b:J.viewer.FileManager.fixPath(c.toString()+
"/"+b)},"J.viewer.Viewer,~S");c$.setScriptFileReferences=$_M(c$,"setScriptFileReferences",function(a,b,c,d){null!=b&&(a=J.viewer.FileManager.setScriptFileRefs(a,b,!0));null!=c&&(a=J.viewer.FileManager.setScriptFileRefs(a,c,!1));a=J.util.Txt.simpleReplace(a,'\u0001"','"');if(null!=d){for(;d.endsWith("/");)d=d.substring(0,d.length-1);for(b=0;b<J.viewer.FileManager.scriptFilePrefixes.length;b++)c=J.viewer.FileManager.scriptFilePrefixes[b],a=J.util.Txt.simpleReplace(a,c+".",c+d)}return a},"~S,~S,~S,~S");
c$.setScriptFileRefs=$_M(c$,"setScriptFileRefs",($fz=function(a,b,c){if(null==b)return a;var d=0==b.length,e=new JU.List;J.io.JmolBinary.getFileReferences(a,e);for(var f=new JU.List,g=new JU.List,h=e.size(),k=0;k<h;k++){var l=e.get(k),m=l;if(c==J.viewer.FileManager.isLocal(m)){var n=d?-1:m.indexOf("/"+b+"/");0<=n?m=m.substring(n+1):(n=m.lastIndexOf("/"),0>n&&!d&&(m="/"+m),(0>n||d)&&n++,m=b+m.substring(n))}J.util.Logger.info("FileManager substituting "+l+" --\x3e "+m);f.addLast('"'+l+'"');g.addLast('\u0001"'+
m+'"')}return J.util.Txt.replaceStrings(a,f,g)},$fz.isPrivate=!0,$fz),"~S,~S,~B");c$.stripPath=$_M(c$,"stripPath",function(a){var b=Math.max(a.lastIndexOf("|"),a.lastIndexOf("/"));return a.substring(b+1)},"~S");c$.fixFileNameVariables=$_M(c$,"fixFileNameVariables",function(a,b){var c=J.util.Txt.simpleReplace(a,"%FILE",b);if(0>c.indexOf("%LC"))return c;b=b.toLowerCase();c=J.util.Txt.simpleReplace(c,"%LCFILE",b);4==b.length&&(c=J.util.Txt.simpleReplace(c,"%LC13",b.substring(1,3)));return c},"~S,~S");
$_M(c$,"clearPngjCache",function(a){null!=a&&(null==this.pngjCache||!this.pngjCache.containsKey(this.getCanonicalName(J.io.JmolBinary.getZipRoot(a))))||(this.pngjCache=null,J.util.Logger.info("PNGJ cache cleared"))},"~S");$_M(c$,"cachePut",function(a,b){a=a.$replace("\\","/");J.util.Logger.debugging&&J.util.Logger.debug("cachePut "+a);null==b||"".equals(b)?this.cache.remove(a):(this.cache.put(a,b),J.io.JmolBinary.getCachedPngjBytes(this,a))},"~S,~O");$_M(c$,"cacheGet",function(a,b){a=a.$replace("\\",
"/");var c=a.indexOf("|");0<=c&&(a=a.substring(0,c));J.util.Logger.debugging&&J.util.Logger.debug("cacheGet "+a+" "+this.cache.containsKey(a));c=this.cache.get(a);return b&&Clazz.instanceOf(c,String)?null:c},"~S,~B");$_M(c$,"cacheClear",function(){J.util.Logger.info("cache cleared");this.cache.clear();this.clearPngjCache(null)});$_M(c$,"cacheFileByNameAdd",function(a,b){if(null==a||!b&&a.equalsIgnoreCase(""))return this.cacheClear(),-1;var c;if(b){a=this.viewer.resolveDatabaseFormat(a);c=this.getFileAsBytes(a,
null,!0);if(Clazz.instanceOf(c,String))return 0;this.cachePut(a,c)}else{if(a.endsWith("*"))return JU.ArrayUtil.removeMapKeys(this.cache,a.substring(0,a.length-1));c=this.cache.remove(a.$replace("\\","/"))}return null==c?0:(Clazz.instanceOf(c,String),c.length)},"~S,~B");$_M(c$,"cacheList",function(){for(var a=new java.util.Hashtable,b,c=this.cache.entrySet().iterator();c.hasNext()&&((b=c.next())||1);)a.put(b.getKey(),Integer.$valueOf(J.util.Escape.isAB(b.getValue())?b.getValue().length:b.getValue().toString().length));
return a});$_M(c$,"getCanonicalName",function(a){var b=this.classifyName(a,!0);return null==b?a:b[2]},"~S");Clazz.overrideMethod(c$,"postByteArray",function(a,b){var c=this.getBufferedInputStreamOrErrorMessageFromName(a,null,!1,!1,b,!1);if(Clazz.instanceOf(c,String))return c;try{c=J.io.JmolBinary.getStreamAsBytes(c,null)}catch(d){if(Clazz.exceptionOf(d,java.io.IOException))try{c.close()}catch(e){if(!Clazz.exceptionOf(e,java.io.IOException))throw e;}else throw d;}return null==c?"":J.io.JmolBinary.fixUTF(c)},
"~S,~A");Clazz.defineStatics(c$,"URL_LOCAL",3,"urlPrefixes",["http:","https:","ftp:","file:"],"urlPrefixPairs","http: http:// www. http://www. https: https:// ftp: ftp:// file: file:///".split(" "));c$.scriptFilePrefixes=c$.prototype.scriptFilePrefixes=['/*file*/"','FILE0="','FILE1="']}),Clazz.declarePackage("J.script"),Clazz.load(["J.script.T"],"J.script.ContextToken",["java.util.Hashtable","J.script.SV"],function(){c$=Clazz.decorateAsClass(function(){this.name0=this.contextVariables=null;Clazz.instantialize(this,
arguments)},J.script,"ContextToken",J.script.T);c$.newContext=$_M(c$,"newContext",function(a){a=a?J.script.ContextToken.newCmd(266280,"{"):J.script.ContextToken.newCmd(266278,"}");a.intValue=0;return a},"~B");c$.newCmd=$_M(c$,"newCmd",function(a,b){var c=new J.script.ContextToken;c.tok=a;c.value=b;return c},"~N,~O");$_M(c$,"addName",function(a){null==this.contextVariables&&(this.contextVariables=new java.util.Hashtable);this.contextVariables.put(a,J.script.SV.newVariable(4,"").setName(a))},"~S")}),
Clazz.declarePackage("J.script"),c$=Clazz.decorateAsClass(function(){this.aatoken=null;this.chk=this.allowJSThreads=!1;this.contextPath=" >> ";this.contextVariables=null;this.displayLoadErrorsSave=!1;this.errorType=this.errorMessageUntranslated=this.errorMessage=null;this.executionStepping=this.executionPaused=!1;this.functionName=null;this.iCommandError=-1;this.id=0;this.isComplete=!0;this.isTryCatch=this.isStateScript=this.isJSThread=this.isFunction=!1;this.iToken=0;this.lineEnd=2147483647;this.lineNumbers=
this.lineIndices=null;this.mustResumeEval=!1;this.parentContext=this.parallelProcessor=this.outputBuffer=null;this.pc=0;this.pcEnd=2147483647;this.scriptFileName=this.scriptExtensions=this.script=null;this.scriptLevel=0;this.htFileCache=this.statement=null;this.statementLength=0;this.token=null;this.tryPt=0;Clazz.instantialize(this,arguments)},J.script,"ScriptContext"),Clazz.makeConstructor(c$,function(){this.id=($t$=++J.script.ScriptContext.contextCount,J.script.ScriptContext.prototype.contextCount=
J.script.ScriptContext.contextCount,$t$)}),Clazz.defineStatics(c$,"contextCount",0),Clazz.declarePackage("J.constant"),Clazz.load(["java.lang.Enum"],"J.constant.EnumAnimationMode",null,function(){c$=Clazz.declareType(J.constant,"EnumAnimationMode",Enum);Clazz.defineEnumConstant(c$,"ONCE",0,[]);Clazz.defineEnumConstant(c$,"LOOP",1,[]);Clazz.defineEnumConstant(c$,"PALINDROME",2,[])}),Clazz.declarePackage("J.io"),Clazz.load(null,"J.io.FileReader","java.io.BufferedReader J.api.Interface J.io.JmolBinary J.util.Escape $.Logger $.Txt".split(" "),
function(){c$=Clazz.decorateAsClass(function(){this.htParams=this.reader=this.atomSetCollection=this.fileTypeIn=this.nameAsGivenIn=this.fullPathNameIn=this.fileNameIn=this.viewer=this.fm=null;this.isAppend=!1;this.bytes=null;Clazz.instantialize(this,arguments)},J.io,"FileReader");Clazz.makeConstructor(c$,function(a,b,c,d,e,f,g,h,k){this.fm=a;this.viewer=b;this.fileNameIn=c;this.fullPathNameIn=d;this.nameAsGivenIn=e;this.fileTypeIn=f;this.reader=Clazz.instanceOf(g,java.io.BufferedReader)?g:Clazz.instanceOf(g,
java.io.Reader)?new java.io.BufferedReader(g):null;this.bytes=J.util.Escape.isAB(g)?g:null;this.htParams=h;this.isAppend=k},"J.viewer.FileManager,J.viewer.Viewer,~S,~S,~S,~S,~O,java.util.Map,~B");$_M(c$,"run",function(){!this.isAppend&&this.viewer.displayLoadErrors&&this.viewer.zap(!1,!0,!1);var a=null,a=null;if(null==this.reader){a=this.fm.getUnzippedReaderOrStreamFromName(this.fullPathNameIn,this.bytes,!0,!1,!1,!0,this.htParams);if(null==a||Clazz.instanceOf(a,String)){a=null==a?"error opening:"+
this.nameAsGivenIn:a;a.startsWith("NOTE:")||J.util.Logger.error("file ERROR: "+this.fullPathNameIn+"\n"+a);this.atomSetCollection=a;return}if(Clazz.instanceOf(a,java.io.BufferedReader))this.reader=a;else if(Clazz.instanceOf(a,J.api.ZInputStream)){var b=this.fullPathNameIn,c=null;0<=b.indexOf("|")&&!b.endsWith(".zip")&&(c=J.util.Txt.split(b,"|"),b=c[0]);null!=c&&this.htParams.put("subFileList",c);c=a;a=this.fm.getZipDirectory(b,!0);this.atomSetCollection=a=J.io.JmolBinary.getAtomSetCollectionOrBufferedReaderFromZip(this.viewer.getModelAdapter(),
c,b,a,this.htParams,!1);try{c.close()}catch(d){if(!Clazz.exceptionOf(d,Exception))throw d;}}}Clazz.instanceOf(a,java.io.BufferedInputStream)&&(b=J.api.Interface.getOptionInterface("io2.BinaryDocument"),b.setStream(a,!0),this.reader=b);if(null!=this.reader){this.atomSetCollection=this.viewer.getModelAdapter().getAtomSetCollectionReader(this.fullPathNameIn,this.fileTypeIn,this.reader,this.htParams);Clazz.instanceOf(this.atomSetCollection,String)||(this.atomSetCollection=this.viewer.getModelAdapter().getAtomSetCollection(this.atomSetCollection));
try{Clazz.instanceOf(this.reader,java.io.BufferedReader)?this.reader.close():Clazz.instanceOf(this.reader,J.api.JmolDocument)&&this.reader.close()}catch(e){if(!Clazz.exceptionOf(e,java.io.IOException))throw e;}}Clazz.instanceOf(this.atomSetCollection,String)||(!this.isAppend&&!this.viewer.displayLoadErrors&&this.viewer.zap(!1,!0,!1),this.fm.fullPathName=this.fullPathNameIn,this.fm.nameAsGiven=this.nameAsGivenIn,this.fm.fileName=this.fileNameIn)});$_M(c$,"getAtomSetCollection",function(){return this.atomSetCollection})}),
Clazz.declarePackage("J.viewer"),Clazz.load(["java.util.Hashtable","J.constant.EnumVdw"],"J.viewer.DataManager","JU.ArrayUtil $.BS $.ParserJS $.SB J.script.T J.util.BSUtil $.Elements $.Escape $.Logger $.ParserBS".split(" "),function(){c$=Clazz.decorateAsClass(function(){this.bsUserVdws=this.defaultVdw=this.userVdwMars=this.userVdws=this.viewer=this.dataValues=null;Clazz.instantialize(this,arguments)},J.viewer,"DataManager");Clazz.prepareFields(c$,function(){this.dataValues=new java.util.Hashtable;
this.defaultVdw=J.constant.EnumVdw.JMOL});Clazz.makeConstructor(c$,function(a){this.viewer=a},"J.viewer.Viewer");$_M(c$,"clear",function(){this.dataValues.clear()});$_M(c$,"setData",function(a,b,c,d,e,f,g,h){if(null==a)this.clear();else if(a=a.toLowerCase(),a.equals("element_vdw")){var k=b[1].trim();if(0==k.length)this.bsUserVdws=this.userVdws=this.userVdwMars=null;else{null==this.bsUserVdws&&this.setUserVdw(this.defaultVdw);J.util.ParserBS.parseFloatArrayFromMatchAndField(k,this.bsUserVdws,1,0,b[2],
2,0,this.userVdws,1);for(g=this.userVdws.length;0<=--g;)this.userVdwMars[g]=Clazz.doubleToInt(Math.floor(1E3*this.userVdws[g]))}}else{if(null!=b[2]&&0<c){c=0!=e||-2147483648!=g&&2147483647!=g;var l=this.dataValues.get(a);d=null==l||c?Clazz.newFloatArray(d,0):JU.ArrayUtil.ensureLengthA(l[1],d);var m=b[3].intValue(),k=0==m?b[1]:null,m=1==m?b[1]:null,n=null;if(-2147483648==g&&1<(n=JU.ParserJS.getTokens(k)).length)g=0;if(-2147483648==g)e=b[2],J.viewer.DataManager.setSelectedFloats(JU.ParserJS.parseFloat(k),
e,d);else if(0==g||2147483647==g)if(e=b[2],null!=m)if(m.length==e.cardinality()){g=e.nextSetBit(0);for(h=0;0<=g;g=e.nextSetBit(g+1),h++)d[g]=m[h]}else for(g=e.nextSetBit(0);0<=g;g=e.nextSetBit(g+1))d[g]=m[g];else J.util.ParserBS.parseFloatArrayBsData(null==n?JU.ParserJS.getTokens(k):n,e,d);else if(0>=e)e=b[2],J.util.ParserBS.parseFloatArrayFromMatchAndField(k,e,0,0,null,g,h,d,1);else{m=b[2];J.util.ParserBS.parseFloatArrayFromMatchAndField(k,null,e,f,m,g,h,d,1);e=new JU.BS;for(g=m.length;0<=--g;)0<=
m[g]&&e.set(m[g])}null!=l&&(Clazz.instanceOf(l[2],JU.BS)&&!c)&&e.or(l[2]);b[3]=Integer.$valueOf(1);b[2]=e;b[1]=d;if(0==a.indexOf("property_atom.")){b=J.script.T.getSettableTokFromString(a=a.substring(14));if(0==b){J.util.Logger.error("Unknown atom property: "+a);return}a=e.cardinality();c=Clazz.newFloatArray(a,0);l=0;for(g=e.nextSetBit(0);l<a;g=e.nextSetBit(g+1))c[l++]=d[g];this.viewer.setAtomProperty(e,b,0,0,null,c,null);return}}this.dataValues.put(a,b)}},"~S,~A,~N,~N,~N,~N,~N,~N");c$.setSelectedFloats=
$_M(c$,"setSelectedFloats",($fz=function(a,b,c){for(var d=null==b,e=d?0:b.nextSetBit(0);0<=e&&e<c.length;e=d?e+1:b.nextSetBit(e+1))c[e]=a},$fz.isPrivate=!0,$fz),"~N,JU.BS,~A");$_M(c$,"getData",function(a){if(null==this.dataValues||null==a)return null;if(!a.equalsIgnoreCase("types"))return this.dataValues.get(a);a=Array(2);a[0]="types";a[1]="";for(var b=0,c,d=this.dataValues.keySet().iterator();d.hasNext()&&((c=d.next())||1);)a[1]+=(0<b++?"\n":"")+c;return a},"~S");$_M(c$,"getDataFloatA",function(a){if(null==
this.dataValues)return null;a=this.getData(a);return null==a||1!=a[3].intValue()?null:a[1]},"~S");$_M(c$,"getDataFloat",function(a,b){if(null!=this.dataValues){var c=this.getData(a);if(null!=c&&1==c[3].intValue()&&(c=c[1],b<c.length))return c[b]}return NaN},"~S,~N");$_M(c$,"getDataFloat2D",function(a){if(null==this.dataValues)return null;a=this.getData(a);return null==a||2!=a[3].intValue()?null:a[1]},"~S");$_M(c$,"getDataFloat3D",function(a){if(null==this.dataValues)return null;a=this.getData(a);
return null==a||3!=a[3].intValue()?null:a[1]},"~S");$_M(c$,"deleteModelAtoms",function(a,b,c){if(null!=this.dataValues)for(var d,e=this.dataValues.keySet().iterator();e.hasNext()&&((d=e.next())||1);)if(0==d.indexOf("property_")){var f=this.dataValues.get(d);J.util.BSUtil.deleteBits(f[2],c);switch(f[3].intValue()){case 1:f[1]=JU.ArrayUtil.deleteElements(f[1],a,b);break;case 2:f[1]=JU.ArrayUtil.deleteElements(f[1],a,b)}}},"~N,~N,JU.BS");$_M(c$,"setUserVdw",($fz=function(a){this.userVdwMars=Clazz.newIntArray(J.util.Elements.elementNumberMax,
0);this.userVdws=Clazz.newFloatArray(J.util.Elements.elementNumberMax,0);this.bsUserVdws=new JU.BS;a===J.constant.EnumVdw.USER&&(a=J.constant.EnumVdw.JMOL);for(var b=1;b<J.util.Elements.elementNumberMax;b++)this.userVdwMars[b]=J.util.Elements.getVanderwaalsMar(b,a),this.userVdws[b]=this.userVdwMars[b]/1E3},$fz.isPrivate=!0,$fz),"J.constant.EnumVdw");$_M(c$,"setDefaultVdw",function(a){switch(a){case J.constant.EnumVdw.JMOL:case J.constant.EnumVdw.BABEL:case J.constant.EnumVdw.RASMOL:case J.constant.EnumVdw.AUTO:case J.constant.EnumVdw.USER:break;
default:a=J.constant.EnumVdw.JMOL}a!==this.defaultVdw&&(a===J.constant.EnumVdw.USER&&null==this.bsUserVdws)&&this.setUserVdw(this.defaultVdw);this.defaultVdw=a},"J.constant.EnumVdw");$_M(c$,"getDefaultVdwNameOrData",function(a,b,c){switch(a){case -2147483648:return this.defaultVdw.getVdwLabel();case 2147483647:if(null==(c=this.bsUserVdws))return"";b=J.constant.EnumVdw.USER}if(null==b||b===J.constant.EnumVdw.AUTO)b=this.defaultVdw;b===J.constant.EnumVdw.USER&&null==this.bsUserVdws&&this.setUserVdw(this.defaultVdw);
a=new JU.SB;a.append(b.getVdwLabel()).append("\n");for(var d=null==c,e=d?1:c.nextSetBit(0),f=d?J.util.Elements.elementNumberMax:c.length();e<f&&0<=e;e=d?e+1:c.nextSetBit(e+1))a.appendI(e).appendC("\t").appendF(b===J.constant.EnumVdw.USER?this.userVdws[e]:J.util.Elements.getVanderwaalsMar(e,b)/1E3).appendC("\t").append(J.util.Elements.elementSymbolFromNumber(e)).appendC("\n");return null==c?a.toString():'\n  DATA "element_vdw"\n'+a.append('  end "element_vdw";\n\n').toString()},"~N,J.constant.EnumVdw,JU.BS");
c$.getInlineData=$_M(c$,"getInlineData",function(a,b,c,d){c=(c?"append":"model")+" inline";a.append('load /*data*/ data "').append(c).append('"\n').append(b).append('end "').append(c).append(null==d||0==d.length?"":" filter"+J.util.Escape.eS(d)).append('";')},"JU.SB,~S,~B,~S");Clazz.defineStatics(c$,"DATA_TYPE_STRING",0,"DATA_TYPE_AF",1,"DATA_ARRAY_FF",2,"DATA_ARRAY_FFF",3,"DATA_VALUE",1,"DATA_SELECTION_MAP",2,"DATA_TYPE",3,"DATA_SAVE_IN_STATE",4)}),Clazz.declarePackage("J.util"),Clazz.declareInterface(J.util,
"JmolNode"),Clazz.declarePackage("J.util"),Clazz.load(["JU.P3"],"J.util.Point3fi",null,function(){c$=Clazz.decorateAsClass(function(){this.screenZ=this.screenY=this.screenX=this.index=0;this.modelIndex=this.screenDiameter=-1;Clazz.instantialize(this,arguments)},J.util,"Point3fi",JU.P3);c$.set2=$_M(c$,"set2",function(a,b){a.x=b.x;a.y=b.y;a.z=b.z},"JU.P3,JU.P3i")}),Clazz.declarePackage("J.modelset"),Clazz.load(["J.util.JmolNode","$.Point3fi","J.constant.EnumPalette","J.viewer.JC"],"J.modelset.Atom",
"java.lang.Float JU.P3 $.SB $.V3 J.atomdata.RadiusData J.constant.EnumVdw J.util.C $.ColorUtil $.Elements $.Escape".split(" "),function(){c$=Clazz.decorateAsClass(function(){this.altloc="\x00";this.atomSite=this.atomID=0;this.group=null;this.atomicAndIsotopeNumber=this.valence=this.userDefinedVanDerWaalRadius=0;this.atomSymmetry=null;this.paletteID=this.colixAtom=this.madAtom=this.formalChargeAndFlags=0;this.bonds=null;this.shapeVisibilityFlags=this.clickabilityFlags=this.nBackbonesDisplayed=this.nBondsDisplayed=
0;Clazz.instantialize(this,arguments)},J.modelset,"Atom",J.util.Point3fi,J.util.JmolNode);Clazz.prepareFields(c$,function(){this.paletteID=J.constant.EnumPalette.CPK.id});$_M(c$,"getAtomID",function(){return this.atomID});$_M(c$,"getBonds",function(){return this.bonds});$_M(c$,"setBonds",function(a){this.bonds=a},"~A");$_M(c$,"getNBackbonesDisplayed",function(){return this.nBackbonesDisplayed});Clazz.overrideConstructor(c$,function(a,b,c,d,e,f,g,h,k){this.modelIndex=a;this.atomSymmetry=e;this.atomSite=
f;this.index=b;this.atomicAndIsotopeNumber=g;k&&(this.formalChargeAndFlags=2);0!=h&&-2147483648!=h&&this.setFormalCharge(h);this.userDefinedVanDerWaalRadius=d;this.setT(c)},"~N,~N,JU.P3,~N,JU.BS,~N,~N,~N,~B");$_M(c$,"setAltLoc",function(a){this.altloc=a},"~S");$_M(c$,"setShapeVisibilityFlags",function(a){this.shapeVisibilityFlags=a},"~N");$_M(c$,"setShapeVisibility",function(a,b){this.shapeVisibilityFlags=b?this.shapeVisibilityFlags|a:this.shapeVisibilityFlags&~a},"~N,~B");$_M(c$,"isCovalentlyBonded",
function(a){if(null!=this.bonds)for(var b=this.bonds.length;0<=--b;)if(this.bonds[b].isCovalent()&&this.bonds[b].getOtherAtom(this)===a)return!0;return!1},"J.modelset.Atom");$_M(c$,"isBonded",function(a){if(null!=this.bonds)for(var b=this.bonds.length;0<=--b;)if(this.bonds[b].getOtherAtom(this)===a)return!0;return!1},"J.modelset.Atom");$_M(c$,"getBond",function(a){if(null!=this.bonds)for(var b=this.bonds.length;0<=--b;)if(null!=this.bonds[b].getOtherAtom(a))return this.bonds[b];return null},"J.modelset.Atom");
$_M(c$,"addDisplayedBond",function(a,b){this.nBondsDisplayed+=b?1:-1;this.setShapeVisibility(a,0<this.nBondsDisplayed)},"~N,~B");$_M(c$,"addDisplayedBackbone",function(a,b){this.nBackbonesDisplayed+=b?1:-1;this.setShapeVisibility(a,b)},"~N,~B");$_M(c$,"deleteBond",function(a){if(null!=this.bonds)for(var b=this.bonds.length;0<=--b;)if(this.bonds[b]===a){this.deleteBondAt(b);break}},"J.modelset.Bond");$_M(c$,"deleteBondAt",($fz=function(a){var b=this.bonds.length-1;if(0==b)this.bonds=null;else{for(var c=
Array(b),d=0;d<a;++d)c[d]=this.bonds[d];for(;d<b;++d)c[d]=this.bonds[d+1];this.bonds=c}},$fz.isPrivate=!0,$fz),"~N");$_M(c$,"clearBonds",function(){this.bonds=null});Clazz.overrideMethod(c$,"getBondedAtomIndex",function(a){return this.bonds[a].getOtherAtom(this).index},"~N");$_M(c$,"setMadAtom",function(a,b){this.madAtom=this.calculateMad(a,b)},"J.viewer.Viewer,J.atomdata.RadiusData");$_M(c$,"calculateMad",function(a,b){if(null==b)return 0;var c=b.value;if(0==c)return 0;switch(b.factorType){case J.atomdata.RadiusData.EnumType.SCREEN:return Clazz.floatToShort(c);
case J.atomdata.RadiusData.EnumType.FACTOR:case J.atomdata.RadiusData.EnumType.OFFSET:var d=0;switch(b.vdwType){case J.constant.EnumVdw.TEMP:d=a.getBfactor100Hi();d=0<d?this.getBfactor100()/d:0;break;case J.constant.EnumVdw.HYDRO:d=Math.abs(this.getHydrophobicity());break;case J.constant.EnumVdw.IONIC:d=this.getBondingRadiusFloat();break;case J.constant.EnumVdw.ADPMIN:case J.constant.EnumVdw.ADPMAX:d=this.getADPMinMax(b.vdwType===J.constant.EnumVdw.ADPMAX);break;default:d=this.getVanderwaalsRadiusFloat(a,
b.vdwType)}c=b.factorType===J.atomdata.RadiusData.EnumType.FACTOR?c*d:c+d}d=Clazz.floatToShort(0>c?c:2E3*c);0>d&&0<c&&(d=0);return d},"J.viewer.Viewer,J.atomdata.RadiusData");$_M(c$,"getADPMinMax",function(a){var b=this.getTensors();if(null==b)return 0;var c=b[0];if(null==c||1!=c.iType)return 0;this.group.chain.model.modelSet.isModulated(this.index)&&c.isUnmodulated&&(c=b[1]);return c.getFactoredValue(a?2:1)},"~B");$_M(c$,"getTensors",function(){return this.group.chain.model.modelSet.getAtomTensorList(this.index)});
$_M(c$,"getRasMolRadius",function(){return Math.abs(Clazz.doubleToInt(this.madAtom/8))});Clazz.overrideMethod(c$,"getCovalentBondCount",function(){if(null==this.bonds)return 0;for(var a=0,b,c=this.bonds.length;0<=--c;)0!=((b=this.bonds[c]).order&1023)&&!b.getOtherAtom(this).isDeleted()&&++a;return a});Clazz.overrideMethod(c$,"getCovalentHydrogenCount",function(){if(null==this.bonds)return 0;for(var a=0,b=this.bonds.length;0<=--b;)if(0!=(this.bonds[b].order&1023)){var c=this.bonds[b].getOtherAtom(this);
0<=c.valence&&1==c.getElementNumber()&&++a}return a});Clazz.overrideMethod(c$,"getEdges",function(){return this.bonds});$_M(c$,"setColixAtom",function(a){this.colixAtom=a},"~N");$_M(c$,"setPaletteID",function(a){this.paletteID=a},"~N");$_M(c$,"setTranslucent",function(a,b){this.colixAtom=J.util.C.getColixTranslucent3(this.colixAtom,a,b)},"~B,~N");$_M(c$,"isTranslucent",function(){return J.util.C.isColixTranslucent(this.colixAtom)});Clazz.overrideMethod(c$,"getElementNumber",function(){return J.util.Elements.getElementNumber(this.atomicAndIsotopeNumber)});
Clazz.overrideMethod(c$,"getIsotopeNumber",function(){return J.util.Elements.getIsotopeNumber(this.atomicAndIsotopeNumber)});Clazz.overrideMethod(c$,"getAtomicAndIsotopeNumber",function(){return this.atomicAndIsotopeNumber});$_M(c$,"setAtomicAndIsotopeNumber",function(a){if(0>a||(a&127)>=J.util.Elements.elementNumberMax||32767<a)a=0;this.atomicAndIsotopeNumber=a},"~N");$_M(c$,"getElementSymbolIso",function(a){return J.util.Elements.elementSymbolFromNumber(a?this.atomicAndIsotopeNumber:this.atomicAndIsotopeNumber&
127)},"~B");$_M(c$,"getElementSymbol",function(){return this.getElementSymbolIso(!0)});$_M(c$,"getAlternateLocationID",function(){return this.altloc});$_M(c$,"isAlternateLocationMatch",function(a){if(null==a)return"\x00"==this.altloc;if(1!=a.length)return!1;a=a.charAt(0);return"*"==a||"?"==a&&"\x00"!=this.altloc||this.altloc==a},"~S");$_M(c$,"isHetero",function(){return 0!=(this.formalChargeAndFlags&2)});$_M(c$,"hasVibration",function(){return 0!=(this.formalChargeAndFlags&1)});$_M(c$,"setFormalCharge",
function(a){this.formalChargeAndFlags=this.formalChargeAndFlags&3|(-2147483648==a?0:7<a?7:-3>a?-3:a)<<2},"~N");$_M(c$,"setVibrationVector",function(){this.formalChargeAndFlags|=1});Clazz.overrideMethod(c$,"getFormalCharge",function(){return this.formalChargeAndFlags>>2});$_M(c$,"getOccupancy100",function(){var a=this.group.chain.model.modelSet.occupancies;return null==a?100:a[this.index]});$_M(c$,"getBfactor100",function(){var a=this.group.chain.model.modelSet.bfactor100s;return null==a?0:a[this.index]});
$_M(c$,"getHydrophobicity",($fz=function(){var a=this.group.chain.model.modelSet.hydrophobicities;return null==a?J.util.Elements.getHydrophobicity(this.group.getGroupID()):a[this.index]},$fz.isPrivate=!0,$fz));$_M(c$,"setRadius",function(a){return!Float.isNaN(this.userDefinedVanDerWaalRadius=0<a?a:NaN)},"~N");$_M(c$,"deleteBonds",function(a){this.valence=-1;if(null!=this.bonds)for(var b=this.bonds.length;0<=--b;){var c=this.bonds[b];c.getOtherAtom(this).deleteBond(c);a.set(c.index)}this.bonds=null},
"JU.BS");Clazz.overrideMethod(c$,"isDeleted",function(){return 0>this.valence});$_M(c$,"setValence",function(a){this.isDeleted()||(this.valence=0>a?0:239>a?a:239)},"~N");Clazz.overrideMethod(c$,"getValence",function(){if(this.isDeleted())return-1;var a=this.valence;if(0==a&&null!=this.bonds)for(var b=this.bonds.length;0<=--b;)a+=this.bonds[b].getValence();return a});Clazz.overrideMethod(c$,"getImplicitHydrogenCount",function(){return this.group.chain.model.modelSet.getImplicitHydrogenCount(this,!1)});
$_M(c$,"getTargetValence",function(){switch(this.getElementNumber()){case 6:case 14:return 4;case 5:case 7:case 15:return 3;case 8:case 16:return 2;case 1:case 9:case 17:case 35:case 53:return 1}return-1});$_M(c$,"getDimensionValue",function(a){return 0==a?this.x:1==a?this.y:this.z},"~N");$_M(c$,"getVanderwaalsRadiusFloat",function(a,b){return Float.isNaN(this.userDefinedVanDerWaalRadius)?a.getVanderwaalsMarType(this.atomicAndIsotopeNumber,this.getVdwType(b))/1E3:this.userDefinedVanDerWaalRadius},
"J.viewer.Viewer,J.constant.EnumVdw");$_M(c$,"getVdwType",($fz=function(a){switch(a){case J.constant.EnumVdw.AUTO:a=this.group.chain.model.modelSet.getDefaultVdwType(this.modelIndex);break;case J.constant.EnumVdw.NOJMOL:a=this.group.chain.model.modelSet.getDefaultVdwType(this.modelIndex),a===J.constant.EnumVdw.AUTO_JMOL&&(a=J.constant.EnumVdw.AUTO_BABEL)}return a},$fz.isPrivate=!0,$fz),"J.constant.EnumVdw");$_M(c$,"getCovalentRadiusFloat",($fz=function(){return J.util.Elements.getBondingRadiusFloat(this.atomicAndIsotopeNumber,
0)},$fz.isPrivate=!0,$fz));$_M(c$,"getBondingRadiusFloat",function(){var a=this.group.chain.model.modelSet.ionicRadii,a=null==a?0:a[this.index];return 0==a?J.util.Elements.getBondingRadiusFloat(this.atomicAndIsotopeNumber,this.getFormalCharge()):a});$_M(c$,"getVolume",function(a,b){var c=null==b?this.userDefinedVanDerWaalRadius:NaN;Float.isNaN(c)&&(c=a.getVanderwaalsMarType(this.getElementNumber(),this.getVdwType(b))/1E3);var d=0;if(null!=this.bonds)for(var e=0;e<this.bonds.length;e++)if(this.bonds[e].isCovalent()){var f=
this.bonds[e].getOtherAtom(this),g=null==b?f.userDefinedVanDerWaalRadius:NaN;Float.isNaN(g)&&(g=a.getVanderwaalsMarType(f.getElementNumber(),f.getVdwType(b))/1E3);f=this.distance(f);if(!(f>c+g)){if(f+c<=g)return 0;g=c-(c*c+f*f-g*g)/(2*f);d-=1.0471975511965976*g*g*(3*c-g)}}return d+4.1887902047863905*c*c*c},"J.viewer.Viewer,J.constant.EnumVdw");$_M(c$,"getCurrentBondCount",function(){return null==this.bonds?0:this.bonds.length});$_M(c$,"getColix",function(){return this.colixAtom});$_M(c$,"getPaletteID",
function(){return this.paletteID});$_M(c$,"getRadius",function(){return Math.abs(this.madAtom/2E3)});Clazz.overrideMethod(c$,"getIndex",function(){return this.index});Clazz.overrideMethod(c$,"getAtomSite",function(){return this.atomSite});$_M(c$,"setAtomSymmetry",function(a){this.atomSymmetry=a},"JU.BS");$_M(c$,"getAtomSymmetry",function(){return this.atomSymmetry});$_M(c$,"setGroup",function(a){this.group=a},"J.modelset.Group");$_M(c$,"getGroup",function(){return this.group});Clazz.overrideMethod(c$,
"getGroupBits",function(a){this.group.selectAtoms(a)},"JU.BS");Clazz.overrideMethod(c$,"getAtomName",function(){return 0<this.atomID?J.viewer.JC.getSpecialAtomName(this.atomID):this.group.chain.model.modelSet.atomNames[this.index]});Clazz.overrideMethod(c$,"getAtomType",function(){var a=this.group.chain.model.modelSet.atomTypes,a=null==a?null:a[this.index];return null==a?this.getAtomName():a});$_M(c$,"getAtomNumber",function(){var a=this.group.chain.model.modelSet.atomSerials;return null!=a?a[this.index]:
this.index});$_M(c$,"isInFrame",function(){return 0!=(this.shapeVisibilityFlags&1)});$_M(c$,"getShapeVisibilityFlags",function(){return this.shapeVisibilityFlags});$_M(c$,"isShapeVisible",function(a){return 0!=(this.shapeVisibilityFlags&a)},"~N");$_M(c$,"getPartialCharge",function(){var a=this.group.chain.model.modelSet.partialCharges;return null==a?0:a[this.index]});$_M(c$,"getSymmetryTranslation",function(a,b,c){for(var d=0;d<b.length;d++)if(this.atomSymmetry.get(a+=c))return b[d];return 0},"~N,~A,~N");
$_M(c$,"getCellTranslation",function(a,b,c){for(var d=c,e=0;e<b.length;e++)for(var f=0;f<c;f++,d++)if(this.atomSymmetry.get(d)&&b[e]==a)return b[e];return 0},"~N,~A,~N");$_M(c$,"getSymmetryOperatorList",function(){var a="",b=this.group.chain.model.modelSet,c=b.getModelSymmetryCount(this.modelIndex);if(0==c||null==this.atomSymmetry)return"";for(var b=b.getModelCellRange(this.modelIndex),d=c,e=null==b?1:b.length,f=0;f<e;f++)for(var g=0;g<c;g++)this.atomSymmetry.get(d++)&&(a+=","+(g+1)+""+b[f]);return 0==
a.length?"":a.substring(1)});Clazz.overrideMethod(c$,"getModelIndex",function(){return this.modelIndex});$_M(c$,"getMoleculeNumber",function(a){return this.group.chain.model.modelSet.getMoleculeIndex(this.index,a)+1},"~B");$_M(c$,"getFractionalCoord",($fz=function(a,b){var c=this.getFractionalCoordPt(b);return"X"==a?c.x:"Y"==a?c.y:c.z},$fz.isPrivate=!0,$fz),"~S,~B");$_M(c$,"getFractionalCoordPt",($fz=function(a){var b=this.group.chain.model.modelSet.getUnitCell(this.modelIndex);if(null==b)return this;
var c=JU.P3.newP(this);b.toFractional(c,a);return c},$fz.isPrivate=!0,$fz),"~B");$_M(c$,"getFractionalUnitCoord",($fz=function(a){var b=this.getFractionalUnitCoordPt(!1);return"X"==a?b.x:"Y"==a?b.y:b.z},$fz.isPrivate=!0,$fz),"~S");$_M(c$,"getFractionalUnitCoordPt",function(a){var b=this.group.chain.model.modelSet.getUnitCell(this.modelIndex);if(null==b)return this;var c=JU.P3.newP(this);this.group.chain.model.isJmolDataFrame?(b.toFractional(c,!1),a&&b.toCartesian(c,!1)):(b.toUnitCell(c,null),a||b.toFractional(c,
!1));return c},"~B");$_M(c$,"getFractionalUnitDistance",function(a,b,c){var d=this.group.chain.model.modelSet.getUnitCell(this.modelIndex);if(null==d)return this.distance(a);b.setT(this);c.setT(a);this.group.chain.model.isJmolDataFrame?(d.toFractional(b,!0),d.toFractional(c,!0)):(d.toUnitCell(b,null),d.toUnitCell(c,null));return b.distance(c)},"JU.P3,JU.P3,JU.P3");$_M(c$,"setFractionalCoord",function(a,b,c){var d=this.group.chain.model.modelSet.getUnitCell(this.modelIndex);null!=d&&d.toFractional(this,
c);switch(a){case 1112541191:case 1112541188:this.x=b;break;case 1112541192:case 1112541189:this.y=b;break;case 1112541193:case 1112541190:this.z=b}null!=d&&d.toCartesian(this,c)},"~N,~N,~B");$_M(c$,"setFractionalCoordTo",function(a,b){this.setFractionalCoordPt(this,a,b)},"JU.P3,~B");$_M(c$,"setFractionalCoordPt",function(a,b,c){a.setT(b);b=this.group.chain.model.modelSet.getUnitCell(this.modelIndex);null!=b&&b.toCartesian(a,c&&!this.group.chain.model.isJmolDataFrame)},"JU.P3,JU.P3,~B");$_M(c$,"isCursorOnTopOf",
function(a,b,c,d){var e=Clazz.doubleToInt(this.screenDiameter/2);e<c&&(e=c);c=e*e;e=this.screenX-a;e*=e;if(e>c)return!1;var f=this.screenY-b;c-=e+f*f;if(0>c)return!1;if(null==d)return!0;var e=this.screenZ,f=d.screenZ,g=Clazz.doubleToInt(d.screenDiameter/2);if(e<f-g)return!0;a=d.screenX-a;b=d.screenY-b;b=g*g-(a*a+b*b);return e-Math.sqrt(c)<f-Math.sqrt(b)},"~N,~N,~N,J.modelset.Atom");$_M(c$,"getInfo",function(){return this.getIdentity(!0)});$_M(c$,"getInfoXYZ",function(a){if(a){a=this.getGroup3(!0);
var b=this.getChainID(),c=this.getFractionalCoordPt(!0);return"Atom: "+(null==a?this.getElementSymbol():this.getAtomName())+" "+this.getAtomNumber()+(null!=a&&0<a.length?(this.isHetero()?" Hetero: ":" Group: ")+a+" "+this.getResno()+(0!=b&&32!=b?" Chain: "+this.group.chain.getIDStr():""):"")+" Model: "+this.getModelNumber()+" Coordinates: "+this.x+" "+this.y+" "+this.z+(null==c?"":" Fractional: "+c.x+" "+c.y+" "+c.z)}return this.getIdentityXYZ(!0)},"~B");$_M(c$,"getIdentityXYZ",function(a){var b=
this.group.chain.model.isJmolDataFrame?this.getFractionalCoordPt(!1):this;return this.getIdentity(a)+" "+b.x+" "+b.y+" "+b.z},"~B");$_M(c$,"getIdentity",function(a){var b=new JU.SB,c=this.getGroup3(!0);if(null!=c&&0<c.length){b.append("[");b.append(c);b.append("]");c=this.getSeqcodeString();null!=c&&b.append(c);c=this.getChainID();if(0!=c&&32!=c){b.append(":");var d=this.getChainIDStr();256<=c&&(d=J.util.Escape.eS(d));b.append(d)}if(!a)return b.toString();b.append(".")}b.append(this.getAtomName());
0==b.length()&&(b.append(this.getElementSymbolIso(!1)),b.append(" "),b.appendI(this.getAtomNumber()));0!=this.altloc.charCodeAt(0)&&(b.append("%"),b.appendC(this.altloc));1<this.group.chain.model.modelSet.modelCount&&(b.append("/"),b.append(this.getModelNumberForLabel()));b.append(" #");b.appendI(this.getAtomNumber());return b.toString()},"~B");Clazz.overrideMethod(c$,"getGroup3",function(a){var b=this.group.getGroup3();return a||null!=b&&0<b.length?b:"UNK"},"~B");Clazz.overrideMethod(c$,"getGroup1",
function(a){var b=this.group.getGroup1();return"\x00"!=b?""+b:"\x00"!=a?""+a:""},"~S");Clazz.overrideMethod(c$,"isProtein",function(){return this.group.isProtein()});$_M(c$,"isCarbohydrate",function(){return this.group.isCarbohydrate()});Clazz.overrideMethod(c$,"isNucleic",function(){return this.group.isNucleic()});Clazz.overrideMethod(c$,"isDna",function(){return this.group.isDna()});Clazz.overrideMethod(c$,"isRna",function(){return this.group.isRna()});Clazz.overrideMethod(c$,"isPurine",function(){return this.group.isPurine()});
Clazz.overrideMethod(c$,"isPyrimidine",function(){return this.group.isPyrimidine()});$_M(c$,"getSeqcode",function(){return this.group.seqcode});Clazz.overrideMethod(c$,"getResno",function(){return this.group.getResno()});$_M(c$,"isClickable",function(){return!this.isVisible(0)?!1:0!=((this.shapeVisibilityFlags|this.group.shapeVisibilityFlags)&this.clickabilityFlags)});$_M(c$,"getClickabilityFlags",function(){return this.clickabilityFlags});$_M(c$,"setClickable",function(a){this.clickabilityFlags=
0==a?0:this.clickabilityFlags|a},"~N");$_M(c$,"isVisible",function(a){if(!this.isInFrame()||this.group.chain.model.modelSet.isAtomHidden(this.index))return!1;if(0!=a)return this.isShapeVisible(a);a=this.shapeVisibilityFlags;if(this.group.shapeVisibilityFlags!=J.modelset.Atom.BACKBONE_VISIBILITY_FLAG||this.isLeadAtom())a|=this.group.shapeVisibilityFlags;return 0!=(a&-2)},"~N");Clazz.overrideMethod(c$,"isLeadAtom",function(){return this.group.isLeadAtom(this.index)});$_M(c$,"getGroupParameter",function(a){return this.group.getGroupParameter(a)},
"~N");Clazz.overrideMethod(c$,"getChainID",function(){return this.group.chain.chainID});Clazz.overrideMethod(c$,"getChainIDStr",function(){return this.group.chain.getIDStr()});$_M(c$,"getSurfaceDistance100",function(){return this.group.chain.model.modelSet.getSurfaceDistance100(this.index)});$_M(c$,"getVibrationVector",function(){return this.group.chain.model.modelSet.getVibration(this.index,!1)});$_M(c$,"getVibrationCoord",function(a){return this.group.chain.model.modelSet.getVibrationCoord(this.index,
a)},"~S");$_M(c$,"getPolymerLength",function(){return this.group.getBioPolymerLength()});$_M(c$,"getPolymerIndexInModel",function(){return this.group.getBioPolymerIndexInModel()});$_M(c$,"getMonomerIndex",function(){return this.group.getMonomerIndex()});$_M(c$,"getSelectedGroupCountWithinChain",function(){return this.group.chain.selectedGroupCount});$_M(c$,"getSelectedGroupIndexWithinChain",function(){return this.group.getSelectedGroupIndex()});$_M(c$,"getSelectedMonomerCountWithinPolymer",function(){return this.group.getSelectedMonomerCount()});
$_M(c$,"getSelectedMonomerIndexWithinPolymer",function(){return this.group.getSelectedMonomerIndex()});$_M(c$,"getChain",function(){return this.group.chain});$_M(c$,"getModelNumberForLabel",function(){return this.group.chain.model.modelSet.getModelNumberForAtomLabel(this.modelIndex)});$_M(c$,"getModelNumber",function(){return this.group.chain.model.modelSet.getModelNumber(this.modelIndex)%1E6});$_M(c$,"getModelFileIndex",function(){return this.group.chain.model.fileIndex});$_M(c$,"getModelFileNumber",
function(){return this.group.chain.model.modelSet.getModelFileNumber(this.modelIndex)});Clazz.overrideMethod(c$,"getBioStructureTypeName",function(){return this.getProteinStructureType().getBioStructureTypeName(!0)});$_M(c$,"getProteinStructureType",function(){return this.group.getProteinStructureType()});$_M(c$,"getProteinStructureSubType",function(){return this.group.getProteinStructureSubType()});$_M(c$,"getStrucNo",function(){return this.group.getStrucNo()});$_M(c$,"getStructureId",function(){return this.group.getStructureId()});
$_M(c$,"getProteinStructureTag",function(){return this.group.getProteinStructureTag()});$_M(c$,"getGroupID",function(){return this.group.groupID});$_M(c$,"getSeqcodeString",function(){return this.group.getSeqcodeString()});$_M(c$,"getInsertionCode",function(){return this.group.getInsertionCode()});Clazz.overrideMethod(c$,"equals",function(a){return this===a},"~O");Clazz.overrideMethod(c$,"hashCode",function(){return this.index});$_M(c$,"findAromaticNeighbor",function(a){if(null==this.bonds)return null;
for(var b=this.bonds.length;0<=--b;){var c=this.bonds[b],d=c.getOtherAtom(this);if(c.isAromatic()&&d.index!=a)return d}return null},"~N");c$.atomPropertyInt=$_M(c$,"atomPropertyInt",function(a,b){switch(b){case 1095763969:return a.getAtomNumber();case 1095761922:return a.atomID;case 1095761923:return a.getIndex();case 1095761924:return a.getCovalentBondCount();case 1766856708:return a.group.chain.model.modelSet.viewer.getColorArgbOrGray(a.getColix());case 1087375365:case 1095763976:return a.getElementNumber();
case 1095761927:return a.atomicAndIsotopeNumber;case 1229984263:return a.getModelFileIndex()+1;case 1632634889:return a.getFormalCharge();case 1095761930:return a.getGroupID();case 1095761931:return a.group.getGroupIndex();case 1095766028:return a.getModelNumber();case -1095766028:return a.getModelFileNumber();case 1095761933:return a.modelIndex;case 1095761934:return a.getMoleculeNumber(!0);case 1129318401:return a.getOccupancy100();case 1095761935:return a.getGroup().getBioPolymerIndexInModel()+
1;case 1095761936:return a.getPolymerLength();case 1666189314:return a.getRasMolRadius();case 1095761937:return a.getResno();case 1095761938:return a.getAtomSite();case 1641025539:return a.getProteinStructureType().getId();case 1238369286:return a.getProteinStructureSubType().getId();case 1095761939:return a.getStrucNo();case 1095763988:return a.getValence()}return 0},"J.modelset.Atom,~N");c$.atomPropertyFloat=$_M(c$,"atomPropertyFloat",function(a,b,c){switch(c){case 1666189314:return b.getRadius();
case 1114638363:return a.isAtomSelected(b.index)?1:0;case 1112539151:return b.group.chain.model.modelSet.getSurfaceDistanceMax(),b.getSurfaceDistance100()/100;case 1112541199:return b.getBfactor100()/100;case 1114638362:return b.getHydrophobicity();case 1313866247:return b.getVolume(a,J.constant.EnumVdw.AUTO);case 1112539137:return b.getADPMinMax(!0);case 1112539138:return b.getADPMinMax(!1);case 1112541185:case 1112541205:return b.x;case 1112541186:case 1112541206:return b.y;case 1112541187:case 1112541207:return b.z;
case 1112539140:return b.getCovalentRadiusFloat();case 1112541188:return b.getFractionalCoord("X",!0);case 1112541189:return b.getFractionalCoord("Y",!0);case 1112541190:return b.getFractionalCoord("Z",!0);case 1112541191:return b.getFractionalCoord("X",!1);case 1112541192:return b.getFractionalCoord("Y",!1);case 1112541193:return b.getFractionalCoord("Z",!1);case 1112539147:return b.screenX;case 1112539148:return b.group.chain.model.modelSet.viewer.getScreenHeight()-b.screenY;case 1112539149:return b.screenZ;
case 1112541195:return b.getBondingRadiusFloat();case 1112539143:return b.getMass();case 1129318401:return b.getOccupancy100()/100;case 1112541196:return b.getPartialCharge();case 1112539145:case 1112539146:case 1112539144:if(b.group.chain.model.isJmolDataFrame&&b.group.chain.model.jmolFrameType.startsWith("plot ramachandran"))switch(c){case 1112539145:return b.getFractionalCoord("X",!1);case 1112539146:return b.getFractionalCoord("Y",!1);case 1112539144:if(b.group.chain.model.isJmolDataFrame&&b.group.chain.model.jmolFrameType.equals("plot ramachandran"))return a=
b.getFractionalCoord("Z",!1)-180,-180>a?360+a:a}return b.getGroupParameter(c);case 1112539141:case 1112539152:case 1112539150:return b.getGroupParameter(c);case 1113200651:return b.getRadius();case 1115297793:case 1113200642:case 1113198595:case 1113198596:case 1113198597:case 1113200646:case 1113200647:case 1113200649:case 1113200650:case 1113200652:case 1650071565:case 1113200654:return a.getAtomShapeValue(c,b.group,b.index);case 1112539153:return b.getFractionalUnitCoord("X");case 1112539154:return b.getFractionalUnitCoord("Y");
case 1112539155:return b.getFractionalUnitCoord("Z");case 1649412120:return b.getVanderwaalsRadiusFloat(a,J.constant.EnumVdw.AUTO);case 1112541202:return b.getVibrationCoord("X");case 1112541203:return b.getVibrationCoord("Y");case 1112541204:return b.getVibrationCoord("Z");case 1649410049:return b=b.getVibrationVector(),null==b?0:b.length()*a.getFloat(1649410049);case 1112539142:return a.getNMRCalculation().getMagneticShielding(b);case 1112539139:return a.getNMRCalculation().getChemicalShift(b)}return J.modelset.Atom.atomPropertyInt(b,
c)},"J.viewer.Viewer,J.modelset.Atom,~N");$_M(c$,"getMass",($fz=function(){var a=this.getIsotopeNumber();return 0<a?a:J.util.Elements.getAtomicMass(this.getElementNumber())},$fz.isPrivate=!0,$fz));c$.atomPropertyString=$_M(c$,"atomPropertyString",function(a,b,c){switch(c){case 1087373315:return a=b.getAlternateLocationID(),"\x00"==a?"":""+a;case 1087375362:return b.getAtomName();case 1087375361:return b.getAtomType();case 1087373316:return b.getChainIDStr();case 1087373320:return b.getGroup1("?");
case 1087373319:return b.getGroup1("\x00");case 1087373318:return b.getGroup3(!1);case 1087375365:return b.getElementSymbolIso(!0);case 1087373321:return b.getIdentity(!0);case 1087373322:return a=b.getInsertionCode(),"\x00"==a?"":""+a;case 1826248715:case 1288701960:return a=b.group.chain.model.modelSet.getAtomLabel(b.getIndex()),null==a&&(a=""),a;case 1641025539:return b.getProteinStructureType().getBioStructureTypeName(!1);case 1238369286:return b.getProteinStructureSubType().getBioStructureTypeName(!1);
case 1087373324:return b.getStructureId();case 1087373323:return a.getHybridizationAndAxes(b.index,null,null,"d");case 1087375373:return b.getElementSymbolIso(!1);case 1089470478:return b.getSymmetryOperatorList()}return""},"J.viewer.Viewer,J.modelset.Atom,~N");c$.atomPropertyTuple=$_M(c$,"atomPropertyTuple",function(a,b){switch(b){case 1146095627:return a.getFractionalCoordPt(!a.group.chain.model.isJmolDataFrame);case 1146095629:return a.getFractionalCoordPt(!1);case 1146093582:return a.group.chain.model.isJmolDataFrame?
a.getFractionalCoordPt(!1):a.getFractionalUnitCoordPt(!1);case 1146095628:return JU.P3.new3(a.screenX,a.group.chain.model.modelSet.viewer.getScreenHeight()-a.screenY,a.screenZ);case 1146095631:var c=a.getVibrationVector();null==c&&(c=new JU.V3);return c;case 1146095626:return a;case 1766856708:return J.util.ColorUtil.colorPointFromInt2(a.group.chain.model.modelSet.viewer.getColorArgbOrGray(a.getColix()))}return null},"J.modelset.Atom,~N");$_M(c$,"isWithinStructure",function(a){return this.group.isWithinStructure(a)},
"J.constant.EnumStructure");Clazz.overrideMethod(c$,"getOffsetResidueAtom",function(a,b){return this.group.chain.model.modelSet.getGroupAtom(this,b,a)},"~S,~N");Clazz.overrideMethod(c$,"isCrossLinked",function(a){return this.group.isCrossLinked(a.getGroup())},"J.util.JmolNode");Clazz.overrideMethod(c$,"getCrossLinkLeadAtomIndexes",function(a){return this.group.getCrossLinkLead(a)},"JU.List");Clazz.overrideMethod(c$,"toString",function(){return this.getInfo()});$_M(c$,"isWithinFourBonds",function(a){if(this.modelIndex!=
a.modelIndex)return!1;if(this.isCovalentlyBonded(a))return!0;for(var b=a.bonds,c=0;c<b.length;c++){var d=b[c].getOtherAtom(a);if(this.isCovalentlyBonded(d))return!0;for(var e=0;e<this.bonds.length;e++)if(this.bonds[e].getOtherAtom(this).isCovalentlyBonded(d))return!0}return!1},"J.modelset.Atom");Clazz.overrideMethod(c$,"findAtomsLike",function(a){return this.group.chain.model.modelSet.viewer.getAtomBitSet(a)},"~S");Clazz.defineStatics(c$,"VIBRATION_VECTOR_FLAG",1,"IS_HETERO_FLAG",2,"FLAG_MASK",3,
"RADIUS_MAX",16);c$.BACKBONE_VISIBILITY_FLAG=c$.prototype.BACKBONE_VISIBILITY_FLAG=J.viewer.JC.getShapeVisibilityFlag(9)}),Clazz.declarePackage("J.modelset"),Clazz.load(["java.lang.Float","JU.BS","$.V3"],"J.modelset.AtomCollection","java.lang.Character java.util.Arrays $.Hashtable JU.A4 $.ArrayUtil $.List $.M3 $.P3 $.ParserJS J.api.Interface J.atomdata.RadiusData J.constant.EnumPalette $.EnumStructure $.EnumVdw J.modelset.Group J.script.T J.util.BSUtil $.Elements $.Escape $.Logger $.Measure $.Parser $.Txt $.Vibration J.viewer.JC".split(" "),
function(){c$=Clazz.decorateAsClass(function(){this.atoms=this.g3d=this.viewer=null;this.atomCount=0;this.surfaceDistance100s=this.atomTensors=this.atomTensorList=this.hydrophobicities=this.ionicRadii=this.partialCharges=this.bfactor100s=this.occupancies=this.vibrations=this.atomSerials=this.atomTypes=this.atomNames=null;this.haveStraightness=!1;this.labeler=this.bsHidden=null;this.maxVanderwaalsRadius=this.maxBondingRadius=1.4E-45;this.hasBfactorRange=!1;this.surfaceDistanceMax=this.bfactor100Hi=
this.bfactor100Lo=0;this.bsSurface=null;this.nSurfaceAtoms=0;this.bspf=null;this.preserveState=!0;this.tainted=null;this.canSkipLoad=!0;this.aaRet=this.bsFoundRectangle=this.bsEmpty=null;Clazz.isClassDefined("J.modelset.AtomCollection.AtomSorter")||J.modelset.AtomCollection.$AtomCollection$AtomSorter$();this.bsModulated=null;Clazz.instantialize(this,arguments)},J.modelset,"AtomCollection");Clazz.prepareFields(c$,function(){this.bsHidden=new JU.BS;this.bsEmpty=new JU.BS;this.bsFoundRectangle=new JU.BS});
$_M(c$,"releaseModelSet",function(){this.releaseModelSetAC()});$_M(c$,"releaseModelSetAC",function(){this.atomTensors=this.ionicRadii=this.partialCharges=this.bfactor100s=this.occupancies=this.vibrations=this.atomSerials=this.atomTypes=this.atomNames=this.tainted=this.bsSurface=this.surfaceDistance100s=this.bspf=this.g3d=this.viewer=this.atoms=null});$_M(c$,"mergeAtomArrays",function(a){this.tainted=a.tainted;this.atomNames=a.atomNames;this.atomTypes=a.atomTypes;this.atomSerials=a.atomSerials;this.vibrations=
a.vibrations;this.occupancies=a.occupancies;this.bfactor100s=a.bfactor100s;this.ionicRadii=a.ionicRadii;this.partialCharges=a.partialCharges;this.atomTensors=a.atomTensors;this.atomTensorList=a.atomTensorList;this.bsModulated=a.bsModulated;this.setHaveStraightness(!1);this.surfaceDistance100s=null},"J.modelset.AtomCollection");$_M(c$,"setHaveStraightness",function(a){this.haveStraightness=a},"~B");$_M(c$,"getHaveStraightness",function(){return this.haveStraightness});$_M(c$,"getAtomPointVector",function(a){var b=
new JU.List;if(null!=a)for(var c=a.nextSetBit(0);0<=c;c=a.nextSetBit(c+1))b.addLast(this.atoms[c]);return b},"JU.BS");$_M(c$,"getAtomCount",function(){return this.atomCount});$_M(c$,"modelSetHasVibrationVectors",function(){return null!=this.vibrations});$_M(c$,"getAtomTypes",function(){return this.atomTypes});$_M(c$,"getPartialCharges",function(){return this.partialCharges});$_M(c$,"getIonicRadii",function(){return this.ionicRadii});$_M(c$,"getBFactors",function(){return this.bfactor100s});$_M(c$,
"getHydrophobicity",function(){return this.hydrophobicities});$_M(c$,"setBsHidden",function(a){this.bsHidden=a},"JU.BS");$_M(c$,"isAtomHidden",function(a){return this.bsHidden.get(a)},"~N");$_M(c$,"getAtomInfo",function(a,b){return null==b?this.atoms[a].getInfo():this.getLabeler().formatLabel(this.viewer,this.atoms[a],b)},"~N,~S");$_M(c$,"getLabeler",function(){return null==this.labeler?this.labeler=J.api.Interface.getOptionInterface("modelset.LabelToken"):this.labeler});$_M(c$,"getAtomInfoXYZ",function(a,
b){return this.atoms[a].getInfoXYZ(b)},"~N,~B");$_M(c$,"getElementSymbol",function(a){return this.atoms[a].getElementSymbol()},"~N");$_M(c$,"getElementNumber",function(a){return this.atoms[a].getElementNumber()},"~N");$_M(c$,"getElementName",function(a){return J.util.Elements.elementNameFromNumber(this.atoms[a].getAtomicAndIsotopeNumber())},"~N");$_M(c$,"getAtomName",function(a){return this.atoms[a].getAtomName()},"~N");$_M(c$,"getAtomNumber",function(a){return this.atoms[a].getAtomNumber()},"~N");
$_M(c$,"getAtomPoint3f",function(a){return this.atoms[a]},"~N");$_M(c$,"getAtomRadius",function(a){return this.atoms[a].getRadius()},"~N");$_M(c$,"getAtomVdwRadius",function(a,b){return this.atoms[a].getVanderwaalsRadiusFloat(this.viewer,b)},"~N,J.constant.EnumVdw");$_M(c$,"getAtomColix",function(a){return this.atoms[a].getColix()},"~N");$_M(c$,"getAtomChain",function(a){return this.atoms[a].getChainIDStr()},"~N");$_M(c$,"getQuaternion",function(a,b){return 0>a?null:this.atoms[a].group.getQuaternion(b)},
"~N,~S");$_M(c$,"getHelixData",function(a,b){var c=a.nextSetBit(0);return 0>c?"null":this.atoms[c].group.getHelixData(b,this.viewer.getQuaternionFrame(),this.viewer.getInt(553648146))},"JU.BS,~N");$_M(c$,"getAtomIndexFromAtomNumber",function(a,b){for(var c=0;c<this.atomCount;c++){var d=this.atoms[c];if(d.getAtomNumber()==a&&b.get(d.modelIndex))return c}return-1},"~N,JU.BS");$_M(c$,"setFormalCharges",function(a,b){if(null!=a)for(var c=a.nextSetBit(0);0<=c;c=a.nextSetBit(c+1))this.atoms[c].setFormalCharge(b),
this.taintAtom(c,4)},"JU.BS,~N");$_M(c$,"getAtomicCharges",function(){for(var a=Clazz.newFloatArray(this.atomCount,0),b=this.atomCount;0<=--b;)a[b]=this.atoms[b].getElementNumber();return a});$_M(c$,"getRadiusVdwJmol",function(a){return J.util.Elements.getVanderwaalsMar(a.getElementNumber(),J.constant.EnumVdw.JMOL)/1E3},"J.modelset.Atom");$_M(c$,"getMaxVanderwaalsRadius",function(){1.4E-45==this.maxVanderwaalsRadius&&this.findMaxRadii();return this.maxVanderwaalsRadius});$_M(c$,"findMaxRadii",function(){for(var a=
this.atomCount;0<=--a;){var b=this.atoms[a],c=b.getBondingRadiusFloat();c>this.maxBondingRadius&&(this.maxBondingRadius=c);b=b.getVanderwaalsRadiusFloat(this.viewer,J.constant.EnumVdw.AUTO);b>this.maxVanderwaalsRadius&&(this.maxVanderwaalsRadius=b)}});$_M(c$,"clearBfactorRange",function(){this.hasBfactorRange=!1});$_M(c$,"calcBfactorRange",($fz=function(a){if(!this.hasBfactorRange){this.bfactor100Lo=2147483647;this.bfactor100Hi=-2147483648;if(null==a)for(var b=0;b<this.atomCount;b++)this.setBf(b);
else for(b=a.nextSetBit(0);0<=b;b=a.nextSetBit(b+1))this.setBf(b);this.hasBfactorRange=!0}},$fz.isPrivate=!0,$fz),"JU.BS");$_M(c$,"setBf",($fz=function(a){a=this.atoms[a].getBfactor100();a<this.bfactor100Lo?this.bfactor100Lo=a:a>this.bfactor100Hi&&(this.bfactor100Hi=a)},$fz.isPrivate=!0,$fz),"~N");$_M(c$,"getBfactor100Lo",function(){this.hasBfactorRange||(this.viewer.global.rangeSelected?this.calcBfactorRange(this.viewer.getSelectionSet(!1)):this.calcBfactorRange(null));return this.bfactor100Lo});
$_M(c$,"getBfactor100Hi",function(){this.getBfactor100Lo();return this.bfactor100Hi});$_M(c$,"getSurfaceDistanceMax",function(){null==this.surfaceDistance100s&&this.calcSurfaceDistances();return this.surfaceDistanceMax});$_M(c$,"calculateVolume",function(a,b){var c=0;if(null!=a)for(var d=a.nextSetBit(0);0<=d;d=a.nextSetBit(d+1))c+=this.atoms[d].getVolume(this.viewer,b);return c},"JU.BS,J.constant.EnumVdw");$_M(c$,"getSurfaceDistance100",function(a){if(0==this.nSurfaceAtoms)return-1;null==this.surfaceDistance100s&&
this.calcSurfaceDistances();return this.surfaceDistance100s[a]},"~N");$_M(c$,"calcSurfaceDistances",($fz=function(){this.calculateSurface(null,-1)},$fz.isPrivate=!0,$fz));$_M(c$,"calculateSurface",function(a,b){0>b&&(b=3);var c=J.api.Interface.getOptionInterface("geodesic.EnvelopeCalculation").set(this.viewer,this.atomCount,null);c.calculate(new J.atomdata.RadiusData(null,b,J.atomdata.RadiusData.EnumType.ABSOLUTE,null),3.4028235E38,a,J.util.BSUtil.copyInvert(a,this.atomCount),!1,!1,!1,!0);var d=c.getPoints();
this.surfaceDistanceMax=0;this.bsSurface=c.getBsSurfaceClone();this.surfaceDistance100s=Clazz.newIntArray(this.atomCount,0);this.nSurfaceAtoms=J.util.BSUtil.cardinalityOf(this.bsSurface);if(0==this.nSurfaceAtoms||null==d||0==d.length)return d;for(var c=3.4028235E38==b?0:b,e=0;e<this.atomCount;e++)if(this.bsSurface.get(e))this.surfaceDistance100s[e]=0;else{for(var f=3.4028235E38,g=this.atoms[e],h=d.length;0<=--h;){var k=Math.abs(d[h].distance(g)-c);0>k&&J.util.Logger.debugging&&J.util.Logger.debug("draw d"+
h+" "+J.util.Escape.eP(d[h])+' "'+k+" ? "+g.getInfo()+'"');f=Math.min(k,f)}k=this.surfaceDistance100s[e]=Clazz.doubleToInt(Math.floor(100*f));this.surfaceDistanceMax=Math.max(this.surfaceDistanceMax,k)}return d},"JU.BS,~N");$_M(c$,"setAtomCoord2",function(a,b,c){var d=null,e=null,f=null,g=0,h=1;if(Clazz.instanceOf(c,JU.P3))d=c;else if(Clazz.instanceOf(c,JU.List)){f=c;if(0==(h=f.size()))return;g=1}else if(J.util.Escape.isAP(c)){e=c;if(0==(h=e.length))return;g=2}else return;c=0;if(null!=a)for(var k=
a.nextSetBit(0);0<=k;k=a.nextSetBit(k+1)){switch(g){case 1:if(c>=h)return;d=f.get(c++);break;case 2:if(c>=h)return;d=e[c++]}switch(b){case 1146095626:this.setAtomCoord(k,d.x,d.y,d.z);break;case 1146095627:this.atoms[k].setFractionalCoordTo(d,!0);this.taintAtom(k,2);break;case 1146095629:this.atoms[k].setFractionalCoordTo(d,!1);this.taintAtom(k,2);break;case 1146095631:this.setAtomVibrationVector(k,d)}}},"JU.BS,~N,~O");$_M(c$,"setAtomVibrationVector",($fz=function(a,b){this.setVibrationVector(a,b);
this.taintAtom(a,12)},$fz.isPrivate=!0,$fz),"~N,JU.T3");$_M(c$,"setAtomCoord",function(a,b,c,d){if(!(0>a||a>=this.atomCount)){var e=this.atoms[a];e.set(b,c,d);this.fixTrajectory(e);this.taintAtom(a,2)}},"~N,~N,~N,~N");$_M(c$,"fixTrajectory",($fz=function(a){var b=a.modelIndex;if(this.isTrajectory(b)){var c=null!=this.unitCells&&this.unitCells[b].getCoordinatesAreFractional(),d=this.trajectorySteps.get(b)[a.index-this.models[b].firstAtomIndex];d.set(a.x,a.y,a.z);c&&this.unitCells[b].toFractional(d,
!0)}},$fz.isPrivate=!0,$fz),"J.modelset.Atom");$_M(c$,"setAtomCoordRelative",function(a,b,c,d){if(!(0>a||a>=this.atomCount)){var e=this.atoms[a];e.x+=b;e.y+=c;e.z+=d;this.fixTrajectory(e);this.taintAtom(a,2)}},"~N,~N,~N,~N");$_M(c$,"setAtomsCoordRelative",function(a,b,c,d){if(null!=a)for(var e=a.nextSetBit(0);0<=e;e=a.nextSetBit(e+1))this.setAtomCoordRelative(e,b,c,d)},"JU.BS,~N,~N,~N");$_M(c$,"setAPa",function(a,b,c,d,e,f,g){var h=0;if(!(null!=f&&0==f.length||null==a)){for(var k=null!=f&&f.length==
this.atomCount||null!=g&&g.length==this.atomCount,l=a.nextSetBit(0);0<=l;l=a.nextSetBit(l+1)){k&&(h=l);if(null!=f){if(h>=f.length)return;d=f[h++];c=Clazz.floatToInt(d)}else if(null!=g){if(h>=g.length)return;e=g[h++]}var m=this.atoms[l];switch(b){case 1087375362:this.taintAtom(l,0);this.setAtomName(l,e);break;case 1095763969:this.taintAtom(l,13);this.setAtomNumber(l,c);break;case 1087375361:this.taintAtom(l,1);this.setAtomType(l,e);break;case 1112541185:case 1112541205:this.setAtomCoord(l,d,m.y,m.z);
break;case 1112541186:case 1112541206:this.setAtomCoord(l,m.x,d,m.z);break;case 1112541187:case 1112541207:this.setAtomCoord(l,m.x,m.y,d);break;case 1112541202:case 1112541203:case 1112541204:this.setVibrationVector2(l,b,d);break;case 1112541188:case 1112541189:case 1112541190:m.setFractionalCoord(b,d,!0);this.taintAtom(l,2);break;case 1112541191:case 1112541192:case 1112541193:m.setFractionalCoord(b,d,!1);this.taintAtom(l,2);break;case 1095763976:case 1087375365:this.setElement(m,c);break;case 1632634889:m.setFormalCharge(c);
this.taintAtom(l,4);break;case 1114638362:this.setHydrophobicity(l,d)&&this.taintAtom(l,5);break;case 1826248715:case 1288701960:this.viewer.setAtomLabel(e,l);break;case 1129318401:2>c&&(c=Clazz.doubleToInt(Math.floor(100*d)));this.setOccupancy(l,c)&&this.taintAtom(l,7);break;case 1112541196:this.setPartialCharge(l,d)&&this.taintAtom(l,8);break;case 1112541195:this.setIonicRadius(l,d)&&this.taintAtom(l,6);break;case 1666189314:case 1113200651:0>d?d=0:16<d&&(d=16);m.madAtom=Clazz.floatToShort(2E3*
d);break;case 1114638363:this.viewer.setSelectedAtom(m.index,0!=d);break;case 1112541199:this.setBFactor(l,d)&&this.taintAtom(l,9);break;case 1095763988:m.setValence(c);this.taintAtom(l,10);break;case 1649412120:m.setRadius(d)?this.taintAtom(l,11):this.untaint(l,11);break;default:J.util.Logger.error("unsettable atom property: "+J.script.T.nameOf(b))}}1114638363==b&&this.viewer.setSelectedAtom(-1,!1)}},"JU.BS,~N,~N,~N,~S,~A,~A");$_M(c$,"setElement",function(a,b){this.taintAtom(a.index,3);a.setAtomicAndIsotopeNumber(b);
a.setPaletteID(J.constant.EnumPalette.CPK.id);a.setColixAtom(this.viewer.getColixAtomPalette(a,J.constant.EnumPalette.CPK.id))},"J.modelset.Atom,~N");$_M(c$,"getVibrationCoord",function(a,b){if(null==this.vibrations||null==this.vibrations[a])return 0;switch(b){case "X":return this.vibrations[a].x;case "Y":return this.vibrations[a].y;default:return this.vibrations[a].z}},"~N,~S");$_M(c$,"getVibration",function(a,b){var c=null==this.vibrations?null:this.vibrations[a];return null==c&&b?new J.util.Vibration:
c},"~N,~B");$_M(c$,"setVibrationVector",function(a,b){if(!Float.isNaN(b.x)&&!Float.isNaN(b.y)&&!Float.isNaN(b.z)){if(null==this.vibrations||this.vibrations.length<a)this.vibrations=Array(this.atoms.length);Clazz.instanceOf(b,J.util.Vibration)?this.vibrations[a]=b:(null==this.vibrations[a]&&(this.vibrations[a]=new J.util.Vibration),this.vibrations[a].setT(b));this.atoms[a].setVibrationVector()}},"~N,JU.T3");$_M(c$,"setVibrationVector2",($fz=function(a,b,c){var d=this.getVibration(a,!0);switch(b){case 1112541202:d.x=
c;break;case 1112541203:d.y=c;break;case 1112541204:d.z=c}this.setAtomVibrationVector(a,d)},$fz.isPrivate=!0,$fz),"~N,~N,~N");$_M(c$,"setAtomName",function(a,b){var c=J.viewer.JC.lookupSpecialAtomID(b);this.atoms[a].atomID=c;0<c&&this.models[this.atoms[a].modelIndex].isBioModel||(null==this.atomNames&&(this.atomNames=Array(this.atoms.length)),this.atomNames[a]=b)},"~N,~S");$_M(c$,"setAtomType",function(a,b){null==this.atomTypes&&(this.atomTypes=Array(this.atoms.length));this.atomTypes[a]=b},"~N,~S");
$_M(c$,"setAtomNumber",function(a,b){null==this.atomSerials&&(this.atomSerials=Clazz.newIntArray(this.atoms.length,0));this.atomSerials[a]=b;return!0},"~N,~N");$_M(c$,"setOccupancy",function(a,b){if(null==this.occupancies){if(100==b)return!1;this.occupancies=Clazz.newByteArray(this.atoms.length,0);for(var c=this.atoms.length;0<=--c;)this.occupancies[c]=100}this.occupancies[a]=255<b?255:0>b?0:b;return!0},"~N,~N");$_M(c$,"setPartialCharge",function(a,b){if(Float.isNaN(b))return!1;if(null==this.partialCharges){if(0==
b&&!Float.$valueOf(b).equals(J.modelset.AtomCollection.MINUSZERO))return!1;this.partialCharges=Clazz.newFloatArray(this.atoms.length,0)}this.partialCharges[a]=b;return!0},"~N,~N");$_M(c$,"setIonicRadius",function(a,b){if(Float.isNaN(b))return!1;null==this.ionicRadii&&(this.ionicRadii=Clazz.newFloatArray(this.atoms.length,0));this.ionicRadii[a]=b;return!0},"~N,~N");$_M(c$,"setBFactor",function(a,b){if(Float.isNaN(b))return!1;if(null==this.bfactor100s){if(0==b&&null==this.bfactor100s)return!1;this.bfactor100s=
Clazz.newShortArray(this.atoms.length,0)}this.bfactor100s[a]=Clazz.doubleToShort(100*(-327.68>b?-327.68:327.67<b?327.67:b)+(0>b?-0.5:0.5));return!0},"~N,~N");$_M(c$,"setHydrophobicity",function(a,b){if(Float.isNaN(b))return!1;if(null==this.hydrophobicities){this.hydrophobicities=Clazz.newFloatArray(this.atoms.length,0);for(var c=0;c<this.atoms.length;c++)this.hydrophobicities[c]=J.util.Elements.getHydrophobicity(this.atoms[c].getGroupID())}this.hydrophobicities[a]=b;return!0},"~N,~N");$_M(c$,"setAtomData",
function(a,b,c,d){var e=null,f=null;switch(a){case 2:this.loadCoordinates(c,!1,!d);return;case 12:this.loadCoordinates(c,!0,!0);return;case 14:e=Clazz.newFloatArray(this.atomCount,0),f=J.util.BSUtil.newBitSet(this.atomCount)}d=J.util.Parser.markLines(c,";");var g=0;try{for(var h=JU.ParserJS.parseInt(c.substring(0,d[0]-1)),k=1;k<=h;k++){var l=JU.ParserJS.getTokens(JU.ParserJS.parseTrimmed(c.substring(d[k],d[k+1]-1))),m=JU.ParserJS.parseInt(l[0])-1;if(!(0>m||m>=this.atomCount)){var n=this.atoms[m];
g++;var q=l.length-1,p=JU.ParserJS.parseFloat(l[q]);switch(a){case 14:e[m]=p;f.set(m);continue;case 13:this.setAtomNumber(m,Clazz.floatToInt(p));break;case 0:this.setAtomName(m,l[q]);break;case 1:this.setAtomType(m,l[q]);break;case 3:n.setAtomicAndIsotopeNumber(Clazz.floatToInt(p));n.setPaletteID(J.constant.EnumPalette.CPK.id);n.setColixAtom(this.viewer.getColixAtomPalette(n,J.constant.EnumPalette.CPK.id));break;case 4:n.setFormalCharge(Clazz.floatToInt(p));break;case 5:this.setHydrophobicity(m,p);
break;case 6:this.setIonicRadius(m,p);break;case 8:this.setPartialCharge(m,p);break;case 9:this.setBFactor(m,p);break;case 10:n.setValence(Clazz.floatToInt(p));break;case 11:n.setRadius(p)}this.taintAtom(m,a)}}14==a&&0<g&&this.viewer.setData(b,[b,e,f,Integer.$valueOf(1)],0,0,0,0,0)}catch(r){if(Clazz.exceptionOf(r,Exception))J.util.Logger.error("AtomCollection.loadData error: "+r);else throw r;}},"~N,~S,~S,~B");$_M(c$,"loadCoordinates",($fz=function(a,b,c){var d=J.util.Parser.markLines(a,";"),e=b?
new JU.V3:null;try{for(var f=JU.ParserJS.parseInt(a.substring(0,d[0]-1)),g=1;g<=f;g++){var h=JU.ParserJS.getTokens(JU.ParserJS.parseTrimmed(a.substring(d[g],d[g+1]))),k=JU.ParserJS.parseInt(h[0])-1,l=JU.ParserJS.parseFloat(h[3]),m=JU.ParserJS.parseFloat(h[4]),n=JU.ParserJS.parseFloat(h[5]);b?(e.set(l,m,n),this.setAtomVibrationVector(k,e)):(this.setAtomCoord(k,l,m,n),c||this.untaint(k,2))}}catch(q){if(Clazz.exceptionOf(q,Exception))J.util.Logger.error("Frame.loadCoordinate error: "+q);else throw q;
}},$fz.isPrivate=!0,$fz),"~S,~B,~B");$_M(c$,"validateBspf",function(a){null!=this.bspf&&this.bspf.validate(a)},"~B");$_M(c$,"validateBspfForModel",function(a,b){null!=this.bspf&&this.bspf.validateModel(a,b)},"~N,~B");$_M(c$,"setPreserveState",function(a){this.preserveState=a},"~B");c$.getUserSettableType=$_M(c$,"getUserSettableType",function(a){var b=0==a.indexOf("property_");a=b?a.substring(9):a;for(var c=0;14>c;c++)if(J.modelset.AtomCollection.userSettableValues[c].equalsIgnoreCase(a))return c;
return b?14:-1},"~S");$_M(c$,"getTaintedAtoms",function(a){return null==this.tainted?null:this.tainted[a]},"~N");$_M(c$,"taintAtoms",function(a,b){this.canSkipLoad=!1;if(this.preserveState)for(var c=a.nextSetBit(0);0<=c;c=a.nextSetBit(c+1))this.taintAtom(c,b)},"JU.BS,~N");$_M(c$,"taintAtom",function(a,b){this.preserveState&&(null==this.tainted&&(this.tainted=Array(14)),null==this.tainted[b]&&(this.tainted[b]=J.util.BSUtil.newBitSet(this.atomCount)),this.tainted[b].set(a),2==b&&this.validateBspfForModel(this.models[this.atoms[a].modelIndex].trajectoryBaseIndex,
!1))},"~N,~N");$_M(c$,"untaint",($fz=function(a,b){this.preserveState&&(null==this.tainted||null==this.tainted[b]||this.tainted[b].clear(a))},$fz.isPrivate=!0,$fz),"~N,~N");$_M(c$,"setTaintedAtoms",function(a,b){this.preserveState&&(null==a?null!=this.tainted&&(this.tainted[b]=null):(null==this.tainted&&(this.tainted=Array(14)),null==this.tainted[b]&&(this.tainted[b]=J.util.BSUtil.newBitSet(this.atomCount)),J.util.BSUtil.copy2(a,this.tainted[b])))},"JU.BS,~N");$_M(c$,"unTaintAtoms",function(a,b){if(!(null==
this.tainted||null==this.tainted[b])){for(var c=a.nextSetBit(0);0<=c;c=a.nextSetBit(c+1))this.tainted[b].clear(c);0>this.tainted[b].nextSetBit(0)&&(this.tainted[b]=null)}},"JU.BS,~N");$_M(c$,"findNearest2",function(a,b,c,d,e){for(var f=null,g=this.atomCount;0<=--g;)if(!(null!=d&&d.get(g))){var h=this.atoms[g];h.isClickable()&&this.isCursorOnTopOf(h,a,b,e,f)&&(f=h)}c[0]=f},"~N,~N,~A,JU.BS,~N");$_M(c$,"isCursorOnTopOf",function(a,b,c,d,e){return 1<a.screenZ&&!this.g3d.isClippedZ(a.screenZ)&&this.g3d.isInDisplayRange(a.screenX,
a.screenY)&&a.isCursorOnTopOf(b,c,d,e)},"J.modelset.Atom,~N,~N,~N,J.modelset.Atom");$_M(c$,"findAtomsInRectangle",function(a,b){this.bsFoundRectangle.and(this.bsEmpty);for(var c=this.atomCount;0<=--c;){var d=this.atoms[c];b.get(d.modelIndex)&&(d.isVisible(0)&&a.contains(d.screenX,d.screenY))&&this.bsFoundRectangle.set(c)}return this.bsFoundRectangle},"J.util.Rectangle,JU.BS");$_M(c$,"fillADa",function(a,b){a.atomXyz=this.atoms;a.atomCount=this.atomCount;a.atomicNumber=Clazz.newIntArray(this.atomCount,
0);var c=0!=(b&2);c&&(a.atomRadius=Clazz.newFloatArray(this.atomCount,0));for(var d=0!=(b&16),e=0;e<this.atomCount;e++){var f=this.atoms[e];f.isDeleted()||!d&&0<=a.modelIndex&&f.modelIndex!=a.firstModelIndex?(null==a.bsIgnored&&(a.bsIgnored=new JU.BS),a.bsIgnored.set(e)):(a.atomicNumber[e]=f.getElementNumber(),a.lastModelIndex=f.modelIndex,c&&(a.atomRadius[e]=this.getWorkingRadius(f,a)))}},"J.atomdata.AtomData,~N");$_M(c$,"getWorkingRadius",($fz=function(a,b){var c=0,d=b.radiusData;switch(d.factorType){case J.atomdata.RadiusData.EnumType.ABSOLUTE:c=
d.value;break;case J.atomdata.RadiusData.EnumType.FACTOR:case J.atomdata.RadiusData.EnumType.OFFSET:switch(d.vdwType){case J.constant.EnumVdw.IONIC:c=a.getBondingRadiusFloat();break;case J.constant.EnumVdw.ADPMAX:c=a.getADPMinMax(!0);break;case J.constant.EnumVdw.ADPMIN:c=a.getADPMinMax(!1);break;default:c=a.getVanderwaalsRadiusFloat(this.viewer,b.radiusData.vdwType)}c=d.factorType===J.atomdata.RadiusData.EnumType.FACTOR?c*d.value:c+d.value}return c+d.valueExtended},$fz.isPrivate=!0,$fz),"J.modelset.Atom,J.atomdata.AtomData");
$_M(c$,"calculateHydrogens",function(a,b,c,d,e){var f=new JU.V3,g=new JU.V3,h=Array(this.atomCount),k=this.viewer.getDeletedAtoms(),l,m=0;if(null!=a)for(var n=a.nextSetBit(0);0<=n;n=a.nextSetBit(n+1))if(!(null!=k&&k.get(n))){var q=this.atoms[n],p=q.getElementNumber();if(!(d&&6!=p)){var r=6>=p?1.1:10>=p?1:1.3;switch(p){case 7:case 8:r=1}if(!(c&&0<q.getCovalentHydrogenCount())&&(l=this.getImplicitHydrogenCount(q,!1),0!=l)){var s=this.aaRet[0],t=this.aaRet[2],u=this.aaRet[3];h[n]=Array(l);var v=0;if(0==
u)switch(l){case 4:f.set(0.635,0.635,0.635),l=JU.P3.newP(f),l.add(q),h[n][v++]=l,null!=e&&e.addLast(q);case 3:f.set(-0.635,-0.635,0.635),l=JU.P3.newP(f),l.add(q),h[n][v++]=l,null!=e&&e.addLast(q);case 2:f.set(-0.635,0.635,-0.635),l=JU.P3.newP(f),l.add(q),h[n][v++]=l,null!=e&&e.addLast(q);case 1:f.set(0.635,-0.635,-0.635),l=JU.P3.newP(f),l.add(q),h[n][v++]=l,null!=e&&e.addLast(q)}else switch(l){case 3:this.getHybridizationAndAxes(n,p,f,g,"sp3b",!1,!0);l=new JU.P3;l.scaleAdd2(r,f,q);h[n][v++]=l;null!=
e&&e.addLast(q);this.getHybridizationAndAxes(n,p,f,g,"sp3c",!1,!0);l=new JU.P3;l.scaleAdd2(r,f,q);h[n][v++]=l;null!=e&&e.addLast(q);this.getHybridizationAndAxes(n,p,f,g,"sp3d",!1,!0);l=new JU.P3;l.scaleAdd2(r,f,q);h[n][v++]=l;null!=e&&e.addLast(q);break;case 2:t=2==t||5==p||1==u&&4==s||7==p&&this.isAdjacentSp2(q);this.getHybridizationAndAxes(n,p,f,g,t?"sp2b":3==s?"sp3c":"lpa",!1,!0);l=JU.P3.newP(f);l.scaleAdd2(r,f,q);h[n][v++]=l;null!=e&&e.addLast(q);this.getHybridizationAndAxes(n,p,f,g,t?"sp2c":
3==s?"sp3d":"lpb",!1,!0);l=JU.P3.newP(f);l.scaleAdd2(r,f,q);h[n][v++]=l;null!=e&&e.addLast(q);break;case 1:switch(s-u){case 1:if(8==p&&q===q.getGroup().getCarbonylOxygenAtom()){h[n]=null;continue}null!=this.getHybridizationAndAxes(n,p,f,g,2==t||5==p||7==p&&this.isAdjacentSp2(q)?"sp2c":"sp3d",!0,!1)?(l=JU.P3.newP(f),l.scaleAdd2(r,f,q),h[n][v++]=l,null!=e&&e.addLast(q)):h[n]=[];break;case 2:this.getHybridizationAndAxes(n,p,f,g,4==s?"sp2c":"sp2b",!1,!1);l=JU.P3.newP(f);l.scaleAdd2(r,f,q);h[n][v++]=l;
null!=e&&e.addLast(q);break;case 3:this.getHybridizationAndAxes(n,p,f,g,"spb",!1,!0),l=JU.P3.newP(f),l.scaleAdd2(r,f,q),h[n][v++]=l,null!=e&&e.addLast(q)}}m+=v}}}b[0]=m;return h},"JU.BS,~A,~B,~B,JU.List");$_M(c$,"isAdjacentSp2",($fz=function(a){for(var b=a.bonds,c=0;c<b.length;c++)for(var d=b[c].getOtherAtom(a).bonds,e=0;e<d.length;e++)switch(d[e].order){case 515:case 514:case 2:case 3:return!0}return!1},$fz.isPrivate=!0,$fz),"J.modelset.Atom");$_M(c$,"getImplicitHydrogenCount",function(a,b){var c=
a.getTargetValence();if(0>c)return 0;var d=a.getFormalCharge();null==this.aaRet&&(this.aaRet=Clazz.newIntArray(4,0));this.aaRet[0]=c;this.aaRet[1]=d;this.aaRet[2]=0;this.aaRet[3]=a.getCovalentBondCount();var e=this.models[a.modelIndex],e=e.isBioModel&&!e.isPdbWithMultipleBonds?a.group.getGroup3():null;null!=e&&0==d&&J.viewer.JC.getAminoAcidValenceAndCharge(e,a.getAtomName(),this.aaRet)&&(c=this.aaRet[0],d=this.aaRet[1]);0!=d&&(c+=4==c?-Math.abs(d):d,this.aaRet[0]=c);c-=a.getValence();return 0>c&&
!b?0:c},"J.modelset.Atom,~B");$_M(c$,"fixFormalCharges",function(a){for(var b=0,c=a.nextSetBit(0);0<=c;c=a.nextSetBit(c+1)){var d=this.atoms[c],e=this.getImplicitHydrogenCount(d,!0);if(0!=e){var f=d.getFormalCharge(),e=f-e;d.setFormalCharge(e);this.taintAtom(c,4);J.util.Logger.debugging&&J.util.Logger.debug("atom "+d+" formal charge "+f+" -> "+e);b++}}return b},"JU.BS");$_M(c$,"getHybridizationAndAxes",function(a,b,c,d,e,f,g){var h=0<e.length&&"-"==e.charAt(0)?e.substring(1):e;if(0<=e.indexOf("d")&&
!e.endsWith("sp3d"))return this.getHybridizationAndAxesD(a,c,d,h);var k=this.atoms[a];0==b&&(b=k.getElementNumber());var l=this.getAttached(k,4,f),m=l.length,n=h.charCodeAt(h.length-1)-97;if(0>n||6<n)n=0;a=new JU.V3;c.set(0,0,0);d.set(0,0,0);for(var q=Array(4),p=0;p<m;p++)q[p]=JU.V3.newVsub(k,l[p]),q[p].normalize(),c.add(q[p]);0<m&&d.setT(q[0]);p=!1;3<=m&&(2.984513>d.angle(q[1])?a.cross(d,q[1]):a.cross(d,q[2]),a.normalize(),e=new JU.V3,2.984513>q[1].angle(q[2])?e.cross(q[1],q[2]):e.cross(d,q[2]),
e.normalize(),p=0.95<=Math.abs(e.dot(a)));var r=0==h.indexOf("sp3"),s=!r&&0==h.indexOf("sp2"),t=!r&&!s&&0==h.indexOf("sp"),u=0==h.indexOf("p"),v=0==h.indexOf("lp");e=null;if(f){if(0==m)return null;if(r){if(3<n||4<m)return null}else if(s){if(2<n||3<m)return null}else if(t&&(1<n||2<m))return null;switch(m){case 1:if(1==b&&!r)return null;if(r){e="sp3";break}switch(l[0].getCovalentBondCount()){case 1:if(2!=l[0].getValence()){e="sp";break}case 2:e=t?"sp":"sp2";break;case 3:if(!s&&!u)return null;e="sp2"}break;
case 2:if(0.1>c.length()){if(0<=h.indexOf("2")||0<=h.indexOf("3"))return null;e="sp";break}e=r?"sp3":"sp2";if(0==h.indexOf("sp"))break;if(v){e="lp";break}e=h;break;default:if(p)e="sp2";else{if(v&&3==m){e="lp";break}e="sp3"}}if(null==e)return null;if(0==h.indexOf("p")){if("sp3"===e)return null}else if(0>h.indexOf(e))return null}if(n<m&&!h.startsWith("p")&&!h.startsWith("l"))return c.sub2(l[n],k),c.normalize(),e;switch(m){case 0:h.equals("sp3c")||h.equals("sp2d")||h.equals("lpa")?c.set(-0.5,-0.7,1):
h.equals("sp3b")||h.equals("lpb")?c.set(0.5,-0.7,-1):h.equals("sp3a")?c.set(0,1,0):c.set(0,0,1);d.set(1,0,0);break;case 1:a.setT(J.modelset.AtomCollection.vRef);d.cross(a,c);if(r){for(p=0;p<l[0].bonds.length;p++)if(l[0].bonds[p].isCovalent()&&l[0].getBondedAtomIndex(p)!=k.index&&(d.sub2(l[0],l[0].bonds[p].getOtherAtom(l[0])),d.cross(c,d),0!=d.length())){d.cross(d,c);break}d.normalize();Float.isNaN(d.x)&&(d.setT(J.modelset.AtomCollection.vRef),d.cross(d,c));a.cross(c,d);a.normalize();c.normalize();
d.scaleAdd2(2.828,d,c);3!=n&&(d.normalize(),b=JU.A4.new4(c.x,c.y,c.z,2.09439507*(2==n?1:-1)),g=new JU.M3,g.setIdentity(),g.setAA(b),g.transform(d));c.setT(d);d.cross(a,c);break}a.cross(d,c);switch(l[0].getCovalentBondCount()){case 1:if(2!=l[0].getValence())break;case 2:g=l[0];d.setT(c);for(a.setT(J.modelset.AtomCollection.vRef);null!=g&&2==g.getCovalentBondCount();){h=g.bonds;b=null;for(p=0;p<h.length;p++)if(h[p].isCovalent()&&(b=h[p].getOtherAtom(g),b!==k)){a.sub2(b,g);break}a.cross(a,d);if(0.1<
a.length()||2!=b.getCovalentBondCount())break;k=g;g=b}0.1<a.length()?(c.cross(a,d),c.normalize(),1==n&&c.scale(-1),c.scale(J.modelset.AtomCollection.sqrt3_2),c.scaleAdd2(0.5,d,c),u&&(a.cross(c,d),c.setT(a),a.setT(d)),d.cross(a,c)):(c.setT(d),d.cross(J.modelset.AtomCollection.vRef,d));break;case 3:this.getHybridizationAndAxes(l[0].index,0,d,a,"pz",!1,g),a.setT(d),s?(d.cross(d,c),1==n&&d.scale(-1),d.scale(J.modelset.AtomCollection.sqrt3_2),c.scaleAdd2(0.5,c,d)):(a.setT(c),c.setT(d)),d.cross(a,c)}break;
case 2:if(0.1>c.length()){if(!h.equals("pz")){b=l[0];(k=3==b.getCovalentBondCount())||(k=3==(b=l[1]).getCovalentBondCount());if(k){this.getHybridizationAndAxes(b.index,0,d,c,"pz",!1,g);h.equals("px")&&d.scale(-1);c.setT(q[0]);break}a.setT(J.modelset.AtomCollection.vRef);c.cross(a,d);a.cross(c,d)}c.setT(d);d.cross(a,c);break}a.cross(c,d);if(s){d.cross(c,a);break}if(r||v){a.normalize();c.normalize();h.equals("lp")||(0==n||2==n?c.scaleAdd2(-1.2,a,c):c.scaleAdd2(1.2,a,c));d.cross(c,a);break}d.cross(c,
a);c.setT(a);0>c.z&&(c.scale(-1),d.scale(-1));break;default:if(r)break;if(!p){d.cross(c,d);break}c.setT(a);0>c.z&&g&&(c.scale(-1),d.scale(-1))}d.normalize();c.normalize();return e},"~N,~N,JU.V3,JU.V3,~S,~B,~B");$_M(c$,"getHybridizationAndAxesD",($fz=function(a,b,c,d){d.startsWith("sp3d2")&&(d="d2sp3"+(5==d.length?"a":d.substring(5)));d.startsWith("sp3d")&&(d="dsp3"+(4==d.length?"a":d.substring(4)));if(d.equals("d2sp3")||d.equals("dsp3"))d+="a";var e=d.startsWith("dsp3"),f=d.charCodeAt(d.length-1)-
97;if(null!=b&&(!e&&(5<f||!d.startsWith("d2sp3"))||e&&4<f))return null;a=this.atoms[a];d=this.getAttached(a,6,!0);if(null==d)return null==b?null:"?";var g=d.length;if(3>g&&null!=b)return null;for(var h=f>=g,k=Clazz.doubleToInt(g*(g-1)/2),l=JU.ArrayUtil.newInt2(k),m=Clazz.newIntArray(3,0),k=Clazz.newIntArray(3,k,0),n=0,q=0,p=0;p<g-1;p++)for(var r=p+1;r<g;r++){var s=J.util.Measure.computeAngleABC(d[p],a,d[r],!0),s=105>s?0:150<=s?2:1;k[s][m[s]]=n;m[s]++;l[n++]=[p,r];0==p&&1==s&&q++}n=100*m[0]+10*m[1]+
m[2];if(null==b)switch(n){default:return"";case 0:return"";case 1:return"linear";case 100:case 10:return"bent";case 111:case 201:return"T-shaped";case 30:case 120:case 210:case 300:return 162<Math.abs(J.util.Measure.computeTorsion(d[0],a,d[1],d[2],!0))?"trigonal planar":"trigonal pyramidal";case 330:return 1==q%2?"tetrahedral":"uncapped trigonal pyramid";case 60:case 150:case 240:return"tetrahedral";case 402:return"square planar";case 411:case 501:return"see-saw";case 631:return"trigonal bipyramidal";
case 802:return"uncapped square pyramid";case 1203:return"octahedral"}switch(n){default:return null;case 201:break;case 210:case 330:case 411:case 631:if(!e)return null;break;case 300:case 402:case 501:case 802:case 1203:if(e)return null}if(h)if(e)switch(m[1]){case 0:b.sub2(d[l[k[0][0]][0]],a);c.sub2(d[l[k[0][0]][1]],a);b.cross(b,c);b.normalize();4==f&&b.scale(-1);m=this.findNotAttached(g,l,k[2],m[2]);p=m.nextSetBit(0);c.sub2(d[p],a);c.normalize();c.scale(0.5);b.scaleAdd2(J.modelset.AtomCollection.sqrt3_2,
b,c);f=-1;break;case 1:4==f?(c=l[k[1][0]],b.add2(d[c[0]],d[c[1]]),b.scaleAdd2(-2,a,b),f=-1):(m=this.findNotAttached(g,l,k[1],m[1]),f=m.nextSetBit(0));break;default:m=this.findNotAttached(g,l,k[1],m[1]),f=m.nextSetBit(0)}else{n=!1;if(4==g)switch(m[2]){case 1:m=this.findNotAttached(g,l,k[2],m[2]);p=m.nextSetBit(0);f=4==f?p:m.nextSetBit(p+1);break;default:n=!0}else{m=this.findNotAttached(g,l,k[2],m[2]);p=m.nextSetBit(0);for(r=g;r<f&&0<=p;r++)p=m.nextSetBit(p+1);-1==p?n=!0:f=p}n&&(b.sub2(d[l[k[0][0]][0]],
a),c.sub2(d[l[k[0][0]][1]],a),b.cross(b,c),4==f&&b.scale(-1),f=-1)}0<=f&&b.sub2(d[f],a);h&&b.scale(-1);b.normalize();return e?"dsp3":"d2sp3"},$fz.isPrivate=!0,$fz),"~N,JU.V3,JU.V3,~S");$_M(c$,"getAttached",($fz=function(a,b,c){var d=a.getCovalentBondCount();if(d>b)return null;b=Array(d);if(0<d){for(var d=a.bonds,e=0,f=0;f<d.length;f++)d[f].isCovalent()&&(b[e++]=d[f].getOtherAtom(a));c&&java.util.Arrays.sort(b,Clazz.innerTypeInstance(J.modelset.AtomCollection.AtomSorter,this,null))}return b},$fz.isPrivate=
!0,$fz),"J.modelset.Atom,~N,~B");$_M(c$,"findNotAttached",($fz=function(a,b,c,d){var e=J.util.BSUtil.newBitSet(a);e.setBits(0,a);for(var f=0;f<a;f++)for(var g=0;g<d;g++){var h=b[c[g]];(h[0]==f||h[1]==f)&&e.clear(f)}return e},$fz.isPrivate=!0,$fz),"~N,~A,~A,~N");$_M(c$,"getAtomBitsMDa",function(a,b){var c=new JU.BS,d,e,f=0;switch(a){case 1095763969:d=b.intValue();for(f=this.atomCount;0<=--f;)this.atoms[f].getAtomNumber()==d&&c.set(f);break;case 1087375362:d=","+b+",";for(f=this.atomCount;0<=--f;)e=
this.atoms[f].getAtomName(),0<=d.indexOf(e)&&0<=d.indexOf(","+e+",")&&c.set(f);break;case 1087375361:d=","+b+",";for(f=this.atomCount;0<=--f;)e=this.atoms[f].getAtomType(),0<=d.indexOf(e)&&0<=d.indexOf(","+e+",")&&c.set(f);break;case 1048613:d=b.intValue();for(f=this.atomCount;0<=--f;)this.atoms[f].getGroupID()==d&&c.set(f);break;case 1048609:return J.util.BSUtil.copy(this.getChainBits(b.intValue()));case 1048614:return J.util.BSUtil.copy(this.getSeqcodeBits(b.intValue(),!0));case 1613758470:for(f=
this.atomCount;0<=--f;)this.atoms[f].isHetero()&&c.set(f);break;case 1613758476:for(f=this.atomCount;0<=--f;)1==this.atoms[f].getElementNumber()&&c.set(f);break;case 3145744:for(f=this.atomCount;0<=--f;)this.atoms[f].isProtein()&&c.set(f);break;case 3145764:for(f=this.atomCount;0<=--f;)this.atoms[f].isCarbohydrate()&&c.set(f);break;case 137363468:case 3145760:e=137363468==a?J.constant.EnumStructure.HELIX:J.constant.EnumStructure.SHEET;for(f=this.atomCount;0<=--f;)this.atoms[f].isWithinStructure(e)&&
c.set(f);break;case 3145742:for(f=this.atomCount;0<=--f;)this.atoms[f].isNucleic()&&c.set(f);break;case 3145732:for(f=this.atomCount;0<=--f;)this.atoms[f].isDna()&&c.set(f);break;case 3145750:for(f=this.atomCount;0<=--f;)this.atoms[f].isRna()&&c.set(f);break;case 3145746:for(f=this.atomCount;0<=--f;)this.atoms[f].isPurine()&&c.set(f);break;case 3145748:for(f=this.atomCount;0<=--f;)this.atoms[f].isPyrimidine()&&c.set(f);break;case 1087375365:d=b;e=new JU.BS;for(f=d.nextSetBit(0);0<=f;f=d.nextSetBit(f+
1))e.set(this.getElementNumber(f));for(f=this.atomCount;0<=--f;)e.get(this.getElementNumber(f))&&c.set(f);break;case 1095761938:d=b;e=new JU.BS;for(f=d.nextSetBit(0);0<=f;f=d.nextSetBit(f+1))e.set(this.atoms[f].atomSite);for(f=this.atomCount;0<=--f;)e.get(this.atoms[f].atomSite)&&c.set(f);break;case 1073741824:return this.getIdentifierOrNull(b);case 1048608:d=b.toUpperCase();0<=d.indexOf("\\?")&&(d=J.util.Txt.simpleReplace(d,"\\?","\u0001"));for(f=this.atomCount;0<=--f;)this.isAtomNameMatch(this.atoms[f],
d,!1)&&c.set(f);break;case 1048607:for(f=this.atomCount;0<=--f;)this.atoms[f].isAlternateLocationMatch(b)&&c.set(f);break;case 1048612:return this.getSpecName(b)}if(0>f)return c;d=b;var g;e=d.nextSetBit(0);if(0>e)return c;f=0;switch(a){case 1087373318:for(f=e;0<=f;f=d.nextSetBit(f+1))e=this.atoms[f].getGroup().selectAtoms(c),e>f&&(f=e);break;case 1095766028:for(f=e;0<=f;f=d.nextSetBit(f+1))if(!c.get(f)){g=this.atoms[f].modelIndex;c.set(f);for(e=f;0<=--e;)if(this.atoms[e].modelIndex==g)c.set(e);else break;
for(;++f<this.atomCount;)if(this.atoms[f].modelIndex==g)c.set(f);else break}break;case 1087373316:d=J.util.BSUtil.copy(b);for(f=d.nextSetBit(0);0<=f;f=d.nextSetBit(f+1))this.atoms[f].getChain().setAtomBitSet(c),d.andNot(c);break;case 1095761935:for(f=e;0<=f;f=d.nextSetBit(f+1))if(!c.get(f)){g=this.atoms[f].getPolymerIndexInModel();c.set(f);for(e=f;0<=--e;)if(this.atoms[e].getPolymerIndexInModel()==g)c.set(e);else break;for(;++f<this.atomCount;)if(this.atoms[f].getPolymerIndexInModel()==g)c.set(f);
else break}break;case 1641025539:for(f=e;0<=f;f=d.nextSetBit(f+1))if(!c.get(f)){g=this.atoms[f].getGroup().getStructure();c.set(f);for(e=f;0<=--e;)if(this.atoms[e].getGroup().getStructure()===g)c.set(e);else break;for(;++f<this.atomCount;)if(this.atoms[f].getGroup().getStructure()===g)c.set(f);else break}}0==f&&J.util.Logger.error("MISSING getAtomBits entry for "+J.script.T.nameOf(a));return c},"~N,~O");$_M(c$,"getIdentifierOrNull",($fz=function(a){var b=this.getSpecNameOrNull(a,!1);0<=a.indexOf("\\?")&&
(a=J.util.Txt.simpleReplace(a,"\\?","\u0001"));if(null!=b||0<a.indexOf("?"))return b;if(0<a.indexOf("*"))return this.getSpecNameOrNull(a,!0);for(var c=a.length,d=0;d<c&&Character.isLetter(a.charAt(d));)++d;b=this.getSpecNameOrNull(a.substring(0,d),!1);if(d==c)return b;null==b&&(b=new JU.BS);for(var e=d;d<c&&Character.isDigit(a.charAt(d));)++d;var f=0;try{f=Integer.parseInt(a.substring(e,d))}catch(g){if(Clazz.exceptionOf(g,NumberFormatException))return null;throw g;}e=" ";d<c&&"^"==a.charAt(d)&&++d<
c&&(e=a.charAt(d));f=J.modelset.Group.getSeqcodeFor(f,e);f=this.getSeqcodeBits(f,!1);if(null==f){" "!=e&&(f=this.getSeqcodeBits(Character.toUpperCase(a.charAt(d)).charCodeAt(0),!1));if(null==f)return null;d++}b.and(f);if(d>=c)return b;if(d!=c-1)return null;b.and(this.getChainBits(a.charCodeAt(d)));return b},$fz.isPrivate=!0,$fz),"~S");$_M(c$,"getSpecName",($fz=function(a){var b=this.getSpecNameOrNull(a,!1);if(null!=b)return b;0<a.indexOf("*")&&(b=this.getSpecNameOrNull(a,!0));return null==b?new JU.BS:
b},$fz.isPrivate=!0,$fz),"~S");$_M(c$,"getSpecNameOrNull",($fz=function(a,b){var c=null;a=a.toUpperCase();0<=a.indexOf("\\?")&&(a=J.util.Txt.simpleReplace(a,"\\?","\u0001"));for(var d=this.atomCount;0<=--d;){var e=this.atoms[d].getGroup3(!0);if(null!=e&&0<e.length){if(J.util.Txt.isMatch(e,a,b,!0)){null==c&&(c=J.util.BSUtil.newBitSet(d+1));for(c.set(d);0<=--d&&this.atoms[d].getGroup3(!0).equals(e);)c.set(d);d++}}else this.isAtomNameMatch(this.atoms[d],a,b)&&(null==c&&(c=J.util.BSUtil.newBitSet(d+1)),
c.set(d))}return c},$fz.isPrivate=!0,$fz),"~S,~B");$_M(c$,"isAtomNameMatch",($fz=function(a,b,c){return J.util.Txt.isMatch(a.getAtomName().toUpperCase(),b,c,!1)},$fz.isPrivate=!0,$fz),"J.modelset.Atom,~S,~B");$_M(c$,"getSeqcodeBits",function(a,b){var c=new JU.BS,d=J.modelset.Group.getSeqNumberFor(a),e=2147483647!=d,f=!0,g=J.modelset.Group.getInsertionCodeChar(a);switch(g){case "?":for(var h=this.atomCount;0<=--h;){var k=this.atoms[h].getSeqcode();if(!e||d==J.modelset.Group.getSeqNumberFor(k)&&0!=
J.modelset.Group.getInsertionCodeFor(k))c.set(h),f=!1}break;default:for(h=this.atomCount;0<=--h;)if(k=this.atoms[h].getSeqcode(),a==k||!e&&a==J.modelset.Group.getInsertionCodeFor(k)||"*"==g&&d==J.modelset.Group.getSeqNumberFor(k))c.set(h),f=!1}return!f||b?c:null},"~N,~B");$_M(c$,"getChainBits",function(a){var b=256>a&&this.viewer.getBoolean(603979822);b||(a=J.modelset.AtomCollection.chainToUpper(a));for(var c=new JU.BS,d=J.util.BSUtil.newBitSet(this.atomCount),e,f=d.nextClearBit(0);f<this.atomCount;f=
d.nextClearBit(f+1)){var g=this.atoms[f].getChain();a==(e=g.chainID)||!b&&a==J.modelset.AtomCollection.chainToUpper(e)?(g.setAtomBitSet(c),d.or(c)):g.setAtomBitSet(d)}return c},"~N");c$.chainToUpper=$_M(c$,"chainToUpper",function(a){return String.fromCharCode(a).toUpperCase().charCodeAt(0)},"~N");$_M(c$,"getAtomIndices",function(a){for(var b=0,c=Clazz.newIntArray(this.atomCount,0),d=a.nextSetBit(0);0<=d&&d<this.atomCount;d=a.nextSetBit(d+1))c[d]=++b;return c},"JU.BS");$_M(c$,"getAtomsWithin",function(a,
b){for(var c=new JU.BS,d=this.atomCount;0<=--d;){var e=this.atoms[d],f=J.util.Measure.distanceToPlane(b,e);(0<a&&-0.1<=f&&f<=a||0>a&&0.1>=f&&f>=a||0==a&&0.01>Math.abs(f))&&c.set(e.index)}return c},"~N,JU.P4");$_M(c$,"getAtomsWithinBs",function(a,b,c){var d=new JU.BS;if(0==b.length||null!=c&&0==c.cardinality())return d;null==c&&(c=J.util.BSUtil.setAll(b.length));for(var e=this.atomCount;0<=--e;)for(var f=this.atoms[e],g=c.nextSetBit(0);0<=g;g=c.nextSetBit(g+1))if(f.distance(b[g])<a){d.set(e);break}return d},
"~N,~A,JU.BS");$_M(c$,"getVisibleSet",function(){for(var a=new JU.BS,b=this.atomCount;0<=--b;)this.atoms[b].isVisible(0)&&a.set(b);return a});$_M(c$,"getClickableSet",function(){for(var a=new JU.BS,b=this.atomCount;0<=--b;)this.atoms[b].isClickable()&&a.set(b);return a});$_M(c$,"isModulated",function(a){return null!=this.bsModulated&&this.bsModulated.get(a)},"~N");$_M(c$,"deleteModelAtoms",function(a,b,c){this.atoms=JU.ArrayUtil.deleteElements(this.atoms,a,b);this.atomCount=this.atoms.length;for(var d=
a;d<this.atomCount;d++)this.atoms[d].index=d,this.atoms[d].modelIndex--;null!=this.bsModulated&&J.util.BSUtil.deleteBits(this.bsModulated,c);this.deleteAtomTensors(c);this.atomNames=JU.ArrayUtil.deleteElements(this.atomNames,a,b);this.atomTypes=JU.ArrayUtil.deleteElements(this.atomTypes,a,b);this.atomSerials=JU.ArrayUtil.deleteElements(this.atomSerials,a,b);this.bfactor100s=JU.ArrayUtil.deleteElements(this.bfactor100s,a,b);this.hasBfactorRange=!1;this.occupancies=JU.ArrayUtil.deleteElements(this.occupancies,
a,b);this.partialCharges=JU.ArrayUtil.deleteElements(this.partialCharges,a,b);this.atomTensorList=JU.ArrayUtil.deleteElements(this.atomTensorList,a,b);this.vibrations=JU.ArrayUtil.deleteElements(this.vibrations,a,b);this.nSurfaceAtoms=0;this.surfaceDistance100s=this.bsSurface=null;if(null!=this.tainted)for(a=0;14>a;a++)J.util.BSUtil.deleteBits(this.tainted[a],c)},"~N,~N,JU.BS");$_M(c$,"getAtomIdentityInfo",function(a,b){b.put("_ipt",Integer.$valueOf(a));b.put("atomIndex",Integer.$valueOf(a));b.put("atomno",
Integer.$valueOf(this.getAtomNumber(a)));b.put("info",this.getAtomInfo(a,null));b.put("sym",this.getElementSymbol(a))},"~N,java.util.Map");$_M(c$,"getAtomTensorList",function(a){return 0>a||null==this.atomTensorList||a>=this.atomTensorList.length?null:this.atomTensorList[a]},"~N");$_M(c$,"deleteAtomTensors",($fz=function(a){if(null!=this.atomTensors){for(var b=new JU.List,c,d=this.atomTensors.keySet().iterator();d.hasNext()&&((c=d.next())||1);){for(var e=this.atomTensors.get(c),f=e.size();0<=--f;){var g=
e.get(f);(a.get(g.atomIndex1)||0<=g.atomIndex2&&a.get(g.atomIndex2))&&e.remove(f)}0==e.size()&&b.addLast(c)}for(f=b.size();0<=--f;)this.atomTensors.remove(b.get(f))}},$fz.isPrivate=!0,$fz),"JU.BS");$_M(c$,"setAtomTensors",function(a,b){if(!(null==b||0==b.size())){null==this.atomTensors&&(this.atomTensors=new java.util.Hashtable);null==this.atomTensorList&&(this.atomTensorList=Array(this.atoms.length));this.atomTensorList=JU.ArrayUtil.ensureLength(this.atomTensorList,this.atoms.length);this.atomTensorList[a]=
J.modelset.AtomCollection.getTensorList(b);for(var c=b.size();0<=--c;){var d=b.get(c);d.atomIndex1=a;d.atomIndex2=-1;d.modelIndex=this.atoms[a].modelIndex;this.addTensor(d,d.type);null!=d.altType&&this.addTensor(d,d.altType)}}},"~N,JU.List");c$.getTensorList=$_M(c$,"getTensorList",($fz=function(a){for(var b=-1,c=!1,d=a.size(),e=d;0<=--e;){var f=a.get(e);f.forThermalEllipsoid?b=e:2==f.iType&&(c=!0)}var g=Array((0<=b||!c?0:1)+d);if(0<=b&&(g[0]=a.get(b),1==a.size()))return g;if(c){b=0;for(e=d;0<=--e;)f=
a.get(e),f.forThermalEllipsoid||(g[++b]=f)}else for(e=0;e<d;e++)g[e]=a.get(e);return g},$fz.isPrivate=!0,$fz),"JU.List");$_M(c$,"getAtomTensor",function(a,b){var c=this.getAtomTensorList(a);if(null!=c&&null!=b){b=b.toLowerCase();for(var d=0;d<c.length;d++){var e=c[d];if(null!=e&&(b.equals(e.type)||b.equals(e.altType)))return e}}return null},"~N,~S");$_M(c$,"addTensor",function(a,b){b=b.toLowerCase();var c=this.atomTensors.get(b);null==c&&this.atomTensors.put(b,c=new JU.List);c.addLast(a)},"J.util.Tensor,~S");
$_M(c$,"getAllAtomTensors",function(a){if(null==this.atomTensors)return null;if(null!=a)return this.atomTensors.get(a.toLowerCase());a=new JU.List;for(var b,c=this.atomTensors.entrySet().iterator();c.hasNext()&&((b=c.next())||1);)a.addAll(b.getValue());return a},"~S");c$.$AtomCollection$AtomSorter$=function(){Clazz.pu$h();c$=Clazz.decorateAsClass(function(){Clazz.prepareCallback(this,arguments);Clazz.instantialize(this,arguments)},J.modelset.AtomCollection,"AtomSorter",null,java.util.Comparator);
Clazz.overrideMethod(c$,"compare",function(a,b){return a.index>b.index?1:a.index<b.index?-1:0},"J.modelset.Atom,J.modelset.Atom");c$=Clazz.p0p()};c$.MINUSZERO=c$.prototype.MINUSZERO=Float.$valueOf(-0);Clazz.defineStatics(c$,"TAINT_ATOMNAME",0,"TAINT_ATOMTYPE",1,"TAINT_COORD",2,"TAINT_ELEMENT",3,"TAINT_FORMALCHARGE",4,"TAINT_HYDROPHOBICITY",5,"TAINT_IONICRADIUS",6,"TAINT_OCCUPANCY",7,"TAINT_PARTIALCHARGE",8,"TAINT_TEMPERATURE",9,"TAINT_VALENCE",10,"TAINT_VANDERWAALS",11,"TAINT_VIBRATION",12,"TAINT_ATOMNO",
13,"TAINT_MAX",14,"userSettableValues","atomName atomType coord element formalCharge hydrophobicity ionic occupany partialCharge temperature valence vanderWaals vibrationVector atomNo".split(" "));14!=J.modelset.AtomCollection.userSettableValues.length&&J.util.Logger.error("AtomCollection.java userSettableValues is not length TAINT_MAX!");c$.sqrt3_2=c$.prototype.sqrt3_2=Math.sqrt(3)/2;c$.vRef=c$.prototype.vRef=JU.V3.new3(3.14159,2.71828,1.41421);Clazz.defineStatics(c$,"almost180",2.984513)}),Clazz.declarePackage("J.modelset"),
Clazz.load(null,"J.modelset.LabelToken","java.lang.Character $.Float java.util.Hashtable JU.SB J.modelset.Atom J.script.T J.util.Escape $.Txt".split(" "),function(){c$=Clazz.decorateAsClass(function(){this.data=this.key=this.text=null;this.tok=0;this.pt=-1;this.ch1="\x00";this.width=0;this.precision=2147483647;this.intAsFloat=this.zeroPad=this.alignLeft=!1;Clazz.instantialize(this,arguments)},J.modelset,"LabelToken");Clazz.makeConstructor(c$,function(){});$_M(c$,"set",($fz=function(a,b){this.text=
a;this.pt=b;return this},$fz.isPrivate=!0,$fz),"~S,~N");c$.isLabelPropertyTok=$_M(c$,"isLabelPropertyTok",($fz=function(a){for(var b=J.modelset.LabelToken.labelTokenIds.length;0<=--b;)if(J.modelset.LabelToken.labelTokenIds[b]==a)return!0;return!1},$fz.isPrivate=!0,$fz),"~N");c$.compile=$_M(c$,"compile",function(a,b,c,d){if(null==b||0==b.length)return null;if(0>b.indexOf("%")||2>b.length)return[(new J.modelset.LabelToken).set(b,-1)];for(var e=0,f=-1,g=b.length;++f<g&&0<=(f=b.indexOf("%",f));)e++;for(var e=
Array(2*e+1),h,k=0,f=0;0<=(h=b.indexOf("%",f));)f!=h&&(e[k++]=(new J.modelset.LabelToken).set(b.substring(f,h),-1)),f=e[k++]=(new J.modelset.LabelToken).set(null,h),a.autoCalculate(f.tok),f=J.modelset.LabelToken.setToken(a,b,f,g,c.charCodeAt(0),d);f<g&&(e[k++]=(new J.modelset.LabelToken).set(b.substring(f),-1));return e},"J.viewer.Viewer,~S,~S,java.util.Map");c$.formatLabel=$_M(c$,"formatLabel",function(a,b,c){if(null==c||0==c.length)return null;c=J.modelset.LabelToken.compile(a,c,"\x00",null);return J.modelset.LabelToken.formatLabelAtomArray(a,
b,c,"\x00",null)},"J.viewer.Viewer,J.modelset.Atom,~S");c$.formatLabelAtomArray=$_M(c$,"formatLabelAtomArray",function(a,b,c,d,e){if(null==b)return null;var f="0"<d?null:new JU.SB;if(null!=c)for(var g=0;g<c.length;g++){var h=c[g];if(null==h)break;"0"<d&&h.ch1!=d||(0>=h.tok||null!=h.key?null!=f&&(f.append(h.text),"\x00"!=h.ch1&&f.appendC(h.ch1)):J.modelset.LabelToken.appendAtomTokenValue(a,b,h,f,e))}return null==f?null:f.toString().intern()},"J.viewer.Viewer,J.modelset.Atom,~A,~S,~A");c$.getBondLabelValues=
$_M(c$,"getBondLabelValues",function(){var a=new java.util.Hashtable;a.put("#","");a.put("ORDER","");a.put("TYPE","");a.put("LENGTH",Float.$valueOf(0));a.put("ENERGY",Float.$valueOf(0));return a});c$.formatLabelBond=$_M(c$,"formatLabelBond",function(a,b,c,d,e){d.put("#",""+(b.index+1));d.put("ORDER",""+b.getOrderNumberAsString());d.put("TYPE",b.getOrderName());d.put("LENGTH",Float.$valueOf(b.atom1.distance(b.atom2)));d.put("ENERGY",Float.$valueOf(b.getEnergy()));J.modelset.LabelToken.setValues(c,
d);J.modelset.LabelToken.formatLabelAtomArray(a,b.atom1,c,"1",e);J.modelset.LabelToken.formatLabelAtomArray(a,b.atom2,c,"2",e);return J.modelset.LabelToken.getLabel(c)},"J.viewer.Viewer,J.modelset.Bond,~A,java.util.Map,~A");c$.formatLabelMeasure=$_M(c$,"formatLabelMeasure",function(a,b,c,d,e){var f=new java.util.Hashtable;f.put("#",""+(b.index+1));f.put("VALUE",Float.$valueOf(d));f.put("UNITS",e);c=J.modelset.LabelToken.compile(a,c,"\u0001",f);if(null==c)return"";J.modelset.LabelToken.setValues(c,
f);f=b.modelSet.atoms;b=b.getCountPlusIndices();for(d=b[0];1<=d;--d)0<=b[d]&&J.modelset.LabelToken.formatLabelAtomArray(a,f[b[d]],c,String.fromCharCode(48+d),null);c=J.modelset.LabelToken.getLabel(c);return null==c?"":c},"J.viewer.Viewer,J.modelset.Measurement,~S,~N,~S");c$.setValues=$_M(c$,"setValues",function(a,b){for(var c=0;c<a.length;c++){var d=a[c];if(null==d)break;if(null!=d.key){var e=b.get(d.key);d.text=Clazz.instanceOf(e,Float)?d.format(e.floatValue(),null,null):d.format(NaN,e,null)}}},
"~A,java.util.Map");c$.getLabel=$_M(c$,"getLabel",function(a){for(var b=new JU.SB,c=0;c<a.length;c++){var d=a[c];if(null==d)break;b.append(d.text)}return b.toString()},"~A");c$.setToken=$_M(c$,"setToken",($fz=function(a,b,c,d,e,f){var g=c.pt+1;if(g>=d)return g;var h;"-"==b.charAt(g)&&(c.alignLeft=!0,++g);g<d&&"0"==b.charAt(g)&&(c.zeroPad=!0,++g);for(;g<d&&Character.isDigit(h=b.charAt(g));)c.width=10*c.width+(h.charCodeAt(0)-48),++g;c.precision=2147483647;var k=!1;if(g<d&&"."==b.charAt(g)){++g;if(g<
d&&"-"==(h=b.charAt(g)))k=!0,++g;if(g<d&&Character.isDigit(h=b.charAt(g)))c.precision=h.charCodeAt(0)-48,k&&(c.precision=-1-c.precision),++g}if(g<d&&null!=f){var l;for(f=f.keySet().iterator();f.hasNext()&&((l=f.next())||1);)if(b.indexOf(l)==g)return g+(c.key=l).length}if(g<d)switch(h=b.charAt(g++)){case "%":return c.text="%",g;case "[":l=b.indexOf("]",g);if(l<g){g=d;break}g=b.substring(g,l).toLowerCase();g.startsWith("property_")?(c.text=g,c.tok=135270407,c.data=a.getDataFloat(c.text)):(a=J.script.T.getTokenFromName(g),
null!=a&&J.modelset.LabelToken.isLabelPropertyTok(a.tok)&&(c.tok=a.tok));g=l+1;break;case "{":l=b.indexOf("}",g);if(l<g){g=d;break}c.text=b.substring(g,l);c.data=a.getDataFloat(c.text);null==c.data?(c.data=a.getData(c.text),Clazz.instanceOf(c.data,Array)&&(c.data=c.data[1],Clazz.instanceOf(c.data,String)&&(c.data=J.util.Txt.split(c.data,"\n")),J.util.Escape.isAS(c.data)||(c.data=null)),c.tok=null==c.data?4:135266306):c.tok=135270407;g=l+1;break;default:var m,n;if(g<d&&0<=(m="fuv".indexOf(h))&&0<=
(n="xyz".indexOf(b.charAt(g))))c.tok=J.modelset.LabelToken.twoCharLabelTokenIds[3*m+n],g++;else if(0<=(m="AaBbCcDEefGgIiLlMmNnoPpQqRrSsTtUuVvWXxYyZz%%%gqW".indexOf(h)))c.tok=J.modelset.LabelToken.labelTokenIds[m]}c.text=b.substring(c.pt,g);if(g<d&&0!=e&&Character.isDigit(h=b.charAt(g)))g++,c.ch1=h,h.charCodeAt(0)!=e&&1!=e&&(c.tok=0);return g},$fz.isPrivate=!0,$fz),"J.viewer.Viewer,~S,J.modelset.LabelToken,~N,~N,java.util.Map");c$.appendAtomTokenValue=$_M(c$,"appendAtomTokenValue",($fz=function(a,
b,c,d,e){var f=null,g=NaN,h=null;try{switch(c.tok){case 1095761923:f=""+(null==e?b.index:e[b.index]);break;case 1766856708:h=J.modelset.Atom.atomPropertyTuple(b,c.tok);break;case 135270407:null!=c.data&&(g=c.data[b.index]);break;case 135266306:if(null!=c.data)var k=c.data,f=b.index<k.length?k[b.index]:"";break;case 1632634889:var l=b.getFormalCharge(),f=0<l?""+l+"+":0>l?""+-l+"-":"";break;case "g":f=""+b.getSelectedGroupIndexWithinChain();break;case 1095766028:f=b.getModelNumberForLabel();break;case 1129318401:f=
""+J.modelset.Atom.atomPropertyInt(b,c.tok);break;case "Q":g=b.getOccupancy100()/100;break;case 1666189314:g=J.modelset.Atom.atomPropertyFloat(a,b,c.tok);break;case "r":f=b.getSeqcodeString();break;case 1087373324:f=b.getStructureId();break;case 1095761939:var m=b.getStrucNo(),f=0>=m?"":""+m;break;case 1112539150:g=b.getGroupParameter(1112539150);Float.isNaN(g)&&(f="null");break;case 4:f=a.getModelAtomProperty(b,c.text.substring(2,c.text.length-1));break;case 1641025539:case 1238369286:f=J.modelset.Atom.atomPropertyString(a,
b,c.tok);break;case "W":f=b.getIdentityXYZ(!1);break;default:switch(c.tok&1137704960){case 1095761920:c.intAsFloat?g=J.modelset.Atom.atomPropertyInt(b,c.tok):f=""+J.modelset.Atom.atomPropertyInt(b,c.tok);break;case 1112539136:g=J.modelset.Atom.atomPropertyFloat(a,b,c.tok);break;case 1087373312:f=J.modelset.Atom.atomPropertyString(a,b,c.tok);break;case 1078984704:h=J.modelset.Atom.atomPropertyTuple(b,c.tok)}}}catch(n){if(Clazz.exceptionOf(n,IndexOutOfBoundsException))g=NaN,h=f=null;else throw n;}f=
c.format(g,f,h);null==d?c.text=f:d.append(f)},$fz.isPrivate=!0,$fz),"J.viewer.Viewer,J.modelset.Atom,J.modelset.LabelToken,JU.SB,~A");$_M(c$,"format",($fz=function(a,b,c){return Float.isNaN(a)?null!=b?J.util.Txt.formatS(b,this.width,this.precision,this.alignLeft,this.zeroPad):null!=c?(0==this.width&&2147483647==this.precision&&(this.width=6,this.precision=2),J.util.Txt.formatF(c.x,this.width,this.precision,!1,!1)+J.util.Txt.formatF(c.y,this.width,this.precision,!1,!1)+J.util.Txt.formatF(c.z,this.width,
this.precision,!1,!1)):this.text:J.util.Txt.formatF(a,this.width,this.precision,this.alignLeft,this.zeroPad)},$fz.isPrivate=!0,$fz),"~N,~S,JU.T3");Clazz.defineStatics(c$,"labelTokenParams","AaBbCcDEefGgIiLlMmNnoPpQqRrSsTtUuVvWXxYyZz%%%gqW","labelTokenIds",[1087373315,1087375362,1087375361,1112541199,1632634889,1087373316,1095761923,1087373322,1087375365,1112539145,1095761931,"g",1112541195,1095763969,1095761936,1095763976,1095766028,1087373319,1095761934,1087373318,1089470478,1112541196,1112539146,
"Q",1129318401,1095761937,"r",1095761938,1087373316,1112539150,1112541199,1087373321,1112539151,1649412120,1146095631,"W",1112541188,1112541185,1112541189,1112541186,1112541190,1112541187,1115297793,1113200642,1113198595,1113198596,1113198597,1113200646,1113200647,1113200649,1113200650,1113200652,1650071565,1113200654,1112539137,1112539138,1095761922,1095761924,1766856708,1095761930,1112539140,1229984263,1288701960,1826248715,1112539143,1095761933,1112539141,1112539144,1095761935,1716520985,1666189314,
1114638363,1087373323,1087373320,1113200651,1641025539,1238369286,1095761939,1087373324,1087375373,1112539152,1112539153,1112539154,1112539155,1095763988,1649410049,1112541202,1112541203,1112541204,1313866247,1146093582,1146095627,1146095626,1146095629,1112541191,1112541192,1112541193,1114638362,1112539147,1112539148,1112539149,1146095628,1112539142,1112539139],"STANDARD_LABEL","%[identify]","twoCharLabelTokenParams","fuv","twoCharLabelTokenIds",[1112541188,1112541189,1112541190,1112539153,1112539154,
1112539155,1112541202,1112541203,1112541204])}),Clazz.declarePackage("J.api"),Clazz.declareInterface(J.api,"JmolMeasurementClient"),Clazz.declarePackage("J.modelset"),Clazz.load(["J.api.JmolMeasurementClient"],"J.modelset.MeasurementData",["java.lang.Float","JU.List","J.modelset.Measurement","J.util.BSUtil"],function(){c$=Clazz.decorateAsClass(function(){this.points=this.measurements=this.measurementStrings=this.client=null;this.mustNotBeConnected=this.mustBeConnected=!1;this.tickInfo=null;this.tokAction=
1060866;this.note=this.strFormat=this.radiusData=null;this.isAll=!1;this.colix=0;this.intramolecular=null;this.mad=0;this.viewer=this.modelSet=this.minArray=this.units=this.atoms=this.text=this.thisID=null;this.iFirstAtom=0;this.justOneModel=!0;this.htMin=null;Clazz.instantialize(this,arguments)},J.modelset,"MeasurementData",null,J.api.JmolMeasurementClient);Clazz.makeConstructor(c$,function(){});$_M(c$,"init",function(a,b,c){this.viewer=b;this.points=c;this.thisID=a;return this},"~S,J.viewer.Viewer,JU.List");
$_M(c$,"setModelSet",function(a){this.modelSet=a;return this},"J.modelset.ModelSet");$_M(c$,"set",function(a,b,c,d,e,f,g,h,k,l,m,n,q){this.modelSet=this.viewer.getModelSet();this.tokAction=a;2<=this.points.size()&&(Clazz.instanceOf(this.points.get(0),JU.BS)&&Clazz.instanceOf(this.points.get(1),JU.BS))&&(this.justOneModel=J.util.BSUtil.haveCommon(this.viewer.getModelBitSet(this.points.get(0),!1),this.viewer.getModelBitSet(this.points.get(1),!1)));this.htMin=b;this.radiusData=c;this.strFormat=d;this.units=
e;this.tickInfo=f;this.mustBeConnected=g;this.mustNotBeConnected=h;this.intramolecular=k;this.isAll=l;this.mad=m;this.colix=n;this.text=q;return this},"~N,java.util.Map,J.atomdata.RadiusData,~S,~S,J.modelset.TickInfo,~B,~B,Boolean,~B,~N,~N,J.modelset.Text");$_M(c$,"processNextMeasure",function(a){var b=a.getMeasurement();if(!(null!=this.htMin&&!a.isMin(this.htMin)||null!=this.radiusData&&!a.isInRange(this.radiusData,b)))if(null==this.measurementStrings&&null==this.measurements){var c=this.minArray[this.iFirstAtom];
a.value=b;b=a.fixValue(this.units,!1);this.minArray[this.iFirstAtom]=-Infinity==1/c?b:Math.min(c,b)}else null!=this.measurementStrings?this.measurementStrings.addLast(a.getStringUsing(this.viewer,this.strFormat,this.units)):this.measurements.addLast(Float.$valueOf(a.getMeasurement()))},"J.modelset.Measurement");$_M(c$,"getMeasurements",function(a,b){if(b){this.minArray=Clazz.newFloatArray(this.points.get(0).cardinality(),0);for(var c=0;c<this.minArray.length;c++)this.minArray[c]=-0;this.define(null,
this.modelSet);return this.minArray}if(a)return this.measurements=new JU.List,this.define(null,this.modelSet),this.measurements;this.measurementStrings=new JU.List;this.define(null,this.modelSet);return this.measurementStrings},"~B,~B");$_M(c$,"define",function(a,b){this.client=null==a?this:a;this.atoms=b.atoms;var c=this.points.size();if(!(2>c)){var d=-1,e=Array(4),f=Clazz.newIntArray(5,0),g=(new J.modelset.Measurement).setPoints(b,f,e,null);g.setCount(c);for(var h=-1,k=0;k<c;k++){var l=this.points.get(k);
if(Clazz.instanceOf(l,JU.BS)){h=l.cardinality();if(0==h)return;1<h&&(d=0);h=k;0==k&&(this.iFirstAtom=0);f[k+1]=l.nextSetBit(0)}else e[k]=l,f[k+1]=-2-k}this.nextMeasure(0,h,g,d)}},"J.api.JmolMeasurementClient,J.modelset.ModelSet");$_M(c$,"nextMeasure",($fz=function(a,b,c,d){if(a>b)c.isValid()&&((!this.mustBeConnected||c.isConnected(this.atoms,a))&&(!this.mustNotBeConnected||!c.isConnected(this.atoms,a))&&(null==this.intramolecular||c.isIntramolecular(this.atoms,a)==this.intramolecular.booleanValue()))&&
this.client.processNextMeasure(c);else{var e=this.points.get(a),f=c.getCountPlusIndices(),g=0==a?2147483647:f[a];if(0>g)this.nextMeasure(a+1,b,c,d);else{for(var h=!1,k=e.nextSetBit(0),l=0;0<=k;k=e.nextSetBit(k+1),l++)if(k!=g){var m=this.atoms[k].getModelIndex();if(0<=d&&this.justOneModel)if(0==a)d=m;else if(d!=m)continue;f[a+1]=k;0==a&&(this.iFirstAtom=l);h=!0;this.nextMeasure(a+1,b,c,d)}h||this.nextMeasure(a+1,b,c,d)}}},$fz.isPrivate=!0,$fz),"~N,~N,J.modelset.Measurement,~N")}),Clazz.declarePackage("J.util"),
Clazz.load(["JU.P3","$.P3i","$.V3"],"J.util.BoxInfo",["java.util.Hashtable","JU.List","$.P4","J.util.Measure","$.Point3fi"],function(){c$=Clazz.decorateAsClass(function(){this.bbVertices=this.bbVector=this.bbCenter=this.bbCorner1=this.bbCorner0=null;this.isScaleSet=!1;this.margin=0;Clazz.instantialize(this,arguments)},J.util,"BoxInfo");Clazz.prepareFields(c$,function(){this.bbCorner0=new JU.P3;this.bbCorner1=new JU.P3;this.bbCenter=new JU.P3;this.bbVector=new JU.V3;this.bbVertices=Array(8);for(var a=
8;0<=--a;)this.bbVertices[a]=new J.util.Point3fi;for(a=0;8>a;a++)J.util.BoxInfo.unitBboxPoints[a]=JU.P3.new3(-1,-1,-1),J.util.BoxInfo.unitBboxPoints[a].scaleAdd2(2,J.util.BoxInfo.unitCubePoints[a],J.util.BoxInfo.unitBboxPoints[a])});Clazz.makeConstructor(c$,function(){this.reset()});$_M(c$,"intersectPlane",function(a,b,c,d){var e=new JU.List;e.addLast(this.getCanonicalCopy(c));return a.intersectPlane(b,e,d)},"J.modelset.ModelSet,JU.P4,~N,~N");$_M(c$,"getCanonicalCopy",function(a){return J.util.BoxInfo.getCanonicalCopy(this.bbVertices,
a)},"~N");c$.getCanonicalCopy=$_M(c$,"getCanonicalCopy",function(a,b){for(var c=Array(8),d=0;8>d;d++)c[J.util.BoxInfo.toCanonical[d]]=JU.P3.newP(a[d]);J.util.BoxInfo.scaleBox(c,b);return c},"~A,~N");c$.scaleBox=$_M(c$,"scaleBox",function(a,b){if(!(0==b||1==b)){for(var c=new JU.P3,d=new JU.V3,e=0;8>e;e++)c.add(a[e]);c.scale(0.125);for(e=0;8>e;e++)d.sub2(a[e],c),d.scale(b),a[e].add2(c,d)}},"~A,~N");c$.getFacesFromCriticalPoints=$_M(c$,"getFacesFromCriticalPoints",function(a){for(var b=Array(6),c=new JU.V3,
d=new JU.V3,e=new JU.V3,f=new JU.P3,g=new JU.P3,h=new JU.P3,k=Array(8),l=0;8>l;l++)k[l]=JU.P3.newP(a[0]),1==(l&1)&&k[l].add(a[1]),2==(l&2)&&k[l].add(a[2]),4==(l&4)&&k[l].add(a[3]);for(l=0;6>l;l++)f.setT(k[J.util.BoxInfo.facePoints[l].x]),g.setT(k[J.util.BoxInfo.facePoints[l].y]),h.setT(k[J.util.BoxInfo.facePoints[l].z]),J.util.Measure.getPlaneThroughPoints(f,g,h,c,d,e,b[l]=new JU.P4);return b},"~A");c$.getCriticalPoints=$_M(c$,"getCriticalPoints",function(a,b){var c=JU.P3.newP(a[0]),d=JU.P3.newP(a[1]),
e=JU.P3.newP(a[2]),f=JU.P3.newP(a[4]);d.sub(c);e.sub(c);f.sub(c);null!=b&&c.add(b);return[c,d,e,f]},"~A,JU.T3");$_M(c$,"getBoundBoxCenter",function(){this.isScaleSet||this.setBbcage(1);return this.bbCenter});$_M(c$,"getBoundBoxCornerVector",function(){this.isScaleSet||this.setBbcage(1);return this.bbVector});$_M(c$,"getBoundBoxPoints",function(a){this.isScaleSet||this.setBbcage(1);return a?[this.bbCenter,JU.P3.newP(this.bbVector),this.bbCorner0,this.bbCorner1]:[this.bbCorner0,this.bbCorner1]},"~B");
$_M(c$,"getBoundBoxVertices",function(){this.isScaleSet||this.setBbcage(1);return this.bbVertices});$_M(c$,"getBoundBoxInfo",function(){this.isScaleSet||this.setBbcage(1);var a=new java.util.Hashtable;a.put("center",JU.P3.newP(this.bbCenter));a.put("vector",JU.V3.newV(this.bbVector));a.put("corner0",JU.P3.newP(this.bbCorner0));a.put("corner1",JU.P3.newP(this.bbCorner1));return a});$_M(c$,"setBoundBox",function(a,b,c,d){if(null!=a){if(0==d)return;if(c){if(0==a.distance(b))return;this.bbCorner0.set(Math.min(a.x,
b.x),Math.min(a.y,b.y),Math.min(a.z,b.z));this.bbCorner1.set(Math.max(a.x,b.x),Math.max(a.y,b.y),Math.max(a.z,b.z))}else{if(0==b.x||0==b.y&&0==b.z)return;this.bbCorner0.set(a.x-b.x,a.y-b.y,a.z-b.z);this.bbCorner1.set(a.x+b.x,a.y+b.y,a.z+b.z)}}this.setBbcage(d)},"JU.P3,JU.P3,~B,~N");$_M(c$,"reset",function(){this.isScaleSet=!1;this.bbCorner0.set(3.4028235E38,3.4028235E38,3.4028235E38);this.bbCorner1.set(-3.4028235E38,-3.4028235E38,-3.4028235E38)});$_M(c$,"setMargin",function(a){this.margin=a},"~N");
$_M(c$,"addBoundBoxPoint",function(a){this.isScaleSet=!1;J.util.BoxInfo.addPoint(a,this.bbCorner0,this.bbCorner1,this.margin)},"JU.P3");c$.addPoint=$_M(c$,"addPoint",function(a,b,c,d){a.x-d<b.x&&(b.x=a.x-d);a.x+d>c.x&&(c.x=a.x+d);a.y-d<b.y&&(b.y=a.y-d);a.y+d>c.y&&(c.y=a.y+d);a.z-d<b.z&&(b.z=a.z-d);a.z+d>c.z&&(c.z=a.z+d)},"JU.P3,JU.P3,JU.P3,~N");c$.addPointXYZ=$_M(c$,"addPointXYZ",function(a,b,c,d,e,f){a-f<d.x&&(d.x=a-f);a+f>e.x&&(e.x=a+f);b-f<d.y&&(d.y=b-f);b+f>e.y&&(e.y=b+f);c-f<d.z&&(d.z=c-f);c+
f>e.z&&(e.z=c+f)},"~N,~N,~N,JU.P3,JU.P3,~N");$_M(c$,"setBbcage",function(a){this.isScaleSet=!0;this.bbCenter.add2(this.bbCorner0,this.bbCorner1);this.bbCenter.scale(0.5);this.bbVector.sub2(this.bbCorner1,this.bbCenter);0<a?this.bbVector.scale(a):(this.bbVector.x-=a/2,this.bbVector.y-=a/2,this.bbVector.z-=a/2);for(a=8;0<=--a;){var b=this.bbVertices[a];b.setT(J.util.BoxInfo.unitBboxPoints[a]);b.x*=this.bbVector.x;b.y*=this.bbVector.y;b.z*=this.bbVector.z;b.add(this.bbCenter)}this.bbCorner0.setT(this.bbVertices[0]);
this.bbCorner1.setT(this.bbVertices[7])},"~N");$_M(c$,"isWithin",function(a){this.isScaleSet||this.setBbcage(1);return a.x>=this.bbCorner0.x&&a.x<=this.bbCorner1.x&&a.y>=this.bbCorner0.y&&a.y<=this.bbCorner1.y&&a.z>=this.bbCorner0.z&&a.z<=this.bbCorner1.z},"JU.P3");Clazz.defineStatics(c$,"bbcageTickEdges","z\x00\x00yx\x00\x00\x00\x00\x00\x00\x00".split(""),"uccageTickEdges","zyx\x00\x00\x00\x00\x00\x00\x00\x00\x00".split(""),"edges",[0,1,0,2,0,4,1,3,1,5,2,3,2,6,3,7,4,5,4,6,5,7,6,7]);c$.unitCubePoints=
c$.prototype.unitCubePoints=[JU.P3.new3(0,0,0),JU.P3.new3(0,0,1),JU.P3.new3(0,1,0),JU.P3.new3(0,1,1),JU.P3.new3(1,0,0),JU.P3.new3(1,0,1),JU.P3.new3(1,1,0),JU.P3.new3(1,1,1)];c$.facePoints=c$.prototype.facePoints=[JU.P3i.new3(4,0,6),JU.P3i.new3(4,6,5),JU.P3i.new3(5,7,1),JU.P3i.new3(1,3,0),JU.P3i.new3(6,2,7),JU.P3i.new3(1,0,5)];Clazz.defineStatics(c$,"toCanonical",[0,3,4,7,1,2,5,6]);c$.cubeVertexOffsets=c$.prototype.cubeVertexOffsets=[JU.P3i.new3(0,0,0),JU.P3i.new3(1,0,0),JU.P3i.new3(1,0,1),JU.P3i.new3(0,
0,1),JU.P3i.new3(0,1,0),JU.P3i.new3(1,1,0),JU.P3i.new3(1,1,1),JU.P3i.new3(0,1,1)];c$.unitBboxPoints=c$.prototype.unitBboxPoints=Array(8)}),Clazz.declarePackage("J.modelset"),Clazz.load(["J.modelset.AtomCollection","JU.BS"],"J.modelset.BondCollection","java.lang.Float JU.ArrayUtil J.modelset.Bond $.BondIteratorSelected $.HBond J.util.BSUtil $.C $.JmolEdge $.Logger".split(" "),function(){c$=Clazz.decorateAsClass(function(){this.molecules=null;this.moleculeCount=0;this.bonds=null;this.bondCount=0;this.freeBonds=
this.numCached=null;this.haveWarned=!1;this.defaultCovalentMad=0;this.bsAromatic=this.bsAromaticDouble=this.bsAromaticSingle=null;this.haveHiddenBonds=!1;Clazz.instantialize(this,arguments)},J.modelset,"BondCollection",J.modelset.AtomCollection);Clazz.prepareFields(c$,function(){this.numCached=Clazz.newIntArray(5,0);this.freeBonds=Array(5);for(var a=5;0<--a;)this.freeBonds[a]=Array(200);this.bsAromatic=new JU.BS});Clazz.overrideMethod(c$,"releaseModelSet",function(){this.releaseModelSetBC()});$_M(c$,
"releaseModelSetBC",function(){this.freeBonds=this.bonds=null;this.releaseModelSetAC()});$_M(c$,"resetMolecules",function(){this.molecules=null;this.moleculeCount=0});$_M(c$,"getBondAt",function(a){return this.bonds[a]},"~N");$_M(c$,"getBondIteratorForType",function(a,b){return new J.modelset.BondIteratorSelected(this.bonds,this.bondCount,a,b,this.viewer.getBoolean(603979812))},"~N,JU.BS");$_M(c$,"getBondIterator",function(a){return new J.modelset.BondIteratorSelected(this.bonds,this.bondCount,131071,
a,!1)},"JU.BS");$_M(c$,"getBondAtom1",function(a){return this.bonds[a].atom1},"~N");$_M(c$,"getBondAtom2",function(a){return this.bonds[a].atom2},"~N");$_M(c$,"getBondRadius",function(a){return this.bonds[a].getRadius()},"~N");$_M(c$,"getBondOrder",function(a){return this.bonds[a].order},"~N");$_M(c$,"getBondColix1",function(a){return this.bonds[a].getColix1()},"~N");$_M(c$,"getBondColix2",function(a){return this.bonds[a].getColix2()},"~N");$_M(c$,"getBondModelIndex",function(a){return this.bonds[a].atom1.modelIndex},
"~N");$_M(c$,"getBondCountInModel",function(a){for(var b=0,c=this.bondCount;0<=--c;)this.bonds[c].atom1.modelIndex==a&&b++;return b},"~N");$_M(c$,"getBondsForSelectedAtoms",function(a,b){for(var c=new JU.BS,d=0;d<this.bondCount;++d){var e=this.bonds[d],f=a.get(e.atom1.index),e=a.get(e.atom2.index);((new Boolean(!b&f&e)).valueOf()||(new Boolean(b&(new Boolean(f|e)).valueOf())).valueOf())&&c.set(d)}return c},"JU.BS,~B");$_M(c$,"bondAtoms",function(a,b,c,d,e,f,g,h){c=this.getOrAddBond(a,b,c,d,e,f,!0);
h&&(c.order|=131072,g&&(a.group=b.group,a.group.addAtoms(a.index)));return c},"J.modelset.Atom,J.modelset.Atom,~N,~N,JU.BS,~N,~B,~B");$_M(c$,"getOrAddBond",($fz=function(a,b,c,d,e,f,g){if(131071==c||65535==c)c=1;a.isBonded(b)?(a=a.getBond(b).index,g&&(this.bonds[a].setOrder(c),this.bonds[a].setMad(d),Clazz.instanceOf(this.bonds[a],J.modelset.HBond)&&(this.bonds[a].energy=f))):(this.bondCount==this.bonds.length&&(this.bonds=JU.ArrayUtil.arrayCopyObject(this.bonds,this.bondCount+250)),a=this.setBond(this.bondCount++,
this.bondMutually(a,b,c,d,f)).index);null!=e&&e.set(a);return this.bonds[a]},$fz.isPrivate=!0,$fz),"J.modelset.Atom,J.modelset.Atom,~N,~N,JU.BS,~N,~B");$_M(c$,"setBond",function(a,b){return this.bonds[b.index=a]=b},"~N,J.modelset.Bond");$_M(c$,"bondMutually",function(a,b,c,d,e){c=J.modelset.Bond.isOrderH(c)?new J.modelset.HBond(a,b,c,d,0,e):new J.modelset.Bond(a,b,c,d,0);this.addBondToAtom(a,c);this.addBondToAtom(b,c);return c},"J.modelset.Atom,J.modelset.Atom,~N,~N,~N");$_M(c$,"addBondToAtom",($fz=
function(a,b){null==a.bonds?(a.bonds=Array(1),a.bonds[0]=b):a.bonds=this.addToBonds(b,a.bonds)},$fz.isPrivate=!0,$fz),"J.modelset.Atom,J.modelset.Bond");$_M(c$,"addToBonds",($fz=function(a,b){var c;if(null==b)c=0<this.numCached[1]?this.freeBonds[1][--this.numCached[1]]:Array(1),c[0]=a;else{var d=b.length;c=d+1;c=5>c&&0<this.numCached[c]?this.freeBonds[c][--this.numCached[c]]:Array(c);c[d]=a;for(var e=d;0<=--e;)c[e]=b[e];5>d&&200>this.numCached[d]&&(this.freeBonds[d][this.numCached[d]++]=b)}return c},
$fz.isPrivate=!0,$fz),"J.modelset.Bond,~A");$_M(c$,"addHBond",function(a,b,c,d){this.bondCount==this.bonds.length&&(this.bonds=JU.ArrayUtil.arrayCopyObject(this.bonds,this.bondCount+250));return this.setBond(this.bondCount++,this.bondMutually(a,b,c,1,d)).index},"J.modelset.Atom,J.modelset.Atom,~N,~N");c$.getBondOrderFull=$_M(c$,"getBondOrderFull",function(a,b,c,d,e){if(0==a||0==b||c<d)return 0;a=a+b+e;return c>a*a?0:1},"~N,~N,~N,~N,~N");$_M(c$,"checkValencesAndBond",function(a,b,c,d,e){if(20<a.getCurrentBondCount()||
20<b.getCurrentBondCount())return this.haveWarned||J.util.Logger.warn("maximum auto bond count reached"),this.haveWarned=!0,!1;var f=a.getFormalCharge();if(0!=f){var g=b.getFormalCharge();if(0>f&&0>g||0<f&&0<g)return!1}if(a.altloc!=b.altloc&&"\x00"!=a.altloc&&"\x00"!=b.altloc)return!1;this.getOrAddBond(a,b,c,d,e,0,!1);return!0},"J.modelset.Atom,J.modelset.Atom,~N,~N,JU.BS");$_M(c$,"deleteAllBonds2",function(){this.viewer.setShapeProperty(1,"reset",null);for(var a=this.bondCount;0<=--a;)this.bonds[a].deleteAtomReferences(),
this.bonds[a]=null;this.bondCount=0});$_M(c$,"getDefaultMadFromOrder",function(a){return J.modelset.Bond.isOrderH(a)?1:0!=(a&32768)?Clazz.doubleToInt(Math.floor(2E3*this.viewer.getFloat(570425406))):this.defaultCovalentMad},"~N");$_M(c$,"deleteConnections",function(a,b,c,d,e,f,g,h,k){var l=0>a,m=0>b,n=0,q=0;l&&(a=-a);m&&(b=-b);var p=new JU.BS,r=0,s=c|=131072;!g&&J.modelset.Bond.isOrderH(c)&&(c=30720);if(f)f=d;else{f=new JU.BS;for(var t=d.nextSetBit(0);0<=t;t=d.nextSetBit(t+1)){var u=this.atoms[t];
if(null!=u.bonds)for(var v=u.bonds.length;0<=--v;)e.get(u.getBondedAtomIndex(v))&&f.set(u.bonds[v].index)}}for(t=f.nextSetBit(0);t<this.bondCount&&0<=t;t=f.nextSetBit(t+1)){d=this.bonds[t];e=d.atom1;u=d.atom2;v=e.distanceSquared(u);if(l||m)n=e.distance(u),q=e.getBondingRadiusFloat()+u.getBondingRadiusFloat();if(!(l?n<q*a:v<h)&&!(m?n>q*b:v>k))if(g||s==(d.order&-257|131072)||0!=(c&d.order&30720))p.set(t),r++}0<r&&this.dBm(p,!1);return[0,r]},"~N,~N,~N,JU.BS,JU.BS,~B,~B,~N,~N");$_M(c$,"dBm",function(a,
b){this.deleteBonds(a,b)},"JU.BS,~B");$_M(c$,"dBb",function(a,b){var c=a.nextSetBit(0);if(!(0>c)){this.resetMolecules();for(var d=-1,e=a.cardinality(),f=c;f<this.bondCount;++f){var g=this.bonds[f];if(0<e&&a.get(f)){e--;if(!b){var h=g.atom1.modelIndex;h!=d&&this.models[d=h].resetBoundCount()}g.deleteAtomReferences()}else this.setBond(c++,g)}for(d=this.bondCount;--d>=c;)this.bonds[d]=null;this.bondCount=c;c=this.viewer.getShapeProperty(1,"sets");if(null!=c)for(d=0;d<c.length;d++)J.util.BSUtil.deleteBits(c[d],
a);J.util.BSUtil.deleteBits(this.bsAromatic,a)}},"JU.BS,~B");$_M(c$,"resetAromatic",function(){for(var a=this.bondCount;0<=--a;){var b=this.bonds[a];b.isAromatic()&&b.setOrder(515)}});$_M(c$,"assignAromaticBonds",function(){this.assignAromaticBondsBs(!0,null)});$_M(c$,"assignAromaticBondsBs",function(a,b){a||(this.bsAromatic=new JU.BS);this.bsAromaticSingle=new JU.BS;this.bsAromaticDouble=new JU.BS;for(var c=null==b,d=c?this.bondCount-1:b.nextSetBit(0),e=d;0<=e;e=c?e-1:b.nextSetBit(e+1)){var f=this.bonds[e];
this.bsAromatic.get(e)&&f.setOrder(515);switch(f.order&-131073){case 515:this.bsAromatic.set(e);break;case 513:this.bsAromaticSingle.set(e);break;case 514:this.bsAromaticDouble.set(e)}}for(e=d=(c=null==b)?this.bondCount-1:b.nextSetBit(0);0<=e;e=c?e-1:b.nextSetBit(e+1))f=this.bonds[e],f.is(515)&&(!this.bsAromaticDouble.get(e)&&!this.bsAromaticSingle.get(e))&&(this.assignAromaticDouble(f)||this.assignAromaticSingle(f));for(e=d;0<=e;e=c?e-1:b.nextSetBit(e+1))if(f=this.bonds[e],this.bsAromaticDouble.get(e))f.is(514)||
(this.bsAromatic.set(e),f.setOrder(514));else if((this.bsAromaticSingle.get(e)||f.isAromatic())&&!f.is(513))this.bsAromatic.set(e),f.setOrder(513);this.assignAromaticNandO(b);this.bsAromaticDouble=this.bsAromaticSingle=null},"~B,JU.BS");$_M(c$,"assignAromaticDouble",($fz=function(a){var b=a.index;if(this.bsAromaticSingle.get(b))return!1;if(this.bsAromaticDouble.get(b))return!0;this.bsAromaticDouble.set(b);return!this.assignAromaticSingleForAtom(a.atom1,b)||!this.assignAromaticSingleForAtom(a.atom2,
b)?(this.bsAromaticDouble.clear(b),!1):!0},$fz.isPrivate=!0,$fz),"J.modelset.Bond");$_M(c$,"assignAromaticSingle",($fz=function(a){var b=a.index;if(this.bsAromaticDouble.get(b))return!1;if(this.bsAromaticSingle.get(b))return!0;this.bsAromaticSingle.set(b);return!this.assignAromaticDoubleForAtom(a.atom1)||!this.assignAromaticDoubleForAtom(a.atom2)?(this.bsAromaticSingle.clear(b),!1):!0},$fz.isPrivate=!0,$fz),"J.modelset.Bond");$_M(c$,"assignAromaticSingleForAtom",($fz=function(a,b){var c=a.bonds;if(null==
c||this.assignAromaticSingleHetero(a))return!1;for(var d=c.length;0<=--d;){var e=c[d],f=e.index;if(!(f==b||!e.isAromatic()||this.bsAromaticSingle.get(f)))if(this.bsAromaticDouble.get(f)||!this.assignAromaticSingle(e))return!1}return!0},$fz.isPrivate=!0,$fz),"J.modelset.Atom,~N");$_M(c$,"assignAromaticDoubleForAtom",($fz=function(a){var b=a.bonds;if(null==b)return!1;a=this.assignAromaticSingleHetero(a);for(var c=-1,d=b.length;0<=--d;)this.bsAromaticDouble.get(b[d].index)&&(a=!0),b[d].isAromatic()&&
(c=d);for(d=b.length;0<=--d;){var e=b[d],f=e.index;if(e.isAromatic()&&!this.bsAromaticDouble.get(f)&&!this.bsAromaticSingle.get(f))if(!a&&this.assignAromaticDouble(e))a=!0;else if((a||d<c)&&!this.assignAromaticSingle(e))return!1}return a},$fz.isPrivate=!0,$fz),"J.modelset.Atom");$_M(c$,"assignAromaticSingleHetero",($fz=function(a){var b=a.getElementNumber();switch(b){case 6:case 7:case 8:case 16:break;default:return!0}var c=a.getValence();switch(b){case 6:return 4==c;case 7:case 8:return c==10-b&&
1>a.getFormalCharge();case 16:return c==18-b&&1>a.getFormalCharge()}return!1},$fz.isPrivate=!0,$fz),"J.modelset.Atom");$_M(c$,"assignAromaticNandO",($fz=function(a){for(var b,c=null==a,d=c?this.bondCount-1:a.nextSetBit(0);0<=d;d=c?d-1:a.nextSetBit(d+1))if(b=this.bonds[d],b.is(513)){var e,f=b.atom2,g,h=f.getElementNumber();7==h||8==h?(g=h,e=f,f=b.atom1,h=f.getElementNumber()):(e=b.atom1,g=e.getElementNumber());if(!(7!=g&&8!=g)){var k=e.getValence();if(!(0>k)){var l=e.getCovalentBondCount();e=e.getFormalCharge();
switch(g){case 7:3==k&&(3==l&&1>e&&6==h&&3==f.getValence())&&b.setOrder(514);break;case 8:1==k&&(0==e&&(14==h||16==h))&&b.setOrder(514)}}}}},$fz.isPrivate=!0,$fz),"JU.BS");$_M(c$,"getAtomBitsMDb",function(a,b){var c;switch(a){default:return this.getAtomBitsMDa(a,b);case 1678770178:c=new JU.BS;for(var d=b.nextSetBit(0);0<=d;d=b.nextSetBit(d+1))c.set(this.bonds[d].atom1.index),c.set(this.bonds[d].atom2.index);return c;case 1048585:c=new JU.BS;for(d=this.bondCount;0<=--d;)this.bonds[d].isAromatic()&&
(c.set(this.bonds[d].atom1.index),c.set(this.bonds[d].atom2.index));return c}},"~N,~O");$_M(c$,"setBondOrder",function(a,b){var c=b.charCodeAt(0)-48,d=this.bonds[a];switch(b){case "0":case "1":case "2":case "3":break;case "p":case "m":c=J.util.JmolEdge.getBondOrderNumberFromOrder(d.getCovalentOrder()).charCodeAt(0)-48+("p"==b?1:-1);3<c?c=1:0>c&&(c=3);break;default:return null}var e=new JU.BS;try{if(0==c){var f=new JU.BS;f.set(d.index);e.set(d.getAtomIndex1());e.set(d.getAtomIndex2());this.dBm(f,!1);
return e}d.setOrder(c|131072);this.removeUnnecessaryBonds(d.atom1,!1);this.removeUnnecessaryBonds(d.atom2,!1);e.set(d.getAtomIndex1());e.set(d.getAtomIndex2())}catch(g){if(Clazz.exceptionOf(g,Exception))J.util.Logger.error("Exception in seBondOrder: "+g.toString());else throw g;}return e},"~N,~S");$_M(c$,"removeUnnecessaryBonds",function(a,b){var c=new JU.BS,d=new JU.BS,e=a.bonds;if(null!=e){for(var f=0;f<e.length;f++)e[f].isCovalent()?1==e[f].getOtherAtom(a).getElementNumber()&&c.set(e[f].getOtherAtom(a).index):
d.set(e[f].index);0<=d.nextSetBit(0)&&this.dBm(d,!1);b&&c.set(a.index);0<=c.nextSetBit(0)&&this.viewer.deleteAtoms(c,!1)}},"J.modelset.Atom,~B");$_M(c$,"displayBonds",function(a,b){b||(this.haveHiddenBonds=!0);for(var c=a.nextSetBit(0);0<=c;c=a.nextSetBit(c+1))c<this.bondCount&&0!=this.bonds[c].mad&&this.bonds[c].setShapeVisibility(b)},"J.modelset.Bond.BondSet,~B");$_M(c$,"setBondParametersBS",function(a,b,c,d,e,f,g){if(null==c)this.setBondParameters(a,b,d,e,f,g);else for(b=c.nextSetBit(0);0<=b;b=
c.nextSetBit(b+1))this.setBondParameters(a,b,d,e,f,g)},"~N,~N,JU.BS,~N,~N,~N,~N");$_M(c$,"setBondParameters",function(a,b,c,d,e,f){0>b||b>=this.bondCount||(b=this.bonds[b],0<=a&&b.atom1.modelIndex!=a||(Float.isNaN(c)||(b.mad=Clazz.floatToShort(2E3*c)),a=b.colix,2147483647!=e&&(a=J.util.C.getColix(e)),Float.isNaN(f)?b.colix!=a&&(b.colix=J.util.C.copyColixTranslucency(b.colix,a)):b.colix=J.util.C.getColixTranslucent3(a,0!=f,f),1==d?b.order&=-65537:0==d&&(b.order|=65536)))},"~N,~N,~N,~N,~N,~N");Clazz.defineStatics(c$,
"BOND_GROWTH_INCREMENT",250,"MAX_BONDS_LENGTH_TO_CACHE",5,"MAX_NUM_TO_CACHE",200)}),Clazz.declarePackage("J.modelset"),Clazz.load(["J.modelset.BondCollection","JU.BS","$.List","$.P3","J.util.BoxInfo"],"J.modelset.ModelCollection","java.lang.Character $.Float java.util.Date $.Hashtable JU.ArrayUtil $.P4 $.ParserJS $.SB $.V3 J.api.Interface J.bspt.Bspf J.constant.EnumPalette $.EnumVdw J.io.XmlUtil J.modelset.Atom $.AtomIteratorWithinModel $.AtomIteratorWithinModelSet $.Bond $.HBond $.LabelToken $.Model J.util.BSUtil $.Elements $.Escape $.JmolEdge $.JmolMolecule $.Logger $.Quaternion $.Txt J.viewer.Viewer".split(" "),
function(){c$=Clazz.decorateAsClass(function(){this.models=this.modelSetName=this.bsSymmetry=null;this.modelCount=0;this.unitCells=null;this.haveUnitCells=!1;this.elementsPresent=this.frameTitles=this.modelNames=this.modelNumbersForAtomLabel=this.modelFileNumbers=this.modelNumbers=null;this.isPDB=this.isXYZ=!1;this.modelSetAuxiliaryInfo=this.modelSetProperties=null;this.someModelsHaveFractionalCoordinates=this.someModelsHaveAromaticBonds=this.someModelsHaveSymmetry=!1;this.averageAtomPoint=this.ptTemp=
null;this.isBbcageDefault=!1;this.stateScripts=this.boxInfo=this.bboxAtoms=this.bboxModels=null;this.thisStateModel=0;this.selectedMolecules=this.vibrationSteps=this.trajectorySteps=null;this.selectedMoleculeCount=0;this.showRebondTimes=!0;this.ptTemp2=this.ptTemp1=this.shapeManager=this.bsAll=null;this.proteinStructureTainted=!1;this.triangulator=this.vOrientations=this.htPeaks=this.symTemp=null;Clazz.instantialize(this,arguments)},J.modelset,"ModelCollection",J.modelset.BondCollection);Clazz.prepareFields(c$,
function(){this.models=Array(1);this.modelNumbers=Clazz.newIntArray(1,0);this.modelFileNumbers=Clazz.newIntArray(1,0);this.modelNumbersForAtomLabel=Array(1);this.modelNames=Array(1);this.frameTitles=Array(1);this.ptTemp=new JU.P3;this.averageAtomPoint=new JU.P3;this.boxInfo=new J.util.BoxInfo;this.boxInfo.addBoundBoxPoint(JU.P3.new3(-10,-10,-10));this.boxInfo.addBoundBoxPoint(JU.P3.new3(10,10,10));this.stateScripts=new JU.List;this.selectedMolecules=new JU.BS;this.ptTemp1=new JU.P3;this.ptTemp2=new JU.P3});
$_M(c$,"mergeModelArrays",function(a){this.atoms=a.atoms;this.bonds=a.bonds;this.stateScripts=a.stateScripts;this.proteinStructureTainted=a.proteinStructureTainted;this.thisStateModel=-1;this.bsSymmetry=a.bsSymmetry;this.modelFileNumbers=a.modelFileNumbers;this.modelNumbersForAtomLabel=a.modelNumbersForAtomLabel;this.modelNames=a.modelNames;this.modelNumbers=a.modelNumbers;this.frameTitles=a.frameTitles;this.mergeAtomArrays(a)},"J.modelset.ModelSet");Clazz.overrideMethod(c$,"releaseModelSet",function(){this.unitCells=
this.bsAll=this.bsSymmetry=this.models=null;this.releaseModelSetBC()});$_M(c$,"getUnitCell",function(a){return!this.haveUnitCells||0>a||a>=this.modelCount?null:null!=this.models[a].simpleCage?this.models[a].simpleCage:null==this.unitCells||a>=this.unitCells.length||!this.unitCells[a].haveUnitCell()?null:this.unitCells[a]},"~N");$_M(c$,"setModelCage",function(a,b){0>a||a>=this.modelCount||(this.models[a].simpleCage=b,this.haveUnitCells=!0)},"~N,J.api.SymmetryInterface");$_M(c$,"getPlaneIntersection",
function(a,b,c,d,e){var f=null;switch(a){case 1614417948:f=this.getUnitCell(e);if(null==f)return null;f=f.getCanonicalCopy(c);break;case 1679429641:f=this.boxInfo.getCanonicalCopy(c)}c=new JU.List;c.addLast(f);return this.intersectPlane(b,c,d)},"~N,JU.P4,~N,~N,~N");$_M(c$,"getModelName",function(a){return 1>this.modelCount?"":0<=a?this.modelNames[a]:this.modelNumbersForAtomLabel[-1-a]},"~N");$_M(c$,"getModelTitle",function(a){return this.getModelAuxiliaryInfoValue(a,"title")},"~N");$_M(c$,"getModelFileName",
function(a){return this.getModelAuxiliaryInfoValue(a,"fileName")},"~N");$_M(c$,"getModelFileType",function(a){return this.getModelAuxiliaryInfoValue(a,"fileType")},"~N");$_M(c$,"setFrameTitle",function(a,b){if(Clazz.instanceOf(b,String))for(var c=a.nextSetBit(0);0<=c;c=a.nextSetBit(c+1))this.frameTitles[c]=b;else for(var c=a.nextSetBit(0),d=0;0<=c;c=a.nextSetBit(c+1))d<b.length&&(this.frameTitles[c]=b[d++])},"JU.BS,~O");$_M(c$,"getFrameTitle",function(a){return 0<=a&&a<this.modelCount?this.frameTitles[a]:
""},"~N");$_M(c$,"getModelNumberForAtomLabel",function(a){return this.modelNumbersForAtomLabel[a]},"~N");$_M(c$,"calculatePolymers",function(a,b,c,d){if(this.isPDB)for(var e=!this.viewer.getBoolean(603979892),f=0;f<this.modelCount;f++)if((null==d||!d.get(f))&&this.models[f].isBioModel){this.models[f].calculatePolymers(a,b,c,d,e);break}},"~A,~N,~N,JU.BS");$_M(c$,"getGroups",function(){for(var a=0,b=0;b<this.modelCount;b++)a+=this.models[b].getGroupCount();for(var a=Array(a),c=b=0;b<this.modelCount;b++)for(var d=
0;d<this.models[b].chainCount;d++)for(var e=0;e<this.models[b].chains[d].groupCount;e++)a[c]=this.models[b].chains[d].groups[e],a[c].groupIndex=c,c++;return a});$_M(c$,"getNotionalUnitcell",function(){var a=this.getUnitCell(0);return null==a?null:a.getNotionalUnitCell()});$_M(c$,"setCrystallographicDefaults",function(){return!this.isPDB&&this.someModelsHaveSymmetry&&this.someModelsHaveFractionalCoordinates});$_M(c$,"getAverageAtomPoint",function(){return this.averageAtomPoint});$_M(c$,"getBoundBoxCenter",
function(a){return this.isJmolDataFrameForModel(a)?new JU.P3:this.boxInfo.getBoundBoxCenter()},"~N");$_M(c$,"getBoundBoxCornerVector",function(){return this.boxInfo.getBoundBoxCornerVector()});$_M(c$,"getBboxVertices",function(){return this.boxInfo.getBoundBoxVertices()});$_M(c$,"getBoundBoxInfo",function(){return this.boxInfo.getBoundBoxInfo()});$_M(c$,"getBoundBoxModels",function(){return this.bboxModels});$_M(c$,"setBoundBox",function(a,b,c,d){this.isBbcageDefault=!1;this.bboxAtoms=this.bboxModels=
null;this.boxInfo.setBoundBox(a,b,c,d)},"JU.P3,JU.P3,~B,~N");$_M(c$,"getBoundBoxCommand",function(a){if(!a&&null!=this.bboxAtoms)return"boundbox "+J.util.Escape.eBS(this.bboxAtoms);this.ptTemp.setT(this.boxInfo.getBoundBoxCenter());var b=this.boxInfo.getBoundBoxCornerVector();a=a?"boundbox "+J.util.Escape.eP(this.ptTemp)+" "+J.util.Escape.eP(b)+"\n#or\n":"";this.ptTemp.sub(b);a+="boundbox corners "+J.util.Escape.eP(this.ptTemp)+" ";this.ptTemp.scaleAdd2(2,b,this.ptTemp);b=Math.abs(8*b.x*b.y*b.z);
return a+=J.util.Escape.eP(this.ptTemp)+" # volume = "+b},"~B");$_M(c$,"getDefaultVdwType",function(a){return!this.models[a].isBioModel?J.constant.EnumVdw.AUTO_BABEL:0==this.models[a].hydrogenCount?J.constant.EnumVdw.AUTO_JMOL:J.constant.EnumVdw.AUTO_BABEL},"~N");$_M(c$,"setRotationRadius",function(a,b){return this.isJmolDataFrameForModel(a)?(this.models[a].defaultRotationRadius=b,!1):!0},"~N,~N");$_M(c$,"calcRotationRadius",function(a,b){if(this.isJmolDataFrameForModel(a)){var c=this.models[a].defaultRotationRadius;
return 0==c?10:c}for(var c=0,d=this.atomCount;0<=--d;)if(this.isJmolDataFrameForAtom(this.atoms[d]))for(a=this.atoms[d].modelIndex;0<=d&&this.atoms[d].modelIndex==a;)d--;else{var e=this.atoms[d],e=b.distance(e)+this.getRadiusVdwJmol(e);e>c&&(c=e)}return 0==c?10:c},"~N,JU.P3");$_M(c$,"calcBoundBoxDimensions",function(a,b){null!=a&&0>a.nextSetBit(0)&&(a=null);null==a&&this.isBbcageDefault||2>this.atomCount||(this.bboxModels=this.getModelBitSet(this.bboxAtoms=J.util.BSUtil.copy(a),!1),this.calcAtomsMinMax(a,
this.boxInfo)==this.atomCount&&(this.isBbcageDefault=!0),null==a&&(this.averageAtomPoint.setT(this.getAtomSetCenter(null)),null!=this.unitCells&&this.calcUnitCellMinMax()),this.boxInfo.setBbcage(b))},"JU.BS,~N");$_M(c$,"getBoxInfo",function(a,b){if(null==a)return this.boxInfo;var c=new J.util.BoxInfo;this.calcAtomsMinMax(a,c);c.setBbcage(b);return c},"JU.BS,~N");$_M(c$,"calcAtomsMinMax",function(a,b){b.reset();for(var c=0,d=null==a,e=d?this.atomCount-1:a.nextSetBit(0);0<=e;e=d?e-1:a.nextSetBit(e+
1))c++,this.isJmolDataFrameForAtom(this.atoms[e])||b.addBoundBoxPoint(this.atoms[e]);return c},"JU.BS,J.util.BoxInfo");$_M(c$,"calcUnitCellMinMax",($fz=function(){for(var a=0;a<this.modelCount;a++)if(this.unitCells[a].getCoordinatesAreFractional())for(var b=this.unitCells[a].getUnitCellVertices(),c=0;8>c;c++)this.boxInfo.addBoundBoxPoint(b[c])},$fz.isPrivate=!0,$fz));$_M(c$,"calcRotationRadiusBs",function(a){for(var b=this.getAtomSetCenter(a),c=0,d=a.nextSetBit(0);0<=d;d=a.nextSetBit(d+1)){var e=
this.atoms[d],e=b.distance(e)+this.getRadiusVdwJmol(e);e>c&&(c=e)}return 0==c?10:c},"JU.BS");$_M(c$,"getCenterAndPoints",function(a,b){for(var c,d,e=b?1:0,f=a.size();0<=--f;){var g=a.get(f);c=g[0];Clazz.instanceOf(g[1],JU.BS)?(d=g[1],e+=Math.min(c.cardinality(),d.cardinality())):e+=Math.min(c.cardinality(),g[1].length)}var h=Clazz.newArray(2,e,null);b&&(h[0][0]=new JU.P3,h[1][0]=new JU.P3);for(f=a.size();0<=--f;)if(g=a.get(f),c=g[0],Clazz.instanceOf(g[1],JU.BS)){d=g[1];for(var g=c.nextSetBit(0),k=
d.nextSetBit(0);0<=g&&0<=k;g=c.nextSetBit(g+1),k=d.nextSetBit(k+1))h[0][--e]=this.atoms[g],h[1][e]=this.atoms[k],b&&(h[0][0].add(this.atoms[g]),h[1][0].add(this.atoms[k]))}else{d=g[1];g=c.nextSetBit(0);for(k=0;0<=g&&k<d.length;g=c.nextSetBit(g+1),k++)h[0][--e]=this.atoms[g],h[1][e]=d[k],b&&(h[0][0].add(this.atoms[g]),h[1][0].add(d[k]))}b&&(h[0][0].scale(1/(h[0].length-1)),h[1][0].scale(1/(h[1].length-1)));return h},"JU.List,~B");$_M(c$,"getAtomSetCenter",function(a){var b=JU.P3.new3(0,0,0),c=0;if(null!=
a)for(var d=a.nextSetBit(0);0<=d;d=a.nextSetBit(d+1))this.isJmolDataFrameForAtom(this.atoms[d])||(c++,b.add(this.atoms[d]));0<c&&b.scale(1/c);return b},"JU.BS");$_M(c$,"setAPm",function(a,b,c,d,e,f,g){this.setAPa(a,b,c,d,e,f,g);switch(b){case 1095763988:case 1632634889:this.viewer.getBoolean(603979944)&&this.assignAromaticBonds()}},"JU.BS,~N,~N,~N,~S,~A,~A");$_M(c$,"addStateScript",function(a,b,c,d,e,f,g){var h=this.viewer.getCurrentModelIndex();f?(this.thisStateModel!=h&&(a="frame "+(0>h?"all #"+
h:this.getModelNumberDotted(h))+";\n  "+a),this.thisStateModel=h):this.thisStateModel=-1;a=new J.modelset.ModelCollection.StateScript(this.thisStateModel,a,b,c,d,e,g);a.isValid()&&this.stateScripts.addLast(a);return a},"~S,JU.BS,JU.BS,JU.BS,~S,~B,~B");$_M(c$,"calculateStructuresAllExcept",function(a,b,c,d,e,f){this.freezeModels();var g="";a=J.util.BSUtil.copyInvert(a,this.modelCount);e&&this.setDefaultStructure(a);for(var h=a.nextSetBit(0);0<=h;h=a.nextSetBit(h+1))g+=this.models[h].calculateStructures(b,
c,d,e,f);e&&this.setStructureIndexes();return g},"JU.BS,~B,~B,~B,~B,~B");$_M(c$,"setDefaultStructure",function(a){for(var b=a.nextSetBit(0);0<=b;b=a.nextSetBit(b+1))this.models[b].isBioModel&&null==this.models[b].defaultStructure&&(this.models[b].defaultStructure=this.getProteinStructureState(this.models[b].bsAtoms,!1,!1,0))},"JU.BS");$_M(c$,"setProteinType",function(a,b){var c=-1,d=-1,e=this.getModelBitSet(a,!1);this.setDefaultStructure(e);for(var f=a.nextSetBit(0);0<=f;f=a.nextSetBit(f+1)){d!=f-
1&&(c=-1);var c=this.atoms[f].group.setProteinStructureType(b,c),g=this.atoms[f].modelIndex;this.proteinStructureTainted=this.models[g].structureTainted=!0;d=f=this.atoms[f].group.lastAtomIndex}c=Clazz.newIntArray(this.modelCount,0);for(f=0;f<this.atomCount;)g=this.atoms[f].modelIndex,e.get(g)?(d=this.atoms[f].getStrucNo(),1E3>d&&d>c[g]&&(c[g]=d),f=this.atoms[f].group.lastAtomIndex+1):f=this.models[g].firstAtomIndex+this.models[g].atomCount;for(f=0;f<this.atomCount;)g=this.atoms[f].modelIndex,e.get(g)?
(1E3<this.atoms[f].getStrucNo()&&this.atoms[f].group.setStrucNo(++c[g]),f=this.atoms[f].group.lastAtomIndex+1):f=this.models[g].firstAtomIndex+this.models[g].atomCount},"JU.BS,J.constant.EnumStructure");$_M(c$,"freezeModels",function(){for(var a=this.modelCount;0<=--a;)this.models[a].freeze()});$_M(c$,"getStructureList",function(){return this.viewer.getStructureList()});$_M(c$,"setStructureList",function(a){for(var b=this.modelCount;0<=--b;)this.models[b].setStructureList(a)},"java.util.Map");$_M(c$,
"setConformation",function(a){for(var b=this.getModelBitSet(a,!1),c=b.nextSetBit(0);0<=c;c=b.nextSetBit(c+1))this.models[c].setConformation(a);return a},"JU.BS");$_M(c$,"getConformation",function(a,b,c){for(var d=new JU.BS,e=this.modelCount;0<=--e;)if(e==a||0>a){var f=this.getAltLocListInModel(e),g=this.getAltLocCountInModel(e);if(!(0<b&&b>=g)){var h=this.viewer.getModelUndeletedAtomsBitSet(e);if(0<=b&&!this.models[e].getPdbConformation(h,b))for(;0<=--g;)g!=b&&h.andNot(this.getAtomBitsMDa(1048607,
f.substring(g,g+1)));0<=h.nextSetBit(0)&&(d.or(h),c&&this.models[e].setConformation(h))}}return d},"~N,~N,~B");$_M(c$,"getHeteroList",function(a){for(var b=new java.util.Hashtable,c=!1,d=this.modelCount;0<=--d;)if(0>a||d==a){var e=this.getModelAuxiliaryInfoValue(d,"hetNames");if(null!=e)for(var c=!0,f,e=e.entrySet().iterator();e.hasNext()&&((f=e.next())||1);){var g=f.getKey();b.put(g,f.getValue())}}return c?b:this.getModelSetAuxiliaryInfoValue("hetNames")},"~N");$_M(c$,"getModelSetProperties",function(){return this.modelSetProperties});
$_M(c$,"getModelSetAuxiliaryInfo",function(){return this.modelSetAuxiliaryInfo});$_M(c$,"getModelSetProperty",function(a){return null==this.modelSetProperties?null:this.modelSetProperties.getProperty(a)},"~S");$_M(c$,"getModelSetAuxiliaryInfoValue",function(a){return null==this.modelSetAuxiliaryInfo?null:this.modelSetAuxiliaryInfo.get(a)},"~S");$_M(c$,"getModelSetAuxiliaryInfoBoolean",function(a){a=this.getModelSetAuxiliaryInfoValue(a);return Clazz.instanceOf(a,Boolean)&&a.booleanValue()},"~S");$_M(c$,
"mergeTrajectories",function(a){if(null==this.trajectorySteps){if(!a)return 0;this.trajectorySteps=new JU.List}for(a=this.trajectorySteps.size();a<this.modelCount;a++)this.trajectorySteps.addLast(null);return this.modelCount},"~B");$_M(c$,"getTrajectoryIndex",function(a){return this.models[a].trajectoryBaseIndex},"~N");$_M(c$,"isTrajectory",function(a){return this.models[a].isTrajectory},"~N");$_M(c$,"isTrajectoryMeasurement",function(a){if(null==a)return!1;for(var b=a[0],c,d=1;d<=b;d++)if(0<=(c=
a[d])&&this.models[this.atoms[c].modelIndex].isTrajectory)return!0;return!1},"~A");$_M(c$,"getModelBitSet",function(a,b){for(var c=new JU.BS,d=0,e=null==a,d=e?0:a.nextSetBit(0);0<=d&&d<this.atomCount;d=e?d+1:a.nextSetBit(d+1)){c.set(d=this.atoms[d].modelIndex);if(b)for(var f=this.models[d].trajectoryBaseIndex,g=0;g<this.modelCount;g++)this.models[g].trajectoryBaseIndex==f&&c.set(g);d=this.models[d].firstAtomIndex+this.models[d].atomCount-1}return c},"JU.BS,~B");$_M(c$,"getIterativeModels",function(a){for(var b=
new JU.BS,c=0;c<this.modelCount;c++)(a||!this.isJmolDataFrameForModel(c))&&this.models[c].trajectoryBaseIndex==c&&b.set(c);return b},"~B");$_M(c$,"isTrajectorySubFrame",function(a){return this.models[a].isTrajectory&&this.models[a].trajectoryBaseIndex!=a},"~N");$_M(c$,"selectDisplayedTrajectories",function(a){for(var b=0;b<this.modelCount;b++)this.models[b].isTrajectory&&this.atoms[this.models[b].firstAtomIndex].modelIndex!=b&&a.clear(b);return a},"JU.BS");$_M(c$,"fillAtomData",function(a,b){if(0!=
(b&4)){this.getMolecules();a.bsMolecules=Array(this.molecules.length);a.atomMolecule=Clazz.newIntArray(this.atomCount,0);for(var c,d=0;d<this.molecules.length;d++){c=a.bsMolecules[d]=this.molecules[d].atomList;for(var e=c.nextSetBit(0);0<=e;e=c.nextSetBit(e+1))a.atomMolecule[e]=d}}0!=(b&8)?(c=Clazz.newIntArray(1,0),a.hAtomRadius=this.viewer.getVanderwaalsMar(1)/1E3,a.hAtoms=this.calculateHydrogens(a.bsSelected,c,!1,!0,null),a.hydrogenAtomCount=c[0]):(a.firstAtomIndex=0>a.modelIndex?null==a.bsSelected?
0:Math.max(0,a.bsSelected.nextSetBit(0)):this.models[a.modelIndex].firstAtomIndex,a.lastModelIndex=a.firstModelIndex=0==this.atomCount?0:this.atoms[a.firstAtomIndex].modelIndex,a.modelName=this.getModelNumberDotted(a.firstModelIndex),this.fillADa(a,b))},"J.atomdata.AtomData,~N");$_M(c$,"getModelNumberDotted",function(a){return 1>this.modelCount||a>=this.modelCount||0>a?"":J.util.Escape.escapeModelFileNumber(this.modelFileNumbers[a])},"~N");$_M(c$,"getModelNumber",function(a){2147483647==a&&(a=this.modelCount-
1);return this.modelNumbers[a]},"~N");$_M(c$,"getModelFileNumber",function(a){return this.modelFileNumbers[a]},"~N");$_M(c$,"getModelProperties",function(a){return this.models[a].properties},"~N");$_M(c$,"getModelProperty",function(a,b){var c=this.models[a].properties;return null==c?null:c.getProperty(b)},"~N,~S");$_M(c$,"getModelAuxiliaryInfo",function(a){return 0>a?null:this.models[a].auxiliaryInfo},"~N");$_M(c$,"setModelAuxiliaryInfo",function(a,b,c){this.models[a].auxiliaryInfo.put(b,c)},"~N,~O,~O");
$_M(c$,"getModelAuxiliaryInfoValue",function(a,b){return 0>a?null:this.models[a].auxiliaryInfo.get(b)},"~N,~S");$_M(c$,"getModelAuxiliaryInfoBoolean",function(a,b){var c=this.models[a].auxiliaryInfo;return null!=c&&c.containsKey(b)&&c.get(b).booleanValue()},"~N,~S");$_M(c$,"getModelAuxiliaryInfoInt",function(a,b){var c=this.models[a].auxiliaryInfo;return null!=c&&c.containsKey(b)?c.get(b).intValue():-2147483648},"~N,~S");$_M(c$,"getModelAtomProperty",function(a,b){var c=this.getModelAuxiliaryInfoValue(a.modelIndex,
b);if(!Clazz.instanceOf(c,Array))return"";var d=a.index-this.models[a.modelIndex].firstAtomIndex;return d<c.length?c[d].toString():""},"J.modelset.Atom,~S");$_M(c$,"getInsertionCountInModel",function(a){return this.models[a].nInsertions},"~N");c$.modelFileNumberFromFloat=$_M(c$,"modelFileNumberFromFloat",function(a){var b=Clazz.doubleToInt(Math.floor(a));for(a=Clazz.doubleToInt(Math.floor(1E4*(a-b+1E-5)));0!=a&&0==a%10;)a/=10;return 1E6*b+a},"~N");$_M(c$,"getAltLocCountInModel",function(a){return this.models[a].nAltLocs},
"~N");$_M(c$,"getChainCount",function(a){for(var b=0,c=this.modelCount;0<=--c;)b+=this.models[c].getChainCount(a);return b},"~B");$_M(c$,"getBioPolymerCount",function(){for(var a=0,b=this.modelCount;0<=--b;)this.isTrajectorySubFrame(b)||(a+=this.models[b].getBioPolymerCount());return a});$_M(c$,"getBioPolymerCountInModel",function(a){return 0>a?this.getBioPolymerCount():this.isTrajectorySubFrame(a)?0:this.models[a].getBioPolymerCount()},"~N");$_M(c$,"getPolymerPointsAndVectors",function(a,b,c,d){for(var e=
0;e<this.modelCount;++e)this.models[e].getPolymerPointsAndVectors(a,b,c,d)},"JU.BS,JU.List,~B,~N");$_M(c$,"recalculateLeadMidpointsAndWingVectors",function(a){if(0>a)for(a=0;a<this.modelCount;a++)this.isTrajectorySubFrame(a)||this.models[a].recalculateLeadMidpointsAndWingVectors();else this.models[a].recalculateLeadMidpointsAndWingVectors()},"~N");$_M(c$,"getPolymerLeadMidPoints",function(a,b){return this.models[a].getPolymerLeadMidPoints(b)},"~N,~N");$_M(c$,"getChainCountInModel",function(a,b){return 0>
a?this.getChainCount(b):this.models[a].getChainCount(b)},"~N,~B");$_M(c$,"getGroupCount",function(){for(var a=0,b=this.modelCount;0<=--b;)a+=this.models[b].getGroupCount();return a});$_M(c$,"getGroupCountInModel",function(a){return 0>a?this.getGroupCount():this.models[a].getGroupCount()},"~N");$_M(c$,"calcSelectedGroupsCount",function(a){for(var b=this.modelCount;0<=--b;)this.models[b].calcSelectedGroupsCount(a)},"JU.BS");$_M(c$,"calcSelectedMonomersCount",function(a){for(var b=this.modelCount;0<=
--b;)this.models[b].calcSelectedMonomersCount(a)},"JU.BS");$_M(c$,"calcRasmolHydrogenBonds",function(a,b,c,d,e,f,g){for(var h=null==b||a.equals(b),k=this.modelCount;0<=--k;)this.models[k].isBioModel&&this.models[k].trajectoryBaseIndex==k&&(null==c&&(this.models[k].clearRasmolHydrogenBonds(a),h||this.models[k].clearRasmolHydrogenBonds(b)),this.models[k].getRasmolHydrogenBonds(a,b,c,d,e,f,g))},"JU.BS,JU.BS,JU.List,~B,~N,~B,JU.BS");$_M(c$,"calculateStraightness",function(){if(!this.getHaveStraightness()){for(var a=
this.viewer.getQuaternionFrame(),b=this.viewer.getInt(553648146),c=this.modelCount;0<=--c;)this.models[c].calculateStraightness(this.viewer,"S",a,b);this.setHaveStraightness(!0)}});$_M(c$,"getAtomGroupQuaternions",function(a,b,c){for(var d=0,e=new JU.List,f=a.nextSetBit(0);0<=f&&d<b;f=a.nextSetBit(f+1)){var g=this.atoms[f].group,h=g.getQuaternion(c);if(null==h&&(-2147483648==g.seqcode&&(h=g.getQuaternionFrame(this.atoms)),null==h))continue;d++;e.addLast(h);f=g.lastAtomIndex}return e.toArray(Array(e.size()))},
"JU.BS,~N,~S");$_M(c$,"getPdbAtomData",function(a,b){if(0==this.atomCount||0>a.nextSetBit(0))return"";null==b&&(b=this.viewer.getOutputChannel(null,null));var c=this.atoms[a.nextSetBit(0)].modelIndex,d=-1,e="%6.2Q%6.2b          ";if("PQR".equals(b.getType())){for(var e="%8.4P%7.4V       ",f=0,g=a.nextSetBit(0);0<=g;g=a.nextSetBit(g+1))f+=this.atoms[g].getPartialCharge();b.append("REMARK   1 PQR file generated by Jmol "+J.viewer.Viewer.getJmolVersion()).append("\nREMARK   1 created "+new java.util.Date).append("\nREMARK   1 Forcefield Used: unknown\nREMARK   1").append("\nREMARK   5").append("\nREMARK   6 Total charge on this protein: "+
f+" e\nREMARK   6\n")}for(var g=a.length()-1,h=(f=c!=this.atoms[g].modelIndex)?null:new JU.SB,c=this.models[c].isPdbWithMultipleBonds,k,g=a.nextSetBit(0);0<=g;g=a.nextSetBit(g+1)){var l=this.atoms[g];f&&l.modelIndex!=d&&(-1!=d&&b.append("ENDMDL\n"),d=l.modelIndex,b.append("MODEL     "+(d+1)+"\n"));var m=l.getAtomName();k=2==l.getElementSymbol().length||4<=m.length||Character.isDigit(m.charAt(0));var n=this.models[l.modelIndex].isBioModel,m=l.isHetero();k=n?m?k?J.modelset.LabelToken.compile(this.viewer,
"HETATM%5.-5i %-4.4a%1A%3.-3n %1c%4.-4R%1E   %8.3x%8.3y%8.3z"+e,"\x00",null):J.modelset.LabelToken.compile(this.viewer,"HETATM%5.-5i  %-3.3a%1A%3.-3n %1c%4.-4R%1E   %8.3x%8.3y%8.3z"+e,"\x00",null):k?J.modelset.LabelToken.compile(this.viewer,"ATOM  %5.-5i %-4.4a%1A%3.-3n %1c%4.-4R%1E   %8.3x%8.3y%8.3z"+e,"\x00",null):J.modelset.LabelToken.compile(this.viewer,"ATOM  %5.-5i  %-3.3a%1A%3.-3n %1c%4.-4R%1E   %8.3x%8.3y%8.3z"+e,"\x00",null):k?J.modelset.LabelToken.compile(this.viewer,"HETATM%5.-5i %-4.4a%1AUNK %1c   1%1E   %8.3x%8.3y%8.3z"+
e,"\x00",null):J.modelset.LabelToken.compile(this.viewer,"HETATM%5.-5i  %-3.3a%1AUNK %1c   1%1E   %8.3x%8.3y%8.3z"+e,"\x00",null);var q=l.getElementSymbolIso(!1).toUpperCase();b.append(J.modelset.LabelToken.formatLabelAtomArray(this.viewer,l,k,"\x00",null)).append(1==q.length?" "+q:q.substring(0,2)).append("  \n");if(!f&&(!n||m||c))if(n=l.getBonds(),null!=n)for(k=0;k<n.length;k++){var p=l.getAtomNumber(),r=n[k].getOtherAtom(l);if(a.get(r.index)&&(q=n[k].getCovalentOrder(),!(1==q&&c&&!m)))switch(r=
r.getAtomNumber(),q){case 2:case 3:if(r<p)continue;case 1:h.append("CONECT").append(J.util.Txt.formatStringI("%5i","i",p));for(p=0;p<q;p++)h.append(J.util.Txt.formatStringI("%5i","i",r));h.appendC("\n")}}}f?b.append("ENDMDL\n"):b.append(h.toString());return b.toString()},"JU.BS,J.io.JmolOutputChannel");$_M(c$,"getPdbData",function(a,b,c,d,e){this.isJmolDataFrameForModel(a)&&(a=this.getJmolDataSourceFrame(a));if(0>a)return"";var f=this.models[a].isBioModel;if(null==d&&!f)return null;var g=this.models[a];
null==e&&(e=this.viewer.getOutputChannel(null,null));var h=new JU.SB,k=0<=b.indexOf("draw"),l=null,m=new JU.BS,n="\x00",q=this.getLabeler().compile(this.viewer,"ATOM  %-6i%4a%1A%3n %1c%4R%1E   ","\x00",null);if(null==d)n=11<b.length&&0<=b.indexOf("quaternion ")?b.charAt(11):"R",g.getPdbData(this.viewer,b,n,k,c,e,q,h,m),l=this.viewer.getModelUndeletedAtomsBitSet(a);else{l=d[0];a=d[1];var g=d[2],p=d[3],r=null!=p,s=d[4],t=d[5],u=d[6];d=d[7];e.append("REMARK   6 Jmol PDB-encoded data: ").append(b).append(";\n");
e.append("REMARK   6 Jmol data").append(" min = ").append(J.util.Escape.eP(s)).append(" max = ").append(J.util.Escape.eP(t)).append(" unScaledXyz = xyz * ").append(J.util.Escape.eP(u)).append(" + ").append(J.util.Escape.eP(d)).append(";\n");b=null;d=l.nextSetBit(0);for(s=0;0<=d;d=l.nextSetBit(d+1),s++){var t=a[s],u=g[s],v=r?p[s]:0;if(!Float.isNaN(t)&&!Float.isNaN(u)&&!Float.isNaN(v)){var y=this.atoms[d];e.append(J.modelset.LabelToken.formatLabelAtomArray(this.viewer,y,q,"\x00",null));f&&m.set(d);
e.append(J.util.Txt.sprintf("%-8.2f%-8.2f%-10.2f    %6.3f          %2s    %s\n","ssF",[y.getElementSymbolIso(!1).toUpperCase(),"",[t,u,v,0]]));null!=b&&b.getPolymerIndexInModel()==y.getPolymerIndexInModel()&&h.append("CONECT").append(J.util.Txt.formatStringI("%5i","i",b.getAtomNumber())).append(J.util.Txt.formatStringI("%5i","i",y.getAtomNumber())).appendC("\n");b=y}}}e.append(h.toString());if(k)return e.toString();c.and(l);f&&e.append("\n\n"+this.getProteinStructureState(m,!1,"R"==n,1));return e.toString()},
"~N,~S,JU.BS,~A,J.io.JmolOutputChannel");$_M(c$,"isJmolDataFrameForModel",function(a){return 0<=a&&a<this.modelCount&&this.models[a].isJmolDataFrame},"~N");$_M(c$,"isJmolDataFrameForAtom",($fz=function(a){return this.models[a.modelIndex].isJmolDataFrame},$fz.isPrivate=!0,$fz),"J.modelset.Atom");$_M(c$,"setJmolDataFrame",function(a,b,c){var d=this.models[null==a?this.models[c].dataSourceFrame:b];null==a&&(a=this.models[c].jmolFrameType);0<=b&&(null==d.dataFrames&&(d.dataFrames=new java.util.Hashtable),
this.models[c].dataSourceFrame=b,this.models[c].jmolFrameType=a,d.dataFrames.put(a,Integer.$valueOf(c)));a.startsWith("quaternion")&&0>a.indexOf("deriv")&&(a=a.substring(0,a.indexOf(" ")),d.dataFrames.put(a,Integer.$valueOf(c)))},"~S,~N,~N");$_M(c$,"getJmolDataFrameIndex",function(a,b){if(null==this.models[a].dataFrames)return-1;var c=this.models[a].dataFrames.get(b);return null==c?-1:c.intValue()},"~N,~S");$_M(c$,"clearDataFrameReference",function(a){for(var b=0;b<this.modelCount;b++){var c=this.models[b].dataFrames;
if(null!=c)for(c=c.values().iterator();c.hasNext();)c.next().intValue()==a&&c.remove()}},"~N");$_M(c$,"getJmolFrameType",function(a){return 0<=a&&a<this.modelCount?this.models[a].jmolFrameType:"modelSet"},"~N");$_M(c$,"getJmolDataSourceFrame",function(a){return 0<=a&&a<this.modelCount?this.models[a].dataSourceFrame:-1},"~N");$_M(c$,"saveModelOrientation",function(a,b){this.models[a].orientation=b},"~N,J.viewer.StateManager.Orientation");$_M(c$,"getModelOrientation",function(a){return this.models[a].orientation},
"~N");$_M(c$,"getPDBHeader",function(a){return this.models[a].isBioModel?this.models[a].getFullPDBHeader():this.getFileHeader(a)},"~N");$_M(c$,"getFileHeader",function(a){if(0>a)return"";if(this.models[a].isBioModel)return this.models[a].getFullPDBHeader();a=this.getModelAuxiliaryInfoValue(a,"fileHeader");null==a&&(a=this.modelSetName);return null!=a?a:"no header information found"},"~N");$_M(c$,"getAltLocIndexInModel",function(a,b){if("\x00"==b)return 0;var c=this.getAltLocListInModel(a);return 0==
c.length?0:c.indexOf(b)+1},"~N,~S");$_M(c$,"getInsertionCodeIndexInModel",function(a,b){if("\x00"==b)return 0;var c=this.getInsertionListInModel(a);return 0==c.length?0:c.indexOf(b)+1},"~N,~S");$_M(c$,"getAltLocListInModel",function(a){if(0>a)return"";a=this.getModelAuxiliaryInfoValue(a,"altLocs");return null==a?"":a},"~N");$_M(c$,"getInsertionListInModel",($fz=function(a){a=this.getModelAuxiliaryInfoValue(a,"insertionCodes");return null==a?"":a},$fz.isPrivate=!0,$fz),"~N");$_M(c$,"getModelSymmetryCount",
function(a){var b;return 0<this.models[a].biosymmetryCount||null==this.unitCells||null==this.unitCells[a]||null==(b=this.unitCells[a].getSymmetryOperations())?this.models[a].biosymmetryCount:b.length},"~N");$_M(c$,"getSymmetryOperation",function(a,b,c,d,e,f,g){a=this.getSymTemp(!0).getSpaceGroupInfo(this,a,b,c,d,e,f);return null==a?"":this.symTemp.getSymmetryOperationInfo(a,c,f,g)},"~N,~S,~N,JU.P3,JU.P3,~S,~B");$_M(c$,"getModelCellRange",function(a){return null==this.unitCells?null:this.unitCells[a].getCellRange()},
"~N");$_M(c$,"getLastVibrationVector",function(a,b){if(null!=this.vibrations)for(var c=this.atomCount;0<=--c;)if((0>a||this.atoms[c].modelIndex==a)&&null!=this.vibrations[c]&&0<this.vibrations[c].length()&&(0==b||135270424==b==Clazz.instanceOf(this.vibrations[c],J.util.ModulationSet)))return c;return-1},"~N,~N");$_M(c$,"getElementsPresentBitSet",function(a){if(0<=a)return this.elementsPresent[a];a=new JU.BS;for(var b=0;b<this.modelCount;b++)a.or(this.elementsPresent[b]);return a},"~N");$_M(c$,"getSymmetryInfoAsStringForModel",
($fz=function(a){a=this.getUnitCell(a);return null==a?"no symmetry information":a.getSymmetryInfoString()},$fz.isPrivate=!0,$fz),"~N");$_M(c$,"getMoleculeIndex",function(a,b){0==this.moleculeCount&&this.getMolecules();for(var c=0;c<this.moleculeCount;c++)if(this.molecules[c].atomList.get(a))return b?this.molecules[c].indexInModel:c;return 0},"~N,~B");$_M(c$,"getMoleculeBitSet",function(a){0==this.moleculeCount&&this.getMolecules();var b=J.util.BSUtil.copy(a);a=J.util.BSUtil.copy(a);for(var c=0,d=
new JU.BS;0<=(c=a.length()-1);)d=this.getMoleculeBitSetForAtom(c),null==d?(a.clear(c),b.clear(c)):(a.andNot(d),b.or(d));return b},"JU.BS");$_M(c$,"getMoleculeBitSetForAtom",function(a){0==this.moleculeCount&&this.getMolecules();for(var b=0;b<this.moleculeCount;b++)if(this.molecules[b].atomList.get(a))return this.molecules[b].atomList;return null},"~N");$_M(c$,"getModelDipole",function(a){if(0>a)return null;var b=this.getModelAuxiliaryInfoValue(a,"dipole");null==b&&(b=this.getModelAuxiliaryInfoValue(a,
"DIPOLE_VEC"));return b},"~N");$_M(c$,"calculateMolecularDipole",function(a){if(null==this.partialCharges||0>a)return null;for(var b=0,c=0,d=0,e=0,f=new JU.V3,g=new JU.V3,h=0;h<this.atomCount;h++)if(this.atoms[h].modelIndex==a){var k=this.partialCharges[h];0>k?(c++,e+=k,g.scaleAdd2(k,this.atoms[h],g)):0<k&&(b++,d+=k,f.scaleAdd2(k,this.atoms[h],f))}if(0==c||0==b)return null;f.scale(1/d);g.scale(1/e);f.sub(g);J.util.Logger.warn("CalculateMolecularDipole: this is an approximate result -- needs checking");
f.scale(4.8*d);return f},"~N");$_M(c$,"getMoleculeCountInModel",function(a){var b=0;0==this.moleculeCount&&this.getMolecules();if(0>a)return this.moleculeCount;for(var c=0;c<this.modelCount;c++)a==c&&(b+=this.models[c].moleculeCount);return b},"~N");$_M(c$,"calcSelectedMoleculesCount",function(a){0==this.moleculeCount&&this.getMolecules();this.selectedMolecules.xor(this.selectedMolecules);this.selectedMoleculeCount=0;for(var b=new JU.BS,c=0;c<this.moleculeCount;c++)J.util.BSUtil.copy2(a,b),b.and(this.molecules[c].atomList),
0<b.length()&&(this.selectedMolecules.set(c),this.selectedMoleculeCount++)},"JU.BS");$_M(c$,"setCentroid",function(a,b){var c=this.getNotInCentroid(a,b);null!=c&&0<=c.nextSetBit(0)&&this.viewer.deleteAtoms(c,!1)},"JU.BS,~A");$_M(c$,"getNotInCentroid",($fz=function(a,b){var c=a.nextSetBit(0);if(0>c)return null;c=this.getUnitCell(this.atoms[c].modelIndex);return null==c?null:c.notInCentroid(this,a,b)},$fz.isPrivate=!0,$fz),"JU.BS,~A");$_M(c$,"getMolecules",function(){if(0<this.moleculeCount)return this.molecules;
null==this.molecules&&(this.molecules=Array(4));this.moleculeCount=0;for(var a=null,b=Array(this.modelCount),c=null,d=0;d<this.modelCount;d++)b[d]=this.viewer.getModelUndeletedAtomsBitSet(d),a=this.models[d],a.moleculeCount=0,c=a.getBioBranches(c);this.molecules=J.util.JmolMolecule.getMolecules(this.atoms,b,c,null);for(d=this.moleculeCount=this.molecules.length;0<=--d;)a=this.models[this.molecules[d].modelIndex],a.firstMoleculeIndex=d,a.moleculeCount++;return this.molecules});$_M(c$,"initializeBspf",
function(){if(!(null!=this.bspf&&this.bspf.isInitialized())){this.showRebondTimes&&J.util.Logger.startTimer("build bspf");var a=new J.bspt.Bspf(3);J.util.Logger.debugging&&J.util.Logger.debug("sequential bspt order");for(var b=J.util.BSUtil.newBitSet(this.modelCount),c=this.atomCount;0<=--c;){var d=this.atoms[c];!d.isDeleted()&&!this.isTrajectorySubFrame(d.modelIndex)&&(a.addTuple(this.models[d.modelIndex].trajectoryBaseIndex,d),b.set(d.modelIndex))}this.showRebondTimes&&(J.util.Logger.checkTimer("build bspf",
!1),a.stats());for(c=b.nextSetBit(0);0<=c;c=b.nextSetBit(c+1))a.validateModel(c,!0);a.validate(!0);this.bspf=a}});$_M(c$,"initializeBspt",function(a){this.initializeBspf();this.bspf.isInitializedIndex(a)||this.bspf.initialize(a,this.atoms,this.viewer.getModelUndeletedAtomsBitSet(a))},"~N");$_M(c$,"setIteratorForPoint",function(a,b,c,d){0>b?a.setCenter(c,d):(this.initializeBspt(b),a.setModel(this,b,this.models[b].firstAtomIndex,2147483647,c,d,null))},"J.api.AtomIndexIterator,~N,JU.P3,~N");$_M(c$,"setIteratorForAtom",
function(a,b,c,d,e){0>b&&(b=this.atoms[c].modelIndex);b=this.models[b].trajectoryBaseIndex;this.initializeBspt(b);a.setModel(this,b,this.models[b].firstAtomIndex,c,this.atoms[c],d,e)},"J.api.AtomIndexIterator,~N,~N,~N,J.atomdata.RadiusData");$_M(c$,"getSelectedAtomIterator",function(a,b,c,d,e){this.initializeBspf();if(e){e=this.getModelBitSet(a,!1);for(var f=e.nextSetBit(0);0<=f;f=e.nextSetBit(f+1))this.initializeBspt(f);e=new J.modelset.AtomIteratorWithinModelSet(e)}else e=new J.modelset.AtomIteratorWithinModel;
e.initialize(this.bspf,a,b,c,d,this.viewer.isParallel());return e},"JU.BS,~B,~B,~B,~B");Clazz.overrideMethod(c$,"getBondCountInModel",function(a){return 0>a?this.bondCount:this.models[a].getBondCount()},"~N");$_M(c$,"calculateStruts",function(a,b){return this.calculateStrutsMC(a,b)},"JU.BS,JU.BS");$_M(c$,"calculateStrutsMC",function(a,b){this.makeConnections2(0,3.4028235E38,32768,12291,a,b,null,!1,!1,0);var c=a.nextSetBit(0);if(0>c)return 0;c=this.models[this.atoms[c].modelIndex];return c.isBioModel?
c.calculateStruts(this,a,b):0},"JU.BS,JU.BS");$_M(c$,"getAtomCountInModel",function(a){return 0>a?this.atomCount:this.models[a].atomCount},"~N");$_M(c$,"getModelAtomBitSetIncludingDeletedBs",function(a){var b=new JU.BS;null==a&&null==this.bsAll&&(this.bsAll=J.util.BSUtil.setAll(this.atomCount));if(null==a)b.or(this.bsAll);else for(var c=a.nextSetBit(0);0<=c;c=a.nextSetBit(c+1))b.or(this.getModelAtomBitSetIncludingDeleted(c,!1));return b},"JU.BS");$_M(c$,"getModelAtomBitSetIncludingDeleted",function(a,
b){var c=0>a?this.bsAll:this.models[a].bsAtoms;null==c&&(c=this.bsAll=J.util.BSUtil.setAll(this.atomCount));return b?J.util.BSUtil.copy(c):c},"~N,~B");$_M(c$,"getAtomBitsMaybeDeleted",function(a,b){var c,d;switch(a){default:return this.getAtomBitsMDa(a,b);case 1678770178:case 1048585:return this.getAtomBitsMDb(a,b);case 1073741864:return this.getBasePairBits(b);case 1679429641:var e=this.getBoxInfo(b,1);d=this.getAtomsWithin(e.getBoundBoxCornerVector().length()+1E-4,e.getBoundBoxCenter(),null,-1);
for(c=d.nextSetBit(0);0<=c;c=d.nextSetBit(c+1))e.isWithin(this.atoms[c])||d.clear(c);return d;case 1095761925:d=new JU.BS;c=b;this.ptTemp1.set(c[0]/1E3,c[1]/1E3,c[2]/1E3);e=!this.viewer.getBoolean(603979848);for(c=this.atomCount;0<=--c;)this.isInLatticeCell(c,this.ptTemp1,this.ptTemp2,e)&&d.set(c);return d;case 1095761926:d=J.util.BSUtil.newBitSet2(0,this.atomCount);c=b;e=[Clazz.doubleToInt(c[0]/1E3)-1,Clazz.doubleToInt(c[1]/1E3)-1,Clazz.doubleToInt(c[2]/1E3)-1,Clazz.doubleToInt(c[0]/1E3),Clazz.doubleToInt(c[1]/
1E3),Clazz.doubleToInt(c[2]/1E3),0];for(c=this.modelCount;0<=--c;){var f=this.getUnitCell(c);null==f?J.util.BSUtil.andNot(d,this.models[c].bsAtoms):d.andNot(f.notInCentroid(this,this.models[c].bsAtoms,e))}return d;case 1095761934:return this.getMoleculeBitSet(b);case 1087373320:return this.getSequenceBits(b,null);case 1048615:c=b;var e=c[0],f=c[1],g=c[2];d=new JU.BS;var h=this.viewer.getBoolean(603979822);0<=g&&(256>g&&!h)&&(g=J.modelset.AtomCollection.chainToUpper(g));for(c=this.modelCount;0<=--c;)this.models[c].isBioModel&&
this.models[c].selectSeqcodeRange(e,f,g,d,h);return d;case 3145772:d=J.util.BSUtil.newBitSet(this.atomCount);e=-1;f=0;for(c=this.atomCount;0<=--c;)if(h=this.atoms[c],g=h.getAtomSymmetry(),null!=g){if(h.modelIndex!=e){e=h.modelIndex;if(null==this.getModelCellRange(e))continue;f=this.getModelSymmetryCount(e)}for(var h=0,k=f;0<=--k;)if(g.get(k)&&1<++h){d.set(c);break}}return d;case 1089470478:return J.util.BSUtil.copy(null==this.bsSymmetry?this.bsSymmetry=J.util.BSUtil.newBitSet(this.atomCount):this.bsSymmetry);
case 1614417948:d=new JU.BS;if(null==this.viewer.getCurrentUnitCell())return d;this.ptTemp1.set(1,1,1);for(c=this.atomCount;0<=--c;)this.isInLatticeCell(c,this.ptTemp1,this.ptTemp2,!1)&&d.set(c);return d}},"~N,~O");$_M(c$,"isInLatticeCell",($fz=function(a,b,c,d){var e=this.getUnitCell(this.atoms[a].modelIndex);c.setT(this.atoms[a]);return null!=e&&e.checkUnitCell(e,b,c,d)},$fz.isPrivate=!0,$fz),"~N,JU.P3,JU.P3,~B");$_M(c$,"getAtomsWithinRD",function(a,b,c,d){var e=new JU.BS,f=this.getIterativeModels(!1);
b=J.util.BSUtil.andNot(b,this.viewer.getDeletedAtoms());var g=this.getSelectedAtomIterator(null,!1,!1,!1,!1);if(c)for(c=b.nextSetBit(0);0<=c;c=b.nextSetBit(c+1))for(var h=this.modelCount;0<=--h;)f.get(h)&&(0>a?this.getAtomsWithin(a,this.atoms[c].getFractionalUnitCoordPt(!0),e,-1):(this.setIteratorForAtom(g,h,c,a,d),g.addAtoms(e)));else{e.or(b);for(c=b.nextSetBit(0);0<=c;c=b.nextSetBit(c+1))0>a?this.getAtomsWithin(a,this.atoms[c],e,this.atoms[c].modelIndex):(this.setIteratorForAtom(g,-1,c,a,d),g.addAtoms(e))}g.release();
return e},"~N,JU.BS,~B,J.atomdata.RadiusData");$_M(c$,"getGroupsWithin",function(a,b){for(var c=this.getIterativeModels(!1),d=new JU.BS,e=this.modelCount;0<=--e;)c.get(e)&&this.models[e].isBioModel&&this.models[e].getGroupsWithin(a,b,d);return d},"~N,JU.BS");$_M(c$,"getAtomsWithin",function(a,b,c,d){null==c&&(c=new JU.BS);if(0>a){a=-a;for(var e=this.atomCount;0<=--e;){var f=this.atoms[e];0<=d&&this.atoms[e].modelIndex!=d||!c.get(e)&&f.getFractionalUnitDistance(b,this.ptTemp1,this.ptTemp2)<=a&&c.set(f.index)}return c}d=
this.getIterativeModels(!0);e=this.getSelectedAtomIterator(null,!1,!1,!1,!1);for(f=this.modelCount;0<=--f;)d.get(f)&&(this.setIteratorForAtom(e,-1,this.models[f].firstAtomIndex,-1,null),e.setCenter(b,a),e.addAtoms(c));e.release();return c},"~N,JU.P3,JU.BS,~N");$_M(c$,"getBasePairBits",($fz=function(a){var b=new JU.BS;if(0!=a.length%2)return b;var c=null,d=null,b=new JU.List;if(0==a.length)c=d=this.viewer.getModelUndeletedAtomsBitSet(-1),this.calcRasmolHydrogenBonds(c,d,b,!0,1,!1,null);else for(var e=
0;e<a.length;)c=this.getSequenceBits(a.substring(e,++e),null),0!=c.cardinality()&&(d=this.getSequenceBits(a.substring(e,++e),null),0!=d.cardinality()&&this.calcRasmolHydrogenBonds(c,d,b,!0,1,!1,null));a=new JU.BS;for(e=b.size();0<=--e;)c=b.get(e),a.set(c.atom1.index),a.set(c.atom2.index);return this.getAtomBitsMDb(1087373318,a)},$fz.isPrivate=!0,$fz),"~S");$_M(c$,"getSequenceBits",function(a,b){null==b&&(b=this.viewer.getModelUndeletedAtomsBitSet(-1));var c=new JU.BS;if(0<a.length)for(var d=0;d<this.modelCount;++d)this.models[d].isBioModel&&
this.models[d].getSequenceBits(a,b,c);return c},"~S,JU.BS");$_M(c$,"deleteBonds",function(a,b){if(!b)for(var c=new JU.BS,d=new JU.BS,e=a.nextSetBit(0);0<=e;e=a.nextSetBit(e+1)){var f=this.bonds[e].atom1;this.models[f.modelIndex].isModelKit||(c.clearAll(),d.clearAll(),c.set(f.index),d.set(this.bonds[e].getAtomIndex2()),this.addStateScript("connect ",null,c,d,"delete",!1,!0))}this.dBb(a,b)},"JU.BS,~B");$_M(c$,"makeConnections2",function(a,b,c,d,e,f,g,h,k,l){null==g&&(g=new JU.BS);var m=65535==c,n=131071==
c;n&&(c=1);var q=J.modelset.Bond.isOrderH(c),p=!1,r=!1,s=!1,t=!1,u=a*a,v=b*b;switch(d){case 12291:return this.deleteConnections(a,b,c,e,f,h,n,u,v);case 603979874:case 1073741852:if(515!=c)return this.autoBond(e,f,g,h,q,603979874==d);t=r=!0;break;case 1087373321:p=!0;break;case 1073742025:r=!0;break;case 1073741904:s=!0}this.defaultCovalentMad=this.viewer.getMadBond();d=0>a;n=0>b;d&&(a=-a);n&&(b=-b);for(var y=this.getDefaultMadFromOrder(c),A=0,B=0,w=null,x=h?1:this.atomCount,z=null,D=null,C=0,E=0,
I=c|131072,G=e.nextSetBit(0);0<=G;G=e.nextSetBit(G+1)){if(h)w=this.bonds[G],z=w.atom1,D=w.atom2;else if(z=this.atoms[G],z.isDeleted())continue;for(var H=h?x:f.nextSetBit(0);0<=H;H=h?H-1:f.nextSetBit(H+1)){if(!h){if(H==G)continue;D=this.atoms[H];if(z.modelIndex!=D.modelIndex||D.isDeleted())continue;if(z.altloc!=D.altloc&&"\x00"!=z.altloc&&"\x00"!=D.altloc)continue;w=z.getBond(D)}if(!(null==w&&(p||r)||null!=w&&s)){var F=z.distanceSquared(D);if(d||n)C=z.distance(D),E=z.getBondingRadiusFloat()+D.getBondingRadiusFloat();
if(!(d?C<E*a:F<u)&&!(n?C>E*b:F>v))if(null!=w){if(!p&&!m&&(w.setOrder(c),this.bsAromatic.clear(w.index)),!p||m||c==w.order||I==w.order||q&&w.isHydrogen())g.set(w.index),B++}else g.set(this.bondAtoms(z,D,c,y,g,l,k,!0).index),A++}}}t&&this.assignAromaticBondsBs(!0,g);p||this.shapeManager.setShapeSizeBs(1,-2147483648,null,g);return[A,B]},"~N,~N,~N,~N,JU.BS,JU.BS,JU.BS,~B,~B,~N");$_M(c$,"autoBondBs4",function(a,b,c,d,e,f){if(f)return this.autoBond_Pre_11_9_24(a,b,c,d,e);if(0==this.atomCount)return 0;0==
e&&(e=1);1.4E-45==this.maxBondingRadius&&this.findMaxRadii();f=this.viewer.getFloat(570425348);var g=this.viewer.getFloat(570425364),g=g*g,h=0;this.showRebondTimes&&J.util.Logger.startTimer("autobond");var k=-1,l=null==a,m,n;l?(n=0,m=null):(a.equals(b)?m=a:(m=J.util.BSUtil.copy(a),m.or(b)),n=m.nextSetBit(0));for(var q=this.getSelectedAtomIterator(null,!1,!1,!0,!1);0<=n&&n<this.atomCount;n=l?n+1:m.nextSetBit(n+1)){var p=l||a.get(n),r=l||b.get(n),s=this.atoms[n];if(!s.isDeleted()){var t=s.modelIndex;
if(t!=k&&(k=t,this.isJmolDataFrameForModel(t))){n=this.models[t].firstAtomIndex+this.models[t].atomCount-1;continue}t=s.getBondingRadiusFloat();if(0!=t){var u=null!=c&&c.get(n);for(this.setIteratorForAtom(q,-1,n,t+this.maxBondingRadius+f,null);q.hasNext();){var v=this.atoms[q.next()];if(!v.isDeleted()){var y=v.index,A=l||a.get(y),B=l||b.get(y);!A&&!B||(!(p&&B||r&&A)||u&&c.get(y))||(y=J.modelset.BondCollection.getBondOrderFull(t,v.getBondingRadiusFloat(),q.foundDistance2(),g,f),0<y&&this.checkValencesAndBond(s,
v,y,e,d)&&h++)}}q.release()}}}this.showRebondTimes&&J.util.Logger.checkTimer("autoBond",!1);return h},"JU.BS,JU.BS,JU.BS,JU.BS,~N,~B");$_M(c$,"autoBond_Pre_11_9_24",($fz=function(a,b,c,d,e){if(0==this.atomCount)return 0;0==e&&(e=1);1.4E-45==this.maxBondingRadius&&this.findMaxRadii();var f=this.viewer.getFloat(570425348),g=this.viewer.getFloat(570425364),g=g*g,h=0;this.initializeBspf();for(var k=-1,l=this.atomCount;0<=--l;){var m=null==a||a.get(l),n=null==b||b.get(l);if(m||n){var q=this.atoms[l];if(!q.isDeleted()){var p=
q.modelIndex;if(p!=k&&(k=p,this.isJmolDataFrameForModel(p))){for(;0<=--l&&this.atoms[l].modelIndex==p;);l++;continue}var r=q.getBondingRadiusFloat();if(0!=r){var s=r+this.maxBondingRadius+f;this.initializeBspt(p);p=this.bspf.getCubeIterator(p);for(p.initialize(q,s,!0);p.hasMoreElements();)if(s=p.nextElement(),!(s===q||s.isDeleted())){var t=s.index,u=null==a||a.get(t),v=null==b||b.get(t);if(!(!u&&!v||null!=c&&c.get(t)&&c.get(l)))if(m&&v||n&&u)t=J.modelset.BondCollection.getBondOrderFull(r,s.getBondingRadiusFloat(),
p.foundDistance2(),g,f),0<t&&this.checkValencesAndBond(q,s,t,e,d)&&h++}p.release()}}}}return h},$fz.isPrivate=!0,$fz),"JU.BS,JU.BS,JU.BS,JU.BS,~N");$_M(c$,"autoBond",($fz=function(a,b,c,d,e,f){if(d){d=a;a=new JU.BS;b=new JU.BS;for(var g=d.nextSetBit(0);0<=g;g=d.nextSetBit(g+1))a.set(this.bonds[g].atom1.index),b.set(this.bonds[g].atom2.index)}return[e?this.autoHbond(a,b,!1):this.autoBondBs4(a,b,null,c,this.viewer.getMadBond(),f),0]},$fz.isPrivate=!0,$fz),"JU.BS,JU.BS,JU.BS,~B,~B,~B");$_M(c$,"autoHbond",
function(a,b,c){if(c){for(var d=this.getModelBitSet(a,!1),e=d.nextSetBit(0);0<=e&&c;e=d.nextSetBit(e+1))c=!this.models[e].hasRasmolHBonds;if(c)return 0}c=!1;for(e=a.nextSetBit(0);0<=e;e=a.nextSetBit(e+1))if(1==this.atoms[e].getElementNumber()){c=!0;break}d=new JU.BS;e=this.viewer.getBoolean(603979853);if(null==b||e&&!c)return J.util.Logger.info((null==b?"DSSP ":"RasMol")+" pseudo-hbond calculation"),this.calcRasmolHydrogenBonds(a,b,null,!1,2147483647,!1,d),-J.util.BSUtil.cardinalityOf(d);J.util.Logger.info(c?
"Standard Hbond calculation":"Jmol pseudo-hbond calculation");var f=null;if(!c){f=new JU.BS;for(e=a.nextSetBit(0);0<=e;e=a.nextSetBit(e+1))switch(this.atoms[e].atomID){case 64:case 4:case 14:case 15:case 16:case 17:f.set(e)}}var g=this.viewer.getFloat(570425361),h=3.141592653589793*this.viewer.getFloat(570425360)/180,k=g*g,l=J.modelset.ModelCollection.hbondMin*J.modelset.ModelCollection.hbondMin,m=g>J.modelset.ModelCollection.hbondMin?l:k,n=g>J.modelset.ModelCollection.hbondMin?J.modelset.ModelCollection.hbondMin:
g,q=0,p=0,r=new JU.V3,s=new JU.V3;this.showRebondTimes&&J.util.Logger.debugging&&J.util.Logger.startTimer("hbond");var t=null,u=null;b=this.getSelectedAtomIterator(b,!1,!1,!1,!1);for(e=a.nextSetBit(0);0<=e;e=a.nextSetBit(e+1)){var v=this.atoms[e],y=v.getElementNumber(),A=1==y;if(!(!A&&(c||7!=y&&8!=y)||A&&!c)){var B,w,x;if(A){y=v.bonds;if(null==y)continue;x=!1;for(B=0;B<y.length&&!x;B++)x=y[B].getOtherAtom(v).getElementNumber(),x=7==x||8==x;if(!x)continue;w=n;y=1;B=m;x=!1}else w=g,y=l,B=k,x=f.get(e);
for(this.setIteratorForAtom(b,-1,v.index,w,null);b.hasNext();){w=this.atoms[b.next()];var z=w.getElementNumber();if(!(w===v||!A&&7!=z&&8!=z||A&&1==z||(p=b.foundDistance2())<y||p>B||x&&f.get(w.index)||v.isBonded(w))){if(0<h){r.sub2(v,w);if(null==(u=J.modelset.ModelCollection.checkMinAttachedAngle(v,h,r,s,c)))continue;r.scale(-1);if(null==(t=J.modelset.ModelCollection.checkMinAttachedAngle(w,h,r,s,c)))continue}var z=0,D;A&&!Float.isNaN(t.x)&&!Float.isNaN(u.x)?(D=4096,z=J.modelset.HBond.getEnergy(Math.sqrt(p),
t.distance(v),t.distance(u),w.distance(u))/1E3):D=2048;d.set(this.addHBond(v,w,D,z));q++}}}}b.release();this.shapeManager.setShapeSizeBs(1,-2147483648,null,d);this.showRebondTimes&&J.util.Logger.checkTimer("hbond",!1);return c?q:-q},"JU.BS,JU.BS,~B");c$.checkMinAttachedAngle=$_M(c$,"checkMinAttachedAngle",($fz=function(a,b,c,d,e){var f=a.bonds;if(null==f||0==f.length)return JU.P3.new3(NaN,0,0);for(var g=null,h=3.4028235E38,k=f.length;0<=--k;)if(f[k].isCovalent()){var l=f[k].getOtherAtom(a);if(e||
1!=l.getElementNumber()){d.sub2(a,l);var m=d.angle(c);if(m<b)return null;m<h&&(g=l,h=m)}}return g},$fz.isPrivate=!0,$fz),"J.modelset.Atom,~N,JU.V3,JU.V3,~B");$_M(c$,"setStructureIndexes",function(){for(var a,b=0,c=-1,d=-1,e=-1,f=0;f<this.atomCount;f++){if((d=this.atoms[f].modelIndex)!=e)b=0,e=d,c=-1;if((a=this.atoms[f].getStrucNo())!=c&&0!=a)this.atoms[f].getGroup().setStrucNo(++b),c=b}});$_M(c$,"getProteinStructureState",function(a,b,c,d){if(!this.isPDB)return"";for(var e=0;e<this.modelCount;e++)if(this.models[e].isBioModel)return this.models[e].getProteinStructureState(a,
b,c,d);return""},"JU.BS,~B,~B,~N");$_M(c$,"getModelInfoAsString",function(){var a=(new JU.SB).append('<models count="');a.appendI(this.modelCount).append('" modelSetHasVibrationVectors="').append(this.modelSetHasVibrationVectors()+'">\n<properties>');if(null!=this.modelSetProperties){for(var b=this.modelSetProperties.propertyNames();b.hasMoreElements();){var c=b.nextElement();a.append('\n <property name="').append(c).append('" value=').append(J.util.Escape.eS(this.modelSetProperties.getProperty(c))).append(" />")}a.append("\n</properties>")}for(b=
0;b<this.modelCount;++b)a.append('\n<model index="').appendI(b).append('" n="').append(this.getModelNumberDotted(b)).append('" id=').append(J.util.Escape.eS(""+this.getModelAuxiliaryInfoValue(b,"modelID"))),c=this.viewer.getJDXBaseModelIndex(b),c!=b&&a.append(" baseModelId=").append(J.util.Escape.eS(this.getModelAuxiliaryInfoValue(c,"jdxModelID"))),a.append(" name=").append(J.util.Escape.eS(this.getModelName(b))).append(" title=").append(J.util.Escape.eS(this.getModelTitle(b))).append(' hasVibrationVectors="').appendB(this.viewer.modelHasVibrationVectors(b)).append('" />');
a.append("\n</models>");return a.toString()});$_M(c$,"getSymmetryInfoAsString",function(){for(var a=(new JU.SB).append("Symmetry Information:"),b=0;b<this.modelCount;++b)a.append("\nmodel #").append(this.getModelNumberDotted(b)).append("; name=").append(this.getModelName(b)).append("\n").append(this.getSymmetryInfoAsStringForModel(b));return a.toString()});$_M(c$,"getAtomsConnected",function(a,b,c,d){for(var e=new JU.BS,f=Clazz.newIntArray(this.atomCount,0),g,h=30720==c,k=65535==c,l=0;l<this.bondCount;l++){var m=
this.bonds[l];if(k||m.is(c)||h&&m.isHydrogen())d.get(m.atom1.index)&&(f[g=m.atom2.index]++,e.set(g)),d.get(m.atom2.index)&&(f[g=m.atom1.index]++,e.set(g))}c=0==a;for(g=this.atomCount;0<=--g;)d=f[g],d<a||d>b?e.clear(g):c&&0==d&&e.set(g);return e},"~N,~N,~N,JU.BS");$_M(c$,"getUnitCellInfoText",function(){var a=this.viewer.getCurrentModelIndex();if(0>a)return"no single current model";a=this.getUnitCell(a);return null==a?"not applicable":a.getUnitCellInfo()});$_M(c$,"getSymTemp",function(a){if(null==
this.symTemp||a)this.symTemp=J.api.Interface.getOptionInterface("symmetry.Symmetry");return this.symTemp},"~B");$_M(c$,"createModels",function(a){a=this.modelCount+a;var b=JU.ArrayUtil.arrayCopyObject(this.models,a);this.validateBspf(!1);this.modelNumbers=JU.ArrayUtil.arrayCopyI(this.modelNumbers,a);this.modelFileNumbers=JU.ArrayUtil.arrayCopyI(this.modelFileNumbers,a);this.modelNumbersForAtomLabel=JU.ArrayUtil.arrayCopyS(this.modelNumbersForAtomLabel,a);this.modelNames=JU.ArrayUtil.arrayCopyS(this.modelNames,
a);this.frameTitles=JU.ArrayUtil.arrayCopyS(this.frameTitles,a);for(var c=Clazz.doubleToInt(this.getModelFileNumber(this.modelCount-1)/1E6)+1,d=this.modelCount,e=0;d<a;d++)this.modelNumbers[d]=d+this.modelCount,this.modelFileNumbers[d]=1E6*c+ ++e,this.modelNumbersForAtomLabel[d]=this.modelNames[d]=c+"."+e;this.thisStateModel=-1;c=this.getModelSetAuxiliaryInfoValue("group3Lists");null!=c&&(d=this.getModelSetAuxiliaryInfoValue("group3Counts"),c=JU.ArrayUtil.arrayCopyS(c,a),d=JU.ArrayUtil.arrayCopyII(d,
a),this.modelSetAuxiliaryInfo.put("group3Lists",c),this.modelSetAuxiliaryInfo.put("group3Counts",d));this.unitCells=JU.ArrayUtil.arrayCopyObject(this.unitCells,a);for(d=this.modelCount;d<a;d++)b[d]=new J.modelset.Model(this,d,-1,null,null,null),b[d].loadState=" model create #"+d+";";this.models=b;this.modelCount=a},"~N");$_M(c$,"deleteModel",function(a,b,c,d,e){if(0>a)this.validateBspf(!1),this.bsAll=null,this.resetMolecules(),this.isBbcageDefault=!1,this.calcBoundBoxDimensions(null,1);else{this.modelNumbers=
JU.ArrayUtil.deleteElements(this.modelNumbers,a,1);this.modelFileNumbers=JU.ArrayUtil.deleteElements(this.modelFileNumbers,a,1);this.modelNumbersForAtomLabel=JU.ArrayUtil.deleteElements(this.modelNumbersForAtomLabel,a,1);this.modelNames=JU.ArrayUtil.deleteElements(this.modelNames,a,1);this.frameTitles=JU.ArrayUtil.deleteElements(this.frameTitles,a,1);this.thisStateModel=-1;var f=this.getModelSetAuxiliaryInfoValue("group3Lists"),g=this.getModelSetAuxiliaryInfoValue("group3Counts"),h=a+1;if(null!=f&&
null!=f[h])for(var k=Clazz.doubleToInt(f[h].length/6);0<=--k;)0<g[h][k]&&(g[0][k]-=g[h][k],0==g[0][k]&&(f[0]=f[0].substring(0,6*k)+",["+f[0].substring(6*k+2)));null!=f&&(this.modelSetAuxiliaryInfo.put("group3Lists",JU.ArrayUtil.deleteElements(f,a,1)),this.modelSetAuxiliaryInfo.put("group3Counts",JU.ArrayUtil.deleteElements(g,a,1)));null!=this.unitCells&&(this.unitCells=JU.ArrayUtil.deleteElements(this.unitCells,a,1));for(k=this.stateScripts.size();0<=--k;)this.stateScripts.get(k).deleteAtoms(a,e,
d)||this.stateScripts.remove(k);this.deleteModelAtoms(b,c,d);this.viewer.deleteModelAtoms(b,c,d)}},"~N,~N,~N,JU.BS,JU.BS");$_M(c$,"getMoInfo",function(a){for(var b=new JU.SB,c=0;c<this.modelCount;c++)if(!(0<=a&&c!=a)){var d=this.viewer.getModelAuxiliaryInfoValue(c,"moData");if(null!=d){var d=d.get("mos"),e=null==d?0:d.size();if(0!=e)for(;0<=--e;){var f=d.get(e),g=f.get("type");null==g&&(g="");var h=f.get("energyUnits");null==h&&(h="");var k=f.get("occupancy");null!=k&&(g="occupancy "+k.floatValue()+
" "+g);k=f.get("symmetry");null!=k&&(g+=k);k=""+f.get("energy");Float.isNaN(JU.ParserJS.parseFloat(k))?b.append(J.util.Txt.sprintf("model %-2s;  mo %-2i # %s\n","sis",[this.getModelNumberDotted(c),Integer.$valueOf(e+1),g])):b.append(J.util.Txt.sprintf("model %-2s;  mo %-2i # energy %-8.3f %s %s\n","sifss",[this.getModelNumberDotted(c),Integer.$valueOf(e+1),f.get("energy"),h,g]))}}}return b.toString()},"~N");$_M(c$,"assignAtom",function(a,b,c){null==b&&(b="C");var d=this.atoms[a],e=new JU.BS,f=1==
d.getElementNumber(),e=J.util.Elements.elementNumberFromSymbol(b,!0),g=!1;if(0<e)this.setElement(d,e),this.viewer.setShapeSizeRD(0,this.viewer.getDefaultRadiusData(),J.util.BSUtil.newAndSetBit(a)),this.setAtomName(a,b+d.getAtomNumber()),this.models[d.modelIndex].isModelKit||this.taintAtom(a,0);else if(b.equals("Pl"))d.setFormalCharge(d.getFormalCharge()+1);else if(b.equals("Mi"))d.setFormalCharge(d.getFormalCharge()-1);else if(b.equals("X"))g=!0;else if(!b.equals("."))return;this.removeUnnecessaryBonds(d,
g);b=0;1==d.getCovalentBondCount()&&(f?b=1.5:!f&&1==e&&(b=1));0!=b&&(f=JU.V3.newVsub(d,this.atoms[d.getBondedAtomIndex(0)]),g=f.length(),f.normalize(),f.scale(b-g),this.setAtomCoordRelative(a,f.x,f.y,f.z));a=J.util.BSUtil.newAndSetBit(a);1!=e&&c&&(this.validateBspf(!1),e=this.getAtomsWithinRD(1,a,!1,null),e.andNot(a),0<=e.nextSetBit(0)&&this.viewer.deleteAtoms(e,!1),e=this.viewer.getModelUndeletedAtomsBitSet(d.modelIndex),e.andNot(this.getAtomBitsMDa(1613758476,null)),this.makeConnections2(0.1,1.8,
1,1073741904,a,e,null,!1,!1,0));this.viewer.addHydrogens(a,!1,!0)},"~N,~S,~B");$_M(c$,"deleteAtoms",function(a){if(null!=a){for(var b=new JU.BS,c=a.nextSetBit(0);0<=c&&c<this.atomCount;c=a.nextSetBit(c+1))this.atoms[c].deleteBonds(b);for(c=0;c<this.modelCount;c++)this.models[c].bsAtomsDeleted.or(a),this.models[c].bsAtomsDeleted.and(this.models[c].bsAtoms);this.deleteBonds(b,!1)}},"JU.BS");$_M(c$,"getModelCml",function(a,b,c){var d=new JU.SB;if(0==J.util.BSUtil.cardinalityOf(a))return"";var e=J.api.Interface.getOptionInterface("io.XmlUtil");
e.openTag(d,"molecule");e.openTag(d,"atomArray");for(var f=new JU.BS,g=a.nextSetBit(0);0<=g&&!(0>--b);g=a.nextSetBit(g+1)){var h=this.atoms[g],k=h.getAtomName();J.util.Txt.simpleReplace(k,'"',"''");f.set(h.index);e.appendTag(d,"atom/",["id","a"+(h.index+1),"title",h.getAtomName(),"elementType",h.getElementSymbol(),"x3",""+h.x,"y3",""+h.y,"z3",""+h.z])}e.closeTag(d,"atomArray");if(c){e.openTag(d,"bondArray");for(g=0;g<this.bondCount;g++)a=this.bonds[g],b=a.atom2,f.get(a.atom1.index)&&f.get(b.index)&&
(b=J.util.JmolEdge.getCmlBondOrder(a.order),null!=b&&e.appendTag(d,"bond/",["atomRefs2","a"+(a.atom1.index+1)+" a"+(a.atom2.index+1),"order",b]));e.closeTag(d,"bondArray")}e.closeTag(d,"molecule");return d.toString()},"JU.BS,~N,~B");$_M(c$,"adjustAtomArrays",function(a,b,c){this.atomCount=c;for(var d=b;d<c;d++){this.atoms[d]=this.atoms[a[d]];this.atoms[d].index=d;var e=this.models[this.atoms[d].modelIndex];e.firstAtomIndex==a[d]&&(e.firstAtomIndex=d);e.bsAtoms.set(d)}if(null!=this.vibrations)for(d=
b;d<c;d++)this.vibrations[d]=this.vibrations[a[d]];if(null!=this.occupancies)for(d=b;d<c;d++)this.occupancies[d]=this.occupancies[a[d]];if(null!=this.bfactor100s)for(d=b;d<c;d++)this.bfactor100s[d]=this.bfactor100s[a[d]];if(null!=this.partialCharges)for(d=b;d<c;d++)this.partialCharges[d]=this.partialCharges[a[d]];if(null!=this.atomTensorList)for(d=b;d<c;d++)for(var e=this.atomTensorList[d]=this.atomTensorList[a[d]],f=e.length;0<=--f;){var g=e[f];null!=g&&(g.atomIndex1=a[g.atomIndex1])}if(null!=this.atomNames)for(d=
b;d<c;d++)this.atomNames[d]=this.atomNames[a[d]];if(null!=this.atomTypes)for(d=b;d<c;d++)this.atomTypes[d]=this.atomTypes[a[d]];if(null!=this.atomSerials)for(d=b;d<c;d++)this.atomSerials[d]=this.atomSerials[a[d]]},"~A,~N,~N");$_M(c$,"growAtomArrays",function(a){this.atoms=JU.ArrayUtil.arrayCopyObject(this.atoms,a);null!=this.vibrations&&(this.vibrations=JU.ArrayUtil.arrayCopyObject(this.vibrations,a));null!=this.occupancies&&(this.occupancies=JU.ArrayUtil.arrayCopyByte(this.occupancies,a));null!=
this.bfactor100s&&(this.bfactor100s=JU.ArrayUtil.arrayCopyShort(this.bfactor100s,a));null!=this.partialCharges&&(this.partialCharges=JU.ArrayUtil.arrayCopyF(this.partialCharges,a));null!=this.atomTensorList&&(this.atomTensorList=JU.ArrayUtil.arrayCopyObject(this.atomTensorList,a));null!=this.atomNames&&(this.atomNames=JU.ArrayUtil.arrayCopyS(this.atomNames,a));null!=this.atomTypes&&(this.atomTypes=JU.ArrayUtil.arrayCopyS(this.atomTypes,a));null!=this.atomSerials&&(this.atomSerials=JU.ArrayUtil.arrayCopyI(this.atomSerials,
a))},"~N");$_M(c$,"addAtom",function(a,b,c,d,e,f,g,h,k,l,m,n,q,p,r,s,t){f=new J.modelset.Atom(a,this.atomCount,g,h,t,f,c,l,r);this.models[a].atomCount++;this.models[a].bsAtoms.set(this.atomCount);J.util.Elements.isElement(c,1)&&this.models[a].hydrogenCount++;this.atomCount>=this.atoms.length&&this.growAtomArrays(this.atomCount+100);this.atoms[this.atomCount]=f;this.setBFactor(this.atomCount,q);this.setOccupancy(this.atomCount,n);this.setPartialCharge(this.atomCount,m);null!=p&&this.setAtomTensors(this.atomCount,
p);f.group=b;f.colixAtom=this.viewer.getColixAtomPalette(f,J.constant.EnumPalette.CPK.id);if(null!=d){if(0<=(a=d.indexOf("\x00")))null==this.atomTypes&&(this.atomTypes=Array(this.atoms.length)),this.atomTypes[this.atomCount]=d.substring(a+1),d=d.substring(0,a);f.atomID=s;0==s&&(null==this.atomNames&&(this.atomNames=Array(this.atoms.length)),this.atomNames[this.atomCount]=d.intern())}-2147483648!=e&&(null==this.atomSerials&&(this.atomSerials=Clazz.newIntArray(this.atoms.length,0)),this.atomSerials[this.atomCount]=
e);null!=k&&this.setVibrationVector(this.atomCount,k);this.atomCount++;return f},"~N,J.modelset.Group,~N,~S,~N,~N,JU.P3,~N,JU.V3,~N,~N,~N,~N,JU.List,~B,~N,JU.BS");$_M(c$,"getInlineData",function(a){var b=null;if(0<=a)b=this.models[a].loadScript;else for(a=this.modelCount;0<=--a&&!(0<(b=this.models[a].loadScript).length()););a=b.lastIndexOf('data "');if(0>a)return null;a=b.indexOf2('"',a+7);var c=b.lastIndexOf('end "');return c<a||0>a?null:b.substring2(a+2,c)},"~N");$_M(c$,"isAtomPDB",function(a){return 0<=
a&&this.models[this.atoms[a].modelIndex].isBioModel},"~N");$_M(c$,"isAtomAssignable",function(a){return 0<=a&&this.atoms[a].modelIndex==this.modelCount-1},"~N");$_M(c$,"getGroupAtom",function(a,b,c){var d=a.group;a=d.getMonomerIndex();if(0>a)return-1;d=d.getGroups();a+=b;if(0<=a&&a<d.length){a=d[a];if(1==b&&!a.isConnectedPrevious())return-1;if("0".equals(c))return a.leadAtomIndex;for(b=a.firstAtomIndex;b<=a.lastAtomIndex;b++)if(null==c||c.equalsIgnoreCase(this.atoms[b].getAtomName()))return b}return-1},
"J.modelset.Atom,~N,~S");$_M(c$,"haveModelKit",function(){for(var a=0;a<this.modelCount;a++)if(this.models[a].isModelKit)return!0;return!1});$_M(c$,"getModelKitStateBitset",function(a,b){for(var c=J.util.BSUtil.copy(b),d=0;d<this.modelCount;d++)this.models[d].isModelKit||c.andNot(this.models[d].bsAtoms);return J.util.BSUtil.deleteBits(a,c)},"JU.BS,JU.BS");$_M(c$,"setAtomNamesAndNumbers",function(a,b,c){0>b&&(a=this.models[this.atoms[a].modelIndex].firstAtomIndex);null==this.atomSerials&&(this.atomSerials=
Clazz.newIntArray(this.atomCount,0));null==this.atomNames&&(this.atomNames=Array(this.atomCount));for(var d=this.isXYZ&&this.viewer.getBoolean(603979978),e=2147483647,f=1;a<this.atomCount;++a){var g=this.atoms[a];g.modelIndex!=e&&(e=g.modelIndex,f=d?0:1);if(a>=-b){if(0==this.atomSerials[a]||0>b)this.atomSerials[a]=a<b?c.atomSerials[a]:f;if(null==this.atomNames[a]||0>b)this.atomNames[a]=(g.getElementSymbol()+this.atomSerials[a]).intern()}(!this.models[e].isModelKit||0<g.getElementNumber()&&!g.isDeleted())&&
f++}},"~N,~N,J.modelset.AtomCollection");$_M(c$,"setUnitCellOffset",function(a,b,c){for(var d=a;d<this.modelCount;d++)if(!(0>d||0<=a&&d!=a&&this.models[d].trajectoryBaseIndex!=a)){var e=this.getUnitCell(d);null!=e&&(null==b?e.setOffset(c):e.setOffsetPt(b))}},"~N,JU.P3,~N");$_M(c$,"connect",function(a){this.resetMolecules();for(var b=new JU.BS,c=0;c<a.length;c++){var d=a[c];if(!(null==d||2>d.length)){var e=Clazz.floatToInt(d[0]),f=0>e;f&&(e=-1-e);var g=Clazz.floatToInt(d[1]);if(!(0>g||e>=this.atomCount||
g>=this.atomCount)){var h=2<d.length?Clazz.floatToInt(d[2]):1;0>h&&(h&=65535);var k=3<d.length?Clazz.floatToShort(1E3*a[c][3]):this.getDefaultMadFromOrder(h);0==h||0==k&&32768!=h&&!J.modelset.Bond.isOrderH(h)?(d=this.atoms[e].getBond(this.atoms[g]),null!=d&&b.set(d.index)):this.bondAtoms(this.atoms[e],this.atoms[g],h,k,null,4<d.length?d[4]:0,f,!0)}}}0<=b.nextSetBit(0)&&this.deleteBonds(b,!1)},"~A");$_M(c$,"allowSpecAtom",function(){return 1!=this.modelCount||this.models[0].isBioModel});$_M(c$,"setFrameDelayMs",
function(a,b){for(var c=b.nextSetBit(0);0<=c;c=b.nextSetBit(c+1))this.models[this.models[c].trajectoryBaseIndex].frameDelay=a},"~N,JU.BS");$_M(c$,"getFrameDelayMs",function(a){return a<this.models.length&&0<=a?this.models[this.models[a].trajectoryBaseIndex].frameDelay:0},"~N");$_M(c$,"getModelIndexFromId",function(a){var b=0<=a.indexOf("#"),c=a.toLowerCase().endsWith(".basemodel");c&&(a=a.substring(0,a.length-10));for(var d=-1,e=null,f=0;f<this.modelCount;f++){var g=this.getModelAuxiliaryInfoValue(f,
"modelID"),h=a.startsWith("~")?"~"+this.getModelNumberDotted(f):null;if(!(null==h&&null==g&&null==(g=this.getModelTitle(f)))){b&&(e=this.getModelFileName(f)+"#",g=e+g);if(a.equalsIgnoreCase(g)||a.equalsIgnoreCase(h))return c?this.viewer.getJDXBaseModelIndex(f):f;null!=e&&a.startsWith(e)&&(d=-2)}}return null==e&&!b?-2:d},"~S");$_M(c$,"getAuxiliaryInfo",function(a){var b=this.modelSetAuxiliaryInfo;if(null==b)return null;for(var c=new JU.List,d=0;d<this.modelCount;++d)if(null==a||a.get(d)){var e=this.getModelAuxiliaryInfo(d);
c.addLast(e)}b.put("models",c);return b},"JU.BS");$_M(c$,"getDihedralMap",function(a){for(var b=new JU.List,c=a.length,d=null,e=null,f=null,g=null,h=c-1;0<=--h;)for(var k=c;--k>h;)if(d=this.atoms[a[h]],e=this.atoms[a[k]],d.isBonded(e))for(var l=c;0<=--l;)if(l!=h&&l!=k&&(f=this.atoms[a[l]]).isBonded(d))for(var m=c;0<=--m;)if(m!=h&&m!=k&&m!=l&&(g=this.atoms[a[m]]).isBonded(e)){var n=Clazz.newIntArray(4,0);n[0]=f.index;n[1]=d.index;n[2]=e.index;n[3]=g.index;b.addLast(n)}c=b.size();a=JU.ArrayUtil.newInt2(c);
for(h=c;0<=--h;)a[c-h-1]=b.get(h);return a},"~A");$_M(c$,"setModulation",function(a,b,c){null==this.bsModulated&&(this.bsModulated=new JU.BS);for(var d=a.nextSetBit(0);0<=d;d=a.nextSetBit(d+1)){var e=this.getVibration(d,!1);if(Clazz.instanceOf(e,J.util.ModulationSet)){var f=this.atoms[d],g=e.enabled;switch(e.setModT(b,c)){case 0:continue;case 1:case 2:f.sub(e);break;case 3:this.getUnitCell(f.modelIndex).toCartesian(e,!0);g&&f.add(e.prevSetting);e.setModT(!0,2147483647);f.sub(e);break;case 4:e.setModT(!0,
2147483647),g||f.sub(e)}this.bsModulated.setBitTo(d,e.enabled)}}},"JU.BS,~B,~N");$_M(c$,"getBoundBoxOrientation",function(a,b){var c=b.nextSetBit(0);if(0>c)return"{0 0 0 1}";var d=null==this.vOrientations?0:this.vOrientations.length;if(0==d){for(var e=Array(3375),d=0,f=new JU.P4,g=-7;7>=g;g++)for(var h=-7;7>=h;h++)for(var k=0;14>=k;k++,d++)1<(e[d]=JU.V3.new3(g/7,h/7,k/14)).length()&&--d;this.vOrientations=Array(d);for(g=d;0<=--g;)k=Math.sqrt(1-e[g].lengthSquared()),Float.isNaN(k)&&(k=0),f.set(e[g].x,
e[g].y,e[g].z,k),this.vOrientations[g]=J.util.Quaternion.newP4(f)}for(var e=new JU.P3,f=3.4028235E38,l=null,m=null,g=0;g<d;g++){var k=this.vOrientations[g],n=new J.util.BoxInfo;n.setMargin(0);for(h=c;0<=h;h=b.nextSetBit(h+1))n.addBoundBoxPoint(k.transformP2(this.atoms[h],e));switch(a){default:case 1313866247:case 1073741863:h=(n.bbCorner1.x-n.bbCorner0.x)*(n.bbCorner1.y-n.bbCorner0.y)*(n.bbCorner1.z-n.bbCorner0.z);break;case 1112541205:h=n.bbCorner1.x-n.bbCorner0.x;break;case 1112541206:h=n.bbCorner1.y-
n.bbCorner0.y;break;case 1112541207:h=n.bbCorner1.z-n.bbCorner0.z}h<f&&(l=k,m=n,f=h)}if(1313866247!=a&&1073741863!=a)return l.toString();k=J.util.Quaternion.newQ(l);c=m.bbCorner1.x-m.bbCorner0.x;d=m.bbCorner1.y-m.bbCorner0.y;g=m.bbCorner1.z-m.bbCorner0.z;c<d&&(e.set(0,0,1),k=J.util.Quaternion.newVA(e,90).mulQ(k),h=c,c=d,d=h);d<g&&(g>c&&(e.set(0,1,0),k=J.util.Quaternion.newVA(e,90).mulQ(k),h=c,c=g,g=h),e.set(1,0,0),k=J.util.Quaternion.newVA(e,90).mulQ(k),h=d,d=g,g=h);return 1313866247==a?f+"\t{"+c+
" "+d+" "+g+"}":0==k.getTheta()?"{0 0 0 1}":k.toString()},"~N,JU.BS");$_M(c$,"intersectPlane",function(a,b,c){return(null==this.triangulator?this.triangulator=J.api.Interface.getOptionInterface("util.TriangleData"):this.triangulator).intersectPlane(a,b,c)},"JU.P4,JU.List,~N");Clazz.pu$h();c$=Clazz.decorateAsClass(function(){this.modelIndex=0;this.script2=this.script1=this.bsAtoms2=this.bsAtoms1=this.bsBonds=null;this.inDefinedStateBlock=!1;Clazz.instantialize(this,arguments)},J.modelset.ModelCollection,
"StateScript");Clazz.makeConstructor(c$,function(a,b,c,d,e,f,g){this.modelIndex=a;this.script1=b;this.bsBonds=J.util.BSUtil.copy(c);this.bsAtoms1=J.util.BSUtil.copy(d);this.bsAtoms2=J.util.BSUtil.copy(e);this.script2=f;this.inDefinedStateBlock=g},"~N,~S,JU.BS,JU.BS,JU.BS,~S,~B");$_M(c$,"isValid",function(){return null!=this.script1&&0<this.script1.length&&(null==this.bsBonds||0<=this.bsBonds.nextSetBit(0))&&(null==this.bsAtoms1||0<=this.bsAtoms1.nextSetBit(0))&&(null==this.bsAtoms2||0<=this.bsAtoms2.nextSetBit(0))});
Clazz.overrideMethod(c$,"toString",function(){if(!this.isValid())return"";var a=JU.SB.newS(this.script1);null!=this.bsBonds&&a.append(" ").append(J.util.Escape.eBond(this.bsBonds));null!=this.bsAtoms1&&a.append(" ").append(J.util.Escape.eBS(this.bsAtoms1));null!=this.bsAtoms2&&a.append(" ").append(J.util.Escape.eBS(this.bsAtoms2));null!=this.script2&&a.append(" ").append(this.script2);a=a.toString();a.endsWith(";")||(a+=";");return a});$_M(c$,"isConnect",function(){return 0<=this.script1.indexOf("connect")});
$_M(c$,"deleteAtoms",function(a,b,c){if(a==this.modelIndex)return!1;if(a>this.modelIndex)return!0;J.util.BSUtil.deleteBits(this.bsBonds,b);J.util.BSUtil.deleteBits(this.bsAtoms1,c);J.util.BSUtil.deleteBits(this.bsAtoms2,c);return this.isValid()},"~N,JU.BS,JU.BS");$_M(c$,"setModelIndex",function(a){this.modelIndex=a},"~N");c$=Clazz.p0p();Clazz.defineStatics(c$,"hbondMin",2.5)}),Clazz.declarePackage("J.atomdata"),c$=Clazz.decorateAsClass(function(){this.modelName=this.fileName=this.programInfo=null;
this.modelIndex=0;this.radiusData=this.bsMolecules=this.bsIgnored=this.bsSelected=null;this.hAtomRadius=this.lastModelIndex=this.firstModelIndex=this.firstAtomIndex=0;this.hAtoms=this.atomMolecule=this.atomicNumber=this.atomRadius=this.atomXyz=this.atomIndex=null;this.adpMode=this.hydrogenAtomCount=this.atomCount=0;Clazz.instantialize(this,arguments)},J.atomdata,"AtomData"),Clazz.makeConstructor(c$,function(){}),Clazz.defineStatics(c$,"MODE_FILL_COORDS",1,"MODE_FILL_RADII",2,"MODE_FILL_MOLECULES",
4,"MODE_GET_ATTACHED_HYDROGENS",8,"MODE_FILL_MULTIMODEL",16),Clazz.declarePackage("J.modelset"),Clazz.load(null,"J.modelset.Measurement","java.lang.Float JU.A4 $.List $.P3 $.SB $.V3 J.atomdata.RadiusData J.constant.EnumVdw J.modelset.LabelToken J.util.Escape $.Measure".split(" "),function(){c$=Clazz.decorateAsClass(function(){this.modelSet=this.thisID=null;this.index=0;this.isVisible=!0;this.isTrajectory=this.isDynamic=this.isHidden=!1;this.$isValid=!0;this.colix=0;this.labelColix=-1;this.mad=0;this.tickInfo=
null;this.traceX=-2147483648;this.count=this.traceY=0;this.pts=this.countPlusIndices=null;this.value=0;this.type=this.text=this.pointArc=this.aa=this.strMeasurement=this.viewer=this.strFormat=null;Clazz.instantialize(this,arguments)},J.modelset,"Measurement");Clazz.prepareFields(c$,function(){this.countPlusIndices=Clazz.newIntArray(5,0)});$_M(c$,"setM",function(a,b,c,d,e,f){this.modelSet=a;this.index=f;this.viewer=a.viewer;this.colix=d;this.strFormat=e;null!=b&&(this.tickInfo=b.tickInfo,this.pts=
b.pts,this.mad=b.mad,this.thisID=b.thisID,this.text=b.text,null!=this.thisID&&null!=this.text&&(this.labelColix=this.text.colix));null==this.pts&&(this.pts=Array(4));b=null==b?null:b.countPlusIndices;this.count=null==b?0:b[0];0<this.count&&(System.arraycopy(b,0,this.countPlusIndices,0,this.count+1),this.isTrajectory=a.isTrajectoryMeasurement(this.countPlusIndices));this.value=Float.isNaN(c)||this.isTrajectory?this.getMeasurement():c;this.formatMeasurement(null);return this},"J.modelset.ModelSet,J.modelset.Measurement,~N,~N,~S,~N");
$_M(c$,"setPoints",function(a,b,c,d){this.modelSet=a;this.countPlusIndices=b;this.count=b[0];this.pts=null==c?Array(4):c;this.viewer=a.viewer;this.tickInfo=d;return this},"J.modelset.ModelSet,~A,~A,J.modelset.TickInfo");$_M(c$,"getCount",function(){return this.count});$_M(c$,"setCount",function(a){this.setCountM(a)},"~N");$_M(c$,"setCountM",function(a){this.count=this.countPlusIndices[0]=a},"~N");$_M(c$,"getCountPlusIndices",function(){return this.countPlusIndices});$_M(c$,"getPoints",function(){return this.pts});
$_M(c$,"getAtomIndex",function(a){return 0<a&&a<=this.count?this.countPlusIndices[a]:-1},"~N");$_M(c$,"getAtom",function(a){a=this.countPlusIndices[a];return-1>a?this.pts[-2-a]:this.modelSet.atoms[a]},"~N");$_M(c$,"getLastIndex",function(){return 0<this.count?this.countPlusIndices[this.count]:-1});$_M(c$,"getString",function(){return this.strMeasurement});$_M(c$,"getStringUsing",function(a,b,c){this.viewer=a;this.value=this.getMeasurement();this.formatMeasurementAs(b,c,!0);return null==b?this.getInfoAsString(c):
this.strMeasurement},"J.viewer.Viewer,~S,~S");$_M(c$,"getStringDetail",function(){return(2==this.count?"Distance":3==this.count?"Angle":"Torsion")+this.getMeasurementScript(" - ",!1)+" : "+this.value});$_M(c$,"getStrFormat",function(){return this.strFormat});$_M(c$,"getValue",function(){return this.value});$_M(c$,"getAxisAngle",function(){return this.aa});$_M(c$,"getPointArc",function(){return this.pointArc});$_M(c$,"refresh",function(){this.value=this.getMeasurement();this.isTrajectory=this.modelSet.isTrajectoryMeasurement(this.countPlusIndices);
this.formatMeasurement(null)});$_M(c$,"getMeasurementScript",function(a,b){for(var c="",d=a.equals(" "),e=1;e<=this.count;e++)c+=(1<e?a:" ")+this.getLabel(e,d,b);return c},"~S,~B");$_M(c$,"formatMeasurementAs",function(a,b,c){null!=a&&0==a.length&&(a=null);if(c||!(null!=a&&0!=a.indexOf(this.countPlusIndices[0]+":")))this.strFormat=a,this.formatMeasurement(b)},"~S,~S,~B");$_M(c$,"formatMeasurement",function(a){this.strMeasurement=null;if(!(Float.isNaN(this.value)||0==this.count))switch(this.count){case 2:this.strMeasurement=
this.formatDistance(a);break;case 3:if(180==this.value)this.pointArc=this.aa=null;else{a=new JU.V3;var b=new JU.V3,c=J.util.Measure.computeAngle(this.getAtom(1),this.getAtom(2),this.getAtom(3),a,b,!1),d=new JU.V3;d.cross(a,b);this.aa=JU.A4.new4(d.x,d.y,d.z,c);a.normalize();a.scale(0.5);this.pointArc=JU.P3.newP(a)}case 4:this.strMeasurement=this.formatAngle(this.value)}},"~S");$_M(c$,"reformatDistanceIfSelected",function(){2==this.count&&this.viewer.isSelected(this.countPlusIndices[1])&&this.viewer.isSelected(this.countPlusIndices[2])&&
this.formatMeasurement(null)});$_M(c$,"formatDistance",($fz=function(a){var b=this.getLabelString();if(null==b)return"";System.out.println("strformat="+this.strFormat+" units="+a);if(null==a){var c=this.strFormat.indexOf("//");a=0<=c?this.strFormat.substring(c+2):null;null==a&&(a=this.viewer.getMeasureDistanceUnits(),this.strFormat+="//"+a,3==this.count&&System.out.println("measu"))}a=J.modelset.Measurement.fixUnits(a);c=b.indexOf("//");0<=c&&(b=b.substring(0,c),0==b.length&&(b="%VALUE"));c=this.fixValue(a,
0<=b.indexOf("%V"));return this.formatString(c,a,b)},$fz.isPrivate=!0,$fz),"~S");c$.fixUnits=$_M(c$,"fixUnits",($fz=function(a){return a.equals("nanometers")?"nm":a.equals("picometers")?"pm":a.equals("angstroms")?"\u00c5":a.equals("vanderwaals")||a.equals("vdw")?"%":a},$fz.isPrivate=!0,$fz),"~S");$_M(c$,"fixValue",function(a,b){if(2!=this.count)return this.value;var c=this.value;if(null!=a){var d=a.equals("%");if(d||a.endsWith("hz")){var e=this.getAtomIndex(1),f=this.getAtomIndex(2);if(0<=e&&0<=f){var e=
this.getAtom(1),f=this.getAtom(2),g=!d&&1==J.modelset.Measurement.nmrType(a);this.type=d?"percent":g?"dipoleCouplingConstant":"J-CouplingConstant";c=d?c/(e.getVanderwaalsRadiusFloat(this.viewer,J.constant.EnumVdw.AUTO)+f.getVanderwaalsRadiusFloat(this.viewer,J.constant.EnumVdw.AUTO)):g?this.viewer.getNMRCalculation().getDipolarConstantHz(e,f):this.viewer.getNMRCalculation().getIsoOrAnisoHz(!0,e,f,a,null);this.$isValid=!Float.isNaN(c);d&&(a="pm")}}if(a.equals("nm"))return b?Math.round(100*c)/1E3:c/
10;if(a.equals("pm"))return b?Math.round(1E3*c)/10:100*c;if(a.equals("au"))return b?Math.round(1E3*(c/0.5291772))/1E3:c/0.5291772;if(a.endsWith("khz"))return b?Math.round(c/10)/100:c/1E3}return b?Math.round(100*c)/100:c},"~S,~B");c$.nmrType=$_M(c$,"nmrType",function(a){return 0>a.indexOf("hz")?0:a.startsWith("dc_")||a.equals("khz")?1:2},"~S");$_M(c$,"formatAngle",($fz=function(a){var b=this.getLabelString();0<=b.indexOf("%V")&&(a=Math.round(10*a)/10);return this.formatString(a,"\u00b0",b)},$fz.isPrivate=
!0,$fz),"~N");$_M(c$,"getLabelString",($fz=function(){var a=this.countPlusIndices[0]+":",b=null;if(null!=this.strFormat){if(0==this.strFormat.length)return null;b=2<this.strFormat.length&&0==this.strFormat.indexOf(a)?this.strFormat:null}null==b&&(this.strFormat=null,b=this.viewer.getDefaultMeasurementLabel(this.countPlusIndices[0]));0==b.indexOf(a)&&(b=b.substring(2));null==this.strFormat&&(this.strFormat=a+b);return b},$fz.isPrivate=!0,$fz));$_M(c$,"formatString",($fz=function(a,b,c){return J.modelset.LabelToken.formatLabelMeasure(this.viewer,
this,c,a,b)},$fz.isPrivate=!0,$fz),"~N,~S,~S");$_M(c$,"sameAsPoints",function(a,b){if(this.count!=a[0])return!1;for(var c=!0,d=1;d<=this.count&&c;d++)c=this.countPlusIndices[d]==a[d];if(c)for(d=0;d<this.count&&c;d++)null!=b[d]&&(c=0.01>this.pts[d].distance(b[d]));if(c)return!0;switch(this.count){default:return!0;case 2:return this.sameAsIJ(a,b,1,2)&&this.sameAsIJ(a,b,2,1);case 3:return this.sameAsIJ(a,b,1,3)&&this.sameAsIJ(a,b,2,2)&&this.sameAsIJ(a,b,3,1);case 4:return this.sameAsIJ(a,b,1,4)&&this.sameAsIJ(a,
b,2,3)&&this.sameAsIJ(a,b,3,2)&&this.sameAsIJ(a,b,4,1)}},"~A,~A");$_M(c$,"sameAsIJ",($fz=function(a,b,c,d){c=this.countPlusIndices[c];a=a[d];return 0<=c||0<=a?c==a:0.01>this.pts[-2-c].distance(b[-2-a])},$fz.isPrivate=!0,$fz),"~A,~A,~N,~N");$_M(c$,"sameAs",function(a,b){return this.sameAsIJ(this.countPlusIndices,this.pts,a,b)},"~N,~N");$_M(c$,"toVector",function(a){for(var b=new JU.List,c=1;c<=this.count;c++)b.addLast(this.getLabel(c,a,!1));b.addLast(this.strMeasurement);return b},"~B");$_M(c$,"getMeasurement",
function(){if(null==this.countPlusIndices||2>this.count)return NaN;for(var a=this.count;0<=--a;)if(-1==this.countPlusIndices[a+1])return NaN;var a=this.getAtom(1),b=this.getAtom(2),c,d;switch(this.count){case 2:return a.distance(b);case 3:return c=this.getAtom(3),J.util.Measure.computeAngleABC(a,b,c,!0);case 4:return c=this.getAtom(3),d=this.getAtom(4),J.util.Measure.computeTorsion(a,b,c,d,!0);default:return NaN}});$_M(c$,"getLabel",function(a,b,c){var d=this.countPlusIndices[a];return 0>d?(c?"modelIndex "+
this.getAtom(a).modelIndex+" ":"")+J.util.Escape.eP(this.getAtom(a)):b?"(({"+d+"}))":this.viewer.getAtomInfo(d)},"~N,~B,~B");$_M(c$,"setModelIndex",function(a){if(null!=this.pts)for(var b=0;b<this.count;b++)null!=this.pts[b]&&(this.pts[b].modelIndex=a)},"~N");$_M(c$,"isValid",function(){return!(this.sameAs(1,2)||2<this.count&&this.sameAs(1,3)||4==this.count&&this.sameAs(2,4))});c$.find=$_M(c$,"find",function(a,b){for(var c=b.getCountPlusIndices(),d=b.getPoints(),e=a.size();0<=--e;)if(a.get(e).sameAsPoints(c,
d))return e;return-1},"JU.List,J.modelset.Measurement");$_M(c$,"isConnected",function(a,b){for(var c=-1,d=1;d<=b;d++){var e=this.getAtomIndex(d);if(!(0>e)){if(0<=c&&!a[e].isBonded(a[c]))return!1;c=e}}return!0},"~A,~N");$_M(c$,"getInfoAsString",function(a){var b=this.fixValue(a,!0);a=new JU.SB;a.append(2==this.count?null==this.type?"distance":this.type:3==this.count?"angle":"dihedral");a.append(" \t").appendF(b);a.append(" \t").append(J.util.Escape.eS(this.strMeasurement));for(b=1;b<=this.count;b++)a.append(" \t").append(this.getLabel(b,
!1,!1));null!=this.thisID&&a.append(" \t").append(this.thisID);return a.toString()},"~S");$_M(c$,"isInRange",function(a,b){if(a.factorType===J.atomdata.RadiusData.EnumType.FACTOR){var c=this.getAtom(1),d=this.getAtom(2),c=(c.getVanderwaalsRadiusFloat(this.viewer,a.vdwType)+d.getVanderwaalsRadiusFloat(this.viewer,a.vdwType))*a.value;return b<=c}return 3.4028235E38==a.values[0]||b>=a.values[0]&&b<=a.values[1]},"J.atomdata.RadiusData,~N");$_M(c$,"isIntramolecular",function(a,b){for(var c=-1,d=1;d<=b;d++){var e=
this.getAtomIndex(d);if(!(0>e))if(e=a[e].getMoleculeNumber(!1),0>c)c=e;else if(e!=c)return!1}return!0},"~A,~N");$_M(c$,"isMin",function(a){var b=this.getAtom(1),c=this.getAtom(2),d=Clazz.floatToInt(100*c.distanceSquared(b)),b=b.getAtomName(),c=c.getAtomName(),c=0>b.compareTo(c)?b+c:c+b;a=a.get(c);return null!=a&&d==a.intValue()},"java.util.Map");Clazz.defineStatics(c$,"NMR_NOT",0,"NMR_DC",1,"NMR_JC",2)}),Clazz.declarePackage("J.util"),Clazz.load(["JU.ArrayUtil"],"J.util.Geodesic",["java.lang.NullPointerException",
"$.Short","java.util.Hashtable","JU.V3"],function(){c$=Clazz.declareType(J.util,"Geodesic");c$.getNeighborVertexesArrays=$_M(c$,"getNeighborVertexesArrays",function(){null==J.util.Geodesic.vertexCounts&&J.util.Geodesic.createGeodesic(3);return J.util.Geodesic.neighborVertexesArrays});c$.getVertexCount=$_M(c$,"getVertexCount",function(a){null==J.util.Geodesic.vertexCounts&&J.util.Geodesic.createGeodesic(3);return J.util.Geodesic.vertexCounts[a]},"~N");c$.getVertexVectors=$_M(c$,"getVertexVectors",
function(){null==J.util.Geodesic.vertexCounts&&J.util.Geodesic.createGeodesic(3);return J.util.Geodesic.vertexVectors});c$.getVertexVector=$_M(c$,"getVertexVector",function(a){return J.util.Geodesic.vertexVectors[a]},"~N");c$.getFaceVertexes=$_M(c$,"getFaceVertexes",function(a){return J.util.Geodesic.faceVertexesArrays[a]},"~N");c$.createGeodesic=$_M(c$,"createGeodesic",function(a){if(!(a<J.util.Geodesic.currentLevel)){$t$=J.util.Geodesic.currentLevel=a;J.util.Geodesic.prototype.currentLevel=J.util.Geodesic.currentLevel;
$t$;var b=Clazz.newShortArray(a+1,0);$t$=J.util.Geodesic.neighborVertexesArrays=JU.ArrayUtil.newShort2(a+1);J.util.Geodesic.prototype.neighborVertexesArrays=J.util.Geodesic.neighborVertexesArrays;$t$;$t$=J.util.Geodesic.faceVertexesArrays=JU.ArrayUtil.newShort2(a+1);J.util.Geodesic.prototype.faceVertexesArrays=J.util.Geodesic.faceVertexesArrays;$t$;$t$=J.util.Geodesic.vertexVectors=Array(12);J.util.Geodesic.prototype.vertexVectors=J.util.Geodesic.vertexVectors;$t$;J.util.Geodesic.vertexVectors[0]=
JU.V3.new3(0,0,J.util.Geodesic.halfRoot5);for(var c=0;5>c;++c)J.util.Geodesic.vertexVectors[c+1]=JU.V3.new3(Math.cos(1.2566371*c),Math.sin(1.2566371*c),0.5),J.util.Geodesic.vertexVectors[c+6]=JU.V3.new3(Math.cos(1.2566371*c+0.62831855),Math.sin(1.2566371*c+0.62831855),-0.5);J.util.Geodesic.vertexVectors[11]=JU.V3.new3(0,0,($t$=-J.util.Geodesic.halfRoot5,J.util.Geodesic.prototype.halfRoot5=J.util.Geodesic.halfRoot5,$t$));for(c=12;0<=--c;)J.util.Geodesic.vertexVectors[c].normalize();J.util.Geodesic.faceVertexesArrays[0]=
J.util.Geodesic.faceVertexesIcosahedron;J.util.Geodesic.neighborVertexesArrays[0]=J.util.Geodesic.neighborVertexesIcosahedron;b[0]=12;for(c=0;c<a;++c)J.util.Geodesic.quadruple(c,b);$t$=J.util.Geodesic.vertexCounts=b;J.util.Geodesic.prototype.vertexCounts=J.util.Geodesic.vertexCounts;$t$}},"~N");c$.quadruple=$_M(c$,"quadruple",($fz=function(a,b){$t$=J.util.Geodesic.htVertex=new java.util.Hashtable;J.util.Geodesic.prototype.htVertex=J.util.Geodesic.htVertex;$t$;var c=J.util.Geodesic.vertexVectors.length,
d=J.util.Geodesic.faceVertexesArrays[a],e=d.length,f=Clazz.doubleToInt(e/3),g=c+(c+f-2),f=4*f;$t$=J.util.Geodesic.vertexVectors=JU.ArrayUtil.arrayCopyObject(J.util.Geodesic.vertexVectors,g);J.util.Geodesic.prototype.vertexVectors=J.util.Geodesic.vertexVectors;$t$;f=Clazz.newShortArray(3*f,0);J.util.Geodesic.faceVertexesArrays[a+1]=f;var h=Clazz.newShortArray(6*g,0);J.util.Geodesic.neighborVertexesArrays[a+1]=h;for(var k=h.length;0<=--k;)h[k]=-1;b[a+1]=g;$t$=J.util.Geodesic.vertexNext=c;J.util.Geodesic.prototype.vertexNext=
J.util.Geodesic.vertexNext;$t$;for(k=c=0;k<e;){var l=d[k++],m=d[k++],n=d[k++],q=J.util.Geodesic.getVertex(l,m),p=J.util.Geodesic.getVertex(m,n),r=J.util.Geodesic.getVertex(n,l);f[c++]=l;f[c++]=q;f[c++]=r;f[c++]=m;f[c++]=p;f[c++]=q;f[c++]=n;f[c++]=r;f[c++]=p;f[c++]=r;f[c++]=q;f[c++]=p;J.util.Geodesic.addNeighboringVertexes(h,q,l);J.util.Geodesic.addNeighboringVertexes(h,q,r);J.util.Geodesic.addNeighboringVertexes(h,q,p);J.util.Geodesic.addNeighboringVertexes(h,q,m);J.util.Geodesic.addNeighboringVertexes(h,
p,m);J.util.Geodesic.addNeighboringVertexes(h,p,r);J.util.Geodesic.addNeighboringVertexes(h,p,n);J.util.Geodesic.addNeighboringVertexes(h,r,n);J.util.Geodesic.addNeighboringVertexes(h,r,l)}e=J.util.Geodesic.vertexVectors.length;if(c!=f.length)throw new NullPointerException;if(J.util.Geodesic.vertexNext!=g)throw new NullPointerException;for(k=0;12>k;++k)for(d=0;5>d;++d){c=h[6*k+d];if(0>c)throw new NullPointerException;if(c>=e)throw new NullPointerException;if(-1!=h[6*k+5])throw new NullPointerException;
}for(k=72;k<h.length;++k){c=h[k];if(0>c)throw new NullPointerException;if(c>=e)throw new NullPointerException;}for(k=0;k<g;++k){e=0;for(d=h.length;0<=--d;)h[d]==k&&++e;if(12>k&&5!=e||12<=k&&6!=e)throw new NullPointerException;e=0;for(d=f.length;0<=--d;)f[d]==k&&++e;if(12>k&&5!=e||12<=k&&6!=e)throw new NullPointerException;}$t$=J.util.Geodesic.htVertex=null;J.util.Geodesic.prototype.htVertex=J.util.Geodesic.htVertex;$t$},$fz.isPrivate=!0,$fz),"~N,~A");c$.addNeighboringVertexes=$_M(c$,"addNeighboringVertexes",
($fz=function(a,b,c){for(var d=6*b,e=d+6;d<e;++d){if(a[d]==c)return;if(0>a[d]){a[d]=c;for(var f=6*c,g=f+6;f<g;++f){if(a[f]==b)return;if(0>a[f]){a[f]=b;return}}}}throw new NullPointerException;},$fz.isPrivate=!0,$fz),"~A,~N,~N");c$.getVertex=$_M(c$,"getVertex",($fz=function(a,b){if(a>b){var c=a;a=b;b=c}var c=Integer.$valueOf((a<<16)+b),d=J.util.Geodesic.htVertex.get(c);if(null!=d)return d.shortValue();d=JU.V3.newV(J.util.Geodesic.vertexVectors[a]);J.util.Geodesic.vertexVectors[J.util.Geodesic.vertexNext]=
d;d.add(J.util.Geodesic.vertexVectors[b]);d.scale(0.5);d.normalize();J.util.Geodesic.htVertex.put(c,Short.$valueOf(J.util.Geodesic.vertexNext));return $t$=J.util.Geodesic.vertexNext++,J.util.Geodesic.prototype.vertexNext=J.util.Geodesic.vertexNext,$t$},$fz.isPrivate=!0,$fz),"~N,~N");c$.halfRoot5=c$.prototype.halfRoot5=0.5*Math.sqrt(5);Clazz.defineStatics(c$,"oneFifth",1.2566371,"oneTenth",0.62831855,"faceVertexesIcosahedron",[0,1,2,0,2,3,0,3,4,0,4,5,0,5,1,1,6,2,2,7,3,3,8,4,4,9,5,5,10,1,6,1,10,7,2,
6,8,3,7,9,4,8,10,5,9,11,6,10,11,7,6,11,8,7,11,9,8,11,10,9],"neighborVertexesIcosahedron",[1,2,3,4,5,-1,0,5,10,6,2,-1,0,1,6,7,3,-1,0,2,7,8,4,-1,0,3,8,9,5,-1,0,4,9,10,1,-1,1,10,11,7,2,-1,2,6,11,8,3,-1,3,7,11,9,4,-1,4,8,11,10,5,-1,5,9,11,6,1,-1,6,7,8,9,10,-1],"standardLevel",3,"maxLevel",3,"vertexCounts",null,"vertexVectors",null,"faceVertexesArrays",null,"neighborVertexesArrays",null,"currentLevel",0,"vertexNext",0,"htVertex",null,"VALIDATE",!0)}),Clazz.declarePackage("J.util"),Clazz.load(["J.util.Geodesic"],
"J.util.Normix",["JU.BS"],function(){c$=Clazz.declareType(J.util,"Normix");c$.getNormixCount=$_M(c$,"getNormixCount",function(){0==J.util.Normix.normixCount&&($t$=J.util.Normix.normixCount=J.util.Geodesic.getVertexCount(3),J.util.Normix.prototype.normixCount=J.util.Normix.normixCount,$t$);return J.util.Normix.normixCount});c$.newVertexBitSet=$_M(c$,"newVertexBitSet",function(){return JU.BS.newN(J.util.Normix.getNormixCount())});c$.getVertexVectors=$_M(c$,"getVertexVectors",function(){null==J.util.Normix.vertexVectors&&
($t$=J.util.Normix.vertexVectors=J.util.Geodesic.getVertexVectors(),J.util.Normix.prototype.vertexVectors=J.util.Normix.vertexVectors,$t$);return J.util.Normix.vertexVectors});c$.setInverseNormixes=$_M(c$,"setInverseNormixes",function(){if(null==J.util.Normix.inverseNormixes){J.util.Normix.getNormixCount();J.util.Normix.getVertexVectors();$t$=J.util.Normix.inverseNormixes=Clazz.newShortArray(J.util.Normix.normixCount,0);J.util.Normix.prototype.inverseNormixes=J.util.Normix.inverseNormixes;$t$;for(var a=
new JU.BS,b=J.util.Normix.normixCount;0<=--b;){var c=J.util.Normix.vertexVectors[b];J.util.Normix.inverseNormixes[b]=J.util.Normix.getNormix(-c.x,-c.y,-c.z,3,a)}}});c$.getInverseNormix=$_M(c$,"getInverseNormix",function(a){return J.util.Normix.inverseNormixes[a]},"~N");c$.getNeighborVertexArrays=$_M(c$,"getNeighborVertexArrays",($fz=function(){null==J.util.Normix.neighborVertexesArrays&&($t$=J.util.Normix.neighborVertexesArrays=J.util.Geodesic.getNeighborVertexesArrays(),J.util.Normix.prototype.neighborVertexesArrays=
J.util.Normix.neighborVertexesArrays,$t$);return J.util.Normix.neighborVertexesArrays},$fz.isPrivate=!0,$fz));c$.getNormixV=$_M(c$,"getNormixV",function(a,b){return J.util.Normix.getNormix(a.x,a.y,a.z,3,b)},"JU.V3,JU.BS");c$.get2SidedNormix=$_M(c$,"get2SidedNormix",function(a,b){return~J.util.Normix.getNormixV(a,b)},"JU.V3,JU.BS");c$.getNormix=$_M(c$,"getNormix",($fz=function(a,b,c,d,e){var f,g;0<=c?(f=0,g=c-1):(f=11,g=c- -1);e.clearAll();e.set(f);J.util.Normix.getVertexVectors();J.util.Normix.getNeighborVertexArrays();
g=a*a+b*b+g*g;for(var h=0;h<=d;++h)for(var k=J.util.Normix.neighborVertexesArrays[h],l=6*f,m=l+(12>f?5:6);--m>=l;){var n=k[m];if(!e.get(n)){e.set(n);var q=J.util.Normix.vertexVectors[n],p;p=q.x-a;var r=p*p;r>=g||(p=q.y-b,r+=p*p,r>=g||(p=q.z-c,r+=p*p,r>=g||(f=n,g=r)))}}return f},$fz.isPrivate=!0,$fz),"~N,~N,~N,~N,JU.BS");Clazz.defineStatics(c$,"NORMIX_GEODESIC_LEVEL",3,"normixCount",0,"vertexVectors",null,"inverseNormixes",null,"neighborVertexesArrays",null,"NORMIX_NULL",9999)}),Clazz.declarePackage("J.modelset"),
Clazz.declareInterface(J.modelset,"BondIterator"),Clazz.declarePackage("J.modelset"),Clazz.load(["J.modelset.BondIterator"],"J.modelset.BondIteratorSelected",null,function(){c$=Clazz.decorateAsClass(function(){this.bonds=null;this.iBond=this.bondType=this.bondCount=0;this.bsSelected=null;this.bondSelectionModeOr=!1;Clazz.instantialize(this,arguments)},J.modelset,"BondIteratorSelected",null,J.modelset.BondIterator);Clazz.makeConstructor(c$,function(a,b,c,d,e){this.bonds=a;this.bondCount=b;this.bondType=
c;this.bsSelected=d;this.bondSelectionModeOr=e},"~A,~N,~N,JU.BS,~B");Clazz.overrideMethod(c$,"hasNext",function(){if(131071==this.bondType)return this.iBond=this.bsSelected.nextSetBit(this.iBond),0<=this.iBond&&this.iBond<this.bondCount;for(;this.iBond<this.bondCount;++this.iBond){var a=this.bonds[this.iBond];if(!(65535!=this.bondType&&0==(a.order&this.bondType))&&!(65535==this.bondType&&0!=(a.order&32768))){var b=this.bsSelected.get(a.atom1.index),a=this.bsSelected.get(a.atom2.index);if(!this.bondSelectionModeOr&&
b&&a||this.bondSelectionModeOr&&(b||a))return!0}}return!1});Clazz.overrideMethod(c$,"nextIndex",function(){return this.iBond});Clazz.overrideMethod(c$,"next",function(){return this.bonds[this.iBond++]})}),Clazz.declarePackage("J.modelset"),Clazz.load(["J.modelset.Bond"],"J.modelset.HBond",["J.util.Logger"],function(){c$=Clazz.decorateAsClass(function(){this.paletteID=this.energy=0;Clazz.instantialize(this,arguments)},J.modelset,"HBond",J.modelset.Bond);Clazz.makeConstructor(c$,function(a,b,c,d,e,
f){Clazz.superConstructor(this,J.modelset.HBond,[a,b,c,d,e]);this.energy=f;J.util.Logger.debugging&&J.util.Logger.debug("HBond energy = "+f+" #"+this.getIdentity())},"J.modelset.Atom,J.modelset.Atom,~N,~N,~N,~N");$_M(c$,"getEnergy",function(){return this.energy});$_M(c$,"getPaletteId",function(){return this.paletteID});Clazz.overrideMethod(c$,"setPaletteID",function(a){this.paletteID=a},"~N");c$.getEnergy=$_M(c$,"getEnergy",function(a,b,c,d){return Math.round(-27888/a- -27888/d+-27888/c- -27888/b)},
"~N,~N,~N,~N");Clazz.defineStatics(c$,"QConst",-27888)}),Clazz.declarePackage("J.bspt"),Clazz.load(null,"J.bspt.Bspf",["JU.ArrayUtil","J.bspt.Bspt","J.util.Logger"],function(){c$=Clazz.decorateAsClass(function(){this.dimMax=0;this.bspts=null;this.isValid=!1;this.cubeIterators=this.bsptsValid=null;Clazz.instantialize(this,arguments)},J.bspt,"Bspf");$_M(c$,"validate",function(a){this.isValid=a},"~B");$_M(c$,"validateModel",function(a,b){this.bsptsValid[a]=b},"~N,~B");$_M(c$,"isInitialized",function(){return this.isValid});
$_M(c$,"isInitializedIndex",function(a){return this.bspts.length>a&&null!=this.bspts[a]&&this.bsptsValid[a]},"~N");Clazz.makeConstructor(c$,function(a){this.dimMax=a;this.bspts=[];this.bsptsValid=Clazz.newBooleanArray(0,!1);this.cubeIterators=[]},"~N");$_M(c$,"getBsptCount",function(){return this.bspts.length});$_M(c$,"addTuple",function(a,b){a>=this.bspts.length&&(this.bspts=JU.ArrayUtil.arrayCopyObject(this.bspts,a+1),this.bsptsValid=JU.ArrayUtil.arrayCopyBool(this.bsptsValid,a+1));var c=this.bspts[a];
null==c&&(c=this.bspts[a]=new J.bspt.Bspt(this.dimMax,a));c.addTuple(b)},"~N,JU.P3");$_M(c$,"stats",function(){for(var a=0;a<this.bspts.length;++a)null!=this.bspts[a]&&this.bspts[a].stats()});$_M(c$,"dump",function(){for(var a=0;a<this.bspts.length;++a)J.util.Logger.info(">>>>\nDumping bspt #"+a+"\n>>>>"),this.bspts[a].dump();J.util.Logger.info("<<<<")});$_M(c$,"getCubeIterator",function(a){if(0>a)return this.getNewCubeIterator(-1-a);a>=this.cubeIterators.length&&(this.cubeIterators=JU.ArrayUtil.arrayCopyObject(this.cubeIterators,
a+1));null==this.cubeIterators[a]&&null!=this.bspts[a]&&(this.cubeIterators[a]=this.getNewCubeIterator(a));this.cubeIterators[a].set(this.bspts[a]);return this.cubeIterators[a]},"~N");$_M(c$,"getNewCubeIterator",function(a){return this.bspts[a].allocateCubeIterator()},"~N");$_M(c$,"initialize",function(a,b,c){null!=this.bspts[a]&&this.bspts[a].reset();for(var d=c.nextSetBit(0);0<=d;d=c.nextSetBit(d+1))this.addTuple(a,b[d]);this.bsptsValid[a]=!0},"~N,~A,JU.BS")}),Clazz.declarePackage("J.io"),Clazz.load(null,
"J.io.XmlUtil",["J.util.Txt"],function(){c$=Clazz.declareType(J.io,"XmlUtil");Clazz.makeConstructor(c$,function(){});c$.openDocument=$_M(c$,"openDocument",function(a){a.append('<?xml version="1.0"?>\n')},"JU.SB");c$.openTag=$_M(c$,"openTag",function(a,b){a.append("<").append(b).append(">\n")},"JU.SB,~S");c$.openTagAttr=$_M(c$,"openTagAttr",function(a,b,c){J.io.XmlUtil.appendTagAll(a,b,c,null,!1,!1);a.append("\n")},"JU.SB,~S,~A");c$.closeTag=$_M(c$,"closeTag",function(a,b){a.append("</").append(b).append(">\n")},
"JU.SB,~S");c$.appendTagAll=$_M(c$,"appendTagAll",function(a,b,c,d,e,f){var g=">";b.endsWith("/")&&(b=b.substring(0,b.length-1),null==d&&(g="/>\n",f=!1));a.append("<").append(b);if(null!=c)for(var h=0;h<c.length;h++){var k=c[h];if(null!=k)if(Clazz.instanceOf(k,Array))for(var l=0;l<k.length;l+=2)J.io.XmlUtil.appendAttrib(a,k[l],k[l+1]);else J.io.XmlUtil.appendAttrib(a,k,c[++h])}a.append(g);null!=d&&(e&&(d=J.io.XmlUtil.wrapCdata(d)),a.appendO(d));f&&J.io.XmlUtil.closeTag(a,b)},"JU.SB,~S,~A,~O,~B,~B");
c$.wrapCdata=$_M(c$,"wrapCdata",function(a){a=""+a;return 0>a.indexOf("&")&&0>a.indexOf("<")?(a.startsWith("\n")?"":"\n")+a:"<![CDATA["+J.util.Txt.simpleReplace(a,"]]\x3e","]]]]\x3e<![CDATA[>")+"]]\x3e"},"~O");c$.unwrapCdata=$_M(c$,"unwrapCdata",function(a){return a.startsWith("<![CDATA[")&&a.endsWith("]]\x3e")?J.util.Txt.simpleReplace(a.substring(9,a.length-3),"]]]]\x3e<![CDATA[>","]]\x3e"):a},"~S");c$.appendTagObj=$_M(c$,"appendTagObj",function(a,b,c,d){J.io.XmlUtil.appendTagAll(a,b,c,d,!1,!0)},
"JU.SB,~S,~A,~O");c$.appendTag=$_M(c$,"appendTag",function(a,b,c){Clazz.instanceOf(c,Array)?J.io.XmlUtil.appendTagAll(a,b,c,null,!1,!0):J.io.XmlUtil.appendTagAll(a,b,null,c,!1,!0)},"JU.SB,~S,~O");c$.appendCdata=$_M(c$,"appendCdata",function(a,b,c,d){J.io.XmlUtil.appendTagAll(a,b,c,d,!0,!0)},"JU.SB,~S,~A,~S");c$.appendAttrib=$_M(c$,"appendAttrib",function(a,b,c){null!=c&&a.append(" ").appendO(b).append('="').appendO(c).append('"')},"JU.SB,~O,~O")}),Clazz.declarePackage("J.api"),Clazz.declareInterface(J.api,
"AtomIndexIterator"),Clazz.declarePackage("J.modelset"),Clazz.load(["J.api.AtomIndexIterator"],"J.modelset.AtomIteratorWithinModel",["J.atomdata.RadiusData"],function(){c$=Clazz.decorateAsClass(function(){this.bspf=this.cubeIterator=null;this.isZeroBased=this.hemisphereOnly=this.threadSafe=!1;this.modelIndex=2147483647;this.atomIndex=-1;this.distanceSquared=this.zeroBase=0;this.bsSelected=null;this.checkGreater=this.isGreaterOnly=!1;this.radiusData=null;this.vdw1=0;this.isVdw=!1;this.viewer=this.atoms=
null;this.iNext=0;Clazz.instantialize(this,arguments)},J.modelset,"AtomIteratorWithinModel",null,J.api.AtomIndexIterator);Clazz.makeConstructor(c$,function(){});$_M(c$,"initialize",function(a,b,c,d,e,f){this.bspf=a;this.bsSelected=b;this.isGreaterOnly=c;this.isZeroBased=d;this.hemisphereOnly=e;this.threadSafe=f;this.cubeIterator=null},"J.bspt.Bspf,JU.BS,~B,~B,~B,~B");Clazz.overrideMethod(c$,"setModel",function(a,b,c,d,e,f,g){this.threadSafe&&(b=-1-b);if(b!=this.modelIndex||null==this.cubeIterator)this.cubeIterator=
this.bspf.getCubeIterator(b),this.modelIndex=b;this.zeroBase=this.isZeroBased?c:0;if(-2147483648!=f){this.atomIndex=0>f?-1:d;if(this.isVdw=null!=g)this.radiusData=g,this.atoms=a.atoms,this.viewer=a.viewer,f=g.factorType===J.atomdata.RadiusData.EnumType.OFFSET?5+g.value:5*g.value,this.vdw1=this.atoms[d].getVanderwaalsRadiusFloat(this.viewer,g.vdwType);this.checkGreater=this.isGreaterOnly&&2147483647!=d;this.setCenter(e,f)}},"J.modelset.ModelCollection,~N,~N,~N,JU.P3,~N,J.atomdata.RadiusData");Clazz.overrideMethod(c$,
"setCenter",function(a,b){this.setCenter2(a,b)},"JU.P3,~N");$_M(c$,"setCenter2",function(a,b){null!=this.cubeIterator&&(this.cubeIterator.initialize(a,b,this.hemisphereOnly),this.distanceSquared=b*b)},"JU.P3,~N");Clazz.overrideMethod(c$,"hasNext",function(){return this.hasNext2()});$_M(c$,"hasNext2",function(){if(0<=this.atomIndex)for(;this.cubeIterator.hasMoreElements();){var a=this.cubeIterator.nextElement();if((this.iNext=a.index)!=this.atomIndex&&(!this.checkGreater||this.iNext>this.atomIndex)&&
(null==this.bsSelected||this.bsSelected.get(this.iNext)))return!0}else if(this.cubeIterator.hasMoreElements())return a=this.cubeIterator.nextElement(),this.iNext=a.index,!0;this.iNext=-1;return!1});Clazz.overrideMethod(c$,"next",function(){return this.iNext-this.zeroBase});Clazz.overrideMethod(c$,"foundDistance2",function(){return null==this.cubeIterator?-1:this.cubeIterator.foundDistance2()});Clazz.overrideMethod(c$,"addAtoms",function(a){for(var b;this.hasNext();)if(0<=(b=this.next())){var c;if(this.isVdw){c=
this.atoms[b].getVanderwaalsRadiusFloat(this.viewer,this.radiusData.vdwType)+this.vdw1;switch(this.radiusData.factorType){case J.atomdata.RadiusData.EnumType.OFFSET:c+=2*this.radiusData.value;break;case J.atomdata.RadiusData.EnumType.FACTOR:c*=this.radiusData.value}c*=c}else c=this.distanceSquared;this.foundDistance2()<=c&&a.set(b)}},"JU.BS");Clazz.overrideMethod(c$,"release",function(){null!=this.cubeIterator&&(this.cubeIterator.release(),this.cubeIterator=null)})}),Clazz.declarePackage("J.modelset"),
Clazz.load(["J.modelset.AtomIteratorWithinModel"],"J.modelset.AtomIteratorWithinModelSet",null,function(){c$=Clazz.decorateAsClass(function(){this.center=this.bsModels=null;this.distance=0;Clazz.instantialize(this,arguments)},J.modelset,"AtomIteratorWithinModelSet",J.modelset.AtomIteratorWithinModel);Clazz.makeConstructor(c$,function(a){Clazz.superConstructor(this,J.modelset.AtomIteratorWithinModelSet,[]);this.bsModels=a},"JU.BS");Clazz.overrideMethod(c$,"setCenter",function(a,b){this.center=a;this.distance=
b;this.set(0)},"JU.P3,~N");$_M(c$,"set",($fz=function(a){if(0>(this.modelIndex=this.bsModels.nextSetBit(a))||null==(this.cubeIterator=this.bspf.getCubeIterator(this.modelIndex)))return!1;this.setCenter2(this.center,this.distance);return!0},$fz.isPrivate=!0,$fz),"~N");Clazz.overrideMethod(c$,"hasNext",function(){return this.hasNext2()?!0:!this.set(this.modelIndex+1)?!1:this.hasNext()})}),Clazz.declarePackage("J.bspt"),Clazz.load(null,"J.bspt.Bspt",["JU.SB","J.bspt.CubeIterator","$.Leaf","J.util.Logger"],
function(){c$=Clazz.decorateAsClass(function(){this.index=this.dimMax=this.treeDepth=0;this.eleRoot=null;Clazz.instantialize(this,arguments)},J.bspt,"Bspt");Clazz.makeConstructor(c$,function(a,b){this.dimMax=a;this.index=b;this.reset()},"~N,~N");$_M(c$,"reset",function(){this.eleRoot=new J.bspt.Leaf(this,null,0);this.treeDepth=1});$_M(c$,"addTuple",function(a){this.eleRoot=this.eleRoot.addTuple(0,a)},"JU.P3");$_M(c$,"stats",function(){});$_M(c$,"dump",function(){var a=new JU.SB;this.eleRoot.dump(0,
a);J.util.Logger.info(a.toString())});$_M(c$,"allocateCubeIterator",function(){return new J.bspt.CubeIterator(this)});Clazz.defineStatics(c$,"leafCountMax",2,"MAX_TREE_DEPTH",100)}),Clazz.declarePackage("J.util"),Clazz.load(["J.util.Elements"],"J.util.JmolMolecule",["JU.ArrayUtil","$.BS","J.util.BSUtil"],function(){c$=Clazz.decorateAsClass(function(){this.nodes=null;this.nElements=this.atomCount=this.firstAtomIndex=this.indexInModel=this.modelIndex=this.moleculeIndex=0;this.altElementCounts=this.elementCounts=
null;this.altElementMax=this.elementNumberMax=0;this.atomList=this.mf=null;Clazz.instantialize(this,arguments)},J.util,"JmolMolecule");Clazz.prepareFields(c$,function(){this.elementCounts=Clazz.newIntArray(J.util.Elements.elementNumberMax,0);this.altElementCounts=Clazz.newIntArray(J.util.Elements.altElementMax,0)});Clazz.makeConstructor(c$,function(){});c$.getMolecules=$_M(c$,"getMolecules",function(a,b,c,d){var e=null,f=new JU.BS,g=-1,h=0,k=0,l=Array(4);null==d&&(d=new JU.BS);for(var m=0;m<a.length;m++)if(!d.get(m)&&
!f.get(m))if(a[m].isDeleted())d.set(m);else{var n=a[m].getModelIndex();n!=g&&(g=n,h=0,e=b[n]);f=J.util.JmolMolecule.getBranchBitSet(a,m,e,c,-1,!0,!0);0<=f.nextSetBit(0)&&(l=J.util.JmolMolecule.addMolecule(l,k++,a,m,f,n,h++,d))}return J.util.JmolMolecule.allocateArray(l,k)},"~A,~A,JU.List,JU.BS");c$.getBranchBitSet=$_M(c$,"getBranchBitSet",function(a,b,c,d,e,f,g){var h=J.util.BSUtil.newBitSet(a.length);if(0>b)return h;0<=e&&c.clear(e);return J.util.JmolMolecule.getCovalentlyConnectedBitSet(a,a[b],
c,f,g,d,h)?h:new JU.BS},"~A,~N,JU.BS,JU.List,~N,~B,~B");c$.addMolecule=$_M(c$,"addMolecule",function(a,b,c,d,e,f,g,h){h.or(e);b==a.length&&(a=J.util.JmolMolecule.allocateArray(a,2*b+1));a[b]=J.util.JmolMolecule.initialize(c,b,d,e,f,g);return a},"~A,~N,~A,~N,JU.BS,~N,~N,JU.BS");c$.getMolecularFormula=$_M(c$,"getMolecularFormula",function(a,b,c){var d=new J.util.JmolMolecule;d.nodes=a;d.atomList=b;return d.getMolecularFormula(c)},"~A,JU.BS,~B");$_M(c$,"getMolecularFormula",function(a){if(null!=this.mf)return this.mf;
this.getElementAndAtomCount(a);for(var b=a="",c,d=1;d<=this.elementNumberMax;d++)c=this.elementCounts[d],0!=c&&(a+=b+J.util.Elements.elementSymbolFromNumber(d)+" "+c,b=" ");for(d=1;d<=this.altElementMax;d++)c=this.altElementCounts[d],0!=c&&(a+=b+J.util.Elements.elementSymbolFromNumber(J.util.Elements.altElementNumberFromIndex(d))+" "+c,b=" ");return a},"~B");c$.initialize=$_M(c$,"initialize",($fz=function(a,b,c,d,e,f){var g=new J.util.JmolMolecule;g.nodes=a;g.firstAtomIndex=c;g.atomList=d;g.atomCount=
d.cardinality();g.moleculeIndex=b;g.modelIndex=e;g.indexInModel=f;return g},$fz.isPrivate=!0,$fz),"~A,~N,~N,JU.BS,~N,~N");$_M(c$,"getElementAndAtomCount",($fz=function(a){null==this.atomList&&(this.atomList=new JU.BS,this.atomList.setBits(0,this.nodes.length));this.elementCounts=Clazz.newIntArray(J.util.Elements.elementNumberMax,0);this.altElementCounts=Clazz.newIntArray(J.util.Elements.altElementMax,0);this.atomCount=this.atomList.cardinality();for(var b=this.atomList.nextSetBit(0);0<=b;b=this.atomList.nextSetBit(b+
1)){var c=this.nodes[b].getAtomicAndIsotopeNumber();c<J.util.Elements.elementNumberMax?(this.elementCounts[c]++,1==this.elementCounts[c]&&this.nElements++,this.elementNumberMax=Math.max(this.elementNumberMax,c),a&&(c=this.nodes[b].getImplicitHydrogenCount(),0<c&&(0==this.elementCounts[1]&&this.nElements++,this.elementCounts[1]+=c))):(c=J.util.Elements.altElementIndexFromNumber(c),this.altElementCounts[c]++,1==this.altElementCounts[c]&&this.nElements++,this.altElementMax=Math.max(this.altElementMax,
c))}},$fz.isPrivate=!0,$fz),"~B");c$.getCovalentlyConnectedBitSet=$_M(c$,"getCovalentlyConnectedBitSet",($fz=function(a,b,c,d,e,f,g){var h=b.getIndex();if(!c.get(h)||!e&&0<b.getBioStructureTypeName().length)return d;c.clear(h);if(null!=f&&!g.get(h))for(var k=f.size();0<=--k;){var l=f.get(k);if(l.get(h)){g.or(l);c.andNot(l);for(k=l.nextSetBit(0);0<=k;k=l.nextSetBit(k+1)){var m=a[k];c.set(k);J.util.JmolMolecule.getCovalentlyConnectedBitSet(a,m,c,d,e,f,g);c.clear(k)}break}}g.set(h);h=b.getEdges();if(null==
h)return!0;for(k=h.length;0<=--k;)if(l=h[k],l.isCovalent()&&!J.util.JmolMolecule.getCovalentlyConnectedBitSet(a,l.getOtherAtomNode(b),c,d,e,f,g))return!1;return!0},$fz.isPrivate=!0,$fz),"~A,J.util.JmolNode,JU.BS,~B,~B,JU.List,JU.BS");c$.allocateArray=$_M(c$,"allocateArray",($fz=function(a,b){return b==a.length?a:JU.ArrayUtil.arrayCopyObject(a,b)},$fz.isPrivate=!0,$fz),"~A,~N")}),Clazz.declarePackage("J.modelset"),c$=Clazz.decorateAsClass(function(){this.id="";this.type=" ";this.scale=this.tickLabelFormats=
this.ticks=null;this.first=0;this.signFactor=1;this.reference=null;Clazz.instantialize(this,arguments)},J.modelset,"TickInfo"),Clazz.makeConstructor(c$,function(a){this.ticks=a},"JU.P3"),Clazz.declarePackage("J.script"),Clazz.load(["java.lang.Exception"],"J.script.ScriptException",null,function(){c$=Clazz.decorateAsClass(function(){this.untranslated=this.message=this.eval=null;Clazz.instantialize(this,arguments)},J.script,"ScriptException",Exception);Clazz.makeConstructor(c$,function(a,b,c,d){Clazz.superConstructor(this,
J.script.ScriptException,[]);this.eval=a;this.message=b;d&&this.eval.setException(this,b,c)},"J.api.JmolScriptEvaluator,~S,~S,~B");$_M(c$,"getErrorMessageUntranslated",function(){return this.untranslated});Clazz.overrideMethod(c$,"toString",function(){return this.message})}),Clazz.declarePackage("J.bspt"),c$=Clazz.decorateAsClass(function(){this.stack=this.bspt=null;this.leafIndex=this.sp=0;this.leaf=null;this.dz=this.dy=this.dx=this.cz=this.cy=this.cx=this.radius=0;this.tHemisphere=!1;Clazz.instantialize(this,
arguments)},J.bspt,"CubeIterator"),Clazz.makeConstructor(c$,function(a){this.set(a)},"J.bspt.Bspt"),$_M(c$,"set",function(a){this.bspt=a;this.stack=Array(a.treeDepth)},"J.bspt.Bspt"),$_M(c$,"initialize",function(a,b,c){this.radius=b;this.tHemisphere=!1;this.cx=a.x;this.cy=a.y;this.cz=a.z;this.leaf=null;this.stack[0]=this.bspt.eleRoot;this.sp=1;this.findLeftLeaf();this.tHemisphere=c},"JU.P3,~N,~B"),$_M(c$,"release",function(){this.set(this.bspt)}),$_M(c$,"hasMoreElements",function(){for(;null!=this.leaf;){for(;this.leafIndex<
this.leaf.count;++this.leafIndex)if(this.isWithinRadius(this.leaf.tuples[this.leafIndex]))return!0;this.findLeftLeaf()}return!1}),$_M(c$,"nextElement",function(){return this.leaf.tuples[this.leafIndex++]}),$_M(c$,"foundDistance2",function(){return this.dx*this.dx+this.dy*this.dy+this.dz*this.dz}),$_M(c$,"findLeftLeaf",($fz=function(){this.leaf=null;if(0!=this.sp){for(var a=this.stack[--this.sp];Clazz.instanceOf(a,J.bspt.Node);){var b;switch(a.dim){case 0:b=this.cx;break;case 1:b=this.cy;break;default:b=
this.cz}var c=b+this.radius;if(!this.tHemisphere||0!=a.dim)b-=this.radius;if(b<=a.maxLeft&&c>=a.minLeft)c>=a.minRight&&b<=a.maxRight&&(this.stack[this.sp++]=a.eleRight),a=a.eleLeft;else if(c>=a.minRight&&b<=a.maxRight)a=a.eleRight;else{if(0==this.sp)return;a=this.stack[--this.sp]}}this.leaf=a;this.leafIndex=0}},$fz.isPrivate=!0,$fz)),$_M(c$,"isWithinRadius",($fz=function(a){this.dx=a.x-this.cx;return(!this.tHemisphere||0<=this.dx)&&(this.dx=Math.abs(this.dx))<=this.radius&&(this.dy=Math.abs(a.y-this.cy))<=
this.radius&&(this.dz=Math.abs(a.z-this.cz))<=this.radius},$fz.isPrivate=!0,$fz),"JU.P3"),Clazz.declarePackage("J.bspt"),c$=Clazz.decorateAsClass(function(){this.bspt=null;this.count=0;Clazz.instantialize(this,arguments)},J.bspt,"Element"),Clazz.declarePackage("J.bspt"),Clazz.load(["J.bspt.Element"],"J.bspt.Leaf",["J.bspt.Node","J.util.Escape"],function(){c$=Clazz.decorateAsClass(function(){this.tuples=null;Clazz.instantialize(this,arguments)},J.bspt,"Leaf",J.bspt.Element);Clazz.makeConstructor(c$,
function(a,b,c){Clazz.superConstructor(this,J.bspt.Leaf,[]);this.bspt=a;this.count=0;this.tuples=Array(2);if(null!=b){for(a=c;2>a;++a)this.tuples[this.count++]=b.tuples[a],b.tuples[a]=null;b.count=c}},"J.bspt.Bspt,J.bspt.Leaf,~N");$_M(c$,"sort",function(a){for(var b=this.count;0<--b;)for(var c=this.tuples[b],d=J.bspt.Node.getDimensionValue(c,a),e=b;0<=--e;){var f=this.tuples[e],g=J.bspt.Node.getDimensionValue(f,a);g>d&&(this.tuples[b]=f,this.tuples[e]=c,c=f,d=g)}},"~N");Clazz.overrideMethod(c$,"addTuple",
function(a,b){return 2>this.count?(this.tuples[this.count++]=b,this):(new J.bspt.Node(this.bspt,a,this)).addTuple(a,b)},"~N,JU.P3");Clazz.overrideMethod(c$,"dump",function(a,b){for(var c=0;c<this.count;++c){for(var d=this.tuples[c],e=0;e<a;++e)b.append(".");b.append(J.util.Escape.eP(d)).append("Leaf ").appendI(c).append(": ").append(d.getInfo())}},"~N,JU.SB");Clazz.overrideMethod(c$,"toString",function(){return"leaf:"+this.count+"\n"})}),Clazz.declarePackage("J.util"),Clazz.load(null,"J.util.ColorEncoder",
"java.lang.Boolean $.Float java.util.Hashtable JU.ArrayUtil $.List J.constant.EnumPalette J.util.C $.ColorUtil $.Escape $.Logger $.Txt J.viewer.JC".split(" "),function(){c$=Clazz.decorateAsClass(function(){this.argbsAmino=this.argbsShapely=this.argbsRwb=this.argbsRoygb=this.argbsCpk=this.paletteWB=this.paletteBW=null;this.ihalf=0;this.schemes=null;this.currentPalette=0;this.currentSegmentCount=1;this.isTranslucent=!1;this.hi=this.lo=0;this.isReversed=!1;this.thisScale=this.userScale=null;this.thisName=
"scheme";this.isColorIndex=!1;this.propertyColorEncoder=null;Clazz.instantialize(this,arguments)},J.util,"ColorEncoder");Clazz.prepareFields(c$,function(){this.userScale=[-8355712];this.thisScale=[-8355712]});Clazz.makeConstructor(c$,function(a){null==a?(this.schemes=new java.util.Hashtable,this.argbsCpk=J.constant.EnumPalette.argbsCpk,this.argbsRoygb=J.viewer.JC.argbsRoygbScale,this.argbsRwb=J.viewer.JC.argbsRwbScale,this.argbsShapely=J.viewer.JC.argbsShapely,this.argbsAmino=J.viewer.JC.argbsAmino,
this.ihalf=Clazz.doubleToInt(J.viewer.JC.argbsRoygbScale.length/3),this.propertyColorEncoder=this):(this.propertyColorEncoder=a,this.schemes=a.schemes)},"J.util.ColorEncoder");c$.getSchemeIndex=$_M(c$,"getSchemeIndex",($fz=function(a){for(var b=0;b<J.util.ColorEncoder.colorSchemes.length;b++)if(J.util.ColorEncoder.colorSchemes[b].equalsIgnoreCase(a))return 15<=b?b-15:12>b?b:-b;return-1},$fz.isPrivate=!0,$fz),"~S");c$.fixName=$_M(c$,"fixName",($fz=function(a){if(a.equalsIgnoreCase("byelement"))return"byelement_jmol";
var b=J.util.ColorEncoder.getSchemeIndex(a);return 0<=b?J.util.ColorEncoder.colorSchemes[b]:a.toLowerCase()},$fz.isPrivate=!0,$fz),"~S");$_M(c$,"makeColorScheme",($fz=function(a,b,c){a=J.util.ColorEncoder.fixName(a);if(null==b){this.schemes.remove(a);a=this.createColorScheme(a,!1,c);if(c)switch(a){case 10:this.paletteBW=this.getPaletteBW();break;case 11:this.paletteWB=this.getPaletteWB();break;case 0:case 1:this.argbsRoygb=J.viewer.JC.argbsRoygbScale;break;case 6:case 7:this.argbsRwb=J.viewer.JC.argbsRwbScale;
break;case 2:this.argbsCpk=J.constant.EnumPalette.argbsCpk;break;case 3:J.util.ColorEncoder.getRasmolScale();break;case 5:this.argbsAmino=J.viewer.JC.argbsAmino;break;case 4:this.argbsShapely=J.viewer.JC.argbsShapely}return 2147483647==a?0:a}this.schemes.put(a,b);this.setThisScheme(a,b);a=this.createColorScheme(a,!1,c);if(c)switch(a){case 10:this.paletteBW=this.thisScale;break;case 11:this.paletteWB=this.thisScale;break;case 0:case 1:this.argbsRoygb=this.thisScale;this.ihalf=Clazz.doubleToInt(this.argbsRoygb.length/
3);break;case 6:case 7:this.argbsRwb=this.thisScale;break;case 2:this.argbsCpk=this.thisScale;break;case 5:this.argbsAmino=this.thisScale;break;case 4:this.argbsShapely=this.thisScale}return-1},$fz.isPrivate=!0,$fz),"~S,~A,~B");$_M(c$,"createColorScheme",function(a,b,c){a=a.toLowerCase();if(a.equals("inherit"))return 14;var d=Math.max(a.indexOf("="),a.indexOf("["));if(0<=d){b=J.util.Txt.replaceAllCharacters(a.substring(0,d)," =","");0<b.length&&(c=!0);var e=0;a.length>d+1&&!a.contains("[")&&(a="["+
a.substring(d+1).trim()+"]",a=J.util.Txt.simpleReplace(a.$replace("\n"," "),"  "," "),a=J.util.Txt.simpleReplace(a,", ",",").$replace(" ",","),a=J.util.Txt.simpleReplace(a,",","]["));for(d=-1;0<=(d=a.indexOf("[",d+1));)e++;if(0==e)return this.makeColorScheme(b,null,c);for(var f=Clazz.newIntArray(e,0),e=0;0<=(d=a.indexOf("[",d+1));){var g=a.indexOf("]",d);0>g&&(g=a.length-1);var h=J.util.ColorUtil.getArgbFromString(a.substring(d,g+1));0==h&&(h=J.util.ColorUtil.getArgbFromString(a.substring(d+1,g).trim()));
if(0==h)return J.util.Logger.error("error in color value: "+a.substring(d,g+1)),0;f[e++]=h}return b.equals("user")?(this.setUserScale(f),-12):this.makeColorScheme(b,f,c)}a=J.util.ColorEncoder.fixName(a);c=J.util.ColorEncoder.getSchemeIndex(a);return this.schemes.containsKey(a)?(this.setThisScheme(a,this.schemes.get(a)),c):-1!=c?c:b?0:2147483647},"~S,~B,~B");$_M(c$,"setUserScale",function(a){this.propertyColorEncoder.userScale=a;this.makeColorScheme("user",a,!1)},"~A");$_M(c$,"getColorSchemeArray",
function(a){switch(a){case -1:return this.thisScale;case 0:return this.propertyColorEncoder.argbsRoygb;case 1:return JU.ArrayUtil.arrayCopyRangeRevI(this.propertyColorEncoder.argbsRoygb,0,-1);case 8:return JU.ArrayUtil.arrayCopyRangeI(this.propertyColorEncoder.argbsRoygb,0,this.propertyColorEncoder.ihalf);case 9:var b=JU.ArrayUtil.arrayCopyRangeI(this.propertyColorEncoder.argbsRoygb,this.propertyColorEncoder.argbsRoygb.length-2*this.propertyColorEncoder.ihalf,-1);a=Clazz.newIntArray(this.propertyColorEncoder.ihalf,
0);for(var c=a.length,d=b.length;0<=--c&&0<=--d;)a[c]=b[d--];return a;case 10:return this.getPaletteBW();case 11:return this.getPaletteWB();case 6:return this.propertyColorEncoder.argbsRwb;case 7:return JU.ArrayUtil.arrayCopyRangeRevI(this.propertyColorEncoder.argbsRwb,0,-1);case 2:return this.propertyColorEncoder.argbsCpk;case 3:return J.util.ColorEncoder.getRasmolScale();case 4:return this.propertyColorEncoder.argbsShapely;case 5:return this.propertyColorEncoder.argbsAmino;case -12:return this.propertyColorEncoder.userScale;
case -13:return JU.ArrayUtil.arrayCopyRangeRevI(this.propertyColorEncoder.userScale,0,-1);default:return null}},"~N");$_M(c$,"getColorIndexFromPalette",function(a,b,c,d,e){d=J.util.C.getColix(this.getArgbFromPalette(a,b,c,d));e&&(a=(c-a)/(c-b),1<a?a=1:0.125>a&&(a=0.125),d=J.util.C.getColixTranslucent3(d,!0,a));return d},"~N,~N,~N,~N,~B");$_M(c$,"getPaletteColorCount",function(a){switch(a){case -1:return this.thisScale.length;case 10:case 11:return this.getPaletteBW(),this.propertyColorEncoder.paletteBW.length;
case 0:case 1:return this.propertyColorEncoder.argbsRoygb.length;case 8:case 9:return this.propertyColorEncoder.ihalf;case 6:case 7:return this.propertyColorEncoder.argbsRwb.length;case -12:case -13:return this.propertyColorEncoder.userScale.length;case 2:return this.argbsCpk.length;case 3:return J.util.ColorEncoder.getRasmolScale().length;case 4:return this.propertyColorEncoder.argbsShapely.length;case 5:return this.propertyColorEncoder.argbsAmino.length;default:return 0}},"~N");$_M(c$,"getArgbFromPalette",
function(a,b,c,d){if(Float.isNaN(a))return-8355712;var e=this.getPaletteColorCount(d);switch(d){case -1:return this.isColorIndex&&(b=0,c=this.thisScale.length),this.thisScale[J.util.ColorEncoder.quantize(a,b,c,e)];case 10:return this.getPaletteBW()[J.util.ColorEncoder.quantize(a,b,c,e)];case 11:return this.getPaletteWB()[J.util.ColorEncoder.quantize(a,b,c,e)];case 0:return this.propertyColorEncoder.argbsRoygb[J.util.ColorEncoder.quantize(a,b,c,e)];case 1:return this.propertyColorEncoder.argbsRoygb[J.util.ColorEncoder.quantize(-a,
-c,-b,e)];case 8:return this.propertyColorEncoder.argbsRoygb[J.util.ColorEncoder.quantize(a,b,c,e)];case 9:return this.propertyColorEncoder.argbsRoygb[this.propertyColorEncoder.ihalf+2*J.util.ColorEncoder.quantize(a,b,c,e)];case 6:return this.propertyColorEncoder.argbsRwb[J.util.ColorEncoder.quantize(a,b,c,e)];case 7:return this.propertyColorEncoder.argbsRwb[J.util.ColorEncoder.quantize(-a,-c,-b,e)];case -12:return 0==this.propertyColorEncoder.userScale.length?-8355712:this.propertyColorEncoder.userScale[J.util.ColorEncoder.quantize(a,
b,c,e)];case -13:return 0==this.propertyColorEncoder.userScale.length?-8355712:this.propertyColorEncoder.userScale[J.util.ColorEncoder.quantize(-a,-c,-b,e)];case 2:return this.propertyColorEncoder.argbsCpk[J.util.ColorEncoder.colorIndex(a,e)];case 3:return J.util.ColorEncoder.getRasmolScale()[J.util.ColorEncoder.colorIndex(a,e)];case 4:return this.propertyColorEncoder.argbsShapely[J.util.ColorEncoder.colorIndex(a,e)];case 5:return this.propertyColorEncoder.argbsAmino[J.util.ColorEncoder.colorIndex(a,
e)];default:return-8355712}},"~N,~N,~N,~N");$_M(c$,"setThisScheme",($fz=function(a,b){this.thisName=a;this.thisScale=b;a.equals("user")&&(this.userScale=b);this.isColorIndex=0==a.indexOf("byelement")||0==a.indexOf("byresidue")},$fz.isPrivate=!0,$fz),"~S,~A");$_M(c$,"getArgb",function(a){return this.isReversed?this.getArgbFromPalette(-a,-this.hi,-this.lo,this.currentPalette):this.getArgbFromPalette(a,this.lo,this.hi,this.currentPalette)},"~N");$_M(c$,"getColorIndex",function(a){return this.isReversed?
this.getColorIndexFromPalette(-a,-this.hi,-this.lo,this.currentPalette,this.isTranslucent):this.getColorIndexFromPalette(a,this.lo,this.hi,this.currentPalette,this.isTranslucent)},"~N");$_M(c$,"getColorKey",function(){for(var a=new java.util.Hashtable,b=this.getPaletteColorCount(this.currentPalette),c=new JU.List,d=Clazz.newFloatArray(b+1,0),e=(this.hi-this.lo)/b,f=e*(this.isReversed?-0.5:0.5),g=0;g<b;g++)d[g]=this.isReversed?this.hi-g*e:this.lo+g*e,c.addLast(J.util.ColorUtil.colorPointFromInt2(this.getArgb(d[g]+
f)));d[b]=this.isReversed?this.lo:this.hi;a.put("values",d);a.put("colors",c);a.put("min",Float.$valueOf(this.lo));a.put("max",Float.$valueOf(this.hi));a.put("reversed",Boolean.$valueOf(this.isReversed));a.put("name",this.getCurrentColorSchemeName());return a});$_M(c$,"setColorScheme",function(a,b){this.isTranslucent=b;null!=a&&(this.currentPalette=this.createColorScheme(a,!0,!1))},"~S,~B");$_M(c$,"setRange",function(a,b,c){3.4028235E38==b&&(a=1,b=this.getPaletteColorCount(this.currentPalette)+1);
this.lo=Math.min(a,b);this.hi=Math.max(a,b);this.isReversed=c},"~N,~N,~B");$_M(c$,"getCurrentColorSchemeName",function(){return this.getColorSchemeName(this.currentPalette)});$_M(c$,"getColorSchemeName",function(a){var b=Math.abs(a);return-1==a?this.thisName:b<J.util.ColorEncoder.colorSchemes.length&&0<=b?J.util.ColorEncoder.colorSchemes[b]:null},"~N");c$.getColorSchemeList=$_M(c$,"getColorSchemeList",function(a){if(null==a)return"";for(var b="",c=0;c<a.length;c++)b+=(0==c?"":" ")+J.util.Escape.escapeColor(a[c]);
return b},"~A");c$.getRasmolScale=$_M(c$,"getRasmolScale",function(){if(null!=J.util.ColorEncoder.rasmolScale)return J.util.ColorEncoder.rasmolScale;$t$=J.util.ColorEncoder.rasmolScale=Clazz.newIntArray(J.constant.EnumPalette.argbsCpk.length,0);J.util.ColorEncoder.prototype.rasmolScale=J.util.ColorEncoder.rasmolScale;$t$;for(var a=J.constant.EnumPalette.argbsCpkRasmol[0]|4278190080,b=J.util.ColorEncoder.rasmolScale.length;0<=--b;)J.util.ColorEncoder.rasmolScale[b]=a;for(b=J.constant.EnumPalette.argbsCpkRasmol.length;0<=
--b;)a=J.constant.EnumPalette.argbsCpkRasmol[b],J.util.ColorEncoder.rasmolScale[a>>24]=a|4278190080;return J.util.ColorEncoder.rasmolScale});$_M(c$,"getPaletteWB",($fz=function(){if(null!=this.propertyColorEncoder.paletteWB)return this.propertyColorEncoder.paletteWB;for(var a=Clazz.newIntArray(J.viewer.JC.argbsRoygbScale.length,0),b=0;b<a.length;b++){var c=1/a.length*(a.length-b);a[b]=J.util.ColorUtil.colorTriadToInt(c,c,c)}return this.propertyColorEncoder.paletteWB=a},$fz.isPrivate=!0,$fz));c$.getPaletteAtoB=
$_M(c$,"getPaletteAtoB",function(a,b,c){2>c&&(c=J.viewer.JC.argbsRoygbScale.length);var d=Clazz.newIntArray(c,0),e=((a&16711680)>>16&255)/255,f=((a&65280)>>8&255)/255;a=(a&255)/255;var g=(((b&16711680)>>16&255)/255-e)/(c-1),h=(((b&65280)>>8&255)/255-f)/(c-1);b=((b&255)/255-a)/(c-1);for(var k=0;k<c;k++)d[k]=J.util.ColorUtil.colorTriadToInt(e+g*k,f+h*k,a+b*k);return d},"~N,~N,~N");$_M(c$,"getPaletteBW",($fz=function(){if(null!=this.propertyColorEncoder.paletteBW)return this.propertyColorEncoder.paletteBW;
for(var a=Clazz.newIntArray(J.viewer.JC.argbsRoygbScale.length,0),b=0;b<a.length;b++){var c=1/a.length*b;a[b]=J.util.ColorUtil.colorTriadToInt(c,c,c)}return this.propertyColorEncoder.paletteBW=a},$fz.isPrivate=!0,$fz));$_M(c$,"quantize",function(a,b){var c=this.getPaletteColorCount(this.currentPalette);a=(Clazz.floatToInt(a*c)+(b?0:1))/c;return 0>=a?this.lo:1<=a?this.hi:this.lo+(this.hi-this.lo)*a},"~N,~B");c$.quantize=$_M(c$,"quantize",function(a,b,c,d){c-=b;if(0>=c||Float.isNaN(a))return Clazz.doubleToInt(d/
2);a-=b;if(0>=a)return 0;a=Clazz.floatToInt(a/(c/d)+1E-4);a>=d&&(a=d-1);return a},"~N,~N,~N,~N");c$.colorIndex=$_M(c$,"colorIndex",($fz=function(a,b){return Clazz.doubleToInt(Math.floor((new Boolean(0>=a|a>=b)).valueOf()?0:a))},$fz.isPrivate=!0,$fz),"~N,~N");$_M(c$,"getColorScheme",function(){return(this.isTranslucent?"translucent ":"")+(0>this.currentPalette?J.util.ColorEncoder.getColorSchemeList(this.getColorSchemeArray(this.currentPalette)):this.getColorSchemeName(this.currentPalette))});c$.RGBtoHSL=
$_M(c$,"RGBtoHSL",function(a,b,c,d){a/=255;b/=255;c/=255;1<a&&(a=1);1<b&&(b=1);1<c&&(c=1);var e=Math.min(a,Math.min(b,c)),f=Math.max(a,Math.max(b,c)),g=0;f==e?g=0:f==a?g=(60*(b-c)/(f-e)+360)%360:f==b?g=60*(c-a)/(f-e)+120:f==c&&(g=60*(a-b)/(f-e)+240);a=(f+e)/2;d[0]=g/360;d[1]=f==e?0:0.5>=a?(f-e)/(f+e):(f-e)/(2-f-e);d[2]=a},"~N,~N,~N,~A");Clazz.defineStatics(c$,"GRAY",4286611584,"BYELEMENT_PREFIX","byelement","BYRESIDUE_PREFIX","byresidue");c$.BYELEMENT_JMOL=c$.prototype.BYELEMENT_JMOL="byelement_jmol";
c$.BYELEMENT_RASMOL=c$.prototype.BYELEMENT_RASMOL="byelement_rasmol";c$.BYRESIDUE_SHAPELY=c$.prototype.BYRESIDUE_SHAPELY="byresidue_shapely";c$.BYRESIDUE_AMINO=c$.prototype.BYRESIDUE_AMINO="byresidue_amino";Clazz.defineStatics(c$,"CUSTOM",-1,"ROYGB",0,"BGYOR",1,"JMOL",2,"RASMOL",3,"SHAPELY",4,"AMINO",5,"RWB",6,"BWR",7,"LOW",8,"HIGH",9,"BW",10,"WB",11,"USER",-12,"RESU",-13,"INHERIT",14,"ALT",15);c$.colorSchemes=c$.prototype.colorSchemes="roygb bgyor byelement_jmol byelement_rasmol byresidue_shapely byresidue_amino rwb bwr low high bw wb user resu inherit rgb bgr jmol rasmol byresidue".split(" ");
Clazz.defineStatics(c$,"rasmolScale",null)}),Clazz.declarePackage("J.api"),Clazz.declareInterface(J.api,"JmolGraphicsInterface"),Clazz.declarePackage("J.util"),Clazz.load(["J.api.JmolGraphicsInterface"],"J.util.GData",["JU.ArrayUtil","J.util.C","$.JmolFont","$.Shader"],function(){c$=Clazz.decorateAsClass(function(){this.apiPlatform=null;this.translucentCoverOnly=!1;this.displayMaxY=this.displayMinY=this.displayMaxX=this.displayMinX=this.windowHeight=this.windowWidth=0;this.inGreyscaleMode=this.antialiasEnabled=
this.antialiasThisFrame=!1;this.backgroundImage=this.changeableColixMap=null;this.newWindowHeight=this.newWindowWidth=0;this.newAntialiasing=!1;this.zDepth=this.zSlab=this.height=this.width=this.depth=this.slab=this.yLast=this.xLast=this.bgcolor=0;this.zShadePower=3;this.bufferSize=this.argbCurrent=this.colixCurrent=0;this.shader=null;this.zShadeB=this.zShadeG=this.zShadeR=0;this.graphicsForMetrics=null;this.$isPass2=!1;Clazz.instantialize(this,arguments)},J.util,"GData",null,J.api.JmolGraphicsInterface);
Clazz.prepareFields(c$,function(){this.changeableColixMap=Clazz.newShortArray(16,0)});$_M(c$,"setTranslucentCoverOnly",function(a){this.translucentCoverOnly=a},"~B");$_M(c$,"getTranslucentCoverOnly",function(){return this.translucentCoverOnly});Clazz.makeConstructor(c$,function(){this.shader=new J.util.Shader});$_M(c$,"initialize",function(a){this.apiPlatform=a},"J.api.ApiPlatform");Clazz.overrideMethod(c$,"setDepth",function(a){this.depth=0>a?0:a},"~N");Clazz.overrideMethod(c$,"setSlab",function(a){this.slab=
0>a?0:a},"~N");$_M(c$,"setZShade",function(a,b,c,d){a&&this.setZShade2(b,c,d)},"~B,~N,~N,~N");$_M(c$,"setZShade2",function(a,b,c){this.zShadeR=this.bgcolor&255;this.zShadeG=(this.bgcolor&65280)>>8;this.zShadeB=(this.bgcolor&16711680)>>16;this.zSlab=0>a?0:a;this.zDepth=0>b?0:b;this.zShadePower=c},"~N,~N,~N");Clazz.overrideMethod(c$,"getRenderWidth",function(){return this.width});Clazz.overrideMethod(c$,"getRenderHeight",function(){return this.height});Clazz.overrideMethod(c$,"getSlab",function(){return this.slab});
Clazz.overrideMethod(c$,"getDepth",function(){return this.depth});$_M(c$,"isDisplayAntialiased",function(){return this.antialiasEnabled});Clazz.overrideMethod(c$,"isAntialiased",function(){return this.antialiasThisFrame});$_M(c$,"getChangeableColix",function(a,b){a>=this.changeableColixMap.length&&(this.changeableColixMap=JU.ArrayUtil.arrayCopyShort(this.changeableColixMap,a+16));0==this.changeableColixMap[a]&&(this.changeableColixMap[a]=J.util.C.getColix(b));return a|-32768},"~N,~N");$_M(c$,"changeColixArgb",
function(a,b){a<this.changeableColixMap.length&&0!=this.changeableColixMap[a]&&(this.changeableColixMap[a]=J.util.C.getColix(b))},"~N,~N");$_M(c$,"getBgColixes",function(a){return a},"~A");Clazz.overrideMethod(c$,"getColorArgbOrGray",function(a){0>a&&(a=this.changeableColixMap[a&2047]);return this.inGreyscaleMode?J.util.C.getArgbGreyscale(a):J.util.C.getArgb(a)},"~N");$_M(c$,"getShades",function(a){0>a&&(a=this.changeableColixMap[a&2047]);return this.inGreyscaleMode?this.shader.getShadesG(a):this.shader.getShades(a)},
"~N");$_M(c$,"setGreyscaleMode",function(a){this.inGreyscaleMode=a},"~B");$_M(c$,"getSpecularPower",function(){return this.shader.specularPower});$_M(c$,"setSpecularPower",function(a){0>a?this.setSpecularExponent(-a):this.shader.specularPower!=a&&(this.shader.specularPower=a,this.shader.intenseFraction=a/100,this.shader.flushCaches())},"~N");$_M(c$,"getSpecularPercent",function(){return this.shader.specularPercent});$_M(c$,"setSpecularPercent",function(a){this.shader.specularPercent!=a&&(this.shader.specularPercent=
a,this.shader.specularFactor=a/100,this.shader.flushCaches())},"~N");$_M(c$,"getSpecularExponent",function(){return this.shader.specularExponent});$_M(c$,"setSpecularExponent",function(a){this.shader.specularExponent!=a&&(this.shader.specularExponent=a,this.shader.phongExponent=Clazz.doubleToInt(Math.pow(2,a)),this.shader.usePhongExponent=!1,this.shader.flushCaches())},"~N");$_M(c$,"getPhongExponent",function(){return this.shader.phongExponent});$_M(c$,"setPhongExponent",function(a){this.shader.phongExponent==
a&&this.shader.usePhongExponent||(this.shader.phongExponent=a,a=Math.log(a)/Math.log(2),this.shader.usePhongExponent=a!=Clazz.floatToInt(a),this.shader.usePhongExponent||(this.shader.specularExponent=Clazz.floatToInt(a)),this.shader.flushCaches())},"~N");$_M(c$,"getDiffusePercent",function(){return this.shader.diffusePercent});$_M(c$,"setDiffusePercent",function(a){this.shader.diffusePercent!=a&&(this.shader.diffusePercent=a,this.shader.diffuseFactor=a/100,this.shader.flushCaches())},"~N");$_M(c$,
"getAmbientPercent",function(){return this.shader.ambientPercent});$_M(c$,"setAmbientPercent",function(a){this.shader.ambientPercent!=a&&(this.shader.ambientPercent=a,this.shader.ambientFraction=a/100,this.shader.flushCaches())},"~N");$_M(c$,"getSpecular",function(){return this.shader.specularOn});$_M(c$,"setSpecular",function(a){this.shader.specularOn!=a&&(this.shader.specularOn=a,this.shader.flushCaches())},"~B");$_M(c$,"setCel",function(a){this.shader.setCel(a,this.bgcolor)},"~B");$_M(c$,"getCel",
function(){return this.shader.getCelOn()});$_M(c$,"getLightSource",function(){return this.shader.lightSource});$_M(c$,"isClipped3",function(a,b,c){return 0>a||a>=this.width||0>b||b>=this.height||c<this.slab||c>this.depth},"~N,~N,~N");$_M(c$,"isClipped",function(a,b){return 0>a||a>=this.width||0>b||b>=this.height},"~N,~N");Clazz.overrideMethod(c$,"isInDisplayRange",function(a,b){return a>=this.displayMinX&&a<this.displayMaxX&&b>=this.displayMinY&&b<this.displayMaxY},"~N,~N");Clazz.overrideMethod(c$,
"isClippedXY",function(a,b,c){a=a+1>>1;return b<-a||b>=this.width+a||c<-a||c>=this.height+a},"~N,~N,~N");Clazz.overrideMethod(c$,"isClippedZ",function(a){return-2147483648!=a&&(a<this.slab||a>this.depth)},"~N");$_M(c$,"clipCode3",function(a,b,c){var d=0;0>a?d|=8:a>=this.width&&(d|=4);0>b?d|=2:b>=this.height&&(d|=1);c<this.slab?d|=32:c>this.depth&&(d|=16);return d},"~N,~N,~N");$_M(c$,"clipCode",function(a){var b=0;a<this.slab?b|=32:a>this.depth&&(b|=16);return b},"~N");$_M(c$,"getFont3D",function(a){return J.util.JmolFont.createFont3D(0,
0,a,a,this.apiPlatform,this.graphicsForMetrics)},"~N");$_M(c$,"getFont3DFS",function(a,b){return J.util.JmolFont.createFont3D(J.util.JmolFont.getFontFaceID(a),0,b,b,this.apiPlatform,this.graphicsForMetrics)},"~S,~N");$_M(c$,"getFontFidFS",function(a,b){return this.getFont3DFSS(a,"Bold",b).fid},"~S,~N");$_M(c$,"getFont3DFSS",function(a,b,c){b=J.util.JmolFont.getFontStyleID(b);0>b&&(b=0);return J.util.JmolFont.createFont3D(J.util.JmolFont.getFontFaceID(a),b,c,c,this.apiPlatform,this.graphicsForMetrics)},
"~S,~S,~N");Clazz.overrideMethod(c$,"getFont3DScaled",function(a,b){var c=a.fontSizeNominal*b;return c==a.fontSize?a:J.util.JmolFont.createFont3D(a.idFontFace,a.idFontStyle,c,a.fontSizeNominal,this.apiPlatform,this.graphicsForMetrics)},"J.util.JmolFont,~N");Clazz.overrideMethod(c$,"getFontFid",function(a){return this.getFont3D(a).fid},"~N");c$.getFontStyleID=$_M(c$,"getFontStyleID",function(a){return J.util.JmolFont.getFontStyleID(a)},"~S");$_M(c$,"setBackgroundTransparent",function(){},"~B");$_M(c$,
"setBackgroundArgb",function(a){this.bgcolor=a;this.setCel(this.getCel())},"~N");$_M(c$,"setBackgroundImage",function(a){this.backgroundImage=a},"~O");$_M(c$,"setWindowParameters",function(a,b,c){this.setWinParams(a,b,c)},"~N,~N,~B");$_M(c$,"setWinParams",function(a,b,c){this.newWindowWidth=a;this.newWindowHeight=b;this.newAntialiasing=c},"~N,~N,~B");$_M(c$,"setNewWindowParametersForExport",function(){this.windowWidth=this.newWindowWidth;this.windowHeight=this.newWindowHeight;this.setWidthHeight(!1)});
$_M(c$,"setWidthHeight",function(a){this.width=this.windowWidth;this.height=this.windowHeight;a&&(this.width<<=1,this.height<<=1);this.xLast=this.width-1;this.yLast=this.height-1;this.displayMinX=-(this.width>>1);this.displayMaxX=this.width-this.displayMinX;this.displayMinY=-(this.height>>1);this.displayMaxY=this.height-this.displayMinY;this.bufferSize=this.width*this.height},"~B");$_M(c$,"beginRendering",function(){},"JU.M3,~B,~B,~B");$_M(c$,"endRendering",function(){});$_M(c$,"snapshotAnaglyphChannelBytes",
function(){});$_M(c$,"getScreenImage",function(){return null},"~B");$_M(c$,"releaseScreenImage",function(){});$_M(c$,"applyAnaglygh",function(){},"J.constant.EnumStereoMode,~A");$_M(c$,"setPass2",function(){return!1},"~B");$_M(c$,"destroy",function(){});$_M(c$,"clearFontCache",function(){});$_M(c$,"plotImage",function(){},"~N,~N,~N,java.awt.Image,J.api.JmolRendererInterface,~N,~N,~N");$_M(c$,"plotText",function(){},"~N,~N,~N,~N,~N,~S,J.util.JmolFont,J.api.JmolRendererInterface");$_M(c$,"renderBackground",
function(){},"J.api.JmolRendererInterface");$_M(c$,"getFont3DCurrent",function(){return null});$_M(c$,"setFont",function(){},"J.util.JmolFont");$_M(c$,"setFontFid",function(){},"~N");$_M(c$,"setColor",function(a){this.argbCurrent=a},"~N");$_M(c$,"isPass2",function(){return this.$isPass2});$_M(c$,"setColix",function(){return!0},"~N");$_M(c$,"isDirectedTowardsCamera",function(){return!0},"~N");$_M(c$,"getTransformedVertexVectors",function(){return null});$_M(c$,"setNoisySurfaceShade",function(){},"JU.P3i,JU.P3i,JU.P3i");
c$.roundInt=$_M(c$,"roundInt",function(a){return a},"~N");$_M(c$,"clear",function(){});Clazz.overrideMethod(c$,"renderAllStrings",function(){},"~O");c$.getScreenOctant=$_M(c$,"getScreenOctant",function(a){var b=0;0>a.x&&(b|=1);0>a.y&&(b|=2);0>a.z&&(b|=4);return b},"JU.P3");$_M(c$,"addRenderer",function(){},"~N");Clazz.defineStatics(c$,"ENDCAPS_NONE",0,"ENDCAPS_OPEN",1,"ENDCAPS_FLAT",2,"ENDCAPS_SPHERICAL",3,"ENDCAPS_OPENEND",4,"EXPORT_RAYTRACER",2,"EXPORT_CARTESIAN",1,"EXPORT_NOT",0,"yGT",1,"yLT",
2,"xGT",4,"xLT",8,"zGT",16,"zLT",32)}),Clazz.declarePackage("J.bspt"),Clazz.load(["J.bspt.Element"],"J.bspt.Node",["java.lang.NullPointerException","J.bspt.Leaf"],function(){c$=Clazz.decorateAsClass(function(){this.maxLeft=this.minLeft=this.dim=0;this.eleLeft=null;this.maxRight=this.minRight=0;this.eleRight=null;Clazz.instantialize(this,arguments)},J.bspt,"Node",J.bspt.Element);Clazz.makeConstructor(c$,function(a,b,c){Clazz.superConstructor(this,J.bspt.Node,[]);this.bspt=a;b==a.treeDepth&&(a.treeDepth=
b+1);if(2!=c.count)throw new NullPointerException;this.dim=b%a.dimMax;c.sort(this.dim);a=new J.bspt.Leaf(a,c,1);this.minLeft=J.bspt.Node.getDimensionValue(c.tuples[0],this.dim);this.maxLeft=J.bspt.Node.getDimensionValue(c.tuples[c.count-1],this.dim);this.minRight=J.bspt.Node.getDimensionValue(a.tuples[0],this.dim);this.maxRight=J.bspt.Node.getDimensionValue(a.tuples[a.count-1],this.dim);this.eleLeft=c;this.eleRight=a;this.count=2},"J.bspt.Bspt,~N,J.bspt.Leaf");$_M(c$,"addTuple",function(a,b){var c=
J.bspt.Node.getDimensionValue(b,this.dim);++this.count;c<this.maxLeft||(c>this.minRight?0:c==this.maxLeft?c==this.minRight?this.eleLeft.count<this.eleRight.count:1:c==this.minRight?0:this.eleLeft.count<this.eleRight.count)?(c<this.minLeft?this.minLeft=c:c>this.maxLeft&&(this.maxLeft=c),this.eleLeft=this.eleLeft.addTuple(a+1,b)):(c<this.minRight?this.minRight=c:c>this.maxRight&&(this.maxRight=c),this.eleRight=this.eleRight.addTuple(a+1,b));return this},"~N,JU.P3");$_M(c$,"dump",function(a,b){b.append("\nnode LEFT"+
a);this.eleLeft.dump(a+1,b);for(var c=0;c<a;++c)b.append("->");b.append(" RIGHT"+a);this.eleRight.dump(a+1,b)},"~N,JU.SB");$_M(c$,"toString",function(){return this.eleLeft.toString()+this.dim+":\n"+this.eleRight.toString()});c$.getDimensionValue=$_M(c$,"getDimensionValue",function(a,b){return 0==b?a.x:1==b?a.y:a.z},"JU.P3,~N")}),Clazz.declarePackage("J.util"),Clazz.load(null,"J.util.JmolFont",["JU.ArrayUtil"],function(){c$=Clazz.decorateAsClass(function(){this.fid=0;this.fontStyle=this.fontFace=null;
this.fontSize=this.idFontStyle=this.idFontFace=this.fontSizeNominal=0;this.apiPlatform=this.fontMetrics=this.font=null;this.descent=this.ascent=0;this.isItalic=this.isBold=!1;Clazz.instantialize(this,arguments)},J.util,"JmolFont");Clazz.makeConstructor(c$,($fz=function(a,b,c,d,e,f,g){this.apiPlatform=a;this.fid=b;this.fontFace=J.util.JmolFont.fontFaces[c];this.fontStyle=J.util.JmolFont.fontStyles[d];this.idFontFace=c;this.idFontStyle=d;this.fontSize=e;this.isBold=1==(d&1);this.isItalic=2==(d&2);this.fontSizeNominal=
f;this.font=a.newFont(J.util.JmolFont.fontFaces[c],this.isBold,this.isItalic,e);this.fontMetrics=a.getFontMetrics(this,g);this.descent=a.getFontDescent(this.fontMetrics);this.ascent=a.getFontAscent(this.fontMetrics)},$fz.isPrivate=!0,$fz),"J.api.ApiPlatform,~N,~N,~N,~N,~N,~O");c$.getFont3D=$_M(c$,"getFont3D",function(a){return J.util.JmolFont.font3ds[a&255]},"~N");c$.createFont3D=$_M(c$,"createFont3D",function(a,b,c,d,e,f){255<c&&(c=255);for(var g=Clazz.floatToInt(c)<<4,g=a&3|(b&3)<<2|g<<4,h=J.util.JmolFont.fontkeyCount;0<
--h;)if(g==J.util.JmolFont.fontkeys[h]&&J.util.JmolFont.font3ds[h].fontSizeNominal==d)return J.util.JmolFont.font3ds[h];h=($t$=J.util.JmolFont.fontkeyCount++,J.util.JmolFont.prototype.fontkeyCount=J.util.JmolFont.fontkeyCount,$t$);h==J.util.JmolFont.fontkeys.length&&($t$=J.util.JmolFont.fontkeys=JU.ArrayUtil.arrayCopyI(J.util.JmolFont.fontkeys,h+8),J.util.JmolFont.prototype.fontkeys=J.util.JmolFont.fontkeys,$t$);$t$=J.util.JmolFont.font3ds=JU.ArrayUtil.arrayCopyObject(J.util.JmolFont.font3ds,h+8);
J.util.JmolFont.prototype.font3ds=J.util.JmolFont.font3ds;$t$;a=new J.util.JmolFont(e,h,a,b,c,d,f);J.util.JmolFont.font3ds[h]=a;J.util.JmolFont.fontkeys[h]=g;return a},"~N,~N,~N,~N,J.api.ApiPlatform,~O");c$.getFontFaceID=$_M(c$,"getFontFaceID",function(a){return"Monospaced".equalsIgnoreCase(a)?2:"Serif".equalsIgnoreCase(a)?1:0},"~S");c$.getFontStyleID=$_M(c$,"getFontStyleID",function(a){for(var b=4;0<=--b;)if(J.util.JmolFont.fontStyles[b].equalsIgnoreCase(a))return b;return-1},"~S");$_M(c$,"getAscent",
function(){return this.ascent});$_M(c$,"getDescent",function(){return this.descent});$_M(c$,"getHeight",function(){return this.getAscent()+this.getDescent()});$_M(c$,"stringWidth",function(a){return this.apiPlatform.fontStringWidth(this,this.fontMetrics,a)},"~S");$_M(c$,"getInfo",function(){return this.fontSizeNominal+" "+this.fontFace+" "+this.fontStyle});Clazz.defineStatics(c$,"FONT_ALLOCATION_UNIT",8,"fontkeyCount",1,"fontkeys",Clazz.newIntArray(8,0));c$.font3ds=c$.prototype.font3ds=Array(8);Clazz.defineStatics(c$,
"FONT_FACE_SANS",0,"FONT_FACE_SERIF",1,"FONT_FACE_MONO",2,"fontFaces",["SansSerif","Serif","Monospaced",""],"FONT_STYLE_PLAIN",0,"FONT_STYLE_BOLD",1,"FONT_STYLE_ITALIC",2,"FONT_STYLE_BOLDITALIC",3,"fontStyles",["Plain","Bold","Italic","BoldItalic"])}),Clazz.declarePackage("J.util"),Clazz.load(null,"J.util.MeshSurface","java.lang.Float java.util.Hashtable JU.ArrayUtil $.BS $.List $.P3 $.SB J.util.BSUtil $.BoxInfo $.C $.Escape $.Geodesic $.Measure $.TempArray $.Txt".split(" "),function(){c$=Clazz.decorateAsClass(function(){this.meshType=
this.spanningVectors=null;this.vertexCount=0;this.vertexSource=this.vertexValues=this.vertices=null;this.polygonCount=0;this.polygonTranslucencies=this.polygonIndexes=null;this.haveQuads=this.isTriangleSet=!1;this.colixBack=this.colix=0;this.isColorSolid=!0;this.normalsTemp=this.normals=this.vertexColixes=this.polygonColixes=this.altVertices=this.offset=null;this.normixCount=this.normalCount=0;this.vertexSets=this.surfaceSet=this.mat4=this.bsPolygons=null;this.nSets=0;this.checkCount=2;this.vertexCount0=
this.polygonCount0=this.iC=this.iB=this.iA=this.lastColix=this.lastColor=0;this.bsTransPolygons=this.bsSlabGhost=this.bsSlabDisplay=null;this.slabColix=this.slabMeshType=0;this.slabOptions=this.bsDisplay=null;this.doCap=this.doGhost=this.doClear=!1;this.mergePolygonCount0=this.mergeVertexCount0=this.iE=this.iD=0;this.isMerged=!1;Clazz.instantialize(this,arguments)},J.util,"MeshSurface");Clazz.makeConstructor(c$,function(){});c$.newMesh=$_M(c$,"newMesh",function(a,b,c,d,e,f){var g=new J.util.MeshSurface;
g.polygonIndexes=d;a?g.altVertices=b:g.vertices=b;g.vertexCount=0==c?b.length:c;g.normals=e;g.normalCount=0==f&&null!=e?e.length:f;return g},"~B,~A,~N,~A,~A,~N");c$.newSlab=$_M(c$,"newSlab",function(a,b,c,d,e,f){var g=new J.util.MeshSurface;g.vertices=a;g.vertexValues=c;g.vertexCount=b;g.polygonIndexes=d;g.polygonCount=e;g.checkCount=f;return g},"~A,~N,~A,~A,~N,~N");$_M(c$,"getVertices",function(){return null==this.altVertices?this.vertices:this.altVertices});$_M(c$,"getFaces",function(){return this.polygonIndexes});
$_M(c$,"setColix",function(a){this.colix=a},"~N");$_M(c$,"setColixBack",function(a){this.colixBack=a},"~N");$_M(c$,"addV",function(a){0==this.vertexCount?this.vertices=Array(25):this.vertexCount==this.vertices.length&&(this.vertices=JU.ArrayUtil.doubleLength(this.vertices));this.vertices[this.vertexCount]=JU.P3.newP(a);return this.vertexCount++},"JU.P3");$_M(c$,"addTriangle",function(a,b,c){this.addPolygon([a,b,c],null)},"~N,~N,~N");$_M(c$,"addQuad",function(a,b,c,d){this.haveQuads=!0;this.addPolygon([a,
b,c,d],null)},"~N,~N,~N,~N");$_M(c$,"setPolygonCount",function(a){this.polygonCount=a;if(!(0>a)&&(null==this.polygonIndexes||a>this.polygonIndexes.length))this.polygonIndexes=JU.ArrayUtil.newInt2(a)},"~N");$_M(c$,"addVCVal",function(a,b){0==this.vertexCount?this.vertexValues=Clazz.newFloatArray(25,0):this.vertexCount>=this.vertexValues.length&&(this.vertexValues=JU.ArrayUtil.doubleLengthF(this.vertexValues));this.vertexValues[this.vertexCount]=b;return this.addV(a)},"JU.P3,~N");$_M(c$,"addTriangleCheck",
function(a,b,c,d,e,f){return null==this.vertices||null!=this.vertexValues&&(Float.isNaN(this.vertexValues[a])||Float.isNaN(this.vertexValues[b])||Float.isNaN(this.vertexValues[c]))||Float.isNaN(this.vertices[a].x)||Float.isNaN(this.vertices[b].x)||Float.isNaN(this.vertices[c].x)?-1:this.addPolygonV3(a,b,c,d,e,f,null)},"~N,~N,~N,~N,~N,~N");$_M(c$,"addPolygonV3",($fz=function(a,b,c,d,e,f,g){return 2==this.checkCount?this.addPolygonC([a,b,c,d,e],f,g):this.addPolygon([a,b,c,d],g)},$fz.isPrivate=!0,$fz),
"~N,~N,~N,~N,~N,~N,JU.BS");$_M(c$,"addPolygonC",function(a,b,c){if(0!=b){if(null==this.polygonColixes||0==this.polygonCount)this.lastColor=0;b=b==this.lastColor?this.lastColix:this.lastColix=J.util.C.getColix(this.lastColor=b);this.setPolygonColix(this.polygonCount,b)}return this.addPolygon(a,c)},"~A,~N,JU.BS");$_M(c$,"addPolygon",($fz=function(a,b){var c=this.polygonCount;0==this.polygonCount?this.polygonIndexes=JU.ArrayUtil.newInt2(25):this.polygonCount==this.polygonIndexes.length&&(this.polygonIndexes=
JU.ArrayUtil.doubleLength(this.polygonIndexes));null!=b&&b.set(this.polygonCount);this.polygonIndexes[this.polygonCount++]=a;return c},$fz.isPrivate=!0,$fz),"~A,JU.BS");$_M(c$,"setPolygonColix",($fz=function(a,b){null==this.polygonColixes?this.polygonColixes=Clazz.newShortArray(25,0):a>=this.polygonColixes.length&&(this.polygonColixes=JU.ArrayUtil.doubleLengthShort(this.polygonColixes));this.polygonColixes[a]=b},$fz.isPrivate=!0,$fz),"~N,~N");$_M(c$,"invalidatePolygons",function(){for(var a=this.polygonCount;--a>=
this.mergePolygonCount0;)if((null==this.bsSlabDisplay||this.bsSlabDisplay.get(a))&&!this.setABC(a))this.polygonIndexes[a]=null});$_M(c$,"setABC",function(a){if(null!=this.bsSlabDisplay&&!this.bsSlabDisplay.get(a)&&(null==this.bsSlabGhost||!this.bsSlabGhost.get(a)))return!1;a=this.polygonIndexes[a];if(null==a||3>a.length)return!1;this.iA=a[0];this.iB=a[1];this.iC=a[2];return null==this.vertexValues||!(Float.isNaN(this.vertexValues[this.iA])||Float.isNaN(this.vertexValues[this.iB])||Float.isNaN(this.vertexValues[this.iC]))},
"~N");$_M(c$,"setTranslucentVertices",function(){},"JU.BS");$_M(c$,"setSlab",function(a,b,c,d,e){this.bsSlabDisplay=a;this.bsSlabGhost=b;this.slabMeshType=c.equalsIgnoreCase("mesh")?1073742018:1073741938;this.slabColix=J.util.C.getColixTranslucent3(J.util.C.getColixS(d),!0,e)},"JU.BS,JU.BS,~S,~S,~N");$_M(c$,"getSlabColor",function(){return null==this.bsSlabGhost?null:J.util.C.getHexCode(this.slabColix)});$_M(c$,"getSlabTranslucency",function(){return null==this.bsSlabGhost?null:""+J.util.C.getColixTranslucencyFractional(this.slabColix)});
$_M(c$,"getSlabType",function(){return null!=this.bsSlabGhost&&1073742018==this.slabMeshType?"mesh":null});$_M(c$,"resetTransPolygons",function(){for(var a=J.util.C.isColixTranslucent(this.colix),b=J.util.C.getColixTranslucencyFractional(this.colix),c=0;c<this.polygonCount;c++)this.bsTransPolygons.get(c)&&this.setABC(c)&&(this.vertexColixes[this.iA]=J.util.C.getColixTranslucent3(this.vertexColixes[this.iA],a,b),this.vertexColixes[this.iB]=J.util.C.getColixTranslucent3(this.vertexColixes[this.iB],
a,b),this.vertexColixes[this.iC]=J.util.C.getColixTranslucent3(this.vertexColixes[this.iC],a,b));this.polygonTranslucencies=this.bsTransPolygons=null});$_M(c$,"resetSlab",function(){this.slabPolygons(J.util.TempArray.getSlabObjectType(1048587,null,!1,null),!1)});c$.getCapSlabObject=$_M(c$,"getCapSlabObject",function(a,b){try{if(0==a.indexOf("array")){var c=J.util.Txt.split(a.substring(6,a.length-1),",");return J.util.TempArray.getSlabObjectType(1679429641,[J.util.Escape.uP(c[0]),J.util.Escape.uP(c[1]),
J.util.Escape.uP(c[2]),J.util.Escape.uP(c[3])],b,null)}var d=J.util.Escape.uP(a);if(Clazz.instanceOf(d,JU.P4))return J.util.TempArray.getSlabObjectType(135266319,d,b,null)}catch(e){if(!Clazz.exceptionOf(e,Exception))throw e;}return null},"~S,~B");$_M(c$,"slabPolygonsList",function(a,b){for(var c=0;c<a.size()&&this.slabPolygons(a.get(c),b);c++);},"JU.List,~B");$_M(c$,"slabPolygons",function(a,b){if(0>this.polygonCount0)return!1;var c=a[0].intValue();if(1048587==c||1073741872==c){if(null!=this.bsSlabDisplay&&
(0!=this.polygonCount0||0!=this.vertexCount0))this.polygonCount=this.polygonCount0,this.vertexCount=this.vertexCount0,this.polygonCount0=this.vertexCount0=0,this.normixCount=this.isTriangleSet?this.polygonCount:this.vertexCount,this.bsSlabDisplay.setBits(0,0==this.polygonCount?this.vertexCount:this.polygonCount),this.slabOptions=(new JU.SB).append(this.meshType+" slab none"),this.bsSlabGhost=null,this.slabMeshType=1048587;if(1048587==c)return!1}var d=a[1],e=a[2].booleanValue()&&1073741872!=c;if(e&&
!b)return!1;var f=a[3],g=null!=f;if(null==this.bsSlabDisplay||0==this.polygonCount0&&0==this.vertexCount0){if(this.polygonCount0=this.polygonCount,this.vertexCount0=this.vertexCount,this.bsSlabDisplay=J.util.BSUtil.setAll(0==this.polygonCount?this.vertexCount:this.polygonCount),this.bsSlabGhost=null,0==this.polygonCount&&0==this.vertexCount)return!1}else this.isMerged&&(0==this.polygonCount?this.bsSlabDisplay.setBits(this.mergeVertexCount0,this.vertexCount):this.bsSlabDisplay.setBits(this.mergePolygonCount0,
this.polygonCount));g&&(null==this.bsSlabGhost&&(this.bsSlabGhost=new JU.BS),this.slabMeshType=f[0].intValue(),this.slabColix=f[1].shortValue(),e=!1,this.colix=J.util.C.getColixTranslucent3(this.colix,!1,0));f=new JU.SB;f.append(e?" cap ":" slab ");if(g){f.append("translucent ").appendF(J.util.C.getColixTranslucencyFractional(this.slabColix)).append(" ");var h=J.util.C.getHexCode(this.slabColix);null!=h&&f.append(h).append(" ");1073742018==this.slabMeshType&&f.append("mesh ")}switch(c){case 1073741872:f.append("brillouin");
this.slabBrillouin(d);break;case 3:this.getIntersection(0,null,null,null,null,d,null,e,!1,3,g);break;case 135266319:f.append(J.util.Escape.eP4(d));this.getIntersection(0,d,null,null,null,null,null,e,!1,135266319,g);break;case 1614417948:case 1679429641:f.append("within ").append(J.util.Escape.eAP(d));d=J.util.BoxInfo.getFacesFromCriticalPoints(d);for(h=0;h<d.length;h++)this.getIntersection(0,d[h],null,null,null,null,null,e,!1,135266319,g);break;case 135270407:this.getIntersection(0,null,null,null,
d,null,null,!1,!1,32,g);break;case 135266324:case 1073742114:case 1073742018:switch(h=d[0].floatValue(),c){case 135266324:c=d[1];d=d[2];f.append("within ").appendF(h).append(null==d?J.util.Escape.e(c):J.util.Escape.e(d));this.getIntersection(h,null,c,null,null,null,null,e,!1,0<h?1276118018:1073742154,g);break;case 1073742114:if(null==this.vertexValues)return!1;c=d[1].floatValue();f.append("within range ").appendF(h).append(" ").appendF(c);d=c<h?J.util.BSUtil.copy(this.bsSlabDisplay):null;this.getIntersection(h,
null,null,null,null,null,null,e,!1,32,g);h=null==d?null:J.util.BSUtil.copy(this.bsSlabDisplay);J.util.BSUtil.copy2(d,this.bsSlabDisplay);this.getIntersection(c,null,null,null,null,null,null,e,!1,64,g);null!=h&&this.bsSlabDisplay.or(h);break;case 1073742018:this.getIntersection(0,null,null,null,null,null,d[1],e,!1,0>h?32:64,g)}}e=f.toString();null==this.slabOptions&&(this.slabOptions=new JU.SB);0>this.slabOptions.indexOf(e)&&this.slabOptions.append(0<this.slabOptions.length()?"; ":"").append(this.meshType).append(e);
return!0},"~A,~B");$_M(c$,"slabBrillouin",function(){},"~A");$_M(c$,"addIntersectionVertex",function(a,b,c,d,e,f,g){g=f>g?g+"_"+f:f+"_"+g;if(0<=f&&(f=e.get(g),null!=f))return f.intValue();null!=this.vertexSource&&(this.vertexCount>=this.vertexSource.length&&(this.vertexSource=JU.ArrayUtil.doubleLengthI(this.vertexSource)),this.vertexSource[this.vertexCount]=c);null!=this.vertexSets&&(this.vertexCount>=this.vertexSets.length&&(this.vertexSets=JU.ArrayUtil.doubleLengthI(this.vertexSets)),this.vertexSets[this.vertexCount]=
d);a=this.addVCVal(a,b);e.put(g,Integer.$valueOf(a));return a},"JU.P3,~N,~N,~N,java.util.Map,~N,~N");$_M(c$,"getIntersection",function(a,b,c,d,e,f,g,h,k,l,m){var n=null==d,q=null;if(null==e)if(3==l&&null!=f){e=Clazz.newFloatArray(this.vertexCount,0);for(g=0;g<this.vertexCount;g++)-1==(e[g]=this.vertexSource[g])&&System.out.println("meshsurface hmm")}else e=this.vertexValues;var p=new java.util.Hashtable;if(null!=c||m)h=!1;var r=Clazz.newFloatArray(2,0),s=Clazz.newFloatArray(2,0),t=Math.abs(a),u,v,
y,A,B,w,x=0,z=0,D=0,C=0,E=h?new JU.List:null;if(0==this.polygonCount)for(g=this.mergeVertexCount0;g<this.vertexCount;g++)(Float.isNaN(e[g])||0<J.util.MeshSurface.checkSlab(l,this.vertices[g],e[g],a,b,c,f))&&this.bsSlabDisplay.clear(g);else{var I=this.polygonCount;for(g=this.mergePolygonCount0;g<I;g++)if(this.setABC(g)){var G=null!=this.bsSlabGhost&&this.bsSlabGhost.get(g)?this.bsSlabGhost:this.bsSlabDisplay,H=this.polygonIndexes[g][3],F=2==this.checkCount?this.polygonIndexes[g][4]:0,K=this.vertices[this.iA],
L=this.vertices[this.iB],M=this.vertices[this.iC];A=e[this.iA];B=e[this.iB];w=e[this.iC];null!=this.vertexSource&&(x=this.vertexSource[this.iA],z=this.vertexSource[this.iB],D=this.vertexSource[this.iC]);null!=this.vertexSets&&(C=this.vertexSets[this.iA]);u=J.util.MeshSurface.checkSlab(l,K,A,null==f?a:x,b,c,f);v=J.util.MeshSurface.checkSlab(l,L,B,null==f?a:z,b,c,f);y=J.util.MeshSurface.checkSlab(l,M,w,null==f?a:D,b,c,f);var N=(0!=u&&0>u?1:0)+(0!=v&&0>v?2:0)+(0!=y&&0>y?4:0);switch(N){case 1:case 6:q=
null==c?[J.util.MeshSurface.interpolatePoint(K,L,-u,v,A,B,r,s,0),J.util.MeshSurface.interpolatePoint(K,M,-u,y,A,w,r,s,1)]:[this.interpolateSphere(K,L,-u,-v,t,A,B,r,s,0),this.interpolateSphere(K,M,-u,-y,t,A,w,r,s,1)];break;case 2:case 5:q=null==c?[J.util.MeshSurface.interpolatePoint(L,K,-v,u,B,A,r,s,1),J.util.MeshSurface.interpolatePoint(L,M,-v,y,B,w,r,s,0)]:[this.interpolateSphere(L,K,-v,-u,t,B,A,r,s,1),this.interpolateSphere(L,M,-v,-y,t,B,w,r,s,0)];break;case 3:case 4:q=null==c?[J.util.MeshSurface.interpolatePoint(M,
K,-y,u,w,A,r,s,0),J.util.MeshSurface.interpolatePoint(M,L,-y,v,w,B,r,s,1)]:[this.interpolateSphere(M,K,-y,-u,t,w,A,r,s,0),this.interpolateSphere(M,L,-y,-v,t,w,B,r,s,1)]}this.doClear=!0;this.doGhost=m;this.doCap=h;if(n){switch(N){case 0:this.doCap=!1;break;case 7:continue;case 1:case 6:if((v=1==N)||m){if(!this.getDE(s,0,this.iA,this.iB,this.iC,v))break;0>this.iD&&(this.iD=this.addIntersectionVertex(q[0],r[0],x,C,p,this.iA,this.iB));0>this.iE&&(this.iE=this.addIntersectionVertex(q[1],r[1],x,C,p,this.iA,
this.iC));u=v?G:this.bsSlabGhost;this.addPolygonV3(this.iA,this.iD,this.iE,H&5|2,F,0,u);if(!m)break}if(!this.getDE(s,1,this.iA,this.iC,this.iB,v))break;u=v?this.bsSlabGhost:G;0>this.iE&&(this.iE=this.addIntersectionVertex(q[0],r[0],z,C,p,this.iA,this.iB),this.addPolygonV3(this.iE,this.iB,this.iC,H&3,F,0,u));0>this.iD&&(this.iD=this.addIntersectionVertex(q[1],r[1],D,C,p,this.iA,this.iC),this.addPolygonV3(this.iD,this.iE,this.iC,H&4|1,F,0,u));break;case 5:case 2:if((v=2==N)||m){if(!this.getDE(s,0,this.iB,
this.iC,this.iA,v))break;u=v?G:this.bsSlabGhost;0>this.iE&&(this.iE=this.addIntersectionVertex(q[0],r[0],z,C,p,this.iB,this.iA));0>this.iD&&(this.iD=this.addIntersectionVertex(q[1],r[1],z,C,p,this.iB,this.iC));this.addPolygonV3(this.iE,this.iB,this.iD,H&3|4,F,0,u);if(!m)break}if(!this.getDE(s,1,this.iB,this.iA,this.iC,v))break;u=v?this.bsSlabGhost:G;0>this.iD&&(this.iD=this.addIntersectionVertex(q[0],r[0],x,C,p,this.iB,this.iA),this.addPolygonV3(this.iA,this.iD,this.iC,H&5,F,0,u));0>this.iE&&(this.iE=
this.addIntersectionVertex(q[1],r[1],D,C,p,this.iB,this.iC),this.addPolygonV3(this.iD,this.iE,this.iC,H&2|1,F,0,u));break;case 4:case 3:if((v=4==N)||m){if(!this.getDE(s,0,this.iC,this.iA,this.iB,v))break;0>this.iD&&(this.iD=this.addIntersectionVertex(q[0],r[0],D,C,p,this.iA,this.iC));0>this.iE&&(this.iE=this.addIntersectionVertex(q[1],r[1],D,C,p,this.iB,this.iC));u=v?G:this.bsSlabGhost;this.addPolygonV3(this.iD,this.iE,this.iC,H&6|1,F,0,u);if(!m)break}if(!this.getDE(s,1,this.iC,this.iB,this.iA,v))break;
u=v?this.bsSlabGhost:G;0>this.iE&&(this.iE=this.addIntersectionVertex(q[0],r[0],x,C,p,this.iA,this.iC),this.addPolygonV3(this.iA,this.iB,this.iE,H&5,F,0,u));0>this.iD&&(this.iD=this.addIntersectionVertex(q[1],r[1],z,C,p,this.iB,this.iC),this.addPolygonV3(this.iE,this.iB,this.iD,H&2|4,F,0,u))}this.doClear&&(G.clear(g),this.doGhost&&this.bsSlabGhost.set(g));this.doCap&&E.addLast([this.iD,this.iE])}else null!=q&&d.addLast(q)}if(h&&0<E.size()){b=new JU.P3;for(g=E.size();0<=--g;)a=E.get(g),b.add(this.vertices[a[0]]),
b.add(this.vertices[a[1]]);b.scale(0.5/E.size());p=this.addIntersectionVertex(b,0,-1,C,p,-1,-1);for(g=E.size();0<=--g;)a=E.get(g),this.addPolygonV3(a[0],p,a[1],0,0,0,this.bsSlabDisplay)}if(k){p=new JU.BS;C=new JU.BS;for(g=0;g<this.polygonCount;g++)if(null!=this.polygonIndexes[g]){C.set(g);for(k=0;3>k;k++)p.set(this.polygonIndexes[g][k])}E=0;C=C.cardinality();if(C!=this.polygonCount){a=Clazz.newIntArray(this.vertexCount,0);for(g=0;g<this.vertexCount;g++)p.get(g)&&(a[g]=E++);b=Array(E);for(g=E=0;g<
this.vertexCount;g++)p.get(g)&&(b[E++]=this.vertices[g]);p=JU.ArrayUtil.newInt2(C);for(g=C=0;g<this.polygonCount;g++)if(null!=this.polygonIndexes[g]){for(k=0;3>k;k++)this.polygonIndexes[g][k]=a[this.polygonIndexes[g][k]];p[C++]=this.polygonIndexes[g]}this.vertices=b;this.vertexCount=E;this.polygonIndexes=p;this.polygonCount=C}}}},"~N,JU.P4,~A,JU.List,~A,JU.BS,J.util.MeshSurface,~B,~B,~N,~B");c$.setPoint=$_M(c$,"setPoint",($fz=function(a,b,c,d){return 0==a[b]?c:1==a[b]?d:-1},$fz.isPrivate=!0,$fz),
"~A,~N,~N,~N");$_M(c$,"getDE",($fz=function(a,b,c,d,e,f){this.iD=J.util.MeshSurface.setPoint(a,b,c,d);this.iE=J.util.MeshSurface.setPoint(a,1-b,c,e);if(this.iD==c&&this.iE==c)return this.doClear=f,this.doCap=!1;if(this.iD==d&&this.iE==e)return this.doClear=!f,!1;if(this.iD==c||this.iE==c)return this.doClear=f,0>this.iD?this.iD=f?d:e:0>this.iE&&(this.iE=f?e:d),this.doCap;this.doGhost=!1;return!0},$fz.isPrivate=!0,$fz),"~A,~N,~N,~N,~N,~B");c$.checkSlab=$_M(c$,"checkSlab",($fz=function(a,b,c,d,e,f,g){switch(a){case 3:return 0<=
c&&g.get(Clazz.floatToInt(c))?1:-1;case 32:a=d-c;break;case 64:a=c-d;break;case 135266319:a=J.util.Measure.distanceToPlane(e,b);break;case 1276118018:a=J.util.MeshSurface.minDist(b,f)-d;break;default:a=-J.util.MeshSurface.minDist(b,f)-d}return 1E-4>Math.abs(a)?0:a},$fz.isPrivate=!0,$fz),"~N,JU.P3,~N,~N,JU.P4,~A,JU.BS");c$.minDist=$_M(c$,"minDist",($fz=function(a,b){for(var c=2147483647,d=b.length;0<=--d;){var e=b[d].distance(a);e<c&&(c=e)}return c},$fz.isPrivate=!0,$fz),"JU.P3,~A");$_M(c$,"interpolateSphere",
($fz=function(a,b,c,d,e,f,g,h,k,l){return J.util.MeshSurface.interpolateFraction(a,b,J.util.MeshSurface.getSphericalInterpolationFraction(e,c,d,a.distance(b)),f,g,h,k,l)},$fz.isPrivate=!0,$fz),"JU.P3,JU.P3,~N,~N,~N,~N,~N,~A,~A,~N");c$.interpolatePoint=$_M(c$,"interpolatePoint",($fz=function(a,b,c,d,e,f,g,h,k){return J.util.MeshSurface.interpolateFraction(a,b,c/(c+d),e,f,g,h,k)},$fz.isPrivate=!0,$fz),"JU.P3,JU.P3,~N,~N,~N,~N,~A,~A,~N");c$.interpolateFraction=$_M(c$,"interpolateFraction",($fz=function(a,
b,c,d,e,f,g,h){1E-4>c?c=0:0.9999<c&&(c=1);g[h]=c;f[h]=(e-d)*c+d;return JU.P3.new3(a.x+(b.x-a.x)*c,a.y+(b.y-a.y)*c,a.z+(b.z-a.z)*c)},$fz.isPrivate=!0,$fz),"JU.P3,JU.P3,~N,~N,~N,~A,~A,~N");c$.getSphericalInterpolationFraction=$_M(c$,"getSphericalInterpolationFraction",function(a,b,c,d){b=Math.abs(a+b)/d;c=Math.abs(a+c)/d;a/=d;d=b*b;var e=d-c*c+1;return(e+(b<c?1:-1)*Math.sqrt(e*e+4*(a*a-d)))/2},"~N,~N,~N,~N");c$.getSphereData=$_M(c$,"getSphereData",function(a){J.util.Geodesic.createGeodesic(a);var b=
J.util.Geodesic.getVertexCount(a),c=J.util.Geodesic.getFaceVertexes(a),d=Clazz.doubleToInt(c.length/3);a=JU.ArrayUtil.newInt2(d);for(var e=0,f=0;e<d;e++)a[e]=[c[f++],c[f++],c[f++]];c=Array(b);for(e=0;e<b;e++)c[e]=J.util.Geodesic.getVertexVector(e);return J.util.MeshSurface.newMesh(!0,c,0,a,c,0)},"~N");Clazz.defineStatics(c$,"SEED_COUNT",25)}),Clazz.declarePackage("J.util"),c$=Clazz.decorateAsClass(function(){this.height=this.width=this.y=this.x=0;Clazz.instantialize(this,arguments)},J.util,"Rectangle"),
$_M(c$,"contains",function(a,b){return a>=this.x&&b>=this.y&&a-this.x<this.width&&b-this.y<this.height},"~N,~N"),Clazz.declarePackage("J.viewer"),c$=Clazz.decorateAsClass(function(){this.y=this.x=-1E3;this.modifiers=0;this.time=-1;this.name=null;Clazz.instantialize(this,arguments)},J.viewer,"MouseState"),Clazz.makeConstructor(c$,function(a){this.name=a},"~S"),$_M(c$,"set",function(a,b,c,d){this.time=a;this.x=b;this.y=c;this.modifiers=d},"~N,~N,~N,~N"),$_M(c$,"setCurrent",function(a,b){this.time=a.time;
2>b&&(this.x=a.x,this.y=a.y);this.modifiers=a.modifiers},"J.viewer.MouseState,~N"),$_M(c$,"inRange",function(a,b,c){return Math.abs(this.x-b)<=a&&Math.abs(this.y-c)<=a},"~N,~N,~N"),$_M(c$,"check",function(a,b,c,d,e,f){return this.modifiers==d&&(2147483647<=f?this.inRange(a,b,c):e-this.time<f&&20<e-this.time)},"~N,~N,~N,~N,~N,~N"),$_M(c$,"is",function(a){return a.x==this.x&&a.y==this.y&&a.time==this.time},"J.viewer.MouseState"),Clazz.defineStatics(c$,"MIN_DELAY_MS",20),Clazz.declarePackage("J.api"),
Clazz.declareInterface(J.api,"EventManager"),Clazz.declarePackage("J.viewer"),Clazz.load(["J.api.EventManager","J.util.Rectangle","J.viewer.MouseState"],"J.viewer.ActionManager","java.lang.Character $.Float java.util.Hashtable JU.List $.P3 J.i18n.GT J.thread.HoverWatcherThread J.util.BSUtil $.Escape $.Logger $.Point3fi $.Txt J.viewer.binding.Binding $.JmolBinding".split(" "),function(){c$=Clazz.decorateAsClass(function(){this.viewer=null;this.haveMultiTouchInput=!1;this.predragBinding=this.rasmolBinding=
this.dragBinding=this.pfaatBinding=this.jmolBinding=this.binding=null;this.LEFT_DRAGGED=this.LEFT_CLICKED=0;this.hoverWatcherThread=null;Clazz.isClassDefined("J.viewer.ActionManager.MotionPoint")||J.viewer.ActionManager.$ActionManager$MotionPoint$();this.dragGesture=null;Clazz.isClassDefined("J.viewer.ActionManager.Gesture")||J.viewer.ActionManager.$ActionManager$Gesture$();this.atomPickingMode=1;this.pickingStyleSelect=this.pickingStyle=this.bondPickingMode=0;this.pickingStyleMeasure=5;this.rootPickingStyle=
0;this.pickAtomAssignType="C";this.pickBondAssignType="p";this.isPickAtomAssignCharge=!1;this.xyRange=0;this.mouseDragFactor=this.gestureSwipeFactor=1;this.mouseWheelFactor=1.15;this.dragged=this.pressed=this.clicked=this.moved=this.current=null;this.clickedCount=this.pressedCount=0;this.dragSelectedMode=this.labelMode=this.drawMode=!1;this.measuresEnabled=!0;this.hoverActive=this.haveSelection=!1;this.measurementPending=null;this.dragAtomIndex=-1;this.rubberbandSelectionMode=!1;this.rectRubber=null;
this.isAltKeyReleased=!0;this.isMultiTouchServer=this.isMultiTouchClient=this.keyProcessing=!1;this.clickAction=this.dragAction=this.pressAction=0;this.measurementQueued=null;this.selectionWorking=!1;Clazz.instantialize(this,arguments)},J.viewer,"ActionManager",null,J.api.EventManager);Clazz.prepareFields(c$,function(){this.dragGesture=Clazz.innerTypeInstance(J.viewer.ActionManager.Gesture,this,null,20);this.current=new J.viewer.MouseState("current");this.moved=new J.viewer.MouseState("moved");this.clicked=
new J.viewer.MouseState("clicked");this.pressed=new J.viewer.MouseState("pressed");this.dragged=new J.viewer.MouseState("dragged");this.rectRubber=new J.util.Rectangle});$_M(c$,"setViewer",function(a){this.viewer=a;this.setBinding(this.jmolBinding=new J.viewer.binding.JmolBinding("toggle"));this.LEFT_CLICKED=J.viewer.binding.Binding.getMouseAction(1,16,2);this.LEFT_DRAGGED=J.viewer.binding.Binding.getMouseAction(1,16,1)},"J.viewer.Viewer,~S");$_M(c$,"checkHover",function(){if(!this.viewer.getInMotion(!0)&&
!this.viewer.getSpinOn()&&!this.viewer.getNavOn()&&!this.viewer.checkObjectHovered(this.current.x,this.current.y)){var a=this.viewer.findNearestAtomIndex(this.current.x,this.current.y);if(!(0>a)){var b=2==this.getAtomPickingMode()&&this.isBound(J.viewer.binding.Binding.getMouseAction(this.clickedCount,this.moved.modifiers,1),10);this.viewer.hoverOn(a,b)}}});$_M(c$,"processMultitouchEvent",function(){},"~N,~N,~N,~N,JU.P3,~N");$_M(c$,"isBound",function(a,b){return this.binding.isBound(a,b)},"~N,~N");
$_M(c$,"bindAction",function(a,b){var c=J.viewer.ActionManager.getActionFromName(b),d=J.viewer.binding.Binding.getMouseActionStr(a);0!=d&&(0<=c?this.binding.bindAction(d,c):this.binding.bindName(d,b))},"~S,~S");$_M(c$,"clearBindings",function(){this.setBinding(this.jmolBinding=new J.viewer.binding.JmolBinding("toggle"));this.rasmolBinding=this.dragBinding=this.pfaatBinding=null});$_M(c$,"unbindAction",function(a,b){if(null==a&&null==b)this.clearBindings();else{var c=J.viewer.ActionManager.getActionFromName(b),
d=J.viewer.binding.Binding.getMouseActionStr(a);0<=c?this.binding.unbindAction(d,c):0!=d&&this.binding.unbindName(d,b);null==b&&this.binding.unbindUserAction(a)}},"~S,~S");c$.newAction=$_M(c$,"newAction",function(a,b,c){J.viewer.ActionManager.actionInfo[a]=c;J.viewer.ActionManager.actionNames[a]=b},"~N,~S,~S");c$.getActionName=$_M(c$,"getActionName",function(a){return a<J.viewer.ActionManager.actionNames.length?J.viewer.ActionManager.actionNames[a]:null},"~N");c$.getActionFromName=$_M(c$,"getActionFromName",
function(a){for(var b=0;b<J.viewer.ActionManager.actionNames.length;b++)if(J.viewer.ActionManager.actionNames[b].equalsIgnoreCase(a))return b;return-1},"~S");$_M(c$,"getBindingInfo",function(a){return this.binding.getBindingInfo(J.viewer.ActionManager.actionInfo,J.viewer.ActionManager.actionNames,a)},"~S");$_M(c$,"setBinding",function(a){this.binding=a},"J.viewer.binding.Binding");c$.getPickingModeName=$_M(c$,"getPickingModeName",function(a){return 0>a||a>=J.viewer.ActionManager.pickingModeNames.length?
"off":J.viewer.ActionManager.pickingModeNames[a]},"~N");c$.getPickingMode=$_M(c$,"getPickingMode",function(a){for(var b=J.viewer.ActionManager.pickingModeNames.length;0<=--b;)if(a.equalsIgnoreCase(J.viewer.ActionManager.pickingModeNames[b]))return b;return-1},"~S");$_M(c$,"getAtomPickingMode",function(){return this.atomPickingMode});$_M(c$,"setPickingMode",function(a){var b=!1;switch(a){case -1:b=!0;this.bondPickingMode=35;a=1;break;case 35:case 34:case 33:this.viewer.setBooleanProperty("bondPicking",
!0);this.bondPickingMode=a;return;case 8:this.bondPickingMode=a;if(this.viewer.getBondPicking())return;b=!0}b=(new Boolean(b|this.atomPickingMode!=a)).valueOf();this.atomPickingMode=a;b&&this.resetMeasurement()},"~N");$_M(c$,"setAtomPickingOption",function(a){switch(this.atomPickingMode){case 32:this.pickAtomAssignType=a,this.isPickAtomAssignCharge=this.pickAtomAssignType.equals("Pl")||this.pickAtomAssignType.equals("Mi")}},"~S");$_M(c$,"setBondPickingOption",function(a){switch(this.bondPickingMode){case 33:this.pickBondAssignType=
Character.toLowerCase(a.charAt(0))}},"~S");c$.getPickingStyleName=$_M(c$,"getPickingStyleName",function(a){return 0>a||a>=J.viewer.ActionManager.pickingStyleNames.length?"toggle":J.viewer.ActionManager.pickingStyleNames[a]},"~N");c$.getPickingStyleIndex=$_M(c$,"getPickingStyleIndex",function(a){for(var b=J.viewer.ActionManager.pickingStyleNames.length;0<=--b;)if(a.equalsIgnoreCase(J.viewer.ActionManager.pickingStyleNames[b]))return b;return-1},"~S");$_M(c$,"getPickingState",function(){var a=";set modelkitMode "+
this.viewer.getBoolean(603979883)+";set picking "+J.viewer.ActionManager.getPickingModeName(this.atomPickingMode);32==this.atomPickingMode&&(a+="_"+this.pickAtomAssignType);a+=";";0!=this.bondPickingMode&&(a+="set picking "+J.viewer.ActionManager.getPickingModeName(this.bondPickingMode));33==this.bondPickingMode&&(a+="_"+this.pickBondAssignType);return a+";"});$_M(c$,"getPickingStyle",function(){return this.pickingStyle});$_M(c$,"setPickingStyle",function(a){this.pickingStyle=a;4<=a?(this.pickingStyleMeasure=
a,this.resetMeasurement()):(3>a&&(this.rootPickingStyle=a),this.pickingStyleSelect=a);this.rubberbandSelectionMode=!1;switch(this.pickingStyleSelect){case 2:this.binding.getName().equals("extendedSelect")||this.setBinding(null==this.pfaatBinding?this.pfaatBinding=J.viewer.binding.Binding.newBinding("Pfaat"):this.pfaatBinding);break;case 3:this.binding.getName().equals("drag")||this.setBinding(null==this.dragBinding?this.dragBinding=J.viewer.binding.Binding.newBinding("Drag"):this.dragBinding);this.rubberbandSelectionMode=
!0;break;case 1:this.binding.getName().equals("selectOrToggle")||this.setBinding(null==this.rasmolBinding?this.rasmolBinding=J.viewer.binding.Binding.newBinding("Rasmol"):this.rasmolBinding);break;default:this.binding!==this.jmolBinding&&this.setBinding(this.jmolBinding)}this.binding.getName().equals("drag")||(this.predragBinding=this.binding)},"~N");$_M(c$,"getMouseInfo",function(){for(var a=new java.util.Hashtable,b=new JU.List,c,d=this.binding.getBindings().values().iterator();d.hasNext()&&((c=
d.next())||1);)Clazz.instanceOf(c,Boolean)||(J.util.Escape.isAI(c)&&(c=[J.viewer.binding.Binding.getMouseActionName(c[0],!1),J.viewer.ActionManager.getActionName(c[1])]),b.addLast(c));a.put("bindings",b);a.put("bindingName",this.binding.getName());a.put("actionNames",J.viewer.ActionManager.actionNames);a.put("actionInfo",J.viewer.ActionManager.actionInfo);a.put("bindingInfo",J.util.Txt.split(this.getBindingInfo(null),"\n"));return a});$_M(c$,"setGestureSwipeFactor",function(a){this.gestureSwipeFactor=
a},"~N");$_M(c$,"setMouseDragFactor",function(a){this.mouseDragFactor=a},"~N");$_M(c$,"setMouseWheelFactor",function(a){this.mouseWheelFactor=a},"~N");$_M(c$,"setCurrent",function(a,b,c,d){this.viewer.hoverOff();this.current.set(a,b,c,d)},"~N,~N,~N,~N");$_M(c$,"getCurrentX",function(){return this.current.x});$_M(c$,"getCurrentY",function(){return this.current.y});$_M(c$,"setMouseMode",function(){this.drawMode=this.labelMode=!1;this.dragSelectedMode=this.viewer.getDragSelected();this.measuresEnabled=
!this.dragSelectedMode;if(!this.dragSelectedMode)switch(this.atomPickingMode){default:return;case 32:this.measuresEnabled=!this.isPickAtomAssignCharge;return;case 4:this.drawMode=!0;this.measuresEnabled=!1;break;case 2:this.labelMode=!0;this.measuresEnabled=!1;break;case 9:this.measuresEnabled=!1;break;case 19:case 22:case 20:case 21:this.measuresEnabled=!1;return}this.exitMeasurementMode()});$_M(c$,"clearMouseInfo",function(){this.pressedCount=this.clickedCount=0;this.dragGesture.setAction(0,0);
this.exitMeasurementMode()});$_M(c$,"isMTClient",function(){return this.isMultiTouchClient});$_M(c$,"isMTServer",function(){return this.isMultiTouchServer});$_M(c$,"dispose",function(){this.clear()});$_M(c$,"clear",function(){this.startHoverWatcher(!1);null!=this.predragBinding&&(this.binding=this.predragBinding);this.viewer.setPickingMode(null,1);this.viewer.setPickingStyle(null,this.rootPickingStyle);this.isAltKeyReleased=!0});$_M(c$,"startHoverWatcher",function(a){if(!this.viewer.isPreviewOnly())try{a?
null==this.hoverWatcherThread&&(this.current.time=-1,this.hoverWatcherThread=new J.thread.HoverWatcherThread(this,this.current,this.moved,this.viewer)):null!=this.hoverWatcherThread&&(this.current.time=-1,this.hoverWatcherThread.interrupt(),this.hoverWatcherThread=null)}catch(b){if(!Clazz.exceptionOf(b,Exception))throw b;}},"~B");$_M(c$,"setModeMouse",function(a){-1==a&&this.startHoverWatcher(!1)},"~N");Clazz.overrideMethod(c$,"keyPressed",function(a,b){if(this.keyProcessing)return!1;this.viewer.hoverOff();
this.keyProcessing=!0;switch(a){case 18:this.dragSelectedMode&&this.isAltKeyReleased&&this.viewer.moveSelected(-2147483648,0,-2147483648,-2147483648,-2147483648,null,!1,!1);this.isAltKeyReleased=!1;this.moved.modifiers|=8;break;case 16:this.dragged.modifiers|=1;this.moved.modifiers|=1;break;case 17:this.moved.modifiers|=2}var c=8464|this.moved.modifiers;!this.labelMode&&!this.binding.isUserAction(c)&&this.checkMotionRotateZoom(c,this.current.x,0,0,!1);if(this.viewer.getBoolean(603979887))switch(a){case 38:case 40:case 37:case 39:case 32:case 46:this.viewer.navigate(a,
b)}this.keyProcessing=!1;return!0},"~N,~N");Clazz.overrideMethod(c$,"keyReleased",function(a){switch(a){case 18:this.dragSelectedMode&&this.viewer.moveSelected(2147483647,0,-2147483648,-2147483648,-2147483648,null,!1,!1);this.isAltKeyReleased=!0;this.moved.modifiers&=-9;break;case 16:this.moved.modifiers&=-2;break;case 17:this.moved.modifiers&=-3}0==this.moved.modifiers&&this.viewer.setCursor(0);if(this.viewer.getBoolean(603979887))switch(a){case 38:case 40:case 37:case 39:this.viewer.navigate(0,
0)}},"~N");Clazz.overrideMethod(c$,"mouseEnterExit",function(a,b,c,d){this.setCurrent(a,b,c,0);d&&null!=this.measurementPending&&(this.exitMeasurementMode(),this.viewer.refresh(3,"mouseExit"))},"~N,~N,~N,~B");$_M(c$,"setMouseActions",($fz=function(a,b,c){this.pressAction=J.viewer.binding.Binding.getMouseAction(a,b,c?5:4);this.dragAction=J.viewer.binding.Binding.getMouseAction(a,b,1);this.clickAction=J.viewer.binding.Binding.getMouseAction(a,b,2)},$fz.isPrivate=!0,$fz),"~N,~N,~B");Clazz.overrideMethod(c$,
"mouseAction",function(a,b,c,d,e,f){if(this.viewer.getMouseEnabled())switch(a){case 0:this.setCurrent(b,c,d,f);this.moved.setCurrent(this.current,0);if(null!=this.measurementPending||this.hoverActive){this.clickAction=J.viewer.binding.Binding.getMouseAction(this.clickedCount,f,0);this.checkClickAction(c,d,b,0);break}if(this.isZoomArea(c)){this.checkMotionRotateZoom(this.LEFT_DRAGGED,0,0,0,!1);break}8==this.viewer.getCursor()&&this.viewer.setCursor(0);break;case 4:this.setMouseMode();this.pressedCount=
this.pressed.check(0,0,0,f,b,700)?this.pressedCount+1:1;1==this.pressedCount&&(this.viewer.checkInMotion(1),this.setCurrent(b,c,d,f));this.pressAction=J.viewer.binding.Binding.getMouseAction(this.pressedCount,f,4);this.viewer.setCursor(12);this.pressed.setCurrent(this.current,1);this.dragged.setCurrent(this.current,1);this.viewer.setFocus();this.dragGesture.setAction(this.dragAction,b);this.checkPressedAction(c,d,b);break;case 1:this.setMouseMode();this.setMouseActions(this.pressedCount,f,!1);a=c-
this.dragged.x;e=d-this.dragged.y;this.setCurrent(b,c,d,f);this.dragged.setCurrent(this.current,-1);32!=this.atomPickingMode&&this.exitMeasurementMode();this.dragGesture.add(this.dragAction,c,d,b);this.checkDragWheelAction(this.dragAction,c,d,a,e,b,1);break;case 5:this.setMouseActions(this.pressedCount,f,!0);this.setCurrent(b,c,d,f);this.viewer.spinXYBy(0,0,0);f=!this.pressed.check(this.xyRange,c,d,f,b,9223372036854775E3);this.checkReleaseAction(c,d,b,f);break;case 3:if(this.viewer.isApplet()&&!this.viewer.hasFocus())break;
this.setCurrent(b,this.current.x,this.current.y,f);this.checkDragWheelAction(J.viewer.binding.Binding.getMouseAction(0,f,3),this.current.x,this.current.y,0,d,b,3);break;case 2:this.setMouseMode();this.clickedCount=1<e?e:this.clicked.check(0,0,0,f,b,700)?this.clickedCount+1:1;1==this.clickedCount&&this.setCurrent(b,c,d,f);this.setMouseActions(this.clickedCount,f,!1);this.clicked.setCurrent(this.current,this.clickedCount);this.viewer.setFocus();if(9!=this.atomPickingMode&&this.isBound(J.viewer.binding.Binding.getMouseAction(1,
f,4),31))break;this.clickAction=J.viewer.binding.Binding.getMouseAction(this.clickedCount,f,2);this.checkClickAction(c,d,b,this.clickedCount)}},"~N,~N,~N,~N,~N,~N");$_M(c$,"checkPressedAction",($fz=function(a,b,c){var d=J.viewer.binding.Binding.getButtonMods(this.pressAction),e=this.isBound(J.viewer.binding.Binding.getMouseAction(1,d,4),31);if(0!=d){this.pressAction=this.viewer.notifyMouseClicked(a,b,this.pressAction,4);if(0==this.pressAction)return;d=J.viewer.binding.Binding.getButtonMods(this.pressAction)}this.setMouseActions(this.pressedCount,
d,!1);J.util.Logger.debugging&&J.util.Logger.debug(J.viewer.binding.Binding.getMouseActionName(this.pressAction,!1));if(this.drawMode&&(this.isBound(this.dragAction,8)||this.isBound(this.dragAction,9))||this.labelMode&&this.isBound(this.dragAction,10))this.viewer.checkObjectDragged(-2147483648,0,a,b,this.dragAction);else{this.checkUserAction(this.pressAction,a,b,0,0,c,4);c=!1;switch(this.atomPickingMode){case 32:c=this.isBound(this.clickAction,0);break;case 28:c=this.isBound(this.dragAction,7)||this.isBound(this.dragAction,
14);break;case 26:case 36:case 27:c=this.isBound(this.dragAction,7)||this.isBound(this.dragAction,27)||this.isBound(this.dragAction,14);break;case 29:c=this.isBound(this.dragAction,11)||this.isBound(this.dragAction,14);break;case 30:c=this.isBound(this.dragAction,12)||this.isBound(this.dragAction,27)||this.isBound(this.dragAction,14)}if(c){if(this.dragAtomIndex=this.viewer.findNearestAtomIndexMovable(a,b,!0),0<=this.dragAtomIndex&&(32==this.atomPickingMode||31==this.atomPickingMode)&&this.viewer.isAtomAssignable(this.dragAtomIndex))this.enterMeasurementMode(this.dragAtomIndex),
this.measurementPending.addPoint(this.dragAtomIndex,null,!1)}else this.isBound(this.pressAction,23)?(e="j",this.viewer.getBoolean(603979883)&&(e=this.viewer.checkObjectClicked(a,b,this.LEFT_CLICKED),e=null!=e&&"bond".equals(e.get("type"))?"b":0<=this.viewer.findNearestAtomIndex(a,b)?"a":"m"),this.viewer.popupMenu(a,b,e)):this.dragSelectedMode?(this.haveSelection=!0,e&&(this.haveSelection=0<=this.viewer.findNearestAtomIndexMovable(a,b,!0)),this.haveSelection&&(this.isBound(this.dragAction,13)||this.isBound(this.dragAction,
14))&&this.viewer.moveSelected(-2147483648,0,-2147483648,-2147483648,-2147483648,null,!1,!1)):(this.viewer.global.useArcBall&&this.viewer.rotateArcBall(a,b,0),this.checkMotionRotateZoom(this.dragAction,a,0,0,!0))}},$fz.isPrivate=!0,$fz),"~N,~N,~N");$_M(c$,"checkDragWheelAction",($fz=function(a,b,c,d,e,f,g){var h=J.viewer.binding.Binding.getButtonMods(a);if(0!=h){h=this.viewer.notifyMouseClicked(b,c,J.viewer.binding.Binding.getMouseAction(this.pressedCount,h,g),g);if(0==h)return;0<h&&(a=h)}if(this.isRubberBandSelect(a))this.calcRectRubberBand(),
this.viewer.refresh(3,"rubberBand selection");else if(!this.checkUserAction(a,b,c,d,e,f,g)){if(0<=this.viewer.getRotateBondIndex()){if(this.isBound(a,26)){this.viewer.moveSelected(d,e,-2147483648,b,c,null,!1,!1);return}this.isBound(a,25)||this.viewer.setRotateBondIndex(-1)}f=null;if(0<=this.dragAtomIndex)switch(this.atomPickingMode){case 26:this.setMotion(13,!0);this.isBound(a,27)&&this.viewer.getBoolean(603979785)?this.viewer.rotateSelected(this.getDegrees(d,0),this.getDegrees(e,1),null):this.viewer.moveSelected(d,
e,this.isBound(a,14)?-e:-2147483648,-2147483648,-2147483648,null,!0,!1);return;case 36:case 27:case 30:f=this.viewer.getAtomBits(1095761934,J.util.BSUtil.newAndSetBit(this.dragAtomIndex)),36==this.atomPickingMode&&f.and(this.viewer.getAtomBitSet("ligand"));case 28:case 29:1==this.dragGesture.getPointCount()&&this.viewer.undoMoveActionClear(this.dragAtomIndex,2,!0);this.setMotion(13,!0);if(this.isBound(a,27))this.viewer.rotateSelected(this.getDegrees(d,0),this.getDegrees(e,1),f);else{switch(this.atomPickingMode){case 36:case 27:case 30:this.viewer.select(f,
!1,0,!0)}this.viewer.moveAtomWithHydrogens(this.dragAtomIndex,d,e,this.isBound(a,14)?-e:-2147483648,f)}return}0<=this.dragAtomIndex&&1==g&&this.isBound(this.clickAction,0)&&32==this.atomPickingMode?(e=this.viewer.findNearestAtomIndexMovable(b,c,!1),0<=e?(null!=this.measurementPending?this.measurementPending.setCount(1):this.measuresEnabled&&this.enterMeasurementMode(e),this.addToMeasurement(e,null,!0),this.measurementPending.colix=20):null!=this.measurementPending&&(this.measurementPending.setCount(1),
this.measurementPending.colix=23),null!=this.measurementPending&&(this.measurementPending.traceX=b,this.measurementPending.traceY=c,this.viewer.refresh(3,"assignNew"))):!this.drawMode&&!this.labelMode&&this.isBound(a,45)?this.viewer.translateXYBy(d,e):this.dragSelectedMode&&this.haveSelection&&(this.isBound(a,13)||this.isBound(a,27))?(b=this.viewer.getSelectionSet(!1).nextSetBit(0),0>b||(1==this.dragGesture.getPointCount()?this.viewer.undoMoveActionClear(b,2,!0):this.viewer.moveSelected(2147483647,
0,-2147483648,-2147483648,-2147483648,null,!1,!1),this.setMotion(13,!0),this.isBound(a,27)&&this.viewer.getBoolean(603979785)?this.viewer.rotateSelected(this.getDegrees(d,0),this.getDegrees(e,1),null):this.viewer.moveSelected(d,e,-2147483648,-2147483648,-2147483648,null,!0,!1))):this.drawMode&&(this.isBound(a,8)||this.isBound(a,9))||this.labelMode&&this.isBound(a,10)?(this.setMotion(13,!0),this.viewer.checkObjectDragged(this.dragged.x,this.dragged.y,b,c,a)):this.checkMotionRotateZoom(a,b,d,e,!0)?
this.viewer.getSlabEnabled()&&this.checkSlideZoom(a)?this.viewer.slabDepthByPixels(e):this.viewer.zoomBy(e):this.isBound(a,25)?(a=this.getDegrees(d,0),e=this.getDegrees(e,1),this.viewer.global.useArcBall?this.viewer.rotateArcBall(b,c,this.mouseDragFactor):this.viewer.rotateXYBy(a,e)):this.isBound(a,29)?0==d&&1<Math.abs(e)?(this.setMotion(8,!0),this.viewer.zoomBy(e+(0<e?-1:1))):0==e&&1<Math.abs(d)&&(this.setMotion(13,!0),this.viewer.rotateZBy(-d+(0<d?1:-1),2147483647,2147483647)):this.isBound(a,46)?
this.zoomByFactor(e,2147483647,2147483647):this.isBound(a,28)?(this.setMotion(13,!0),this.viewer.rotateZBy(-d,2147483647,2147483647)):this.viewer.getSlabEnabled()&&(this.isBound(a,6)?this.viewer.depthByPixels(e):this.isBound(a,38)?this.viewer.slabByPixels(e):this.isBound(a,39)&&this.viewer.slabDepthByPixels(e))}},$fz.isPrivate=!0,$fz),"~N,~N,~N,~N,~N,~N,~N");$_M(c$,"checkReleaseAction",($fz=function(a,b,c,d){J.util.Logger.debugging&&J.util.Logger.debug(J.viewer.binding.Binding.getMouseActionName(this.pressAction,
!1));this.viewer.checkInMotion(0);this.viewer.setInMotion(!1);this.viewer.setCursor(0);this.dragGesture.add(this.dragAction,a,b,c);d&&this.viewer.setRotateBondIndex(-2147483648);0<=this.dragAtomIndex&&(29==this.atomPickingMode||30==this.atomPickingMode)&&this.minimize(!0);if(32==this.atomPickingMode&&this.isBound(this.clickAction,0))null==this.measurementPending||0>this.dragAtomIndex||this.assignNew(a,b);else if(this.dragAtomIndex=-1,this.isRubberBandSelect(this.clickAction)&&this.selectRb(this.clickAction),
this.rubberbandSelectionMode=this.binding.getName().equals("drag"),this.rectRubber.x=2147483647,d&&this.viewer.notifyMouseClicked(a,b,J.viewer.binding.Binding.getMouseAction(this.pressedCount,0,5),5),this.drawMode&&(this.isBound(this.dragAction,8)||this.isBound(this.dragAction,9))||this.labelMode&&this.isBound(this.dragAction,10))this.viewer.checkObjectDragged(2147483647,0,a,b,this.dragAction);else if(this.dragSelectedMode&&(this.isBound(this.dragAction,13)&&this.haveSelection)&&this.viewer.moveSelected(2147483647,
0,-2147483648,-2147483648,-2147483648,null,!1,!1),(!d||!this.checkUserAction(this.pressAction,a,b,0,0,c,5))&&this.viewer.getBoolean(603979780)&&this.isBound(this.dragAction,44))a=this.getExitRate(),0<a&&this.viewer.spinXYBy(this.dragGesture.getDX(4,2),this.dragGesture.getDY(4,2),30*a*this.gestureSwipeFactor),this.viewer.global.logGestures&&this.viewer.log("$NOW$ swipe "+this.dragGesture+" "+a)},$fz.isPrivate=!0,$fz),"~N,~N,~N,~B");$_M(c$,"checkClickAction",($fz=function(a,b,c,d){if(this.viewer.haveModelSet()){if(0<
d){if(this.checkUserAction(this.clickAction,a,b,0,0,c,32768))return;this.clickAction=this.viewer.notifyMouseClicked(a,b,this.clickAction,32768);if(0==this.clickAction)return}J.util.Logger.debugging&&J.util.Logger.debug(J.viewer.binding.Binding.getMouseActionName(this.clickAction,!1));if(this.isBound(this.clickAction,2)&&this.viewer.frankClicked(a,b))this.viewer.popupMenu(-a,b,"j");else if(this.isBound(this.clickAction,2)&&this.viewer.frankClickedModelKit(a,b))this.viewer.popupMenu(0,0,"m");else{c=
null;var e=!1,f=!1,g=null;this.drawMode||(g=this.viewer.checkObjectClicked(a,b,this.clickAction),null!=g&&(e="bond".equals(g.get("type")),f="isosurface".equals(g.get("type")),c=this.getPoint(g)));e&&(d=1);if(!(null!=c&&Float.isNaN(c.x))){var h=this.findNearestAtom(a,b,c,0<d);if(0==d&&32!=this.atomPickingMode)null!=this.measurementPending&&((null!=c||0==this.measurementPending.getIndexOf(h))&&this.measurementPending.addPoint(h,c,!1),this.measurementPending.haveModified()&&this.viewer.setPendingMeasurement(this.measurementPending),
this.viewer.refresh(3,"measurementPending"));else if(this.setMouseMode(),this.isBound(this.clickAction,43)&&this.viewer.stopMotion(),this.viewer.getBoolean(603979887)&&23==this.atomPickingMode&&this.isBound(this.clickAction,21))this.viewer.navTranslatePercent(100*a/this.viewer.getScreenWidth()-50,100*b/this.viewer.getScreenHeight()-50);else{if(e){if(this.isBound(this.clickAction,34==this.bondPickingMode||33==this.bondPickingMode?0:5)){this.bondPicked(g.get("index").intValue());return}}else{if(f)return;
if(32!=this.atomPickingMode&&null!=this.measurementPending&&this.isBound(this.clickAction,20)){this.atomOrPointPicked(h,c);4==this.addToMeasurement(h,c,!1)&&this.toggleMeasurement();return}if(this.isBound(this.clickAction,37)){null!=this.measurementPending?(this.addToMeasurement(h,c,!0),this.toggleMeasurement()):!this.drawMode&&(!this.labelMode&&!this.dragSelectedMode&&this.measuresEnabled)&&(this.enterMeasurementMode(h),this.addToMeasurement(h,c,!0));this.atomOrPointPicked(h,c);return}}this.isSelectAction(this.clickAction)?
f||this.atomOrPointPicked(h,c):this.isBound(this.clickAction,24)&&0>h&&this.reset()}}}}},$fz.isPrivate=!0,$fz),"~N,~N,~N,~N");$_M(c$,"checkUserAction",($fz=function(a,b,c,d,e,f,g){if(!this.binding.isUserAction(a))return!1;for(var h=!1,k,l=this.binding.getBindings(),m=a+"\t",n,q=l.keySet().iterator();q.hasNext()&&((n=q.next())||1);)if(0==n.indexOf(m)&&J.util.Escape.isAS(k=l.get(n))){var p=k[1],r=null;if(0<=p.indexOf("_ATOM")){var s=this.findNearestAtom(b,c,null,!0),p=J.util.Txt.simpleReplace(p,"_ATOM",
"({"+(0<=s?""+s:"")+"})");0<=s&&(p=J.util.Txt.simpleReplace(p,"_POINT",J.util.Escape.eP(this.viewer.getModelSet().atoms[s])))}if(!this.drawMode&&(0<=p.indexOf("_POINT")||0<=p.indexOf("_OBJECT")||0<=p.indexOf("_BOND"))){s=this.viewer.checkObjectClicked(b,c,a);if(null!=s&&null!=(r=s.get("pt")))s.get("type").equals("bond")&&(p=J.util.Txt.simpleReplace(p,"_BOND","[{"+s.get("index")+"}]")),p=J.util.Txt.simpleReplace(p,"_POINT",J.util.Escape.eP(r)),p=J.util.Txt.simpleReplace(p,"_OBJECT",J.util.Escape.escapeMap(s));
p=J.util.Txt.simpleReplace(p,"_BOND","[{}]");p=J.util.Txt.simpleReplace(p,"_OBJECT","{}")}p=J.util.Txt.simpleReplace(p,"_POINT","{}");p=J.util.Txt.simpleReplace(p,"_ACTION",""+a);p=J.util.Txt.simpleReplace(p,"_X",""+b);p=J.util.Txt.simpleReplace(p,"_Y",""+(this.viewer.getScreenHeight()-c));p=J.util.Txt.simpleReplace(p,"_DELTAX",""+d);p=J.util.Txt.simpleReplace(p,"_DELTAY",""+e);p=J.util.Txt.simpleReplace(p,"_TIME",""+f);p=J.util.Txt.simpleReplace(p,"_MODE",""+g);p.startsWith("+:")&&(h=!0,p=p.substring(2));
this.viewer.evalStringQuiet(p)}return!h},$fz.isPrivate=!0,$fz),"~N,~N,~N,~N,~N,~N,~N");$_M(c$,"checkMotionRotateZoom",($fz=function(a,b,c,d,e){b=this.checkSlideZoom(a);var f=this.isBound(a,25),g=this.isBound(a,29);if(!b&&!f&&!g)return!1;a=(c=g&&(0==c||Math.abs(d)>5*Math.abs(c)))||this.isZoomArea(this.moved.x)||this.isBound(a,46)?8:f||g?13:this.isBound(a,1)?12:0;this.setMotion(a,e);return c||b},$fz.isPrivate=!0,$fz),"~N,~N,~N,~N,~B");$_M(c$,"getExitRate",function(){return 10<this.dragGesture.getTimeDifference(2)?
0:this.dragGesture.getSpeedPixelsPerMillisecond(4,2)});$_M(c$,"isRubberBandSelect",($fz=function(a){return this.rubberbandSelectionMode&&(this.isBound(a,35)||this.isBound(a,34)||this.isBound(a,32))},$fz.isPrivate=!0,$fz),"~N");$_M(c$,"getRubberBand",function(){return!this.rubberbandSelectionMode||2147483647==this.rectRubber.x?null:this.rectRubber});$_M(c$,"calcRectRubberBand",($fz=function(){var a=this.viewer.isAntialiased()?2:1;this.current.x<this.pressed.x?(this.rectRubber.x=this.current.x*a,this.rectRubber.width=
(this.pressed.x-this.current.x)*a):(this.rectRubber.x=this.pressed.x*a,this.rectRubber.width=(this.current.x-this.pressed.x)*a);this.current.y<this.pressed.y?(this.rectRubber.y=this.current.y*a,this.rectRubber.height=(this.pressed.y-this.current.y)*a):(this.rectRubber.y=this.pressed.y*a,this.rectRubber.height=(this.current.y-this.pressed.y)*a)},$fz.isPrivate=!0,$fz));$_M(c$,"getDegrees",function(a,b){var c=0==b?this.viewer.getScreenWidth():this.viewer.getScreenHeight();500<c&&(c=500);return 180*(a/
c)*this.mouseDragFactor},"~N,~N");$_M(c$,"checkSlideZoom",($fz=function(a){return this.isBound(a,40)&&this.isZoomArea(this.pressed.x)},$fz.isPrivate=!0,$fz),"~N");$_M(c$,"isZoomArea",($fz=function(a){return a>98*this.viewer.getScreenWidth()*(this.viewer.isStereoDouble()?2:1)/100},$fz.isPrivate=!0,$fz),"~N");$_M(c$,"getPoint",($fz=function(a){var b=new J.util.Point3fi;b.setT(a.get("pt"));b.modelIndex=a.get("modelIndex").intValue();return b},$fz.isPrivate=!0,$fz),"java.util.Map");$_M(c$,"findNearestAtom",
($fz=function(a,b,c,d){a=this.drawMode||null!=c?-1:this.viewer.findNearestAtomIndexMovable(a,b,!1);return 0<=a&&(d||null==this.measurementPending)&&!this.viewer.isInSelectionSubset(a)?-1:a},$fz.isPrivate=!0,$fz),"~N,~N,J.util.Point3fi,~B");$_M(c$,"isSelectAction",($fz=function(a){return this.isBound(a,17)||!this.drawMode&&!this.labelMode&&1==this.atomPickingMode&&this.isBound(a,1)||this.dragSelectedMode&&(this.isBound(this.dragAction,27)||this.isBound(this.dragAction,13))||this.isBound(a,22)||this.isBound(a,
35)||this.isBound(a,32)||this.isBound(a,34)||this.isBound(a,36)||this.isBound(a,30)},$fz.isPrivate=!0,$fz),"~N");$_M(c$,"enterMeasurementMode",($fz=function(a){this.viewer.setPicked(-1);this.viewer.setPicked(a);this.viewer.setCursor(1);this.viewer.setPendingMeasurement(this.measurementPending=this.viewer.getMP());this.measurementQueued=this.measurementPending},$fz.isPrivate=!0,$fz),"~N");$_M(c$,"addToMeasurement",($fz=function(a,b,c){if(-1==a&&null==b||null==this.measurementPending)return this.exitMeasurementMode(),
0;var d=this.measurementPending.getCount();-2147483648!=this.measurementPending.traceX&&2==d&&this.measurementPending.setCount(d=1);return 4==d&&!c?d:this.measurementPending.addPoint(a,b,!0)},$fz.isPrivate=!0,$fz),"~N,J.util.Point3fi,~B");$_M(c$,"resetMeasurement",($fz=function(){this.exitMeasurementMode();this.measurementQueued=this.viewer.getMP()},$fz.isPrivate=!0,$fz));$_M(c$,"exitMeasurementMode",($fz=function(){null!=this.measurementPending&&(this.viewer.setPendingMeasurement(this.measurementPending=
null),this.viewer.setCursor(0))},$fz.isPrivate=!0,$fz));$_M(c$,"getSequence",($fz=function(){var a=this.measurementQueued.getAtomIndex(1),b=this.measurementQueued.getAtomIndex(2);0>a||0>b||(a=this.viewer.getSmiles(a,b,null,!0,!1,!1,!1),this.viewer.setStatusMeasuring("measureSequence",-2,a,0))},$fz.isPrivate=!0,$fz));$_M(c$,"minimize",($fz=function(a){this.viewer.stopMinimization();var b=this.dragAtomIndex;a&&(this.dragAtomIndex=-1);a=0==this.viewer.getMotionFixedAtoms().cardinality()?this.viewer.getAtomBits(this.viewer.isAtomPDB(b)?
1087373318:1095761934,J.util.BSUtil.newAndSetBit(b)):J.util.BSUtil.setAll(this.viewer.getAtomCount());this.viewer.minimize(2147483647,0,a,null,0,!1,!1,!1)},$fz.isPrivate=!0,$fz),"~B");$_M(c$,"queueAtom",($fz=function(a,b){var c=this.measurementQueued.addPoint(a,b,!0);0<=a&&this.viewer.setStatusAtomPicked(a,"Atom #"+c+":"+this.viewer.getAtomInfo(a));return c},$fz.isPrivate=!0,$fz),"~N,J.util.Point3fi");$_M(c$,"setMotion",function(a,b){switch(this.viewer.getCursor()){case 3:break;default:this.viewer.setCursor(a)}b&&
this.viewer.setInMotion(!0)},"~N,~B");$_M(c$,"zoomByFactor",function(a,b,c){0!=a&&(this.setMotion(8,!0),this.viewer.zoomByFactor(Math.pow(this.mouseWheelFactor,a),b,c),this.viewer.setInMotion(!1))},"~N,~N,~N");$_M(c$,"runScript",($fz=function(a){this.viewer.script(a)},$fz.isPrivate=!0,$fz),"~S");$_M(c$,"atomOrPointPicked",($fz=function(a,b){if(0>a){this.resetMeasurement();if(this.isBound(this.clickAction,33)){this.runScript("select none");return}if(5!=this.atomPickingMode&&6!=this.atomPickingMode)return}var c=
2;switch(this.atomPickingMode){case 28:case 29:return;case 0:return;case 25:case 24:case 8:var d=8==this.atomPickingMode,c=25==this.atomPickingMode;if(!this.isBound(this.clickAction,d?5:3))return;if(null==this.measurementQueued||0==this.measurementQueued.getCount()||2<this.measurementQueued.getCount())this.resetMeasurement(),this.enterMeasurementMode(a);this.addToMeasurement(a,b,!0);if(2!=this.queueAtom(a,b))return;d=d||this.measurementQueued.isConnected(this.viewer.getModelSet().atoms,2)?" DELETE":
c?"STRUTS":"";this.runScript("connect "+this.measurementQueued.getMeasurementScript(" ",!0)+d);this.resetMeasurement();return;case 21:c++;case 20:c++;case 18:case 19:case 22:if(!this.isBound(this.clickAction,20))return;if(null==this.measurementQueued||0==this.measurementQueued.getCount()||this.measurementQueued.getCount()>c)this.resetMeasurement(),this.enterMeasurementMode(a);this.addToMeasurement(a,b,!0);this.queueAtom(a,b);d=this.measurementQueued.getCount();1==d&&(this.viewer.setPicked(-1),this.viewer.setPicked(a));
if(d<c)return;22==this.atomPickingMode?this.getSequence():(this.viewer.setStatusMeasuring("measurePicked",c,this.measurementQueued.getStringDetail(),this.measurementQueued.getValue()),(18==this.atomPickingMode||4==this.pickingStyleMeasure)&&this.runScript("measure "+this.measurementQueued.getMeasurementScript(" ",!0)));this.resetMeasurement();return}d=null!=this.measurementPending&&1!=this.atomPickingMode?1:this.atomPickingMode;switch(d){case 3:if(!this.isBound(this.clickAction,17))return;null==b?
this.zoomTo(a):this.runScript("zoomTo "+J.util.Escape.eP(b));return;case 5:case 6:this.isBound(this.clickAction,17)&&this.checkTwoAtomAction(b,a)}if(null==b){switch(d){case 1:!this.drawMode&&!this.labelMode&&this.isBound(this.clickAction,1)?this.zoomTo(a):this.isBound(this.clickAction,17)&&this.viewer.setStatusAtomPicked(a,null);return;case 2:this.isBound(this.clickAction,19)&&(this.runScript("set labeltoggle {atomindex="+a+"}"),this.viewer.setStatusAtomPicked(a,null));return;case 31:if(this.isBound(this.clickAction,
0)){var c=this.viewer.getAtomBitSet("connected(atomIndex="+a+") and !within(SMARTS,'[r50,R]')"),e=c.cardinality();switch(e){case 0:case 1:return;case 3:case 4:for(var f=Clazz.newIntArray(e,0),g=Clazz.newIntArray(e,0),h=0,d=c.nextSetBit(0);0<=d;d=c.nextSetBit(d+1),h++)f[h]=this.viewer.getBranchBitSet(d,a,!0).cardinality(),g[h]=d;for(h=0;h<e-2;h++){for(var k=-2147483648,l=0,d=0;d<e;d++)f[d]>=k&&c.get(g[d])&&(l=g[d],k=f[d]);c.clear(l)}}this.viewer.undoMoveActionClear(a,2,!0);this.viewer.invertSelected(null,
null,a,c);this.viewer.setStatusAtomPicked(a,"inverted: "+J.util.Escape.eBS(c))}return;case 7:this.isBound(this.clickAction,4)&&(c=J.util.BSUtil.newAndSetBit(a),this.viewer.deleteAtoms(c,!1),this.viewer.setStatusAtomPicked(a,"deleted: "+J.util.Escape.eBS(c)));return}d="atomindex="+a;switch(this.atomPickingMode){default:return;case 9:this.selectAtoms(d);break;case 10:this.selectAtoms("within(group, "+d+")");break;case 11:this.selectAtoms("within(chain, "+d+")");break;case 13:this.selectAtoms("within(polymer, "+
d+")");break;case 14:this.selectAtoms("within(structure, "+d+")");break;case 12:this.selectAtoms("within(molecule, "+d+")");break;case 16:this.selectAtoms("within(model, "+d+")");break;case 17:this.selectAtoms("visible and within(element, "+d+")");break;case 15:this.selectAtoms("visible and within(site, "+d+")")}this.viewer.clearClickCount();this.viewer.setStatusAtomPicked(a,null)}},$fz.isPrivate=!0,$fz),"~N,J.util.Point3fi");$_M(c$,"assignNew",($fz=function(a,b){if(2==this.measurementPending.getCount())this.viewer.undoMoveActionClear(-1,
4146,!0),this.runScript("assign connect "+this.measurementPending.getMeasurementScript(" ",!1));else if(this.pickAtomAssignType.equals("Xx"))this.exitMeasurementMode(),this.viewer.refresh(3,"bond dropped");else if(this.pressed.inRange(this.xyRange,this.dragged.x,this.dragged.y)){var c="assign atom ({"+this.dragAtomIndex+'}) "'+this.pickAtomAssignType+'"';this.isPickAtomAssignCharge?(c+=";{atomindex="+this.dragAtomIndex+"}.label='%C'; ",this.viewer.undoMoveActionClear(this.dragAtomIndex,4,!0)):this.viewer.undoMoveActionClear(-1,
4146,!0);this.runScript(c)}else this.isPickAtomAssignCharge||(this.viewer.undoMoveActionClear(-1,4146,!0),c=this.viewer.getModelSet().atoms[this.dragAtomIndex],1==c.getElementNumber()?this.runScript("assign atom ({"+this.dragAtomIndex+'}) "X"'):(c=JU.P3.new3(a,b,c.screenZ),this.viewer.unTransformPoint(c,c),this.runScript("assign atom ({"+this.dragAtomIndex+'}) "'+this.pickAtomAssignType+'" '+J.util.Escape.eP(c))));this.exitMeasurementMode()},$fz.isPrivate=!0,$fz),"~N,~N");$_M(c$,"bondPicked",($fz=
function(a){33==this.bondPickingMode&&this.viewer.undoMoveActionClear(-1,4146,!0);switch(this.bondPickingMode){case 33:this.runScript("assign bond [{"+a+'}] "'+this.pickBondAssignType+'"');break;case 34:this.viewer.setRotateBondIndex(a);break;case 8:this.viewer.deleteBonds(J.util.BSUtil.newAndSetBit(a))}},$fz.isPrivate=!0,$fz),"~N");$_M(c$,"checkTwoAtomAction",($fz=function(a,b){var c=5==this.atomPickingMode;if(this.viewer.getSpinOn()||this.viewer.getNavOn()||null!=this.viewer.getPendingMeasurement())this.resetMeasurement(),
this.viewer.getSpinOn()&&this.runScript("spin off");else{2<=this.measurementQueued.getCount()&&this.resetMeasurement();var d=this.measurementQueued.getCount();if(1==d)if(null==a){if(this.measurementQueued.getAtomIndex(1)==b)return}else if(0==this.measurementQueued.getAtom(1).distance(a))return;if(0<=b||null!=a)d=this.queueAtom(b,a);2>d?c?this.viewer.scriptStatus(1==d?J.i18n.GT._("pick one more atom in order to spin the model around an axis"):J.i18n.GT._("pick two atoms in order to spin the model around an axis")):
this.viewer.scriptStatus(1==d?J.i18n.GT._("pick one more atom in order to display the symmetry relationship"):J.i18n.GT._("pick two atoms in order to display the symmetry relationship between them")):(d=this.measurementQueued.getMeasurementScript(" ",!1),c?this.runScript("spin"+d+" "+this.viewer.getInt(553648157)):this.runScript("draw symop"+d+";show symop"+d))}},$fz.isPrivate=!0,$fz),"J.util.Point3fi,~N");$_M(c$,"reset",($fz=function(){this.runScript("!reset")},$fz.isPrivate=!0,$fz));$_M(c$,"selectAtoms",
($fz=function(a){if(!(null!=this.measurementPending||this.selectionWorking)){this.selectionWorking=!0;var b=this.rubberbandSelectionMode||this.isBound(this.clickAction,35)?"selected and not ("+a+") or (not selected) and ":this.isBound(this.clickAction,32)?"selected and not ":this.isBound(this.clickAction,34)?"selected or ":0==this.clickAction||this.isBound(this.clickAction,36)?"selected tog ":this.isBound(this.clickAction,30)?"":null;if(null!=b)try{var c=this.viewer.getAtomBitSetEval(null,b+("("+
a+")"));this.viewer.select(c,!1,0,!1);this.viewer.refresh(3,"selections set")}catch(d){if(!Clazz.exceptionOf(d,Exception))throw d;}this.selectionWorking=!1}},$fz.isPrivate=!0,$fz),"~S");$_M(c$,"selectRb",($fz=function(a){var b=this.viewer.findAtomsInRectangle(this.rectRubber);0<b.length()&&(b=J.util.Escape.eBS(b),this.isBound(a,34)?this.runScript("selectionHalos on;select selected or "+b):this.isBound(a,32)?this.runScript("selectionHalos on;select selected and not "+b):this.runScript("selectionHalos on;select selected tog "+
b));this.viewer.refresh(3,"mouseReleased")},$fz.isPrivate=!0,$fz),"~N");$_M(c$,"toggleMeasurement",($fz=function(){if(null!=this.measurementPending){var a=this.measurementPending.getCount();2<=a&&4>=a&&this.runScript("!measure "+this.measurementPending.getMeasurementScript(" ",!0));this.exitMeasurementMode()}},$fz.isPrivate=!0,$fz));$_M(c$,"zoomTo",($fz=function(a){this.runScript("zoomTo (atomindex="+a+")");this.viewer.setStatusAtomPicked(a,null)},$fz.isPrivate=!0,$fz),"~N");Clazz.overrideMethod(c$,
"keyTyped",function(){return!1},"~N,~N");c$.$ActionManager$MotionPoint$=function(){Clazz.pu$h();c$=Clazz.decorateAsClass(function(){Clazz.prepareCallback(this,arguments);this.time=this.y=this.x=this.index=0;Clazz.instantialize(this,arguments)},J.viewer.ActionManager,"MotionPoint");$_M(c$,"set",function(a,b,c,d){this.index=a;this.x=b;this.y=c;this.time=d},"~N,~N,~N,~N");Clazz.overrideMethod(c$,"toString",function(){return"[x = "+this.x+" y = "+this.y+" time = "+this.time+" ]"});c$=Clazz.p0p()};c$.$ActionManager$Gesture$=
function(){Clazz.pu$h();c$=Clazz.decorateAsClass(function(){Clazz.prepareCallback(this,arguments);this.action=0;this.nodes=null;this.time0=this.ptNext=0;Clazz.instantialize(this,arguments)},J.viewer.ActionManager,"Gesture");Clazz.makeConstructor(c$,function(a){this.nodes=Array(a);for(var b=0;b<a;b++)this.nodes[b]=Clazz.innerTypeInstance(J.viewer.ActionManager.MotionPoint,this,null)},"~N");$_M(c$,"setAction",function(a,b){this.action=a;this.ptNext=0;this.time0=b;for(var c=0;c<this.nodes.length;c++)this.nodes[c].index=
-1},"~N,~N");$_M(c$,"getAction",function(){return this.action});$_M(c$,"add",function(a,b,c,d){this.action=a;this.getNode(this.ptNext).set(this.ptNext,b,c,d-this.time0);this.ptNext++;return this.ptNext},"~N,~N,~N,~N");$_M(c$,"getTimeDifference",function(a){a=this.getPointCount2(a,0);if(2>a)return 0;var b=this.getNode(this.ptNext-1);a=this.getNode(this.ptNext-a);return b.time-a.time},"~N");$_M(c$,"getSpeedPixelsPerMillisecond",function(a,b){a=this.getPointCount2(a,b);if(2>a)return 0;var c=this.getNode(this.ptNext-
1-b),d=this.getNode(this.ptNext-a-b),e=360*((c.x-d.x)/this.b$["J.viewer.ActionManager"].viewer.getScreenWidth()),f=360*((c.y-d.y)/this.b$["J.viewer.ActionManager"].viewer.getScreenHeight());return Math.sqrt(e*e+f*f)/(c.time-d.time)},"~N,~N");$_M(c$,"getDX",function(a,b){a=this.getPointCount2(a,b);if(2>a)return 0;var c=this.getNode(this.ptNext-1-b),d=this.getNode(this.ptNext-a-b);return c.x-d.x},"~N,~N");$_M(c$,"getDY",function(a,b){a=this.getPointCount2(a,b);if(2>a)return 0;var c=this.getNode(this.ptNext-
1-b),d=this.getNode(this.ptNext-a-b);return c.y-d.y},"~N,~N");$_M(c$,"getPointCount",function(){return this.ptNext});$_M(c$,"getPointCount2",($fz=function(a,b){a>this.nodes.length-b&&(a=this.nodes.length-b);for(var c=a+1;0<=--c&&!(0<=this.getNode(this.ptNext-c-b).index););return c},$fz.isPrivate=!0,$fz),"~N,~N");$_M(c$,"getNode",function(a){return this.nodes[(a+this.nodes.length+this.nodes.length)%this.nodes.length]},"~N");Clazz.overrideMethod(c$,"toString",function(){return 0==this.nodes.length?
""+this:J.viewer.binding.Binding.getMouseActionName(this.action,!1)+" nPoints = "+this.ptNext+" "+this.nodes[0]});c$=Clazz.p0p()};Clazz.defineStatics(c$,"ACTION_assignNew",0,"ACTION_center",1,"ACTION_clickFrank",2,"ACTION_connectAtoms",3,"ACTION_deleteAtom",4,"ACTION_deleteBond",5,"ACTION_depth",6,"ACTION_dragAtom",7,"ACTION_dragDrawObject",8,"ACTION_dragDrawPoint",9,"ACTION_dragLabel",10,"ACTION_dragMinimize",11,"ACTION_dragMinimizeMolecule",12,"ACTION_dragSelected",13,"ACTION_dragZ",14,"ACTION_multiTouchSimulation",
15,"ACTION_navTranslate",16,"ACTION_pickAtom",17,"ACTION_pickIsosurface",18,"ACTION_pickLabel",19,"ACTION_pickMeasure",20,"ACTION_pickNavigate",21,"ACTION_pickPoint",22,"ACTION_popupMenu",23,"ACTION_reset",24,"ACTION_rotate",25,"ACTION_rotateBranch",26,"ACTION_rotateSelected",27,"ACTION_rotateZ",28,"ACTION_rotateZorZoom",29,"ACTION_select",30,"ACTION_selectAndDrag",31,"ACTION_selectAndNot",32,"ACTION_selectNone",33,"ACTION_selectOr",34,"ACTION_selectToggle",35,"ACTION_selectToggleExtended",36,"ACTION_setMeasure",
37,"ACTION_slab",38,"ACTION_slabAndDepth",39,"ACTION_slideZoom",40,"ACTION_spinDrawObjectCCW",41,"ACTION_spinDrawObjectCW",42,"ACTION_stopMotion",43,"ACTION_swipe",44,"ACTION_translate",45,"ACTION_wheelZoom",46,"ACTION_count",47);c$.actionInfo=c$.prototype.actionInfo=Array(47);c$.actionNames=c$.prototype.actionNames=Array(47);J.viewer.ActionManager.newAction(0,"_assignNew",J.i18n.GT._("assign/new atom or bond (requires {0})","set picking assignAtom_??/assignBond_?"));J.viewer.ActionManager.newAction(1,
"_center",J.i18n.GT._("center"));J.viewer.ActionManager.newAction(2,"_clickFrank",J.i18n.GT._("pop up recent context menu (click on Jmol frank)"));J.viewer.ActionManager.newAction(4,"_deleteAtom",J.i18n.GT._("delete atom (requires {0})","set picking DELETE ATOM"));J.viewer.ActionManager.newAction(5,"_deleteBond",J.i18n.GT._("delete bond (requires {0})","set picking DELETE BOND"));J.viewer.ActionManager.newAction(6,"_depth",J.i18n.GT._("adjust depth (back plane; requires {0})","SLAB ON"));J.viewer.ActionManager.newAction(7,
"_dragAtom",J.i18n.GT._("move atom (requires {0})","set picking DRAGATOM"));J.viewer.ActionManager.newAction(8,"_dragDrawObject",J.i18n.GT._("move whole DRAW object (requires {0})","set picking DRAW"));J.viewer.ActionManager.newAction(9,"_dragDrawPoint",J.i18n.GT._("move specific DRAW point (requires {0})","set picking DRAW"));J.viewer.ActionManager.newAction(10,"_dragLabel",J.i18n.GT._("move label (requires {0})","set picking LABEL"));J.viewer.ActionManager.newAction(11,"_dragMinimize",J.i18n.GT._("move atom and minimize molecule (requires {0})",
"set picking DRAGMINIMIZE"));J.viewer.ActionManager.newAction(12,"_dragMinimizeMolecule",J.i18n.GT._("move and minimize molecule (requires {0})","set picking DRAGMINIMIZEMOLECULE"));J.viewer.ActionManager.newAction(13,"_dragSelected",J.i18n.GT._("move selected atoms (requires {0})","set DRAGSELECTED"));J.viewer.ActionManager.newAction(14,"_dragZ",J.i18n.GT._("drag atoms in Z direction (requires {0})","set DRAGSELECTED"));J.viewer.ActionManager.newAction(15,"_multiTouchSimulation",J.i18n.GT._("simulate multi-touch using the mouse)"));
J.viewer.ActionManager.newAction(16,"_navTranslate",J.i18n.GT._("translate navigation point (requires {0} and {1})",["set NAVIGATIONMODE","set picking NAVIGATE"]));J.viewer.ActionManager.newAction(17,"_pickAtom",J.i18n.GT._("pick an atom"));J.viewer.ActionManager.newAction(3,"_pickConnect",J.i18n.GT._("connect atoms (requires {0})","set picking CONNECT"));J.viewer.ActionManager.newAction(18,"_pickIsosurface",J.i18n.GT._("pick an ISOSURFACE point (requires {0}","set DRAWPICKING"));J.viewer.ActionManager.newAction(19,
"_pickLabel",J.i18n.GT._("pick a label to toggle it hidden/displayed (requires {0})","set picking LABEL"));J.viewer.ActionManager.newAction(20,"_pickMeasure",J.i18n.GT._("pick an atom to include it in a measurement (after starting a measurement or after {0})","set picking DISTANCE/ANGLE/TORSION"));J.viewer.ActionManager.newAction(21,"_pickNavigate",J.i18n.GT._("pick a point or atom to navigate to (requires {0})","set NAVIGATIONMODE"));J.viewer.ActionManager.newAction(22,"_pickPoint",J.i18n.GT._("pick a DRAW point (for measurements) (requires {0}",
"set DRAWPICKING"));J.viewer.ActionManager.newAction(23,"_popupMenu",J.i18n.GT._("pop up the full context menu"));J.viewer.ActionManager.newAction(24,"_reset",J.i18n.GT._("reset (when clicked off the model)"));J.viewer.ActionManager.newAction(25,"_rotate",J.i18n.GT._("rotate"));J.viewer.ActionManager.newAction(26,"_rotateBranch",J.i18n.GT._("rotate branch around bond (requires {0})","set picking ROTATEBOND"));J.viewer.ActionManager.newAction(27,"_rotateSelected",J.i18n.GT._("rotate selected atoms (requires {0})",
"set DRAGSELECTED"));J.viewer.ActionManager.newAction(28,"_rotateZ",J.i18n.GT._("rotate Z"));J.viewer.ActionManager.newAction(29,"_rotateZorZoom",J.i18n.GT._("rotate Z (horizontal motion of mouse) or zoom (vertical motion of mouse)"));J.viewer.ActionManager.newAction(30,"_select",J.i18n.GT._("select an atom (requires {0})","set pickingStyle EXTENDEDSELECT"));J.viewer.ActionManager.newAction(31,"_selectAndDrag",J.i18n.GT._("select and drag atoms (requires {0})","set DRAGSELECTED"));J.viewer.ActionManager.newAction(32,
"_selectAndNot",J.i18n.GT._("unselect this group of atoms (requires {0})","set pickingStyle DRAG/EXTENDEDSELECT"));J.viewer.ActionManager.newAction(33,"_selectNone",J.i18n.GT._("select NONE (requires {0})","set pickingStyle EXTENDEDSELECT"));J.viewer.ActionManager.newAction(34,"_selectOr",J.i18n.GT._("add this group of atoms to the set of selected atoms (requires {0})","set pickingStyle DRAG/EXTENDEDSELECT"));J.viewer.ActionManager.newAction(35,"_selectToggle",J.i18n.GT._("toggle selection (requires {0})",
"set pickingStyle DRAG/EXTENDEDSELECT/RASMOL"));J.viewer.ActionManager.newAction(36,"_selectToggleOr",J.i18n.GT._("if all are selected, unselect all, otherwise add this group of atoms to the set of selected atoms (requires {0})","set pickingStyle DRAG"));J.viewer.ActionManager.newAction(37,"_setMeasure",J.i18n.GT._("pick an atom to initiate or conclude a measurement"));J.viewer.ActionManager.newAction(38,"_slab",J.i18n.GT._("adjust slab (front plane; requires {0})","SLAB ON"));J.viewer.ActionManager.newAction(39,
"_slabAndDepth",J.i18n.GT._("move slab/depth window (both planes; requires {0})","SLAB ON"));J.viewer.ActionManager.newAction(40,"_slideZoom",J.i18n.GT._("zoom (along right edge of window)"));J.viewer.ActionManager.newAction(41,"_spinDrawObjectCCW",J.i18n.GT._("click on two points to spin around axis counterclockwise (requires {0})","set picking SPIN"));J.viewer.ActionManager.newAction(42,"_spinDrawObjectCW",J.i18n.GT._("click on two points to spin around axis clockwise (requires {0})","set picking SPIN"));
J.viewer.ActionManager.newAction(43,"_stopMotion",J.i18n.GT._("stop motion (requires {0})","set waitForMoveTo FALSE"));J.viewer.ActionManager.newAction(44,"_swipe",J.i18n.GT._("spin model (swipe and release button and stop motion simultaneously)"));J.viewer.ActionManager.newAction(45,"_translate",J.i18n.GT._("translate"));J.viewer.ActionManager.newAction(46,"_wheelZoom",J.i18n.GT._("zoom"));Clazz.defineStatics(c$,"PICKING_OFF",0,"PICKING_IDENTIFY",1,"PICKING_LABEL",2,"PICKING_CENTER",3,"PICKING_DRAW",
4,"PICKING_SPIN",5,"PICKING_SYMMETRY",6,"PICKING_DELETE_ATOM",7,"PICKING_DELETE_BOND",8,"PICKING_SELECT_ATOM",9,"PICKING_SELECT_GROUP",10,"PICKING_SELECT_CHAIN",11,"PICKING_SELECT_MOLECULE",12,"PICKING_SELECT_POLYMER",13,"PICKING_SELECT_STRUCTURE",14,"PICKING_SELECT_SITE",15,"PICKING_SELECT_MODEL",16,"PICKING_SELECT_ELEMENT",17,"PICKING_MEASURE",18,"PICKING_MEASURE_DISTANCE",19,"PICKING_MEASURE_ANGLE",20,"PICKING_MEASURE_TORSION",21,"PICKING_MEASURE_SEQUENCE",22,"PICKING_NAVIGATE",23,"PICKING_CONNECT",
24,"PICKING_STRUTS",25,"PICKING_DRAG_SELECTED",26,"PICKING_DRAG_MOLECULE",27,"PICKING_DRAG_ATOM",28,"PICKING_DRAG_MINIMIZE",29,"PICKING_DRAG_MINIMIZE_MOLECULE",30,"PICKING_INVERT_STEREO",31,"PICKING_ASSIGN_ATOM",32,"PICKING_ASSIGN_BOND",33,"PICKING_ROTATE_BOND",34,"PICKING_IDENTIFY_BOND",35,"PICKING_DRAG_LIGAND",36,"pickingModeNames","off identify label center draw spin symmetry deleteatom deletebond atom group chain molecule polymer structure site model element measure distance angle torsion sequence navigate connect struts dragselected dragmolecule dragatom dragminimize dragminimizemolecule invertstereo assignatom assignbond rotatebond identifybond dragligand".split(" "),
"PICKINGSTYLE_SELECT_JMOL",0,"PICKINGSTYLE_SELECT_CHIME",0,"PICKINGSTYLE_SELECT_RASMOL",1,"PICKINGSTYLE_SELECT_PFAAT",2,"PICKINGSTYLE_SELECT_DRAG",3,"PICKINGSTYLE_MEASURE_ON",4,"PICKINGSTYLE_MEASURE_OFF",5,"pickingStyleNames","toggle selectOrToggle extendedSelect drag measure measureoff".split(" "),"MAX_DOUBLE_CLICK_MILLIS",700,"MININUM_GESTURE_DELAY_MILLISECONDS",10,"SLIDE_ZOOM_X_PERCENT",98,"DEFAULT_MOUSE_DRAG_FACTOR",1,"DEFAULT_MOUSE_WHEEL_FACTOR",1.15,"DEFAULT_GESTURE_SWIPE_FACTOR",1)}),Clazz.declarePackage("J.viewer"),
Clazz.load(["java.util.Hashtable","JU.M3","$.P3","J.constant.EnumAxesMode","$.EnumCallback"],"J.viewer.StateManager","java.lang.Boolean $.Float java.util.Arrays JU.BS $.DecimalFormat $.SB J.constant.EnumStructure J.script.SV J.util.BSUtil $.Escape $.Logger $.Txt J.viewer.JC $.Viewer".split(" "),function(){c$=Clazz.decorateAsClass(function(){this.saved=this.viewer=null;this.lastCoordinates=this.lastShape=this.lastState=this.lastSelected=this.lastScene=this.lastConnections=this.lastOrientation="";Clazz.isClassDefined("J.viewer.StateManager.Scene")||
J.viewer.StateManager.$StateManager$Scene$();Clazz.isClassDefined("J.viewer.StateManager.Orientation")||J.viewer.StateManager.$StateManager$Orientation$();Clazz.isClassDefined("J.viewer.StateManager.Connections")||J.viewer.StateManager.$StateManager$Connections$();Clazz.isClassDefined("J.viewer.StateManager.GlobalSettings")||J.viewer.StateManager.$StateManager$GlobalSettings$();Clazz.instantialize(this,arguments)},J.viewer,"StateManager");Clazz.prepareFields(c$,function(){this.saved=new java.util.Hashtable});
c$.getVariableList=$_M(c$,"getVariableList",function(a,b,c,d){var e=new JU.SB,f=0,g=Array(a.size()),h;for(a=a.entrySet().iterator();a.hasNext()&&((h=a.next())||1);){var k=h.getKey(),l=h.getValue();if((c||!k.startsWith("site_"))&&(!d||"@"==k.charAt(0)))g[f++]=k+("@"==k.charAt(0)?" "+l.asString():" = "+J.viewer.StateManager.varClip(k,l.escape(),b))}java.util.Arrays.sort(g,0,f);for(b=0;b<f;b++)null!=g[b]&&e.append("  ").append(g[b]).append(";\n");0==f&&!d&&e.append("# --no global user variables defined--;\n");
return e.toString()},"java.util.Map,~N,~B,~B");c$.getObjectIdFromName=$_M(c$,"getObjectIdFromName",function(a){if(null==a)return-1;a="background axis1      axis2      axis3      boundbox   unitcell   frank      ".indexOf(a.toLowerCase());return 0>a?a:Clazz.doubleToInt(a/11)},"~S");c$.getObjectNameFromId=$_M(c$,"getObjectNameFromId",function(a){return 0>a||8<=a?null:"background axis1      axis2      axis3      boundbox   unitcell   frank      ".substring(11*a,11*a+11).trim()},"~N");Clazz.makeConstructor(c$,
function(a){this.viewer=a},"J.viewer.Viewer");$_M(c$,"getGlobalSettings",function(a,b){this.saved.clear();return Clazz.innerTypeInstance(J.viewer.StateManager.GlobalSettings,this,null,a,b)},"J.viewer.StateManager.GlobalSettings,~B");$_M(c$,"clear",function(a){this.viewer.setShowAxes(!1);this.viewer.setShowBbcage(!1);this.viewer.setShowUnitCell(!1);a.clear()},"J.viewer.StateManager.GlobalSettings");$_M(c$,"setCrystallographicDefaults",function(){this.viewer.setAxesModeUnitCell(!0);this.viewer.setShowAxes(!0);
this.viewer.setShowUnitCell(!0);this.viewer.setBooleanProperty("perspectiveDepth",!1)});$_M(c$,"setCommonDefaults",($fz=function(){this.viewer.setBooleanProperty("perspectiveDepth",!0);this.viewer.setFloatProperty("bondTolerance",0.45);this.viewer.setFloatProperty("minBondDistance",0.4);this.viewer.setBooleanProperty("translucent",!0)},$fz.isPrivate=!0,$fz));$_M(c$,"setJmolDefaults",function(){this.setCommonDefaults();this.viewer.setStringProperty("ColorScheme","Jmol");this.viewer.setBooleanProperty("axesOrientationRasmol",
!1);this.viewer.setBooleanProperty("zeroBasedXyzRasmol",!1);this.viewer.setIntProperty("percentVdwAtom",23);this.viewer.setIntProperty("bondRadiusMilliAngstroms",150);this.viewer.setDefaultVdw("auto")});$_M(c$,"setRasMolDefaults",function(){this.setCommonDefaults();this.viewer.setStringProperty("defaultColorScheme","RasMol");this.viewer.setBooleanProperty("axesOrientationRasmol",!0);this.viewer.setBooleanProperty("zeroBasedXyzRasmol",!0);this.viewer.setIntProperty("percentVdwAtom",0);this.viewer.setIntProperty("bondRadiusMilliAngstroms",
1);this.viewer.setDefaultVdw("Rasmol")});$_M(c$,"setPyMOLDefaults",function(){this.setCommonDefaults();this.viewer.setStringProperty("measurementUnits","ANGSTROMS");this.viewer.setBooleanProperty("zoomHeight",!0)});c$.getNoCase=$_M(c$,"getNoCase",($fz=function(a,b){for(var c,d=a.entrySet().iterator();d.hasNext()&&((c=d.next())||1);)if(c.getKey().equalsIgnoreCase(b))return c.getValue();return null},$fz.isPrivate=!0,$fz),"java.util.Map,~S");$_M(c$,"listSavedStates",function(){for(var a="",b,c=this.saved.keySet().iterator();c.hasNext()&&
((b=c.next())||1);)a+="\n"+b;return a});$_M(c$,"deleteSavedType",($fz=function(a){for(var b=this.saved.keySet().iterator();b.hasNext();)b.next().startsWith(a)&&b.remove()},$fz.isPrivate=!0,$fz),"~S");$_M(c$,"deleteSaved",function(a){this.saved.remove(a)},"~S");$_M(c$,"saveSelection",function(a,b){a.equalsIgnoreCase("DELETE")?this.deleteSavedType("Selected_"):(a=this.lastSelected="Selected_"+a,this.saved.put(a,J.util.BSUtil.copy(b)))},"~S,JU.BS");$_M(c$,"restoreSelection",function(a){a=J.viewer.StateManager.getNoCase(this.saved,
0<a.length?"Selected_"+a:this.lastSelected);if(null==a)return this.viewer.select(new JU.BS,!1,0,!1),!1;this.viewer.select(a,!1,0,!1);return!0},"~S");$_M(c$,"saveState",function(a){a.equalsIgnoreCase("DELETE")?this.deleteSavedType("State_"):(a=this.lastState="State_"+a,this.saved.put(a,this.viewer.getStateInfo()))},"~S");$_M(c$,"getSavedState",function(a){a=J.viewer.StateManager.getNoCase(this.saved,0<a.length?"State_"+a:this.lastState);return null==a?"":a},"~S");$_M(c$,"saveStructure",function(a){a.equalsIgnoreCase("DELETE")?
this.deleteSavedType("Shape_"):(a=this.lastShape="Shape_"+a,this.saved.put(a,this.viewer.getStructureState()))},"~S");$_M(c$,"getSavedStructure",function(a){a=J.viewer.StateManager.getNoCase(this.saved,0<a.length?"Shape_"+a:this.lastShape);return null==a?"":a},"~S");$_M(c$,"saveCoordinates",function(a,b){a.equalsIgnoreCase("DELETE")?this.deleteSavedType("Coordinates_"):(a=this.lastCoordinates="Coordinates_"+a,this.saved.put(a,this.viewer.getCoordinateState(b)))},"~S,JU.BS");$_M(c$,"getSavedCoordinates",
function(a){a=J.viewer.StateManager.getNoCase(this.saved,0<a.length?"Coordinates_"+a:this.lastCoordinates);return null==a?"":a},"~S");$_M(c$,"getOrientation",function(){return Clazz.innerTypeInstance(J.viewer.StateManager.Orientation,this,null,!1,null)});$_M(c$,"getSavedOrientationText",function(a){var b;if(null!=a)return b=this.getOrientationFor(a),null==b?"":b.getMoveToText(!0);a=new JU.SB;for(var c=this.saved.entrySet().iterator();c.hasNext()&&((b=c.next())||1);)b.getKey().startsWith("Orientation_")&&
a.append(b.getValue().getMoveToText(!0));return a.toString()},"~S");$_M(c$,"saveScene",function(a,b){if(a.equalsIgnoreCase("DELETE"))this.deleteSavedType("Scene_");else{var c=Clazz.innerTypeInstance(J.viewer.StateManager.Scene,this,null,b);c.saveName=this.lastScene="Scene_"+a;this.saved.put(c.saveName,c)}},"~S,java.util.Map");$_M(c$,"restoreScene",function(a,b){var c=this.getSceneFor(a);return null!=c&&c.restore(b)},"~S,~N");$_M(c$,"getSceneFor",($fz=function(a){return J.viewer.StateManager.getNoCase(this.saved,
0<a.length?"Scene_"+a:this.lastScene)},$fz.isPrivate=!0,$fz),"~S");$_M(c$,"saveOrientation",function(a,b){if(a.equalsIgnoreCase("DELETE"))this.deleteSavedType("Orientation_");else{var c=Clazz.innerTypeInstance(J.viewer.StateManager.Orientation,this,null,a.equalsIgnoreCase("default"),b);c.saveName=this.lastOrientation="Orientation_"+a;this.saved.put(c.saveName,c)}},"~S,~A");$_M(c$,"restoreOrientation",function(a,b,c){a=this.getOrientationFor(a);return null!=a&&a.restore(b,c)},"~S,~N,~B");$_M(c$,"getOrientationFor",
($fz=function(a){return J.viewer.StateManager.getNoCase(this.saved,0<a.length?"Orientation_"+a:this.lastOrientation)},$fz.isPrivate=!0,$fz),"~S");$_M(c$,"saveBonds",function(a){if(a.equalsIgnoreCase("DELETE"))this.deleteSavedType("Bonds_");else{var b=Clazz.innerTypeInstance(J.viewer.StateManager.Connections,this,null);b.saveName=this.lastConnections="Bonds_"+a;this.saved.put(b.saveName,b)}},"~S");$_M(c$,"restoreBonds",function(a){a=J.viewer.StateManager.getNoCase(this.saved,0<a.length?"Bonds_"+a:
this.lastConnections);return null!=a&&a.restore()},"~S");c$.doReportProperty=$_M(c$,"doReportProperty",function(a){return"_"!=a.charAt(0)&&0>J.viewer.StateManager.unreportedProperties.indexOf(";"+a+";")},"~S");c$.getJmolVersionInt=$_M(c$,"getJmolVersionInt",function(){var a=J.viewer.JC.version,b=-1;try{var c=a.indexOf(".");if(0>c)return b=1E5*Integer.parseInt(a);b=1E5*Integer.parseInt(a.substring(0,c));a=a.substring(c+1);c=a.indexOf(".");if(0>c)return b+=1E3*Integer.parseInt(a);b+=1E3*Integer.parseInt(a.substring(0,
c));a=a.substring(c+1);c=a.indexOf("_");0<=c&&(a=a.substring(0,c));c=a.indexOf(" ");0<=c&&(a=a.substring(0,c));b+=Integer.parseInt(a)}catch(d){if(!Clazz.exceptionOf(d,NumberFormatException))throw d;}return b});c$.varClip=$_M(c$,"varClip",function(a,b,c){0<c&&b.length>c&&(b=b.substring(0,c)+" #...more ("+b.length+" bytes -- use SHOW "+a+" or MESSAGE @"+a+" to view)");return b},"~S,~S,~N");c$.$StateManager$Scene$=function(){Clazz.pu$h();c$=Clazz.decorateAsClass(function(){Clazz.prepareCallback(this,
arguments);this.scene=this.saveName=null;Clazz.instantialize(this,arguments)},J.viewer.StateManager,"Scene");Clazz.makeConstructor(c$,function(a){this.scene=a},"java.util.Map");$_M(c$,"restore",function(a){var b=this.scene.get("generator");null!=b&&b.generateScene(this.scene);b=this.scene.get("pymolView");return null!=b&&this.b$["J.viewer.StateManager"].viewer.movePyMOL(this.b$["J.viewer.StateManager"].viewer.eval,a,b)},"~N");c$=Clazz.p0p()};c$.$StateManager$Orientation$=function(){Clazz.pu$h();c$=
Clazz.decorateAsClass(function(){Clazz.prepareCallback(this,arguments);this.rotationMatrix=this.saveName=null;this.rotationRadius=this.zoom=this.yTrans=this.xTrans=0;this.navCenter=this.center=null;this.cameraY=this.cameraX=this.cameraDepth=this.navDepth=this.yNav=this.xNav=NaN;this.navigationMode=this.windowCenteredFlag=!1;this.pymolView=this.moveToText=null;Clazz.instantialize(this,arguments)},J.viewer.StateManager,"Orientation");Clazz.prepareFields(c$,function(){this.rotationMatrix=new JU.M3;this.center=
new JU.P3;this.navCenter=new JU.P3});Clazz.makeConstructor(c$,function(a,b){if(null!=b)this.pymolView=b,this.moveToText="moveTo -1.0 PyMOL "+J.util.Escape.eAF(b);else{this.b$["J.viewer.StateManager"].viewer.finalizeTransformParameters();if(a){var c=this.b$["J.viewer.StateManager"].viewer.getModelSetAuxiliaryInfoValue("defaultOrientationMatrix");null==c?this.rotationMatrix.setIdentity():this.rotationMatrix.setM(c)}else this.b$["J.viewer.StateManager"].viewer.getRotation(this.rotationMatrix);this.xTrans=
this.b$["J.viewer.StateManager"].viewer.getTranslationXPercent();this.yTrans=this.b$["J.viewer.StateManager"].viewer.getTranslationYPercent();this.zoom=this.b$["J.viewer.StateManager"].viewer.getZoomSetting();this.center.setT(this.b$["J.viewer.StateManager"].viewer.getRotationCenter());this.windowCenteredFlag=this.b$["J.viewer.StateManager"].viewer.isWindowCentered();this.rotationRadius=this.b$["J.viewer.StateManager"].viewer.getFloat(570425388);this.navigationMode=this.b$["J.viewer.StateManager"].viewer.getBoolean(603979887);
this.moveToText=this.b$["J.viewer.StateManager"].viewer.getMoveToText(-1);this.navigationMode&&(this.xNav=this.b$["J.viewer.StateManager"].viewer.getNavigationOffsetPercent("X"),this.yNav=this.b$["J.viewer.StateManager"].viewer.getNavigationOffsetPercent("Y"),this.navDepth=this.b$["J.viewer.StateManager"].viewer.getNavigationDepthPercent(),this.navCenter=JU.P3.newP(this.b$["J.viewer.StateManager"].viewer.getNavigationCenter()));0!=this.b$["J.viewer.StateManager"].viewer.getCamera().z&&(this.cameraDepth=
this.b$["J.viewer.StateManager"].viewer.getCameraDepth(),this.cameraX=this.b$["J.viewer.StateManager"].viewer.getCamera().x,this.cameraY=this.b$["J.viewer.StateManager"].viewer.getCamera().y)}},"~B,~A");$_M(c$,"getMoveToText",function(a){return a?"   "+this.moveToText+"\n  save orientation "+J.util.Escape.eS(this.saveName.substring(12))+";\n":this.moveToText},"~B");$_M(c$,"restore",function(a,b){b?(this.b$["J.viewer.StateManager"].viewer.setBooleanProperty("windowCentered",this.windowCenteredFlag),
this.b$["J.viewer.StateManager"].viewer.setBooleanProperty("navigationMode",this.navigationMode),null==this.pymolView?this.b$["J.viewer.StateManager"].viewer.moveTo(this.b$["J.viewer.StateManager"].viewer.eval,a,this.center,null,NaN,this.rotationMatrix,this.zoom,this.xTrans,this.yTrans,this.rotationRadius,this.navCenter,this.xNav,this.yNav,this.navDepth,this.cameraDepth,this.cameraX,this.cameraY):this.b$["J.viewer.StateManager"].viewer.movePyMOL(this.b$["J.viewer.StateManager"].viewer.eval,a,this.pymolView)):
this.b$["J.viewer.StateManager"].viewer.setRotationMatrix(this.rotationMatrix);return!0},"~N,~B");c$=Clazz.p0p()};c$.$StateManager$Connections$=function(){Clazz.pu$h();c$=Clazz.decorateAsClass(function(){Clazz.prepareCallback(this,arguments);this.saveName=null;this.bondCount=0;this.connections=null;Clazz.instantialize(this,arguments)},J.viewer.StateManager,"Connections");Clazz.makeConstructor(c$,function(){var a=this.b$["J.viewer.StateManager"].viewer.getModelSet();if(null!=a){this.bondCount=a.bondCount;
this.connections=Array(this.bondCount+1);for(var a=a.bonds,b=this.bondCount;0<=--b;){var c=a[b];this.connections[b]=new J.viewer.StateManager.Connection(c.getAtomIndex1(),c.getAtomIndex2(),c.mad,c.colix,c.order,c.getEnergy(),c.getShapeVisibilityFlags())}}});$_M(c$,"restore",function(){var a=this.b$["J.viewer.StateManager"].viewer.getModelSet();if(null==a)return!1;a.deleteAllBonds();for(var b=this.bondCount;0<=--b;){var c=this.connections[b],d=a.getAtomCount();c.atomIndex1>=d||c.atomIndex2>=d||(d=
a.bondAtoms(a.atoms[c.atomIndex1],a.atoms[c.atomIndex2],c.order,c.mad,null,c.energy,!1,!0),d.setColix(c.colix),d.setShapeVisibilityFlags(c.shapeVisibilityFlags))}for(c=this.bondCount;0<=--c;)a.getBondAt(c).setIndex(c);this.b$["J.viewer.StateManager"].viewer.setShapeProperty(1,"reportAll",null);return!0});c$=Clazz.p0p()};c$.$StateManager$GlobalSettings$=function(){Clazz.pu$h();c$=Clazz.decorateAsClass(function(){Clazz.prepareCallback(this,arguments);this.databases=this.htUserVariables=this.htPropertyFlagsRemoved=
this.htBooleanParameterFlags=this.htNonbooleanParameterValues=null;this.ambientPercent=45;this.diffusePercent=84;this.specular=!0;this.specularExponent=6;this.phongExponent=64;this.specularPercent=22;this.specularPower=40;this.zDepth=0;this.zShadePower=3;this.zSlab=50;this.slabByAtom=this.slabByMolecule=!1;this.appendNew=this.allowEmbeddedScripts=!0;this.appletProxy="";this.applySymmetryToBonds=!1;this.atomTypes="";this.autoBond=!0;this.axesOrientationRasmol=!1;this.bondRadiusMilliAngstroms=150;this.bondTolerance=
0.45;this.defaultDirectory="";this.defaultStructureDSSP=!0;this.ptDefaultLattice=null;this.defaultLoadFilter=this.defaultLoadScript="";this.defaultDropScript="zap; load SYNC \"%FILE\";if (%ALLOWCARTOONS && _loadScript == '' && defaultLoadScript == '' && _filetype == 'Pdb') {if ({(protein or nucleic)&*/1.1} && {*/1.1}[1].groupindex != {*/1.1}[0].groupindex){select protein or nucleic;cartoons only;}if ({visible}){color structure}else{wireframe -0.1};if (!{visible}){spacefill 23%};select *}";this.fractionalRelative=
this.forceAutoBond=!1;this.inlineNewlineChar="|";this.pubChemFormat=this.nihResolverFormat=this.smilesUrlFormat=this.nmrPredictFormat=this.nmrUrlFormat=this.loadLigandFormat=this.loadFormat=null;this.edsUrlFormat="http://eds.bmc.uu.se/eds/dfs/%LC13/%LCFILE/%LCFILE.omap";this.edsUrlCutoff="load('http://eds.bmc.uu.se/eds/dfs/%LC13/%LCFILE/%LCFILE.sfdat').lines.find('MAP_SIGMA').split(' ')[2]";this.edsUrlOptions="within 2.0 {*}";this.minBondDistance=0.4;this.minPixelSelRadius=6;this.pdbSequential=this.pdbGetHeader=
this.pdbAddHydrogens=!1;this.percentVdwAtom=23;this.smallMoleculeMaxAtoms=4E4;this.smartAromatic=!0;this.allowMoveAtoms=this.allowRotateSelected=this.legacyHAddition=this.legacyAutoBonding=this.zeroBasedXyzRasmol=!1;this.defaultPerspectiveDepth=!0;this.visualRange=5;this.solventOn=!1;this.defaultTorsionLabel=this.defaultDistanceLabel=this.defaultAngleLabel="%VALUE %UNITS";this.measureAllModels=this.justifyMeasurements=!1;this.minimizationSteps=100;this.minimizationRefresh=!0;this.minimizationSilent=
!1;this.minimizationCriterion=0.001;this.antialiasDisplay=!1;this.displayCellParameters=this.antialiasTranslucent=this.imageState=this.antialiasImages=!0;this.dotsSelectedOnly=!1;this.dotSurface=!0;this.dotDensity=3;this.meshScale=this.dotScale=1;this.isosurfaceKey=this.greyscaleRendering=this.dynamicMeasurements=!1;this.isosurfacePropertySmoothing=!0;this.isosurfacePropertySmoothingPower=7;this.platformSpeed=10;this.repaintWaitMs=1E3;this.showHiddenSelectionHalos=!1;this.showMeasurements=this.showKeyStrokes=
!0;this.showTiming=!1;this.zoomLarge=!0;this.zoomHeight=!1;this.backgroundImageFileName=null;this.hbondsBackbone=this.bondModeOr=this.partialDots=!1;this.hbondsAngleMinimum=90;this.hbondsDistanceMaximum=3.25;this.hbondsRasmol=!0;this.hbondsSolid=!1;this.modeMultipleBond=2;this.showMultipleBonds=this.showHydrogens=!0;this.ssbondsBackbone=!1;this.multipleBondSpacing=-1;this.multipleBondRadiusFactor=0;this.chainCaseSensitive=this.cartoonLadders=this.cartoonFancy=this.cartoonRockets=this.cartoonBaseEdges=
!1;this.hermiteLevel=0;this.rangeSelected=this.highResolutionFlag=!1;this.rasmolHeteroSetting=this.rasmolHydrogenSetting=!0;this.ribbonAspectRatio=16;this.rocketBarrels=this.ribbonBorder=!1;this.sheetSmoothing=1;this.translucent=this.traceAlpha=!0;this.allowGestures=this.twistedSheets=!1;this.allowMultiTouch=this.allowModelkit=!0;this.allowKeyStrokes=!1;this.animationFps=10;this.atomPicking=!0;this.autoFps=!1;this.axesMode=null;this.axesScale=2;this.starScale=0.05;this.bondPicking=!1;this.defaultCameraDepth=
3;this.celShading=!1;this.dataSeparator="~~~";this.debugScript=!1;this.defaultDrawArrowScale=0.5;this.defaultLabelXYZ="%a";this.defaultLabelPDB="%m%r";this.defaultTranslucent=0.5;this.delayMaximumMs=0;this.dipoleScale=1;this.drawFontSize=14;this.drawPicking=this.drawHover=this.dragSelected=this.disablePopupMenu=!1;this.dsspCalcHydrogen=!0;this.energyUnits="kJ";this.exportScale=1;this.helpPath="http://chemapps.stolaf.edu/jmol/docs/index.htm";this.fontScaling=!1;this.fontCaching=!0;this.forceField=
"MMFF";this.helixStep=1;this.hideNameInPopup=!1;this.hoverDelayMs=500;this.loadAtomDataTolerance=0.01;this.logGestures=this.logCommands=!1;this.measureDistanceUnits="nanometers";this.measurementLabels=!0;this.monitorEnergy=this.messageStyleChime=!1;this.multiProcessor=!0;this.pickingSpinRate=10;this.pickLabel="";this.pointGroupDistanceTolerance=0.2;this.pointGroupLinearTolerance=8;this.preserveState=!0;this.propertyColorScheme="roygb";this.quaternionFrame="p";this.saveProteinStructureState=!0;this.solventProbeRadius=
1.2;this.scriptDelay=0;this.statusReporting=this.selectAllModels=!0;this.strandCountForStrands=5;this.strandCountForMeshRibbon=7;this.strutSpacing=6;this.strutLengthMaximum=7;this.strutDefaultRadius=0.3;this.useArcBall=this.strutsMultiple=!1;this.waitForMoveTo=this.useScriptQueue=this.useNumberLocalization=this.useMinimizationThread=!0;this.vectorScale=1;this.vectorSymmetry=!1;this.vibrationScale=this.vibrationPeriod=1;this.navigationPeriodic=this.navigationMode=this.hideNavigationPoint=this.wireframeRotation=
!1;this.navigationSpeed=5;this.showNavigationPointAlways=!1;this.stereoState=null;this.modelKitMode=!1;this.objMad=this.objStateOn=this.objColors=null;this.ellipsoidFill=this.ellipsoidArrows=this.ellipsoidArcs=this.ellipsoidDots=this.ellipsoidAxes=!1;this.ellipsoidBall=!0;this.ellipsoidDotCount=200;this.ellipsoidAxisDiameter=0.02;this.testFlag4=this.testFlag3=this.testFlag2=this.testFlag1=!1;this.structureList=null;this.haveSetStructureList=!1;this.userDatabases=null;Clazz.instantialize(this,arguments)},
J.viewer.StateManager,"GlobalSettings");Clazz.prepareFields(c$,function(){this.htUserVariables=new java.util.Hashtable;this.ptDefaultLattice=new JU.P3;this.axesMode=J.constant.EnumAxesMode.BOUNDBOX;this.objColors=Clazz.newIntArray(8,0);this.objStateOn=Clazz.newBooleanArray(8,!1);this.objMad=Clazz.newIntArray(8,0);this.structureList=new java.util.Hashtable;this.structureList.put(J.constant.EnumStructure.TURN,[30,90,-15,95]);this.structureList.put(J.constant.EnumStructure.SHEET,[-180,-10,70,180,-180,
-45,-180,-130,140,180,90,180]);this.structureList.put(J.constant.EnumStructure.HELIX,[-160,0,-100,45])});Clazz.makeConstructor(c$,function(a,b){this.registerAllValues(a,b)},"J.viewer.StateManager.GlobalSettings,~B");$_M(c$,"clear",function(){for(var a=this.htUserVariables.keySet().iterator();a.hasNext();){var b=a.next();("@"==b.charAt(0)||b.startsWith("site_"))&&a.remove()}this.setPicked(-1);this.setI("_atomhovered",-1);this.setS("_pickinfo","");this.setB("selectionhalos",!1);this.setB("hidenotselected",
!1);this.setB("measurementlabels",this.measurementLabels=!0);this.setB("drawHover",this.drawHover=!1);this.b$["J.viewer.StateManager"].saveScene("DELETE",null)});$_M(c$,"registerAllValues",function(a,b){this.htNonbooleanParameterValues=new java.util.Hashtable;this.htBooleanParameterFlags=new java.util.Hashtable;this.htPropertyFlagsRemoved=new java.util.Hashtable;null!=a&&(b||(this.htUserVariables=a.htUserVariables),this.debugScript=a.debugScript,this.disablePopupMenu=a.disablePopupMenu,this.messageStyleChime=
a.messageStyleChime,this.defaultDirectory=a.defaultDirectory,this.allowGestures=a.allowGestures,this.allowModelkit=a.allowModelkit,this.allowMultiTouch=a.allowMultiTouch,this.allowKeyStrokes=a.allowKeyStrokes,this.legacyAutoBonding=a.legacyAutoBonding,this.legacyHAddition=a.legacyHAddition,this.platformSpeed=a.platformSpeed,this.useScriptQueue=a.useScriptQueue,this.useArcBall=a.useArcBall,this.databases=a.databases,this.showTiming=a.showTiming,this.wireframeRotation=a.wireframeRotation);null==this.databases&&
(this.databases=new java.util.Hashtable,this.getDataBaseList(J.viewer.JC.databases),this.getDataBaseList(this.userDatabases));this.loadFormat=this.databases.get("pdb");this.loadLigandFormat=this.databases.get("ligand");this.nmrUrlFormat=this.databases.get("nmr");this.nmrPredictFormat=this.databases.get("nmrdb");this.smilesUrlFormat=this.databases.get("nci")+"/file?format=sdf&get3d=True";this.nihResolverFormat=this.databases.get("nci");this.pubChemFormat=this.databases.get("pubchem");for(var c,d=0,
e=J.constant.EnumCallback.values();d<e.length&&((c=e[d])||1);d++)this.resetValue(c.name()+"Callback",a);this.setI("historyLevel",0);this.setI("depth",0);this.setF("gestureSwipeFactor",1);this.setB("hideNotSelected",!1);this.setS("hoverLabel","");this.setB("isKiosk",this.b$["J.viewer.StateManager"].viewer.isKiosk());this.setS("logFile",this.b$["J.viewer.StateManager"].viewer.getLogFileName());this.setI("logLevel",J.util.Logger.getLogLevel());this.setF("mouseWheelFactor",1.15);this.setF("mouseDragFactor",
1);this.setI("navFps",10);this.setI("navigationDepth",0);this.setI("navigationSlab",0);this.setI("navX",0);this.setI("navY",0);this.setI("navZ",0);this.setS("pathForAllFiles","");this.setI("perspectiveModel",11);this.setS("picking","identify");this.setS("pickingStyle","toggle");this.setB("refreshing",!0);this.setI("rotationRadius",0);this.setI("scaleAngstromsPerInch",0);this.setI("scriptReportingLevel",0);this.setB("selectionHalos",!1);this.setB("showaxes",!1);this.setB("showboundbox",!1);this.setB("showfrank",
!1);this.setB("showUnitcell",!1);this.setI("slab",100);this.setB("slabEnabled",!1);this.setF("slabrange",0);this.setI("spinX",0);this.setI("spinY",30);this.setI("spinZ",0);this.setI("spinFps",30);this.setI("stereoDegrees",-5);this.setI("stateversion",0);this.setB("syncScript",this.b$["J.viewer.StateManager"].viewer.getStatusManager().syncingScripts);this.setB("syncMouse",this.b$["J.viewer.StateManager"].viewer.getStatusManager().syncingMouse);this.setB("syncStereo",this.b$["J.viewer.StateManager"].viewer.getStatusManager().stereoSync);
this.setB("windowCentered",!0);this.setB("zoomEnabled",!0);this.setI("zDepth",0);this.setB("zShade",!1);this.setI("zSlab",50);this.setI("_version",J.viewer.StateManager.getJmolVersionInt());this.setB("axesWindow",!0);this.setB("axesMolecular",!1);this.setB("axesPosition",!1);this.setB("axesUnitcell",!1);this.setI("backgroundModel",0);this.setB("colorRasmol",!1);this.setS("currentLocalPath","");this.setS("defaultLattice","{0 0 0}");this.setS("defaultColorScheme","Jmol");this.setS("defaultDirectoryLocal",
"");this.setS("defaults","Jmol");this.setS("defaultVDW","Jmol");this.setS("exportDrivers","Idtf;Maya;Povray;Vrml;X3d;Tachyon;Obj");this.setI("propertyAtomNumberColumnCount",0);this.setI("propertyAtomNumberField",0);this.setI("propertyDataColumnCount",0);this.setI("propertyDataField",0);this.setB("undo",!0);this.setB("allowEmbeddedScripts",this.allowEmbeddedScripts);this.setB("allowGestures",this.allowGestures);this.setB("allowKeyStrokes",this.allowKeyStrokes);this.setB("allowModelkit",this.allowModelkit);
this.setB("allowMultiTouch",this.allowMultiTouch);this.setB("allowRotateSelected",this.allowRotateSelected);this.setB("allowMoveAtoms",this.allowMoveAtoms);this.setI("ambientPercent",this.ambientPercent);this.setI("animationFps",this.animationFps);this.setB("antialiasImages",this.antialiasImages);this.setB("antialiasDisplay",this.antialiasDisplay);this.setB("antialiasTranslucent",this.antialiasTranslucent);this.setB("appendNew",this.appendNew);this.setS("appletProxy",this.appletProxy);this.setB("applySymmetryToBonds",
this.applySymmetryToBonds);this.setB("atomPicking",this.atomPicking);this.setS("atomTypes",this.atomTypes);this.setB("autoBond",this.autoBond);this.setB("autoFps",this.autoFps);this.setI("axesMode",this.axesMode.getCode());this.setF("axesScale",this.axesScale);this.setB("axesOrientationRasmol",this.axesOrientationRasmol);this.setB("bondModeOr",this.bondModeOr);this.setB("bondPicking",this.bondPicking);this.setI("bondRadiusMilliAngstroms",this.bondRadiusMilliAngstroms);this.setF("bondTolerance",this.bondTolerance);
this.setF("cameraDepth",this.defaultCameraDepth);this.setB("cartoonBaseEdges",this.cartoonBaseEdges);this.setB("cartoonFancy",this.cartoonFancy);this.setB("cartoonLadders",this.cartoonLadders);this.setB("cartoonRockets",this.cartoonRockets);this.setB("chainCaseSensitive",this.chainCaseSensitive);this.setB("celShading",this.celShading);this.setS("dataSeparator",this.dataSeparator);this.setB("debugScript",this.debugScript);this.setS("defaultAngleLabel",this.defaultAngleLabel);this.setF("defaultDrawArrowScale",
this.defaultDrawArrowScale);this.setS("defaultDirectory",this.defaultDirectory);this.setS("defaultDistanceLabel",this.defaultDistanceLabel);this.setS("defaultDropScript",this.defaultDropScript);this.setS("defaultLabelPDB",this.defaultLabelPDB);this.setS("defaultLabelXYZ",this.defaultLabelXYZ);this.setS("defaultLoadFilter",this.defaultLoadFilter);this.setS("defaultLoadScript",this.defaultLoadScript);this.setB("defaultStructureDSSP",this.defaultStructureDSSP);this.setS("defaultTorsionLabel",this.defaultTorsionLabel);
this.setF("defaultTranslucent",this.defaultTranslucent);this.setI("delayMaximumMs",this.delayMaximumMs);this.setI("diffusePercent",this.diffusePercent);this.setF("dipoleScale",this.dipoleScale);this.setB("disablePopupMenu",this.disablePopupMenu);this.setB("displayCellParameters",this.displayCellParameters);this.setI("dotDensity",this.dotDensity);this.setI("dotScale",this.dotScale);this.setB("dotsSelectedOnly",this.dotsSelectedOnly);this.setB("dotSurface",this.dotSurface);this.setB("dragSelected",
this.dragSelected);this.setB("drawHover",this.drawHover);this.setF("drawFontSize",this.drawFontSize);this.setB("drawPicking",this.drawPicking);this.setB("dsspCalculateHydrogenAlways",this.dsspCalcHydrogen);this.setB("dynamicMeasurements",this.dynamicMeasurements);this.setS("edsUrlFormat",this.edsUrlFormat);this.setS("edsUrlCutoff",this.edsUrlCutoff);this.setB("ellipsoidArcs",this.ellipsoidArcs);this.setB("ellipsoidArrows",this.ellipsoidArrows);this.setB("ellipsoidAxes",this.ellipsoidAxes);this.setF("ellipsoidAxisDiameter",
this.ellipsoidAxisDiameter);this.setB("ellipsoidBall",this.ellipsoidBall);this.setI("ellipsoidDotCount",this.ellipsoidDotCount);this.setB("ellipsoidDots",this.ellipsoidDots);this.setB("ellipsoidFill",this.ellipsoidFill);this.setS("energyUnits",this.energyUnits);this.setF("exportScale",this.exportScale);this.setB("fontScaling",this.fontScaling);this.setB("fontCaching",this.fontCaching);this.setB("forceAutoBond",this.forceAutoBond);this.setS("forceField",this.forceField);this.setB("fractionalRelative",
this.fractionalRelative);this.setB("greyscaleRendering",this.greyscaleRendering);this.setF("hbondsAngleMinimum",this.hbondsAngleMinimum);this.setF("hbondsDistanceMaximum",this.hbondsDistanceMaximum);this.setB("hbondsBackbone",this.hbondsBackbone);this.setB("hbondsRasmol",this.hbondsRasmol);this.setB("hbondsSolid",this.hbondsSolid);this.setI("helixStep",this.helixStep);this.setS("helpPath",this.helpPath);this.setI("hermiteLevel",this.hermiteLevel);this.setB("hideNameInPopup",this.hideNameInPopup);
this.setB("hideNavigationPoint",this.hideNavigationPoint);this.setB("highResolution",this.highResolutionFlag);this.setF("hoverDelay",this.hoverDelayMs/1E3);this.setB("imageState",this.imageState);this.setB("isosurfaceKey",this.isosurfaceKey);this.setB("isosurfacePropertySmoothing",this.isosurfacePropertySmoothing);this.setI("isosurfacePropertySmoothingPower",this.isosurfacePropertySmoothingPower);this.setB("justifyMeasurements",this.justifyMeasurements);this.setB("legacyAutoBonding",this.legacyAutoBonding);
this.setB("legacyHAddition",this.legacyHAddition);this.setF("loadAtomDataTolerance",this.loadAtomDataTolerance);this.setS("loadFormat",this.loadFormat);this.setS("loadLigandFormat",this.loadLigandFormat);this.setB("logCommands",this.logCommands);this.setB("logGestures",this.logGestures);this.setB("measureAllModels",this.measureAllModels);this.setB("measurementLabels",this.measurementLabels);this.setS("measurementUnits",this.measureDistanceUnits);this.setI("meshScale",this.meshScale);this.setB("messageStyleChime",
this.messageStyleChime);this.setF("minBondDistance",this.minBondDistance);this.setI("minPixelSelRadius",this.minPixelSelRadius);this.setI("minimizationSteps",this.minimizationSteps);this.setB("minimizationRefresh",this.minimizationRefresh);this.setB("minimizationSilent",this.minimizationSilent);this.setF("minimizationCriterion",this.minimizationCriterion);this.setB("modelKitMode",this.modelKitMode);this.setB("monitorEnergy",this.monitorEnergy);this.setF("multipleBondRadiusFactor",this.multipleBondRadiusFactor);
this.setF("multipleBondSpacing",this.multipleBondSpacing);this.setB("multiProcessor",this.multiProcessor&&1<J.viewer.Viewer.nProcessors);this.setB("navigationMode",this.navigationMode);this.setB("navigationPeriodic",this.navigationPeriodic);this.setF("navigationSpeed",this.navigationSpeed);this.setS("nmrPredictFormat",this.nmrPredictFormat);this.setS("nmrUrlFormat",this.nmrUrlFormat);this.setB("partialDots",this.partialDots);this.setB("pdbAddHydrogens",this.pdbAddHydrogens);this.setB("pdbGetHeader",
this.pdbGetHeader);this.setB("pdbSequential",this.pdbSequential);this.setB("perspectiveDepth",this.defaultPerspectiveDepth);this.setI("percentVdwAtom",this.percentVdwAtom);this.setI("phongExponent",this.phongExponent);this.setI("pickingSpinRate",this.pickingSpinRate);this.setS("pickLabel",this.pickLabel);this.setI("platformSpeed",this.platformSpeed);this.setF("pointGroupLinearTolerance",this.pointGroupLinearTolerance);this.setF("pointGroupDistanceTolerance",this.pointGroupDistanceTolerance);this.setB("preserveState",
this.preserveState);this.setS("propertyColorScheme",this.propertyColorScheme);this.setS("quaternionFrame",this.quaternionFrame);this.setB("rangeSelected",this.rangeSelected);this.setI("repaintWaitMs",this.repaintWaitMs);this.setI("ribbonAspectRatio",this.ribbonAspectRatio);this.setB("ribbonBorder",this.ribbonBorder);this.setB("rocketBarrels",this.rocketBarrels);this.setB("saveProteinStructureState",this.saveProteinStructureState);this.setB("scriptqueue",this.useScriptQueue);this.setB("selectAllModels",
this.selectAllModels);this.setB("selectHetero",this.rasmolHeteroSetting);this.setB("selectHydrogen",this.rasmolHydrogenSetting);this.setF("sheetSmoothing",this.sheetSmoothing);this.setB("showHiddenSelectionHalos",this.showHiddenSelectionHalos);this.setB("showHydrogens",this.showHydrogens);this.setB("showKeyStrokes",this.showKeyStrokes);this.setB("showMeasurements",this.showMeasurements);this.setB("showMultipleBonds",this.showMultipleBonds);this.setB("showNavigationPointAlways",this.showNavigationPointAlways);
this.setI("showScript",this.scriptDelay);this.setB("showtiming",this.showTiming);this.setB("slabByMolecule",this.slabByMolecule);this.setB("slabByAtom",this.slabByAtom);this.setB("smartAromatic",this.smartAromatic);this.setI("smallMoleculeMaxAtoms",this.smallMoleculeMaxAtoms);this.setS("smilesUrlFormat",this.smilesUrlFormat);this.setS("nihResolverFormat",this.nihResolverFormat);this.setS("pubChemFormat",this.pubChemFormat);this.setB("solventProbe",this.solventOn);this.setF("solventProbeRadius",this.solventProbeRadius);
this.setB("specular",this.specular);this.setI("specularExponent",this.specularExponent);this.setI("specularPercent",this.specularPercent);this.setI("specularPower",this.specularPower);this.setB("ssbondsBackbone",this.ssbondsBackbone);this.setF("starScale",this.starScale);this.setB("statusReporting",this.statusReporting);this.setI("strandCount",this.strandCountForStrands);this.setI("strandCountForStrands",this.strandCountForStrands);this.setI("strandCountForMeshRibbon",this.strandCountForMeshRibbon);
this.setF("strutDefaultRadius",this.strutDefaultRadius);this.setF("strutLengthMaximum",this.strutLengthMaximum);this.setI("strutSpacing",this.strutSpacing);this.setB("strutsMultiple",this.strutsMultiple);this.setB("testFlag1",this.testFlag1);this.setB("testFlag2",this.testFlag2);this.setB("testFlag3",this.testFlag3);this.setB("testFlag4",this.testFlag4);this.setB("traceAlpha",this.traceAlpha);this.setB("translucent",this.translucent);this.setB("twistedSheets",this.twistedSheets);this.setB("useArcBall",
this.useArcBall);this.setB("useMinimizationThread",this.useMinimizationThread);this.setB("useNumberLocalization",this.useNumberLocalization);this.setF("vectorScale",this.vectorScale);this.setB("vectorSymmetry",this.vectorSymmetry);this.setF("vibrationPeriod",this.vibrationPeriod);this.setF("vibrationScale",this.vibrationScale);this.setF("visualRange",this.visualRange);this.setB("waitForMoveTo",this.waitForMoveTo);this.setB("wireframeRotation",this.wireframeRotation);this.setI("zDepth",this.zDepth);
this.setB("zeroBasedXyzRasmol",this.zeroBasedXyzRasmol);this.setB("zoomHeight",this.zoomHeight);this.setB("zoomLarge",this.zoomLarge);this.setI("zShadePower",this.zShadePower);this.setI("zSlab",this.zSlab)},"J.viewer.StateManager.GlobalSettings,~B");$_M(c$,"setDefaultLattice",function(a){this.ptDefaultLattice.setT(a)},"JU.P3");$_M(c$,"getDefaultLattice",function(){return this.ptDefaultLattice});$_M(c$,"setUnits",function(a){var b=this.measureDistanceUnits,c=this.energyUnits;a.equalsIgnoreCase("angstroms")?
this.measureDistanceUnits="angstroms":a.equalsIgnoreCase("nanometers")||a.equalsIgnoreCase("nm")?this.measureDistanceUnits="nanometers":a.equalsIgnoreCase("picometers")||a.equalsIgnoreCase("pm")?this.measureDistanceUnits="picometers":a.equalsIgnoreCase("bohr")||a.equalsIgnoreCase("au")?this.measureDistanceUnits="au":a.equalsIgnoreCase("vanderwaals")||a.equalsIgnoreCase("vdw")?this.measureDistanceUnits="vdw":a.toLowerCase().endsWith("hz")||a.toLowerCase().endsWith("khz")?this.measureDistanceUnits=
a.toLowerCase():a.equalsIgnoreCase("kj")?this.energyUnits="kJ":a.equalsIgnoreCase("kcal")&&(this.energyUnits="kcal");b.equalsIgnoreCase(this.measureDistanceUnits)?c.equalsIgnoreCase(this.energyUnits)||this.setS("energyUnits",this.energyUnits):this.setS("measurementUnits",this.measureDistanceUnits)},"~S");$_M(c$,"isJmolVariable",function(a){return"_"==a.charAt(0)||this.htNonbooleanParameterValues.containsKey(a=a.toLowerCase())||this.htBooleanParameterFlags.containsKey(a)||0<=J.viewer.StateManager.unreportedProperties.indexOf(";"+
a+";")},"~S");$_M(c$,"resetValue",($fz=function(a,b){this.setS(a,null==b?"":b.getParameter(a))},$fz.isPrivate=!0,$fz),"~S,J.viewer.StateManager.GlobalSettings");$_M(c$,"setB",function(a,b){a=a.toLowerCase();this.htNonbooleanParameterValues.containsKey(a)||this.htBooleanParameterFlags.put(a,b?Boolean.TRUE:Boolean.FALSE)},"~S,~B");$_M(c$,"setI",function(a,b){a=a.toLowerCase();this.htBooleanParameterFlags.containsKey(a)||this.htNonbooleanParameterValues.put(a,Integer.$valueOf(b))},"~S,~N");$_M(c$,"setF",
function(a,b){Float.isNaN(b)||(a=a.toLowerCase(),this.htBooleanParameterFlags.containsKey(a)||this.htNonbooleanParameterValues.put(a,Float.$valueOf(b)))},"~S,~N");$_M(c$,"setS",function(a,b){a=a.toLowerCase();null==b||this.htBooleanParameterFlags.containsKey(a)||this.htNonbooleanParameterValues.put(a,b)},"~S,~S");$_M(c$,"removeParam",function(a){a=a.toLowerCase();this.htBooleanParameterFlags.containsKey(a)?(this.htBooleanParameterFlags.remove(a),this.htPropertyFlagsRemoved.containsKey(a)||this.htPropertyFlagsRemoved.put(a,
Boolean.FALSE)):this.htNonbooleanParameterValues.containsKey(a)&&this.htNonbooleanParameterValues.remove(a)},"~S");$_M(c$,"setUserVariable",function(a,b){if(null==b)return null;a=a.toLowerCase();this.htUserVariables.put(a,b.setName(a).setGlobal());return b},"~S,J.script.SV");$_M(c$,"unsetUserVariable",function(a){a.equals("all")||a.equals("variables")?(this.htUserVariables.clear(),J.util.Logger.info("all user-defined variables deleted")):this.htUserVariables.containsKey(a)&&(J.util.Logger.info("variable "+
a+" deleted"),this.htUserVariables.remove(a))},"~S");$_M(c$,"removeUserVariable",function(a){this.htUserVariables.remove(a)},"~S");$_M(c$,"getUserVariable",function(a){if(null==a)return null;a=a.toLowerCase();return this.htUserVariables.get(a)},"~S");$_M(c$,"getParameterEscaped",function(a,b){a=a.toLowerCase();if(this.htNonbooleanParameterValues.containsKey(a)){var c=this.htNonbooleanParameterValues.get(a);return J.viewer.StateManager.varClip(a,J.util.Escape.e(c),b)}return this.htBooleanParameterFlags.containsKey(a)?
this.htBooleanParameterFlags.get(a).toString():this.htUserVariables.containsKey(a)?this.htUserVariables.get(a).escape():this.htPropertyFlagsRemoved.containsKey(a)?"false":"<not defined>"},"~S,~N");$_M(c$,"getParameter",function(a){a=this.getParam(a,!1);return null==a?"":a},"~S");$_M(c$,"getOrSetNewVariable",function(a,b){if(null==a||0==a.length)a="x";var c=this.getParam(a,!0);return null==c&&b&&"_"!=a.charAt(0)?this.setUserVariable(a,J.script.SV.newVariable(4,"")):J.script.SV.getVariable(c)},"~S,~B");
$_M(c$,"getParam",function(a,b){a=a.toLowerCase();if(a.equals("_memory")){var c=0,c=JU.DecimalFormat.formatDecimal(c-0,1)+"/"+JU.DecimalFormat.formatDecimal(c,1);this.htNonbooleanParameterValues.put("_memory",c)}return this.htNonbooleanParameterValues.containsKey(a)?this.htNonbooleanParameterValues.get(a):this.htBooleanParameterFlags.containsKey(a)?this.htBooleanParameterFlags.get(a):this.htPropertyFlagsRemoved.containsKey(a)?Boolean.FALSE:this.htUserVariables.containsKey(a)?(c=this.htUserVariables.get(a),
b?c:J.script.SV.oValue(c)):null},"~S,~B");$_M(c$,"getVariableList",function(){return J.viewer.StateManager.getVariableList(this.htUserVariables,0,!0,!1)});$_M(c$,"setStructureList",function(a,b){this.haveSetStructureList=!0;this.structureList.put(b,a)},"~A,J.constant.EnumStructure");$_M(c$,"getStructureList",function(){return this.structureList});$_M(c$,"setPicked",function(a){var b=null;0<=a&&(this.setI("_atompicked",a),b=this.getParam("picked",!0));if(null==b||10!=b.tok)b=J.script.SV.newVariable(10,
new JU.BS),this.setUserVariable("picked",b);0<=a&&J.script.SV.getBitSet(b,!1).set(a)},"~N");$_M(c$,"resolveDataBase",function(a,b){var c=this.databases.get(a.toLowerCase());if(null==c)return null;0>b.indexOf("/")&&(a.equals("pubchem")?b="name/"+b:a.equals("nci")&&(b+="/file?format=sdf&get3d=True"));return 0>c.indexOf("%FILE")?c+b:J.util.Txt.formatStringS(c,"FILE",b)},"~S,~S");$_M(c$,"getDataBaseList",($fz=function(a){if(null!=a)for(var b=0;b<a.length;b+=2)this.databases.put(a[b].toLowerCase(),a[b+
1])},$fz.isPrivate=!0,$fz),"~A");c$=Clazz.p0p()};Clazz.pu$h();c$=Clazz.decorateAsClass(function(){this.shapeVisibilityFlags=this.energy=this.order=this.colix=this.mad=this.atomIndex2=this.atomIndex1=0;Clazz.instantialize(this,arguments)},J.viewer.StateManager,"Connection");Clazz.makeConstructor(c$,function(a,b,c,d,e,f,g){this.atomIndex1=a;this.atomIndex2=b;this.mad=c;this.colix=d;this.order=e;this.energy=f;this.shapeVisibilityFlags=g},"~N,~N,~N,~N,~N,~N,~N");c$=Clazz.p0p();Clazz.defineStatics(c$,
"OBJ_BACKGROUND",0,"OBJ_AXIS1",1,"OBJ_AXIS2",2,"OBJ_AXIS3",3,"OBJ_BOUNDBOX",4,"OBJ_UNITCELL",5,"OBJ_FRANK",6,"OBJ_MAX",8,"objectNameList","background axis1      axis2      axis3      boundbox   unitcell   frank      ");c$.unreportedProperties=c$.prototype.unreportedProperties=(";ambientpercent;animationfps;antialiasdisplay;antialiasimages;antialiastranslucent;appendnew;axescolor;axesposition;axesmolecular;axesorientationrasmol;axesunitcell;axeswindow;axis1color;axis2color;axis3color;backgroundcolor;backgroundmodel;bondsymmetryatoms;boundboxcolor;cameradepth;debug;debugscript;defaultlatttice;defaults;defaultdropscript;diffusepercent;;exportdrivers;exportscale;_filecaching;_filecache;fontcaching;fontscaling;forcefield;language;legacyautobonding;legacyhaddition;loglevel;logfile;loggestures;logcommands;measurestylechime;loadformat;loadligandformat;smilesurlformat;pubchemformat;nihresolverformat;edsurlformat;edsurlcutoff;multiprocessor;navigationmode;;pathforallfiles;perspectivedepth;phongexponent;perspectivemodel;platformspeed;preservestate;refreshing;repaintwaitms;rotationradius;showaxes;showaxis1;showaxis2;showaxis3;showboundbox;showfrank;showtiming;showunitcell;slabenabled;slab;slabrange;depth;zshade;zshadepower;specular;specularexponent;specularpercent;celshading;specularpower;stateversion;statusreporting;stereo;stereostate;vibrationperiod;unitcellcolor;visualrange;windowcentered;zerobasedxyzrasmol;zoomenabled;mousedragfactor;mousewheelfactor;scriptqueue;scriptreportinglevel;syncscript;syncmouse;syncstereo;;defaultdirectory;currentlocalpath;defaultdirectorylocal;ambient;bonds;colorrasmol;diffuse;frank;hetero;hidenotselected;hoverlabel;hydrogen;languagetranslation;measurementunits;navigationdepth;navigationslab;picking;pickingstyle;propertycolorschemeoverload;radius;rgbblue;rgbgreen;rgbred;scaleangstromsperinch;selectionhalos;showscript;showselections;solvent;strandcount;spinx;spiny;spinz;spinfps;navx;navy;navz;navfps;"+
J.constant.EnumCallback.getNameList()+";undo;bondpicking;modelkitmode;allowgestures;allowkeystrokes;allowmultitouch;allowmodelkit;").toLowerCase()}),Clazz.declarePackage("J.modelset"),Clazz.load(["J.modelset.Measurement"],"J.modelset.MeasurementPending",null,function(){c$=Clazz.decorateAsClass(function(){this.$haveModified=this.$haveTarget=!1;this.numSet=0;this.lastIndex=-1;Clazz.instantialize(this,arguments)},J.modelset,"MeasurementPending",J.modelset.Measurement);$_M(c$,"haveTarget",function(){return this.$haveTarget});
$_M(c$,"haveModified",function(){return this.$haveModified});$_M(c$,"getNumSet",function(){return this.numSet});$_M(c$,"set",function(a){return this.setM(a,null,NaN,0,null,0)},"J.modelset.ModelSet");$_M(c$,"checkPoint",($fz=function(a){for(var b=1;b<=this.numSet;b++)if(this.countPlusIndices[b]==-1-b&&0.01>this.pts[b-1].distance(a))return!1;return!0},$fz.isPrivate=!0,$fz),"J.util.Point3fi");$_M(c$,"getIndexOf",function(a){for(var b=1;b<=this.numSet;b++)if(this.countPlusIndices[b]==a)return b;return 0},
"~N");Clazz.overrideMethod(c$,"setCount",function(a){this.setCountM(a);this.numSet=a},"~N");$_M(c$,"addPoint",function(a,b,c){System.out.println("addPoint "+a);this.$haveModified=a!=this.lastIndex;this.lastIndex=a;if(null==b){if(0<this.getIndexOf(a))return c&&(this.numSet=this.count),this.count;this.$haveTarget=0<=a;if(!this.$haveTarget)return this.count=this.numSet;this.count=this.numSet+1;this.countPlusIndices[this.count]=a}else{if(!this.checkPoint(b))return c&&(this.numSet=this.count),this.count;
a=this.numSet;this.$haveModified=this.$haveTarget=!0;this.count=this.numSet+1;this.pts[a]=b;this.countPlusIndices[this.count]=-2-a}this.countPlusIndices[0]=this.count;c&&(this.numSet=this.count);this.value=this.getMeasurement();this.strFormat=null;this.formatMeasurement(null);return this.count},"~N,J.util.Point3fi,~B")}),Clazz.declarePackage("J.thread"),Clazz.load(["J.thread.JmolThread"],"J.thread.HoverWatcherThread",["java.lang.Thread"],function(){c$=Clazz.decorateAsClass(function(){this.moved=this.current=
this.actionManager=null;this.hoverDelay=0;Clazz.instantialize(this,arguments)},J.thread,"HoverWatcherThread",J.thread.JmolThread);Clazz.makeConstructor(c$,function(a,b,c,d){Clazz.superConstructor(this,J.thread.HoverWatcherThread);this.setViewer(d,"HoverWatcher");this.actionManager=a;this.current=b;this.moved=c;this.start()},"J.viewer.ActionManager,J.viewer.MouseState,J.viewer.MouseState,J.viewer.Viewer");Clazz.overrideMethod(c$,"run1",function(a){for(;;)switch(a){case -1:this.isJS||Thread.currentThread().setPriority(1);
a=0;break;case 0:this.hoverDelay=this.viewer.getHoverDelay();if(this.stopped||0>=this.hoverDelay||!this.runSleep(this.hoverDelay,1))return;a=1;break;case 1:this.moved.is(this.current)&&(this.currentTime=System.currentTimeMillis(),this.currentTime-this.moved.time>this.hoverDelay&&!this.stopped&&this.actionManager.checkHover()),a=0}},"~N")}),Clazz.declarePackage("J.viewer.binding"),Clazz.load(["java.util.Hashtable"],"J.viewer.binding.Binding","java.lang.Boolean java.util.Arrays JU.List $.SB J.api.Interface J.util.Escape $.Logger $.Txt".split(" "),
function(){c$=Clazz.decorateAsClass(function(){this.bindings=this.name=null;Clazz.instantialize(this,arguments)},J.viewer.binding,"Binding");Clazz.prepareFields(c$,function(){this.bindings=new java.util.Hashtable});c$.getMouseAction=$_M(c$,"getMouseAction",function(a,b,c){2<a&&(a=2);switch(a){case 0:break;case 1:a=256;break;default:a=512}switch(c){case 4:c=4096;break;case 1:c=8192;break;case 5:c=16384;break;case 2:c=32768;break;case 3:c=32}return b&63|a|c},"~N,~N,~N");c$.getMouseActionStr=$_M(c$,
"getMouseActionStr",function(a){if(null==a)return 0;var b=0;a=a.toUpperCase();b=0<=a.indexOf("MIDDLE")?8:0<=a.indexOf("RIGHT")?4:0<=a.indexOf("WHEEL")?32:16;b=0<=a.indexOf("DOWN")?b|4096:0<=a.indexOf("DRAG")?b|8192:0<=a.indexOf("UP")?b|16384:b|32768;32!=b&&(0<=a.indexOf("DOUBLE")?b|=512:0<b&&(b|=256),0<=a.indexOf("ALT")&&(b|=8));0<=a.indexOf("CTRL")&&(b|=2);0<=a.indexOf("SHIFT")&&(b|=1);return b},"~S");c$.getButtonMods=$_M(c$,"getButtonMods",function(a){return a&63},"~N");c$.getClickCount=$_M(c$,
"getClickCount",function(a){return(a&768)>>8},"~N");c$.getMouseActionName=$_M(c$,"getMouseActionName",function(a,b){var c=new JU.SB;if(0==a)return"";var d=J.viewer.binding.Binding.includes(a,8)&&!J.viewer.binding.Binding.includes(a,16)&&!J.viewer.binding.Binding.includes(a,4),e="      ".toCharArray();J.viewer.binding.Binding.includes(a,2)&&(c.append("CTRL+"),e[5]="C");!d&&J.viewer.binding.Binding.includes(a,8)&&(c.append("ALT+"),e[4]="A");J.viewer.binding.Binding.includes(a,1)&&(c.append("SHIFT+"),
e[3]="S");J.viewer.binding.Binding.includes(a,16)?(e[2]="L",c.append("LEFT")):J.viewer.binding.Binding.includes(a,4)?(e[2]="R",c.append("RIGHT")):d?(e[2]="M",c.append("MIDDLE")):J.viewer.binding.Binding.includes(a,32)&&(e[2]="W",c.append("WHEEL"));J.viewer.binding.Binding.includes(a,512)&&(c.append("+double"),e[1]="2");J.viewer.binding.Binding.includes(a,4096)?(c.append("+down"),e[0]="1"):J.viewer.binding.Binding.includes(a,8192)?(c.append("+drag"),e[0]="2"):J.viewer.binding.Binding.includes(a,16384)?
(c.append("+up"),e[0]="3"):J.viewer.binding.Binding.includes(a,32768)&&(c.append("+click"),e[0]="4");return b?String.instantialize(e)+":"+c.toString():c.toString()},"~N,~B");$_M(c$,"getBindings",function(){return this.bindings});Clazz.makeConstructor(c$,function(a){this.name=a},"~S");$_M(c$,"getName",function(){return this.name});$_M(c$,"bindAction",function(a,b){this.addBinding(a+"\t"+b,[a,b])},"~N,~N");$_M(c$,"bindName",function(a,b){this.addBinding(a+"\t",Boolean.TRUE);this.addBinding(a+"\t"+b,
[J.viewer.binding.Binding.getMouseActionName(a,!1),b])},"~N,~S");$_M(c$,"unbindAction",function(a,b){0==a?this.unbindJmolAction(b):this.removeBinding(null,a+"\t"+b)},"~N,~N");$_M(c$,"unbindName",function(a,b){null==b?this.unbindMouseAction(a):this.removeBinding(null,a+"\t"+b)},"~N,~S");$_M(c$,"unbindJmolAction",function(a){var b=this.bindings.keySet().iterator();for(a="\t"+a;b.hasNext();){var c=b.next();c.endsWith(a)&&this.removeBinding(b,c)}},"~N");$_M(c$,"addBinding",($fz=function(a,b){J.util.Logger.debugging&&
J.util.Logger.debug("adding binding "+a+"\t==\t"+J.util.Escape.e(b));this.bindings.put(a,b)},$fz.isPrivate=!0,$fz),"~S,~O");$_M(c$,"removeBinding",($fz=function(a,b){J.util.Logger.debugging&&J.util.Logger.debug("removing binding "+b);null==a?this.bindings.remove(b):a.remove()},$fz.isPrivate=!0,$fz),"java.util.Iterator,~S");$_M(c$,"unbindUserAction",function(a){var b=this.bindings.keySet().iterator();for(a="\t"+a;b.hasNext();){var c=b.next();c.endsWith(a)&&this.removeBinding(b,c)}},"~S");$_M(c$,"unbindMouseAction",
function(a){var b=this.bindings.keySet().iterator();for(a+="\t";b.hasNext();){var c=b.next();c.startsWith(a)&&this.removeBinding(b,c)}},"~N");$_M(c$,"isBound",function(a,b){return this.bindings.containsKey(a+"\t"+b)},"~N,~N");$_M(c$,"isUserAction",function(a){return this.bindings.containsKey(a+"\t")},"~N");$_M(c$,"getBindingInfo",function(a,b,c){var d=new JU.SB;c=null==c||c.equalsIgnoreCase("all")?null:c.toLowerCase();for(var e=Array(a.length),f=new JU.List,g,h=this.bindings.values().iterator();h.hasNext()&&
((g=h.next())||1);)if(J.util.Escape.isAI(g)){var k=g,l=k[1];null==e[l]&&(e[l]=new JU.List);k=J.viewer.binding.Binding.getMouseActionName(k[0],!0);(null==c||0<=(b[l]+";"+a[l]+";"+k).toLowerCase().indexOf(c))&&e[l].addLast(k)}else J.util.Escape.isAS(g)&&(l=g[0],k=g[1],(null==c||0<=c.indexOf("user")||0<=l.indexOf(c)||0<=k.indexOf(c))&&f.addLast(g));for(l=0;l<a.length;l++){var m;null==e[l]||0==(m=e[l].size())||this.addInfo(d,e[l].toArray(Array(m)),b[l],a[l])}for(l=0;l<f.size();l++)k=f.get(l),this.addInfo(d,
["USER:::"+k[0]],"user-defined",k[1]);return d.toString()},"~A,~A,~S");$_M(c$,"addInfo",($fz=function(a,b,c,d){java.util.Arrays.sort(b);J.util.Txt.leftJustify(a,"                      ",c);a.append("\t");c="";for(var e=a.length(),f=0;f<b.length;f++)a.append(c).append(b[f].substring(7)),c=", ";e=a.length()-e;20>e&&a.append("                 ".substring(0,20-e));a.append("\t").append(d).appendC("\n")},$fz.isPrivate=!0,$fz),"JU.SB,~A,~S,~S");c$.includes=$_M(c$,"includes",($fz=function(a,b){return(a&
b)==b},$fz.isPrivate=!0,$fz),"~N,~N");c$.newBinding=$_M(c$,"newBinding",function(a){return J.api.Interface.getOptionInterface("viewer.binding."+a+"Binding")},"~S");Clazz.defineStatics(c$,"LEFT",16,"MIDDLE",8,"RIGHT",4,"WHEEL",32,"ALT",8,"CTRL",2,"SHIFT",1,"CTRL_ALT",10,"CTRL_SHIFT",3,"MAC_COMMAND",20,"BUTTON_MASK",28,"BUTTON_MODIFIER_MASK",63,"SINGLE",256,"DOUBLE",512,"COUNT_MASK",768,"DOWN",4096,"DRAG",8192,"UP",16384,"CLICK",32768,"MODE_MASK",61440)}),Clazz.declarePackage("J.viewer.binding"),Clazz.load(["J.viewer.binding.JmolBinding"],
"J.viewer.binding.DragBinding",null,function(){c$=Clazz.declareType(J.viewer.binding,"DragBinding",J.viewer.binding.JmolBinding);Clazz.makeConstructor(c$,function(){Clazz.superConstructor(this,J.viewer.binding.DragBinding,["drag"])});Clazz.overrideMethod(c$,"setSelectBindings",function(){this.bindAction(33040,30);this.bindAction(33041,35);this.bindAction(33048,34);this.bindAction(33049,32);this.bindAction(4368,31);this.bindAction(41232,13);this.bindAction(33040,17)})}),Clazz.declarePackage("J.viewer.binding"),
Clazz.load(["J.viewer.binding.Binding"],"J.viewer.binding.JmolBinding",null,function(){c$=Clazz.declareType(J.viewer.binding,"JmolBinding",J.viewer.binding.Binding);Clazz.makeConstructor(c$,function(a){Clazz.superConstructor(this,J.viewer.binding.JmolBinding,[a]);this.setGeneralBindings();this.setSelectBindings()},"~S");$_M(c$,"setSelectBindings",function(){this.bindAction(33296,30);this.bindAction(33040,36)});$_M(c$,"setGeneralBindings",($fz=function(){this.bindAction(8474,45);this.bindAction(8454,
45);this.bindAction(8721,45);this.bindAction(8712,45);this.bindAction(8464,25);this.bindAction(8472,28);this.bindAction(8453,28);this.bindAction(8465,29);this.bindAction(8456,29);this.bindAction(288,46);this.bindAction(8464,40);this.bindAction(8464,16);this.bindAction(4370,23);this.bindAction(4356,23);this.bindAction(33040,2);this.bindAction(8467,38);this.bindAction(8723,6);this.bindAction(8475,39);this.bindAction(8464,44);this.bindAction(8464,41);this.bindAction(8465,42);this.bindAction(8473,13);
this.bindAction(8465,14);this.bindAction(8472,27);this.bindAction(8465,26);this.bindAction(8465,10);this.bindAction(8472,9);this.bindAction(8465,8);this.bindAction(33297,24);this.bindAction(33288,24);this.bindAction(33296,43);this.bindAction(8464,7);this.bindAction(8464,11);this.bindAction(8464,12);this.bindAction(33040,17);this.bindAction(33040,22);this.bindAction(33040,19);this.bindAction(33040,20);this.bindAction(33296,37);this.bindAction(33040,18);this.bindAction(33043,21);this.bindAction(33040,
4);this.bindAction(33040,5);this.bindAction(33040,3);this.bindAction(33040,0);this.bindAction(33043,1)},$fz.isPrivate=!0,$fz))}),Clazz.declarePackage("J.thread"),Clazz.load(["J.thread.JmolThread"],"J.thread.TimeoutThread",["java.lang.Thread","JU.SB"],function(){c$=Clazz.decorateAsClass(function(){this.script=null;this.status=0;this.triggered=!0;this.timeouts=null;Clazz.instantialize(this,arguments)},J.thread,"TimeoutThread",J.thread.JmolThread);Clazz.makeConstructor(c$,function(a,b,c,d){Clazz.superConstructor(this,
J.thread.TimeoutThread,[]);this.setViewer(a,b);this.$name=b;this.set(c,d)},"J.viewer.Viewer,~S,~N,~S");$_M(c$,"set",($fz=function(a,b){this.sleepTime=a;null!=b&&(this.script=b)},$fz.isPrivate=!0,$fz),"~N,~S");Clazz.overrideMethod(c$,"toString",function(){return"timeout name="+this.$name+" executions="+this.status+" mSec="+this.sleepTime+" secRemaining="+(this.targetTime-System.currentTimeMillis())/1E3+" script="+this.script});Clazz.overrideMethod(c$,"run1",function(a){for(;;)switch(a){case -1:this.isJS||
Thread.currentThread().setPriority(1);this.timeouts=this.viewer.getTimeouts();this.targetTime=System.currentTimeMillis()+Math.abs(this.sleepTime);a=0;break;case 0:if(this.checkInterrupted()||(null==this.script||0==this.script.length)||!this.runSleep(26,1))return;a=1;break;case 1:a=System.currentTimeMillis()<this.targetTime?0:2;break;case 2:this.currentTime=System.currentTimeMillis();if(null==this.timeouts.get(this.$name))return;this.status++;(a=0>this.sleepTime)?this.targetTime=System.currentTimeMillis()+
Math.abs(this.sleepTime):this.timeouts.remove(this.$name);this.triggered&&(this.triggered=!1,this.$name.equals("_SET_IN_MOTION_")?this.viewer.checkInMotion(2):this.viewer.evalStringQuiet(a?this.script+';\ntimeout ID "'+this.$name+'";':this.script));a=a?0:-2;break;case -2:this.timeouts.remove(this.$name);return}},"~N");c$.clear=$_M(c$,"clear",function(a){for(var b,c=a.values().iterator();c.hasNext()&&((b=c.next())||1);){var d=b;d.script.equals("exitJmol")||d.interrupt()}a.clear()},"java.util.Map");
c$.setTimeout=$_M(c$,"setTimeout",function(a,b,c,d,e){var f=b.get(c);0==d?null!=f&&(f.interrupt(),b.remove(c)):null!=f?f.set(d,e):(f=new J.thread.TimeoutThread(a,c,d,e),b.put(c,f),f.start())},"J.viewer.Viewer,java.util.Map,~S,~N,~S");c$.trigger=$_M(c$,"trigger",function(a,b){var c=a.get(b);null!=c&&(c.triggered=0>c.sleepTime)},"java.util.Map,~S");c$.showTimeout=$_M(c$,"showTimeout",function(a,b){var c=new JU.SB;if(null!=a)for(var d,e=a.values().iterator();e.hasNext()&&((d=e.next())||1);){var f=d;
(null==b||f.$name.equalsIgnoreCase(b))&&c.append(f.toString()).append("\n")}return 0<c.length()?c.toString():"<no timeouts set>"},"java.util.Map,~S")}),Clazz.declarePackage("J.util"),Clazz.load(null,"J.util.TempArray",["java.lang.Boolean","$.Float","JU.P3","$.P3i"],function(){c$=Clazz.decorateAsClass(function(){this.freeEnum=this.lengthsFreeEnum=this.freeScreens=this.lengthsFreeScreens=this.freePoints=this.lengthsFreePoints=null;Clazz.instantialize(this,arguments)},J.util,"TempArray");Clazz.prepareFields(c$,
function(){this.lengthsFreePoints=Clazz.newIntArray(6,0);this.freePoints=Array(6);this.lengthsFreeScreens=Clazz.newIntArray(6,0);this.freeScreens=Array(6);this.lengthsFreeEnum=Clazz.newIntArray(2,0);this.freeEnum=Array(2)});Clazz.makeConstructor(c$,function(){});$_M(c$,"clear",function(){this.clearTempPoints();this.clearTempScreens()});c$.findBestFit=$_M(c$,"findBestFit",($fz=function(a,b){for(var c=-1,d=2147483647,e=b.length;0<=--e;){var f=b[e];f>=a&&f<d&&(d=f,c=e)}0<=c&&(b[c]=0);return c},$fz.isPrivate=
!0,$fz),"~N,~A");c$.findShorter=$_M(c$,"findShorter",($fz=function(a,b){for(var c=b.length;0<=--c;)if(0==b[c])return b[c]=a,c;for(var d=0,e=b[0],c=b.length;0<--c;)b[c]<e&&(e=b[c],d=c);return e<a?(b[d]=a,d):-1},$fz.isPrivate=!0,$fz),"~N,~A");$_M(c$,"clearTempPoints",($fz=function(){for(var a=0;6>a;a++)this.lengthsFreePoints[a]=0,this.freePoints[a]=null},$fz.isPrivate=!0,$fz));$_M(c$,"allocTempPoints",function(a){var b;b=J.util.TempArray.findBestFit(a,this.lengthsFreePoints);if(0<b)b=this.freePoints[b];
else for(b=Array(a);0<=--a;)b[a]=new JU.P3;return b},"~N");$_M(c$,"freeTempPoints",function(a){for(var b=0;b<this.freePoints.length;b++)if(this.freePoints[b]===a){this.lengthsFreePoints[b]=a.length;return}b=J.util.TempArray.findShorter(a.length,this.lengthsFreePoints);0<=b&&(this.freePoints[b]=a)},"~A");$_M(c$,"clearTempScreens",($fz=function(){for(var a=0;6>a;a++)this.lengthsFreeScreens[a]=0,this.freeScreens[a]=null},$fz.isPrivate=!0,$fz));$_M(c$,"allocTempScreens",function(a){var b;b=J.util.TempArray.findBestFit(a,
this.lengthsFreeScreens);if(0<b)b=this.freeScreens[b];else for(b=Array(a);0<=--a;)b[a]=new JU.P3i;return b},"~N");$_M(c$,"freeTempScreens",function(a){for(var b=0;b<this.freeScreens.length;b++)if(this.freeScreens[b]===a){this.lengthsFreeScreens[b]=a.length;return}b=J.util.TempArray.findShorter(a.length,this.lengthsFreeScreens);0<=b&&(this.freeScreens[b]=a)},"~A");$_M(c$,"allocTempEnum",function(a){var b=J.util.TempArray.findBestFit(a,this.lengthsFreeEnum);return 0<b?this.freeEnum[b]:Array(a)},"~N");
$_M(c$,"freeTempEnum",function(a){for(var b=0;b<this.freeEnum.length;b++)if(this.freeEnum[b]===a){this.lengthsFreeEnum[b]=a.length;return}b=J.util.TempArray.findShorter(a.length,this.lengthsFreeEnum);0<=b&&(this.freeEnum[b]=a)},"~A");c$.getSlabWithinRange=$_M(c$,"getSlabWithinRange",function(a,b){return[Integer.$valueOf(1073742114),[Float.$valueOf(a),Float.$valueOf(b)],Boolean.FALSE,null]},"~N,~N");c$.getSlabObjectType=$_M(c$,"getSlabObjectType",function(a,b,c,d){return[Integer.$valueOf(a),b,Boolean.$valueOf(c),
d]},"~N,~O,~B,~O");Clazz.defineStatics(c$,"freePointsSize",6,"freeScreensSize",6,"freeEnumSize",2)}),Clazz.declarePackage("J.viewer"),Clazz.load(["JU.BS","J.constant.EnumAnimationMode"],"J.viewer.AnimationManager",["J.api.Interface","J.util.BSUtil"],function(){c$=Clazz.decorateAsClass(function(){this.viewer=this.modulationThread=this.animationThread=null;this.animationOn=!1;this.lastFrameDelayMs=this.firstFrameDelayMs=this.animationFps=0;this.animationFrames=this.bsDisplay=this.animationReplayMode=
this.bsVisibleModels=null;this.animationPaused=this.isMovie=!1;this.morphCount=this.currentAnimationFrame=this.currentModelIndex=0;this.currentDirection=this.animationDirection=1;this.frameStep=this.lastFrameIndex=this.firstFrameIndex=0;this.backgroundModelIndex=-1;this.firstFrameDelay=this.currentMorphModel=0;this.lastFrameDelay=1;this.intAnimThread=this.lastModelPainted=this.lastFramePainted=0;this.modulationPlay=!1;this.modulationFps=1;this.bsModulating=null;Clazz.instantialize(this,arguments)},
J.viewer,"AnimationManager");Clazz.prepareFields(c$,function(){this.bsVisibleModels=new JU.BS;this.animationReplayMode=J.constant.EnumAnimationMode.ONCE});Clazz.makeConstructor(c$,function(a){this.viewer=a},"J.viewer.Viewer");$_M(c$,"setAnimationOn",function(a){a!=this.animationOn&&(!a||!this.viewer.haveModelSet()||this.viewer.isHeadless()?this.stopThread(!1):(this.viewer.getSpinOn()||this.viewer.refresh(3,"Anim:setAnimationOn"),this.setAnimationRange(-1,-1),this.resumeAnimation()))},"~B");$_M(c$,
"stopThread",function(a){var b=!1;null!=this.animationThread&&(this.animationThread.interrupt(),this.animationThread=null,b=!0);this.animationPaused=a;b&&!this.viewer.getSpinOn()&&this.viewer.refresh(3,"Viewer:setAnimationOff");this.animation(!1);this.stopModulationThread();this.viewer.setStatusFrameChanged(!1)},"~B");$_M(c$,"setAnimationNext",function(){return this.setAnimationRelative(this.animationDirection)});$_M(c$,"getCurrentModelIndex",function(){return this.currentModelIndex});$_M(c$,"currentIsLast",
function(){return this.isMovie?this.lastFramePainted==this.currentAnimationFrame:this.lastModelPainted==this.currentModelIndex});$_M(c$,"currentFrameIs",function(a){var b=this.getCurrentModelIndex();return 0==this.morphCount?b==a:0.001>Math.abs(this.currentMorphModel-a)},"~N");$_M(c$,"clear",function(){this.setMovie(null);this.initializePointers(0);this.setAnimationOn(!1);this.setModel(0,!0);this.currentDirection=1;this.setAnimationDirection(1);this.setAnimationFps(10);this.setAnimationReplayMode(J.constant.EnumAnimationMode.ONCE,
0,0);this.initializePointers(0)});$_M(c$,"getModelSpecial",function(a){switch(a){case -1:a=this.firstFrameIndex;break;case 0:if(0<this.morphCount)return"-"+(1+this.currentMorphModel);a=this.getCurrentModelIndex();break;case 1:a=this.lastFrameIndex}return this.viewer.getModelNumberDotted(a)},"~N");$_M(c$,"setDisplay",function(a){this.bsDisplay=null==a||0==a.cardinality()?null:J.util.BSUtil.copy(a)},"JU.BS");$_M(c$,"setMorphCount",function(a){this.morphCount=this.isMovie?0:a},"~N");$_M(c$,"morph",function(a){var b=
Clazz.floatToInt(a);0.001>Math.abs(b-a)?a=b:0.999<Math.abs(b-a)&&(a=b+=1);a-=b;b-=1;if(0==a)this.currentMorphModel=b,this.setModel(b,!0);else{var c;this.setModel(b,!0);c=b+1;this.currentMorphModel=b+a;c==b||(0>c||0>b)||this.viewer.modelSet.morphTrajectories(b,c,a)}},"~N");$_M(c$,"setModel",function(a,b){0>a&&this.stopThread(!1);var c=this.currentModelIndex,d=this.viewer.getModelSet(),e=null==d?0:d.modelCount;if(1==e)this.currentModelIndex=a=0;else if(0>a||a>=e)a=-1;var d=null,f=!1;if(this.currentModelIndex!=
a){if(0<e){var e=this.viewer.isJmolDataFrameForModel(a),g=this.viewer.isJmolDataFrameForModel(this.currentModelIndex);g&&this.viewer.setJmolDataFrame(null,-1,this.currentModelIndex);-1!=this.currentModelIndex&&this.viewer.saveModelOrientation();if(g||e)d=this.viewer.getJmolFrameType(a)+" "+a+" <--  "+this.currentModelIndex+" "+this.viewer.getJmolFrameType(this.currentModelIndex),f=this.viewer.getJmolDataSourceFrame(a)==this.viewer.getJmolDataSourceFrame(this.currentModelIndex)}this.currentModelIndex=
a;null!=d&&(0<=a&&this.viewer.restoreModelOrientation(a),f&&(0<=d.indexOf("quaternion")||0>d.indexOf("plot")&&0>d.indexOf("ramachandran")&&0>d.indexOf(" property "))&&this.viewer.restoreModelRotation(c))}this.setViewer(b)},"~N,~B");$_M(c$,"setBackgroundModelIndex",function(a){var b=this.viewer.getModelSet();if(null==b||0>a||a>=b.modelCount)a=-1;this.backgroundModelIndex=a;0<=a&&this.viewer.setTrajectory(a);this.viewer.setTainted(!0);this.setFrameRangeVisible()},"~N");$_M(c$,"initializePointers",function(a){this.firstFrameIndex=
0;this.lastFrameIndex=(0==a?0:this.getFrameCount())-1;this.frameStep=a;this.viewer.setFrameVariables()},"~N");$_M(c$,"setAnimationDirection",function(a){this.animationDirection=a},"~N");$_M(c$,"setAnimationFps",function(a){this.animationFps=a;this.viewer.setFrameVariables()},"~N");$_M(c$,"setAnimationReplayMode",function(a,b,c){this.firstFrameDelay=0<b?b:0;this.firstFrameDelayMs=Clazz.floatToInt(1E3*this.firstFrameDelay);this.lastFrameDelay=0<c?c:0;this.lastFrameDelayMs=Clazz.floatToInt(1E3*this.lastFrameDelay);
this.animationReplayMode=a;this.viewer.setFrameVariables()},"J.constant.EnumAnimationMode,~N,~N");$_M(c$,"setAnimationRange",function(a,b){var c=this.getFrameCount();0>a&&(a=0);0>b&&(b=c);a>=c&&(a=c-1);b>=c&&(b=c-1);this.currentMorphModel=this.firstFrameIndex=a;this.lastFrameIndex=b;this.frameStep=b<a?-1:1;this.rewindAnimation()},"~N,~N");$_M(c$,"pauseAnimation",function(){this.stopThread(!0)});$_M(c$,"reverseAnimation",function(){this.currentDirection=-this.currentDirection;this.animationOn||this.resumeAnimation()});
$_M(c$,"repaintDone",function(){this.lastModelPainted=this.currentModelIndex;this.lastFramePainted=this.currentAnimationFrame});$_M(c$,"setModulationPlay",function(a,b){2147483647==a||!this.viewer.haveModelSet()||this.viewer.isHeadless()?this.stopThread(!1):null==this.modulationThread&&(this.modulationPlay=!0,this.modulationThread=J.api.Interface.getOptionInterface("thread.ModulationThread"),this.modulationThread.setManager(this,this.viewer,[a,b]),this.modulationThread.start())},"~N,~N");$_M(c$,"resumeAnimation",
function(){0>this.currentModelIndex&&this.setAnimationRange(this.firstFrameIndex,this.lastFrameIndex);1>=this.getFrameCount()?this.animation(!1):(this.animation(!0),this.animationPaused=!1,null==this.animationThread&&(this.intAnimThread++,this.animationThread=J.api.Interface.getOptionInterface("thread.AnimationThread"),this.animationThread.setManager(this,this.viewer,[this.firstFrameIndex,this.lastFrameIndex,this.intAnimThread]),this.animationThread.start()))});$_M(c$,"setAnimationLast",function(){this.setFrame(0<
this.animationDirection?this.lastFrameIndex:this.firstFrameIndex)});$_M(c$,"rewindAnimation",function(){this.setFrame(0<this.animationDirection?this.firstFrameIndex:this.lastFrameIndex);this.currentDirection=1;this.viewer.setFrameVariables()});$_M(c$,"setAnimationPrevious",function(){return this.setAnimationRelative(-this.animationDirection)});$_M(c$,"getAnimRunTimeSeconds",function(){var a=this.getFrameCount();if(this.firstFrameIndex==this.lastFrameIndex||0>this.lastFrameIndex||0>this.firstFrameIndex||
this.lastFrameIndex>=a||this.firstFrameIndex>=a)return 0;for(var b=Math.min(this.firstFrameIndex,this.lastFrameIndex),a=Math.max(this.firstFrameIndex,this.lastFrameIndex),c=1*(a-b)/this.animationFps+this.firstFrameDelay+this.lastFrameDelay;b<=a;b++)c+=this.viewer.getFrameDelayMs(this.modelIndexForFrame(b))/1E3;return c});$_M(c$,"setMovie",function(a){if(this.isMovie=null!=a&&null==a.get("scripts")){this.animationFrames=a.get("frames");if(null==this.animationFrames||0==this.animationFrames.length)this.isMovie=
!1;else if(this.currentAnimationFrame=a.get("currentFrame").intValue(),0>this.currentAnimationFrame||this.currentAnimationFrame>=this.animationFrames.length)this.currentAnimationFrame=0;this.setFrame(this.currentAnimationFrame)}this.isMovie||(this.animationFrames=null);this.viewer.setBooleanProperty("_ismovie",this.isMovie);this.bsDisplay=null;this.currentMorphModel=this.morphCount=0},"java.util.Map");$_M(c$,"getAnimationFrames",function(){return this.animationFrames});$_M(c$,"getCurrentFrameIndex",
function(){return this.currentAnimationFrame});$_M(c$,"modelIndexForFrame",function(a){return this.isMovie?this.animationFrames[a]-1:a},"~N");$_M(c$,"getFrameCount",function(){return this.isMovie?this.animationFrames.length:this.viewer.getModelCount()});$_M(c$,"setFrame",function(a){try{if(this.isMovie){var b=this.modelIndexForFrame(a);this.currentAnimationFrame=a;a=b}else this.currentAnimationFrame=a;this.setModel(a,!0)}catch(c){if(!Clazz.exceptionOf(c,Exception))throw c;}},"~N");$_M(c$,"setModulationFps",
function(a){0<a?this.modulationFps=a:this.stopModulationThread()},"~N");$_M(c$,"setViewer",($fz=function(a){this.viewer.setTrajectory(this.currentModelIndex);this.viewer.setFrameOffset(this.currentModelIndex);-1==this.currentModelIndex&&a&&this.setBackgroundModelIndex(-1);this.viewer.setTainted(!0);this.setFrameRangeVisible();this.viewer.setStatusFrameChanged(!1);null!=this.viewer.modelSet&&!this.viewer.global.selectAllModels&&this.viewer.setSelectionSubset(this.viewer.getModelUndeletedAtomsBitSet(this.currentModelIndex))},
$fz.isPrivate=!0,$fz),"~B");$_M(c$,"setFrameRangeVisible",($fz=function(){this.bsVisibleModels.clearAll();0<=this.backgroundModelIndex&&this.bsVisibleModels.set(this.backgroundModelIndex);if(0<=this.currentModelIndex)this.bsVisibleModels.set(this.currentModelIndex);else if(0!=this.frameStep){for(var a=0,b=0,c=this.firstFrameIndex;c!=this.lastFrameIndex;c+=this.frameStep){var d=this.modelIndexForFrame(c);this.viewer.isJmolDataFrameForModel(d)||(this.bsVisibleModels.set(d),a++,b=c)}d=this.modelIndexForFrame(this.lastFrameIndex);
if(this.firstFrameIndex==this.lastFrameIndex||!this.viewer.isJmolDataFrameForModel(d)||0==a)this.bsVisibleModels.set(d),0==a&&(this.firstFrameIndex=this.lastFrameIndex),a=0;1==a&&0>this.currentModelIndex&&this.setFrame(b)}},$fz.isPrivate=!0,$fz));$_M(c$,"animation",($fz=function(a){this.animationOn=a;this.viewer.setBooleanProperty("_animating",a)},$fz.isPrivate=!0,$fz),"~B");$_M(c$,"setAnimationRelative",($fz=function(a){a=this.getFrameStep(a);var b=(this.isMovie?this.currentAnimationFrame:this.currentModelIndex)+
a,c=0,d=0,e;0<this.morphCount?(c=1/(this.morphCount+1),d=this.currentMorphModel+a*c,e=this.isNotInRange(d)):e=this.isNotInRange(b);if(e)switch(this.animationReplayMode){case J.constant.EnumAnimationMode.ONCE:return!1;case J.constant.EnumAnimationMode.LOOP:d=b=this.animationDirection==this.currentDirection?this.firstFrameIndex:this.lastFrameIndex;break;case J.constant.EnumAnimationMode.PALINDROME:this.currentDirection=-this.currentDirection,b-=2*a,d-=2*a*c}if(1>this.morphCount){if(0>b||b>=this.getFrameCount())return!1;
this.setFrame(b);return!0}this.morph(d+1);return!0},$fz.isPrivate=!0,$fz),"~N");$_M(c$,"isNotInRange",($fz=function(a){var b=a-0.001;return b>this.firstFrameIndex&&b>this.lastFrameIndex||(b=a+0.001)<this.firstFrameIndex&&b<this.lastFrameIndex},$fz.isPrivate=!0,$fz),"~N");$_M(c$,"getFrameStep",($fz=function(a){return this.frameStep*a*this.currentDirection},$fz.isPrivate=!0,$fz),"~N");$_M(c$,"stopModulationThread",function(){null!=this.modulationThread&&(this.modulationThread.interrupt(),this.modulationThread=
null);this.modulationPlay=!1});Clazz.defineStatics(c$,"FRAME_FIRST",-1,"FRAME_LAST",1,"MODEL_CURRENT",0)}),Clazz.declarePackage("J.viewer"),Clazz.load(["J.util.ColorEncoder"],"J.viewer.ColorManager","java.lang.Float JU.ArrayUtil J.constant.EnumPalette J.util.C $.ColorUtil $.Elements $.Logger J.viewer.JC".split(" "),function(){c$=Clazz.decorateAsClass(function(){this.colorData=this.altArgbsCpk=this.argbsCpk=this.g3d=this.viewer=this.propertyColorEncoder=null;this.isDefaultColorRasmol=!1;this.colixRubberband=
22;this.colixBackgroundContrast=0;Clazz.instantialize(this,arguments)},J.viewer,"ColorManager");Clazz.prepareFields(c$,function(){this.propertyColorEncoder=new J.util.ColorEncoder(null)});Clazz.makeConstructor(c$,function(a,b){this.viewer=a;this.g3d=b;this.argbsCpk=J.constant.EnumPalette.argbsCpk;this.altArgbsCpk=JU.ArrayUtil.arrayCopyRangeI(J.viewer.JC.altArgbsCpk,0,-1)},"J.viewer.Viewer,J.util.GData");$_M(c$,"clear",function(){});$_M(c$,"getDefaultColorRasmol",function(){return this.isDefaultColorRasmol});
$_M(c$,"resetElementColors",function(){this.setDefaultColors(!1)});$_M(c$,"setDefaultColors",function(a){a?(this.isDefaultColorRasmol=!0,this.argbsCpk=JU.ArrayUtil.arrayCopyI(J.util.ColorEncoder.getRasmolScale(),-1)):(this.isDefaultColorRasmol=!1,this.argbsCpk=J.constant.EnumPalette.argbsCpk);this.altArgbsCpk=JU.ArrayUtil.arrayCopyRangeI(J.viewer.JC.altArgbsCpk,0,-1);this.propertyColorEncoder.createColorScheme(a?"Rasmol=":"Jmol=",!0,!0);for(a=J.constant.EnumPalette.argbsCpk.length;0<=--a;)this.g3d.changeColixArgb(a,
this.argbsCpk[a]);for(a=J.viewer.JC.altArgbsCpk.length;0<=--a;)this.g3d.changeColixArgb(J.util.Elements.elementNumberMax+a,this.altArgbsCpk[a])},"~B");$_M(c$,"setRubberbandArgb",function(a){this.colixRubberband=0==a?0:J.util.C.getColix(a)},"~N");$_M(c$,"setColixBackgroundContrast",function(a){this.colixBackgroundContrast=J.util.ColorUtil.getBgContrast(a)},"~N");$_M(c$,"getColixBondPalette",function(a,b){switch(b){case 19:return this.propertyColorEncoder.getColorIndexFromPalette(a.getEnergy(),-2.5,
-0.5,7,!1)}return 10},"J.modelset.Bond,~N");$_M(c$,"getColixAtomPalette",function(a,b){var c=0,d;switch(b){case 84:return null==this.colorData||a.index>=this.colorData.length?12:this.getColixForPropertyValue(this.colorData[a.index]);case 0:case 1:c=a.getAtomicAndIsotopeNumber();if(c<J.util.Elements.elementNumberMax)return this.g3d.getChangeableColix(c,this.argbsCpk[c]);d=c;c=J.util.Elements.altElementIndexFromNumber(c);return 0==c?(c=J.util.Elements.getElementNumber(d),this.g3d.getChangeableColix(c,
this.argbsCpk[c])):this.g3d.getChangeableColix(J.util.Elements.elementNumberMax+c,this.altArgbsCpk[c]);case 2:return c=J.util.ColorEncoder.quantize(a.getPartialCharge(),-1,1,J.viewer.JC.PARTIAL_CHARGE_RANGE_SIZE),this.g3d.getChangeableColix(J.viewer.JC.PARTIAL_CHARGE_COLIX_RED+c,J.viewer.JC.argbsRwbScale[c]);case 3:return c=a.getFormalCharge()- -4,this.g3d.getChangeableColix(J.viewer.JC.FORMAL_CHARGE_COLIX_RED+c,J.viewer.JC.argbsFormalCharge[c]);case 68:case 5:return 68==b?(c=this.viewer.getModelSet(),
d=c.getBfactor100Lo(),c=c.getBfactor100Hi()):(d=0,c=1E4),this.propertyColorEncoder.getColorIndexFromPalette(a.getBfactor100(),d,c,7,!1);case 86:return this.propertyColorEncoder.getColorIndexFromPalette(a.getGroupParameter(1112539150),-1,1,7,!1);case 70:return c=this.viewer.getSurfaceDistanceMax(),this.propertyColorEncoder.getColorIndexFromPalette(a.getSurfaceDistance100(),0,c,7,!1);case 8:return this.propertyColorEncoder.getColorIndexFromPalette(a.getGroupID(),0,0,5,!1);case 9:return this.propertyColorEncoder.getColorIndexFromPalette(a.getGroupID(),
0,0,4,!1);case 75:return this.propertyColorEncoder.getColorIndexFromPalette(a.getSelectedGroupIndexWithinChain(),0,a.getSelectedGroupCountWithinChain()-1,1,!1);case 87:return c=this.viewer.getModelSet().models[a.modelIndex],this.propertyColorEncoder.getColorIndexFromPalette(a.getPolymerIndexInModel(),0,c.getBioPolymerCount()-1,1,!1);case 76:return this.propertyColorEncoder.getColorIndexFromPalette(a.getSelectedMonomerIndexWithinPolymer(),0,a.getSelectedMonomerCountWithinPolymer()-1,1,!1);case 77:return c=
this.viewer.getModelSet(),this.propertyColorEncoder.getColorIndexFromPalette(c.getMoleculeIndex(a.getIndex(),!0),0,c.getMoleculeCountInModel(a.getModelIndex())-1,0,!1);case 14:return c=this.viewer.getModelSet(),d=a.getModelIndex(),this.propertyColorEncoder.getColorIndexFromPalette(c.getAltLocIndexInModel(d,a.getAlternateLocationID()),0,c.getAltLocCountInModel(d),0,!1);case 15:return c=this.viewer.getModelSet(),d=a.getModelIndex(),this.propertyColorEncoder.getColorIndexFromPalette(c.getInsertionCodeIndexInModel(d,
a.getInsertionCode()),0,c.getInsertionCountInModel(d),0,!1);case 16:c=a.getAtomicAndIsotopeNumber();c=this.getJmolOrRasmolArgb(c,1073741992);break;case 17:c=a.getAtomicAndIsotopeNumber();c=this.getJmolOrRasmolArgb(c,1073742116);break;case 7:c=a.getProteinStructureSubType().getColor();break;case 10:c=a.getChainID(),0>c?c=0:256<=c&&(c-=256),c=(c&31)%J.viewer.JC.argbsChainAtom.length,c=(a.isHetero()?J.viewer.JC.argbsChainHetero:J.viewer.JC.argbsChainAtom)[c]}return 0==c?22:J.util.C.getColix(c)},"J.modelset.Atom,~N");
$_M(c$,"getJmolOrRasmolArgb",($fz=function(a,b){switch(b){case 1073741992:if(a>=J.util.Elements.elementNumberMax)break;return this.propertyColorEncoder.getArgbFromPalette(a,0,0,2);case 1073742116:if(a>=J.util.Elements.elementNumberMax)break;return this.propertyColorEncoder.getArgbFromPalette(a,0,0,3);default:return b}return J.viewer.JC.altArgbsCpk[J.util.Elements.altElementIndexFromNumber(a)]},$fz.isPrivate=!0,$fz),"~N,~N");$_M(c$,"setElementArgb",function(a,b){1073741992==b&&this.argbsCpk===J.constant.EnumPalette.argbsCpk||
(b=this.getJmolOrRasmolArgb(a,b),this.argbsCpk===J.constant.EnumPalette.argbsCpk&&(this.argbsCpk=JU.ArrayUtil.arrayCopyRangeI(J.constant.EnumPalette.argbsCpk,0,-1),this.altArgbsCpk=JU.ArrayUtil.arrayCopyRangeI(J.viewer.JC.altArgbsCpk,0,-1)),a<J.util.Elements.elementNumberMax?(this.argbsCpk[a]=b,this.g3d.changeColixArgb(a,b)):(a=J.util.Elements.altElementIndexFromNumber(a),this.altArgbsCpk[a]=b,this.g3d.changeColixArgb(J.util.Elements.elementNumberMax+a,b)))},"~N,~N");$_M(c$,"getPropertyColorRange",
function(){return this.propertyColorEncoder.isReversed?[this.propertyColorEncoder.hi,this.propertyColorEncoder.lo]:[this.propertyColorEncoder.lo,this.propertyColorEncoder.hi]});$_M(c$,"setPropertyColorRangeData",function(a,b,c){this.colorData=a;this.propertyColorEncoder.currentPalette=this.propertyColorEncoder.createColorScheme(c,!0,!1);this.propertyColorEncoder.hi=1.4E-45;this.propertyColorEncoder.lo=3.4028235E38;if(null!=a){c=null==b;for(var d,e=c?a.length-1:b.nextSetBit(0);0<=e;e=c?e-1:b.nextSetBit(e+
1))if(!Float.isNaN(d=a[e]))this.propertyColorEncoder.hi=Math.max(this.propertyColorEncoder.hi,d),this.propertyColorEncoder.lo=Math.min(this.propertyColorEncoder.lo,d);this.setPropertyColorRange(this.propertyColorEncoder.lo,this.propertyColorEncoder.hi)}},"~A,JU.BS,~S");$_M(c$,"setPropertyColorRange",function(a,b){this.propertyColorEncoder.setRange(a,b,a>b);J.util.Logger.info('ColorManager: color "'+this.propertyColorEncoder.getCurrentColorSchemeName()+'" range '+a+" "+b)},"~N,~N");$_M(c$,"setPropertyColorScheme",
function(a,b,c){var d=0==a.length;d&&(a="=");var e=this.getPropertyColorRange();this.propertyColorEncoder.currentPalette=this.propertyColorEncoder.createColorScheme(a,!0,c);d||this.setPropertyColorRange(e[0],e[1]);this.propertyColorEncoder.isTranslucent=b},"~S,~B,~B");$_M(c$,"setUserScale",function(a){this.propertyColorEncoder.setUserScale(a)},"~A");$_M(c$,"getColorSchemeList",function(a){a=null==a||0==a.length?this.propertyColorEncoder.currentPalette:this.propertyColorEncoder.createColorScheme(a,
!0,!1);return J.util.ColorEncoder.getColorSchemeList(this.propertyColorEncoder.getColorSchemeArray(a))},"~S");$_M(c$,"getColixForPropertyValue",function(a){return this.propertyColorEncoder.getColorIndex(a)},"~N");$_M(c$,"getColorEncoder",function(a){if(null==a||0==a.length)return this.propertyColorEncoder;var b=new J.util.ColorEncoder(this.propertyColorEncoder);b.currentPalette=b.createColorScheme(a,!1,!0);return 2147483647==b.currentPalette?null:b},"~S")}),Clazz.declarePackage("J.viewer"),Clazz.load(["JU.BS"],
"J.viewer.ShapeManager","java.lang.Boolean java.util.Hashtable JU.P3 $.SB J.constant.EnumPalette $.EnumVdw J.util.BSUtil $.Logger J.viewer.JC".split(" "),function(){c$=Clazz.decorateAsClass(function(){this.navigationCrossHairMinMax=this.bsRenderableAtoms=this.viewer=this.shapes=this.modelSet=this.gdata=null;Clazz.instantialize(this,arguments)},J.viewer,"ShapeManager");Clazz.prepareFields(c$,function(){this.bsRenderableAtoms=new JU.BS;this.navigationCrossHairMinMax=Clazz.newIntArray(4,0)});Clazz.makeConstructor(c$,
function(a){this.viewer=a;this.gdata=a.getGraphicsData()},"J.viewer.Viewer");$_M(c$,"findNearestShapeAtomIndex",function(a,b,c,d){if(null!=this.shapes)for(var e=0;e<this.shapes.length&&null==c[0];++e)null!=this.shapes[e]&&this.shapes[e].findNearestAtomIndex(a,b,c,d)},"~N,~N,~A,JU.BS");$_M(c$,"getShapes",function(){return this.shapes});$_M(c$,"getShapePropertyIndex",function(a,b,c){if(null==this.shapes||null==this.shapes[a])return null;this.viewer.setShapeErrorState(a,"get "+b);a=this.shapes[a].getProperty(b,
c);this.viewer.setShapeErrorState(-1,null);return a},"~N,~S,~N");$_M(c$,"getShapePropertyData",function(a,b,c){if(null==this.shapes||null==this.shapes[a])return!1;this.viewer.setShapeErrorState(a,"get "+b);a=this.shapes[a].getPropertyData(b,c);this.viewer.setShapeErrorState(-1,null);return a},"~N,~S,~A");$_M(c$,"getShapeIdFromObjectName",function(a){if(null!=this.shapes)for(var b=16;29>b;++b)if(null!=this.shapes[b]&&0<=this.shapes[b].getIndexFromName(a))return b;return-1},"~S");$_M(c$,"loadDefaultShapes",
function(a){this.modelSet=a;if(null!=this.shapes)for(var b=0;b<this.shapes.length;++b)null!=this.shapes[b]&&this.shapes[b].setModelSet(a);this.loadShape(0);this.loadShape(1)},"J.modelset.ModelSet");$_M(c$,"loadShape",function(a){if(null==this.shapes)return null;if(null!=this.shapes[a])return this.shapes[a];if(2==a||3==a||4==a)return null;var b=J.viewer.JC.getShapeClassName(a,!1);try{var c=Class.forName(b).newInstance();this.viewer.setShapeErrorState(a,"allocate");c.initializeShape(this.viewer,this.gdata,
this.modelSet,a);this.viewer.setShapeErrorState(-1,null);return this.shapes[a]=c}catch(d){if(Clazz.exceptionOf(d,Exception))return J.util.Logger.errorEx("Could not instantiate shape:"+b,d),null;throw d;}},"~N");$_M(c$,"refreshShapeTrajectories",function(a,b,c){var d=Integer.$valueOf(a);a=this.viewer.getModelUndeletedAtomsBitSet(a);for(var e=0;36>e;e++)null!=this.shapes[e]&&this.setShapePropertyBs(e,"refreshTrajectories",[d,b,c],a)},"~N,JU.BS,JU.M4");$_M(c$,"releaseShape",function(a){null!=this.shapes&&
(this.shapes[a]=null)},"~N");$_M(c$,"resetShapes",function(){this.viewer.noGraphicsAllowed()||(this.shapes=Array(36))});$_M(c$,"setShapeSizeBs",function(a,b,c,d){if(null!=this.shapes){if(null==d&&(1!=a||2147483647!=b))d=this.viewer.getSelectionSet(!1);null!=c&&(0!=c.value&&c.vdwType===J.constant.EnumVdw.TEMP)&&this.modelSet.getBfactor100Lo();this.viewer.setShapeErrorState(a,"set size");(null==c?0!=b:0!=c.value)&&this.loadShape(a);null!=this.shapes[a]&&this.shapes[a].setShapeSizeRD(b,c,d);this.viewer.setShapeErrorState(-1,
null)}},"~N,~N,J.atomdata.RadiusData,JU.BS");$_M(c$,"setLabel",function(a,b){if(null==a){if(null==this.shapes[5])return}else this.loadShape(5),this.setShapeSizeBs(5,0,null,b);this.setShapePropertyBs(5,"label",a,b)},"~S,JU.BS");$_M(c$,"setShapePropertyBs",function(a,b,c,d){null==this.shapes||null==this.shapes[a]||(null==d&&(d=this.viewer.getSelectionSet(!1)),this.viewer.setShapeErrorState(a,"set "+b),this.shapes[a].setProperty(b.intern(),c,d),this.viewer.setShapeErrorState(-1,null))},"~N,~S,~O,JU.BS");
$_M(c$,"checkFrankclicked",function(a,b){var c=this.shapes[35];return null!=c&&c.wasClicked(a,b)},"~N,~N");$_M(c$,"checkObjectClicked",function(a,b,c,d,e){var f,g=null;if(0!=c&&this.viewer.getBondPicking()&&null!=(g=this.shapes[1].checkObjectClicked(a,b,c,d,e)))return g;for(var h=0;h<J.viewer.ShapeManager.clickableMax;h++)if(null!=(f=this.shapes[J.viewer.ShapeManager.hoverable[h]])&&null!=(g=f.checkObjectClicked(a,b,c,d,e)))return g;return null},"~N,~N,~N,JU.BS,~B");$_M(c$,"checkObjectDragged",function(a,
b,c,d,e,f,g){for(var h=!1,k=0<g?g+1:36;!h&&g<k;++g)null!=this.shapes[g]&&(h=this.shapes[g].checkObjectDragged(a,b,c,d,e,f));return h},"~N,~N,~N,~N,~N,JU.BS,~N");$_M(c$,"checkObjectHovered",function(a,b,c,d){var e=this.shapes[1];if(d&&null!=e&&e.checkObjectHovered(a,b,c))return!0;for(d=0;d<J.viewer.ShapeManager.hoverable.length;d++)if(e=this.shapes[J.viewer.ShapeManager.hoverable[d]],null!=e&&e.checkObjectHovered(a,b,c))return!0;return!1},"~N,~N,JU.BS,~B");$_M(c$,"deleteShapeAtoms",function(a,b){if(null!=
this.shapes)for(var c=0;36>c;c++)null!=this.shapes[c]&&this.setShapePropertyBs(c,"deleteModelAtoms",a,b)},"~A,JU.BS");$_M(c$,"deleteVdwDependentShapes",function(a){null==a&&(a=this.viewer.getSelectionSet(!1));null!=this.shapes[24]&&this.shapes[24].setProperty("deleteVdw",null,a);null!=this.shapes[25]&&this.shapes[25].setProperty("deleteVdw",null,a)},"JU.BS");$_M(c$,"getAtomShapeValue",function(a,b,c){a=J.viewer.JC.shapeTokenIndex(a);if(0>a||null==this.shapes[a])return 0;c=this.shapes[a].getSize(c);
if(0==c){if(0==(b.shapeVisibilityFlags&this.shapes[a].myVisibilityFlag))return 0;c=this.shapes[a].getSizeG(b)}return c/2E3},"~N,J.modelset.Group,~N");$_M(c$,"getObjectMap",function(a,b){if(null!=this.shapes)for(var c=Boolean.$valueOf(b),d=16;29>d;++d)this.getShapePropertyData(d,"getNames",[a,c])},"java.util.Map,~B");$_M(c$,"getProperty",function(a){return a.equals("getShapes")?this.shapes:null},"~O");$_M(c$,"getRenderableBitSet",function(){return this.bsRenderableAtoms});$_M(c$,"getShape",function(a){return null==
this.shapes?null:this.shapes[a]},"~N");$_M(c$,"getShapeInfo",function(){var a=new java.util.Hashtable,b=new JU.SB;if(null!=this.shapes)for(var c=0;36>c;++c){var d=this.shapes[c];if(null!=d){var e=J.viewer.JC.shapeClassBases[c],d=d.getShapeDetail();null!=d&&a.put(e,d)}}0<b.length()&&a.put("shapeCommands",b.toString());return a});$_M(c$,"mergeShapes",function(a){if(null!=a)if(null==this.shapes)this.shapes=a;else for(var b=0;b<a.length;++b)null!=a[b]&&(null==this.shapes[b]&&this.loadShape(b),this.shapes[b].merge(a[b]))},
"~A");$_M(c$,"resetBioshapes",function(a){if(null!=this.shapes)for(var b=0;b<this.shapes.length;++b)null!=this.shapes[b]&&this.shapes[b].isBioShape&&(this.shapes[b].setModelSet(this.modelSet),this.shapes[b].setShapeSizeRD(0,null,a),this.shapes[b].setProperty("color",J.constant.EnumPalette.NONE,a))},"JU.BS");$_M(c$,"setAtomLabel",function(a,b){null!=this.shapes&&(this.loadShape(5),this.shapes[5].setProperty("label:"+a,Integer.$valueOf(b),null))},"~S,~N");$_M(c$,"setModelVisibility",function(){if(!(null==
this.shapes||null==this.shapes[0])){for(var a=this.viewer.getVisibleFramesBitSet(),b=1;36>b;b++)null!=this.shapes[b]&&this.shapes[b].setVisibilityFlags(a);this.shapes[0].setVisibilityFlags(a);for(b=0;36>b;++b)a=this.shapes[b],null!=a&&a.setModelClickability()}});$_M(c$,"finalizeAtoms",function(a,b){if(null!=a){var c=this.viewer.getAtomSetCenter(a),d=new JU.P3;this.viewer.transformPt3f(c,d);d.add(b);this.viewer.unTransformPoint(d,d);d.sub(c);this.viewer.setAtomCoordsRelative(d,a);b.set(0,0,0)}this.bsRenderableAtoms.clearAll();
c=this.modelSet.atoms;for(d=this.modelSet.getAtomCount();0<=--d;)0!=(c[d].getShapeVisibilityFlags()&1)&&this.bsRenderableAtoms.set(d)},"JU.BS,JU.P3");$_M(c$,"transformAtoms",function(){for(var a=this.modelSet.vibrations,b=this.modelSet.atoms,c=this.bsRenderableAtoms.nextSetBit(0);0<=c;c=this.bsRenderableAtoms.nextSetBit(c+1)){var d=b[c],e=null!=a&&d.hasVibration()?this.viewer.transformPtVib(d,a[c]):this.viewer.transformPt(d);d.screenX=e.x;d.screenY=e.y;d.screenZ=e.z;d.screenDiameter=Clazz.floatToShort(this.viewer.scaleToScreen(e.z,
Math.abs(d.madAtom)))}if(this.viewer.getSlabEnabled()){var c=this.viewer.getBoolean(603979940),a=this.viewer.getBoolean(603979938),e=this.gdata.getSlab(),f=this.gdata.getDepth();if(c)for(var d=this.modelSet.getMolecules(),g=this.modelSet.getMoleculeCountInModel(-1),c=0;c<g;c++){var h=d[c],k=0,l=h.firstAtomIndex;if(this.bsRenderableAtoms.get(l)){for(;k<h.atomCount&&!this.gdata.isClippedZ(b[l].screenZ-(b[l].screenDiameter>>1));k++,l++);if(k!=h.atomCount){l=h.firstAtomIndex;for(k=0;k<h.atomCount;k++)this.bsRenderableAtoms.clear(l),
b[l++].screenZ=0}}}for(c=this.bsRenderableAtoms.nextSetBit(0);0<=c;c=this.bsRenderableAtoms.nextSetBit(c+1))if(d=b[c],this.gdata.isClippedZ(d.screenZ-(a?b[c].screenDiameter>>1:0)))d.setClickable(0),g=Clazz.doubleToInt((a?-1:1)*d.screenDiameter/2),(d.screenZ+g<e||d.screenZ-g>f||!this.gdata.isInDisplayRange(d.screenX,d.screenY))&&this.bsRenderableAtoms.clear(c)}if(0==this.modelSet.getAtomCount()||!this.viewer.getShowNavigationPoint())return null;a=2147483647;e=-2147483648;f=2147483647;g=-2147483648;
for(c=this.bsRenderableAtoms.nextSetBit(0);0<=c;c=this.bsRenderableAtoms.nextSetBit(c+1))d=b[c],d.screenX<a&&(a=d.screenX),d.screenX>e&&(e=d.screenX),d.screenY<f&&(f=d.screenY),d.screenY>g&&(g=d.screenY);this.navigationCrossHairMinMax[0]=a;this.navigationCrossHairMinMax[1]=e;this.navigationCrossHairMinMax[2]=f;this.navigationCrossHairMinMax[3]=g;return this.navigationCrossHairMinMax});$_M(c$,"setModelSet",function(a){this.modelSet=this.viewer.modelSet=a},"J.modelset.ModelSet");$_M(c$,"checkInheritedShapes",
function(){null!=this.shapes[24]&&this.setShapePropertyBs(24,"remapInherited",null,null)});$_M(c$,"restrictSelected",function(a,b){var c=J.util.BSUtil.copy(this.viewer.getSelectionSet(!0));if(b){this.viewer.invertSelection();var d=this.viewer.getSelectionSubset();null!=d&&(c=J.util.BSUtil.copy(this.viewer.getSelectionSet(!0)),c.and(d),this.viewer.select(c,!1,0,!0),J.util.BSUtil.invertInPlace(c,this.viewer.getAtomCount()),c.and(d))}J.util.BSUtil.andNot(c,this.viewer.getDeletedAtoms());d=this.viewer.getBoolean(603979812);
a||this.viewer.setBooleanProperty("bondModeOr",!0);this.setShapeSizeBs(1,0,null,null);this.setShapePropertyBs(1,"type",Integer.$valueOf(32768),null);this.setShapeSizeBs(1,0,null,null);this.setShapePropertyBs(1,"type",Integer.$valueOf(1023),null);for(var e=this.viewer.getSelectionSet(!1),f=21;0<=--f;)6!=f&&null!=this.getShape(f)&&this.setShapeSizeBs(f,0,null,e);null!=this.getShape(21)&&this.setShapePropertyBs(21,"delete",e,null);this.setLabel(null,e);a||this.viewer.setBooleanProperty("bondModeOr",
d);this.viewer.select(c,!1,0,!0)},"~B,~B");Clazz.defineStatics(c$,"hoverable",[30,25,24,22,35]);c$.clickableMax=c$.prototype.clickableMax=J.viewer.ShapeManager.hoverable.length-1}),Clazz.declarePackage("J.viewer"),Clazz.load(null,"J.viewer.ModelManager",["J.modelset.ModelLoader"],function(){c$=Clazz.decorateAsClass(function(){this.fileName=this.modelSetPathName=this.modelSet=this.viewer=null;Clazz.instantialize(this,arguments)},J.viewer,"ModelManager");Clazz.makeConstructor(c$,function(a){this.viewer=
a},"J.viewer.Viewer");$_M(c$,"zap",function(){this.modelSetPathName=this.fileName=null;new J.modelset.ModelLoader(this.viewer,this.viewer.getZapName(),null,null,null,null)});$_M(c$,"getModelSetFileName",function(){return null!=this.fileName?this.fileName:this.viewer.getZapName()});$_M(c$,"getModelSetPathName",function(){return this.modelSetPathName});$_M(c$,"createModelSet",function(a,b,c,d,e,f){var g=null;f?(g=this.modelSet.modelSetName,g.equals("zapped")?g=null:0>g.indexOf(" (modified)")&&(g+=" (modified)")):
null==d?this.zap():(this.modelSetPathName=a,this.fileName=b);null!=d&&(null==g&&(g=this.viewer.getModelAdapter().getAtomSetCollectionName(d),null!=g&&(g=g.trim(),0==g.length&&(g=null)),null==g&&(g=J.viewer.ModelManager.reduceFilename(b))),new J.modelset.ModelLoader(this.viewer,g,c,d,f?this.modelSet:null,e));0==this.modelSet.getAtomCount()&&!this.modelSet.getModelSetAuxiliaryInfoBoolean("isPyMOL")&&this.zap()},"~S,~S,JU.SB,~O,JU.BS,~B");c$.reduceFilename=$_M(c$,"reduceFilename",($fz=function(a){if(null==
a)return null;var b=a.indexOf(".");0<b&&(a=a.substring(0,b));24<a.length&&(a=a.substring(0,20)+" ...");return a},$fz.isPrivate=!0,$fz),"~S");$_M(c$,"createAtomDataSet",function(a,b){J.modelset.ModelLoader.createAtomDataSet(this.viewer,this.modelSet,b,a,this.viewer.getSelectionSet(!1))},"~O,~N")}),Clazz.declarePackage("J.viewer"),Clazz.load(["JU.BS"],"J.viewer.SelectionManager",["JU.ArrayUtil","J.i18n.GT","J.util.BSUtil"],function(){c$=Clazz.decorateAsClass(function(){this.bsDeleted=this.bsSubset=
this.bsFixed=this.bsSelection=this.bsHidden=this.listeners=this.viewer=null;this.empty=1;this.hideNotSelected=!1;this.bsTemp=null;Clazz.instantialize(this,arguments)},J.viewer,"SelectionManager");Clazz.prepareFields(c$,function(){this.listeners=[];this.bsHidden=new JU.BS;this.bsSelection=new JU.BS;this.bsFixed=new JU.BS;this.bsTemp=new JU.BS});Clazz.makeConstructor(c$,function(a){this.viewer=a},"J.viewer.Viewer");$_M(c$,"deleteModelAtoms",function(a){J.util.BSUtil.deleteBits(this.bsHidden,a);J.util.BSUtil.deleteBits(this.bsSelection,
a);J.util.BSUtil.deleteBits(this.bsSubset,a);J.util.BSUtil.deleteBits(this.bsFixed,a);J.util.BSUtil.deleteBits(this.bsDeleted,a)},"JU.BS");$_M(c$,"clear",function(){this.clearSelection(!0);this.hide(null,null,0,!0);this.setSelectionSubset(null);this.bsDeleted=null;this.setMotionFixedAtoms(null)});$_M(c$,"display",function(a,b,c,d){switch(c){default:c=a.getModelAtomBitSetIncludingDeleted(-1,!1),this.bsHidden.or(c);case 1276118017:null!=b&&this.bsHidden.andNot(b);break;case 1073742119:null!=b&&this.bsHidden.or(b)}J.util.BSUtil.andNot(this.bsHidden,
this.bsDeleted);a.setBsHidden(this.bsHidden);d||this.viewer.reportSelection(J.i18n.GT._("{0} atoms hidden",""+this.bsHidden.cardinality()))},"J.modelset.ModelSet,JU.BS,~N,~B");$_M(c$,"hide",function(a,b,c,d){J.viewer.SelectionManager.setBitSet(this.bsHidden,b,c);null!=a&&a.setBsHidden(this.bsHidden);d||this.viewer.reportSelection(J.i18n.GT._("{0} atoms hidden",""+this.bsHidden.cardinality()))},"J.modelset.ModelSet,JU.BS,~N,~B");$_M(c$,"setSelectionSet",function(a,b){J.viewer.SelectionManager.setBitSet(this.bsSelection,
a,b);this.empty=-1;this.selectionChanged(!1)},"JU.BS,~N");c$.setBitSet=$_M(c$,"setBitSet",($fz=function(a,b,c){switch(c){default:a.clearAll();case 1276118017:null!=b&&a.or(b);break;case 1073742119:null!=b&&a.andNot(b)}},$fz.isPrivate=!0,$fz),"JU.BS,JU.BS,~N");$_M(c$,"getHiddenSet",function(){return this.bsHidden});$_M(c$,"getHideNotSelected",function(){return this.hideNotSelected});$_M(c$,"setHideNotSelected",function(a){(this.hideNotSelected=a)&&this.selectionChanged(!1)},"~B");$_M(c$,"isSelected",
function(a){return 0<=a&&this.bsSelection.get(a)},"~N");$_M(c$,"select",function(a,b,c){null==a?(this.selectAll(!0),this.viewer.getBoolean(1613758476)||this.excludeSelectionSet(this.viewer.getAtomBits(1613758476,null)),this.viewer.getBoolean(1613758470)||this.excludeSelectionSet(this.viewer.getAtomBits(1613758470,null)),this.selectionChanged(!1)):this.setSelectionSet(a,b);if((a=this.viewer.getBoolean(603979880))||!c)b=this.getSelectionCount(),a?this.viewer.reportSelection((0==b?"No atoms":1==b?"1 atom":
b+" atoms")+" selected!"):c||this.viewer.reportSelection(J.i18n.GT._("{0} atoms selected",b))},"JU.BS,~N,~B");$_M(c$,"selectAll",function(a){var b=this.viewer.getAtomCount();for(this.empty=0==b?1:0;0<=--b;)this.bsSelection.set(b);J.util.BSUtil.andNot(this.bsSelection,this.bsDeleted);this.selectionChanged(a)},"~B");$_M(c$,"clearSelection",function(a){this.setHideNotSelected(!1);this.bsSelection.clearAll();this.empty=1;this.selectionChanged(a)},"~B");$_M(c$,"isAtomSelected",function(a){return((null==
this.bsSubset||this.bsSubset.get(a))&&null==this.bsDeleted||!this.bsDeleted.get(a))&&this.bsSelection.get(a)},"~N");$_M(c$,"setSelectedAtom",function(a,b){0>a?this.selectionChanged(!0):null!=this.bsSubset&&!this.bsSubset.get(a)||null!=this.bsDeleted&&this.bsDeleted.get(a)||(this.bsSelection.setBitTo(a,b),this.empty=b?0:-1)},"~N,~B");$_M(c$,"setSelectionSubset",function(a){this.bsSubset=a},"JU.BS");$_M(c$,"isInSelectionSubset",function(a){return 0>a||null==this.bsSubset||this.bsSubset.get(a)},"~N");
$_M(c$,"invertSelection",function(){J.util.BSUtil.invertInPlace(this.bsSelection,this.viewer.getAtomCount());this.empty=0<this.bsSelection.length()?0:1;this.selectionChanged(!1)});$_M(c$,"excludeSelectionSet",($fz=function(a){null==a||1==this.empty||(this.bsSelection.andNot(a),this.empty=-1)},$fz.isPrivate=!0,$fz),"JU.BS");$_M(c$,"getSelectionCount",function(){if(1==this.empty)return 0;this.empty=1;var a;null!=this.bsSubset?(this.bsTemp.clearAll(),this.bsTemp.or(this.bsSubset),this.bsTemp.and(this.bsSelection),
a=this.bsTemp):a=this.bsSelection;a=a.cardinality();0<a&&(this.empty=0);return a});$_M(c$,"addListener",function(a){for(var b=this.listeners.length;0<=--b;)if(this.listeners[b]===a){this.listeners[b]=null;break}for(var c=this.listeners.length,b=c;0<=--b;)if(null==this.listeners[b]){this.listeners[b]=a;return}this.listeners=0==this.listeners.length?Array(1):JU.ArrayUtil.doubleLength(this.listeners);this.listeners[c]=a},"J.api.JmolSelectionListener");$_M(c$,"selectionChanged",($fz=function(a){this.hideNotSelected&&
this.hide(this.viewer.getModelSet(),J.util.BSUtil.copyInvert(this.bsSelection,this.viewer.getAtomCount()),0,a);if(!(a||0==this.listeners.length))for(a=this.listeners.length;0<=--a;)null!=this.listeners[a]&&this.listeners[a].selectionChanged(this.bsSelection)},$fz.isPrivate=!0,$fz),"~B");$_M(c$,"deleteAtoms",function(a){var b=J.util.BSUtil.copy(a);null==this.bsDeleted?this.bsDeleted=b:(b.andNot(this.bsDeleted),this.bsDeleted.or(a));this.bsHidden.andNot(this.bsDeleted);this.bsSelection.andNot(this.bsDeleted);
return b.cardinality()},"JU.BS");$_M(c$,"getDeletedAtoms",function(){return this.bsDeleted});$_M(c$,"getSelectionSet",function(a){if(a||null==this.bsDeleted&&null==this.bsSubset)return this.bsSelection;a=new JU.BS;a.or(this.bsSelection);this.excludeAtoms(a,!1);return a},"~B");$_M(c$,"getSelectionSubset",function(){return this.bsSubset});$_M(c$,"excludeAtoms",function(a,b){null!=this.bsDeleted&&a.andNot(this.bsDeleted);!b&&null!=this.bsSubset&&a.and(this.bsSubset)},"JU.BS,~B");$_M(c$,"processDeletedModelAtoms",
function(a){null!=this.bsDeleted&&J.util.BSUtil.deleteBits(this.bsDeleted,a);null!=this.bsSubset&&J.util.BSUtil.deleteBits(this.bsSubset,a);J.util.BSUtil.deleteBits(this.bsFixed,a);J.util.BSUtil.deleteBits(this.bsHidden,a);var b=J.util.BSUtil.copy(this.bsSelection);J.util.BSUtil.deleteBits(b,a);this.setSelectionSet(b,0)},"JU.BS");$_M(c$,"setMotionFixedAtoms",function(a){this.bsFixed.clearAll();null!=a&&this.bsFixed.or(a)},"JU.BS");$_M(c$,"getMotionFixedAtoms",function(){return this.bsFixed});Clazz.defineStatics(c$,
"TRUE",1,"FALSE",0,"UNKNOWN",-1)}),Clazz.declarePackage("J.viewer"),Clazz.load(["java.util.Hashtable"],"J.viewer.StatusManager","java.lang.Boolean $.Float javajs.awt.Dimension JU.List J.api.Interface J.constant.EnumCallback J.util.Logger $.Txt".split(" "),function(){c$=Clazz.decorateAsClass(function(){this.jmolCallbackListener=this.jmolStatusListener=this.viewer=null;this.statusList="";this.allowStatusReporting=!1;this.messageQueue=null;this.statusPtr=0;this.jmolScriptCallbacks=null;this.minSyncRepeatMs=
100;this.stereoSync=this.syncDisabled=this.isSynced=this.drivingSync=this.syncingMouse=this.syncingScripts=!1;this.qualityPNG=this.qualityJPG=-1;this.imageType=null;Clazz.instantialize(this,arguments)},J.viewer,"StatusManager");Clazz.prepareFields(c$,function(){this.messageQueue=new java.util.Hashtable;this.jmolScriptCallbacks=new java.util.Hashtable});Clazz.makeConstructor(c$,function(a){this.viewer=a},"J.viewer.Viewer");$_M(c$,"setAllowStatusReporting",function(a){this.allowStatusReporting=a},"~B");
$_M(c$,"getStatusList",function(){return this.statusList});$_M(c$,"getMessageQueue",function(){return this.messageQueue});$_M(c$,"recordStatus",($fz=function(a){return this.allowStatusReporting&&0<this.statusList.length&&(this.statusList.equals("all")||0<=this.statusList.indexOf(a))},$fz.isPrivate=!0,$fz),"~S");$_M(c$,"setStatusChanged",($fz=function(a,b,c,d){if(this.recordStatus(a)){var e=new JU.List;e.addLast(Integer.$valueOf(++this.statusPtr));e.addLast(a);e.addLast(Integer.$valueOf(b));e.addLast(c);
b=d?null:this.messageQueue.get(a);null==b?this.messageQueue.put(a,b=new JU.List):b.size()==J.viewer.StatusManager.MAXIMUM_QUEUE_LENGTH&&b.remove(0);b.addLast(e)}},$fz.isPrivate=!0,$fz),"~S,~N,~O,~B");$_M(c$,"getStatusChanged",function(a){var b=0<a.length&&"-"==a.charAt(0),c=0<a.length&&"+"==a.charAt(0),d=!1;b?this.statusList=J.util.Txt.simpleReplace(this.statusList,a.substring(1,a.length),""):(a=J.util.Txt.simpleReplace(a,"+",""),this.statusList.equals(a)||c&&0<=this.statusList.indexOf(a)?d=!0:(c||
(this.statusList=""),this.statusList+=a,J.util.Logger.debugging&&J.util.Logger.debug("StatusManager messageQueue = "+this.statusList)));a=new JU.List;if(d)for(var e,d=this.messageQueue.entrySet().iterator();d.hasNext()&&((e=d.next())||1);)a.addLast(e.getValue());this.messageQueue.clear();this.statusPtr=0;return a},"~S");$_M(c$,"setJmolStatusListener",function(a,b){this.jmolStatusListener=a;this.jmolCallbackListener=null==b?a:b},"J.api.JmolStatusListener,J.api.JmolCallbackListener");$_M(c$,"setJmolCallbackListener",
function(a){this.jmolCallbackListener=a},"J.api.JmolCallbackListener");$_M(c$,"jmolScriptCallback",($fz=function(a){a=this.jmolScriptCallbacks.get(a);null!=a&&this.viewer.evalStringQuietSync(a,!0,!1);return a},$fz.isPrivate=!0,$fz),"J.constant.EnumCallback");$_M(c$,"setCallbackFunction",function(a,b){var c=J.constant.EnumCallback.getCallback(a);if(null!=c){var d=null==b?0:7<b.length&&0==b.toLowerCase().indexOf("script:")?7:11<b.length&&0==b.toLowerCase().indexOf("jmolscript:")?11:0;0==d?this.jmolScriptCallbacks.remove(c):
this.jmolScriptCallbacks.put(c,b.substring(d).trim())}null!=this.jmolCallbackListener&&this.jmolCallbackListener.setCallbackFunction(a,b)},"~S,~S");$_M(c$,"notifyEnabled",($fz=function(a){return null!=this.jmolCallbackListener&&this.jmolCallbackListener.notifyEnabled(a)},$fz.isPrivate=!0,$fz),"J.constant.EnumCallback");$_M(c$,"setStatusAppletReady",function(a,b){var c=b?this.jmolScriptCallback(J.constant.EnumCallback.APPLETREADY):null;this.notifyEnabled(J.constant.EnumCallback.APPLETREADY)&&this.jmolCallbackListener.notifyCallback(J.constant.EnumCallback.APPLETREADY,
[c,a,Boolean.$valueOf(b),null])},"~S,~B");$_M(c$,"setStatusAtomMoved",function(a){var b=this.jmolScriptCallback(J.constant.EnumCallback.ATOMMOVED);this.setStatusChanged("atomMoved",-1,a,!1);this.notifyEnabled(J.constant.EnumCallback.ATOMMOVED)&&this.jmolCallbackListener.notifyCallback(J.constant.EnumCallback.ATOMMOVED,[b,a])},"JU.BS");$_M(c$,"setStatusAtomPicked",function(a,b){var c=this.jmolScriptCallback(J.constant.EnumCallback.PICK);J.util.Logger.info("setStatusAtomPicked("+a+","+b+")");this.setStatusChanged("atomPicked",
a,b,!1);this.notifyEnabled(J.constant.EnumCallback.PICK)&&this.jmolCallbackListener.notifyCallback(J.constant.EnumCallback.PICK,[c,b,Integer.$valueOf(a)])},"~N,~S");$_M(c$,"setStatusClicked",function(a,b,c,d,e){var f=this.jmolScriptCallback(J.constant.EnumCallback.CLICK);if(!this.notifyEnabled(J.constant.EnumCallback.CLICK))return c;e=[c,e];this.jmolCallbackListener.notifyCallback(J.constant.EnumCallback.CLICK,[f,Integer.$valueOf(a),Integer.$valueOf(b),Integer.$valueOf(c),Integer.$valueOf(d),e]);
return e[0]},"~N,~N,~N,~N,~N");$_M(c$,"setStatusResized",function(a,b){var c=this.jmolScriptCallback(J.constant.EnumCallback.RESIZE);this.notifyEnabled(J.constant.EnumCallback.RESIZE)&&this.jmolCallbackListener.notifyCallback(J.constant.EnumCallback.RESIZE,[c,Integer.$valueOf(a),Integer.$valueOf(b)])},"~N,~N");$_M(c$,"setStatusAtomHovered",function(a,b){var c=this.jmolScriptCallback(J.constant.EnumCallback.HOVER);this.notifyEnabled(J.constant.EnumCallback.HOVER)&&this.jmolCallbackListener.notifyCallback(J.constant.EnumCallback.HOVER,
[c,b,Integer.$valueOf(a)])},"~N,~S");$_M(c$,"setStatusObjectHovered",function(a,b,c){var d=this.jmolScriptCallback(J.constant.EnumCallback.HOVER);this.notifyEnabled(J.constant.EnumCallback.HOVER)&&this.jmolCallbackListener.notifyCallback(J.constant.EnumCallback.HOVER,[d,b,Integer.$valueOf(-1),a,Float.$valueOf(c.x),Float.$valueOf(c.y),Float.$valueOf(c.z)])},"~S,~S,JU.P3");$_M(c$,"setFileLoadStatus",function(a,b,c,d,e,f,g){null==a&&"resetUndo".equals(b)&&(b=this.viewer.getProperty("DATA_API","getAppConsole",
null),null!=b&&b.zap(),b=this.viewer.getZapName());this.setStatusChanged("fileLoaded",e,a,!1);null!=d&&this.setStatusChanged("fileLoadError",e,d,!1);var h=this.jmolScriptCallback(J.constant.EnumCallback.LOADSTRUCT);f&&this.notifyEnabled(J.constant.EnumCallback.LOADSTRUCT)&&(f=this.viewer.getParameter("_smilesString"),0!=f.length&&(b=f),this.jmolCallbackListener.notifyCallback(J.constant.EnumCallback.LOADSTRUCT,[h,a,b,c,d,Integer.$valueOf(e),this.viewer.getParameter("_modelNumber"),this.viewer.getModelNumberDotted(this.viewer.getModelCount()-
1),g]))},"~S,~S,~S,~S,~N,~B,Boolean");$_M(c$,"setStatusFrameChanged",function(a,b,c,d,e,f,g){if(null!=this.viewer.getModelSet()){var h=this.viewer.isAnimationOn();this.setStatusChanged("frameChanged",a,0<=a?this.viewer.getModelNumberDotted(a):"",!1);var k=this.jmolScriptCallback(J.constant.EnumCallback.ANIMFRAME);h&&(a=-2-a);this.notifyEnabled(J.constant.EnumCallback.ANIMFRAME)&&this.jmolCallbackListener.notifyCallback(J.constant.EnumCallback.ANIMFRAME,[k,[a,b,c,d,e,f],g]);null!=this.viewer.jmolpopup&&
!h&&this.viewer.jmolpopup.jpiUpdateComputedMenus()}},"~N,~N,~N,~N,~N,~N,~S");$_M(c$,"setScriptEcho",function(a,b){if(null!=a){this.setStatusChanged("scriptEcho",0,a,!1);var c=this.jmolScriptCallback(J.constant.EnumCallback.ECHO);this.notifyEnabled(J.constant.EnumCallback.ECHO)&&this.jmolCallbackListener.notifyCallback(J.constant.EnumCallback.ECHO,[c,a,Integer.$valueOf(b?1:0)])}},"~S,~B");$_M(c$,"setStatusMeasuring",function(a,b,c,d){this.setStatusChanged(a,b,c,!1);var e=null;a.equals("measureCompleted")?
(J.util.Logger.info("measurement["+b+"] = "+c),e=this.jmolScriptCallback(J.constant.EnumCallback.MEASURE)):a.equals("measurePicked")&&(this.setStatusChanged("measurePicked",b,c,!1),J.util.Logger.info("measurePicked "+b+" "+c));this.notifyEnabled(J.constant.EnumCallback.MEASURE)&&this.jmolCallbackListener.notifyCallback(J.constant.EnumCallback.MEASURE,[e,c,Integer.$valueOf(b),a,Float.$valueOf(d)])},"~S,~N,~S,~N");$_M(c$,"notifyError",function(a,b,c){var d=this.jmolScriptCallback(J.constant.EnumCallback.ERROR);
this.notifyEnabled(J.constant.EnumCallback.ERROR)&&this.jmolCallbackListener.notifyCallback(J.constant.EnumCallback.ERROR,[d,a,b,this.viewer.getShapeErrorState(),c])},"~S,~S,~S");$_M(c$,"notifyMinimizationStatus",function(a,b,c,d,e){var f=this.jmolScriptCallback(J.constant.EnumCallback.MINIMIZATION);this.notifyEnabled(J.constant.EnumCallback.MINIMIZATION)&&this.jmolCallbackListener.notifyCallback(J.constant.EnumCallback.MINIMIZATION,[f,a,b,c,d,e])},"~S,Integer,Float,Float,~S");$_M(c$,"setScriptStatus",
function(a,b,c,d){if(-1>c){var e=-2-c;this.setStatusChanged("scriptStarted",e,b,!1);a="script "+e+" started"}else if(null==a)return;var e=0==c?this.jmolScriptCallback(J.constant.EnumCallback.SCRIPT):null,f="Script completed"===a;if(this.recordStatus("script")){var g=null!=d;this.setStatusChanged(g?"scriptError":"scriptStatus",0,a,!1);if(g||f)this.setStatusChanged("scriptTerminated",1,"Jmol script terminated"+(g?" unsuccessfully: "+a:" successfully"),!1)}f&&(this.viewer.getBoolean(603979880)&&this.viewer.getBoolean(603979824))&&
(a=[null,"script <exiting>",b,Integer.$valueOf(-1),d],this.notifyEnabled(J.constant.EnumCallback.SCRIPT)&&this.jmolCallbackListener.notifyCallback(J.constant.EnumCallback.SCRIPT,a),this.processScript(a),a="Jmol script completed.");a=[e,a,b,Integer.$valueOf(f?-1:c),d];this.notifyEnabled(J.constant.EnumCallback.SCRIPT)&&this.jmolCallbackListener.notifyCallback(J.constant.EnumCallback.SCRIPT,a);this.processScript(a)},"~S,~S,~N,~S");$_M(c$,"processScript",($fz=function(a){var b=a[3].intValue();null!=
this.viewer.scriptEditor&&(0<b?this.viewer.scriptEditor.notifyScriptTermination():0>b?-2==b&&this.viewer.scriptEditor.notifyScriptStart():this.viewer.scriptEditor.isVisible()&&0<a[2].length&&this.viewer.scriptEditor.notifyContext(this.viewer.getScriptContext("SE notify"),a));null!=this.viewer.appConsole&&0==b&&this.viewer.appConsole.sendConsoleMessage(null==a[1]?null:a[1].toString())},$fz.isPrivate=!0,$fz),"~A");$_M(c$,"doSync",function(){return this.isSynced&&this.drivingSync&&!this.syncDisabled});
$_M(c$,"setSync",function(a){this.syncingMouse?null!=a&&this.syncSend(a,"*",0):this.syncingScripts||this.syncSend("!"+this.viewer.getMoveToText(this.minSyncRepeatMs/1E3),"*",0)},"~S");$_M(c$,"setSyncDriver",function(a){this.stereoSync&&4!=a&&(this.syncSend("SET_GRAPHICS_OFF","*",0),this.stereoSync=!1);switch(a){case 4:if(!this.syncDisabled)return;this.syncDisabled=!1;break;case 3:this.syncDisabled=!0;break;case 5:this.stereoSync=this.isSynced=this.drivingSync=!0;break;case 1:this.isSynced=this.drivingSync=
!0;break;case 2:this.drivingSync=!1;this.isSynced=!0;break;default:this.isSynced=this.drivingSync=!1}J.util.Logger.debugging&&J.util.Logger.debug(this.viewer.getHtmlName()+" sync mode="+a+"; synced? "+this.isSynced+"; driving? "+this.drivingSync+"; disabled? "+this.syncDisabled)},"~N");$_M(c$,"syncSend",function(a,b,c){(0!=c||this.notifyEnabled(J.constant.EnumCallback.SYNC))&&this.jmolCallbackListener.notifyCallback(J.constant.EnumCallback.SYNC,[null,a,b,Integer.$valueOf(c)])},"~S,~S,~N");$_M(c$,
"modifySend",function(a,b,c){this.notifyEnabled(J.constant.EnumCallback.STRUCTUREMODIFIED)&&this.jmolCallbackListener.notifyCallback(J.constant.EnumCallback.STRUCTUREMODIFIED,[null,Integer.$valueOf(c),Integer.$valueOf(a),Integer.$valueOf(b)])},"~N,~N,~N");$_M(c$,"getSyncMode",function(){return!this.isSynced?0:this.drivingSync?1:2});$_M(c$,"showUrl",function(a){null!=this.jmolStatusListener&&this.jmolStatusListener.showUrl(a)},"~S");$_M(c$,"clearConsole",function(){null!=this.viewer.appConsole&&this.viewer.appConsole.sendConsoleMessage(null);
null!=this.jmolStatusListener&&this.jmolCallbackListener.notifyCallback(J.constant.EnumCallback.MESSAGE,null)});$_M(c$,"functionXY",function(a,b,c){return null==this.jmolStatusListener?Clazz.newFloatArray(Math.abs(b),Math.abs(c),0):this.jmolStatusListener.functionXY(a,b,c)},"~S,~N,~N");$_M(c$,"functionXYZ",function(a,b,c,d){return null==this.jmolStatusListener?Clazz.newFloatArray(Math.abs(b),Math.abs(c),Math.abs(c),0):this.jmolStatusListener.functionXYZ(a,b,c,d)},"~S,~N,~N,~N");$_M(c$,"jsEval",function(a){return null==
this.jmolStatusListener?"":this.jmolStatusListener.eval(a)},"~S");$_M(c$,"createImage",function(a,b,c,d,e){return null==this.jmolStatusListener?null:this.jmolStatusListener.createImage(a,b,null==c?d:c,e)},"~S,~S,~S,~A,~N");$_M(c$,"getRegistryInfo",function(){return null==this.jmolStatusListener?null:this.jmolStatusListener.getRegistryInfo()});$_M(c$,"dialogAsk",function(a,b){var c=a.equals("Save Image"),d=J.api.Interface.getOptionInterface("dialog.Dialog");if(null==d)return null;d.setupUI(!1);c&&
d.setImageInfo(this.qualityJPG,this.qualityPNG,this.imageType);var e=d.getFileNameFromDialog(this.viewer,a,b);c&&null!=e&&(this.qualityJPG=d.getQuality("JPG"),this.qualityPNG=d.getQuality("PNG"),c=d.getType(),null!=c&&(this.imageType=c));return e},"~S,~S");$_M(c$,"getJspecViewProperties",function(a){return null==this.jmolStatusListener?null:this.jmolStatusListener.getProperty("JSpecView"+(null==a||0==a.length?"":":"+a))},"~S");$_M(c$,"resizeInnerPanel",function(a,b){return null==this.jmolStatusListener?
new javajs.awt.Dimension(a,b):this.jmolStatusListener.resizeInnerPanel("preferredWidthHeight "+a+" "+b+";")},"~N,~N");Clazz.defineStatics(c$,"MAXIMUM_QUEUE_LENGTH",16,"SYNC_OFF",0,"SYNC_DRIVER",1,"SYNC_SLAVE",2,"SYNC_DISABLE",3,"SYNC_ENABLE",4,"SYNC_STEREO",5)}),Clazz.declarePackage("J.viewer"),Clazz.load("JU.A4 $.M3 $.M4 $.P3 $.P3i $.V3 J.constant.EnumStereoMode".split(" "),"J.viewer.TransformManager","java.lang.Boolean $.Float java.util.Hashtable JU.P4 $.SB J.api.Interface J.util.Escape $.Logger $.Quaternion".split(" "),
function(){c$=Clazz.decorateAsClass(function(){this.viewer=null;this.perspectiveModel=11;this.modelRadiusPixels=this.modelRadius=this.modelCenterOffset=this.cameraDistanceFromCenter=this.aperatureAngle=this.referencePlaneOffset=this.cameraScaleFactor=0;this.navigationShiftXY=this.navigationOffset=this.navigationCenter=null;this.navigationDepth=0;this.vectorTemp=this.matrixTemp=null;this.haveNotifiedNaN=!1;this.spinX=0;this.spinY=30;this.spinZ=0;this.spinFps=30;this.navZ=this.navY=this.navX=0;this.navFps=
NaN;this.isSpinSelected=this.isSpinFixed=this.isSpinInternal=!1;this.rotationCenterDefault=this.perspectiveShiftXY=this.perspectiveOffset=this.fixedRotationCenter=this.fixedRotationOffset=null;this.rotationRadiusDefault=0;this.internalRotationCenter=this.internalTranslation=this.internalRotationAxis=this.fixedRotationAxis=null;this.internalRotationAngle=0;this.rotationAxis=this.pointT2=this.vectorT2=this.vectorT=this.axisangleT=this.matrixTemp4=this.matrixTemp3=this.matrixRotate=null;this.rotationRate=
0;this.cameraSetting=this.camera=this.fixedTranslation=this.arcBall0Rotation=this.arcBallAxis=this.arcBall1=this.arcBall0=null;this.yTranslationFraction=this.xTranslationFraction=0.5;this.previousY=this.previousX=this.prevZoomSetting=0;this.zoomEnabled=!0;this.zoomPercentSetting=this.zoomPercent=100;this.zoomRatio=0;this.zShadeEnabled=this.internalSlab=this.slabEnabled=!1;this.depthPercentSetting=this.slabPercentSetting=0;this.zSlabPercentSetting=50;this.zDepthPercentSetting=0;this.zSlabPoint=null;
this.slabRange=this.zDepthValue=this.zSlabValue=this.depthValue=this.slabValue=0;this.depthPlane=this.slabPlane=null;this.perspectiveDepth=!0;this.scale3D=!1;this.cameraDepthSetting=this.cameraDepth=3;this.visualRange=0;this.cameraDistance=1E3;this.scale3DAngstromsPerInch=this.scaleDefaultPixelsPerAngstrom=this.scalePixelsPerAngstrom=this.screenPixelCount=this.height=this.width=0;this.zoomHeight=this.useZoomLarge=this.antialias=!1;this.screenHeight=this.screenWidth=0;this.ptVibTemp=this.point3iScreenTemp=
this.point3fScreenTemp=this.matrixTransformInv=this.matrixTransform=null;this.navigating=!1;this.defaultMode=this.mode=0;this.motion=this.matrixTest=this.aaTest1=this.ptTest3=this.ptTest2=this.ptTest1=this.untransformedPoint=this.pointTsp=null;this.navOn=this.spinOn=!1;this.spinThread=null;this.vibrationOn=this.spinIsGesture=!1;this.vibrationT=this.vibrationScale=this.vibrationPeriodMs=this.vibrationPeriod=0;this.stereoColors=this.stereoMode=this.vibrationThread=null;this.stereoDegrees=NaN;this.stereoRadians=
0;this.stereoFrame=!1;this.matrixStereo=null;this.windowCentered=!1;this.ptOffset=this.bsSelectedAtoms=this.frameOffset=this.frameOffsets=null;this.navMode=1;this.zoomFactor=3.4028235E38;this.navigationSlabOffset=0;this.nav=null;Clazz.instantialize(this,arguments)},J.viewer,"TransformManager");Clazz.prepareFields(c$,function(){this.navigationCenter=new JU.P3;this.navigationOffset=new JU.P3;this.navigationShiftXY=new JU.P3;this.matrixTemp=new JU.M4;this.vectorTemp=new JU.V3;this.fixedRotationOffset=
new JU.P3;this.fixedRotationCenter=new JU.P3;this.perspectiveOffset=new JU.P3;this.perspectiveShiftXY=new JU.P3;this.rotationCenterDefault=new JU.P3;this.fixedRotationAxis=new JU.A4;this.internalRotationAxis=new JU.A4;this.internalRotationCenter=JU.P3.new3(0,0,0);this.matrixRotate=new JU.M3;this.matrixTemp3=new JU.M3;this.matrixTemp4=new JU.M4;this.axisangleT=new JU.A4;this.vectorT=new JU.V3;this.vectorT2=new JU.V3;this.pointT2=new JU.P3;this.rotationAxis=new JU.V3;this.arcBall0=new JU.V3;this.arcBall1=
new JU.V3;this.arcBallAxis=new JU.V3;this.arcBall0Rotation=new JU.M3;this.fixedTranslation=new JU.P3;this.camera=new JU.P3;this.cameraSetting=new JU.P3;this.matrixTransform=new JU.M4;this.matrixTransformInv=new JU.M4;this.point3fScreenTemp=new JU.P3;this.point3iScreenTemp=new JU.P3i;this.ptVibTemp=new JU.P3;this.pointTsp=new JU.P3;this.untransformedPoint=new JU.P3;this.ptTest1=new JU.P3;this.ptTest2=new JU.P3;this.ptTest3=new JU.P3;this.aaTest1=new JU.A4;this.matrixTest=new JU.M3;this.stereoMode=
J.constant.EnumStereoMode.NONE;this.matrixStereo=new JU.M3;this.frameOffset=new JU.P3;this.ptOffset=new JU.P3});Clazz.makeConstructor(c$,function(a,b,c){this.setViewer(a,b,c)},"J.viewer.Viewer,~N,~N");$_M(c$,"setViewer",($fz=function(a,b,c){this.viewer=a;this.setScreenParameters(b,c,!0,!1,!0,!0)},$fz.isPrivate=!0,$fz),"J.viewer.Viewer,~N,~N");$_M(c$,"homePosition",function(a){a&&this.setSpinOff();this.setNavOn(!1);this.navFps=10;this.navX=this.navY=this.navZ=0;this.rotationCenterDefault.setT(this.viewer.getBoundBoxCenter());
this.setFixedRotationCenter(this.rotationCenterDefault);this.rotationRadiusDefault=this.setRotationRadius(0,!0);this.windowCentered=!0;this.setRotationCenterAndRadiusXYZ(null,!0);this.matrixRotate.setIdentity();a=this.viewer.getModelSetAuxiliaryInfoValue("defaultOrientationMatrix");null!=a&&this.matrixRotate.setM(a);this.setZoomEnabled(!0);this.zoomToPercent(this.viewer.global.modelKitMode?50:100);this.zoomPercent=this.zoomPercentSetting;this.slabReset();this.resetFitToScreen(!0);this.viewer.isJmolDataFrame()?
this.fixedRotationCenter.set(0,0,0):this.viewer.global.axesOrientationRasmol&&this.rotateX(3.141592653589793);this.viewer.saveOrientation("default",null);1==this.mode&&this.setNavigationMode(!0)},"~B");$_M(c$,"clear",function(){this.clearVibration();this.clearSpin();this.stopMotion();this.fixedRotationCenter.set(0,0,0);this.navigating=!1;this.zSlabPoint=this.depthPlane=this.slabPlane=null;this.resetNavigationPoint(!0)});$_M(c$,"setFixedRotationCenter",($fz=function(a){null!=a&&this.fixedRotationCenter.setT(a)},
$fz.isPrivate=!0,$fz),"JU.P3");$_M(c$,"setRotationPointXY",function(a){a=this.transformPoint(a);this.fixedTranslation.set(a.x,a.y,0)},"JU.P3");$_M(c$,"spinXYBy",function(a,b,c){if(0==a&&0==b)null!=this.spinThread&&this.spinIsGesture&&this.clearSpin();else{this.clearSpin();var d=JU.P3.newP(this.fixedRotationCenter),e=new JU.P3;this.transformPoint2(d,e);a=JU.P3.new3(-b,a,0);a.add(e);this.unTransformPoint(a,a);this.viewer.setInMotion(!1);this.rotateAboutPointsInternal(null,a,d,10*c,NaN,!1,!0,null,!0,
null,null,null)}},"~N,~N,~N");$_M(c$,"rotateArcBall",function(a,b,c){var d=(this.screenPixelCount>>2)*this.screenPixelCount;a-=this.fixedTranslation.x;b-=this.fixedTranslation.y;d=d-a*a-b*b;d=(0>d?-1:1)*Math.sqrt(Math.abs(d));0==c?(this.arcBall0Rotation.setM(this.matrixRotate),this.arcBall0.set(a,-b,d),Float.isNaN(d)||this.arcBall0.normalize()):!Float.isNaN(this.arcBall0.z)&&!Float.isNaN(d)&&(this.arcBall1.set(a,-b,d),this.arcBall1.normalize(),this.arcBallAxis.cross(this.arcBall0,this.arcBall1),this.axisangleT.setVA(this.arcBallAxis,
c*Math.acos(this.arcBall0.dot(this.arcBall1))),this.matrixRotate.setM(this.arcBall0Rotation),this.rotateAxisAngle2(this.axisangleT,null))},"~N,~N,~N");$_M(c$,"rotateXYBy",function(a,b,c){this.rotateXRadians(0.017453292*b,c);this.rotateYRadians(0.017453292*a,c)},"~N,~N,JU.BS");$_M(c$,"rotateZBy",function(a,b,c){2147483647!=b&&2147483647!=c&&this.resetXYCenter(b,c);this.rotateZRadians(a/57.29577951308232)},"~N,~N,~N");$_M(c$,"rotateFront",function(){this.matrixRotate.setIdentity()});$_M(c$,"rotateX",
function(a){this.matrixRotate.rotX(a)},"~N");$_M(c$,"rotateY",function(a){this.matrixRotate.rotY(a)},"~N");$_M(c$,"rotateZ",function(a){this.matrixRotate.rotZ(a)},"~N");$_M(c$,"applyRotation",($fz=function(a,b,c,d){null==c?this.matrixRotate.mul2(a,this.matrixRotate):(this.viewer.moveAtoms(a,this.matrixRotate,d,this.internalRotationCenter,b,c),null!=d&&this.internalRotationCenter.add(d))},$fz.isPrivate=!0,$fz),"JU.M3,~B,JU.BS,JU.V3");$_M(c$,"rotateXRadians",function(a,b){this.matrixTemp3.rotX(a);this.applyRotation(this.matrixTemp3,
!1,b,null)},"~N,JU.BS");$_M(c$,"rotateYRadians",function(a,b){this.matrixTemp3.rotY(a);this.applyRotation(this.matrixTemp3,!1,b,null)},"~N,JU.BS");$_M(c$,"rotateZRadians",function(a){this.matrixTemp3.rotZ(a);this.applyRotation(this.matrixTemp3,!1,null,null)},"~N");$_M(c$,"rotateAxisAngle",function(a,b){this.axisangleT.setVA(a,b);this.rotateAxisAngle2(this.axisangleT,null)},"JU.V3,~N");$_M(c$,"rotateAxisAngle2",($fz=function(a,b){this.matrixTemp3.setAA(a);this.applyRotation(this.matrixTemp3,!1,b,null)},
$fz.isPrivate=!0,$fz),"JU.A4,JU.BS");$_M(c$,"rotateAxisAngleAtCenter",function(a,b,c,d,e,f,g){null!=b&&this.moveRotationCenter(b,!0);this.setSpinOff();this.setNavOn(!1);if(this.viewer.isHeadless()){if(f&&3.4028235E38==e)return!1;f=!1}if(Float.isNaN(d)||0==d||0==e)return!1;null!=b&&this.setRotationPointXY(b);this.setFixedRotationCenter(b);this.rotationAxis.setT(c);this.rotationRate=d;if(f)return this.fixedRotationAxis.setVA(c,0.017453292*d),this.isSpinInternal=!1,this.isSpinFixed=!0,this.isSpinSelected=
null!=g,this.setSpin(a,!0,e,null,null,g,!1),!1;a=0.017453292*e;this.fixedRotationAxis.setVA(c,e);this.rotateAxisAngleRadiansFixed(a,g);return!0},"J.api.JmolScriptEvaluator,JU.P3,JU.V3,~N,~N,~B,JU.BS");$_M(c$,"rotateAxisAngleRadiansFixed",function(a,b){this.axisangleT.setAA(this.fixedRotationAxis);this.axisangleT.angle=a;this.rotateAxisAngle2(this.axisangleT,b)},"~N,JU.BS");$_M(c$,"rotateAboutPointsInternal",function(a,b,c,d,e,f,g,h,k,l,m,n){this.setSpinOff();this.setNavOn(!1);if(this.viewer.isHeadless()){if(g&&
3.4028235E38==e)return!1;g=!1}if(null==n&&(null==l||0.001>l.length())&&(!g||0==e||Float.isNaN(d)||0==d)&&(g||0==e))return!1;var q=null;null==n&&(q=JU.V3.newVsub(c,b),f&&q.scale(-1),this.internalRotationCenter.setT(b),this.rotationAxis.setT(q),this.internalTranslation=null==l?null:JU.V3.newV(l));b=null!=h;if(g)return null==n?(g=Clazz.doubleToInt(Math.abs(e)/Math.abs(d)*this.spinFps+0.5),Float.isNaN(e)?this.rotationRate=d:(this.rotationRate=e/g*this.spinFps,null!=l&&this.internalTranslation.scale(1/
g)),this.internalRotationAxis.setVA(q,0.017453292*this.rotationRate),this.isSpinInternal=!0,this.isSpinFixed=!1,this.isSpinSelected=b):e=d,this.setSpin(a,!0,e,m,n,h,k),null!=n||null!=h;a=0.017453292*e;this.internalRotationAxis.setVA(q,a);this.rotateAxisAngleRadiansInternal(a,h);return!1},"J.api.JmolScriptEvaluator,JU.P3,JU.P3,~N,~N,~B,~B,JU.BS,~B,JU.V3,JU.List,~A");$_M(c$,"rotateAxisAngleRadiansInternal",function(a,b){this.internalRotationAngle=a;this.vectorT.set(this.internalRotationAxis.x,this.internalRotationAxis.y,
this.internalRotationAxis.z);this.matrixRotate.transform2(this.vectorT,this.vectorT2);this.axisangleT.setVA(this.vectorT2,a);this.matrixTemp3.setAA(this.axisangleT);this.applyRotation(this.matrixTemp3,!0,b,this.internalTranslation);null==b&&this.getNewFixedRotationCenter()},"~N,JU.BS");$_M(c$,"getNewFixedRotationCenter",function(){this.axisangleT.setAA(this.internalRotationAxis);this.axisangleT.angle=-this.internalRotationAngle;this.matrixTemp4.setAA(this.axisangleT);this.vectorT.setT(this.internalRotationCenter);
this.pointT2.setT(this.fixedRotationCenter);this.pointT2.sub(this.vectorT);var a=new JU.P3;this.matrixTemp4.transform2(this.pointT2,a);a.add(this.vectorT);this.setRotationCenterAndRadiusXYZ(a,!1)});$_M(c$,"setTranslationFractions",function(){this.xTranslationFraction=this.fixedTranslation.x/this.width;this.yTranslationFraction=this.fixedTranslation.y/this.height});$_M(c$,"centerAt",function(a,b,c){null==c?this.translateXYBy(a,b):(this.windowCentered&&this.viewer.setBooleanProperty("windowCentered",
!1),this.fixedTranslation.x=a,this.fixedTranslation.y=b,this.setFixedRotationCenter(c))},"~N,~N,JU.P3");$_M(c$,"percentToPixels",function(a,b){switch(a){case "x":return Clazz.doubleToInt(Math.floor(b/100*this.width));case "y":return Clazz.doubleToInt(Math.floor(b/100*this.height));case "z":return Clazz.doubleToInt(Math.floor(b/100*this.screenPixelCount))}return 0},"~S,~N");$_M(c$,"angstromsToPixels",function(a){return Clazz.doubleToInt(Math.floor(this.scalePixelsPerAngstrom*a))},"~N");$_M(c$,"translateXYBy",
function(a,b){this.fixedTranslation.x+=a;this.fixedTranslation.y+=b;this.setTranslationFractions()},"~N,~N");$_M(c$,"setCamera",function(a,b){this.cameraSetting.set(a,b,0==a&&0==b?0:1)},"~N,~N");$_M(c$,"translateToPercent",function(a,b){switch(a){case "x":this.xTranslationFraction=0.5+b/100;this.fixedTranslation.x=this.width*this.xTranslationFraction;break;case "y":this.yTranslationFraction=0.5+b/100;this.fixedTranslation.y=this.height*this.yTranslationFraction;break;case "z":1==this.mode&&this.setNavigationDepthPercent(b)}},
"~S,~N");$_M(c$,"getTranslationXPercent",function(){return 0==this.width?0:100*(this.fixedTranslation.x-this.width/2)/this.width});$_M(c$,"getTranslationYPercent",function(){return 0==this.height?0:100*(this.fixedTranslation.y-this.height/2)/this.height});$_M(c$,"getTranslationZPercent",function(){return 0});$_M(c$,"getTranslationScript",function(){var a="",b=this.getTranslationXPercent();0!=b&&(a+="translate x "+b+";");b=this.getTranslationYPercent();0!=b&&(a+="translate y "+b+";");return a});$_M(c$,
"getOrientationText",function(a){switch(a){case 4130:return this.getMoveToText(1,!1);case 1073742132:return this.getRotationQuaternion().toString();case 1073742178:return a=new JU.SB,J.viewer.TransformManager.truncate2(a,this.getTranslationXPercent()),J.viewer.TransformManager.truncate2(a,this.getTranslationYPercent()),a.toString();default:return this.getMoveToText(1,!0)+"\n#OR\n"+this.getRotateZyzText(!0)}},"~N");$_M(c$,"getOrientationInfo",function(){var a=new java.util.Hashtable;a.put("moveTo",
this.getMoveToText(1,!1));a.put("center","center "+this.getCenterText());a.put("centerPt",this.fixedRotationCenter);var b=new JU.A4;this.getAxisAngle(b);a.put("axisAngle",b);a.put("quaternion",J.util.Quaternion.newAA(b).toPoint4f());a.put("rotationMatrix",this.matrixRotate);a.put("rotateZYZ",this.getRotateZyzText(!1));a.put("rotateXYZ",this.getRotateXyzText());a.put("transXPercent",Float.$valueOf(this.getTranslationXPercent()));a.put("transYPercent",Float.$valueOf(this.getTranslationYPercent()));
a.put("zoom",Float.$valueOf(this.zoomPercent));a.put("modelRadius",Float.$valueOf(this.modelRadius));1==this.mode&&(a.put("navigationCenter","navigate center "+J.util.Escape.eP(this.navigationCenter)),a.put("navigationOffsetXPercent",Float.$valueOf(this.getNavigationOffsetPercent("X"))),a.put("navigationOffsetYPercent",Float.$valueOf(this.getNavigationOffsetPercent("Y"))),a.put("navigationDepthPercent",Float.$valueOf(this.getNavigationDepthPercent())));return a});$_M(c$,"getAxisAngle",function(a){a.setM(this.matrixRotate)},
"JU.A4");$_M(c$,"getTransformText",function(){return this.matrixRotate.toString()});$_M(c$,"getMatrixRotate",function(){return this.matrixRotate});$_M(c$,"setRotation",function(a){Float.isNaN(a.m00)||this.matrixRotate.setM(a)},"JU.M3");$_M(c$,"getRotation",function(a){a.setM(this.matrixRotate)},"JU.M3");$_M(c$,"zoomBy",function(a){20<a?a=20:-20>a&&(a=-20);var b=a*this.zoomPercentSetting/50;0==b&&(b=0<a?1:0>b?-1:0);this.zoomRatio=(b+this.zoomPercentSetting)/this.zoomPercentSetting;this.zoomPercentSetting+=
b},"~N");$_M(c$,"getZoomPercentFloat",function(){return this.zoomPercent});$_M(c$,"zoomToPercent",function(a){this.zoomPercentSetting=a;this.zoomRatio=0},"~N");$_M(c$,"translateZBy",function(a){a>=this.screenPixelCount||(a=this.scalePixelsPerAngstrom/(1-1*a/this.screenPixelCount),a>=this.screenPixelCount||(a=100*(a/this.scaleDefaultPixelsPerAngstrom),this.zoomRatio=a/this.zoomPercentSetting,this.zoomPercentSetting=a))},"~N");$_M(c$,"zoomByFactor0",function(a,b,c){!(0>=a)&&this.zoomEnabled&&(this.zoomRatio=
a,this.zoomPercentSetting*=a,this.resetXYCenter(b,c))},"~N,~N,~N");$_M(c$,"resetXYCenter",($fz=function(a,b){if(!(2147483647==a||2147483647==b)){this.windowCentered&&this.viewer.setBooleanProperty("windowCentered",!1);var c=new JU.P3;this.transformPoint2(this.fixedRotationCenter,c);c.set(a,b,c.z);this.unTransformPoint(c,c);this.fixedTranslation.set(a,b,0);this.setFixedRotationCenter(c)}},$fz.isPrivate=!0,$fz),"~N,~N");$_M(c$,"zoomByPercent",function(a){var b=a*this.zoomPercentSetting/100;0==b&&(b=
0>a?-1:1);this.zoomRatio=(b+this.zoomPercentSetting)/this.zoomPercentSetting;this.zoomPercentSetting+=b},"~N");$_M(c$,"setScaleAngstromsPerInch",function(a){if(this.scale3D=0<a)this.scale3DAngstromsPerInch=a;this.perspectiveDepth=!this.scale3D},"~N");$_M(c$,"setZslabPoint",function(a){this.zSlabPoint=null==a?null:JU.P3.newP(a)},"JU.P3");$_M(c$,"getZShadeStart",function(){return this.zShadeEnabled?this.zDepthValue:0});$_M(c$,"setSlabRange",function(a){this.slabRange=a},"~N");$_M(c$,"setSlabEnabled",
function(a){this.slabEnabled=a;this.viewer.getGlobalSettings().setB("slabEnabled",a)},"~B");$_M(c$,"setZShadeEnabled",function(a){this.zShadeEnabled=a;this.viewer.getGlobalSettings().setB("zShade",a)},"~B");$_M(c$,"setZoomEnabled",function(a){this.zoomEnabled=a;this.viewer.getGlobalSettings().setB("zoomEnabled",a)},"~B");$_M(c$,"slabReset",function(){this.slabToPercent(100);this.depthToPercent(0);this.slabPlane=this.depthPlane=null;this.setSlabEnabled(!1);this.setZShadeEnabled(!1)});$_M(c$,"getSlabPercentSetting",
function(){return this.slabPercentSetting});$_M(c$,"slabByPercentagePoints",function(a){this.slabPlane=null;this.slabPercentSetting+=a;this.slabDepthChanged();this.depthPercentSetting>=this.slabPercentSetting&&(this.depthPercentSetting=this.slabPercentSetting-1)},"~N");$_M(c$,"slabDepthChanged",($fz=function(){this.viewer.getGlobalSettings().setI("slab",this.slabPercentSetting);this.viewer.getGlobalSettings().setI("depth",this.depthPercentSetting)},$fz.isPrivate=!0,$fz));$_M(c$,"depthByPercentagePoints",
function(a){this.depthPlane=null;this.depthPercentSetting+=a;this.slabPercentSetting<=this.depthPercentSetting&&(this.slabPercentSetting=this.depthPercentSetting+1);this.slabDepthChanged()},"~N");$_M(c$,"slabDepthByPercentagePoints",function(a){this.depthPlane=this.slabPlane=null;this.slabPercentSetting+=a;this.depthPercentSetting+=a;this.slabDepthChanged()},"~N");$_M(c$,"slabToPercent",function(a){this.viewer.setFloatProperty("slabRange",0);this.slabPercentSetting=a;this.slabPlane=null;this.depthPercentSetting>=
this.slabPercentSetting&&(this.depthPercentSetting=this.slabPercentSetting-1);this.slabDepthChanged()},"~N");$_M(c$,"depthToPercent",function(a){this.viewer.getGlobalSettings().setI("depth",a);this.depthPercentSetting=a;this.slabPercentSetting<=this.depthPercentSetting&&(this.slabPercentSetting=this.depthPercentSetting+1);this.slabDepthChanged()},"~N");$_M(c$,"zSlabToPercent",function(a){this.zSlabPercentSetting=a;this.zDepthPercentSetting>this.zSlabPercentSetting&&(this.zDepthPercentSetting=a)},
"~N");$_M(c$,"zDepthToPercent",function(a){this.zDepthPercentSetting=a;this.zDepthPercentSetting>this.zSlabPercentSetting&&(this.zSlabPercentSetting=a)},"~N");$_M(c$,"slabInternal",function(a,b){b?(this.depthPlane=a,this.depthPercentSetting=0):(this.slabPlane=a,this.slabPercentSetting=100)},"JU.P4,~B");$_M(c$,"setSlabDepthInternal",function(a){this.finalizeTransformParameters();a?this.depthPlane=null:this.slabPlane=null;this.slabInternal(this.getSlabDepthPlane(a),a)},"~B");$_M(c$,"getSlabDepthPlane",
function(a){if(a){if(null!=this.depthPlane)return this.depthPlane}else if(null!=this.slabPlane)return this.slabPlane;var b=this.matrixTransform;return JU.P4.new4(-b.m20,-b.m21,-b.m22,-b.m23+(a?this.depthValue:this.slabValue))},"~B");$_M(c$,"getCameraFactors",function(){this.aperatureAngle=360*Math.atan2(this.screenPixelCount/2,this.referencePlaneOffset)/3.141592653589793;this.cameraDistanceFromCenter=this.referencePlaneOffset/this.scalePixelsPerAngstrom;var a=JU.P3.new3(Clazz.doubleToInt(this.screenWidth/
2),Clazz.doubleToInt(this.screenHeight/2),this.referencePlaneOffset);this.unTransformPoint(a,a);var b=JU.P3.new3(Clazz.doubleToInt(this.screenWidth/2),Clazz.doubleToInt(this.screenHeight/2),0);this.viewer.unTransformPoint(b,b);b.sub(this.fixedRotationCenter);var c=JU.P3.new3(Clazz.doubleToInt(this.screenWidth/2),Clazz.doubleToInt(this.screenHeight/2),this.cameraDistanceFromCenter*this.scalePixelsPerAngstrom);this.viewer.unTransformPoint(c,c);c.sub(this.fixedRotationCenter);b.add(c);return[a,b,this.fixedRotationCenter,
JU.P3.new3(this.cameraDistanceFromCenter,this.aperatureAngle,this.scalePixelsPerAngstrom)]});$_M(c$,"getFrontPlane",function(){return Clazz.floatToInt(this.cameraDistance)});$_M(c$,"setPerspectiveDepth",function(a){this.perspectiveDepth!=a&&(this.perspectiveDepth=a,this.viewer.global.setB("perspectiveDepth",a),this.resetFitToScreen(!1))},"~B");$_M(c$,"getPerspectiveDepth",function(){return this.perspectiveDepth});$_M(c$,"setCameraDepthPercent",function(a,b){this.resetNavigationPoint(b);var c=0>a?
-a/100:a;0!=c&&(this.cameraDepthSetting=c,this.viewer.global.setF("cameraDepth",this.cameraDepthSetting),1==this.mode&&(this.cameraDepth=NaN))},"~N,~B");$_M(c$,"getCameraDepth",function(){return this.cameraDepthSetting});$_M(c$,"setVisualRange",function(a){this.visualRange=a},"~N");$_M(c$,"getUnscaledTransformMatrix",function(){var a=new JU.M4;a.setIdentity();this.vectorTemp.setT(this.fixedRotationCenter);this.matrixTemp.setZero();this.matrixTemp.setTranslation(this.vectorTemp);a.sub(this.matrixTemp);
this.matrixTemp.setM3(this.matrixRotate);a.mul2(this.matrixTemp,a);return a});$_M(c$,"setScreenParameters0",($fz=function(a,b,c,d,e,f){2147483647!=a&&(this.screenWidth=a,this.screenHeight=b,this.useZoomLarge=c,this.width=(this.antialias=d)?2*a:a,this.height=d?2*b:b,this.scaleFitToScreen(!1,c,e,f))},$fz.isPrivate=!0,$fz),"~N,~N,~B,~B,~B,~B");$_M(c$,"setAntialias",function(a){var b=this.antialias!=a;this.width=(this.antialias=a)?2*this.screenWidth:this.screenWidth;this.height=this.antialias?2*this.screenHeight:
this.screenHeight;b&&this.scaleFitToScreen(!1,this.useZoomLarge,!1,!1)},"~B");$_M(c$,"defaultScaleToScreen",function(a){return this.screenPixelCount/2/a},"~N");$_M(c$,"resetFitToScreen",($fz=function(a){this.scaleFitToScreen(a,this.viewer.global.zoomLarge,!0,!0)},$fz.isPrivate=!0,$fz),"~B");$_M(c$,"scaleFitToScreen",function(a,b,c,d){0==this.width||0==this.height?this.screenPixelCount=1:(this.fixedTranslation.set(this.width*(a?0.5:this.xTranslationFraction),this.height*(a?0.5:this.yTranslationFraction),
0),this.setTranslationFractions(),a&&this.camera.set(0,0,0),d&&this.resetNavigationPoint(c),this.zoomHeight&&(b=this.height>this.width),this.screenPixelCount=b==this.height>this.width?this.height:this.width);2<this.screenPixelCount&&(this.screenPixelCount-=2);this.scaleDefaultPixelsPerAngstrom=this.defaultScaleToScreen(this.modelRadius)},"~B,~B,~B,~B");$_M(c$,"scaleToScreen",function(a,b){if(0==b||2>a)return 0;var c=this.scaleToPerspective(a,b*this.scalePixelsPerAngstrom/1E3);return 0<c?c:1},"~N,~N");
$_M(c$,"unscaleToScreen",function(a,b){var c=b/this.scalePixelsPerAngstrom;return this.perspectiveDepth?c/this.getPerspectiveFactor(a):c},"~N,~N");$_M(c$,"scaleToPerspective",function(a,b){return this.perspectiveDepth?b*this.getPerspectiveFactor(a):b},"~N,~N");$_M(c$,"getMatrixtransform",function(){return this.matrixTransform});$_M(c$,"setNavigationMode",function(a){this.mode=a&&this.canNavigate()?1:this.defaultMode;this.resetNavigationPoint(!0)},"~B");$_M(c$,"isNavigating",function(){return this.navigating||
this.navOn});$_M(c$,"finalizeTransformParameters",function(){this.haveNotifiedNaN=!1;this.fixedRotationOffset.setT(this.fixedTranslation);this.camera.setT(this.cameraSetting);this.internalSlab=this.slabEnabled&&(null!=this.slabPlane||null!=this.depthPlane);var a=this.getZoomSetting();this.zoomPercent!=a&&(this.zoomPercent=a,this.viewer.global.fontCaching||this.viewer.getGraphicsData().clearFontCache());this.calcCameraFactors();this.calcTransformMatrix();1==this.mode?this.calcNavigationPoint():this.calcSlabAndDepthValues()});
$_M(c$,"getZoomSetting",function(){5>this.zoomPercentSetting&&(this.zoomPercentSetting=5);2E5<this.zoomPercentSetting&&(this.zoomPercentSetting=2E5);return this.zoomEnabled||1==this.mode?this.zoomPercentSetting:100});$_M(c$,"calcSlabAndDepthValues",function(){this.slabValue=1>this.slabRange?this.zValueFromPercent(this.slabPercentSetting):Clazz.doubleToInt(Math.floor(this.modelCenterOffset*this.slabRange/(2*this.modelRadius)*(this.zoomPercentSetting/100)));this.depthValue=this.zValueFromPercent(this.depthPercentSetting);
this.zSlabPercentSetting==this.zDepthPercentSetting?(this.zSlabValue=this.slabValue,this.zDepthValue=this.depthValue):(this.zSlabValue=this.zValueFromPercent(this.zSlabPercentSetting),this.zDepthValue=this.zValueFromPercent(this.zDepthPercentSetting));if(null!=this.zSlabPoint)try{this.transformPoint2(this.zSlabPoint,this.pointT2),this.zSlabValue=Clazz.floatToInt(this.pointT2.z)}catch(a){if(!Clazz.exceptionOf(a,Exception))throw a;}this.viewer.getGlobalSettings().setS("_slabPlane",J.util.Escape.eP4(this.getSlabDepthPlane(!1)));
this.viewer.getGlobalSettings().setS("_depthPlane",J.util.Escape.eP4(this.getSlabDepthPlane(!0)));this.slabEnabled||(this.slabValue=0,this.depthValue=2147483647)});$_M(c$,"zValueFromPercent",function(a){return Clazz.doubleToInt(Math.floor((1-a/50)*this.modelRadiusPixels+this.modelCenterOffset))},"~N");$_M(c$,"calcTransformMatrix",function(){this.matrixTransform.setIdentity();this.vectorTemp.setT(this.fixedRotationCenter);this.vectorTemp.sub(this.frameOffset);this.matrixTemp.setZero();this.matrixTemp.setTranslation(this.vectorTemp);
this.matrixTransform.sub(this.matrixTemp);this.matrixTemp.setM3(this.stereoFrame?this.matrixStereo:this.matrixRotate);this.matrixTransform.mul2(this.matrixTemp,this.matrixTransform);this.matrixTemp.setIdentity();this.matrixTemp.m00=this.matrixTemp.m11=this.matrixTemp.m22=this.scalePixelsPerAngstrom;this.matrixTemp.m11=this.matrixTemp.m22=-this.scalePixelsPerAngstrom;this.matrixTransform.mul2(this.matrixTemp,this.matrixTransform);this.matrixTransform.m23+=this.modelCenterOffset;try{this.matrixTransformInv.invertM(this.matrixTransform)}catch(a){if(Clazz.exceptionOf(a,
Exception))System.out.println("ERROR INVERTING matrixTransform!");else throw a;}});$_M(c$,"rotatePoint",function(a,b){this.matrixRotate.transform2(a,b);b.y=-b.y},"JU.P3,JU.P3");$_M(c$,"transformPoints",function(a,b,c){for(;0<=--a;)c[a].setT(this.transformPoint(b[a]))},"~N,~A,~A");$_M(c$,"transformPointScr",function(a,b){b.setT(this.transformPoint(a))},"JU.P3,JU.P3i");$_M(c$,"transformPointNoClip2",function(a,b){b.setT(this.transformPointNoClip(a))},"JU.P3,JU.P3");$_M(c$,"transformPoint",function(a){if(3.4028235E38==
a.z||-3.4028235E38==a.z)return this.transformScreenPoint(a);this.getTemporaryScreenPoint(a,this.internalSlab?a:null);return this.point3iScreenTemp},"JU.P3");$_M(c$,"transformScreenPoint",($fz=function(a){-3.4028235E38==a.z?(this.point3iScreenTemp.x=Clazz.doubleToInt(Math.floor(a.x/100*this.screenWidth)),this.point3iScreenTemp.y=Clazz.doubleToInt(Math.floor((1-a.y/100)*this.screenHeight))):(this.point3iScreenTemp.x=Clazz.floatToInt(a.x),this.point3iScreenTemp.y=this.screenHeight-Clazz.floatToInt(a.y));
this.antialias&&(this.point3iScreenTemp.x<<=1,this.point3iScreenTemp.y<<=1);this.matrixTransform.transform2(this.fixedRotationCenter,this.pointTsp);this.point3iScreenTemp.z=Clazz.floatToInt(this.pointTsp.z);return this.point3iScreenTemp},$fz.isPrivate=!0,$fz),"JU.P3");$_M(c$,"transformPointNoClip",function(a){this.getTemporaryScreenPoint(a,null);return this.point3fScreenTemp},"JU.P3");$_M(c$,"transformPointVib",function(a,b){this.ptVibTemp.setT(a);this.vibrationOn&&null!=b&&b.setTempPoint(this.ptVibTemp,
this.vibrationT,this.vibrationScale);this.getTemporaryScreenPoint(this.ptVibTemp,a);return this.point3iScreenTemp},"JU.P3,J.util.Vibration");$_M(c$,"transformPoint2",function(a,b){this.getTemporaryScreenPoint(a,a);b.setT(this.point3fScreenTemp)},"JU.P3,JU.P3");$_M(c$,"transformVector",function(a,b){this.matrixTransform.transformV2(a,b)},"JU.V3,JU.V3");$_M(c$,"move",function(a,b,c,d,e,f,g){var h=J.api.Interface.getOptionInterface("thread.MoveThread");h.setManager(this,this.viewer,[b,d,[c,e,f,g]]);
0<f&&h.setEval(a);h.run()},"J.api.JmolScriptEvaluator,JU.V3,~N,JU.V3,~N,~N,~N");$_M(c$,"isInPosition",function(a,b){if(Float.isNaN(b))return!0;this.aaTest1.setVA(a,b/57.29577951308232);this.ptTest1.set(4.321,1.23456,3.14159);this.getRotation(this.matrixTest);this.matrixTest.transform2(this.ptTest1,this.ptTest2);this.matrixTest.setAA(this.aaTest1);this.matrixTest.transform2(this.ptTest1,this.ptTest3);return 0.1>this.ptTest3.distance(this.ptTest2)},"JU.V3,~N");$_M(c$,"moveToPyMOL",function(a,b,c){var d=
JU.M3.newA(c);d.invert();var e=c[9],f=-c[10],g=-c[11],h=JU.P3.new3(c[12],c[13],c[14]),k=c[15],l=c[16],m=c[17];this.setPerspectiveDepth(!(0<=m));var m=Math.abs(m)/2,n=Math.tan(3.141592653589793*m/180),m=g*n,n=0.5/n-0.5,q=50/m;0<k&&(k=50+Clazz.floatToInt((g-k)*q),g=50+Clazz.floatToInt((g-l)*q),this.setSlabEnabled(!0),this.slabToPercent(k),this.depthToPercent(g),21==c.length&&(l=0!=c[18],q=0!=c[19],c=c[20],this.setZShadeEnabled(l),l&&(q?this.viewer.setIntProperty("zSlab",Clazz.floatToInt(Math.min(100,
k+c*(g-k)))):this.viewer.setIntProperty("zSlab",Clazz.floatToInt((k+g)/2)),this.viewer.setIntProperty("zDepth",g))));this.moveTo(a,b,h,null,0,d,100,NaN,NaN,m,null,NaN,NaN,NaN,n,e,f)},"J.api.JmolScriptEvaluator,~N,~A");$_M(c$,"moveTo",function(a,b,c,d,e,f,g,h,k,l,m,n,q,p,r,s,t){if(null==f)if(f=new JU.M3,d=JU.V3.newV(d),Float.isNaN(e))f.m00=NaN;else if(0.01>e&&-0.01<e)f.setIdentity();else{if(0==d.x&&0==d.y&&0==d.z)return;var u=new JU.A4;u.setVA(d,e/57.29577951308232);f.setAA(u)}s==this.cameraSetting.x&&
(s=NaN);t==this.cameraSetting.y&&(t=NaN);r==this.cameraDepth&&(r=NaN);Float.isNaN(s)||(h=50*s/l/this.width*this.screenPixelCount);Float.isNaN(t)||(k=50*t/l/this.height*this.screenPixelCount);e=null==c?this.scaleDefaultPixelsPerAngstrom:this.defaultScaleToScreen(l);if(0>=b)this.setAll(c,f,m,g,h,k,l,e,p,n,q,r,s,t),this.viewer.moveUpdate(b),this.viewer.finalizeTransformParameters();else try{null==this.motion&&(this.motion=J.api.Interface.getOptionInterface("thread.MoveToThread"));var v=this.motion.setManager(this,
this.viewer,[c,f,m,[b,g,h,k,l,e,p,n,q,r,s,t]]);0>=v||this.viewer.global.waitForMoveTo?(0<v&&this.motion.setEval(a),this.motion.run(),this.viewer.isSingleThreaded||(this.motion=null)):this.motion.start()}catch(y){if(!Clazz.exceptionOf(y,Exception))throw y;}},"J.api.JmolScriptEvaluator,~N,JU.P3,JU.T3,~N,JU.M3,~N,~N,~N,~N,JU.P3,~N,~N,~N,~N,~N,~N");$_M(c$,"stopMotion",function(){this.motion=null});$_M(c$,"getRotationQuaternion",function(){return J.util.Quaternion.newM(this.matrixRotate)});$_M(c$,"getRotationText",
function(){this.axisangleT.setM(this.matrixRotate);var a=57.29577951308232*this.axisangleT.angle,b=new JU.SB;this.vectorT.set(this.axisangleT.x,this.axisangleT.y,this.axisangleT.z);if(0.01>a)return"{0 0 1 0}";this.vectorT.normalize();this.vectorT.scale(1E3);b.append("{");J.viewer.TransformManager.truncate0(b,this.vectorT.x);J.viewer.TransformManager.truncate0(b,this.vectorT.y);J.viewer.TransformManager.truncate0(b,this.vectorT.z);J.viewer.TransformManager.truncate2(b,a);b.append("}");return b.toString()});
$_M(c$,"getMoveToText",function(a,b){this.finalizeTransformParameters();var c=new JU.SB;c.append("moveto ");b&&c.append("/* time, axisAngle */ ");c.appendF(a);c.append(" ").append(this.getRotationText());b&&c.append(" /* zoom, translation */ ");J.viewer.TransformManager.truncate2(c,this.zoomPercentSetting);J.viewer.TransformManager.truncate2(c,this.getTranslationXPercent());J.viewer.TransformManager.truncate2(c,this.getTranslationYPercent());c.append(" ");b&&c.append(" /* center, rotationRadius */ ");
c.append(this.getCenterText());c.append(" ").appendF(this.modelRadius);c.append(this.getNavigationText(b));b&&c.append(" /* cameraDepth, cameraX, cameraY */ ");J.viewer.TransformManager.truncate2(c,this.cameraDepth);J.viewer.TransformManager.truncate2(c,this.cameraSetting.x);J.viewer.TransformManager.truncate2(c,this.cameraSetting.y);c.append(";");return c.toString()},"~N,~B");$_M(c$,"getCenterText",($fz=function(){return J.util.Escape.eP(this.fixedRotationCenter)},$fz.isPrivate=!0,$fz));$_M(c$,"getRotateXyzText",
($fz=function(){var a=new JU.SB,b=this.matrixRotate.m20,c=-(57.29577951308232*Math.asin(b)),d;0.999<b||-0.999>b?(b=-(57.29577951308232*Math.atan2(this.matrixRotate.m12,this.matrixRotate.m11)),d=0):(b=57.29577951308232*Math.atan2(this.matrixRotate.m21,this.matrixRotate.m22),d=57.29577951308232*Math.atan2(this.matrixRotate.m10,this.matrixRotate.m00));a.append("reset");a.append(";center ").append(this.getCenterText());0!=b&&(a.append("; rotate x"),J.viewer.TransformManager.truncate2(a,b));0!=c&&(a.append("; rotate y"),
J.viewer.TransformManager.truncate2(a,c));0!=d&&(a.append("; rotate z"),J.viewer.TransformManager.truncate2(a,d));a.append(";");this.addZoomTranslationNavigationText(a);return a.toString()},$fz.isPrivate=!0,$fz));$_M(c$,"addZoomTranslationNavigationText",($fz=function(a){100!=this.zoomPercent&&(a.append(" zoom"),J.viewer.TransformManager.truncate2(a,this.zoomPercent),a.append(";"));var b=this.getTranslationXPercent();0!=b&&(a.append(" translate x"),J.viewer.TransformManager.truncate2(a,b),a.append(";"));
b=this.getTranslationYPercent();0!=b&&(a.append(" translate y"),J.viewer.TransformManager.truncate2(a,b),a.append(";"));if(this.modelRadius!=this.rotationRadiusDefault||10==this.modelRadius)a.append(" set rotationRadius"),J.viewer.TransformManager.truncate2(a,this.modelRadius),a.append(";");1==this.mode&&(a.append("navigate 0 center ").append(J.util.Escape.eP(this.navigationCenter)),a.append(";navigate 0 translate"),J.viewer.TransformManager.truncate2(a,this.getNavigationOffsetPercent("X")),J.viewer.TransformManager.truncate2(a,
this.getNavigationOffsetPercent("Y")),a.append(";navigate 0 depth "),J.viewer.TransformManager.truncate2(a,this.getNavigationDepthPercent()),a.append(";"))},$fz.isPrivate=!0,$fz),"JU.SB");$_M(c$,"getRotateZyzText",($fz=function(a){var b=new JU.SB,c=this.viewer.getModelSetAuxiliaryInfoValue("defaultOrientationMatrix");null==c?c=this.matrixRotate:(c=JU.M3.newM(c),c.invert(),c.mul2(this.matrixRotate,c));var d=c.m22,e=57.29577951308232*Math.acos(d);0.999<d||-0.999>d?(d=57.29577951308232*Math.atan2(c.m10,
c.m11),c=0):(d=57.29577951308232*Math.atan2(c.m21,-c.m20),c=57.29577951308232*Math.atan2(c.m12,c.m02));0!=d&&(0!=e&&0!=c&&a)&&b.append("#Follows Z-Y-Z convention for Euler angles\n");b.append("reset");b.append(";center ").append(this.getCenterText());0!=d&&(b.append("; rotate z"),J.viewer.TransformManager.truncate2(b,d));0!=e&&(b.append("; rotate y"),J.viewer.TransformManager.truncate2(b,e));0!=c&&(b.append("; rotate z"),J.viewer.TransformManager.truncate2(b,c));b.append(";");this.addZoomTranslationNavigationText(b);
return b.toString()},$fz.isPrivate=!0,$fz),"~B");c$.truncate0=$_M(c$,"truncate0",($fz=function(a,b){a.appendC(" ");a.appendI(Math.round(b))},$fz.isPrivate=!0,$fz),"JU.SB,~N");c$.truncate2=$_M(c$,"truncate2",($fz=function(a,b){a.appendC(" ");a.appendF(Math.round(100*b)/100)},$fz.isPrivate=!0,$fz),"JU.SB,~N");$_M(c$,"setSpinXYZ",function(a,b,c){Float.isNaN(a)||(this.spinX=a);Float.isNaN(b)||(this.spinY=b);Float.isNaN(c)||(this.spinZ=c);(this.isSpinInternal||this.isSpinFixed)&&this.clearSpin()},"~N,~N,~N");
$_M(c$,"setSpinFps",function(a){0>=a?a=1:50<a&&(a=50);this.spinFps=a},"~N");$_M(c$,"setNavXYZ",function(a,b,c){Float.isNaN(a)||(this.navX=a);Float.isNaN(b)||(this.navY=b);Float.isNaN(c)||(this.navZ=c)},"~N,~N,~N");$_M(c$,"clearSpin",($fz=function(){this.setSpinOff();this.setNavOn(!1);this.isSpinFixed=this.isSpinInternal=!1},$fz.isPrivate=!0,$fz));$_M(c$,"getSpinOn",function(){return this.spinOn});$_M(c$,"getNavOn",function(){return this.navOn});$_M(c$,"setSpinOn",function(){this.setSpin(null,!0,3.4028235E38,
null,null,null,!1)});$_M(c$,"setSpinOff",function(){this.setSpin(null,!1,3.4028235E38,null,null,null,!1)});$_M(c$,"setSpin",($fz=function(a,b,c,d,e,f,g){this.navOn&&b&&this.setNavOn(!1);this.spinOn!=b&&(this.spinOn=b,this.viewer.getGlobalSettings().setB("_spinning",b),b?null==this.spinThread&&(this.spinThread=J.api.Interface.getOptionInterface("thread.SpinThread"),this.spinThread.setManager(this,this.viewer,[Float.$valueOf(c),d,e,f,g?Boolean.TRUE:null]),this.spinIsGesture=g,null==f&&null==e?this.spinThread.start():
(this.spinThread.setEval(a),this.spinThread.run())):null!=this.spinThread&&(this.spinThread.reset(),this.spinThread=null))},$fz.isPrivate=!0,$fz),"J.api.JmolScriptEvaluator,~B,~N,JU.List,~A,JU.BS,~B");$_M(c$,"setNavOn",function(a){if(!Float.isNaN(this.navFps)){var b=this.navOn;a&&this.spinOn&&this.setSpin(null,!1,0,null,null,null,!1);this.navOn=a;this.viewer.getGlobalSettings().setB("_navigating",a);a||this.navInterrupt();a?(0==this.navX&&(0==this.navY&&0==this.navZ)&&(this.navZ=1),0==this.navFps&&
(this.navFps=10),null==this.spinThread&&(this.spinThread=J.api.Interface.getOptionInterface("thread.SpinThread"),this.spinThread.setManager(this,this.viewer,null),this.spinThread.start())):b&&null!=this.spinThread&&(this.spinThread.interrupt(),this.spinThread=null)}},"~B");$_M(c$,"setVibrationScale",function(a){this.vibrationScale=a},"~N");$_M(c$,"setVibrationPeriod",function(a){if(Float.isNaN(a))a=this.vibrationPeriod;else if(0==a)this.vibrationPeriodMs=this.vibrationPeriod=0;else{this.vibrationPeriod=
Math.abs(a);this.vibrationPeriodMs=Clazz.floatToInt(1E3*this.vibrationPeriod);if(0<a)return;a=-a}this.setVibrationOn(0<a&&0<=this.viewer.modelGetLastVibrationIndex(this.viewer.getCurrentModelIndex(),0))},"~N");$_M(c$,"setVibrationT",function(a){this.vibrationT=a;0==this.vibrationScale&&(this.vibrationScale=this.viewer.global.vibrationScale)},"~N");$_M(c$,"isVibrationOn",function(){return this.vibrationOn});$_M(c$,"setVibrationOn",($fz=function(a){a?1>this.viewer.getModelCount()?this.vibrationOn=!1:
(null==this.vibrationThread&&(this.vibrationThread=J.api.Interface.getOptionInterface("thread.VibrationThread"),this.vibrationThread.setManager(this,this.viewer,null),this.vibrationThread.start()),this.vibrationOn=!0):(null!=this.vibrationThread&&(this.vibrationThread.interrupt(),this.vibrationThread=null),this.vibrationOn=!1)},$fz.isPrivate=!0,$fz),"~B");$_M(c$,"clearVibration",($fz=function(){this.setVibrationOn(!1);this.vibrationScale=0},$fz.isPrivate=!0,$fz));$_M(c$,"setStereoMode2",function(a){this.stereoMode=
J.constant.EnumStereoMode.CUSTOM;this.stereoColors=a},"~A");$_M(c$,"setStereoMode",function(a){this.stereoColors=null;this.stereoMode=a},"J.constant.EnumStereoMode");$_M(c$,"setStereoDegrees",function(a){this.stereoDegrees=a;this.stereoRadians=0.017453292*a},"~N");$_M(c$,"getStereoRotationMatrix",function(a){this.stereoFrame=a;if(!a)return this.matrixRotate;this.matrixTemp3.rotY(-this.stereoRadians);this.matrixStereo.mul2(this.matrixTemp3,this.matrixRotate);return this.matrixStereo},"~B");$_M(c$,
"isWindowCentered",function(){return this.windowCentered});$_M(c$,"setWindowCentered",function(a){this.windowCentered=a;this.resetNavigationPoint(!0)},"~B");$_M(c$,"getRotationCenter",function(){return this.fixedRotationCenter});$_M(c$,"getRotationRadius",function(){return this.modelRadius});$_M(c$,"setRotationRadius",function(a,b){a=this.modelRadius=0>=a?this.viewer.calcRotationRadius(this.fixedRotationCenter):a;b&&this.viewer.setRotationRadius(a,!1);return a},"~N,~B");$_M(c$,"setRotationCenterAndRadiusXYZ",
($fz=function(a,b){this.resetNavigationPoint(!1);null==a?(this.setFixedRotationCenter(this.rotationCenterDefault),this.modelRadius=this.rotationRadiusDefault):(this.setFixedRotationCenter(a),b&&this.windowCentered&&(this.modelRadius=this.viewer.calcRotationRadius(this.fixedRotationCenter)))},$fz.isPrivate=!0,$fz),"JU.P3,~B");$_M(c$,"setRotCenterRel",($fz=function(a,b){var c=JU.P3.newP(b);"average"===a?c.add(this.viewer.getAverageAtomPoint()):"boundbox"===a?c.add(this.viewer.getBoundBoxCenter()):"absolute"!==
a&&c.setT(this.rotationCenterDefault);this.setRotationCenterAndRadiusXYZ(c,!0)},$fz.isPrivate=!0,$fz),"~S,JU.P3");$_M(c$,"setNewRotationCenter",function(a,b){null==a&&(a=this.rotationCenterDefault);this.windowCentered?(this.translateToPercent("x",0),this.translateToPercent("y",0),this.setRotationCenterAndRadiusXYZ(a,!0),b&&this.resetFitToScreen(!0)):this.moveRotationCenter(a,!0)},"JU.P3,~B");$_M(c$,"moveRotationCenter",function(a,b){this.setRotationCenterAndRadiusXYZ(a,!1);b&&this.setRotationPointXY(this.fixedRotationCenter)},
"JU.P3,~B");$_M(c$,"setCenter",function(){this.setRotationCenterAndRadiusXYZ(this.fixedRotationCenter,!0)});$_M(c$,"setCenterAt",function(a,b){this.setRotCenterRel(a,b);this.resetFitToScreen(!0)},"~S,JU.P3");$_M(c$,"setFrameOffset",function(a){null==this.frameOffsets||0>a||a>=this.frameOffsets.length?this.frameOffset.set(0,0,0):this.frameOffset.setT(this.frameOffsets[a])},"~N");$_M(c$,"setFrameOffsets",function(a){this.frameOffsets=a},"~A");$_M(c$,"setSelectedTranslation",function(a,b,c){this.bsSelectedAtoms=
a;switch(b){case "X":case "x":this.ptOffset.x+=c;break;case "Y":case "y":this.ptOffset.y+=c;break;case "Z":case "z":this.ptOffset.z+=c}},"JU.BS,~S,~N");$_M(c$,"setNavFps",function(a){this.navFps=a},"~N");$_M(c$,"calcCameraFactors",function(){Float.isNaN(this.cameraDepth)&&(this.cameraDepth=this.cameraDepthSetting,this.zoomFactor=3.4028235E38);this.cameraDistance=this.cameraDepth*this.screenPixelCount;this.referencePlaneOffset=this.cameraDistance+this.screenPixelCount/2;this.scalePixelsPerAngstrom=
this.scale3D&&!this.perspectiveDepth&&1!=this.mode?72/this.scale3DAngstromsPerInch*(this.antialias?2:1):this.screenPixelCount/this.visualRange;1!=this.mode&&(this.mode=0==this.camera.z?0:2);this.perspectiveShiftXY.set(0==this.camera.z?0:100*(this.camera.x*this.scalePixelsPerAngstrom/this.screenWidth),0==this.camera.z?0:100*(this.camera.y*this.scalePixelsPerAngstrom/this.screenHeight),0);this.modelRadiusPixels=this.modelRadius*this.scalePixelsPerAngstrom;var a=2*this.modelRadius/this.visualRange*this.referencePlaneOffset;
if(1==this.mode)this.calcNavCameraFactors(a);else{this.zoomFactor=3.4028235E38;this.modelCenterOffset=this.referencePlaneOffset;if(!this.scale3D||this.perspectiveDepth)this.scalePixelsPerAngstrom*=this.modelCenterOffset/a*this.zoomPercent/100;this.modelRadiusPixels=this.modelRadius*this.scalePixelsPerAngstrom}});$_M(c$,"calcNavCameraFactors",($fz=function(a){3.4028235E38==this.zoomFactor?(1E4<this.zoomPercent&&(this.zoomPercent=1E4),this.modelCenterOffset=100*a/this.zoomPercent):this.prevZoomSetting!=
this.zoomPercentSetting&&(this.modelCenterOffset=0==this.zoomRatio?100*a/this.zoomPercentSetting:this.modelCenterOffset+(1-this.zoomRatio)*this.referencePlaneOffset,this.navMode=-1);this.prevZoomSetting=this.zoomPercentSetting;this.zoomFactor=this.modelCenterOffset/this.referencePlaneOffset;this.zoomPercent=0==this.zoomFactor?1E4:100*(a/this.modelCenterOffset)},$fz.isPrivate=!0,$fz),"~N");$_M(c$,"getPerspectiveFactor",function(a){return 0>=a?this.referencePlaneOffset:this.referencePlaneOffset/a},
"~N");$_M(c$,"getTemporaryScreenPoint",function(a,b){this.matrixTransform.transform2(a,this.point3fScreenTemp);var c=this.point3fScreenTemp.z;Float.isNaN(c)?(!this.haveNotifiedNaN&&J.util.Logger.debugging&&J.util.Logger.debug("NaN seen in TransformPoint"),this.haveNotifiedNaN=!0,c=this.point3fScreenTemp.z=1):0>=c&&(c=this.point3fScreenTemp.z=1);switch(this.mode){case 1:this.point3fScreenTemp.x-=this.navigationShiftXY.x;this.point3fScreenTemp.y-=this.navigationShiftXY.y;break;case 2:this.point3fScreenTemp.x+=
this.perspectiveShiftXY.x,this.point3fScreenTemp.y+=this.perspectiveShiftXY.y}this.perspectiveDepth&&(c=this.getPerspectiveFactor(c),this.point3fScreenTemp.x*=c,this.point3fScreenTemp.y*=c);switch(this.mode){case 1:this.point3fScreenTemp.x+=this.navigationOffset.x;this.point3fScreenTemp.y+=this.navigationOffset.y;break;case 2:this.point3fScreenTemp.x-=this.perspectiveShiftXY.x,this.point3fScreenTemp.y-=this.perspectiveShiftXY.y;case 0:this.point3fScreenTemp.x+=this.fixedRotationOffset.x,this.point3fScreenTemp.y+=
this.fixedRotationOffset.y}Float.isNaN(this.point3fScreenTemp.x)&&!this.haveNotifiedNaN&&(J.util.Logger.debugging&&J.util.Logger.debug("NaN found in transformPoint "),this.haveNotifiedNaN=!0);this.point3iScreenTemp.set(Clazz.floatToInt(this.point3fScreenTemp.x),Clazz.floatToInt(this.point3fScreenTemp.y),Clazz.floatToInt(this.point3fScreenTemp.z));if(null!=b&&(null!=this.slabPlane&&0<b.x*this.slabPlane.x+b.y*this.slabPlane.y+b.z*this.slabPlane.z+this.slabPlane.w||null!=this.depthPlane&&0>b.x*this.depthPlane.x+
b.y*this.depthPlane.y+b.z*this.depthPlane.z+this.depthPlane.w))this.point3iScreenTemp.z=1},"JU.P3,JU.P3");$_M(c$,"unTransformPoint",function(a,b){this.untransformedPoint.setT(a);switch(this.mode){case 1:this.untransformedPoint.x-=this.navigationOffset.x;this.untransformedPoint.y-=this.navigationOffset.y;break;case 2:this.point3fScreenTemp.x+=this.perspectiveShiftXY.x,this.point3fScreenTemp.y+=this.perspectiveShiftXY.y;case 0:this.untransformedPoint.x-=this.fixedRotationOffset.x,this.untransformedPoint.y-=
this.fixedRotationOffset.y}if(this.perspectiveDepth){var c=this.getPerspectiveFactor(this.untransformedPoint.z);this.untransformedPoint.x/=c;this.untransformedPoint.y/=c}switch(this.mode){case 1:this.untransformedPoint.x+=this.navigationShiftXY.x;this.untransformedPoint.y+=this.navigationShiftXY.y;break;case 2:this.untransformedPoint.x-=this.perspectiveShiftXY.x,this.untransformedPoint.y-=this.perspectiveShiftXY.y}this.matrixTransformInv.transform2(this.untransformedPoint,b)},"JU.P3,JU.P3");$_M(c$,
"canNavigate",function(){return!0});$_M(c$,"resetNavigationPoint",function(a){5>this.zoomPercent&&1!=this.mode?(this.perspectiveDepth=!0,this.mode=1):(1==this.mode?(this.navMode=1,this.slabPercentSetting=0,this.perspectiveDepth=!0):a&&(this.slabPercentSetting=100),this.viewer.setFloatProperty("slabRange",0),a&&this.setSlabEnabled(1==this.mode),this.zoomFactor=3.4028235E38,this.zoomPercentSetting=this.zoomPercent)},"~B");$_M(c$,"setNavigatePt",function(a){this.navigationCenter.setT(a);this.navMode=
3;this.navigating=!0;this.finalizeTransformParameters();this.navigating=!1},"JU.P3");$_M(c$,"getNavigationCenter",function(){return this.navigationCenter});$_M(c$,"getNavigationDepthPercent",function(){return this.navigationDepth});$_M(c$,"setNavigationSlabOffsetPercent",function(a){this.viewer.getGlobalSettings().setF("navigationSlab",a);this.calcCameraFactors();this.navigationSlabOffset=a/50*this.modelRadiusPixels},"~N");$_M(c$,"getNavigationOffset",function(){this.transformPoint2(this.navigationCenter,
this.navigationOffset);return this.navigationOffset});$_M(c$,"getNavPtHeight",function(){return this.height/2});$_M(c$,"getNavigationOffsetPercent",function(a){this.getNavigationOffset();return 0==this.width||0==this.height?0:"X"==a?100*(this.navigationOffset.x-this.width/2)/this.width:100*(this.navigationOffset.y-this.getNavPtHeight())/this.height},"~S");$_M(c$,"getNavigationText",function(a){a=a?" /* navigation center, translation, depth */ ":" ";if(1!=this.mode)return a+"{0 0 0} 0 0 0";this.getNavigationOffset();
return a+J.util.Escape.eP(this.navigationCenter)+" "+this.getNavigationOffsetPercent("X")+" "+this.getNavigationOffsetPercent("Y")+" "+this.getNavigationDepthPercent()},"~B");$_M(c$,"setScreenParameters",function(a,b,c,d,e,f){var g=1==this.mode?JU.P3.newP(this.navigationCenter):null,h=JU.P3.newP(this.navigationOffset);h.x/=this.width;h.y/=this.height;this.setScreenParameters0(a,b,c,d,e,f);null!=g&&(this.navigationCenter.setT(g),this.navTranslatePercentOrTo(-1,h.x*this.width,h.y*this.height),this.setNavigatePt(g))},
"~N,~N,~B,~B,~B,~B");$_M(c$,"navInterrupt",($fz=function(){null!=this.nav&&this.nav.interrupt()},$fz.isPrivate=!0,$fz));$_M(c$,"getNav",($fz=function(){if(null!=this.nav)return!0;this.nav=J.api.Interface.getOptionInterface("navigate.Navigator");if(null==this.nav)return!1;this.nav.set(this,this.viewer);return!0},$fz.isPrivate=!0,$fz));$_M(c$,"navigateList",function(a,b){this.getNav()&&this.nav.navigateList(a,b)},"J.api.JmolScriptEvaluator,JU.List");$_M(c$,"navigateAxis",function(a,b){this.getNav()&&
this.nav.navigateAxis(a,b)},"JU.V3,~N");$_M(c$,"zoomByFactor",function(a,b,c){1!=this.mode||!this.zoomEnabled||0>=a?this.zoomByFactor0(a,b,c):this.getNav()&&this.nav.zoomByFactor(a,b,c)},"~N,~N,~N");$_M(c$,"setNavigationOffsetRelative",function(){this.getNav()&&this.nav.setNavigationOffsetRelative()});$_M(c$,"navigateKey",function(a,b){this.getNav()&&this.nav.navigateKey(a,b)},"~N,~N");$_M(c$,"setNavigationDepthPercent",function(a){this.getNav()&&this.nav.setNavigationDepthPercent(a)},"~N");$_M(c$,
"navTranslatePercentOrTo",function(a,b,c){this.getNav()&&this.nav.navTranslatePercentOrTo(a,b,c)},"~N,~N,~N");$_M(c$,"calcNavigationPoint",function(){this.getNav()&&this.nav.calcNavigationPoint()});$_M(c$,"getNavigationState",function(){return 1==this.mode&&this.getNav()?this.nav.getNavigationState():""});$_M(c$,"setZoomHeight",function(a,b){this.zoomHeight=a;this.scaleFitToScreen(!1,b,!1,!0)},"~B,~B");$_M(c$,"setAll",function(a,b,c,d,e,f,g,h,k,l,m,n,q,p){this.setRotation(b);null!=a&&this.moveRotationCenter(a,
!this.windowCentered);null!=c&&1==this.mode&&this.navigationCenter.setT(c);Float.isNaN(n)||this.setCameraDepthPercent(n,!1);!Float.isNaN(q)&&!Float.isNaN(p)&&this.setCamera(q,p);Float.isNaN(d)||this.zoomToPercent(d);Float.isNaN(g)||(this.modelRadius=g);Float.isNaN(h)||(this.scaleDefaultPixelsPerAngstrom=h);!Float.isNaN(e)&&!Float.isNaN(f)&&(this.translateToPercent("x",e),this.translateToPercent("y",f));!Float.isNaN(l)&&!Float.isNaN(m)&&this.navTranslatePercentOrTo(0,l,m);Float.isNaN(k)||this.setNavigationDepthPercent(k)},
"JU.P3,JU.M3,JU.P3,~N,~N,~N,~N,~N,~N,~N,~N,~N,~N,~N");Clazz.defineStatics(c$,"degreesPerRadian",57.29577951308232,"DEFAULT_NAV_FPS",10,"DEFAULT_SPIN_Y",30,"DEFAULT_SPIN_FPS",30,"MAXIMUM_ZOOM_PERCENTAGE",2E5,"MAXIMUM_ZOOM_PERSPECTIVE_DEPTH",1E4,"MODE_STANDARD",0,"MODE_NAVIGATION",1,"MODE_PERSPECTIVE_PYMOL",2,"DEFAULT_PERSPECTIVE_MODEL",11,"NAV_MODE_IGNORE",-2,"NAV_MODE_ZOOMED",-1,"NAV_MODE_NONE",0,"NAV_MODE_RESET",1,"NAV_MODE_NEWXY",2,"NAV_MODE_NEWXYZ",3,"NAV_MODE_NEWZ",4)}),Clazz.declarePackage("J.modelset"),
Clazz.load(["java.util.Hashtable","JU.BS","J.viewer.JC"],"J.modelset.ModelLoader","java.lang.Boolean $.Float $.NullPointerException java.util.Arrays JU.ArrayUtil $.List $.P3 $.SB $.V3 J.api.Interface J.modelset.Chain $.Group $.Model $.ModelSet J.util.BSUtil $.Elements $.JmolMolecule $.Logger $.Txt".split(" "),function(){c$=Clazz.decorateAsClass(function(){this.mergeModelSet=this.modelSet=this.viewer=null;this.appendNew=this.merging=!1;this.specialAtomIndexes=this.group3Counts=this.group3Lists=this.jmolData=
null;this.doRemoveAddedHydrogens=this.doAddHydrogens=this.doMinimize=this.isPyMOLsession=this.isTrajectory=this.isPDB=this.is2D=this.someModelsHaveUnitcells=!1;this.groups=this.jbr=this.fileHeader=null;this.groupCount=0;this.firstAtomIndexes=this.seqcodes=this.group3Of=this.chainOf=this.htAtomMap=null;this.currentModelIndex=0;this.currentModel=null;this.currentChainID=0;this.isNewChain=!1;this.currentChain=null;this.currentGroupSequenceNumber=0;this.currentGroupInsertionCode="\x00";this.nullGroup=
this.currentGroup3=null;this.adapterTrajectoryCount=this.adapterModelCount=this.baseTrajectoryCount=this.baseGroupIndex=this.baseAtomIndex=this.baseModelCount=this.baseModelIndex=0;this.noAutoBond=!1;this.structuresDefinedInFile=this.vStereo=this.$mergeGroups=null;Clazz.instantialize(this,arguments)},J.modelset,"ModelLoader");Clazz.prepareFields(c$,function(){this.specialAtomIndexes=Clazz.newIntArray(J.viewer.JC.ATOMID_MAX,0);this.htAtomMap=new java.util.Hashtable;this.structuresDefinedInFile=new JU.BS});
Clazz.makeConstructor(c$,function(a,b,c,d,e,f){this.viewer=a;this.modelSet=new J.modelset.ModelSet(a,b);var g=a.getModelAdapter();this.mergeModelSet=e;(this.merging=null!=this.mergeModelSet&&0<this.mergeModelSet.atomCount)?this.modelSet.canSkipLoad=!1:a.resetShapes(!1);this.modelSet.preserveState=a.getPreserveState();this.modelSet.showRebondTimes=a.getBoolean(603979934);null==f?(this.initializeInfo(b,null),this.createModelSet(null,null,null),a.setStringProperty("_fileType","")):(this.modelSet.preserveState||
(this.modelSet.canSkipLoad=!1),a=g.getAtomSetCollectionAuxiliaryInfo(d),a.put("loadScript",c),this.initializeInfo(g.getFileTypeName(d).toLowerCase().intern(),a),this.createModelSet(g,d,f))},"J.viewer.Viewer,~S,JU.SB,~O,J.modelset.ModelSet,JU.BS");$_M(c$,"initializeInfo",($fz=function(a,b){this.modelSet.g3d=this.viewer.getGraphicsData();this.modelSet.modelSetTypeName=a;this.modelSet.isXYZ="xyz"===a;this.modelSet.modelSetAuxiliaryInfo=b;this.modelSet.modelSetProperties=this.modelSet.getModelSetAuxiliaryInfoValue("properties");
if(this.isPDB=this.modelSet.isPDB=this.modelSet.getModelSetAuxiliaryInfoBoolean("isPDB"))try{this.jbr=Class.forName("J.modelsetbio.Resolver").newInstance(),this.jbr.initialize(this)}catch(c){if(Clazz.exceptionOf(c,Exception))J.util.Logger.error("developer error: J.modelsetbio.Resolver could not be found");else throw c;}this.jmolData=this.modelSet.getModelSetAuxiliaryInfoValue("jmolData");this.fileHeader=this.modelSet.getModelSetAuxiliaryInfoValue("fileHeader");this.modelSet.trajectorySteps=this.modelSet.getModelSetAuxiliaryInfoValue("trajectorySteps");
this.isTrajectory=null!=this.modelSet.trajectorySteps;this.isPyMOLsession=this.modelSet.getModelSetAuxiliaryInfoBoolean("isPyMOL");this.doAddHydrogens=null!=this.jbr&&!this.isTrajectory&&!this.isPyMOLsession&&!this.modelSet.getModelSetAuxiliaryInfoBoolean("pdbNoHydrogens")&&this.viewer.getBooleanProperty("pdbAddHydrogens");null!=b&&(b.remove("pdbNoHydrogens"),b.remove("trajectorySteps"),this.isTrajectory&&(this.modelSet.vibrationSteps=b.remove("vibrationSteps")));this.noAutoBond=this.modelSet.getModelSetAuxiliaryInfoBoolean("noAutoBond");
this.doMinimize=(this.is2D=this.modelSet.getModelSetAuxiliaryInfoBoolean("is2D"))&&this.modelSet.getModelSetAuxiliaryInfoBoolean("doMinimize");this.adapterTrajectoryCount=null==this.modelSet.trajectorySteps?0:this.modelSet.trajectorySteps.size();this.modelSet.someModelsHaveSymmetry=this.modelSet.getModelSetAuxiliaryInfoBoolean("someModelsHaveSymmetry");this.someModelsHaveUnitcells=this.modelSet.getModelSetAuxiliaryInfoBoolean("someModelsHaveUnitcells");this.modelSet.someModelsHaveFractionalCoordinates=
this.modelSet.getModelSetAuxiliaryInfoBoolean("someModelsHaveFractionalCoordinates");this.merging&&(this.modelSet.isPDB=(new Boolean(this.modelSet.isPDB|this.mergeModelSet.isPDB)).valueOf(),this.modelSet.someModelsHaveSymmetry=(new Boolean(this.modelSet.someModelsHaveSymmetry|this.mergeModelSet.getModelSetAuxiliaryInfoBoolean("someModelsHaveSymmetry"))).valueOf(),this.someModelsHaveUnitcells=(new Boolean(this.someModelsHaveUnitcells|this.mergeModelSet.getModelSetAuxiliaryInfoBoolean("someModelsHaveUnitcells"))).valueOf(),
this.modelSet.someModelsHaveFractionalCoordinates=(new Boolean(this.modelSet.someModelsHaveFractionalCoordinates|this.mergeModelSet.getModelSetAuxiliaryInfoBoolean("someModelsHaveFractionalCoordinates"))).valueOf(),this.modelSet.someModelsHaveAromaticBonds=(new Boolean(this.modelSet.someModelsHaveAromaticBonds|this.mergeModelSet.someModelsHaveAromaticBonds)).valueOf(),this.modelSet.modelSetAuxiliaryInfo.put("someModelsHaveSymmetry",Boolean.$valueOf(this.modelSet.someModelsHaveSymmetry)),this.modelSet.modelSetAuxiliaryInfo.put("someModelsHaveUnitcells",
Boolean.$valueOf(this.someModelsHaveUnitcells)),this.modelSet.modelSetAuxiliaryInfo.put("someModelsHaveFractionalCoordinates",Boolean.$valueOf(this.modelSet.someModelsHaveFractionalCoordinates)),this.modelSet.modelSetAuxiliaryInfo.put("someModelsHaveAromaticBonds",Boolean.$valueOf(this.modelSet.someModelsHaveAromaticBonds)))},$fz.isPrivate=!0,$fz),"~S,java.util.Map");$_M(c$,"getGroup3",function(a){return a>=this.group3Of.length?null:this.group3Of[a]},"~N");$_M(c$,"getFirstAtomIndex",function(a){return this.firstAtomIndexes[a]},
"~N");$_M(c$,"getAtomCount",function(){return this.modelSet.atomCount});$_M(c$,"createModelSet",($fz=function(a,b,c){var d=null==a?0:a.getAtomCount(b);0<d&&J.util.Logger.info("reading "+d+" atoms");this.adapterModelCount=null==a?1:a.getAtomSetCount(b);this.appendNew=!this.merging||null==a||1<this.adapterModelCount||this.isTrajectory||this.viewer.getBoolean(603979792);this.htAtomMap.clear();this.chainOf=Array(32);this.group3Of=Array(32);this.seqcodes=Clazz.newIntArray(32,0);this.firstAtomIndexes=Clazz.newIntArray(32,
0);this.currentChainID=2147483647;this.currentChain=null;this.currentGroupInsertionCode="\uffff";this.currentGroup3="xxxxx";this.currentModelIndex=-1;this.currentModel=null;if(this.merging&&(this.baseModelCount=this.mergeModelSet.modelCount,this.baseTrajectoryCount=this.mergeModelSet.mergeTrajectories(this.isTrajectory),0<this.baseTrajectoryCount)){if(this.isTrajectory){if(null==this.mergeModelSet.vibrationSteps){this.mergeModelSet.vibrationSteps=new JU.List;for(var e=this.mergeModelSet.trajectorySteps.size();0<=
--e;)this.mergeModelSet.vibrationSteps.addLast(null)}for(e=0;e<this.modelSet.trajectorySteps.size();e++)this.mergeModelSet.trajectorySteps.addLast(this.modelSet.trajectorySteps.get(e)),this.mergeModelSet.vibrationSteps.addLast(null==this.modelSet.vibrationSteps?null:this.modelSet.vibrationSteps.get(e))}this.modelSet.trajectorySteps=this.mergeModelSet.trajectorySteps;this.modelSet.vibrationSteps=this.mergeModelSet.vibrationSteps}this.initializeAtomBondModelCounts(d);null!=c&&(this.doMinimize||this.is2D)&&
c.setBits(this.baseAtomIndex,this.baseAtomIndex+d);null==a?this.setModelNameNumberProperties(0,-1,"",1,null,null,null):(0<this.adapterModelCount&&(J.util.Logger.info("ModelSet: haveSymmetry:"+this.modelSet.someModelsHaveSymmetry+" haveUnitcells:"+this.someModelsHaveUnitcells+" haveFractionalCoord:"+this.modelSet.someModelsHaveFractionalCoordinates),J.util.Logger.info(this.adapterModelCount+" model"+(1==this.modelSet.modelCount?"":"s")+' in this collection. Use getProperty "modelInfo" or getProperty "auxiliaryInfo" to inspect them.')),
e=this.modelSet.getModelSetAuxiliaryInfoValue("defaultOrientationQuaternion"),null!=e&&(J.util.Logger.info("defaultOrientationQuaternion = "+e),J.util.Logger.info('Use "set autoLoadOrientation TRUE" before loading or "restore orientation DEFAULT" after loading to view this orientation.')),this.iterateOverAllNewModels(a,b),this.iterateOverAllNewAtoms(a,b),this.iterateOverAllNewBonds(a,b),this.merging&&!this.appendNew&&(e=a.getAtomSetAuxiliaryInfo(b,0),this.modelSet.setModelAuxiliaryInfo(this.baseModelIndex,
"initialAtomCount",e.get("initialAtomCount")),this.modelSet.setModelAuxiliaryInfo(this.baseModelIndex,"initialBondCount",e.get("initialBondCount"))),this.initializeUnitCellAndSymmetry(),this.initializeBonding());this.finalizeGroupBuild();this.is2D&&this.applyStereochemistry();this.doAddHydrogens&&this.jbr.finalizeHydrogens();null!=a&&(this.modelSet.calculatePolymers(this.groups,this.groupCount,this.baseGroupIndex,null),null!=this.jbr&&this.jbr.iterateOverAllNewStructures(a,b));this.setDefaultRendering(this.viewer.getInt(553648170));
var f=this.viewer.getDefaultRadiusData();c=this.modelSet.atomCount;d=this.modelSet.atoms;for(e=this.baseAtomIndex;e<c;e++)d[e].setMadAtom(this.viewer,f);f=this.modelSet.models;for(e=f[this.baseModelIndex].firstAtomIndex;e<c;e++)f[d[e].modelIndex].bsAtoms.set(e);this.freeze();this.finalizeShapes();this.viewer.setModelSet(this.modelSet);this.setAtomProperties();null!=a&&a.finish(b);null!=this.mergeModelSet&&this.mergeModelSet.releaseModelSet();this.mergeModelSet=null},$fz.isPrivate=!0,$fz),"J.api.JmolAdapter,~O,JU.BS");
$_M(c$,"setDefaultRendering",($fz=function(a){if(!this.isPyMOLsession){for(var b=new JU.SB,c=this.modelSet.modelCount,d=this.modelSet.models,e=this.baseModelIndex;e<c;e++)d[e].isBioModel&&d[e].getDefaultLargePDBRendering(b,a);0!=b.length()&&(b.append("select *;"),a=this.modelSet.getModelSetAuxiliaryInfoValue("jmolscript"),null==a&&(a=""),b.append(a),this.modelSet.modelSetAuxiliaryInfo.put("jmolscript",b.toString()))}},$fz.isPrivate=!0,$fz),"~N");$_M(c$,"setAtomProperties",($fz=function(){for(var a=
this.modelSet.modelCount,b=this.modelSet.models,c=this.baseModelIndex;c<a;c++){b[c].bsAtoms.cardinality();var d=this.modelSet.getModelAuxiliaryInfoValue(c,"atomProperties");if(null!=d)for(var e,d=d.entrySet().iterator();d.hasNext()&&((e=d.next())||1);){var f=e.getKey(),g=e.getValue(),h=this.modelSet.getModelAtomBitSetIncludingDeleted(c,!0);this.doAddHydrogens&&(g=this.jbr.fixPropertyValue(h,g));f="property_"+f.toLowerCase();J.util.Logger.info("creating "+f+" for model "+this.modelSet.getModelName(c));
this.viewer.setData(f,[f,g,h,Integer.$valueOf(0),Boolean.FALSE],this.modelSet.atomCount,0,0,2147483647,0)}}},$fz.isPrivate=!0,$fz));$_M(c$,"initializeAtomBondModelCounts",($fz=function(a){var b=this.adapterTrajectoryCount;this.merging?(this.appendNew?(this.baseModelIndex=this.baseModelCount,this.modelSet.modelCount=this.baseModelCount+this.adapterModelCount):(this.baseModelIndex=this.viewer.getCurrentModelIndex(),0>this.baseModelIndex&&(this.baseModelIndex=this.baseModelCount-1),this.modelSet.modelCount=
this.baseModelCount),this.modelSet.atomCount=this.baseAtomIndex=this.mergeModelSet.atomCount,this.modelSet.bondCount=this.mergeModelSet.bondCount,this.$mergeGroups=this.mergeModelSet.getGroups(),this.groupCount=this.baseGroupIndex=this.$mergeGroups.length,this.modelSet.mergeModelArrays(this.mergeModelSet),this.modelSet.growAtomArrays(this.modelSet.atomCount+a)):(this.modelSet.modelCount=this.adapterModelCount,this.modelSet.atomCount=0,this.modelSet.bondCount=0,this.modelSet.atoms=Array(a),this.modelSet.bonds=
Array(250+a));this.doAddHydrogens&&this.jbr.initializeHydrogenAddition();1<b&&(this.modelSet.modelCount+=b-1);this.modelSet.models=JU.ArrayUtil.arrayCopyObject(this.modelSet.models,this.modelSet.modelCount);this.modelSet.modelFileNumbers=JU.ArrayUtil.arrayCopyI(this.modelSet.modelFileNumbers,this.modelSet.modelCount);this.modelSet.modelNumbers=JU.ArrayUtil.arrayCopyI(this.modelSet.modelNumbers,this.modelSet.modelCount);this.modelSet.modelNumbersForAtomLabel=JU.ArrayUtil.arrayCopyS(this.modelSet.modelNumbersForAtomLabel,
this.modelSet.modelCount);this.modelSet.modelNames=JU.ArrayUtil.arrayCopyS(this.modelSet.modelNames,this.modelSet.modelCount);this.modelSet.frameTitles=JU.ArrayUtil.arrayCopyS(this.modelSet.frameTitles,this.modelSet.modelCount);if(this.merging)for(a=0;a<this.mergeModelSet.modelCount;a++)(this.modelSet.models[a]=this.mergeModelSet.models[a]).modelSet=this.modelSet},$fz.isPrivate=!0,$fz),"~N");$_M(c$,"mergeGroups",($fz=function(){var a=this.mergeModelSet.getAuxiliaryInfo(null),b=a.get("group3Lists"),
a=a.get("group3Counts");if(null!=b){for(var c=0;c<this.baseModelCount;c++)this.group3Lists[c+1]=b[c+1],this.group3Counts[c+1]=a[c+1],this.structuresDefinedInFile.set(c);this.group3Lists[0]=b[0];this.group3Counts[0]=a[0]}!this.appendNew&&this.isPDB&&this.structuresDefinedInFile.clear(this.baseModelIndex)},$fz.isPrivate=!0,$fz));$_M(c$,"iterateOverAllNewModels",($fz=function(a,b){this.group3Lists=Array(this.modelSet.modelCount+1);this.group3Counts=JU.ArrayUtil.newInt2(this.modelSet.modelCount+1);this.structuresDefinedInFile=
new JU.BS;this.merging&&this.mergeGroups();for(var c=this.isTrajectory?this.baseTrajectoryCount:-1,d=this.baseModelIndex,e=0;e<this.adapterModelCount;++e,++d){var f=a.getAtomSetNumber(b,e),g=a.getAtomSetName(b,e),h=a.getAtomSetAuxiliaryInfo(b,e);h.containsKey("modelID")&&h.put("modelID0",h.get("modelID"));var k=h.get("modelProperties");this.viewer.setStringProperty("_fileType",h.get("fileType"));null==g&&(g=null!=this.jmolData&&2<this.jmolData.indexOf(";")?this.jmolData.substring(this.jmolData.indexOf(":")+
2,this.jmolData.indexOf(";")):this.appendNew?""+f%1E6:"");this.setModelNameNumberProperties(d,c,g,f,k,h,this.jmolData)&&(this.group3Lists[d+1]=J.viewer.JC.getGroup3List(),this.group3Counts[d+1]=Clazz.newIntArray(J.viewer.JC.getGroup3Count()+10,0),null==this.group3Lists[0]&&(this.group3Lists[0]=J.viewer.JC.getGroup3List(),this.group3Counts[0]=Clazz.newIntArray(J.viewer.JC.getGroup3Count()+10,0)));null!=this.modelSet.getModelAuxiliaryInfoValue(d,"periodicOriginXyz")&&(this.modelSet.someModelsHaveSymmetry=
!0)}c=this.modelSet.models[this.baseModelIndex];this.viewer.setSmilesString(this.modelSet.modelSetAuxiliaryInfo.get("smilesString"));e=this.modelSet.modelSetAuxiliaryInfo.remove("loadState");f=this.modelSet.modelSetAuxiliaryInfo.remove("loadScript");if(0>f.indexOf("Viewer.AddHydrogens")||!c.isModelKit){g=J.util.Txt.split(e,"\n");h=new JU.SB;for(e=0;e<g.length;e++)k=c.loadState.indexOf(g[e]),(0>k||k!=c.loadState.lastIndexOf(g[e]))&&h.append(g[e]).appendC("\n");c.loadState+=c.loadScript.toString()+
h.toString();c.loadScript=new JU.SB;c.loadScript.append("  ").appendSB(f).append(";\n")}if(this.isTrajectory){e=this.modelSet.modelCount-d+1;J.util.Logger.info(e+" trajectory steps read");this.modelSet.setModelAuxiliaryInfo(this.baseModelCount,"trajectoryStepCount",Integer.$valueOf(e));c=this.adapterModelCount;for(e=d;e<this.modelSet.modelCount;e++,c++)this.modelSet.models[e]=this.modelSet.models[this.baseModelCount],this.modelSet.modelNumbers[e]=a.getAtomSetNumber(b,c),this.modelSet.modelNames[e]=
a.getAtomSetName(b,c),this.structuresDefinedInFile.set(e)}this.finalizeModels(this.baseModelCount)},$fz.isPrivate=!0,$fz),"J.api.JmolAdapter,~O");$_M(c$,"setModelNameNumberProperties",($fz=function(a,b,c,d,e,f,g){var h=null!=f&&Boolean.TRUE===f.get("isPDB");this.appendNew?(this.modelSet.models[a]=h?this.jbr.getBioModel(a,b,g,e,f):new J.modelset.Model(this.modelSet,a,b,g,e,f),this.modelSet.modelNumbers[a]=d,this.modelSet.modelNames[a]=c):(b=f.get("PDB_CONECT_firstAtom_count_max"),null!=b&&this.modelSet.setModelAuxiliaryInfo(a,
"PDB_CONECT_firstAtom_count_max",b));b=this.modelSet.models;d=this.modelSet.atoms;b[a].bsAtoms.set(d.length+1);b[a].bsAtoms.clear(d.length+1);d=this.modelSet.getModelAuxiliaryInfoValue(a,"altLocs");b[a].setNAltLocs(null==d?0:d.length);null!=d&&(d=d.toCharArray(),java.util.Arrays.sort(d),d=String.valueOf(d),this.modelSet.setModelAuxiliaryInfo(a,"altLocs",d));d=this.modelSet.getModelAuxiliaryInfoValue(a,"insertionCodes");b[a].setNInsertions(null==d?0:d.length);c=null!=this.modelSet.modelSetName&&this.modelSet.modelSetName.startsWith("Jmol Model Kit")||
c.startsWith("Jmol Model Kit")||"Jme".equals(this.modelSet.getModelAuxiliaryInfoValue(a,"fileType"));b[a].isModelKit=c;return h},$fz.isPrivate=!0,$fz),"~N,~N,~S,~N,java.util.Properties,java.util.Map,~S");$_M(c$,"finalizeModels",($fz=function(a){var b=this.modelSet.modelCount;if(b!=a){var c,d=0,e=-1,f=this.modelSet.modelNumbers,g=this.modelSet.modelNames;if(this.isTrajectory)for(var h=a;++h<this.modelSet.modelCount;)f[h]=f[h-1]+1;if(0<a){if(1E6>f[0])for(h=0;h<a;h++)0==g[h].length&&(g[h]=""+f[h]),f[h]+=
1E6,this.modelSet.modelNumbersForAtomLabel[h]="1."+(h+1);var k=f[a-1],k=k-k%1E6;1E6>f[a]&&(k+=1E6);for(h=a;h<b;h++)f[h]+=k}for(var l=this.modelSet.models,h=a;h<b;++h)if(this.modelSet.setModelAuxiliaryInfo(h,"fileType",this.modelSet.modelSetTypeName),null!=this.fileHeader&&this.modelSet.setModelAuxiliaryInfo(h,"fileHeader",this.fileHeader),k=Clazz.doubleToInt(f[h]/1E6),k!=e&&(d=0,e=k),d++,0==k?(c=""+this.modelSet.getModelNumber(h),k=1):c=k+"."+d,this.modelSet.modelNumbersForAtomLabel[h]=c,l[h].fileIndex=
k-1,this.modelSet.modelFileNumbers[h]=1E6*k+d,null==g[h]||0==g[h].length)g[h]=c;if(this.merging)for(h=0;h<a;h++)l[h].modelSet=this.modelSet;for(h=0;h<b;h++)this.modelSet.setModelAuxiliaryInfo(h,"modelName",g[h]),this.modelSet.setModelAuxiliaryInfo(h,"modelNumber",Integer.$valueOf(f[h]%1E6)),this.modelSet.setModelAuxiliaryInfo(h,"modelFileNumber",Integer.$valueOf(this.modelSet.modelFileNumbers[h])),this.modelSet.setModelAuxiliaryInfo(h,"modelNumberDotted",this.modelSet.getModelNumberDotted(h)),a=this.modelSet.getModelAuxiliaryInfoValue(h,
"altLocs"),null!=a&&J.util.Logger.info("model "+this.modelSet.getModelNumberDotted(h)+" alternative locations: "+a)}},$fz.isPrivate=!0,$fz),"~N");$_M(c$,"iterateOverAllNewAtoms",($fz=function(a,b){var c=-1,d=!1,e=!1,f=a.getAtomIterator(b),g=0,h=this.modelSet.models;0<this.modelSet.modelCount&&(this.nullGroup=(new J.modelset.Group).setGroup(new J.modelset.Chain(this.modelSet.models[this.baseModelIndex],32),"",0,-1,-1));for(;f.hasNext();){g++;var k=f.getAtomSetIndex()+this.baseModelIndex;k!=c&&(this.currentModelIndex=
k,this.currentModel=h[k],this.currentChainID=2147483647,this.isNewChain=!0,h[k].bsAtoms.clearAll(),d=h[k].isBioModel,c=k,e=d&&this.doAddHydrogens,null!=this.jbr&&this.jbr.setHaveHsAlready(!1));var k=f.getGroup3(),l=f.getChainID();this.checkNewGroup(a,l,k,f.getSequenceNumber(),f.getInsertionCode(),e,!1);l=f.getElementNumber();e&&1==J.util.Elements.getElementNumber(l)&&this.jbr.setHaveHsAlready(!0);var m=f.getAtomName(),n=e?this.getPdbCharge(k,m):f.getFormalCharge();this.addAtom(d,f.getAtomSymmetry(),
f.getAtomSite(),f.getUniqueID(),l,m,n,f.getPartialCharge(),f.getTensors(),f.getOccupancy(),f.getBfactor(),f.getXYZ(),f.getIsHetero(),f.getAtomSerial(),k,f.getVib(),f.getAlternateLocationID(),f.getRadius())}0<this.groupCount&&e&&this.jbr.addImplicitHydrogenAtoms(a,this.groupCount-1,this.isNewChain?1:0);c=-1;d=null;e=this.modelSet.atoms;for(f=0;f<this.modelSet.atomCount;f++)e[f].modelIndex!=c&&(c=e[f].modelIndex,h[c].firstAtomIndex=f,k=this.modelSet.getDefaultVdwType(c),k!==d&&(J.util.Logger.info("Default Van der Waals type for model set to "+
k.getVdwLabel()),d=k));J.util.Logger.info(g+" atoms created")},$fz.isPrivate=!0,$fz),"J.api.JmolAdapter,~O");$_M(c$,"getPdbCharge",($fz=function(a,b){return a.equals("ARG")&&b.equals("NH1")||a.equals("LYS")&&b.equals("NZ")||a.equals("HIS")&&b.equals("ND1")?1:0},$fz.isPrivate=!0,$fz),"~S,~S");$_M(c$,"addAtom",($fz=function(a,b,c,d,e,f,g,h,k,l,m,n,q,p,r,s,t,u){var v=0;null!=f&&(a&&0<=f.indexOf("*")&&(f=f.$replace("*","'")),v=J.viewer.JC.lookupSpecialAtomID(f),a&&(2==v&&"CA".equalsIgnoreCase(r))&&(v=
0));a=this.modelSet.addAtom(this.currentModelIndex,this.nullGroup,e,f,p,c,n,u,s,g,h,l,m,k,q,v,b);a.setAltLoc(t);this.htAtomMap.put(d,a)},$fz.isPrivate=!0,$fz),"~B,JU.BS,~N,~O,~N,~S,~N,~N,JU.List,~N,~N,JU.P3,~B,~N,~S,JU.V3,~S,~N");$_M(c$,"checkNewGroup",($fz=function(a,b,c,d,e,f,g){var h=null==c?null:c.intern();b!=this.currentChainID&&(this.currentChainID=b,this.currentChain=this.getOrAllocateChain(this.currentModel,b),this.currentGroupInsertionCode="\uffff",this.currentGroupSequenceNumber=-1,this.currentGroup3=
"xxxx",this.isNewChain=!0);if(d!=this.currentGroupSequenceNumber||e!=this.currentGroupInsertionCode||h!==this.currentGroup3){0<this.groupCount&&f&&(this.jbr.addImplicitHydrogenAtoms(a,this.groupCount-1,this.isNewChain&&!g?1:0),this.jbr.setHaveHsAlready(!1));this.currentGroupSequenceNumber=d;this.currentGroupInsertionCode=e;for(this.currentGroup3=h;this.groupCount>=this.group3Of.length;)this.chainOf=JU.ArrayUtil.doubleLength(this.chainOf),this.group3Of=JU.ArrayUtil.doubleLengthS(this.group3Of),this.seqcodes=
JU.ArrayUtil.doubleLengthI(this.seqcodes),this.firstAtomIndexes=JU.ArrayUtil.doubleLengthI(this.firstAtomIndexes);this.firstAtomIndexes[this.groupCount]=this.modelSet.atomCount;this.chainOf[this.groupCount]=this.currentChain;this.group3Of[this.groupCount]=c;this.seqcodes[this.groupCount]=J.modelset.Group.getSeqcodeFor(d,e);++this.groupCount}},$fz.isPrivate=!0,$fz),"J.api.JmolAdapter,~N,~S,~N,~S,~B,~B");$_M(c$,"getOrAllocateChain",($fz=function(a,b){var c=a.getChain(b);if(null!=c)return c;a.chainCount==
a.chains.length&&(a.chains=JU.ArrayUtil.doubleLength(a.chains));return a.chains[a.chainCount++]=new J.modelset.Chain(a,b)},$fz.isPrivate=!0,$fz),"J.modelset.Model,~N");$_M(c$,"iterateOverAllNewBonds",($fz=function(a,b){var c=a.getBondIterator(b);if(null!=c){var d=this.viewer.getMadBond();this.modelSet.defaultCovalentMad=null==this.jmolData?d:0;for(var e=!1;c.hasNext();){var f=c.getEncodedOrder(),g=f,h=this.bondAtoms(c.getAtomUniqueID1(),c.getAtomUniqueID2(),g);null!=h&&(1<g&&(1025!=g&&1041!=g)&&(e=
!0),g=c.getRadius(),0<g&&h.setMad(Clazz.floatToShort(2E3*g)),g=c.getColix(),0<=g&&h.setColix(g),h.order|=f&65536)}e&&(this.modelSet.someModelsHaveSymmetry&&!this.viewer.getBoolean(603979794))&&J.util.Logger.info('ModelSet: use "set appletSymmetryToBonds TRUE " to apply the file-based multiple bonds to symmetry-generated atoms.');this.modelSet.defaultCovalentMad=d}},$fz.isPrivate=!0,$fz),"J.api.JmolAdapter,~O");$_M(c$,"bondAtoms",($fz=function(a,b,c){var d=this.htAtomMap.get(a);if(null==d)return J.util.Logger.error("bondAtoms cannot find atomUid1?:"+
a),null;a=this.htAtomMap.get(b);if(null==a)return J.util.Logger.error("bondAtoms cannot find atomUid2?:"+b),null;if(d.isBonded(a))return null;1025==c||1041==c?(b=this.modelSet.bondMutually(d,a,this.is2D?c:1,this.modelSet.getDefaultMadFromOrder(1),0),null==this.vStereo&&(this.vStereo=new JU.List),this.vStereo.addLast(b)):(b=this.modelSet.bondMutually(d,a,c,this.modelSet.getDefaultMadFromOrder(c),0),b.isAromatic()&&(this.modelSet.someModelsHaveAromaticBonds=!0));this.modelSet.bondCount==this.modelSet.bonds.length&&
(this.modelSet.bonds=JU.ArrayUtil.arrayCopyObject(this.modelSet.bonds,this.modelSet.bondCount+250));this.modelSet.setBond(this.modelSet.bondCount++,b);return b},$fz.isPrivate=!0,$fz),"~O,~O,~N");$_M(c$,"initializeUnitCellAndSymmetry",($fz=function(){if(this.someModelsHaveUnitcells){this.modelSet.unitCells=Array(this.modelSet.modelCount);this.modelSet.haveUnitCells=!0;for(var a=null!=this.mergeModelSet&&null!=this.mergeModelSet.unitCells,b=0;b<this.modelSet.modelCount;b++)a&&b<this.baseModelCount?
this.modelSet.unitCells[b]=this.mergeModelSet.unitCells[b]:(this.modelSet.unitCells[b]=J.api.Interface.getOptionInterface("symmetry.Symmetry"),this.modelSet.unitCells[b].setSymmetryInfo(b,this.modelSet.getModelAuxiliaryInfo(b)))}if(this.appendNew&&this.modelSet.someModelsHaveSymmetry){this.modelSet.getAtomBits(1089470478,null);for(var a=this.modelSet.atoms,b=this.baseAtomIndex,c=-1,d=0;b<this.modelSet.atomCount;b++)a[b].modelIndex!=c&&(c=a[b].modelIndex,d=this.baseAtomIndex+this.modelSet.getModelAuxiliaryInfoInt(c,
"presymmetryAtomIndex")+this.modelSet.getModelAuxiliaryInfoInt(c,"presymmetryAtomCount")),b>=d&&this.modelSet.bsSymmetry.set(b)}if(this.appendNew&&this.modelSet.someModelsHaveFractionalCoordinates){a=this.modelSet.atoms;d=-1;c=null;for(b=this.baseAtomIndex;b<this.modelSet.atomCount;b++)a[b].modelIndex!=d&&(d=a[b].modelIndex,c=this.modelSet.getUnitCell(d)),null!=c&&c.getCoordinatesAreFractional()&&c.toCartesian(c.toSupercell(a[b]),!1);for(a=this.baseModelIndex;a<this.modelSet.modelCount;a++)if(this.modelSet.isTrajectory(a)&&
(c=this.modelSet.getUnitCell(a),null!=c&&c.getCoordinatesAreFractional()&&c.isSupercell())){d=this.modelSet.trajectorySteps.get(a);for(b=d.length;0<=--b;)null!=d[b]&&c.toSupercell(d[b])}}},$fz.isPrivate=!0,$fz));$_M(c$,"initializeBonding",($fz=function(){var a=null==this.modelSet.getModelSetAuxiliaryInfoValue("someModelsHaveCONECT")?null:new JU.BS;null!=a&&this.modelSet.setPdbConectBonding(this.baseAtomIndex,this.baseModelIndex,a);var b=0,c=this.viewer.getBoolean(603979794),d=this.viewer.getBoolean(603979798),
e=this.viewer.getBoolean(603979846),f=null,g=!1,h=this.modelSet.modelCount,k=this.modelSet.models;if(!this.noAutoBond)for(var l=this.baseModelIndex;l<h;l++){var b=k[l].bsAtoms.cardinality(),m=this.modelSet.getModelAuxiliaryInfoInt(l,"initialBondCount"),n=k[l].isBioModel;0>m&&(m=this.modelSet.bondCount);var q=this.modelSet.getModelAuxiliaryInfoBoolean(l,"hasSymmetry");if(e||d&&(0==m||n&&null==this.jmolData&&(this.modelSet.getModelSetAuxiliaryInfoBoolean("havePDBHeaderName")||m<Clazz.doubleToInt(b/
2))||q&&!c&&!this.modelSet.getModelAuxiliaryInfoBoolean(l,"hasBonds")))if(g=!0,this.merging||1<h)null==f&&(f=J.util.BSUtil.newBitSet(this.modelSet.atomCount)),(l==this.baseModelIndex||!this.isTrajectory)&&f.or(k[l].bsAtoms)}g?(this.modelSet.autoBondBs4(f,f,a,null,this.modelSet.defaultCovalentMad,this.viewer.getBoolean(603979874)),J.util.Logger.info("ModelSet: autobonding; use  autobond=false  to not generate bonds automatically")):(this.modelSet.initializeBspf(),J.util.Logger.info("ModelSet: not autobonding; use  forceAutobond=true  to force automatic bond creation"))},
$fz.isPrivate=!0,$fz));$_M(c$,"finalizeGroupBuild",($fz=function(){this.groups=Array(this.groupCount);if(this.merging)for(var a=0;a<this.$mergeGroups.length;a++)this.groups[a]=this.$mergeGroups[a],this.groups[a].setModelSet(this.modelSet);for(a=this.baseGroupIndex;a<this.groupCount;++a)this.distinguishAndPropagateGroup(a,this.chainOf[a],this.group3Of[a],this.seqcodes[a],this.firstAtomIndexes[a],a==this.groupCount-1?this.modelSet.atomCount:this.firstAtomIndexes[a+1]);if(null!=this.group3Lists&&null!=
this.modelSet.modelSetAuxiliaryInfo){this.modelSet.modelSetAuxiliaryInfo.put("group3Lists",this.group3Lists);this.modelSet.modelSetAuxiliaryInfo.put("group3Counts",this.group3Counts);for(a=0;a<this.group3Counts.length;a++)null==this.group3Counts[a]&&(this.group3Counts[a]=Clazz.newIntArray(0,0))}},$fz.isPrivate=!0,$fz));$_M(c$,"distinguishAndPropagateGroup",($fz=function(a,b,c,d,e,f){var g=f-1;if(g<e)throw new NullPointerException;var h=this.modelSet.atoms[e].modelIndex,k=null==c||null==this.jbr?null:
this.jbr.distinguishAndPropagateGroup(b,c,d,e,f,h,this.specialAtomIndexes,this.modelSet.atoms);null==k?(k=(new J.modelset.Group).setGroup(b,c,d,e,g),d="o>"):d=k.isProtein()?"p>":k.isNucleic()?"n>":k.isCarbohydrate()?"c>":"o>";null!=c&&this.countGroup(h,d,c);this.addGroup(b,k);this.groups[a]=k;k.setGroupIndex(a);for(a=f;--a>=e;)this.modelSet.atoms[a].setGroup(k)},$fz.isPrivate=!0,$fz),"~N,J.modelset.Chain,~S,~N,~N,~N");$_M(c$,"addGroup",($fz=function(a,b){a.groupCount==a.groups.length&&(a.groups=JU.ArrayUtil.doubleLength(a.groups));
a.groups[a.groupCount++]=b},$fz.isPrivate=!0,$fz),"J.modelset.Chain,J.modelset.Group");$_M(c$,"countGroup",($fz=function(a,b,c){var d=a+1;if(!(null==this.group3Lists||null==this.group3Lists[d])){var e=(c+"   ").substring(0,3),f=this.group3Lists[d].indexOf(e);0>f&&(this.group3Lists[d]+=",["+e+"]",f=this.group3Lists[d].indexOf(e),this.group3Counts[d]=JU.ArrayUtil.arrayCopyI(this.group3Counts[d],this.group3Counts[d].length+10));this.group3Counts[d][Clazz.doubleToInt(f/6)]++;f=this.group3Lists[d].indexOf(",["+
e);0<=f&&(this.group3Lists[d]=this.group3Lists[d].substring(0,f)+b+this.group3Lists[d].substring(f+2));0<=a&&this.countGroup(-1,b,c)}},$fz.isPrivate=!0,$fz),"~N,~S,~S");$_M(c$,"freeze",($fz=function(){this.htAtomMap.clear();this.modelSet.atomCount<this.modelSet.atoms.length&&this.modelSet.growAtomArrays(this.modelSet.atomCount);this.modelSet.bondCount<this.modelSet.bonds.length&&(this.modelSet.bonds=JU.ArrayUtil.arrayCopyObject(this.modelSet.bonds,this.modelSet.bondCount));for(var a=5;0<--a;){this.modelSet.numCached[a]=
0;for(var b=this.modelSet.freeBonds[a],c=b.length;0<=--c;)b[c]=null}this.modelSet.setAtomNamesAndNumbers(0,this.baseAtomIndex,this.mergeModelSet);this.findElementsPresent();this.modelSet.resetMolecules();this.currentChain=this.currentModel=null;!this.isPDB||this.isPyMOLsession?this.modelSet.freezeModels():(a=this.viewer.getBoolean(603979825),a=this.modelSet.calculateStructuresAllExcept(this.structuresDefinedInFile,a,!1,!0,!0,a),0<a.length&&J.util.Logger.info(a))},$fz.isPrivate=!0,$fz));$_M(c$,"findElementsPresent",
($fz=function(){this.modelSet.elementsPresent=Array(this.modelSet.modelCount);for(var a=0;a<this.modelSet.modelCount;a++)this.modelSet.elementsPresent[a]=J.util.BSUtil.newBitSet(64);for(a=this.modelSet.atomCount;0<=--a;){var b=this.modelSet.atoms[a].getAtomicAndIsotopeNumber();b>=J.util.Elements.elementNumberMax&&(b=J.util.Elements.elementNumberMax+J.util.Elements.altElementIndexFromNumber(b));this.modelSet.elementsPresent[this.modelSet.atoms[a].modelIndex].set(b)}},$fz.isPrivate=!0,$fz));$_M(c$,
"applyStereochemistry",($fz=function(){this.set2dZ(this.baseAtomIndex,this.modelSet.atomCount);if(null!=this.vStereo){var a=new JU.BS;a.setBits(this.baseAtomIndex,this.modelSet.atomCount);for(var b=this.vStereo.size();0<=--b;){var c=this.vStereo.get(b),d=1025==c.order?3:-3;c.order=1;c.atom2.z!=c.atom1.z&&0>d==c.atom2.z<c.atom1.z&&(d/=3);var e=J.util.JmolMolecule.getBranchBitSet(this.modelSet.atoms,c.atom2.index,a,null,c.atom1.index,!1,!0);e.set(c.atom2.index);for(var f=e.nextSetBit(0);0<=f;f=e.nextSetBit(f+
1))this.modelSet.atoms[f].z+=d;c.atom2.x=(c.atom1.x+c.atom2.x)/2;c.atom2.y=(c.atom1.y+c.atom2.y)/2}this.vStereo=null}this.is2D=!1},$fz.isPrivate=!0,$fz));$_M(c$,"set2dZ",($fz=function(a,b){var c=J.util.BSUtil.newBitSet(b),d=new JU.BS,e=new JU.V3,f=JU.V3.new3(0,1,0),g=new JU.V3,h=new JU.BS;h.setBits(a,b);for(var k=a;k<b;k++)!c.get(k)&&!d.get(k)&&(d=this.getBranch2dZ(k,-1,h,d,e,f,g),c.or(d))},$fz.isPrivate=!0,$fz),"~N,~N");$_M(c$,"getBranch2dZ",($fz=function(a,b,c,d,e,f,g){d=J.util.BSUtil.newBitSet(this.modelSet.atomCount);
if(0>a)return d;var h=new JU.BS;h.or(c);0<=b&&h.clear(b);J.modelset.ModelLoader.setBranch2dZ(this.modelSet.atoms[a],d,h,e,f,g);return d},$fz.isPrivate=!0,$fz),"~N,~N,JU.BS,JU.BS,JU.V3,JU.V3,JU.V3");c$.setBranch2dZ=$_M(c$,"setBranch2dZ",($fz=function(a,b,c,d,e,f){var g=a.index;if(c.get(g)&&(c.clear(g),b.set(g),null!=a.bonds))for(g=a.bonds.length;0<=--g;){var h=a.bonds[g];h.isHydrogen()||(h=h.getOtherAtom(a),J.modelset.ModelLoader.setAtom2dZ(a,h,d,e,f),J.modelset.ModelLoader.setBranch2dZ(h,b,c,d,e,
f))}},$fz.isPrivate=!0,$fz),"J.modelset.Atom,JU.BS,JU.BS,JU.V3,JU.V3,JU.V3");c$.setAtom2dZ=$_M(c$,"setAtom2dZ",($fz=function(a,b,c,d,e){c.setT(b);c.sub(a);c.z=0;c.normalize();e.cross(d,c);c=Math.acos(c.dot(d));b.z=a.z+0.8*Math.sin(4*c)},$fz.isPrivate=!0,$fz),"J.modelset.Atom,J.modelset.Atom,JU.V3,JU.V3,JU.V3");$_M(c$,"finalizeShapes",($fz=function(){this.modelSet.shapeManager=this.viewer.getShapeManager();this.modelSet.shapeManager.setModelSet(this.modelSet);this.modelSet.setBsHidden(this.viewer.getHiddenSet());
this.merging||this.modelSet.shapeManager.resetShapes();this.modelSet.shapeManager.loadDefaultShapes(this.modelSet);this.modelSet.someModelsHaveAromaticBonds&&this.viewer.getBoolean(603979944)&&this.modelSet.assignAromaticBondsBs(!1,null);this.merging&&1==this.baseModelCount&&this.modelSet.shapeManager.setShapePropertyBs(6,"clearModelIndex",null,null)},$fz.isPrivate=!0,$fz));$_M(c$,"undeleteAtom",function(a){this.modelSet.atoms[a].valence=0},"~N");$_M(c$,"deleteAtoms",function(a){this.doRemoveAddedHydrogens=
!0;for(var b=Clazz.newIntArray(this.modelSet.atomCount,0),c=Clazz.newIntArray(this.modelSet.atomCount-a.cardinality(),0),d=this.baseAtomIndex,e=this.modelSet.models,f=this.modelSet.atoms,g=this.baseAtomIndex;g<this.modelSet.atomCount;g++)e[f[g].modelIndex].bsAtoms.clear(g),e[f[g].modelIndex].bsAtomsDeleted.clear(g),a.get(g)?(b[g]=d-1,e[f[g].modelIndex].atomCount--):(c[d]=g,b[g]=d++);this.modelSet.modelSetAuxiliaryInfo.put("bsDeletedAtoms",a);for(g=this.baseGroupIndex;g<this.groups.length;g++)a=this.groups[g],
a.firstAtomIndex>=this.baseAtomIndex&&(a.firstAtomIndex=b[a.firstAtomIndex],a.lastAtomIndex=b[a.lastAtomIndex],0<=a.leadAtomIndex&&(a.leadAtomIndex=b[a.leadAtomIndex]));this.modelSet.adjustAtomArrays(c,this.baseAtomIndex,d);this.modelSet.calcBoundBoxDimensions(null,1);this.modelSet.resetMolecules();this.modelSet.validateBspf(!1)},"JU.BS");c$.createAtomDataSet=$_M(c$,"createAtomDataSet",function(a,b,c,d,e){if(null!=d){var f=a.getModelAdapter(),g=new JU.P3,h=b.atoms,k=a.getFloat(570425363);if(null!=
b.unitCells)for(var l=e.nextSetBit(0);0<=l;l=e.nextSetBit(l+1))if(null!=h[l].getAtomSymmetry()){k=-k;break}for(var l=-1,m=0,n=J.util.BSUtil.cardinalityOf(e)==a.getAtomCount(),q=f.getAtomIterator(d);q.hasNext();){var p=q.getXYZ();if(!Float.isNaN(p.x+p.y+p.z))if(1146095626==c){l=e.nextSetBit(l+1);if(0>l)break;m++;J.util.Logger.debugging&&J.util.Logger.debug("atomIndex = "+l+": "+h[l]+" --\x3e ("+p.x+","+p.y+","+p.z);b.setAtomCoord(l,p.x,p.y,p.z)}else{g.setT(p);p=J.util.BSUtil.newBitSet(b.atomCount);
b.getAtomsWithin(k,g,p,-1);p.and(e);if(n)if(m=J.util.BSUtil.cardinalityOf(p),0==m){J.util.Logger.warn("createAtomDataSet: no atom found at position "+g);continue}else 1<m&&J.util.Logger.debugging&&J.util.Logger.debug("createAtomDataSet: "+m+" atoms found at position "+g);switch(c){case 1146095631:var r=q.getVib();if(null==r)continue;J.util.Logger.debugging&&J.util.Logger.debug("xyz: "+g+" vib: "+r);b.setAtomCoords(p,1146095631,r);break;case 1129318401:b.setAtomProperty(p,c,q.getOccupancy(),0,null,
null,null);break;case 1112541196:b.setAtomProperty(p,c,0,q.getPartialCharge(),null,null,null);break;case 1112541199:b.setAtomProperty(p,c,0,q.getBfactor(),null,null,null)}}}switch(c){case 1146095631:b=f.getAtomSetName(d,0);J.util.Logger.info("_vibrationName = "+b);a.setStringProperty("_vibrationName",b);break;case 1146095626:J.util.Logger.info(m+" atom positions read"),b.recalculateLeadMidpointsAndWingVectors(-1)}}},"J.viewer.Viewer,J.modelset.ModelSet,~N,~O,JU.BS");Clazz.defineStatics(c$,"defaultGroupCount",
32)}),Clazz.declarePackage("J.viewer"),c$=Clazz.declareType(J.viewer,"TransformManager11"),Clazz.declarePackage("J.modelset"),c$=Clazz.decorateAsClass(function(){this.model=null;this.chainID=0;this.isRna=this.isDna=!1;this.groupCount=0;this.groups=null;this.selectedGroupCount=0;Clazz.instantialize(this,arguments)},J.modelset,"Chain"),Clazz.prepareFields(c$,function(){this.groups=Array(16)}),$_M(c$,"getAtom",function(a){return this.model.modelSet.atoms[a]},"~N"),Clazz.makeConstructor(c$,function(a,
b){this.model=a;this.chainID=b},"J.modelset.Model,~N"),$_M(c$,"getGroup",function(a){return this.groups[a]},"~N"),$_M(c$,"getGroupCount",function(){return this.groupCount}),$_M(c$,"calcSelectedGroupsCount",function(a){for(var b=this.selectedGroupCount=0;b<this.groupCount;b++)this.groups[b].selectedIndex=this.groups[b].isSelected(a)?this.selectedGroupCount++:-1},"JU.BS"),$_M(c$,"selectSeqcodeRange",function(a,b,c,d){var e,f,g,h=!1;for(f=a;f<this.groupCount&&this.groups[f].seqcode!=b;f++);if(f==this.groupCount){if(0<
a)return-1;h=!0;g=2147483647;for(var k=this.groupCount;0<=--k;)if((e=this.groups[k].seqcode)>b&&e-b<g)f=k,g=e-b;if(2147483647==g)return-1}if(2147483647==c)b=this.groupCount-1,h=!0;else{for(b=f;b<this.groupCount&&this.groups[b].seqcode!=c;b++);if(b==this.groupCount){if(0<a)return-1;h=!0;g=2147483647;for(k=f;k<this.groupCount;k++)if((e=this.groups[k].seqcode)<c&&c-e<g)b=k,g=c-e;if(2147483647==g)return-1}}for(k=f;k<=b;++k)this.groups[k].selectAtoms(d);return h?-1:b+1},"~N,~N,~N,JU.BS"),$_M(c$,"fixIndices",
function(a,b){for(var c=0;c<this.groupCount;c++)this.groups[c].fixIndices(a,b)},"~N,JU.BS"),$_M(c$,"setAtomBitSet",function(a){for(var b=0;b<this.groupCount;b++)this.groups[b].selectAtoms(a)},"JU.BS"),$_M(c$,"getIDStr",function(){return 0==this.chainID?"":256>this.chainID?""+String.fromCharCode(this.chainID):this.model.modelSet.viewer.chainMap.get(Integer.$valueOf(this.chainID))}),Clazz.declarePackage("J.modelset"),Clazz.load(["JU.BS","$.SB"],"J.modelset.Model",["java.util.Hashtable","JU.ArrayUtil",
"J.util.BSUtil"],function(){c$=Clazz.decorateAsClass(function(){this.modelSet=null;this.hydrogenCount=this.fileIndex=this.modelIndex=0;this.hasRasmolHBonds=this.isPdbWithMultipleBonds=this.isBioModel=!1;this.loadState="";this.loadScript=null;this.isModelKit=!1;this.dataFrames=null;this.dataSourceFrame=-1;this.jmolFrameType=this.jmolData=null;this.atomCount=this.firstAtomIndex=0;this.bsAtomsDeleted=this.bsAtoms=null;this.trajectoryBaseIndex=0;this.isTrajectory=!1;this.bondCount=this.selectedTrajectory=
-1;this.nInsertions=this.nAltLocs=this.moleculeCount=this.firstMoleculeIndex=0;this.groupCount=-1;this.chainCount=0;this.chains=null;this.biosymmetryCount=0;this.properties=this.auxiliaryInfo=null;this.defaultRotationRadius=0;this.orientation=this.defaultStructure=null;this.isJmolDataFrame=this.structureTainted=!1;this.frameDelay=0;this.simpleCage=null;Clazz.instantialize(this,arguments)},J.modelset,"Model");Clazz.prepareFields(c$,function(){this.loadScript=new JU.SB;this.bsAtoms=new JU.BS;this.bsAtomsDeleted=
new JU.BS;this.chains=Array(8)});$_M(c$,"getModelSet",function(){return this.modelSet});$_M(c$,"isModelkit",function(){return this.isModelKit});$_M(c$,"getTrueAtomCount",function(){return this.bsAtoms.cardinality()-this.bsAtomsDeleted.cardinality()});$_M(c$,"setSelectedTrajectory",function(a){this.selectedTrajectory=a},"~N");$_M(c$,"getSelectedTrajectory",function(){return this.selectedTrajectory});$_M(c$,"resetBoundCount",function(){this.bondCount=-1});$_M(c$,"getBondCount",function(){if(0<=this.bondCount)return this.bondCount;
var a=this.modelSet.bonds;this.bondCount=0;for(var b=this.modelSet.bondCount;0<=--b;)a[b].atom1.modelIndex==this.modelIndex&&this.bondCount++;return this.bondCount});Clazz.makeConstructor(c$,function(a,b,c,d,e,f){this.modelSet=a;this.dataSourceFrame=this.modelIndex=b;this.trajectoryBaseIndex=(this.isTrajectory=0<=c)?c:b;null==f&&(f=new java.util.Hashtable);this.auxiliaryInfo=f;f.containsKey("biosymmetryCount")&&(this.biosymmetryCount=f.get("biosymmetryCount").intValue());this.properties=e;null==d?
this.jmolFrameType="modelSet":(this.jmolData=d,this.isJmolDataFrame=!0,f.put("jmolData",d),f.put("title",d),this.jmolFrameType=0<=d.indexOf("ramachandran")?"ramachandran":0<=d.indexOf("quaternion")?"quaternion":"data")},"J.modelset.ModelSet,~N,~N,~S,java.util.Properties,java.util.Map");$_M(c$,"setNAltLocs",function(a){this.nAltLocs=a},"~N");$_M(c$,"setNInsertions",function(a){this.nInsertions=a},"~N");$_M(c$,"getModelNumberDotted",function(){return this.modelSet.getModelNumberDotted(this.modelIndex)});
$_M(c$,"getModelTitle",function(){return this.modelSet.getModelTitle(this.modelIndex)});$_M(c$,"isStructureTainted",function(){return this.structureTainted});$_M(c$,"getChains",function(){return this.chains});$_M(c$,"getChainCount",function(a){if(1<this.chainCount&&!a)for(a=0;a<this.chainCount;a++)if(0==this.chains[a].chainID)return this.chainCount-1;return this.chainCount},"~B");$_M(c$,"getGroupCountHetero",function(a){for(var b=0,c=this.chainCount;0<=--c;)for(var d=this.chains[c].groupCount;0<=
--d;)this.chains[c].groups[d].isHetero()==a&&b++;return b},"~B");$_M(c$,"calcSelectedGroupsCount",function(a){for(var b=this.chainCount;0<=--b;)this.chains[b].calcSelectedGroupsCount(a)},"JU.BS");$_M(c$,"getGroupCount",function(){if(0>this.groupCount){this.groupCount=0;for(var a=this.chainCount;0<=--a;)this.groupCount+=this.chains[a].getGroupCount()}return this.groupCount});$_M(c$,"getChainAt",function(a){return a<this.chainCount?this.chains[a]:null},"~N");$_M(c$,"getChain",function(a){for(var b=
this.chainCount;0<=--b;){var c=this.chains[b];if(c.chainID==a)return c}return null},"~N");$_M(c$,"fixIndices",function(a,b,c){this.fixIndicesM(a,b,c)},"~N,~N,JU.BS");$_M(c$,"fixIndicesM",function(a,b,c){this.dataSourceFrame>a&&this.dataSourceFrame--;this.trajectoryBaseIndex>a&&this.trajectoryBaseIndex--;this.firstAtomIndex-=b;for(a=0;a<this.chainCount;a++)this.chains[a].fixIndices(b,c);J.util.BSUtil.deleteBits(this.bsAtoms,c);J.util.BSUtil.deleteBits(this.bsAtomsDeleted,c)},"~N,~N,JU.BS");$_M(c$,
"freeze",function(){this.freezeM()});$_M(c$,"freezeM",function(){this.chains=JU.ArrayUtil.arrayCopyObject(this.chains,this.chainCount);this.groupCount=-1;this.getGroupCount();for(var a=0;a<this.chainCount;++a)this.chains[a].groups=JU.ArrayUtil.arrayCopyObject(this.chains[a].groups,this.chains[a].groupCount)});$_M(c$,"getPdbData",function(){},"J.viewer.Viewer,~S,~S,~B,JU.BS,J.io.JmolOutputChannel,~A,JU.SB,JU.BS");$_M(c$,"getDefaultLargePDBRendering",function(){},"JU.SB,~N");$_M(c$,"getBioBranches",
function(a){return a},"JU.List");$_M(c$,"getGroupsWithin",function(){},"~N,JU.BS,JU.BS");$_M(c$,"getSequenceBits",function(){},"~S,JU.BS,JU.BS");$_M(c$,"getRasmolHydrogenBonds",function(){},"JU.BS,JU.BS,JU.List,~B,~N,~B,JU.BS");$_M(c$,"clearRasmolHydrogenBonds",function(){},"JU.BS");$_M(c$,"clearBioPolymers",function(){});$_M(c$,"calcSelectedMonomersCount",function(){},"JU.BS");$_M(c$,"calculatePolymers",function(){},"~A,~N,~N,JU.BS,~B");$_M(c$,"getAllPolymerInfo",function(){},"JU.BS,java.util.Map,JU.List");
$_M(c$,"getBioPolymerCount",function(){return 0});$_M(c$,"getPolymerPointsAndVectors",function(){},"JU.BS,JU.List,~B,~N");$_M(c$,"getPolymerLeadMidPoints",function(){return null},"~N");$_M(c$,"recalculateLeadMidpointsAndWingVectors",function(){});$_M(c$,"calculateStructures",function(){return""},"~B,~B,~B,~B,~B");$_M(c$,"setStructureList",function(){},"java.util.Map");$_M(c$,"getChimeInfo",function(a,b){this.getChimeInfoM(a,b)},"JU.SB,~N");$_M(c$,"getChimeInfoM",function(a,b){a.append("\nNumber of Atoms ..... "+
(this.modelSet.atomCount-b));0<b&&a.append(" ("+b+")");a.append("\nNumber of Bonds ..... "+this.modelSet.bondCount);a.append("\nNumber of Models ...... "+this.modelSet.modelCount)},"JU.SB,~N");$_M(c$,"calculateStruts",function(){return 0},"J.modelset.ModelSet,JU.BS,JU.BS");$_M(c$,"calculateStraightness",function(){},"J.viewer.Viewer,~S,~S,~N");$_M(c$,"selectSeqcodeRange",function(){},"~N,~N,~N,JU.BS,~B");$_M(c$,"setConformation",function(){},"JU.BS");$_M(c$,"getPdbConformation",function(){return!1},
"JU.BS,~N");$_M(c$,"getProteinStructureState",function(){return null},"JU.BS,~B,~B,~N");$_M(c$,"getFullPDBHeader",function(){return null})}),Clazz.declarePackage("J.modelset"),Clazz.load(["J.modelset.ModelCollection","JU.M3","$.M4","$.V3"],"J.modelset.ModelSet","java.lang.Boolean java.util.Hashtable JU.A4 $.BS $.List $.P3 $.SB J.api.Interface J.atomdata.RadiusData J.util.BSUtil $.JmolMolecule $.Measure $.Quaternion J.viewer.JC".split(" "),function(){c$=Clazz.decorateAsClass(function(){this.echoShapeActive=
this.selectionHaloEnabled=!1;this.vTemp=this.mat4t=this.mat4=this.matInv=this.matTemp=this.pointGroup=this.closest=this.modelSetTypeName=null;Clazz.instantialize(this,arguments)},J.modelset,"ModelSet",J.modelset.ModelCollection);Clazz.prepareFields(c$,function(){this.closest=Array(1);this.matTemp=new JU.M3;this.matInv=new JU.M3;this.mat4=new JU.M4;this.mat4t=new JU.M4;this.vTemp=new JU.V3});Clazz.makeConstructor(c$,function(a,b){Clazz.superConstructor(this,J.modelset.ModelSet,[]);this.viewer=a;this.modelSetName=
b},"J.viewer.Viewer,~S");$_M(c$,"releaseModelSet",function(){this.models=null;this.closest[0]=null;Clazz.superCall(this,J.modelset.ModelSet,"releaseModelSet",[])});$_M(c$,"setSelectionHaloEnabled",function(a){this.selectionHaloEnabled=a},"~B");$_M(c$,"getSelectionHaloEnabled",function(){return this.selectionHaloEnabled});$_M(c$,"getEchoStateActive",function(){return this.echoShapeActive});$_M(c$,"setEchoStateActive",function(a){this.echoShapeActive=a},"~B");$_M(c$,"getModelSetTypeName",function(){return this.modelSetTypeName});
$_M(c$,"getModelNumberIndex",function(a,b,c){if(b){for(b=0;b<this.modelCount;b++)if(this.modelNumbers[b]==a||1E6>a&&this.modelNumbers[b]==1E6+a)return b;return-1}for(b=0;b<this.modelCount;b++)if(this.modelFileNumbers[b]==a)return c&&this.isTrajectory(b)&&this.setTrajectory(b),b;return-1},"~N,~B,~B");$_M(c$,"getBitSetTrajectories",function(){if(null==this.trajectorySteps)return null;for(var a=new JU.BS,b=this.modelCount;0<=--b;){var c=this.models[b].getSelectedTrajectory();0<=c&&(a.set(c),b=this.models[b].trajectoryBaseIndex)}return a});
$_M(c$,"setTrajectoryBs",function(a){for(var b=0;b<this.modelCount;b++)a.get(b)&&this.setTrajectory(b)},"JU.BS");$_M(c$,"setTrajectory",function(a){if(!(0>a)&&this.isTrajectory(a)&&this.atoms[this.models[a].firstAtomIndex].modelIndex!=a){var b=this.models[a].trajectoryBaseIndex;this.models[b].setSelectedTrajectory(a);this.setAtomPositions(b,a,this.trajectorySteps.get(a),null,0,null==this.vibrationSteps?null:this.vibrationSteps.get(a),!0);b=this.viewer.getCurrentModelIndex();0<=b&&(b!=a&&this.models[b].fileIndex==
this.models[a].fileIndex)&&this.viewer.setCurrentModelIndexClear(a,!1)}},"~N");$_M(c$,"morphTrajectories",function(a,b,c){if(!(0>a||0>b||!this.isTrajectory(a)||!this.isTrajectory(b)))if(0==c)this.setTrajectory(a);else if(1==c)this.setTrajectory(b);else{var d=this.models[a].trajectoryBaseIndex;this.models[d].setSelectedTrajectory(a);this.setAtomPositions(d,a,this.trajectorySteps.get(a),this.trajectorySteps.get(b),c,null==this.vibrationSteps?null:this.vibrationSteps.get(a),!0);b=this.viewer.getCurrentModelIndex();
0<=b&&(b!=a&&this.models[b].fileIndex==this.models[a].fileIndex)&&this.viewer.setCurrentModelIndexClear(a,!1)}},"~N,~N,~N");$_M(c$,"setAtomPositions",($fz=function(a,b,c,d,e,f,g){var h=new JU.BS,k=new JU.V3,l=this.models[a].firstAtomIndex,m=l+this.getAtomCountInModel(a);if(0==e)for(var n=0;l<m&&n<c.length;l++,n++)this.atoms[l].modelIndex=b,null!=c[n]&&(g?this.atoms[l].setFractionalCoordTo(c[n],!0):this.atoms[l].setT(c[n]),null!=this.vibrationSteps&&(null!=f&&null!=f[n]&&(k=f[n]),this.setVibrationVector(l,
k)),h.set(l));else{f=new JU.P3;k=Math.min(c.length,d.length);for(n=0;l<m&&n<k;l++,n++)this.atoms[l].modelIndex=b,null==c[n]||null==d[n]||(f.sub2(d[n],c[n]),f.scaleAdd2(e,f,c[n]),g?this.atoms[l].setFractionalCoordTo(f,!0):this.atoms[l].setT(f),h.set(l))}this.initializeBspf();this.validateBspfForModel(a,!1);this.recalculateLeadMidpointsAndWingVectors(a);this.shapeManager.refreshShapeTrajectories(a,h,null);this.models[a].hasRasmolHBonds&&(this.models[a].clearRasmolHydrogenBonds(null),this.models[a].getRasmolHydrogenBonds(h,
h,null,!1,2147483647,!1,null))},$fz.isPrivate=!0,$fz),"~N,~N,~A,~A,~N,~A,~B");$_M(c$,"getFrameOffsets",function(a){if(null==a)return null;for(var b=Array(this.modelCount),c=0;c<this.modelCount;c++)b[c]=new JU.P3;for(var d=0,e=0,f=b[0],g=null!=this.trajectorySteps&&this.trajectorySteps.size()==this.modelCount,h=g?this.modelCount:1,k=0;k<h;k++){g&&this.setTrajectory(k);for(c=0;c<=this.atomCount;c++){if(c==this.atomCount||this.atoms[c].modelIndex!=d){0<e&&(f.scale(-1/e),0!=d&&f.sub(b[0]),e=0);if(c==
this.atomCount)break;d=this.atoms[c].modelIndex;f=b[d]}a.get(c)&&(f.add(this.atoms[c]),e++)}}b[0].set(0,0,0);return b},"JU.BS");$_M(c$,"getAtomBits",function(a,b){switch(a){default:return J.util.BSUtil.andNot(this.getAtomBitsMaybeDeleted(a,b),this.viewer.getDeletedAtoms());case 1048610:var c=b.intValue(),d=this.getModelNumberIndex(c,!0,!0);return 0>d&&0<c?new JU.BS:this.viewer.getModelUndeletedAtomsBitSet(d)}},"~N,~O");$_M(c$,"getAtomLabel",function(a){return this.viewer.getShapePropertyIndex(5,"label",
a)},"~N");$_M(c$,"findNearestAtomIndex",function(a,b,c,d){if(0==this.atomCount)return-1;this.closest[0]=null;this.g3d.isAntialiased()&&(a<<=1,b<<=1);this.findNearest2(a,b,this.closest,c,d);this.shapeManager.findNearestShapeAtomIndex(a,b,this.closest,c);a=null==this.closest[0]?-1:this.closest[0].index;this.closest[0]=null;return a},"~N,~N,JU.BS,~N");$_M(c$,"calculateStructures",function(a,b,c,d){var e=new JU.BS;a=J.util.BSUtil.copyInvert(this.modelsOf(a,e),this.modelCount);if(!d)return this.calculateStructuresAllExcept(a,
b,!0,c,!1,!1);for(d=0;d<this.modelCount;d++)a.get(d)||this.models[d].clearBioPolymers();this.calculatePolymers(null,0,0,a);b=this.calculateStructuresAllExcept(a,b,!0,c,!0,!1);this.viewer.resetBioshapes(e);this.setStructureIndexes();return b},"JU.BS,~B,~B,~B");$_M(c$,"calculatePointGroup",function(a){return this.calculatePointGroupForFirstModel(a,!1,!1,!1,null,0,0)},"JU.BS");$_M(c$,"getPointGroupInfo",function(a){return this.calculatePointGroupForFirstModel(a,!1,!1,!0,null,0,0)},"JU.BS");$_M(c$,"getPointGroupAsString",
function(a,b,c,d,e){return this.calculatePointGroupForFirstModel(a,!0,b,!1,c,d,e)},"JU.BS,~B,~S,~N,~N");$_M(c$,"calculatePointGroupForFirstModel",($fz=function(a,b,c,d,e,f,g){var h=this.viewer.getCurrentModelIndex(),k=null==a?-1:a.nextSetBit(0);0>h&&0<=k&&(h=this.atoms[k].getModelIndex());0>h&&(h=this.viewer.getVisibleFramesBitSet().nextSetBit(0),a=null);var l=this.viewer.getModelUndeletedAtomsBitSet(h);null!=a&&l.and(a);k=l.nextSetBit(0);0>k&&(l=this.viewer.getModelUndeletedAtomsBitSet(h),k=l.nextSetBit(0));
a=this.viewer.getShapePropertyIndex(18,"mad",k);a=null!=a&&0!=a.intValue()||this.viewer.isVibrationOn();this.pointGroup=J.api.Interface.getOptionInterface("symmetry.Symmetry").setPointGroup(this.pointGroup,this.atoms,l,a,this.viewer.getFloat(570425382),this.viewer.getFloat(570425384));if(!b&&!d)return this.pointGroup.getPointGroupName();b=this.pointGroup.getPointGroupInfo(h,c,d,e,f,g);return d?b:(1<this.modelCount?"frame "+this.getModelNumberDotted(h)+"; ":"")+b},$fz.isPrivate=!0,$fz),"JU.BS,~B,~B,~B,~S,~N,~N");
$_M(c$,"modelsOf",($fz=function(a,b){for(var c=J.util.BSUtil.newBitSet(this.modelCount),d=null==a,e=d?this.atomCount-1:a.nextSetBit(0);0<=e;e=d?e-1:a.nextSetBit(e+1)){var f=this.models[this.atoms[e].modelIndex].trajectoryBaseIndex;this.isJmolDataFrameForModel(f)||(c.set(f),b.set(e))}return c},$fz.isPrivate=!0,$fz),"JU.BS,JU.BS");$_M(c$,"getDefaultStructure",function(a,b){for(var c=this.modelsOf(a,b),d=new JU.SB,e=c.nextSetBit(0);0<=e;e=c.nextSetBit(e+1))this.models[e].isBioModel&&null!=this.models[e].defaultStructure&&
d.append(this.models[e].defaultStructure);return d.toString()},"JU.BS,JU.BS");$_M(c$,"makeConnections",function(a,b,c,d,e,f,g,h,k,l){if(1073741852==d&&2048!=c){var m="connect ";0.1!=a&&(m+=a+" ");1E8!=b&&(m+=b+" ");this.addStateScript(m,h?e:null,h?null:e,h?null:f," auto",!1,!0)}this.moleculeCount=0;return this.makeConnections2(a,b,c,d,e,f,g,h,k,l)},"~N,~N,~N,~N,JU.BS,JU.BS,JU.BS,~B,~B,~N");$_M(c$,"setPdbConectBonding",function(a,b,c){for(var d=this.viewer.getMadBond();b<this.modelCount;b++){var e=
this.getModelAuxiliaryInfoValue(b,"PDB_CONECT_bonds");if(null!=e){var f=e.size();this.setModelAuxiliaryInfo(b,"initialBondCount",Integer.$valueOf(f));for(var g=this.getModelAuxiliaryInfoValue(b,"PDB_CONECT_firstAtom_count_max"),h=g[0]+a,k=h+g[1],g=g[2],l=Clazz.newIntArray(g+1,0),m=h;m<k;m++)if(0<(h=this.atomSerials[m]))l[h]=m+1;for(k=0;k<f;k++){var m=e.get(k),n=m[0],h=m[1],m=m[2];0>n||(0>h||n>g||h>g)||(n=l[n]-1,h=l[h]-1,0>n||0>h||(null!=c&&(this.atoms[n].isHetero()&&c.set(n),this.atoms[h].isHetero()&&
c.set(h)),this.checkValencesAndBond(this.atoms[n],this.atoms[h],m,2048==m?1:d,null)))}}}},"~N,~N,JU.BS");$_M(c$,"deleteAllBonds",function(){this.moleculeCount=0;for(var a=this.stateScripts.size();0<=--a;)this.stateScripts.get(a).isConnect()&&this.stateScripts.remove(a);this.deleteAllBonds2()});$_M(c$,"includeAllRelatedFrames",($fz=function(a){for(var b,c=0;c<this.modelCount;c++)if(a.get(c)){if(this.isTrajectory(c)&&!a.get(b=this.models[c].trajectoryBaseIndex)){a.set(b);this.includeAllRelatedFrames(a);
break}}else(this.isTrajectory(c)&&a.get(this.models[c].trajectoryBaseIndex)||this.isJmolDataFrameForModel(c)&&a.get(this.models[c].dataSourceFrame))&&a.set(c)},$fz.isPrivate=!0,$fz),"JU.BS");$_M(c$,"deleteModels",function(a){this.moleculeCount=0;a=this.getModelBitSet(a,!1);this.includeAllRelatedFrames(a);var b=J.util.BSUtil.cardinalityOf(a);if(0==b)return null;for(var c=a.nextSetBit(0);0<=c;c=a.nextSetBit(c+1))this.clearDataFrameReference(c);if(b==this.modelCount)return b=this.getModelAtomBitSetIncludingDeleted(-1,
!0),this.viewer.zap(!0,!1,!1),b;this.validateBspf(!1);for(var d=Array(this.modelCount-b),e=this.models,b=new JU.BS,f=c=0;c<this.modelCount;c++)a.get(c)?(this.getAtomCountInModel(c),b.or(this.getModelAtomBitSetIncludingDeleted(c,!1))):(this.models[c].modelIndex=f,d[f++]=this.models[c]);this.models=d;var g=this.modelCount,h=this.getBondsForSelectedAtoms(b,!0);this.deleteBonds(h,!0);for(f=c=0;c<g;c++)if(a.get(c)){var k=e[c].atomCount;if(0!=k){var l=e[c].bsAtoms,m=e[c].firstAtomIndex;J.util.BSUtil.deleteBits(this.bsSymmetry,
l);this.deleteModel(f,m,k,l,h);for(var n=g;--n>c;)e[n].fixIndices(f,k,l);this.viewer.deleteShapeAtoms([d,this.atoms,[f,m,k]],l);this.modelCount--}}else f++;this.deleteModel(-1,0,0,null,null);return b},"JU.BS");$_M(c$,"setAtomProperty",function(a,b,c,d,e,f,g){switch(b){case 1115297793:case 1113200642:case 1113200647:case 1113200649:case 1113200650:case 1650071565:case 1113200654:if(4<d&&(d=4),null!=f){c=Clazz.newFloatArray(this.atomCount,0);e=a.nextSetBit(0);for(g=0;0<=e;e=a.nextSetBit(e+1))c[e]=f[g++];
f=c}case 1113200646:case 1113200652:c=null;e=0;null==f?(16<d&&(d=16),0>d&&(d=0),e=Clazz.doubleToInt(Math.floor(2E3*d))):c=new J.atomdata.RadiusData(f,0,null,null);this.shapeManager.setShapeSizeBs(J.viewer.JC.shapeTokenIndex(b),e,c,a);return}this.setAPm(a,b,c,d,e,f,g)},"JU.BS,~N,~N,~N,~S,~A,~A");$_M(c$,"getFileData",function(a){if(0>a)return"";var b=this.getModelAuxiliaryInfoValue(a,"fileData");if(null!=b)return b;if(!this.getModelAuxiliaryInfoBoolean(a,"isCIF"))return this.getPDBHeader(a);b=this.viewer.getCifData(a);
this.setModelAuxiliaryInfo(a,"fileData",b);return b},"~N");Clazz.overrideMethod(c$,"calculateStruts",function(a,b){this.viewer.setModelVisibility();return this.calculateStrutsMC(a,b)},"JU.BS,JU.BS");$_M(c$,"addHydrogens",function(a,b){var c=this.modelCount-1,d=new JU.BS;if(this.isTrajectory(c)||1<this.models[c].getGroupCount())return d;this.growAtomArrays(this.atomCount+b.length);for(var e=this.viewer.getDefaultRadiusData(),f=this.getDefaultMadFromOrder(1),g=0,h=this.models[c].atomCount+1;g<a.size();g++,
h++){var k=a.get(g),l=this.addAtom(c,k.group,1,"H"+h,h,h,b[g],NaN,null,0,0,100,NaN,null,!1,0,null);l.setMadAtom(this.viewer,e);d.set(l.index);this.bondAtoms(k,l,1,f,null,0,!1,!1)}this.shapeManager.loadDefaultShapes(this);return d},"JU.List,~A");$_M(c$,"setAtomCoordsRelative",function(a,b){this.setAtomsCoordRelative(b,a.x,a.y,a.z);this.mat4.setIdentity();this.vTemp.setT(a);this.mat4.setTranslation(this.vTemp);this.recalculatePositionDependentQuantities(b,this.mat4)},"JU.T3,JU.BS");$_M(c$,"setAtomCoords",
function(a,b,c){this.setAtomCoord2(a,b,c);switch(b){case 1112541202:case 1112541203:case 1112541204:case 1146095631:break;default:this.recalculatePositionDependentQuantities(a,null)}},"JU.BS,~N,~O");$_M(c$,"invertSelected",function(a,b,c,d,e){if(null!=a)for(var f=e.nextSetBit(0);0<=f;f=e.nextSetBit(f+1)){c=2*(a.x-this.atoms[f].x);d=2*(a.y-this.atoms[f].y);var g=2*(a.z-this.atoms[f].z);this.setAtomCoordRelative(f,c,d,g)}else if(null!=b){a=JU.V3.new3(b.x,b.y,b.z);a.normalize();for(var h=Math.sqrt(b.x*
b.x+b.y*b.y+b.z*b.z),f=e.nextSetBit(0);0<=f;f=e.nextSetBit(f+1))g=2*-J.util.Measure.distanceToPlaneD(b,h,this.atoms[f]),c=a.x*g,d=a.y*g,g*=a.z,this.setAtomCoordRelative(f,c,d,g)}else if(0<=c&&(b=this.atoms[c],a=b.bonds,null!=a)){e=new JU.BS;g=new JU.List;h=this.viewer.getModelUndeletedAtomsBitSet(b.modelIndex);for(f=0;f<a.length;f++){var k=a[f].getOtherAtom(b);d.get(k.index)?e.or(J.util.JmolMolecule.getBranchBitSet(this.atoms,k.index,h,null,c,!0,!0)):g.addLast(k)}0!=g.size()&&(a=J.util.Measure.getCenterAndPoints(g)[0],
f=JU.V3.newVsub(b,a),f=J.util.Quaternion.newVA(f,180),this.moveAtoms(null,f.getMatrix(),null,e,b,!0))}},"JU.P3,JU.P4,~N,JU.BS,JU.BS");$_M(c$,"setDihedrals",function(a,b,c){var d=Clazz.doubleToInt(a.length/6);1<c&&(c=1);for(var e=0,f=0;e<d;e++,f+=6){var g=b[e];if(!(null==g||g.isEmpty())){var h=this.atoms[Clazz.floatToInt(a[f+1])],k=JU.V3.newVsub(this.atoms[Clazz.floatToInt(a[f+2])],h),k=JU.A4.newVA(k,-((a[f+5]-a[f+4])*c)/57.29577951308232);this.matTemp.setAA(k);this.ptTemp.setT(h);for(h=g.nextSetBit(0);0<=
h;h=g.nextSetBit(h+1))this.atoms[h].sub(this.ptTemp),this.matTemp.transform(this.atoms[h]),this.atoms[h].add(this.ptTemp),this.taintAtom(h,2)}}},"~A,~A,~N");$_M(c$,"moveAtoms",function(a,b,c,d,e,f){null==a?this.matTemp.setM(b):(this.matInv.setM(b),this.matInv.invert(),this.ptTemp.set(0,0,0),this.matTemp.mul2(a,b),this.matTemp.mul2(this.matInv,this.matTemp));f?(this.vTemp.setT(e),this.mat4.setIdentity(),this.mat4.setTranslation(this.vTemp),this.mat4t.setM3(this.matTemp),this.mat4.mulM4(this.mat4t),
this.mat4t.setIdentity(),this.vTemp.scale(-1),this.mat4t.setTranslation(this.vTemp),this.mat4.mulM4(this.mat4t)):this.mat4.setM3(this.matTemp);for(a=d.nextSetBit(0);0<=a;a=d.nextSetBit(a+1))f?this.mat4.transform(this.atoms[a]):(this.ptTemp.add(this.atoms[a]),this.mat4.transform(this.atoms[a]),this.ptTemp.sub(this.atoms[a])),this.taintAtom(a,2);f||(this.ptTemp.scale(1/d.cardinality()),null==c&&(c=new JU.V3),c.add(this.ptTemp));if(null!=c){for(a=d.nextSetBit(0);0<=a;a=d.nextSetBit(a+1))this.atoms[a].add(c);
this.mat4t.setIdentity();this.mat4t.setTranslation(c);this.mat4.mul2(this.mat4t,this.mat4)}this.recalculatePositionDependentQuantities(d,this.mat4)},"JU.M3,JU.M3,JU.V3,JU.BS,JU.P3,~B");$_M(c$,"recalculatePositionDependentQuantities",function(a,b){this.getHaveStraightness()&&this.calculateStraightness();this.recalculateLeadMidpointsAndWingVectors(-1);for(var c=this.getModelBitSet(a,!1),d=c.nextSetBit(0);0<=d;d=c.nextSetBit(d+1))this.shapeManager.refreshShapeTrajectories(d,a,b)},"JU.BS,JU.M4");$_M(c$,
"getBsBranches",function(a){for(var b=Clazz.doubleToInt(a.length/6),c=Array(b),d=new java.util.Hashtable,e=0,f=0;e<b;e++,f+=6)if(!(1>Math.abs(a[f+5]-a[f+4]))){var g=Clazz.floatToInt(a[f+1]),h=Clazz.floatToInt(a[f+2]),k=""+g+"_"+h;if(!d.containsKey(k)){d.put(k,Boolean.TRUE);for(var k=this.viewer.getBranchBitSet(h,g,!0),l=this.atoms[g].bonds,g=this.atoms[g],m=0;m<l.length;m++){var n=l[m];if(n.isCovalent()&&(n=n.getOtherAtom(g).index,n!=h&&k.get(n))){k=null;break}}c[e]=k}}return c},"~A")}),Clazz.declarePackage("J.api"),
Clazz.declareInterface(J.api,"PlatformViewer"),Clazz.declarePackage("J.api"),c$=Clazz.declareInterface(J.api,"ApiPlatform"),Clazz.defineStatics(c$,"CURSOR_DEFAULT",0,"CURSOR_CROSSHAIR",1,"CURSOR_WAIT",3,"CURSOR_ZOOM",8,"CURSOR_HAND",12,"CURSOR_MOVE",13),Clazz.declarePackage("J.awtjs2d"),Clazz.load(["J.api.ApiPlatform"],"J.awtjs2d.Platform","java.net.URL JU.AjaxURLStreamHandlerFactory J.api.Interface J.awtjs2d.Display $.Font $.Image $.JSFile $.Mouse".split(" "),function(){c$=Clazz.decorateAsClass(function(){this.context=
this.viewer=this.canvas=null;Clazz.instantialize(this,arguments)},J.awtjs2d,"Platform",null,J.api.ApiPlatform);Clazz.overrideMethod(c$,"setViewer",function(a,b){this.viewer=a;this.canvas=b;null!=b&&(this.context=b.getContext("2d"),b.imgdata=this.context.getImageData(0,0,b.width,b.height),b.buf8=b.imgdata.data);try{java.net.URL.setURLStreamHandlerFactory(new JU.AjaxURLStreamHandlerFactory)}catch(c){}},"J.api.PlatformViewer,~O");Clazz.overrideMethod(c$,"isSingleThreaded",function(){return!0});Clazz.overrideMethod(c$,
"getJsObjectInfo",function(a,b,c){return"localName"==b?a[0].nodeName:null==c?a[0][b]:a[0][b](c[0])},"~A,~S,~A");Clazz.overrideMethod(c$,"isHeadless",function(){return!1});Clazz.overrideMethod(c$,"getMouseManager",function(a,b){return new J.awtjs2d.Mouse(a,this.viewer,b)},"~N,~O");Clazz.overrideMethod(c$,"convertPointFromScreen",function(a,b){J.awtjs2d.Display.convertPointFromScreen(a,b)},"~O,JU.P3");Clazz.overrideMethod(c$,"getFullScreenDimensions",function(a,b){J.awtjs2d.Display.getFullScreenDimensions(a,
b)},"~O,~A");Clazz.overrideMethod(c$,"getMenuPopup",function(a,b){var c="j"==b?"awtjs2d.JSmolPopup":"awtjs2d.JSModelKitPopup",d=J.api.Interface.getOptionInterface(c);try{null!=d&&d.jpiInitialize(this.viewer,a)}catch(e){if(Clazz.exceptionOf(e,Exception))return System.out.println("Exception creating "+c+":"+e),null;throw e;}return d},"~S,~S");Clazz.overrideMethod(c$,"hasFocus",function(a){return J.awtjs2d.Display.hasFocus(a)},"~O");Clazz.overrideMethod(c$,"prompt",function(a,b,c,d){return J.awtjs2d.Display.prompt(a,
b,c,d)},"~S,~S,~A,~B");Clazz.overrideMethod(c$,"renderScreenImage",function(a,b){J.awtjs2d.Display.renderScreenImage(this.viewer,a,b)},"~O,~O");Clazz.overrideMethod(c$,"drawImage",function(a,b,c,d,e,f){J.awtjs2d.Image.drawImage(a,b,c,d,e,f)},"~O,~O,~N,~N,~N,~N");Clazz.overrideMethod(c$,"requestFocusInWindow",function(a){J.awtjs2d.Display.requestFocusInWindow(a)},"~O");Clazz.overrideMethod(c$,"repaint",function(a){J.awtjs2d.Display.repaint(a)},"~O");Clazz.overrideMethod(c$,"setTransparentCursor",function(a){J.awtjs2d.Display.setTransparentCursor(a)},
"~O");Clazz.overrideMethod(c$,"setCursor",function(a,b){J.awtjs2d.Display.setCursor(a,b)},"~N,~O");Clazz.overrideMethod(c$,"allocateRgbImage",function(a,b,c,d,e,f){return J.awtjs2d.Image.allocateRgbImage(a,b,c,d,e,f?null:this.canvas)},"~N,~N,~A,~N,~B,~B");Clazz.overrideMethod(c$,"notifyEndOfRendering",function(){});Clazz.overrideMethod(c$,"createImage",function(){return null},"~O");Clazz.overrideMethod(c$,"disposeGraphics",function(){},"~O");Clazz.overrideMethod(c$,"grabPixels",function(a,b,c){a.image&&
(b!=a.width||c!=a.height)&&Jmol._setCanvasImage(a,b,c);if(a.buf32)return a.buf32;b=J.awtjs2d.Image.grabPixels(J.awtjs2d.Image.getGraphics(a),b,c);return a.buf32=b},"~O,~N,~N,~A,~N,~N");Clazz.overrideMethod(c$,"drawImageToBuffer",function(a,b,c,d,e){return this.grabPixels(c,d,e,null,0,0)},"~O,~O,~O,~N,~N,~N");Clazz.overrideMethod(c$,"getTextPixels",function(a,b,c,d,e,f,g){return J.awtjs2d.Image.getTextPixels(a,b,c,e,f,g)},"~S,J.util.JmolFont,~O,~O,~N,~N,~N");Clazz.overrideMethod(c$,"flushImage",function(){},
"~O");Clazz.overrideMethod(c$,"getGraphics",function(a){return J.awtjs2d.Image.getGraphics(a)},"~O");Clazz.overrideMethod(c$,"getImageHeight",function(a){return null==a?-1:J.awtjs2d.Image.getHeight(a)},"~O");Clazz.overrideMethod(c$,"getImageWidth",function(a){return null==a?-1:J.awtjs2d.Image.getWidth(a)},"~O");Clazz.overrideMethod(c$,"getStaticGraphics",function(a,b){return J.awtjs2d.Image.getStaticGraphics(a,b)},"~O,~B");Clazz.overrideMethod(c$,"newBufferedImage",function(a,b,c){return"undefined"!=
typeof Jmol&&Jmol._getHiddenCanvas?Jmol._getHiddenCanvas(this.viewer.applet,"stereoImage",b,c):null},"~O,~N,~N");Clazz.overrideMethod(c$,"newOffScreenImage",function(a,b){return"undefined"!=typeof Jmol&&Jmol._getHiddenCanvas?Jmol._getHiddenCanvas(this.viewer.applet,"textImage",a,b):null},"~N,~N");Clazz.overrideMethod(c$,"waitForDisplay",function(a,b){if("undefined"==typeof Jmol||!Jmol._getHiddenCanvas)return!1;var c=this.viewer,d=c.getEvalContextAndHoldQueue(c.eval),e=a[0];return Jmol._loadImage(this,
a,b,function(a,b){c.loadImageData(a,b,e,d)})},"~O,~O");Clazz.overrideMethod(c$,"fontStringWidth",function(a,b,c){return J.awtjs2d.Font.stringWidth(a,b,c)},"J.util.JmolFont,~O,~S");Clazz.overrideMethod(c$,"getFontAscent",function(a){return J.awtjs2d.Font.getAscent(a)},"~O");Clazz.overrideMethod(c$,"getFontDescent",function(a){return J.awtjs2d.Font.getDescent(a)},"~O");Clazz.overrideMethod(c$,"getFontMetrics",function(a,b){return J.awtjs2d.Font.getFontMetrics(a,b)},"J.util.JmolFont,~O");Clazz.overrideMethod(c$,
"newFont",function(a,b,c,d){return J.awtjs2d.Font.newFont(a,b,c,d,"px")},"~S,~B,~B,~N");Clazz.overrideMethod(c$,"getDateFormat",function(){return(""+new Date).split(" (")[0]});Clazz.overrideMethod(c$,"newFile",function(a){return new J.awtjs2d.JSFile(a)},"~S");Clazz.overrideMethod(c$,"getBufferedFileInputStream",function(){return null},"~S");Clazz.overrideMethod(c$,"getBufferedURLInputStream",function(a,b,c){return J.awtjs2d.JSFile.getBufferedURLInputStream(a,b,c)},"java.net.URL,~A,~S")}),Clazz.declarePackage("J.awtjs2d"),
c$=Clazz.declareType(J.awtjs2d,"Display"),c$.getFullScreenDimensions=$_M(c$,"getFullScreenDimensions",function(a,b){b[0]=a.width;b[1]=a.height},"~O,~A"),c$.hasFocus=$_M(c$,"hasFocus",function(){return!0},"~O"),c$.requestFocusInWindow=$_M(c$,"requestFocusInWindow",function(){},"~O"),c$.repaint=$_M(c$,"repaint",function(){},"~O"),c$.renderScreenImage=$_M(c$,"renderScreenImage",function(){},"J.api.PlatformViewer,~O,~O"),c$.setTransparentCursor=$_M(c$,"setTransparentCursor",function(){},"~O"),c$.setCursor=
$_M(c$,"setCursor",function(){},"~N,~O"),c$.prompt=$_M(c$,"prompt",function(a,b){var c=prompt(a,b);return null!=c?c:"null"},"~S,~S,~A,~B"),c$.convertPointFromScreen=$_M(c$,"convertPointFromScreen",function(){},"~O,JU.P3"),Clazz.declarePackage("J.awtjs2d"),c$=Clazz.declareType(J.awtjs2d,"Font"),c$.newFont=$_M(c$,"newFont",function(a,b,c,d,e){a=a.equals("Monospaced")?"Courier":a.startsWith("Sans")?"Sans-Serif":"Serif";return(b?"bold ":"")+(c?"italic ":"")+d+e+" "+a},"~S,~B,~B,~N,~S"),c$.getFontMetrics=
$_M(c$,"getFontMetrics",function(a,b){b.font!=a.font&&(b.font=a.font,a.font=b.font,b._fontAscent=Math.ceil(a.fontSize),b._fontDescent=Math.ceil(0.25*a.fontSize));return b},"J.util.JmolFont,~O"),c$.getAscent=$_M(c$,"getAscent",function(a){return Math.ceil(a._fontAscent)},"~O"),c$.getDescent=$_M(c$,"getDescent",function(a){return Math.ceil(a._fontDescent)},"~O"),c$.stringWidth=$_M(c$,"stringWidth",function(a,b,c){b.font=a.font;return Math.ceil(b.measureText(c).width)},"J.util.JmolFont,~O,~S"),Clazz.declarePackage("J.awtjs2d"),
c$=Clazz.declareType(J.awtjs2d,"Image"),c$.getWidth=$_M(c$,"getWidth",function(a){return a.imageWidth?a.imageWidth:a.width},"~O"),c$.getHeight=$_M(c$,"getHeight",function(a){return a.imageHeight?a.imageHeight:a.height},"~O"),c$.grabPixels=$_M(c$,"grabPixels",function(a,b,c){if(a._buf32)return a._buf32;a=a.getImageData(0,0,b,c).data;return this.toIntARGB(a)},"~O,~N,~N"),c$.toIntARGB=$_M(c$,"toIntARGB",function(a){for(var b=Clazz.doubleToInt(a.length/4),c=Clazz.newIntArray(b,0),d=0,e=0;d<b;e++)c[d++]=
a[e++]<<16|a[e++]<<8|a[e++]|4278190080;return c},"~A"),c$.fromIntARGB=$_M(c$,"fromIntARGB",function(a,b){for(var c=b.length>>2,d=0,e=0;d<c;d++)b[e++]=a[d]>>16&255,b[e++]=a[d]>>8&255,b[e++]=a[d]&255,b[e++]=255},"~A,~A"),c$.getTextPixels=$_M(c$,"getTextPixels",function(a,b,c,d,e,f){c.fillStyle="#000000";c.fillRect(0,0,d,e);c.fillStyle="#FFFFFF";c.font=b.font;c.fillText(a,0,f);return this.grabPixels(c,d,e)},"~S,J.util.JmolFont,~O,~N,~N,~N"),c$.allocateRgbImage=$_M(c$,"allocateRgbImage",function(a,b,
c,d,e,f){null==f&&(f={width:a,height:b});f.buf32=c;return f},"~N,~N,~A,~N,~B,~O"),c$.getStaticGraphics=$_M(c$,"getStaticGraphics",function(a){return this.getGraphics(a)},"~O,~B"),c$.getGraphics=$_M(c$,"getGraphics",function(a){return a.getContext("2d")},"~O"),c$.drawImage=$_M(c$,"drawImage",function(a,b,c,d){this.fromIntARGB(b.buf32,b.buf8);a.putImageData(b.imgdata,c,d)},"~O,~O,~N,~N,~N,~N"),Clazz.declarePackage("J.api"),Clazz.declareInterface(J.api,"JmolFileInterface"),Clazz.declarePackage("J.awtjs2d"),
Clazz.load(["J.api.JmolFileInterface"],"J.awtjs2d.JSFile",["J.util.Txt","J.viewer.FileManager","$.Viewer"],function(){c$=Clazz.decorateAsClass(function(){this.fullName=this.name=null;Clazz.instantialize(this,arguments)},J.awtjs2d,"JSFile",null,J.api.JmolFileInterface);c$.newFile=$_M(c$,"newFile",function(a){return new J.awtjs2d.JSFile(a)},"~S");Clazz.makeConstructor(c$,function(a){this.name=a.$replace("\\","/");this.fullName=a;!this.fullName.startsWith("/")&&0>J.viewer.FileManager.urlTypeIndex(a)&&
(this.fullName=J.viewer.Viewer.jsDocumentBase+"/"+this.fullName);this.fullName=J.util.Txt.simpleReplace(this.fullName,"/./","/");a.substring(a.lastIndexOf("/")+1)},"~S");Clazz.overrideMethod(c$,"getParentAsFile",function(){var a=this.fullName.lastIndexOf("/");return 0>a?null:new J.awtjs2d.JSFile(this.fullName.substring(0,a))});Clazz.overrideMethod(c$,"getAbsolutePath",function(){return this.fullName});Clazz.overrideMethod(c$,"getName",function(){return this.name});Clazz.overrideMethod(c$,"isDirectory",
function(){return this.fullName.endsWith("/")});Clazz.overrideMethod(c$,"length",function(){return 0});c$.getBufferedURLInputStream=$_M(c$,"getBufferedURLInputStream",function(a,b,c){try{var d=a.openConnection();null!=b?d.outputBytes(b):null!=c&&d.outputString(c);return d.getSB()}catch(e){if(Clazz.exceptionOf(e,Exception))return e.toString();throw e;}},"java.net.URL,~A,~S")}),Clazz.declarePackage("J.api"),Clazz.declareInterface(J.api,"JmolMouseInterface"),Clazz.declarePackage("J.api"),c$=Clazz.declareType(J.api,
"Event"),Clazz.defineStatics(c$,"MOUSE_LEFT",16,"MOUSE_MIDDLE",8,"MOUSE_RIGHT",4,"MOUSE_WHEEL",32,"MAC_COMMAND",20,"BUTTON_MASK",28,"MOUSE_DOWN",501,"MOUSE_UP",502,"MOUSE_MOVE",503,"MOUSE_ENTER",504,"MOUSE_EXIT",505,"MOUSE_DRAG",506,"SHIFT_MASK",1,"ALT_MASK",8,"CTRL_MASK",2,"CTRL_ALT",10,"CTRL_SHIFT",3,"META_MASK",4,"VK_SHIFT",16,"VK_ALT",18,"VK_CONTROL",17,"VK_META",157,"VK_LEFT",37,"VK_RIGHT",39,"VK_PERIOD",46,"VK_SPACE",32,"VK_DOWN",40,"VK_UP",38,"VK_ESCAPE",27,"VK_DELETE",127,"VK_BACK_SPACE",
8,"VK_PAGE_DOWN",34,"VK_PAGE_UP",33,"MOVED",0,"DRAGGED",1,"CLICKED",2,"WHEELED",3,"PRESSED",4,"RELEASED",5),Clazz.declarePackage("J.awtjs2d"),Clazz.load(["J.api.JmolMouseInterface","$.Event"],"J.awtjs2d.Mouse",["java.lang.Character","JU.V3","J.util.Escape","$.Logger"],function(){c$=Clazz.decorateAsClass(function(){this.manager=this.viewer=null;this.keyBuffer="";this.isMouseDown=!1;this.modifiersWhenPressed10=this.yWhenPressed=this.xWhenPressed=0;Clazz.instantialize(this,arguments)},J.awtjs2d,"Mouse",
null,J.api.JmolMouseInterface);Clazz.makeConstructor(c$,function(a,b){this.viewer=b;this.manager=this.viewer.getActionManager()},"~N,J.api.PlatformViewer,~O");Clazz.overrideMethod(c$,"clear",function(){});Clazz.overrideMethod(c$,"dispose",function(){});Clazz.overrideMethod(c$,"handleOldJvm10Event",function(a,b,c,d,e){-1!=a&&(d=J.awtjs2d.Mouse.applyLeftMouse(d));switch(a){case -1:this.wheeled(e,b,d|32);break;case 501:this.xWhenPressed=b;this.yWhenPressed=c;this.modifiersWhenPressed10=d;this.pressed(e,
b,c,d,!1);break;case 506:this.dragged(e,b,c,d);break;case 504:this.entered(e,b,c);break;case 505:this.exited(e,b,c);break;case 503:this.moved(e,b,c,d);break;case 502:this.released(e,b,c,d);b==this.xWhenPressed&&(c==this.yWhenPressed&&d==this.modifiersWhenPressed10)&&this.clicked(e,b,c,d,1);break;default:return!1}return!0},"~N,~N,~N,~N,~N");Clazz.overrideMethod(c$,"processTwoPointGesture",function(a){if(!(2>a[0].length)){var b=a[0],c=a[1],d=b[0],e=b[c.length-1];a=d[0];var f=e[0],d=d[1],e=e[1],g=JU.V3.new3(f-
a,e-d,0),h=g.length(),k=c[0],l=c[c.length-1],c=k[0],m=l[0],k=k[1],l=l[1],n=JU.V3.new3(m-c,l-k,0),q=n.length();1>h||1>q||(g.normalize(),n.normalize(),g=g.dot(n),0.8<g?(a=Clazz.floatToInt(f-b[b.length-2][0]),b=Clazz.floatToInt(e-b[b.length-2][1]),this.viewer.translateXYBy(a,b)):-0.8>g&&(g=JU.V3.new3(c-a,k-d,0),n=JU.V3.new3(m-f,l-e,0),b=n.length()-g.length(),this.wheeled(System.currentTimeMillis(),0>b?-1:1,32)))}},"~A");$_M(c$,"mouseClicked",function(a){this.clicked(a.getWhen(),a.getX(),a.getY(),a.getModifiers(),
a.getClickCount())},"java.awt.event.MouseEvent");$_M(c$,"mouseEntered",function(a){this.entered(a.getWhen(),a.getX(),a.getY())},"java.awt.event.MouseEvent");$_M(c$,"mouseExited",function(a){this.exited(a.getWhen(),a.getX(),a.getY())},"java.awt.event.MouseEvent");$_M(c$,"mousePressed",function(a){this.pressed(a.getWhen(),a.getX(),a.getY(),a.getModifiers(),a.isPopupTrigger())},"java.awt.event.MouseEvent");$_M(c$,"mouseReleased",function(a){this.released(a.getWhen(),a.getX(),a.getY(),a.getModifiers())},
"java.awt.event.MouseEvent");$_M(c$,"mouseDragged",function(a){var b=a.getModifiers();0==(b&28)&&(b|=16);this.dragged(a.getWhen(),a.getX(),a.getY(),b)},"java.awt.event.MouseEvent");$_M(c$,"mouseMoved",function(a){this.moved(a.getWhen(),a.getX(),a.getY(),a.getModifiers())},"java.awt.event.MouseEvent");$_M(c$,"mouseWheelMoved",function(a){a.consume();this.wheeled(a.getWhen(),a.getWheelRotation(),a.getModifiers()|32)},"java.awt.event.MouseWheelEvent");$_M(c$,"keyTyped",function(a){a.consume();if(this.viewer.menuEnabled()){var b=
a.getKeyChar(),c=a.getModifiers();J.util.Logger.debuggingHigh&&J.util.Logger.debug("MouseManager keyTyped: "+b+" "+(0+b.charCodeAt(0))+" "+c);if(0!=c&&1!=c)switch(b){case String.fromCharCode(11):case "k":a=!this.viewer.getBooleanProperty("allowKeyStrokes");switch(c){case 2:this.viewer.setBooleanProperty("allowKeyStrokes",a);this.viewer.setBooleanProperty("showKeyStrokes",!0);break;case 10:case 1:this.viewer.setBooleanProperty("allowKeyStrokes",a),this.viewer.setBooleanProperty("showKeyStrokes",!1)}this.clearKeyBuffer();
this.viewer.refresh(3,"showkey");break;case 26:case "z":switch(c){case 2:this.viewer.undoMoveAction(4165,1);break;case 3:this.viewer.undoMoveAction(4139,1)}break;case 25:case "y":switch(c){case 2:this.viewer.undoMoveAction(4139,1)}}else this.viewer.getBooleanProperty("allowKeyStrokes")&&this.addKeyBuffer(1==a.getModifiers()?Character.toUpperCase(b):b)}},"java.awt.event.KeyEvent");$_M(c$,"keyPressed",function(a){this.viewer.isApplet()&&a.consume();this.manager.keyPressed(a.getKeyCode(),a.getModifiers())},
"java.awt.event.KeyEvent");$_M(c$,"keyReleased",function(a){a.consume();this.manager.keyReleased(a.getKeyCode())},"java.awt.event.KeyEvent");$_M(c$,"clearKeyBuffer",($fz=function(){0!=this.keyBuffer.length&&(this.keyBuffer="",this.viewer.getBooleanProperty("showKeyStrokes")&&this.viewer.evalStringQuietSync('!set echo _KEYSTROKES; set echo bottom left;echo ""',!0,!0))},$fz.isPrivate=!0,$fz));$_M(c$,"addKeyBuffer",($fz=function(a){10==a.charCodeAt(0)?this.sendKeyBuffer():(8==a.charCodeAt(0)?0<this.keyBuffer.length&&
(this.keyBuffer=this.keyBuffer.substring(0,this.keyBuffer.length-1)):this.keyBuffer+=a,this.viewer.getBooleanProperty("showKeyStrokes")&&this.viewer.evalStringQuietSync("!set echo _KEYSTROKES; set echo bottom left;echo "+J.util.Escape.eS("\u0001"+this.keyBuffer),!0,!0))},$fz.isPrivate=!0,$fz),"~S");$_M(c$,"sendKeyBuffer",($fz=function(){var a=this.keyBuffer;this.viewer.getBooleanProperty("showKeyStrokes")&&this.viewer.evalStringQuietSync("!set echo _KEYSTROKES; set echo bottom left;echo "+J.util.Escape.eS(this.keyBuffer),
!0,!0);this.clearKeyBuffer();this.viewer.evalStringQuietSync(a,!1,!0)},$fz.isPrivate=!0,$fz));$_M(c$,"entered",($fz=function(a,b,c){this.manager.mouseEnterExit(a,b,c,!1)},$fz.isPrivate=!0,$fz),"~N,~N,~N");$_M(c$,"exited",($fz=function(a,b,c){this.manager.mouseEnterExit(a,b,c,!0)},$fz.isPrivate=!0,$fz),"~N,~N,~N");$_M(c$,"clicked",($fz=function(a,b,c,d){this.clearKeyBuffer();this.manager.mouseAction(2,a,b,c,1,d)},$fz.isPrivate=!0,$fz),"~N,~N,~N,~N,~N");$_M(c$,"moved",($fz=function(a,b,c,d){this.clearKeyBuffer();
this.isMouseDown?this.manager.mouseAction(1,a,b,c,0,J.awtjs2d.Mouse.applyLeftMouse(d)):this.manager.mouseAction(0,a,b,c,0,d)},$fz.isPrivate=!0,$fz),"~N,~N,~N,~N");$_M(c$,"wheeled",($fz=function(a,b,c){this.clearKeyBuffer();this.manager.mouseAction(3,a,0,b,0,c)},$fz.isPrivate=!0,$fz),"~N,~N,~N");$_M(c$,"pressed",($fz=function(a,b,c,d){this.clearKeyBuffer();this.isMouseDown=!0;this.manager.mouseAction(4,a,b,c,0,d)},$fz.isPrivate=!0,$fz),"~N,~N,~N,~N,~B");$_M(c$,"released",($fz=function(a,b,c,d){this.isMouseDown=
!1;this.manager.mouseAction(5,a,b,c,0,d)},$fz.isPrivate=!0,$fz),"~N,~N,~N,~N");$_M(c$,"dragged",($fz=function(a,b,c,d){20==(d&20)&&(d=d&-5|2);this.manager.mouseAction(1,a,b,c,0,d)},$fz.isPrivate=!0,$fz),"~N,~N,~N,~N");c$.applyLeftMouse=$_M(c$,"applyLeftMouse",($fz=function(a){return 0==(a&28)?a|16:a},$fz.isPrivate=!0,$fz),"~N")}),Clazz.declarePackage("J.api"),Clazz.load(["J.api.JmolGraphicsInterface"],"J.api.JmolRendererInterface",null,function(){Clazz.declareInterface(J.api,"JmolRendererInterface",
J.api.JmolGraphicsInterface)}),Clazz.declarePackage("J.g3d"),Clazz.load(["J.api.JmolRendererInterface","J.util.GData","JU.V3","J.util.Normix"],"J.g3d.Graphics3D","java.lang.NullPointerException java.util.Arrays JU.ArrayUtil J.api.Interface J.constant.EnumStereoMode J.g3d.CylinderRenderer $.ImageRenderer $.LineRenderer $.Pixelator $.PixelatorShaded $.Platform3D $.SphereRenderer $.TextRenderer $.TextSorter $.TextString J.util.C $.JmolFont $.Shader".split(" "),function(){c$=Clazz.decorateAsClass(function(){this.hermite3d=
this.circle3d=this.triangle3d=this.cylinder3d=this.sphere3d=this.line3d=this.platform=null;this.antialias2=this.isFullSceneAntialiasingEnabled=!1;this.strings=null;this.stringCount=0;this.anaglyphChannelBytes=null;this.$haveTranslucentObjects=this.addAllPixels=this.twoPass=!1;this.zbufT=this.zbuf=this.pbufT=this.pbuf=null;this.translucencyMask=0;this.renderLow=!1;this.shadesCurrent=null;this.anaglyphLength=0;this.isScreened=!1;this.argbNoisyDn=this.argbNoisyUp=0;this.pixel=this.currentFont=null;this.saveDiffuse=
this.saveAmbient=this.translucencyLog=this.lastRawColor=this.currentShadeIndex=this.zMargin=0;this.$currentlyRendering=!1;this.shadeIndexes2Sided=this.shadeIndexes=this.transformedVectors=this.vectorNormal=this.vectorAC=this.vectorAB=null;Clazz.instantialize(this,arguments)},J.g3d,"Graphics3D",J.util.GData,J.api.JmolRendererInterface);Clazz.prepareFields(c$,function(){this.vectorAB=new JU.V3;this.vectorAC=new JU.V3;this.vectorNormal=new JU.V3;this.transformedVectors=Array(J.g3d.Graphics3D.normixCount);
for(var a=J.g3d.Graphics3D.normixCount;0<=--a;)this.transformedVectors[a]=new JU.V3;this.shadeIndexes=Clazz.newByteArray(J.g3d.Graphics3D.normixCount,0);this.shadeIndexes2Sided=Clazz.newByteArray(J.g3d.Graphics3D.normixCount,0)});Clazz.overrideMethod(c$,"clear",function(){this.stringCount=0;this.strings=null;J.g3d.TextRenderer.clearFontCache()});Clazz.overrideMethod(c$,"destroy",function(){this.releaseBuffers();this.graphicsForMetrics=this.platform=null});Clazz.overrideMethod(c$,"getGData",function(){return this});
$_M(c$,"setZMargin",function(a){this.zMargin=a},"~N");Clazz.makeConstructor(c$,function(){Clazz.superConstructor(this,J.g3d.Graphics3D,[])});Clazz.overrideMethod(c$,"initialize",function(a){this.apiPlatform=a;this.platform=new J.g3d.Platform3D(a);this.graphicsForMetrics=this.platform.getGraphicsForMetrics();this.line3d=new J.g3d.LineRenderer(this);this.sphere3d=new J.g3d.SphereRenderer(this);this.cylinder3d=new J.g3d.CylinderRenderer(this)},"J.api.ApiPlatform");Clazz.overrideMethod(c$,"addRenderer",
function(a){switch(a){case 1073741880:null==this.circle3d&&(this.circle3d=this.getRenderer("Circle"));break;case 553648147:null==this.hermite3d&&(this.hermite3d=this.getRenderer("Hermite"));case 1073742182:null==this.triangle3d&&(this.triangle3d=this.getRenderer("Triangle"))}},"~N");$_M(c$,"getRenderer",($fz=function(a){return J.api.Interface.getOptionInterface("g3d."+a+"Renderer").set(this)},$fz.isPrivate=!0,$fz),"~S");Clazz.overrideMethod(c$,"currentlyRendering",function(){return this.$currentlyRendering});
Clazz.overrideMethod(c$,"setWindowParameters",function(a,b,c){this.setWinParams(a,b,c);this.$currentlyRendering&&this.endRendering()},"~N,~N,~B");Clazz.overrideMethod(c$,"checkTranslucent",function(a){a&&(this.$haveTranslucentObjects=!0);return!this.twoPass||this.twoPass&&this.$isPass2==a},"~B");Clazz.overrideMethod(c$,"beginRendering",function(a,b,c,d){this.$currentlyRendering&&this.endRendering();this.renderLow=d;if(this.windowWidth!=this.newWindowWidth||this.windowHeight!=this.newWindowHeight||
this.newAntialiasing!=this.isFullSceneAntialiasingEnabled)this.windowWidth=this.newWindowWidth,this.windowHeight=this.newWindowHeight,this.isFullSceneAntialiasingEnabled=this.newAntialiasing,this.releaseBuffers();this.setRotationMatrix(a);this.antialiasEnabled=this.antialiasThisFrame=this.newAntialiasing;this.$currentlyRendering=!0;if(null!=this.strings)for(a=Math.min(this.strings.length,this.stringCount);0<=--a;)this.strings[a]=null;this.stringCount=0;this.twoPass=!0;this.$isPass2=!1;this.colixCurrent=
0;this.$haveTranslucentObjects=!1;this.translucentCoverOnly=!b;this.addAllPixels=!0;null==this.pbuf&&(this.platform.allocateBuffers(this.windowWidth,this.windowHeight,this.antialiasThisFrame,c),this.pbuf=this.platform.pBuffer,this.zbuf=this.platform.zBuffer);this.setWidthHeight(this.antialiasThisFrame);this.platform.clearBuffer();null!=this.backgroundImage&&this.plotImage(-2147483648,0,-2147483648,this.backgroundImage,null,0,0,0)},"JU.M3,~B,~B,~B");Clazz.overrideMethod(c$,"setBackgroundTransparent",
function(a){null!=this.platform&&this.platform.setBackgroundTransparent(a)},"~B");$_M(c$,"releaseBuffers",($fz=function(){this.zbufT=this.pbufT=this.zbuf=this.pbuf=null;this.platform.releaseBuffers();this.line3d.clearLineCache()},$fz.isPrivate=!0,$fz));Clazz.overrideMethod(c$,"setPass2",function(a){if(!this.$haveTranslucentObjects||!this.$currentlyRendering)return!1;this.$isPass2=!0;this.colixCurrent=0;this.addAllPixels=!0;if(null==this.pbufT||this.antialias2!=a)this.platform.allocateTBuffers(a),
this.pbufT=this.platform.pBufferT,this.zbufT=this.platform.zBufferT;this.antialias2=a;this.antialiasThisFrame&&!this.antialias2&&this.downsampleFullSceneAntialiasing(!0);this.platform.clearTBuffer();return!0},"~B");Clazz.overrideMethod(c$,"endRendering",function(){this.$currentlyRendering&&(null!=this.pbuf&&(this.$isPass2&&this.mergeOpaqueAndTranslucentBuffers(),this.antialiasThisFrame&&this.downsampleFullSceneAntialiasing(!1)),this.platform.setBackgroundColor(this.bgcolor),this.platform.notifyEndOfRendering(),
this.$currentlyRendering=!1)});Clazz.overrideMethod(c$,"getScreenImage",function(a){var b=this.platform.bufferedImage;a&&this.releaseBuffers();return b},"~B");Clazz.overrideMethod(c$,"applyAnaglygh",function(a,b){switch(a){case J.constant.EnumStereoMode.REDCYAN:this.applyCyanAnaglyph();break;case J.constant.EnumStereoMode.CUSTOM:this.applyCustomAnaglyph(b);break;case J.constant.EnumStereoMode.REDBLUE:this.applyBlueAnaglyph();break;case J.constant.EnumStereoMode.REDGREEN:this.applyGreenAnaglyph()}},
"J.constant.EnumStereoMode,~A");Clazz.overrideMethod(c$,"snapshotAnaglyphChannelBytes",function(){if(this.$currentlyRendering)throw new NullPointerException;this.anaglyphLength=this.windowWidth*this.windowHeight;if(null==this.anaglyphChannelBytes||this.anaglyphChannelBytes.length!=this.anaglyphLength)this.anaglyphChannelBytes=Clazz.newByteArray(this.anaglyphLength,0);for(var a=this.anaglyphLength;0<=--a;)this.anaglyphChannelBytes[a]=this.pbuf[a]});$_M(c$,"applyCustomAnaglyph",function(a){var b=a[0];
a=a[1]&16777215;for(var c=this.anaglyphLength;0<=--c;){var d=this.anaglyphChannelBytes[c]&255,d=(d|(d|d<<8)<<8)&a;this.pbuf[c]=this.pbuf[c]&b|d}},"~A");$_M(c$,"applyGreenAnaglyph",function(){for(var a=this.anaglyphLength;0<=--a;)this.pbuf[a]=this.pbuf[a]&4294901760|(this.anaglyphChannelBytes[a]&255)<<8});$_M(c$,"applyBlueAnaglyph",function(){for(var a=this.anaglyphLength;0<=--a;)this.pbuf[a]=this.pbuf[a]&4294901760|this.anaglyphChannelBytes[a]&255});$_M(c$,"applyCyanAnaglyph",function(){for(var a=
this.anaglyphLength;0<=--a;){var b=this.anaglyphChannelBytes[a]&255;this.pbuf[a]=this.pbuf[a]&4294901760|b<<8|b}});Clazz.overrideMethod(c$,"releaseScreenImage",function(){this.platform.clearScreenBufferThreaded()});Clazz.overrideMethod(c$,"haveTranslucentObjects",function(){return this.$haveTranslucentObjects});$_M(c$,"setTempZSlab",function(a){this.zSlab=a},"~N");Clazz.overrideMethod(c$,"setZShade",function(a,b,c,d){a?(this.setZShade2(b,c,d),this.pixel=new J.g3d.PixelatorShaded(this)):this.pixel=
new J.g3d.Pixelator(this)},"~B,~N,~N,~N");$_M(c$,"downsampleFullSceneAntialiasing",($fz=function(a){var b=this.width,c=0,d=0,e=this.bgcolor;a&&(e+=255==(e&255)?-1:1);for(var f=0;f<this.pbuf.length;f++)0==this.pbuf[f]&&(this.pbuf[f]=e);e&=16777215;for(f=this.windowHeight;0<=--f;d+=b)for(var g=this.windowWidth;0<=--g;++c){var h=(this.pbuf[d]>>2&1061109567)+(this.pbuf[d++ +b]>>2&1061109567)+(this.pbuf[d]>>2&1061109567)+(this.pbuf[d++ +b]>>2&1061109567),h=h+((h&3233857728)>>6);this.pbuf[c]=h&16777215|
4278190080}if(a){c=d=0;for(f=this.windowHeight;0<=--f;d+=b)for(g=this.windowWidth;0<=--g;++c,++d)a=Math.min(this.zbuf[d],this.zbuf[d+b]),a=Math.min(a,this.zbuf[++d]),a=Math.min(a,this.zbuf[d+b]),2147483647!=a&&(a>>=1),this.zbuf[c]=this.pbuf[c]==e?2147483647:a;this.antialiasThisFrame=!1;this.setWidthHeight(!1)}},$fz.isPrivate=!0,$fz),"~B");$_M(c$,"mergeOpaqueAndTranslucentBuffers",function(){if(null!=this.pbufT)for(var a=0;a<this.bufferSize;a++)J.g3d.Graphics3D.mergeBufferPixel(this.pbuf,a,this.pbufT[a],
this.bgcolor)});c$.mergeBufferPixel=$_M(c$,"mergeBufferPixel",function(a,b,c,d){if(0!=c){var e=a[b];if(e!=c){0==e&&(e=d);d=e&16711935;var e=e&65280,f=c&16711935,g=c&65280;switch(c>>24&15){case 0:d=f;e=g;break;case 1:d=(f<<2)+(f<<1)+f+d>>3&16711935;e=(g<<2)+ +(g<<1)+g+e>>3&65280;break;case 2:d=(f<<1)+f+d>>2&16711935;e=(g<<1)+g+e>>2&65280;break;case 3:d=(f<<2)+f+(d<<1)+d>>3&16711935;e=(g<<2)+g+(e<<1)+e>>3&65280;break;case 4:d=d+f>>1&16711935;e=e+g>>1&65280;break;case 5:d=(f<<1)+f+(d<<2)+d>>3&16711935;
e=(g<<1)+g+(e<<2)+e>>3&65280;break;case 6:d=(d<<1)+d+f>>2&16711935;e=(e<<1)+e+g>>2&65280;break;case 7:d=(d<<2)+(d<<1)+d+f>>3&16711935,e=(e<<2)+(e<<1)+e+g>>3&65280}a[b]=4278190080|d|e}}},"~A,~N,~N,~N");$_M(c$,"hasContent",function(){return this.platform.hasContent()});Clazz.overrideMethod(c$,"setColor",function(a){this.argbCurrent=this.argbNoisyUp=this.argbNoisyDn=a},"~N");Clazz.overrideMethod(c$,"setColix",function(a){var b=J.util.C.isColixLastAvailable(a);if(!b&&a==this.colixCurrent&&-1==this.currentShadeIndex)return!0;
var c=a&30720;if(16384==c)return!1;this.renderLow&&(c=0);var d=0!=c;this.isScreened=d&&30720==c;if(!this.checkTranslucent(d&&!this.isScreened))return!1;this.addAllPixels=this.$isPass2||!d;this.$isPass2?(this.translucencyMask=c<<13|16777215,this.translucencyLog=c>>11):this.translucencyLog=0;this.colixCurrent=a;b&&this.argbCurrent!=this.lastRawColor&&(0==this.argbCurrent&&(this.argbCurrent=4294967295),this.lastRawColor=this.argbCurrent,this.shader.setLastColix(this.argbCurrent,this.inGreyscaleMode));
this.shadesCurrent=this.getShades(a);this.currentShadeIndex=-1;this.setColor(this.getColorArgbOrGray(a));return!0},"~N");$_M(c$,"addPixel",function(a,b,c){this.pixel.addPixel(a,b,c)},"~N,~N,~N");$_M(c$,"clearPixel",function(a,b){this.pixel.clearPixel(a,b)},"~N,~N");Clazz.overrideMethod(c$,"drawFilledCircle",function(a,b,c,d,e,f){if(!this.isClippedZ(f)){var g=Clazz.doubleToInt((c+1)/2),g=d<g||d+g>=this.width||e<g||e+g>=this.height;if(!g||!this.isClippedXY(c,d,e))0!=a&&this.setColix(a)&&(g?this.circle3d.plotCircleCenteredClipped(d,
e,f,c):this.circle3d.plotCircleCenteredUnclipped(d,e,f,c)),0!=b&&this.setColix(b)&&(g?this.circle3d.plotFilledCircleCenteredClipped(d,e,f,c):this.circle3d.plotFilledCircleCenteredUnclipped(d,e,f,c))}},"~N,~N,~N,~N,~N,~N");Clazz.overrideMethod(c$,"volumeRender4",function(a,b,c,d){if(1==a)this.plotPixelClippedXYZ(b,c,d);else if(!this.isClippedZ(d)){var e=Clazz.doubleToInt((a+1)/2),e=b<e||b+e>=this.width||c<e||c+e>=this.height;if(!e||!this.isClippedXY(a,b,c))e?this.circle3d.plotFilledCircleCenteredClipped(b,
c,d,a):this.circle3d.plotFilledCircleCenteredUnclipped(b,c,d,a)}},"~N,~N,~N,~N");Clazz.overrideMethod(c$,"fillSphereXYZ",function(a,b,c,d){switch(a){case 1:this.plotPixelClippedArgb(this.argbCurrent,b,c,d);return;case 0:return}a<=(this.antialiasThisFrame?2E3:1E3)&&this.sphere3d.render(this.shadesCurrent,!this.addAllPixels,a,b,c,d,null,null,null,-1,null,this.addAllPixels)},"~N,~N,~N,~N");Clazz.overrideMethod(c$,"volumeRender",function(a){a?(this.saveAmbient=this.shader.ambientPercent,this.saveDiffuse=
this.shader.diffusePercent,this.setAmbientPercent(100),this.setDiffusePercent(0)):(this.setAmbientPercent(this.saveAmbient),this.setDiffusePercent(this.saveDiffuse))},"~B");Clazz.overrideMethod(c$,"fillSphereI",function(a,b){this.fillSphereXYZ(a,b.x,b.y,b.z)},"~N,JU.P3i");Clazz.overrideMethod(c$,"fillSphere",function(a,b){this.fillSphereXYZ(a,Math.round(b.x),Math.round(b.y),Math.round(b.z))},"~N,JU.P3");Clazz.overrideMethod(c$,"fillEllipsoid",function(a,b,c,d,e,f,g,h,k,l,m){switch(f){case 1:this.plotPixelClippedArgb(this.argbCurrent,
c,d,e);return;case 0:return}f<=(this.antialiasThisFrame?2E3:1E3)&&this.sphere3d.render(this.shadesCurrent,!this.addAllPixels,f,c,d,e,g,h,k,l,m,this.addAllPixels)},"JU.P3,~A,~N,~N,~N,~N,JU.M3,~A,JU.M4,~N,~A");Clazz.overrideMethod(c$,"drawRect",function(a,b,c,d,e,f){if(!(0!=d&&this.isClippedZ(d))){d=e-1;f-=1;e=a+d;var g=b+f;0<=b&&b<this.height&&this.drawHLine(a,b,c,d);0<=g&&g<this.height&&this.drawHLine(a,g,c,d);0<=a&&a<this.width&&this.drawVLine(a,b,c,f);0<=e&&e<this.width&&this.drawVLine(e,b,c,f)}},
"~N,~N,~N,~N,~N,~N");$_M(c$,"drawHLine",($fz=function(a,b,c,d){0>d&&(a+=d,d=-d);0>a&&(d+=a,a=0);a+d>=this.width&&(d=this.width-1-a);var e=a+this.width*b;if(this.addAllPixels)for(a=0;a<=d;a++)c<this.zbuf[e]&&this.addPixel(e,c,this.argbCurrent),e++;else{b=0!=((a^b)&1);for(a=0;a<=d;a++)(b=!b)&&c<this.zbuf[e]&&this.addPixel(e,c,this.argbCurrent),e++}},$fz.isPrivate=!0,$fz),"~N,~N,~N,~N");$_M(c$,"drawVLine",($fz=function(a,b,c,d){0>d&&(b+=d,d=-d);0>b&&(d+=b,b=0);b+d>=this.height&&(d=this.height-1-b);var e=
a+this.width*b;if(this.addAllPixels)for(a=0;a<=d;a++)c<this.zbuf[e]&&this.addPixel(e,c,this.argbCurrent),e+=this.width;else{b=0!=((a^b)&1);for(a=0;a<=d;a++)(b=!b)&&c<this.zbuf[e]&&this.addPixel(e,c,this.argbCurrent),e+=this.width}},$fz.isPrivate=!0,$fz),"~N,~N,~N,~N");Clazz.overrideMethod(c$,"fillRect",function(a,b,c,d,e,f){if(!this.isClippedZ(d)){if(0>a){e+=a;if(0>=e)return;a=0}if(a+e>this.width&&(e=this.width-a,0>=e))return;if(0>b){f+=b;if(0>=f)return;b=0}for(b+f>this.height&&(f=this.height-b);0<=
--f;)this.plotPixelsUnclippedCount(e,a,b++,c)}},"~N,~N,~N,~N,~N,~N");Clazz.overrideMethod(c$,"drawString",function(a,b,c,d,e,f,g){this.currentShadeIndex=0;null!=a&&(this.isClippedZ(f)||this.drawStringNoSlab(a,b,c,d,e,g))},"~S,J.util.JmolFont,~N,~N,~N,~N,~N");Clazz.overrideMethod(c$,"drawStringNoSlab",function(a,b,c,d,e,f){if(null!=a){null==this.strings&&(this.strings=Array(10));this.stringCount==this.strings.length&&(this.strings=JU.ArrayUtil.doubleLength(this.strings));var g=new J.g3d.TextString;
g.setText(a,null==b?this.currentFont:this.currentFont=b,this.argbCurrent,J.util.C.isColixTranslucent(f)?this.getColorArgbOrGray(f)&16777215|(f&30720)<<13:0,c,d,e);this.strings[this.stringCount++]=g}},"~S,J.util.JmolFont,~N,~N,~N,~N");Clazz.overrideMethod(c$,"renderAllStrings",function(a){if(null!=this.strings){2<=this.stringCount&&(null==J.g3d.Graphics3D.sort&&($t$=J.g3d.Graphics3D.sort=new J.g3d.TextSorter,J.g3d.Graphics3D.prototype.sort=J.g3d.Graphics3D.sort,$t$),java.util.Arrays.sort(this.strings,
J.g3d.Graphics3D.sort));for(var b=0;b<this.stringCount;b++){var c=this.strings[b];this.plotText(c.x,c.y,c.z,c.argb,c.bgargb,c.text,c.font,a)}this.strings=null;this.stringCount=0}},"~O");Clazz.overrideMethod(c$,"plotText",function(a,b,c,d,e,f,g,h){J.g3d.TextRenderer.plot(a,b,c,d,e,f,g,this,h,this.antialiasThisFrame)},"~N,~N,~N,~N,~N,~S,J.util.JmolFont,J.api.JmolRendererInterface");Clazz.overrideMethod(c$,"drawImage",function(a,b,c,d,e,f,g,h){null==a||(0==g||0==h||this.isClippedZ(e))||this.plotImage(b,
c,d,a,null,f,g,h)},"~O,~N,~N,~N,~N,~N,~N,~N");$_M(c$,"plotImage",function(a,b,c,d,e,f,g,h){this.setColix(f);this.$isPass2||(this.translucencyMask=-1);0==f&&(this.argbCurrent=0);J.g3d.ImageRenderer.plotImage(a,b,c,d,this,e,this.antialiasThisFrame,this.argbCurrent,g,h)},"~N,~N,~N,~O,J.api.JmolRendererInterface,~N,~N,~N");Clazz.overrideMethod(c$,"setFontFid",function(a){this.currentFont=J.util.JmolFont.getFont3D(a)},"~N");Clazz.overrideMethod(c$,"setFont",function(a){this.currentFont=a},"J.util.JmolFont");
Clazz.overrideMethod(c$,"getFont3DCurrent",function(){return this.currentFont});Clazz.overrideMethod(c$,"drawPixel",function(a,b,c){this.plotPixelClippedXYZ(a,b,c)},"~N,~N,~N");Clazz.overrideMethod(c$,"drawPoints",function(a,b,c){if(1<c)for(var d=0.8*c*c,e=-c;e<c;e++)for(var f=-c;f<c;f++)e*e+f*f>d||(this.plotPoints(a,b,e,f),this.plotPoints(a,b,e,f));else this.plotPoints(a,b,0,0)},"~N,~A,~N");Clazz.overrideMethod(c$,"drawDashedLine",function(a,b,c,d){this.line3d.plotDashedLine(this.argbCurrent,!this.addAllPixels,
a,b,c.x,c.y,c.z,d.x,d.y,d.z,!0)},"~N,~N,JU.P3i,JU.P3i");Clazz.overrideMethod(c$,"drawDottedLine",function(a,b){this.line3d.plotDashedLine(this.argbCurrent,!this.addAllPixels,2,1,a.x,a.y,a.z,b.x,b.y,b.z,!0)},"JU.P3i,JU.P3i");Clazz.overrideMethod(c$,"drawLineXYZ",function(a,b,c,d,e,f){this.line3d.plotLine(this.argbCurrent,!this.addAllPixels,this.argbCurrent,!this.addAllPixels,a,b,c,d,e,f,!0)},"~N,~N,~N,~N,~N,~N");Clazz.overrideMethod(c$,"drawLine",function(a,b,c,d,e,f,g,h){this.setColix(a)||(a=0);var k=
!this.addAllPixels,l=this.argbCurrent;this.setColix(b)||(b=0);0==a&&0==b||this.line3d.plotLine(l,k,this.argbCurrent,!this.addAllPixels,c,d,e,f,g,h,!0)},"~N,~N,~N,~N,~N,~N,~N,~N");Clazz.overrideMethod(c$,"drawLineAB",function(a,b){this.line3d.plotLine(this.argbCurrent,!this.addAllPixels,this.argbCurrent,!this.addAllPixels,a.x,a.y,a.z,b.x,b.y,b.z,!0)},"JU.P3i,JU.P3i");Clazz.overrideMethod(c$,"fillCylinderXYZ",function(a,b,c,d,e,f,g,h,k,l){this.setColix(a)||(a=0);var m=!this.addAllPixels;this.setColix(b)||
(b=0);0==a&&0==b||this.cylinder3d.render(a,b,m,!this.addAllPixels,c,d,e,f,g,h,k,l)},"~N,~N,~N,~N,~N,~N,~N,~N,~N,~N");Clazz.overrideMethod(c$,"fillCylinderScreen",function(a,b,c,d,e,f,g,h){this.cylinder3d.render(this.colixCurrent,this.colixCurrent,!this.addAllPixels,!this.addAllPixels,a,b,c,d,e,f,g,h)},"~N,~N,~N,~N,~N,~N,~N,~N");Clazz.overrideMethod(c$,"fillCylinderScreen3I",function(a,b,c,d){this.cylinder3d.render(this.colixCurrent,this.colixCurrent,!this.addAllPixels,!this.addAllPixels,a,b,c.x,c.y,
c.z,d.x,d.y,d.z)},"~N,~N,JU.P3i,JU.P3i,JU.P3,JU.P3,~N");Clazz.overrideMethod(c$,"fillCylinder",function(a,b,c,d){this.cylinder3d.render(this.colixCurrent,this.colixCurrent,!this.addAllPixels,!this.addAllPixels,a,b,c.x,c.y,c.z,d.x,d.y,d.z)},"~N,~N,JU.P3i,JU.P3i");Clazz.overrideMethod(c$,"fillCylinderBits",function(a,b,c,d){this.cylinder3d.renderBits(this.colixCurrent,this.colixCurrent,!this.addAllPixels,!this.addAllPixels,a,b,c.x,c.y,c.z,d.x,d.y,d.z)},"~N,~N,JU.P3,JU.P3");Clazz.overrideMethod(c$,"fillConeScreen",
function(a,b,c,d,e){this.cylinder3d.renderCone(this.colixCurrent,!this.addAllPixels,a,b,c.x,c.y,c.z,d.x,d.y,d.z,!1,e)},"~N,~N,JU.P3i,JU.P3i,~B");Clazz.overrideMethod(c$,"fillConeSceen3f",function(a,b,c,d){this.cylinder3d.renderCone(this.colixCurrent,!this.addAllPixels,a,b,c.x,c.y,c.z,d.x,d.y,d.z,!0,!1)},"~N,~N,JU.P3,JU.P3");Clazz.overrideMethod(c$,"drawHermite4",function(a,b,c,d,e){this.hermite3d.renderHermiteRope(!1,a,0,0,0,b,c,d,e)},"~N,JU.P3i,JU.P3i,JU.P3i,JU.P3i");Clazz.overrideMethod(c$,"drawHermite7",
function(a,b,c,d,e,f,g,h,k,l,m,n,q){if(0==q)this.hermite3d.renderHermiteRibbon(a,b,c,d,e,f,g,h,k,l,m,n,0);else{this.hermite3d.renderHermiteRibbon(a,b,c,d,e,f,g,h,k,l,m,n,1);var p=this.colixCurrent;this.setColix(q);this.hermite3d.renderHermiteRibbon(a,b,c,d,e,f,g,h,k,l,m,n,-1);this.setColix(p)}},"~B,~B,~N,JU.P3i,JU.P3i,JU.P3i,JU.P3i,JU.P3i,JU.P3i,JU.P3i,JU.P3i,~N,~N");Clazz.overrideMethod(c$,"fillHermite",function(a,b,c,d,e,f,g,h){this.hermite3d.renderHermiteRope(!0,a,b,c,d,e,f,g,h)},"~N,~N,~N,~N,JU.P3i,JU.P3i,JU.P3i,JU.P3i");
Clazz.overrideMethod(c$,"drawTriangle3C",function(a,b,c,d,e,f,g){1==(g&1)&&this.drawLine(b,d,a.x,a.y,a.z,c.x,c.y,c.z);2==(g&2)&&this.drawLine(d,f,c.x,c.y,c.z,e.x,e.y,e.z);4==(g&4)&&this.drawLine(b,f,a.x,a.y,a.z,e.x,e.y,e.z)},"JU.P3i,~N,JU.P3i,~N,JU.P3i,~N,~N");Clazz.overrideMethod(c$,"drawTriangle3I",function(a,b,c,d){1==(d&1)&&this.line3d.plotLine(this.argbCurrent,!this.addAllPixels,this.argbCurrent,!this.addAllPixels,a.x,a.y,a.z,b.x,b.y,b.z,!0);2==(d&2)&&this.line3d.plotLine(this.argbCurrent,!this.addAllPixels,
this.argbCurrent,!this.addAllPixels,b.x,b.y,b.z,c.x,c.y,c.z,!0);4==(d&4)&&this.line3d.plotLine(this.argbCurrent,!this.addAllPixels,this.argbCurrent,!this.addAllPixels,a.x,a.y,a.z,c.x,c.y,c.z,!0)},"JU.P3i,JU.P3i,JU.P3i,~N");Clazz.overrideMethod(c$,"fillTriangleTwoSided",function(a,b,c,d,e,f,g,h,k,l){this.setColorNoisy(this.getShadeIndex(a));this.triangle3d.fillTriangleXYZ(b,c,d,e,f,g,h,k,l,!1)},"~N,~N,~N,~N,~N,~N,~N,~N,~N,~N");Clazz.overrideMethod(c$,"fillTriangle3f",function(a,b,c,d){var e=this.getShadeIndexP3(a,
b,c);d?this.setColorNoisy(e):this.setColor(this.shadesCurrent[e]);this.triangle3d.fillTriangleP3f(a,b,c,!1)},"JU.P3,JU.P3,JU.P3,~B");Clazz.overrideMethod(c$,"fillTriangle3i",function(a,b,c){this.triangle3d.fillTriangleP3i(a,b,c,!1)},"JU.P3i,JU.P3i,JU.P3i,JU.P3,JU.P3,JU.P3");Clazz.overrideMethod(c$,"fillTriangle",function(a,b,c,d,e,f,g,h,k,l){if(!this.$isPass2&&c==f&&c==k&&b==e&&b==h)this.setTriangleColixAndShadeIndex(b,this.getShadeIndex(c)),b=!1;else{if(!this.setTriangleTranslucency(b,e,h))return;
this.triangle3d.setGouraud(this.getShades(b)[this.getShadeIndex(c)],this.getShades(e)[this.getShadeIndex(f)],this.getShades(h)[this.getShadeIndex(k)]);b=!0}this.triangle3d.fillTriangleP3if(a,d,g,l,b)},"JU.P3i,~N,~N,JU.P3i,~N,~N,JU.P3i,~N,~N,~N");Clazz.overrideMethod(c$,"fillTriangle3CN",function(a,b,c,d,e,f,g,h,k){if(!this.$isPass2&&c==f&&c==k&&b==e&&b==h)this.setTriangleColixAndShadeIndex(b,this.getShadeIndex(c)),b=!1;else{if(!this.setTriangleTranslucency(b,e,h))return;this.triangle3d.setGouraud(this.getShades(b)[this.getShadeIndex(c)],
this.getShades(e)[this.getShadeIndex(f)],this.getShades(h)[this.getShadeIndex(k)]);b=!0}this.triangle3d.fillTriangleP3i(a,d,g,b)},"JU.P3i,~N,~N,JU.P3i,~N,~N,JU.P3i,~N,~N");$_M(c$,"setTriangleColixAndShadeIndex",($fz=function(a,b){a==this.colixCurrent&&this.currentShadeIndex==b||(this.currentShadeIndex=-1,this.setColix(a),this.setColorNoisy(b))},$fz.isPrivate=!0,$fz),"~N,~N");$_M(c$,"setTriangleTranslucency",($fz=function(a,b,c){if(!this.$isPass2)return!0;a&=14336;b&=14336;c&=14336;this.translucencyMask=
(J.util.GData.roundInt(Clazz.doubleToInt((a+b+c)/3))&30720)<<13|16777215;return!0},$fz.isPrivate=!0,$fz),"~N,~N,~N");Clazz.overrideMethod(c$,"drawQuadrilateral",function(a,b,c,d,e){this.setColix(a);this.drawLineAB(b,c);this.drawLineAB(c,d);this.drawLineAB(d,e);this.drawLineAB(e,b)},"~N,JU.P3i,JU.P3i,JU.P3i,JU.P3i");Clazz.overrideMethod(c$,"fillQuadrilateral",function(a,b,c,d){this.setColorNoisy(this.getShadeIndexP3(a,b,c));this.triangle3d.fillTriangleP3f(a,b,c,!1);this.triangle3d.fillTriangleP3f(a,
c,d,!1)},"JU.P3,JU.P3,JU.P3,JU.P3");Clazz.overrideMethod(c$,"fillQuadrilateral3i",function(a,b,c,d,e,f,g,h,k,l,m,n){this.fillTriangle3CN(a,b,c,d,e,f,g,h,k);this.fillTriangle3CN(a,b,c,g,h,k,l,m,n)},"JU.P3i,~N,~N,JU.P3i,~N,~N,JU.P3i,~N,~N,JU.P3i,~N,~N");Clazz.overrideMethod(c$,"drawSurface",function(){},"J.util.MeshSurface,~N");$_M(c$,"plotPixelClippedXYZ",function(a,b,c){this.isClipped3(a,b,c)||(a=b*this.width+a,c<this.zbuf[a]&&this.addPixel(a,c,this.argbCurrent))},"~N,~N,~N");Clazz.overrideMethod(c$,
"plotPixelClippedP3i",function(a){this.plotPixelClippedXYZ(a.x,a.y,a.z)},"JU.P3i");$_M(c$,"plotPixelClippedArgb",function(a,b,c,d){this.isClipped3(b,c,d)||(b=c*this.width+b,d<this.zbuf[b]&&this.addPixel(b,d,a))},"~N,~N,~N,~N");Clazz.overrideMethod(c$,"plotImagePixel",function(a,b,c,d,e,f){this.isClipped(b,c)||(b=c*this.width+b,d<this.zbuf[b]&&this.shadeTextPixel(b,d,a,f,e))},"~N,~N,~N,~N,~N,~N");$_M(c$,"plotPixelClippedScreened",function(a,b,c,d,e){!this.isClipped3(c,d,e)&&!(b&&0!=((c^d)&1))&&(b=
d*this.width+c,e<this.zbuf[b]&&this.addPixel(b,e,a))},"~N,~B,~N,~N,~N");$_M(c$,"plotPixelUnclipped",function(a,b,c){a=b*this.width+a;c<this.zbuf[a]&&this.addPixel(a,c,this.argbCurrent)},"~N,~N,~N");$_M(c$,"plotPixelUnclippedArgb",function(a,b,c,d){b=c*this.width+b;d<this.zbuf[b]&&this.addPixel(b,d,a)},"~N,~N,~N,~N");$_M(c$,"plotPixelsClipped",function(a,b,c,d){if(!(0>c||c>=this.height||b>=this.width))if(0>b&&(a+=b,b=0),a+b>this.width&&(a=this.width-b),!(0>=a)){var e=c*this.width+b;a=e+a;var f=1;this.addAllPixels||
(f=2,0!=((b^c)&1)&&++e);for(;e<a;)d<this.zbuf[e]&&this.addPixel(e,d,this.argbCurrent),e+=f}},"~N,~N,~N,~N");$_M(c$,"plotPixelsClippedRaster",function(a,b,c,d,e,f,g){if(!(0>=a||0>c||c>=this.height||b>=this.width||d<this.slab&&e<this.slab||d>this.depth&&e>this.depth)){var h=(b<<16)+(c<<1)^858993459,k=(d<<10)+512;d=e-d;e=Clazz.doubleToInt(a/2);d=J.util.GData.roundInt(Clazz.doubleToInt(((d<<10)+(0<=d?e:-e))/a));if(0>b){b=-b;k+=d*b;a-=b;if(0>=a)return;b=0}a+b>this.width&&(a=this.width-b);e=0!=((b^c)&1);
b=c*this.width+b;if(null==f)for(;0<=--a;){if(this.addAllPixels||!0==(e=!e))g=k>>10,g>=this.slab&&(g<=this.depth&&g<this.zbuf[b])&&(h=(h<<16)+(h<<1)+h&2147483647,f=h>>16&7,this.addPixel(b,g,0==f?this.argbNoisyDn:1==f?this.argbNoisyUp:this.argbCurrent));++b;k+=d}else{h=f.rScaled<<8;c=Clazz.doubleToInt((g.rScaled-f.rScaled<<8)/a);var l=f.gScaled,m=Clazz.doubleToInt((g.gScaled-l)/a);f=f.bScaled;for(var n=Clazz.doubleToInt((g.bScaled-f)/a);0<=--a;){if(this.addAllPixels||(e=!e))g=k>>10,g>=this.slab&&(g<=
this.depth&&g<this.zbuf[b])&&this.addPixel(b,g,4278190080|h&16711680|l&65280|f>>8&255);++b;k+=d;h+=c;l+=m;f+=n}}}},"~N,~N,~N,~N,~N,J.util.Rgb16,J.util.Rgb16");$_M(c$,"plotPixelsUnclippedRaster",function(a,b,c,d,e,f,g){if(!(0>=a)){var h=((b<<16)+(c<<1)^858993459)&2147483647,k=0!=((b^c)&1),l=(d<<10)+512;d=e-d;e=Clazz.doubleToInt(a/2);d=J.util.GData.roundInt(Clazz.doubleToInt(((d<<10)+(0<=d?e:-e))/a));b=c*this.width+b;if(null==f)for(;0<=--a;){if(this.addAllPixels||(k=!k))g=l>>10,g<this.zbuf[b]&&(h=(h<<
16)+(h<<1)+h&2147483647,f=h>>16&7,this.addPixel(b,g,0==f?this.argbNoisyDn:1==f?this.argbNoisyUp:this.argbCurrent));++b;l+=d}else{h=f.rScaled<<8;c=J.util.GData.roundInt(Clazz.doubleToInt((g.rScaled-f.rScaled<<8)/a));e=f.gScaled;var m=J.util.GData.roundInt(Clazz.doubleToInt((g.gScaled-e)/a));f=f.bScaled;for(var n=J.util.GData.roundInt(Clazz.doubleToInt((g.bScaled-f)/a));0<=--a;){if(this.addAllPixels||(k=!k))g=l>>10,g<this.zbuf[b]&&this.addPixel(b,g,4278190080|h&16711680|e&65280|f>>8&255);++b;l+=d;h+=
c;e+=m;f+=n}}}},"~N,~N,~N,~N,~N,J.util.Rgb16,J.util.Rgb16");$_M(c$,"plotPixelsUnclippedCount",function(a,b,c,d){var e=c*this.width+b;if(this.addAllPixels)for(;0<=--a;)d<this.zbuf[e]&&this.addPixel(e,d,this.argbCurrent),++e;else if(a=e+a,!(0!=((b^c)&1)&&++e==a)){do d<this.zbuf[e]&&this.addPixel(e,d,this.argbCurrent),e+=2;while(e<a)}},"~N,~N,~N,~N");$_M(c$,"plotPoints",($fz=function(a,b,c,d){for(a*=3;0<a;){var e=b[--a],f=b[--a]+d,g=b[--a]+c;if(!this.isClipped3(g,f,e)){var h=f*this.width+g++;e<this.zbuf[h]&&
this.addPixel(h,e,this.argbCurrent);this.antialiasThisFrame&&(h=f*this.width+g,!this.isClipped3(g,f,e)&&e<this.zbuf[h]&&this.addPixel(h,e,this.argbCurrent),h=++f*this.width+g,!this.isClipped3(g,f,e)&&e<this.zbuf[h]&&this.addPixel(h,e,this.argbCurrent),h=f*this.width+--g,!this.isClipped3(g,f,e)&&e<this.zbuf[h]&&this.addPixel(h,e,this.argbCurrent))}}},$fz.isPrivate=!0,$fz),"~N,~A,~N,~N");$_M(c$,"setColorNoisy",function(a){this.currentShadeIndex=a;this.argbCurrent=this.shadesCurrent[a];this.argbNoisyUp=
this.shadesCurrent[a<J.util.Shader.shadeIndexLast?a+1:J.util.Shader.shadeIndexLast];this.argbNoisyDn=this.shadesCurrent[0<a?a-1:0]},"~N");Clazz.overrideMethod(c$,"setNoisySurfaceShade",function(a,b,c){this.vectorAB.set(b.x-a.x,b.y-a.y,b.z-a.z);null==c?a=this.shader.getShadeIndex(-this.vectorAB.x,-this.vectorAB.y,this.vectorAB.z):(this.vectorAC.set(c.x-a.x,c.y-a.y,c.z-a.z),this.vectorAB.cross(this.vectorAB,this.vectorAC),a=0<=this.vectorAB.z?this.shader.getShadeIndex(-this.vectorAB.x,-this.vectorAB.y,
this.vectorAB.z):this.shader.getShadeIndex(this.vectorAB.x,this.vectorAB.y,-this.vectorAB.z));a>J.util.Shader.shadeIndexNoisyLimit&&(a=J.util.Shader.shadeIndexNoisyLimit);this.setColorNoisy(a)},"JU.P3i,JU.P3i,JU.P3i");$_M(c$,"getShadeIndexP3",($fz=function(a,b,c){this.vectorAB.sub2(b,a);this.vectorAC.sub2(c,a);this.vectorNormal.cross(this.vectorAB,this.vectorAC);return 0<=this.vectorNormal.z?this.shader.getShadeIndex(-this.vectorNormal.x,-this.vectorNormal.y,this.vectorNormal.z):this.shader.getShadeIndex(this.vectorNormal.x,
this.vectorNormal.y,-this.vectorNormal.z)},$fz.isPrivate=!0,$fz),"JU.P3,JU.P3,JU.P3");Clazz.overrideMethod(c$,"renderBackground",function(a){null!=this.backgroundImage&&this.plotImage(-2147483648,0,-2147483648,this.backgroundImage,a,0,0,0)},"J.api.JmolRendererInterface");Clazz.overrideMethod(c$,"drawAtom",function(a){this.fillSphereXYZ(a.screenDiameter,a.screenX,a.screenY,a.screenZ)},"J.modelset.Atom");Clazz.overrideMethod(c$,"getExportType",function(){return 0});Clazz.overrideMethod(c$,"getExportName",
function(){return null});$_M(c$,"canDoTriangles",function(){return!0});$_M(c$,"isCartesianExport",function(){return!1});Clazz.overrideMethod(c$,"initializeExporter",function(){return null},"J.viewer.Viewer,~N,J.util.GData,java.util.Map");Clazz.overrideMethod(c$,"finalizeOutput",function(){return null});Clazz.overrideMethod(c$,"drawBond",function(){},"JU.P3,JU.P3,~N,~N,~N,~N,~N");Clazz.overrideMethod(c$,"drawEllipse",function(){return!1},"JU.P3,JU.P3,JU.P3,~B,~B");$_M(c$,"getPrivateKey",function(){return 0});
Clazz.overrideMethod(c$,"clearFontCache",function(){J.g3d.TextRenderer.clearFontCache()});Clazz.overrideMethod(c$,"getTransformedVertexVectors",function(){return this.transformedVectors});Clazz.overrideMethod(c$,"isDirectedTowardsCamera",function(a){return 0>a||0<this.transformedVectors[a].z},"~N");$_M(c$,"setRotationMatrix",function(a){for(var b=J.util.Normix.getVertexVectors(),c=J.g3d.Graphics3D.normixCount;0<=--c;){var d=this.transformedVectors[c];a.transform2(b[c],d);this.shadeIndexes[c]=this.shader.getShadeB(d.x,
-d.y,d.z);this.shadeIndexes2Sided[c]=0<=d.z?this.shadeIndexes[c]:this.shader.getShadeB(-d.x,d.y,-d.z)}},"JU.M3");$_M(c$,"getShadeIndex",function(a){return-1E4==a||9999==a?J.g3d.Graphics3D.nullShadeIndex:0>a?this.shadeIndexes2Sided[~a]:this.shadeIndexes[a]},"~N");Clazz.overrideMethod(c$,"renderCrossHairs",function(a,b,c,d,e){b=this.isAntialiased();this.setColix(0>e?10:100<e?11:23);e=Math.max(Math.min(this.width,Math.round(d.x)),0);c=Math.max(Math.min(this.height,Math.round(d.y)),0);var f=Math.round(d.z)+
1,g=b?8:4,h=b?20:10;b=b?2:1;this.drawRect(e-g,c,f,0,h,b);this.drawRect(e,c-g,f,0,b,h);this.drawRect(e-g,c-g,f,0,h,h);g=h;h>>=1;this.setColix(a[1]<d.x?21:11);this.drawRect(e-g,c,f,0,h,b);this.setColix(a[0]>d.x?21:11);this.drawRect(e+h,c,f,0,h,b);this.setColix(a[3]<d.y?21:11);this.drawRect(e,c-g,f,0,b,h);this.setColix(a[2]>d.y?21:11);this.drawRect(e,c+h,f,0,b,h)},"~A,~N,~N,JU.P3,~N");Clazz.overrideMethod(c$,"initializeOutput",function(){return!1},"J.viewer.Viewer,~N,J.util.GData,java.util.Map");$_M(c$,
"shadeTextPixel",function(a,b,c,d,e){switch(e){case 8:this.addPixel(a,b,c);return}0!=d&&J.g3d.Graphics3D.mergeBufferPixel(this.pbuf,a,d,this.bgcolor);e+=this.translucencyLog;7<e||(J.g3d.Graphics3D.mergeBufferPixel(this.pbuf,a,c&16777215|e<<24,this.bgcolor),this.zbuf[a]=b)},"~N,~N,~N,~N,~N");Clazz.defineStatics(c$,"sort",null);c$.normixCount=c$.prototype.normixCount=J.util.Normix.getNormixCount();Clazz.defineStatics(c$,"nullShadeIndex",50)}),Clazz.declarePackage("J.g3d"),Clazz.load(["JU.P3","J.util.Shader"],
"J.g3d.SphereRenderer",["J.util.GData"],function(){c$=Clazz.decorateAsClass(function(){this.shader=this.g3d=null;this.diameter=this.z=this.y=this.x=this.maxZ=this.minZ=this.maxY=this.minY=this.maxX=this.minX=0;this.tScreened=!1;this.mDeriv=this.coef=this.mat=this.zroot=this.shades=null;this.selectedOctant=0;this.octantPoints=null;this.planeShade=0;this.zbuf=null;this.offsetPbufBeginLine=this.slab=this.depth=this.height=this.width=0;this.addAllPixels=!1;this.dxyz=this.planeShades=this.ptTemp=null;
this.z0=0;Clazz.instantialize(this,arguments)},J.g3d,"SphereRenderer");Clazz.prepareFields(c$,function(){this.zroot=Clazz.newDoubleArray(2,0);this.ptTemp=new JU.P3;this.planeShades=Clazz.newIntArray(3,0);this.dxyz=Clazz.newFloatArray(3,3,0)});Clazz.makeConstructor(c$,function(a){this.g3d=a;this.shader=a.shader},"J.g3d.Graphics3D");$_M(c$,"render",function(a,b,c,d,e,f,g,h,k,l,m,n){if(1!=f&&(this.width=this.g3d.width,this.height=this.g3d.height,49<c&&(c&=-2),!this.g3d.isClippedXY(c,d,e))){var q=c+1>>
1;this.minX=d-q;this.maxX=d+q;this.minY=e-q;this.maxY=e+q;this.slab=this.g3d.slab;this.depth=this.g3d.depth;this.minZ=f-q;this.maxZ=f+q;this.maxZ<this.slab||this.minZ>this.depth||(this.shader.nOut=this.shader.nIn=0,this.zbuf=this.g3d.zbuf,this.addAllPixels=n,this.offsetPbufBeginLine=this.width*e+d,this.x=d,this.y=e,this.z=f,this.diameter=c,this.tScreened=b,this.shades=a,this.mat=g,null!=g&&(this.coef=h,this.mDeriv=k,this.selectedOctant=l,this.octantPoints=m),null!=g||128<c?(this.renderLarge(),null!=
g&&(this.octantPoints=this.mDeriv=this.coef=this.mat=null)):(a=this.getSphereShape(c),0>this.minX||this.maxX>=this.width||0>this.minY||this.maxY>=this.height||this.minZ<this.slab||f>this.depth?this.renderShapeClipped(a):this.renderShapeUnclipped(a)),this.zbuf=this.shades=null)}},"~A,~B,~N,~N,~N,~N,JU.M3,~A,JU.M4,~N,~A,~B");$_M(c$,"getSphereShape",($fz=function(a){var b;return null==(b=this.shader.sphereShapeCache[a-1])?this.createSphereShape(a):b},$fz.isPrivate=!0,$fz),"~N");$_M(c$,"createSphereShape",
($fz=function(a){for(var b=0,c=0!=(a&1),d=a/2,e=d*d,f=Clazz.doubleToInt((a+1)/2),g=c?0:0.5,h=0;h<f;++h,++g)for(var k=g*g,l=c?0:0.5,m=0;m<f;++m,++l){var n=l*l,n=e-k-n;0<=n&&++b}for(var b=Clazz.newIntArray(b,0),q=0,g=c?0:0.5,h=0;h<f;++h,++g){k=g*g;l=c?0:0.5;for(m=0;m<f;++m,++l)if(n=l*l,n=e-k-n,0<=n){var p=Math.sqrt(n),n=Clazz.floatToInt(p),r=this.shader.getShadeN(l,g,p,d),s=this.shader.getShadeN(-l,g,p,d),t=this.shader.getShadeN(l,-g,p,d),p=this.shader.getShadeN(-l,-g,p,d),n=n|r<<7|s<<13|t<<19|p<<25;
b[q++]=n}b[q-1]|=2147483648}return this.shader.sphereShapeCache[a-1]=b},$fz.isPrivate=!0,$fz),"~N");$_M(c$,"renderShapeUnclipped",($fz=function(a){var b=0,c=1-(this.diameter&1),d=this.offsetPbufBeginLine,e=d-c*this.width,f=Clazz.doubleToInt((this.diameter+1)/2);if(this.tScreened){var g=(this.x^this.y)&1,h=g^c,g=g|(g^c)<<1|h<<2|(h^c)<<3;do{k=d;l=d-c;m=e;n=e-c;h=g=~g;do q=a[b++],p=this.z-(q&127),0!=(h&1)&&p<this.zbuf[k]&&this.g3d.addPixel(k,p,this.shades[q>>7&63]),0!=(h&2)&&p<this.zbuf[l]&&this.g3d.addPixel(l,
p,this.shades[q>>13&63]),0!=(h&4)&&p<this.zbuf[m]&&this.g3d.addPixel(m,p,this.shades[q>>19&63]),0!=(h&8)&&p<this.zbuf[n]&&this.g3d.addPixel(n,p,this.shades[q>>25&63]),++k,--l,++m,--n,h=~h;while(0<=q);d+=this.width;e-=this.width}while(0<--f)}else{do{var k=d,l=d-c,m=e,n=e-c,q;do{q=a[b++];var p=this.z-(q&127);p<this.zbuf[k]&&this.g3d.addPixel(k,p,this.shades[q>>7&63]);p<this.zbuf[l]&&this.g3d.addPixel(l,p,this.shades[q>>13&63]);p<this.zbuf[m]&&this.g3d.addPixel(m,p,this.shades[q>>19&63]);p<this.zbuf[n]&&
this.g3d.addPixel(n,p,this.shades[q>>25&63]);++k;--l;++m;--n}while(0<=q);d+=this.width;e-=this.width}while(0<--f)}},$fz.isPrivate=!0,$fz),"~A");$_M(c$,"renderShapeClipped",($fz=function(a){var b=0,c=1-(this.diameter&1),d=this.offsetPbufBeginLine,e=d-c*this.width,f=Clazz.doubleToInt((this.diameter+1)/2),g=this.y,h=this.y-c,k=(this.x<<16)+(this.y<<1)^858993459,l=(this.x^this.y)&1,m=l^c,l=l|(l^c)<<1|m<<2|(m^c)<<3;do{var m=0<=g&&g<this.height,n=0<=h&&h<this.height,q=d,p=d-c,r=e,s=e-c,t,u=l=~l,v=this.x,
y=this.x-c;do{var A=0<=y&&y<this.width,B=0<=v&&v<this.width;t=a[b++];var w;w=t&127;var x;this.z<this.slab?(x=this.z+w,w=x>=this.slab):(x=this.z-w,w=x<this.slab);w&&(x=this.slab);if(x>=this.slab&&x<=this.depth){if(m){if(B&&(this.addAllPixels||0!=(u&1))&&x<this.zbuf[q]){var z=w?J.g3d.SphereRenderer.SHADE_SLAB_CLIPPED-3+(k>>7&7):t>>7&63;this.g3d.addPixel(q,x,this.shades[z])}if(A&&(this.addAllPixels||0!=(u&2))&&x<this.zbuf[p])z=w?J.g3d.SphereRenderer.SHADE_SLAB_CLIPPED-3+(k>>13&7):t>>13&63,this.g3d.addPixel(p,
x,this.shades[z])}if(n){if(B&&(!this.tScreened||0!=(u&4))&&x<this.zbuf[r])z=w?J.g3d.SphereRenderer.SHADE_SLAB_CLIPPED-3+(k>>19&7):t>>19&63,this.g3d.addPixel(r,x,this.shades[z]);if(A&&(!this.tScreened||0!=(u&8))&&x<this.zbuf[s])z=w?J.g3d.SphereRenderer.SHADE_SLAB_CLIPPED-3+(k>>25&7):t>>25&63,this.g3d.addPixel(s,x,this.shades[z])}}++q;--p;++r;--s;++v;--y;u=~u;w&&(k=(k<<16)+(k<<1)+k&2147483647)}while(0<=t);d+=this.width;e-=this.width;++g;--h}while(0<--f)},$fz.isPrivate=!0,$fz),"~A");$_M(c$,"renderLarge",
($fz=function(){null!=this.mat?(null==this.shader.ellipsoidShades&&this.shader.createEllipsoidShades(),null!=this.octantPoints&&this.setPlaneDerivatives()):this.shader.sphereShadingCalculated||this.shader.calcSphereShading();this.renderQuadrant(-1,-1);this.renderQuadrant(-1,1);this.renderQuadrant(1,-1);this.renderQuadrant(1,1)},$fz.isPrivate=!0,$fz));$_M(c$,"renderQuadrant",($fz=function(a,b){var c=Clazz.doubleToInt(this.diameter/2),d=this.x+c*a,e=(0>this.x?-1:this.x<this.width?0:1)+(0>d?-2:d<this.width?
0:2);-3==e||3==e||(d=this.y+c*b,d=(0>this.y?-1:this.y<this.height?0:1)+(0>d?-2:d<this.height?0:2),-3==d||3==d||(null==this.mat&&0==e&&0==d&&this.z-c>=this.slab&&this.z<=this.depth?this.renderQuadrantUnclipped(c,a,b):this.renderQuadrantClipped(c,a,b)))},$fz.isPrivate=!0,$fz),"~N,~N");$_M(c$,"renderQuadrantUnclipped",($fz=function(a,b,c){for(var d=a*a,e=2*a+1,f=0==((this.x^this.y)&1),g=0>c?-this.width:this.width,h=this.offsetPbufBeginLine,k=0,l=0;l<=d;l+=k+ ++k,h+=g)for(var m=h,n=f=!f,q=d-l,p=this.z-
a,r=Clazz.doubleToInt((k*c+a<<8)/e),s=0,t=0;t<=q;t+=s+ ++s,m+=b)if((this.addAllPixels||(n=!n))&&!(this.zbuf[m]<=p))if(p=Clazz.doubleToInt(Math.sqrt(q-t)),p=this.z-p,!(this.zbuf[m]<=p)){var u=Clazz.doubleToInt((s*b+a<<8)/e);this.g3d.addPixel(m,p,this.shades[this.shader.sphereShadeIndexes[(r<<8)+u]])}},$fz.isPrivate=!0,$fz),"~N,~N,~N");$_M(c$,"renderQuadrantClipped",($fz=function(a,b,c){for(var d=null!=this.mat,e=0<=this.selectedOctant,f=a*a,g=2*a+1,h=0>c?-this.width:this.width,k=this.offsetPbufBeginLine,
l=(this.x<<16)+(this.y<<1)^858993459,m=this.y,n=0,q=0,p=0,r=0;r<=f;r+=p+ ++p,k+=h,m+=c)if(0>m){if(0>c)break}else if(m>=this.height){if(0<c)break}else{var s=f-(d?0:r),t=this.x;d||(n=Clazz.doubleToInt((p*c+a<<8)/g));for(var l=(l<<16)+(l<<1)+l&2147483647,u=-1,v=1,y=k,A=0,B=0;B<=s;B+=A+ ++A,y+=b,t+=b)if(0>t){if(0>b)break}else if(t>=this.width){if(0<b)break}else if(!(this.tScreened&&0!=((t^m)&1))){var w;if(d){if(!J.g3d.SphereRenderer.getQuardricZ(t,m,this.coef,this.zroot)){if(0<=u)break;continue}u=this.z<
this.slab?1:0;w=Clazz.doubleToInt(this.zroot[u]);0==w&&(w=this.z);v=2;this.z0=w;if(e){this.ptTemp.set(t-this.x,m-this.y,w-this.z);this.mat.transform(this.ptTemp);J.util.GData.getScreenOctant(this.ptTemp)==this.selectedOctant&&(q=this.getPlaneShade(t,m,this.zroot),w=Clazz.doubleToInt(this.zroot[0]),v=3);var x=this.z<this.slab?w>=this.slab:w<this.slab;x&&(this.z0=w=this.slab,v=0)}if(w<this.slab||w>this.depth||this.zbuf[y]<=this.z0)continue}else{w=Clazz.doubleToInt(Math.sqrt(s-B));w=this.z+(this.z<this.slab?
w:-w);if(x=this.z<this.slab?w>=this.slab:w<this.slab)w=this.slab,v=0;if(w<this.slab||w>this.depth||this.zbuf[y]<=w)continue}switch(v){case 0:q=J.g3d.SphereRenderer.SHADE_SLAB_CLIPPED-3+(l>>8&7);l=(l<<16)+(l<<1)+l&2147483647;v=1;break;case 2:q=this.shader.getEllipsoidShade(t,m,this.zroot[u],a,this.mDeriv);break;case 3:this.g3d.clearPixel(y,this.z0);break;default:q=Clazz.doubleToInt((A*b+a<<8)/g),q=this.shader.sphereShadeIndexes[(n<<8)+q]}this.g3d.addPixel(y,w,this.shades[q])}l=(l+t+m|1)&2147483647}},
$fz.isPrivate=!0,$fz),"~N,~N,~N");c$.getQuardricZ=$_M(c$,"getQuardricZ",($fz=function(a,b,c,d){var e=(c[4]*a+c[5]*b+c[8])/c[2]/2;a=e*e-(c[0]*a*a+c[1]*b*b+c[3]*a*b+c[6]*a+c[7]*b-1)/c[2];if(0>a)return!1;a=Math.sqrt(a);d[0]=-e-a;d[1]=-e+a;return!0},$fz.isPrivate=!0,$fz),"~N,~N,~A,~A");$_M(c$,"setPlaneDerivatives",($fz=function(){this.planeShade=-1;for(var a=0;3>a;a++){var b=this.dxyz[a][0]=this.octantPoints[a].x-this.x,c=this.dxyz[a][1]=this.octantPoints[a].y-this.y,d=this.dxyz[a][2]=this.octantPoints[a].z-
this.z;this.planeShades[a]=this.shader.getShadeIndex(b,c,-d);if(0==b&&0==c){this.planeShade=this.planeShades[a];break}}},$fz.isPrivate=!0,$fz));$_M(c$,"getPlaneShade",($fz=function(a,b,c){if(0<=this.planeShade)return this.planeShade;for(var d=3,e,f=3.4028235E38,g=0;3>g;g++)if(0!=(e=this.dxyz[g][2]))e=this.z+(-this.dxyz[g][0]*(a-this.x)-this.dxyz[g][1]*(b-this.y))/e,e<f&&(f=e,d=g);3==d&&(d=0,f=this.z);c[0]=f;return this.planeShades[d]},$fz.isPrivate=!0,$fz),"~N,~N,~A");Clazz.defineStatics(c$,"maxOddSizeSphere",
49,"maxSphereDiameter",1E3,"maxSphereDiameter2",2E3);c$.SHADE_SLAB_CLIPPED=c$.prototype.SHADE_SLAB_CLIPPED=J.util.Shader.shadeIndexNormal-5}),Clazz.declarePackage("J.g3d"),Clazz.load(null,"J.g3d.CylinderRenderer",["JU.ArrayUtil","J.util.Shader"],function(){c$=Clazz.decorateAsClass(function(){this.shader=this.line3d=this.g3d=null;this.colixB=this.colixA=0;this.shadesA=null;this.isScreenedA=!1;this.shadesB=null;this.isScreenedB=!1;this.dzBf=this.dyBf=this.dxBf=this.zAf=this.yAf=this.xAf=this.dzB=this.dyB=
this.dxB=this.zA=this.yA=this.xA=0;this.tEvenDiameter=!1;this.endcaps=this.diameter=0;this.tEndcapOpen=!1;this.sinPhi=this.cosPhi=this.cosTheta=this.radius2=this.radius=this.endcapShadeIndex=this.colixEndcap=this.argbEndcap=this.zEndcap=this.yEndcap=this.xEndcap=0;this.drawBackside=this.clipped=!1;this.rasterCount=this.zTip=this.yTip=this.xTip=0;this.fp8ShadeIndexUp=this.zRaster=this.yRaster=this.xRaster=this.tzRaster=this.tyRaster=this.txRaster=this.tRaster=null;this.zXMax=this.zXMin=this.xMax=this.xMin=
this.yMax=this.yMin=0;Clazz.instantialize(this,arguments)},J.g3d,"CylinderRenderer");Clazz.prepareFields(c$,function(){this.tRaster=Clazz.newFloatArray(32,0);this.txRaster=Clazz.newFloatArray(32,0);this.tyRaster=Clazz.newFloatArray(32,0);this.tzRaster=Clazz.newFloatArray(32,0);this.xRaster=Clazz.newIntArray(32,0);this.yRaster=Clazz.newIntArray(32,0);this.zRaster=Clazz.newIntArray(32,0);this.fp8ShadeIndexUp=Clazz.newIntArray(32,0)});Clazz.makeConstructor(c$,function(a){this.g3d=a;this.line3d=a.line3d;
this.shader=a.shader},"J.g3d.Graphics3D");$_M(c$,"render",function(a,b,c,d,e,f,g,h,k,l,m,n){if(!(f>3*this.g3d.getRenderHeight())){this.isScreenedA=c;this.isScreenedB=d;var q=Clazz.doubleToInt(f/2)+1,p=this.g3d.clipCode3(g-q,h-q,k-q),r=this.g3d.clipCode3(g+q,h+q,k+q),s=this.g3d.clipCode3(l-q,m-q,n-q),q=this.g3d.clipCode3(l+q,m+q,n+q);this.clipped=0!=(p|r|s|q);if(0==(p&q&r&s))if(this.dxB=l-g,this.dyB=m-h,this.dzB=n-k,1>=f)this.line3d.plotLineDelta(this.g3d.getColorArgbOrGray(a),c,this.g3d.getColorArgbOrGray(b),
d,g,h,k,this.dxB,this.dyB,this.dzB,this.clipped);else{this.drawBackside=this.clipped||2==e||0==e;this.diameter=f;this.xA=g;this.yA=h;this.zA=k;this.endcaps=e;this.shadesA=this.g3d.getShades(this.colixA=a);this.shadesB=this.g3d.getShades(this.colixB=b);this.calcArgbEndcap(!0,!1);this.generateBaseEllipse();(2==e||4==e)&&this.renderFlatEndcap(!0);this.g3d.setZMargin(5);for(a=this.rasterCount;0<=--a;)this.plotRaster(a);this.g3d.setZMargin(0);3==e&&this.renderSphericalEndcaps()}}},"~N,~N,~B,~B,~N,~N,~N,~N,~N,~N,~N,~N");
$_M(c$,"renderBits",function(a,b,c,d,e,f,g,h,k,l,m,n){if(!(f>3*this.g3d.getRenderHeight())){this.isScreenedA=c;this.isScreenedB=d;var q=Clazz.doubleToInt(f/2)+1,p=Math.round(g),r=Math.round(h),s=Math.round(k),t=Math.round(l),u=Math.round(m),v=Math.round(n),y=this.g3d.clipCode3(p-q,r-q,s-q),p=this.g3d.clipCode3(p+q,r+q,s+q),r=this.g3d.clipCode3(t-q,u-q,v-q),q=this.g3d.clipCode3(t+q,u+q,v+q);this.clipped=0!=(y|p|r|q);if(0==(y&q&p&r))if(this.dxBf=l-g,this.dyBf=m-h,this.dzBf=n-k,0==f||1==f)this.line3d.plotLineDelta(this.g3d.getColorArgbOrGray(a),
c,this.g3d.getColorArgbOrGray(b),d,Clazz.floatToInt(g),Clazz.floatToInt(h),Clazz.floatToInt(k),Clazz.floatToInt(this.dxBf),Clazz.floatToInt(this.dyBf),Clazz.floatToInt(this.dzBf),this.clipped);else{0<f&&(this.diameter=f,this.xAf=g,this.yAf=h,this.zAf=k);this.drawBackside=!c&&!d&&(this.clipped||2==e||0==e);this.xA=Clazz.floatToInt(this.xAf);this.yA=Clazz.floatToInt(this.yAf);this.zA=Clazz.floatToInt(this.zAf);this.dxB=Clazz.floatToInt(this.dxBf);this.dyB=Clazz.floatToInt(this.dyBf);this.dzB=Clazz.floatToInt(this.dzBf);
this.shadesA=this.g3d.getShades(this.colixA=a);this.shadesB=this.g3d.getShades(this.colixB=b);this.endcaps=e;this.calcArgbEndcap(!0,!0);0<f&&this.generateBaseEllipsePrecisely(!1);2==e&&this.renderFlatEndcapPrecisely(!0);this.line3d.setLineBits(this.dxBf,this.dyBf);this.g3d.setZMargin(5);for(a=this.rasterCount;0<=--a;)this.plotRasterBits(a);this.g3d.setZMargin(0);3==e&&this.renderSphericalEndcaps();this.xAf+=this.dxBf;this.yAf+=this.dyBf;this.zAf+=this.dzBf}}},"~N,~N,~B,~B,~N,~N,~N,~N,~N,~N,~N,~N");
$_M(c$,"plotRasterBits",($fz=function(a){var b=this.fp8ShadeIndexUp[a]>>8,c=b>>1,d=this.xRaster[a],e=this.yRaster[a];a=this.zRaster[a];this.tEndcapOpen&&0!=this.argbEndcap&&(this.clipped?(this.g3d.plotPixelClippedArgb(this.argbEndcap,this.xEndcap+d,this.yEndcap+e,this.zEndcap-a-1),this.g3d.plotPixelClippedArgb(this.argbEndcap,this.xEndcap-d,this.yEndcap-e,this.zEndcap+a-1)):(this.g3d.plotPixelUnclippedArgb(this.argbEndcap,this.xEndcap+d,this.yEndcap+e,this.zEndcap-a-1),this.g3d.plotPixelUnclippedArgb(this.argbEndcap,
this.xEndcap-d,this.yEndcap-e,this.zEndcap+a-1)));this.line3d.plotLineDeltaBits(this.shadesA,this.isScreenedA,this.shadesB,this.isScreenedB,b,this.xA+d,this.yA+e,this.zA-a,this.dxB,this.dyB,this.dzB,this.clipped);this.drawBackside&&this.line3d.plotLineDelta(this.shadesA[c],this.isScreenedA,this.shadesB[c],this.isScreenedB,this.xA-d,this.yA-e,this.zA+a,this.dxB,this.dyB,this.dzB,this.clipped)},$fz.isPrivate=!0,$fz),"~N");$_M(c$,"renderCone",function(a,b,c,d,e,f,g,h,k,l,m,n){if(!(d>3*this.g3d.getRenderHeight()))if(this.dxBf=
h-(this.xAf=e),this.dyBf=k-(this.yAf=f),this.dzBf=l-(this.zAf=g),this.xA=Clazz.doubleToInt(Math.floor(this.xAf)),this.yA=Clazz.doubleToInt(Math.floor(this.yAf)),this.zA=Clazz.doubleToInt(Math.floor(this.zAf)),this.dxB=Clazz.doubleToInt(Math.floor(this.dxBf)),this.dyB=Clazz.doubleToInt(Math.floor(this.dyBf)),this.dzB=Clazz.doubleToInt(Math.floor(this.dzBf)),this.xTip=h,this.yTip=k,this.zTip=l,this.colixA=a,this.isScreenedA=b,this.shadesA=this.g3d.getShades(a),a=this.shader.getShadeIndex(this.dxB,this.dyB,
-this.dzB),this.g3d.plotPixelClippedScreened(this.shadesA[a],this.isScreenedA,Clazz.floatToInt(h),Clazz.floatToInt(k),Clazz.floatToInt(l)),this.diameter=d,1>=d)1==d&&this.line3d.plotLineDelta(this.colixA,this.isScreenedA,this.colixA,this.isScreenedA,this.xA,this.yA,this.zA,this.dxB,this.dyB,this.dzB,this.clipped);else{this.endcaps=c;this.calcArgbEndcap(!1,!0);this.generateBaseEllipsePrecisely(n);!n&&2==this.endcaps&&this.renderFlatEndcapPrecisely(!1);this.g3d.setZMargin(5);for(c=this.rasterCount;0<=
--c;)this.plotRasterCone(c,m,n);this.g3d.setZMargin(0)}},"~N,~B,~N,~N,~N,~N,~N,~N,~N,~N,~B,~B");$_M(c$,"generateBaseEllipse",($fz=function(){this.tEvenDiameter=0==(this.diameter&1);this.radius=this.diameter/2;this.radius2=this.radius*this.radius;var a=this.dxB*this.dxB+this.dyB*this.dyB;if(0==a)this.cosPhi=this.cosTheta=1,this.sinPhi=0;else{var b=Math.sqrt(a),a=Math.sqrt(a+this.dzB*this.dzB);this.cosTheta=this.dzB/a;this.cosPhi=this.dxB/b;this.sinPhi=this.dyB/b}this.calcRotatedPoint(0,0,!1);this.calcRotatedPoint(0.5,
1,!1);this.calcRotatedPoint(1,2,!1);this.rasterCount=3;this.interpolate(0,1);this.interpolate(1,2)},$fz.isPrivate=!0,$fz));$_M(c$,"generateBaseEllipsePrecisely",($fz=function(a){this.tEvenDiameter=0==(this.diameter&1);this.radius=this.diameter/2;this.radius2=this.radius*this.radius;var b=this.dxBf*this.dxBf+this.dyBf*this.dyBf;if(0==b)this.cosPhi=this.cosTheta=1,this.sinPhi=0;else{var c=Math.sqrt(b),b=Math.sqrt(b+this.dzBf*this.dzBf);this.cosTheta=this.dzBf/b;this.cosPhi=this.dxBf/c;this.sinPhi=this.dyBf/
c}a?(this.calcRotatedPoint(0,0,!0),this.calcRotatedPoint(0.5,1,!0),this.rasterCount=2,this.interpolatePrecisely(0,1)):(this.calcRotatedPoint(0,0,!0),this.calcRotatedPoint(0.5,1,!0),this.calcRotatedPoint(1,2,!0),this.rasterCount=3,this.interpolatePrecisely(0,1),this.interpolatePrecisely(1,2));for(a=0;a<this.rasterCount;a++)this.xRaster[a]=Clazz.doubleToInt(Math.floor(this.txRaster[a])),this.yRaster[a]=Clazz.doubleToInt(Math.floor(this.tyRaster[a])),this.zRaster[a]=Clazz.doubleToInt(Math.floor(this.tzRaster[a]))},
$fz.isPrivate=!0,$fz),"~B");$_M(c$,"calcRotatedPoint",($fz=function(a,b,c){this.tRaster[b]=a;a*=3.141592653589793;var d=Math.sin(a)*this.cosTheta,e=Math.cos(a);a=this.radius*(d*this.cosPhi-e*this.sinPhi);d=this.radius*(d*this.sinPhi+e*this.cosPhi);e=this.radius2-(a*a+d*d);e=0<e?Math.sqrt(e):0;c?(this.txRaster[b]=a,this.tyRaster[b]=d,this.tzRaster[b]=e):(this.tEvenDiameter?(this.xRaster[b]=Clazz.doubleToInt(a-0.5),this.yRaster[b]=Clazz.doubleToInt(d-0.5)):(this.xRaster[b]=Clazz.doubleToInt(a),this.yRaster[b]=
Clazz.doubleToInt(d)),this.zRaster[b]=Clazz.doubleToInt(e+0.5));this.fp8ShadeIndexUp[b]=this.shader.getShadeFp8(a,d,e)},$fz.isPrivate=!0,$fz),"~N,~N,~B");$_M(c$,"interpolate",($fz=function(a,b){var c=this.xRaster[b]-this.xRaster[a];0>c&&(c=-c);var d=this.yRaster[b]-this.yRaster[a];0>d&&(d=-d);if(!(1>=c+d)){for(var c=this.tRaster[a],d=this.tRaster[b],e=this.allocRaster(!1),f=4;0<=--f;){var g=(c+d)/2;this.calcRotatedPoint(g,e,!1);if(this.xRaster[e]==this.xRaster[a]&&this.yRaster[e]==this.yRaster[a])this.fp8ShadeIndexUp[a]=
this.fp8ShadeIndexUp[a]+this.fp8ShadeIndexUp[e]>>>1,c=g;else if(this.xRaster[e]==this.xRaster[b]&&this.yRaster[e]==this.yRaster[b])this.fp8ShadeIndexUp[b]=this.fp8ShadeIndexUp[b]+this.fp8ShadeIndexUp[e]>>>1,d=g;else{this.interpolate(a,e);this.interpolate(e,b);return}}this.xRaster[e]=this.xRaster[a];this.yRaster[e]=this.yRaster[b]}},$fz.isPrivate=!0,$fz),"~N,~N");$_M(c$,"interpolatePrecisely",($fz=function(a,b){var c=Clazz.doubleToInt(Math.floor(this.txRaster[b]))-Clazz.doubleToInt(Math.floor(this.txRaster[a]));
0>c&&(c=-c);var d=Clazz.doubleToInt(Math.floor(this.tyRaster[b]))-Clazz.doubleToInt(Math.floor(this.tyRaster[a]));0>d&&(d=-d);if(!(1>=c+d)){for(var c=this.tRaster[a],d=this.tRaster[b],e=this.allocRaster(!0),f=4;0<=--f;){var g=(c+d)/2;this.calcRotatedPoint(g,e,!0);if(Clazz.doubleToInt(Math.floor(this.txRaster[e]))==Clazz.doubleToInt(Math.floor(this.txRaster[a]))&&Clazz.doubleToInt(Math.floor(this.tyRaster[e]))==Clazz.doubleToInt(Math.floor(this.tyRaster[a])))this.fp8ShadeIndexUp[a]=this.fp8ShadeIndexUp[a]+
this.fp8ShadeIndexUp[e]>>>1,c=g;else if(Clazz.doubleToInt(Math.floor(this.txRaster[e]))==Clazz.doubleToInt(Math.floor(this.txRaster[b]))&&Clazz.doubleToInt(Math.floor(this.tyRaster[e]))==Clazz.doubleToInt(Math.floor(this.tyRaster[b])))this.fp8ShadeIndexUp[b]=this.fp8ShadeIndexUp[b]+this.fp8ShadeIndexUp[e]>>>1,d=g;else{this.interpolatePrecisely(a,e);this.interpolatePrecisely(e,b);return}}this.txRaster[e]=this.txRaster[a];this.tyRaster[e]=this.tyRaster[b]}},$fz.isPrivate=!0,$fz),"~N,~N");$_M(c$,"plotRaster",
($fz=function(a){var b=this.fp8ShadeIndexUp[a]>>8,c=b>>1,d=this.xRaster[a],e=this.yRaster[a];a=this.zRaster[a];this.tEndcapOpen&&0!=this.argbEndcap&&(this.clipped?(this.g3d.plotPixelClippedArgb(this.argbEndcap,this.xEndcap+d,this.yEndcap+e,this.zEndcap-a-1),this.g3d.plotPixelClippedArgb(this.argbEndcap,this.xEndcap-d,this.yEndcap-e,this.zEndcap+a-1)):(this.g3d.plotPixelUnclippedArgb(this.argbEndcap,this.xEndcap+d,this.yEndcap+e,this.zEndcap-a-1),this.g3d.plotPixelUnclippedArgb(this.argbEndcap,this.xEndcap-
d,this.yEndcap-e,this.zEndcap+a-1)));this.line3d.plotLineDeltaA(this.shadesA,this.isScreenedA,this.shadesB,this.isScreenedB,b,this.xA+d,this.yA+e,this.zA-a,this.dxB,this.dyB,this.dzB,this.clipped);this.drawBackside&&this.line3d.plotLineDelta(this.shadesA[c],this.isScreenedA,this.shadesB[c],this.isScreenedB,this.xA-d,this.yA-e,this.zA+a,this.dxB,this.dyB,this.dzB,this.clipped)},$fz.isPrivate=!0,$fz),"~N");$_M(c$,"allocRaster",($fz=function(a){for(;this.rasterCount>=this.xRaster.length;)this.xRaster=
JU.ArrayUtil.doubleLengthI(this.xRaster),this.yRaster=JU.ArrayUtil.doubleLengthI(this.yRaster),this.zRaster=JU.ArrayUtil.doubleLengthI(this.zRaster),this.tRaster=JU.ArrayUtil.doubleLengthF(this.tRaster);for(;this.rasterCount>=this.fp8ShadeIndexUp.length;)this.fp8ShadeIndexUp=JU.ArrayUtil.doubleLengthI(this.fp8ShadeIndexUp);if(a)for(;this.rasterCount>=this.txRaster.length;)this.txRaster=JU.ArrayUtil.doubleLengthF(this.txRaster),this.tyRaster=JU.ArrayUtil.doubleLengthF(this.tyRaster),this.tzRaster=
JU.ArrayUtil.doubleLengthF(this.tzRaster);return this.rasterCount++},$fz.isPrivate=!0,$fz),"~B");$_M(c$,"findMinMaxY",($fz=function(){this.yMin=this.yMax=this.yRaster[0];for(var a=this.rasterCount;0<--a;){var b=this.yRaster[a];b<this.yMin?this.yMin=b:b>this.yMax?this.yMax=b:(b=-b,b<this.yMin?this.yMin=b:b>this.yMax&&(this.yMax=b))}},$fz.isPrivate=!0,$fz));$_M(c$,"findMinMaxX",($fz=function(a){this.xMin=2147483647;this.xMax=-2147483648;for(var b=this.rasterCount;0<=--b;){if(this.yRaster[b]==a){var c=
this.xRaster[b];c<this.xMin&&(this.xMin=c,this.zXMin=this.zRaster[b]);c>this.xMax&&(this.xMax=c,this.zXMax=this.zRaster[b])}this.yRaster[b]==-a&&(c=-this.xRaster[b],c<this.xMin&&(this.xMin=c,this.zXMin=-this.zRaster[b]),c>this.xMax&&(this.xMax=c,this.zXMax=-this.zRaster[b]))}},$fz.isPrivate=!0,$fz),"~N");$_M(c$,"renderFlatEndcap",($fz=function(a){if(0!=this.dzB&&this.g3d.setColix(this.colixEndcap)){var b=this.xA,c=this.yA,d=this.zA;if(a&&0>this.dzB){if(4==this.endcaps)return;b+=this.dxB;c+=this.dyB;
d+=this.dzB}this.findMinMaxY();for(a=this.yMin;a<=this.yMax;++a){this.findMinMaxX(a);var e=this.xMax-this.xMin+1;this.g3d.setColorNoisy(this.endcapShadeIndex);this.g3d.plotPixelsClippedRaster(e,b+this.xMin,c+a,d-this.zXMin-1,d-this.zXMax-1,null,null)}}},$fz.isPrivate=!0,$fz),"~B");$_M(c$,"renderFlatEndcapPrecisely",($fz=function(a){if(0!=this.dzBf&&this.g3d.setColix(this.colixEndcap)){var b=this.xAf,c=this.yAf,d=this.zAf;a&&0>this.dzBf&&(b+=this.dxBf,c+=this.dyBf,d+=this.dzBf);a=Clazz.floatToInt(b);
c=Clazz.floatToInt(c);d=Clazz.floatToInt(d);this.findMinMaxY();for(b=this.yMin;b<=this.yMax;++b){this.findMinMaxX(b);var e=this.xMax-this.xMin+1;this.g3d.setColorNoisy(this.endcapShadeIndex);this.g3d.plotPixelsClippedRaster(e,a+this.xMin,c+b,d-this.zXMin-1,d-this.zXMax-1,null,null)}}},$fz.isPrivate=!0,$fz),"~B");$_M(c$,"renderSphericalEndcaps",($fz=function(){0!=this.colixA&&this.g3d.setColix(this.colixA)&&this.g3d.fillSphereXYZ(this.diameter,this.xA,this.yA,this.zA+1);0!=this.colixB&&this.g3d.setColix(this.colixB)&&
this.g3d.fillSphereXYZ(this.diameter,this.xA+this.dxB,this.yA+this.dyB,this.zA+this.dzB+1)},$fz.isPrivate=!0,$fz));$_M(c$,"plotRasterCone",($fz=function(a,b,c){var d=this.txRaster[a],e=this.tyRaster[a],f=this.tzRaster[a],g=this.xAf+d,h=this.yAf+e,k=this.zAf-f,d=this.xAf-d,e=this.yAf-e,f=this.zAf+f,l=this.shadesA[0];this.tEndcapOpen&&0!=this.argbEndcap&&(this.g3d.plotPixelClippedScreened(this.argbEndcap,this.isScreenedA,Clazz.floatToInt(g),Clazz.floatToInt(h),Clazz.floatToInt(k)),this.g3d.plotPixelClippedScreened(this.argbEndcap,
this.isScreenedA,Clazz.floatToInt(d),Clazz.floatToInt(e),Clazz.floatToInt(f)));a=this.fp8ShadeIndexUp[a]>>8;0!=l&&(this.line3d.plotLineDeltaA(this.shadesA,this.isScreenedA,this.shadesA,this.isScreenedA,a,Clazz.floatToInt(g),Clazz.floatToInt(h),Clazz.floatToInt(k),Clazz.doubleToInt(Math.ceil(this.xTip-g)),Clazz.doubleToInt(Math.ceil(this.yTip-h)),Clazz.doubleToInt(Math.ceil(this.zTip-k)),!0),b&&(this.line3d.plotLineDeltaA(this.shadesA,this.isScreenedA,this.shadesA,this.isScreenedA,a,Clazz.floatToInt(g),
Clazz.floatToInt(h)+1,Clazz.floatToInt(k),Clazz.doubleToInt(Math.ceil(this.xTip-g)),Clazz.doubleToInt(Math.ceil(this.yTip-h))+1,Clazz.doubleToInt(Math.ceil(this.zTip-k)),!0),this.line3d.plotLineDeltaA(this.shadesA,this.isScreenedA,this.shadesA,this.isScreenedA,a,Clazz.floatToInt(g)+1,Clazz.floatToInt(h),Clazz.floatToInt(k),Clazz.doubleToInt(Math.ceil(this.xTip-g))+1,Clazz.doubleToInt(Math.ceil(this.yTip-h)),Clazz.doubleToInt(Math.ceil(this.zTip-k)),!0)),!c&&!(2!=this.endcaps&&0<this.dzB)&&this.line3d.plotLineDelta(l,
this.isScreenedA,l,this.isScreenedA,Clazz.floatToInt(d),Clazz.floatToInt(e),Clazz.floatToInt(f),Clazz.doubleToInt(Math.ceil(this.xTip-d)),Clazz.doubleToInt(Math.ceil(this.yTip-e)),Clazz.doubleToInt(Math.ceil(this.zTip-f)),!0))},$fz.isPrivate=!0,$fz),"~N,~B,~B");$_M(c$,"calcArgbEndcap",($fz=function(a,b){this.tEndcapOpen=!1;var c=b?this.dzBf:this.dzB;if(!(3==this.endcaps||0==c)){this.xEndcap=this.xA;this.yEndcap=this.yA;this.zEndcap=this.zA;var d=b?this.dxBf:this.dxB,e=b?this.dyBf:this.dyB;0<=c||!a?
(this.endcapShadeIndex=this.shader.getShadeIndex(-d,-e,c),this.colixEndcap=this.colixA,c=this.shadesA):(this.endcapShadeIndex=this.shader.getShadeIndex(d,e,-c),this.colixEndcap=this.colixB,c=this.shadesB,this.xEndcap+=this.dxB,this.yEndcap+=this.dyB,this.zEndcap+=this.dzB);this.endcapShadeIndex>J.util.Shader.shadeIndexNoisyLimit&&(this.endcapShadeIndex=J.util.Shader.shadeIndexNoisyLimit);this.argbEndcap=c[this.endcapShadeIndex];this.tEndcapOpen=1==this.endcaps}},$fz.isPrivate=!0,$fz),"~B,~B")}),Clazz.declarePackage("J.g3d"),
c$=Clazz.declareType(J.g3d,"ImageRenderer"),c$.plotImage=$_M(c$,"plotImage",function(a,b,c,d,e,f,g,h,k,l){h=(g=-2147483648==a)?e.bgcolor:h;g&&(a=0,c=2147483646,k=e.width,l=e.height);0>=a+k||(a>=e.width||0>=b+l||b>=e.height)||(d=e.apiPlatform.drawImageToBuffer(null,e.platform.offscreenImage,d,k,l,g?h:0),null!=d&&(null!=f||0>a||a+k>e.width||0>b||b+l>e.height?J.g3d.ImageRenderer.plotImageClipped(a,b,c,e,f,k,l,d,h):J.g3d.ImageRenderer.plotImageUnClipped(a,b,c,e,k,l,d,h)))},"~N,~N,~N,~O,J.g3d.Graphics3D,J.api.JmolRendererInterface,~B,~N,~N,~N"),
c$.plotImageClipped=$_M(c$,"plotImageClipped",($fz=function(a,b,c,d,e,f,g,h,k){null==e&&(e=d);for(var l=d=0;d<g;d++)for(var m=0;m<f;m++){var n=h[l++];e.plotImagePixel(n,a+m,b+d,c,8,k)}},$fz.isPrivate=!0,$fz),"~N,~N,~N,J.g3d.Graphics3D,J.api.JmolRendererInterface,~N,~N,~A,~N"),c$.plotImageUnClipped=$_M(c$,"plotImageUnClipped",($fz=function(a,b,c,d,e,f,g){var h=d.zbuf,k=d.width;a=b*k+a;for(var l=b=0,m=0;b<f;){for(;l<e;)c<h[a]&&d.addPixel(a,c,g[m]),++m,++l,++a;++b;l-=e;a+=k-e}},$fz.isPrivate=!0,$fz),
"~N,~N,~N,J.g3d.Graphics3D,~N,~N,~A,~N"),Clazz.declarePackage("J.g3d"),Clazz.load(["java.util.Hashtable"],"J.g3d.LineRenderer",["java.lang.Float","J.util.BSUtil","$.Logger","$.Shader"],function(){c$=Clazz.decorateAsClass(function(){this.lineBits=this.shader=this.g3d=null;this.slope=0;this.lineTypeX=!1;this.nFound=this.nCached=this.nBits=0;this.slopeKey=this.lineCache=null;this.cc2=this.cc1=this.z2t=this.y2t=this.x2t=this.z1t=this.y1t=this.x1t=0;Clazz.instantialize(this,arguments)},J.g3d,"LineRenderer");
Clazz.prepareFields(c$,function(){this.lineCache=new java.util.Hashtable});Clazz.makeConstructor(c$,function(a){this.g3d=a;this.shader=a.shader},"J.g3d.Graphics3D");$_M(c$,"setLineBits",function(a,b){this.slope=0!=a?b/a:0<=b?3.4028235E38:-3.4028235E38;this.nBits=(this.lineTypeX=1>=this.slope&&-1<=this.slope)?this.g3d.getRenderWidth():this.g3d.getRenderHeight();if(!this.getCachedLine()){this.lineBits=J.util.BSUtil.newBitSet(this.nBits);b=Math.abs(b);a=Math.abs(a);if(b>a){var c=a;a=b;b=c}for(var c=
0,d=a+a,e=b+b,f=0;f<this.nBits;f++)c+=e,c>a&&(this.lineBits.set(f),c-=d);this.lineCache.put(this.slopeKey,this.lineBits);this.nCached++}},"~N,~N");$_M(c$,"clearLineCache",function(){this.lineCache.clear();this.nCached=0});$_M(c$,"plotLine",function(a,b,c,d,e,f,g,h,k,l,m){this.x1t=e;this.x2t=h;this.y1t=f;this.y2t=k;this.z1t=g;this.z2t=l;if(m)switch(this.getTrimmedLine()){case 0:m=!1;break;case 2:return}this.plotLineClipped(a,b,c,d,e,f,g,h-e,k-f,l-g,m,0,0)},"~N,~B,~N,~B,~N,~N,~N,~N,~N,~N,~B");$_M(c$,
"plotLineDelta",function(a,b,c,d,e,f,g,h,k,l,m){this.x1t=e;this.x2t=e+h;this.y1t=f;this.y2t=f+k;this.z1t=g;this.z2t=g+l;if(m)switch(this.getTrimmedLine()){case 2:return;case 0:m=!1}this.plotLineClipped(a,b,c,d,e,f,g,h,k,l,m,0,0)},"~N,~B,~N,~B,~N,~N,~N,~N,~N,~N,~B");$_M(c$,"plotLineDeltaA",function(a,b,c,d,e,f,g,h,k,l,m,n){this.x1t=f;this.x2t=f+k;this.y1t=g;this.y2t=g+l;this.z1t=h;this.z2t=h+m;if(n)switch(this.getTrimmedLine()){case 2:return;case 0:n=!1}this.plotLineClippedA(a,b,c,d,e,f,g,h,k,l,m,
n,0,0)},"~A,~B,~A,~B,~N,~N,~N,~N,~N,~N,~N,~B");$_M(c$,"plotLineDeltaBits",function(a,b,c,d,e,f,g,h,k,l,m,n){this.x1t=f;this.x2t=f+k;this.y1t=g;this.y2t=g+l;this.z1t=h;this.z2t=h+m;n&&2==this.getTrimmedLine()||this.plotLineClippedBits(a,b,c,d,e,f,g,h,k,l,m,0,0)},"~A,~B,~A,~B,~N,~N,~N,~N,~N,~N,~N,~B");$_M(c$,"plotDashedLine",function(a,b,c,d,e,f,g,h,k,l,m){this.x1t=e;this.x2t=h;this.y1t=f;this.y2t=k;this.z1t=g;this.z2t=l;if(m)switch(this.getTrimmedLine()){case 2:return;case 0:m=!1}this.plotLineClipped(a,
b,a,b,e,f,g,h-e,k-f,l-g,m,c,d)},"~N,~B,~N,~N,~N,~N,~N,~N,~N,~N,~B");$_M(c$,"getCachedLine",($fz=function(){this.slopeKey=Float.$valueOf(this.slope);if(!this.lineCache.containsKey(this.slopeKey))return!1;this.lineBits=this.lineCache.get(this.slopeKey);J.util.Logger.debugging&&(this.nFound++,1E6==this.nFound&&J.util.Logger.debug("nCached/nFound lines: "+this.nCached+" "+this.nFound));return!0},$fz.isPrivate=!0,$fz));$_M(c$,"getTrimmedLine",($fz=function(){this.cc1=this.g3d.clipCode3(this.x1t,this.y1t,
this.z1t);this.cc2=this.g3d.clipCode3(this.x2t,this.y2t,this.z2t);if(0==(this.cc1|this.cc2))return 0;var a=this.g3d.xLast,b=this.g3d.yLast,c=this.g3d.slab,d=this.g3d.depth;do{if(0!=(this.cc1&this.cc2))return 2;var e=this.x2t-this.x1t,f=this.y2t-this.y1t,g=this.z2t-this.z1t;0!=this.cc1?(0!=(this.cc1&8)?(this.y1t+=-this.x1t*f/e,this.z1t+=-this.x1t*g/e,this.x1t=0):0!=(this.cc1&4)?(this.y1t+=(a-this.x1t)*f/e,this.z1t+=(a-this.x1t)*g/e,this.x1t=a):0!=(this.cc1&2)?(this.x1t+=-this.y1t*e/f,this.z1t+=-this.y1t*
g/f,this.y1t=0):0!=(this.cc1&1)?(this.x1t+=(b-this.y1t)*e/f,this.z1t+=(b-this.y1t)*g/f,this.y1t=b):0!=(this.cc1&32)?(this.x1t+=(c-this.z1t)*e/g,this.y1t+=(c-this.z1t)*f/g,this.z1t=c):(this.x1t+=(d-this.z1t)*e/g,this.y1t+=(d-this.z1t)*f/g,this.z1t=d),this.cc1=this.g3d.clipCode3(this.x1t,this.y1t,this.z1t)):(0!=(this.cc2&8)?(this.y2t+=-this.x2t*f/e,this.z2t+=-this.x2t*g/e,this.x2t=0):0!=(this.cc2&4)?(this.y2t+=(a-this.x2t)*f/e,this.z2t+=(a-this.x2t)*g/e,this.x2t=a):0!=(this.cc2&2)?(this.x2t+=-this.y2t*
e/f,this.z2t+=-this.y2t*g/f,this.y2t=0):0!=(this.cc2&1)?(this.x2t+=(b-this.y2t)*e/f,this.z2t+=(b-this.y2t)*g/f,this.y2t=b):0!=(this.cc2&32)?(this.x2t+=(c-this.z2t)*e/g,this.y2t+=(c-this.z2t)*f/g,this.z2t=c):(this.x2t+=(d-this.z2t)*e/g,this.y2t+=(d-this.z2t)*f/g,this.z2t=d),this.cc2=this.g3d.clipCode3(this.x2t,this.y2t,this.z2t))}while(0!=(this.cc1|this.cc2));return 1},$fz.isPrivate=!0,$fz));$_M(c$,"plotLineClipped",($fz=function(a,b,c,d,e,f,g,h,k,l,m,n,q){var p=this.g3d.zbuf,r=this.g3d.getRenderWidth(),
s=0;0==n&&(q=2147483647,n=1);var t=f*r+e,u=this.g3d.bufferSize,v=0!=((e^f)&1);0!=a&&(!m&&0<=t&&t<u&&g<p[t]&&(!b||(v=!v)))&&this.g3d.addPixel(t,g,a);if(!(0==h&&0==k)){m=1;var y=r;e+=h;var A=f+k;0>h&&(h=-h,m=-1);0>k&&(k=-k,y=-r);r=h+h;f=k+k;g<<=10;if(k<=h){var B=h-1;0>l&&(B=-B);l=Clazz.doubleToInt(((l<<10)+B)/h);k=0;B=Math.abs(e-this.x2t)-1;e=Math.abs(e-this.x1t)-1;for(var A=h-1,w=Clazz.doubleToInt(A/2);--A>=B&&!(A==w&&(b=d,a=c,0==a));){t+=m;g+=l;k+=f;k>h&&(t+=y,k-=r,v=!v);if(0!=a&&A<e&&0<=t&&t<u&&
s<q&&(!b||(v=!v))){var x=g>>10;x<p[t]&&this.g3d.addPixel(t,x,a)}s=(s+1)%n}}else{B=k-1;0>l&&(B=-B);l=Clazz.doubleToInt(((l<<10)+B)/k);h=0;B=Math.abs(A-this.y2t)-1;e=Math.abs(A-this.y1t)-1;A=k-1;for(w=Clazz.doubleToInt(A/2);--A>=B&&!(A==w&&(b=d,a=c,0==a));){t+=y;g+=l;h+=r;h>k&&(t+=m,h-=f,v=!v);if(0!=a&&A<e&&0<=t&&t<u&&s<q&&(!b||(v=!v)))x=g>>10,x<p[t]&&this.g3d.addPixel(t,x,a);s=(s+1)%n}}}},$fz.isPrivate=!0,$fz),"~N,~B,~N,~B,~N,~N,~N,~N,~N,~N,~B,~N,~N");$_M(c$,"plotLineClippedA",($fz=function(a,b,c,
d,e,f,g,h,k,l,m,n,q,p){var r=this.g3d.zbuf,s=this.g3d.getRenderWidth(),t=0;0==q&&(p=2147483647,q=1);var u=g*s+f,v=this.g3d.bufferSize,y=e<J.util.Shader.shadeIndexLast?e+1:e,A=0<e?e-1:e,B=a[y],w=a[A],x=c[e],y=c[y];c=c[A];a=a[e];e=b;var z=0!=((f^g)&1);0!=a&&(!n&&0<=u&&u<v&&h<r[u]&&(!e||(z=!z)))&&this.g3d.addPixel(u,h,a);if(!(0==k&&0==l)){n=1;var A=s,D=f+k,C=g+l;0>k&&(k=-k,n=-1);0>l&&(l=-l,A=-s);g=k+k;f=l+l;h<<=10;if(l<=k){var E=k-1;0>m&&(E=-E);m=Clazz.doubleToInt(((m<<10)+E)/k);l=0;for(var E=Math.abs(D-
this.x2t)-1,D=Math.abs(D-this.x1t)-1,C=k-1,F=Clazz.doubleToInt(C/2);--C>=E;){if(C==F){a=x;if(0==a)break;B=y;w=c;if((e=d)&&!b)var z=Clazz.doubleToInt(u/s),G=u%s,z=0==((G^z)&1)}u+=n;h+=m;l+=f;l>k&&(u+=A,l-=g,z=!z);if(0!=a&&C<D&&0<=u&&u<v&&t<p&&(!e||(z=!z)))if(G=h>>10,G<r[u]){var H=this.shader.nextRandom8Bit();this.g3d.addPixel(u,G,85>H?w:170<H?B:a)}t=(t+1)%q}}else{E=l-1;0>m&&(E=-E);m=Clazz.doubleToInt(((m<<10)+E)/l);k=0;E=Math.abs(C-this.y2t)-1;D=Math.abs(C-this.y1t)-1;C=l-1;for(F=Clazz.doubleToInt(C/
2);--C>=E;){if(C==F){a=x;if(0==a)break;B=y;w=c;if((e=d)&&!b)z=Clazz.doubleToInt(u/s),G=u%s,z=0==((G^z)&1)}u+=A;h+=m;k+=g;k>l&&(u+=n,k-=f,z=!z);if(0!=a&&C<D&&0<=u&&u<v&&t<p&&(!e||(z=!z)))G=h>>10,G<r[u]&&(H=this.g3d.shader.nextRandom8Bit(),this.g3d.addPixel(u,G,85>H?w:170<H?B:a));t=(t+1)%q}}}},$fz.isPrivate=!0,$fz),"~A,~B,~A,~B,~N,~N,~N,~N,~N,~N,~N,~B,~N,~N");$_M(c$,"plotLineClippedBits",($fz=function(a,b,c,d,e,f,g,h,k,l,m,n,q){var p=this.g3d.zbuf,r=this.g3d.width,s=0;0==n&&(q=2147483647,n=1);var t=
e<J.util.Shader.shadeIndexLast?e+1:e,u=0<e?e-1:e,v=a[e],y=a[t],A=a[u];e=c[e];t=c[t];c=c[u];var u=b,B=0!=((f^g)&1);a=g*r+f;var w=this.g3d.bufferSize,x,z,D,C,E;this.lineTypeX?(x=f,z=this.x1t,D=this.x2t,f+=Clazz.doubleToInt(k/2),C=g=0<=k?1:-1,E=0<=l?r:-r,k=m/Math.abs(k)):(x=g,z=this.y1t,D=this.y2t,f=g+Clazz.doubleToInt(l/2),g=0<=l?1:-1,C=0<=l?r:-r,E=0<=k?1:-1,k=m/Math.abs(l));l=!1;for(m=x;;m+=g,x+=g){m==z&&(l=!0);if(m==f){v=e;if(0==v)break;y=t;A=c;if((u=d)&&!b)B=Clazz.doubleToInt(a/r),B=0==((a%r^B)&
1)}if(0!=v&&(l&&0<=a&&a<w&&s<q&&(!u||(B=!B)))&&h<p[a]){var F=this.shader.nextRandom8Bit();this.g3d.addPixel(a,Clazz.floatToInt(h),85>F?A:170<F?y:v)}if(m==D)break;s=(s+1)%n;for(a+=C;0>x;)x+=this.nBits;this.lineBits.get(x%this.nBits)&&(a+=E);h+=k}},$fz.isPrivate=!0,$fz),"~A,~B,~A,~B,~N,~N,~N,~N,~N,~N,~N,~N,~N");Clazz.defineStatics(c$,"VISIBILITY_UNCLIPPED",0,"VISIBILITY_CLIPPED",1,"VISIBILITY_OFFSCREEN",2)}),Clazz.declarePackage("J.g3d"),Clazz.load(null,"J.g3d.Pixelator",["J.g3d.Graphics3D"],function(){c$=
Clazz.decorateAsClass(function(){this.g=null;Clazz.instantialize(this,arguments)},J.g3d,"Pixelator");Clazz.makeConstructor(c$,function(a){this.g=a},"J.g3d.Graphics3D");$_M(c$,"clearPixel",function(a,b){!this.g.$isPass2&&this.g.zbuf[a]>b&&(this.g.zbuf[a]=2147483647)},"~N,~N");$_M(c$,"addPixel",function(a,b,c){this.addPixel1(a,b,c)},"~N,~N,~N");$_M(c$,"addPixel1",function(a,b,c){if(this.g.$isPass2){var d=this.g.zbufT[a];if(b<d){var e=this.g.pbufT[a];!this.g.translucentCoverOnly&&(0!=e&&d-b>this.g.zMargin)&&
J.g3d.Graphics3D.mergeBufferPixel(this.g.pbuf,a,e,this.g.bgcolor);this.g.zbufT[a]=b;this.g.pbufT[a]=c&this.g.translucencyMask}else b!=d&&!this.g.translucentCoverOnly&&b-d>this.g.zMargin&&J.g3d.Graphics3D.mergeBufferPixel(this.g.pbuf,a,c&this.g.translucencyMask,this.g.bgcolor)}else this.g.zbuf[a]=b,this.g.pbuf[a]=c},"~N,~N,~N")}),Clazz.declarePackage("J.g3d"),Clazz.load(["J.g3d.Pixelator"],"J.g3d.PixelatorShaded",null,function(){c$=Clazz.declareType(J.g3d,"PixelatorShaded",J.g3d.Pixelator);Clazz.overrideMethod(c$,
"addPixel",function(a,b,c){if(!(b>this.g.zDepth)){if(b<=this.g.zDepth&&b>=this.g.zSlab){var d=(c&65280)>>8,e=(c&16711680)>>16,f=c&4278190080,g=(this.g.zDepth-b)/(this.g.zDepth-this.g.zSlab);if(1<this.g.zShadePower)for(var h=0;h<this.g.zShadePower;h++)g*=g;c=this.g.zShadeR+Clazz.floatToInt(g*((c&255)-this.g.zShadeR));d=this.g.zShadeG+Clazz.floatToInt(g*(d-this.g.zShadeG));e=this.g.zShadeB+Clazz.floatToInt(g*(e-this.g.zShadeB));c=e<<16|d<<8|c|f}this.addPixel1(a,b,c)}},"~N,~N,~N")}),Clazz.declarePackage("J.g3d"),
Clazz.load(["java.lang.Thread"],"J.g3d.Platform3D",null,function(){c$=Clazz.decorateAsClass(function(){this.bufferSizeT=this.bufferSize=this.bufferHeight=this.bufferWidth=this.windowSize=this.windowHeight=this.windowWidth=0;this.zBufferT=this.zBuffer=this.pBufferT=this.pBuffer=this.bufferedImage=null;this.heightOffscreen=this.widthOffscreen=0;this.graphicsForTextOrImage=this.offscreenImage=null;this.useClearingThread=!1;this.apiPlatform=this.clearingThread=null;Clazz.isClassDefined("J.g3d.Platform3D.ClearingThread")||
J.g3d.Platform3D.$Platform3D$ClearingThread$();Clazz.instantialize(this,arguments)},J.g3d,"Platform3D");Clazz.makeConstructor(c$,function(a){this.initialize(!1);this.apiPlatform=a},"J.api.ApiPlatform");$_M(c$,"getGraphicsForMetrics",function(){return this.apiPlatform.getGraphics(this.allocateOffscreenImage(1,1))});$_M(c$,"initialize",function(a){if(this.useClearingThread=a)this.clearingThread=Clazz.innerTypeInstance(J.g3d.Platform3D.ClearingThread,this,null),this.clearingThread.start()},"~B");$_M(c$,
"allocateTBuffers",function(a){this.bufferSizeT=a?this.bufferSize:this.windowSize;this.zBufferT=Clazz.newIntArray(this.bufferSizeT,0);this.pBufferT=Clazz.newIntArray(this.bufferSizeT,0)},"~B");$_M(c$,"allocateBuffers",function(a,b,c,d){this.windowWidth=a;this.windowHeight=b;this.windowSize=a*b;c&&(a*=2,b*=2);this.bufferWidth=a;this.bufferHeight=b;this.bufferSize=this.bufferWidth*this.bufferHeight;this.zBuffer=Clazz.newIntArray(this.bufferSize,0);this.pBuffer=Clazz.newIntArray(this.bufferSize,0);this.bufferedImage=
this.apiPlatform.allocateRgbImage(this.windowWidth,this.windowHeight,this.pBuffer,this.windowSize,J.g3d.Platform3D.backgroundTransparent,d)},"~N,~N,~B,~B");$_M(c$,"releaseBuffers",function(){this.windowWidth=this.windowHeight=this.bufferWidth=this.bufferHeight=this.bufferSize=-1;null!=this.bufferedImage&&(this.apiPlatform.flushImage(this.bufferedImage),this.bufferedImage=null);this.zBufferT=this.pBufferT=this.zBuffer=this.pBuffer=null});$_M(c$,"hasContent",function(){for(var a=this.bufferSize;0<=
--a;)if(2147483647!=this.zBuffer[a])return!0;return!1});$_M(c$,"clearScreenBuffer",function(){for(var a=this.bufferSize;0<=--a;)this.zBuffer[a]=2147483647,this.pBuffer[a]=0});$_M(c$,"setBackgroundColor",function(a){if(null!=this.pBuffer)for(var b=this.bufferSize;0<=--b;)0==this.pBuffer[b]&&(this.pBuffer[b]=a)},"~N");$_M(c$,"clearTBuffer",function(){for(var a=this.bufferSizeT;0<=--a;)this.zBufferT[a]=2147483647,this.pBufferT[a]=0});$_M(c$,"clearBuffer",function(){this.useClearingThread?this.clearingThread.clearClientBuffer():
this.clearScreenBuffer()});$_M(c$,"clearScreenBufferThreaded",function(){this.useClearingThread&&this.clearingThread.releaseBufferForClearing()});$_M(c$,"notifyEndOfRendering",function(){this.apiPlatform.notifyEndOfRendering()});$_M(c$,"getGraphicsForTextOrImage",function(a,b){if(a>this.widthOffscreen||b>this.heightOffscreen)null!=this.offscreenImage&&(this.apiPlatform.disposeGraphics(this.graphicsForTextOrImage),this.apiPlatform.flushImage(this.offscreenImage)),a>this.widthOffscreen&&(this.widthOffscreen=
a),b>this.heightOffscreen&&(this.heightOffscreen=b),this.offscreenImage=this.allocateOffscreenImage(this.widthOffscreen,this.heightOffscreen),this.graphicsForTextOrImage=this.apiPlatform.getStaticGraphics(this.offscreenImage,J.g3d.Platform3D.backgroundTransparent);return this.graphicsForTextOrImage},"~N,~N");$_M(c$,"allocateOffscreenImage",($fz=function(a,b){return this.apiPlatform.newOffScreenImage(a,b)},$fz.isPrivate=!0,$fz),"~N,~N");$_M(c$,"setBackgroundTransparent",function(a){$t$=J.g3d.Platform3D.backgroundTransparent=
a;J.g3d.Platform3D.prototype.backgroundTransparent=J.g3d.Platform3D.backgroundTransparent;$t$},"~B");c$.$Platform3D$ClearingThread$=function(){Clazz.pu$h();c$=Clazz.decorateAsClass(function(){Clazz.prepareCallback(this,arguments);this.clientHasBuffer=this.bufferHasBeenCleared=!1;Clazz.instantialize(this,arguments)},J.g3d.Platform3D,"ClearingThread",Thread);$_M(c$,"notifyBackgroundChange",function(){this.bufferHasBeenCleared=!1;this.notify()},"~N");$_M(c$,"clearClientBuffer",function(){for(;!this.bufferHasBeenCleared;)try{this.wait()}catch(a){if(!Clazz.exceptionOf(a,
InterruptedException))throw a;}this.clientHasBuffer=!0});$_M(c$,"releaseBufferForClearing",function(){this.bufferHasBeenCleared=this.clientHasBuffer=!1;this.notify()});$_M(c$,"waitForClientRelease",function(){for(;this.clientHasBuffer||this.bufferHasBeenCleared;)try{this.wait()}catch(a){if(!Clazz.exceptionOf(a,InterruptedException))throw a;}});$_M(c$,"notifyBufferReady",function(){this.bufferHasBeenCleared=!0;this.notify()});Clazz.overrideMethod(c$,"run",function(){for(;;)this.waitForClientRelease(),
this.b$["J.g3d.Platform3D"].clearScreenBuffer(),this.notifyBufferReady()});c$=Clazz.p0p()};Clazz.defineStatics(c$,"desireClearingThread",!1,"backgroundTransparent",!1)}),Clazz.declarePackage("J.g3d"),Clazz.load(["java.util.Hashtable"],"J.g3d.TextRenderer",["J.util.ColorUtil"],function(){c$=Clazz.decorateAsClass(function(){this.size=this.mapWidth=this.width=this.ascent=this.height=0;this.tmap=null;this.isInvalid=!1;Clazz.instantialize(this,arguments)},J.g3d,"TextRenderer");c$.clearFontCache=$_M(c$,
"clearFontCache",function(){J.g3d.TextRenderer.working||(J.g3d.TextRenderer.htFont3d.clear(),J.g3d.TextRenderer.htFont3dAntialias.clear())});c$.plot=$_M(c$,"plot",function(a,b,c,d,e,f,g,h,k,l){if(0==f.length)return 0;if(0<=f.indexOf("<su")||0<=f.indexOf("<color"))return J.g3d.TextRenderer.plotByCharacter(a,b,c,d,e,f,g,h,k,l);var m=g.getAscent();b-=m;f=J.g3d.TextRenderer.getPlotText3D(a,b,h,f,g,l);if(f.isInvalid)return f.width;l&&0==(d&12632256)&&(d|=263172);null!=k||0>a||a+f.width>h.width||0>b||b+
f.height>h.height?J.g3d.TextRenderer.plotClipped(a,b,c,d,e,h,k,f.mapWidth,f.height,f.tmap):J.g3d.TextRenderer.plotUnclipped(a,b,c,d,e,h,f.mapWidth,f.height,f.tmap);return f.width},"~N,~N,~N,~N,~N,~S,J.util.JmolFont,J.g3d.Graphics3D,J.api.JmolRendererInterface,~B");c$.plotByCharacter=$_M(c$,"plotByCharacter",($fz=function(a,b,c,d,e,f,g,h,k,l){for(var m=0,n=f.length,q=Math.round(0.25*g.getHeight()),p=-Math.round(0.3*g.getHeight()),r=0,s=0;s<n;s++){if("<"==f.charAt(s)){if(s+5<n&&f.substring(s,s+6).equals("<color")){var r=
d,t=f.indexOf(">",s);if(0>t)continue;d=J.util.ColorUtil.getArgbFromString(f.substring(s+7,t).trim());s=t;continue}if(s+7<n&&f.substring(s,s+8).equals("</color>")){s+=7;d=r;continue}if(s+4<n&&f.substring(s,s+5).equals("<sub>")){s+=4;b+=q;continue}if(s+4<n&&f.substring(s,s+5).equals("<sup>")){s+=4;b+=p;continue}if(s+5<n&&f.substring(s,s+6).equals("</sub>")){s+=5;b-=q;continue}if(s+5<n&&f.substring(s,s+6).equals("</sup>")){s+=5;b-=p;continue}}t=J.g3d.TextRenderer.plot(a+m,b,c,d,e,f.substring(s,s+1),
g,h,k,l);m+=t}return m},$fz.isPrivate=!0,$fz),"~N,~N,~N,~N,~N,~S,J.util.JmolFont,J.g3d.Graphics3D,J.api.JmolRendererInterface,~B");c$.plotUnclipped=$_M(c$,"plotUnclipped",($fz=function(a,b,c,d,e,f,g,h,k){var l=0,m=f.zbuf,n=f.width;a=b*n+a;for(b=0;b<h;b++){for(var q=0;q<g;q++){var p=k[l++];0!=p&&c<m[a]&&f.shadeTextPixel(a,c,d,e,p);a++}a+=n-g}},$fz.isPrivate=!0,$fz),"~N,~N,~N,~N,~N,J.g3d.Graphics3D,~N,~N,~A");c$.plotClipped=$_M(c$,"plotClipped",($fz=function(a,b,c,d,e,f,g,h,k,l){null==g&&(g=f);for(var m=
f=0;m<k;m++)for(var n=0;n<h;n++){var q=l[f++];0!=q&&g.plotImagePixel(d,a+n,b+m,c,q,e)}},$fz.isPrivate=!0,$fz),"~N,~N,~N,~N,~N,J.g3d.Graphics3D,J.api.JmolRendererInterface,~N,~N,~A");Clazz.makeConstructor(c$,($fz=function(a,b){this.ascent=b.getAscent();this.height=b.getHeight();this.width=b.stringWidth(a);0!=this.width&&(this.mapWidth=this.width,this.size=this.mapWidth*this.height)},$fz.isPrivate=!0,$fz),"~S,J.util.JmolFont");c$.getPlotText3D=$_M(c$,"getPlotText3D",($fz=function(a,b,c,d,e,f){$t$=J.g3d.TextRenderer.working=
!0;J.g3d.TextRenderer.prototype.working=J.g3d.TextRenderer.working;$t$;f=f?J.g3d.TextRenderer.htFont3dAntialias:J.g3d.TextRenderer.htFont3d;var g=f.get(e),h=null,k=!1,l=!1;null!=g?h=g.get(d):(g=new java.util.Hashtable,k=!0);null==h&&(h=new J.g3d.TextRenderer(d,e),l=!0);h.isInvalid=0==h.width||0>=a+h.width||a>=c.width||0>=b+h.height||b>=c.height;if(h.isInvalid)return h;k&&f.put(e,g);l&&(h.setTranslucency(d,e,c),g.put(d,h));$t$=J.g3d.TextRenderer.working=!1;J.g3d.TextRenderer.prototype.working=J.g3d.TextRenderer.working;
$t$;return h},$fz.isPrivate=!0,$fz),"~N,~N,J.g3d.Graphics3D,~S,J.util.JmolFont,~B");$_M(c$,"setTranslucency",($fz=function(a,b,c){a=c.apiPlatform.getTextPixels(a,b,c.platform.getGraphicsForTextOrImage(this.mapWidth,this.height),c.platform.offscreenImage,this.mapWidth,this.height,this.ascent);if(null!=a){this.tmap=Clazz.newByteArray(this.size,0);for(b=a.length;0<=--b;)c=a[b]&255,0!=c&&(this.tmap[b]=J.g3d.TextRenderer.translucency[c>>5])}},$fz.isPrivate=!0,$fz),"~S,J.util.JmolFont,J.g3d.Graphics3D");
Clazz.defineStatics(c$,"translucency",[7,6,5,4,3,2,1,8],"working",!1);c$.htFont3d=c$.prototype.htFont3d=new java.util.Hashtable;c$.htFont3dAntialias=c$.prototype.htFont3dAntialias=new java.util.Hashtable}),Clazz.declarePackage("J.g3d"),c$=Clazz.declareType(J.g3d,"TextSorter",null,java.util.Comparator),Clazz.overrideMethod(c$,"compare",function(a,b){return null==a||null==b?0:a.z>b.z?-1:a.z<b.z?1:0},"J.g3d.TextString,J.g3d.TextString"),Clazz.declarePackage("J.g3d"),Clazz.load(["JU.P3i"],"J.g3d.TextString",
null,function(){c$=Clazz.decorateAsClass(function(){this.font=this.text=null;this.bgargb=this.argb=0;Clazz.instantialize(this,arguments)},J.g3d,"TextString",JU.P3i);$_M(c$,"setText",function(a,b,c,d,e,f,g){this.text=a;this.font=b;this.argb=c;this.bgargb=d;this.x=e;this.y=f;this.z=g},"~S,J.util.JmolFont,~N,~N,~N,~N,~N");$_M(c$,"toString",function(){return Clazz.superCall(this,J.g3d.TextString,"toString",[])+" "+this.text})}),Clazz.declarePackage("J.util"),Clazz.load(null,"J.util.Rgb16",["JU.SB"],function(){c$=
Clazz.decorateAsClass(function(){this.bScaled=this.gScaled=this.rScaled=0;Clazz.instantialize(this,arguments)},J.util,"Rgb16");Clazz.makeConstructor(c$,function(){});c$.newI=$_M(c$,"newI",function(a){var b=new J.util.Rgb16;b.setInt(a);return b},"~N");$_M(c$,"setInt",function(a){this.rScaled=a>>8&65280|128;this.gScaled=a&65280|128;this.bScaled=a<<8&65280|128},"~N");$_M(c$,"setRgb",function(a){this.rScaled=a.rScaled;this.gScaled=a.gScaled;this.bScaled=a.bScaled},"J.util.Rgb16");$_M(c$,"diffDiv",function(a,
b,c){this.rScaled=Clazz.doubleToInt((a.rScaled-b.rScaled)/c);this.gScaled=Clazz.doubleToInt((a.gScaled-b.gScaled)/c);this.bScaled=Clazz.doubleToInt((a.bScaled-b.bScaled)/c)},"J.util.Rgb16,J.util.Rgb16,~N");$_M(c$,"setAndIncrement",function(a,b){this.rScaled=a.rScaled;a.rScaled+=b.rScaled;this.gScaled=a.gScaled;a.gScaled+=b.gScaled;this.bScaled=a.bScaled;a.bScaled+=b.bScaled},"J.util.Rgb16,J.util.Rgb16");$_M(c$,"getArgb",function(){return 4278190080|this.rScaled<<8&16711680|this.gScaled&65280|this.bScaled>>
8});Clazz.overrideMethod(c$,"toString",function(){return(new JU.SB).append("Rgb16(").appendI(this.rScaled).appendC(",").appendI(this.gScaled).appendC(",").appendI(this.bScaled).append(" -> ").appendI(this.rScaled>>8&255).appendC(",").appendI(this.gScaled>>8&255).appendC(",").appendI(this.bScaled>>8&255).appendC(")").toString()})}),Clazz.declarePackage("J.g3d"),Clazz.declareInterface(J.g3d,"G3DRenderer"),Clazz.declarePackage("J.g3d"),Clazz.load(["J.g3d.G3DRenderer","J.util.Rgb16"],"J.g3d.TriangleRenderer",
["J.util.GData"],function(){c$=Clazz.decorateAsClass(function(){this.rgb16t2=this.rgb16t1=this.rgb16sGouraud=this.rgb16sE=this.rgb16sW=this.azE=this.axE=this.azW=this.axW=this.az=this.ay=this.ax=this.g3d=null;Clazz.instantialize(this,arguments)},J.g3d,"TriangleRenderer",null,J.g3d.G3DRenderer);Clazz.prepareFields(c$,function(){this.ax=Clazz.newIntArray(3,0);this.ay=Clazz.newIntArray(3,0);this.az=Clazz.newIntArray(3,0);this.axW=Clazz.newIntArray(64,0);this.azW=Clazz.newIntArray(64,0);this.axE=Clazz.newIntArray(64,
0);this.azE=Clazz.newIntArray(64,0);this.rgb16t1=new J.util.Rgb16;this.rgb16t2=new J.util.Rgb16});Clazz.makeConstructor(c$,function(){});Clazz.overrideMethod(c$,"set",function(a){try{this.rgb16sW=Array(64);this.rgb16sE=Array(64);for(var b=64;0<=--b;)this.rgb16sW[b]=new J.util.Rgb16,this.rgb16sE[b]=new J.util.Rgb16;this.g3d=a;this.rgb16sGouraud=Array(3);for(b=3;0<=--b;)this.rgb16sGouraud[b]=new J.util.Rgb16}catch(c){if(!Clazz.exceptionOf(c,Exception))throw c;}return this},"J.api.JmolRendererInterface");
$_M(c$,"reallocRgb16s",function(a,b){var c=Array(b);System.arraycopy(a,0,c,0,a.length);for(var d=a.length;d<b;++d)c[d]=new J.util.Rgb16;return c},"~A,~N");$_M(c$,"setGouraud",function(a,b,c){this.rgb16sGouraud[0].setInt(a);this.rgb16sGouraud[1].setInt(b);this.rgb16sGouraud[2].setInt(c)},"~N,~N,~N");$_M(c$,"drawfillTriangle",function(a,b,c,d,e,f,g,h,k,l){this.ax[0]=a;this.ax[1]=d;this.ax[2]=g;this.ay[0]=b;this.ay[1]=e;this.ay[2]=h;this.az[0]=c;this.az[1]=f;this.az[2]=k;this.fillTriangleB(l)},"~N,~N,~N,~N,~N,~N,~N,~N,~N,~B");
$_M(c$,"fillTriangleXYZ",function(a,b,c,d,e,f,g,h,k,l){this.ax[0]=a;this.ax[1]=d;this.ax[2]=g;this.ay[0]=b;this.ay[1]=e;this.ay[2]=h;this.az[0]=c;this.az[1]=f;this.az[2]=k;this.fillTriangleB(l)},"~N,~N,~N,~N,~N,~N,~N,~N,~N,~B");$_M(c$,"fillTriangleP3i",function(a,b,c,d){this.ax[0]=a.x;this.ax[1]=b.x;this.ax[2]=c.x;this.ay[0]=a.y;this.ay[1]=b.y;this.ay[2]=c.y;this.az[0]=a.z;this.az[1]=b.z;this.az[2]=c.z;this.fillTriangleB(d)},"JU.P3i,JU.P3i,JU.P3i,~B");$_M(c$,"fillTriangleP3f",function(a,b,c,d){this.ax[0]=
Math.round(a.x);this.ax[1]=Math.round(b.x);this.ax[2]=Math.round(c.x);this.ay[0]=Math.round(a.y);this.ay[1]=Math.round(b.y);this.ay[2]=Math.round(c.y);this.az[0]=Math.round(a.z);this.az[1]=Math.round(b.z);this.az[2]=Math.round(c.z);this.fillTriangleB(d)},"JU.P3,JU.P3,JU.P3,~B");$_M(c$,"fillTriangleP3if",function(a,b,c,d,e){this.ax[0]=a.x;this.ax[1]=b.x;this.ax[2]=c.x;this.ay[0]=a.y;this.ay[1]=b.y;this.ay[2]=c.y;this.az[0]=a.z;this.az[1]=b.z;this.az[2]=c.z;J.g3d.TriangleRenderer.adjustVertex(this.ax,
d);J.g3d.TriangleRenderer.adjustVertex(this.ay,d);J.g3d.TriangleRenderer.adjustVertex(this.az,d);this.fillTriangleB(e)},"JU.P3i,JU.P3i,JU.P3i,~N,~B");c$.adjustVertex=$_M(c$,"adjustVertex",($fz=function(a,b){for(var c=(a[0]+a[1]+a[2])/3,d=0;3>d;d++)a[d]+=b*(c-a[d])},$fz.isPrivate=!0,$fz),"~A,~N");$_M(c$,"fillTriangleB",($fz=function(a){if(!(1>=this.az[0]||1>=this.az[1]||1>=this.az[2])){var b=this.g3d.clipCode3(this.ax[0],this.ay[0],this.az[0]),c=this.g3d.clipCode3(this.ax[1],this.ay[1],this.az[1]),
d=this.g3d.clipCode3(this.ax[2],this.ay[2],this.az[2]),e=0!=(b|c|d);if(!(e&&0!=(b&c&d))){b=0;this.ay[1]<this.ay[b]&&(b=1);this.ay[2]<this.ay[b]&&(b=2);c=(b+1)%3;d=(b+2)%3;if(this.ay[c]>this.ay[d])var f=c,c=d,d=f;var g=this.ay[b],h=this.ay[c],k=this.ay[d],l=k-g+1;if(!(l>3*this.g3d.height)){l>this.axW.length&&this.reallocRasterArrays(l);var m,n;a?(m=this.rgb16sW,n=this.rgb16sE):m=n=null;f=h-g;0==f?(this.ax[c]<this.ax[b]&&(f=c,c=b,b=f),this.generateRaster(l,b,d,this.axW,this.azW,0,m),this.generateRaster(l,
c,d,this.axE,this.azE,0,n)):h==k?(this.ax[d]<this.ax[c]&&(f=c,c=d,d=f),this.generateRaster(l,b,c,this.axW,this.azW,0,m),this.generateRaster(l,b,d,this.axE,this.azE,0,n)):(h=this.ax[d]-this.ax[b],k=J.util.GData.roundInt(Clazz.doubleToInt(l/2)),0>h&&(k=-k),this.ax[b]+Clazz.doubleToInt((h*f+k)/l)<this.ax[c]?(this.generateRaster(l,b,d,this.axW,this.azW,0,m),this.generateRaster(f+1,b,c,this.axE,this.azE,0,n),this.generateRaster(l-f,c,d,this.axE,this.azE,f,n)):(this.generateRaster(f+1,b,c,this.axW,this.azW,
0,m),this.generateRaster(l-f,c,d,this.axW,this.azW,f,m),this.generateRaster(l,b,d,this.axE,this.azE,0,n)));this.g3d.setZMargin(5);a?this.fillRasterG(g,l,e,this.g3d.$isPass2?1:0):this.fillRaster(g,l,e,this.g3d.$isPass2?1:0);this.g3d.setZMargin(0)}}}},$fz.isPrivate=!0,$fz),"~B");$_M(c$,"reallocRasterArrays",($fz=function(a){a=a+31&-32;this.axW=Clazz.newIntArray(a,0);this.azW=Clazz.newIntArray(a,0);this.axE=Clazz.newIntArray(a,0);this.azE=Clazz.newIntArray(a,0);this.rgb16sW=this.reallocRgb16s(this.rgb16sW,
a);this.rgb16sE=this.reallocRgb16s(this.rgb16sE,a)},$fz.isPrivate=!0,$fz),"~N");$_M(c$,"generateRaster",($fz=function(a,b,c,d,e,f,g){var h=this.ax[b],k=this.az[b],l=this.ax[c]-h,m=this.az[c]-k,n,q,p;0<=l?(n=1,q=l,p=0):(n=-1,q=-l,p=1-a);var k=(k<<10)+512,r=J.util.GData.roundInt(Clazz.doubleToInt(a/2));0>m&&(r=-r);m=Clazz.doubleToInt(((m<<10)+r)/a);q<=a?r=0:(r=J.util.GData.roundInt(Clazz.doubleToInt(l/a)),q%=a);for(var s=0,l=f;s<a;k+=m,++l,++s)d[l]=h,e[l]=k>>10,h+=r,p+=q,0<p&&(h+=n,p-=a);if(null!=g){d=
this.rgb16t1;d.setRgb(this.rgb16sGouraud[b]);b=this.rgb16t2;b.diffDiv(this.rgb16sGouraud[c],d,a);l=f;for(a=f+a;l<a;++l)g[l].setAndIncrement(d,b)}},$fz.isPrivate=!0,$fz),"~N,~N,~N,~A,~A,~N,~A");$_M(c$,"fillRaster",($fz=function(a,b,c,d){var e=0;0>a&&(b+=a,e-=a,a=0);a+b>this.g3d.height&&(b=this.g3d.height-a);if(c)for(;--b>=d;++a,++e){c=this.axW[e];var f=this.axE[e]-c+1-d;0<f&&this.g3d.plotPixelsClippedRaster(f,c,a,this.azW[e],this.azE[e],null,null)}else for(;--b>=d;++a,++e)f=this.axE[e]-(c=this.axW[e])+
1-d,1==d&&0>f&&(f=1,c--),0<f&&this.g3d.plotPixelsUnclippedRaster(f,c,a,this.azW[e],this.azE[e],null,null)},$fz.isPrivate=!0,$fz),"~N,~N,~B,~N");$_M(c$,"fillRasterG",($fz=function(a,b,c,d){var e=0;0>a&&(b+=a,e-=a,a=0);a+b>this.g3d.height&&(b=this.g3d.height-a);if(c)for(;--b>=d;++a,++e){c=this.axW[e];var f=this.axE[e]-c+1-d;0<f&&this.g3d.plotPixelsClippedRaster(f,c,a,this.azW[e],this.azE[e],this.rgb16sW[e],this.rgb16sE[e])}else for(;--b>=d;++a,++e)f=this.axE[e]-(c=this.axW[e])+1-d,1==d&&0>f&&(f=1,c--),
0<f&&this.g3d.plotPixelsUnclippedRaster(f,c,a,this.azW[e],this.azE[e],this.rgb16sW[e],this.rgb16sE[e])},$fz.isPrivate=!0,$fz),"~N,~N,~B,~N");Clazz.defineStatics(c$,"DEFAULT",64)}),Clazz.declarePackage("J.api"),Clazz.declareInterface(J.api,"JmolRepaintManager"),Clazz.declarePackage("J.render"),Clazz.load(["J.api.JmolRepaintManager","JU.BS"],"J.render.RepaintManager",["J.util.Logger","J.viewer.JC"],function(){c$=Clazz.decorateAsClass(function(){this.bsTranslucent=this.renderers=this.shapeManager=this.viewer=
null;this.holdRepaint=0;this.repaintPending=!1;Clazz.instantialize(this,arguments)},J.render,"RepaintManager",null,J.api.JmolRepaintManager);Clazz.prepareFields(c$,function(){this.bsTranslucent=JU.BS.newN(36)});Clazz.makeConstructor(c$,function(){});Clazz.overrideMethod(c$,"set",function(a,b){this.viewer=a;this.shapeManager=b},"J.viewer.Viewer,J.viewer.ShapeManager");Clazz.overrideMethod(c$,"isRepaintPending",function(){return this.repaintPending});Clazz.overrideMethod(c$,"pushHoldRepaint",function(){++this.holdRepaint},
"~S");Clazz.overrideMethod(c$,"popHoldRepaint",function(a,b){--this.holdRepaint;0>=this.holdRepaint&&(this.holdRepaint=0,a&&(this.repaintPending=!0,this.repaintNow(b)))},"~B,~S");Clazz.overrideMethod(c$,"requestRepaintAndWait",function(){"undefined"!=typeof Jmol&&Jmol._repaint&&Jmol._repaint(this.viewer.applet,!1);this.repaintDone()},"~S");Clazz.overrideMethod(c$,"repaintIfReady",function(a){if(this.repaintPending)return!1;this.repaintPending=!0;0==this.holdRepaint&&this.repaintNow(a);return!0},"~S");
$_M(c$,"repaintNow",($fz=function(){this.viewer.haveDisplay&&"undefined"!=typeof Jmol&&Jmol._repaint&&Jmol._repaint(this.viewer.applet,!0)},$fz.isPrivate=!0,$fz),"~S");Clazz.overrideMethod(c$,"repaintDone",function(){this.repaintPending=!1});Clazz.overrideMethod(c$,"clear",function(a){if(null!=this.renderers)if(0<=a)this.renderers[a]=null;else for(a=0;36>a;++a)this.renderers[a]=null},"~N");$_M(c$,"getRenderer",($fz=function(a){if(null!=this.renderers[a])return this.renderers[a];var b=J.viewer.JC.getShapeClassName(a,
!0)+"Renderer";try{var c=Class.forName(b).newInstance();c.setViewerG3dShapeID(this.viewer,a);return this.renderers[a]=c}catch(d){if(Clazz.exceptionOf(d,Exception))return J.util.Logger.errorEx("Could not instantiate renderer:"+b,d),null;throw d;}},$fz.isPrivate=!0,$fz),"~N");Clazz.overrideMethod(c$,"render",function(a,b,c,d){var e=this.viewer.getBoolean(603979934);try{a.renderBackground(null);if(c){this.bsTranslucent.clearAll();null!=d&&a.renderCrossHairs(d,this.viewer.getScreenWidth(),this.viewer.getScreenHeight(),
this.viewer.getNavigationOffset(),this.viewer.getNavigationDepthPercent());var f=this.viewer.getRubberBandSelection();null!=f&&a.setColix(this.viewer.getColixRubberband())&&a.drawRect(f.x,f.y,0,0,f.width,f.height)}null==this.renderers&&(this.renderers=Array(36));d=null;for(f=0;36>f&&a.currentlyRendering();++f){var g=this.shapeManager.getShape(f);null!=g&&(e&&(d="rendering "+J.viewer.JC.getShapeClassName(f,!1),J.util.Logger.startTimer(d)),(c||this.bsTranslucent.get(f))&&this.getRenderer(f).renderShape(a,
b,g)&&this.bsTranslucent.set(f),e&&J.util.Logger.checkTimer(d,!1))}a.renderAllStrings(null)}catch(h){if(Clazz.exceptionOf(h,Exception))this.viewer.isJS||h.printStackTrace(),J.util.Logger.error("rendering error? "+h);else throw h;}},"J.util.GData,J.modelset.ModelSet,~B,~A");Clazz.overrideMethod(c$,"renderExport",function(a,b,c){a=this.viewer.getBoolean(603979934);this.viewer.finalizeTransformParameters();this.shapeManager.finalizeAtoms(null,null);this.shapeManager.transformAtoms();var d=this.viewer.initializeExporter(c);
if(null==d)return J.util.Logger.error("Cannot export "+c.get("type")),null;d.renderBackground(d);null==this.renderers&&(this.renderers=Array(36));c=null;for(var e=0;36>e;++e){var f=this.shapeManager.getShape(e);null!=f&&(a&&(c="rendering "+J.viewer.JC.getShapeClassName(e,!1),J.util.Logger.startTimer(c)),this.getRenderer(e).renderShape(d,b,f),a&&J.util.Logger.checkTimer(c,!1))}d.renderAllStrings(d);return d.finalizeOutput()},"J.util.GData,J.modelset.ModelSet,java.util.Map")}),Clazz.declarePackage("J.shape"),
Clazz.load(["J.shape.Shape"],"J.shape.AtomShape","JU.ArrayUtil $.BS J.atomdata.RadiusData J.constant.EnumPalette $.EnumVdw J.util.BSUtil $.C".split(" "),function(){c$=Clazz.decorateAsClass(function(){this.mad=-1;this.paletteIDs=this.colixes=this.mads=null;this.atomCount=0;this.atoms=null;this.isActive=!1;this.monomerCount=0;this.rd=this.bsSizeDefault=null;Clazz.instantialize(this,arguments)},J.shape,"AtomShape",J.shape.Shape);$_M(c$,"getMonomers",function(){return null});Clazz.overrideMethod(c$,"initModelSet",
function(){this.atoms=this.modelSet.atoms;this.atomCount=this.modelSet.getAtomCount();null!=this.mads&&(this.mads=JU.ArrayUtil.arrayCopyShort(this.mads,this.atomCount));null!=this.colixes&&(this.colixes=JU.ArrayUtil.arrayCopyShort(this.colixes,this.atomCount));null!=this.paletteIDs&&(this.paletteIDs=JU.ArrayUtil.arrayCopyByte(this.paletteIDs,this.atomCount))});Clazz.overrideMethod(c$,"getSize",function(a){return null==this.mads?0:this.mads[a]},"~N");Clazz.overrideMethod(c$,"setSize",function(a,b){this.setSize2(a,
b)},"~N,JU.BS");$_M(c$,"setSize2",function(a,b){0==a?this.setSizeRD(null,b):(null==this.rd?this.rd=new J.atomdata.RadiusData(null,a,J.atomdata.RadiusData.EnumType.SCREEN,null):this.rd.value=a,this.setSizeRD(this.rd,b))},"~N,JU.BS");Clazz.overrideMethod(c$,"setSizeRD",function(a,b){if(null!=this.atoms){this.isActive=!0;null==this.bsSizeSet&&(this.bsSizeSet=new JU.BS);var c=null!=a&&0!=a.value,d=null==b,e=d?this.atomCount-1:b.nextSetBit(0);null==this.mads&&0<=e&&(this.mads=Clazz.newShortArray(this.atomCount,
0));for(;0<=e;e=d?e-1:b.nextSetBit(e+1))this.setSizeRD2(e,a,c)}},"J.atomdata.RadiusData,JU.BS");$_M(c$,"setSizeRD2",function(a,b,c){var d=this.atoms[a];this.mads[a]=d.calculateMad(this.viewer,b);this.bsSizeSet.setBitTo(a,c);d.setShapeVisibility(this.myVisibilityFlag,c)},"~N,J.atomdata.RadiusData,~B");$_M(c$,"setPropAS",function(a,b,c){if("color"===a){this.isActive=!0;var d=J.util.C.getColixO(b);a=J.constant.EnumPalette.pidOf(b);null==this.bsColixSet&&(this.bsColixSet=new JU.BS);for(b=c.nextSetBit(0);0<=
b;b=c.nextSetBit(b+1))this.setColixAndPalette(d,a,b)}else if("params"===a){this.isActive=!0;a=b[0];var e=b[1],f=b[2],g=new J.atomdata.RadiusData(null,0,J.atomdata.RadiusData.EnumType.FACTOR,J.constant.EnumVdw.AUTO);null==this.bsColixSet&&(this.bsColixSet=new JU.BS);null==this.bsSizeSet&&(this.bsSizeSet=new JU.BS);b=c.nextSetBit(0);null==this.mads&&0<=b&&(this.mads=Clazz.newShortArray(this.atomCount,0));for(var h=0;0<=b;b=c.nextSetBit(b+1),h++){d=null==a?0:a[h];0==d&&(d=0);var k=null==e?0:e[h];0.01<
k&&(d=J.util.C.getColixTranslucent3(d,!0,k));this.setColixAndPalette(d,J.constant.EnumPalette.UNKNOWN.id,b);null!=f&&(d=0<(g.value=f[h]),this.setSizeRD2(b,g,d))}}else if("translucency"===a){this.isActive=!0;a=b.equals("translucent");null==this.bsColixSet&&(this.bsColixSet=new JU.BS);for(b=c.nextSetBit(0);0<=b;b=c.nextSetBit(b+1))null==this.colixes&&(this.colixes=Clazz.newShortArray(this.atomCount,0),this.paletteIDs=Clazz.newByteArray(this.atomCount,0)),this.colixes[b]=J.util.C.getColixTranslucent3(this.colixes[b],
a,this.translucentLevel),a&&this.bsColixSet.set(b)}else"deleteModelAtoms"===a?(this.atoms=b[1],a=b[2],this.atomCount=this.modelSet.getAtomCount(),b=a[1],a=a[2],this.mads=JU.ArrayUtil.deleteElements(this.mads,b,a),this.colixes=JU.ArrayUtil.deleteElements(this.colixes,b,a),this.paletteIDs=JU.ArrayUtil.deleteElements(this.paletteIDs,b,a),J.util.BSUtil.deleteBits(this.bsSizeSet,c),J.util.BSUtil.deleteBits(this.bsColixSet,c)):this.setPropS(a,b,c)},"~S,~O,JU.BS");$_M(c$,"setColixAndPalette",function(a,
b,c){if(null==this.colixes||c>=this.colixes.length){if(0==a)return;this.colixes=JU.ArrayUtil.ensureLengthShort(this.colixes,c+1);this.paletteIDs=JU.ArrayUtil.ensureLengthByte(this.paletteIDs,c+1)}null==this.bsColixSet&&(this.bsColixSet=JU.BS.newN(this.atomCount));this.colixes[c]=a=this.getColixI(a,b,c);this.bsColixSet.setBitTo(c,0!=a);this.paletteIDs[c]=b},"~N,~N,~N");Clazz.overrideMethod(c$,"setModelClickability",function(){if(this.isActive)for(var a=this.atomCount;0<=--a;){var b=this.atoms[a];0==
(b.getShapeVisibilityFlags()&this.myVisibilityFlag)||this.modelSet.isAtomHidden(a)||b.setClickable(this.myVisibilityFlag)}});Clazz.overrideMethod(c$,"getShapeState",function(){return this.isActive?this.viewer.getAtomShapeState(this):""});$_M(c$,"getInfoAsString",function(){return null},"~N")}),Clazz.declarePackage("J.shape"),Clazz.load(["J.shape.AtomShape"],"J.shape.Balls",["JU.BS","J.constant.EnumPalette","J.util.C"],function(){c$=Clazz.declareType(J.shape,"Balls",J.shape.AtomShape);Clazz.overrideMethod(c$,
"setSizeRD",function(a,b){this.isActive=!0;null==this.bsSizeSet&&(this.bsSizeSet=new JU.BS);for(var c=Math.min(this.atoms.length,b.length()),d=b.nextSetBit(0);0<=d&&d<c;d=b.nextSetBit(d+1))this.atoms[d].setMadAtom(this.viewer,a),this.bsSizeSet.set(d)},"J.atomdata.RadiusData,JU.BS");Clazz.overrideMethod(c$,"setProperty",function(a,b,c){if("color"===a){var d=J.util.C.getColixO(b);0==d&&(d=2);null==this.bsColixSet&&(this.bsColixSet=new JU.BS);var e=J.constant.EnumPalette.pidOf(b);for(a=c.nextSetBit(0);0<=
a;a=c.nextSetBit(a+1)){var f=this.atoms[a];f.setColixAtom(this.getColixA(d,e,f));this.bsColixSet.setBitTo(a,2!=d||e!=J.constant.EnumPalette.NONE.id);f.setPaletteID(e)}}else if("colorValues"===a){if(0!=b.length){null==this.bsColixSet&&(this.bsColixSet=new JU.BS);var g=0,e=null;for(a=c.nextSetBit(0);0<=a&&!(g>=b.length);a=c.nextSetBit(a+1))e=Integer.$valueOf(b[g++]),d=J.util.C.getColixO(e),0==d&&(d=2),e=J.constant.EnumPalette.pidOf(e),f=this.atoms[a],f.setColixAtom(this.getColixA(d,e,f)),this.bsColixSet.setBitTo(a,
2!=d||e!=J.constant.EnumPalette.NONE.id),f.setPaletteID(e)}}else if("colors"===a){b=b[0];null==this.bsColixSet&&(this.bsColixSet=new JU.BS);for(a=c.nextSetBit(0);0<=a;a=c.nextSetBit(a+1))a>=b.length||(this.atoms[a].setColixAtom(b[a]),this.atoms[a].setPaletteID(J.constant.EnumPalette.UNKNOWN.id),this.bsColixSet.set(a))}else if("translucency"===a){b=b.equals("translucent");null==this.bsColixSet&&(this.bsColixSet=new JU.BS);for(a=c.nextSetBit(0);0<=a;a=c.nextSetBit(a+1))this.atoms[a].setTranslucent(b,
this.translucentLevel),b&&this.bsColixSet.set(a)}else a.startsWith("ball")&&(a=a.substring(4).intern()),this.setPropAS(a,b,c)},"~S,~O,JU.BS");Clazz.overrideMethod(c$,"setModelClickability",function(){for(var a=this.viewer.getDeletedAtoms(),b=this.atomCount;0<=--b;){var c=this.atoms[b];c.setClickable(0);null!=a&&a.get(b)||(0==(c.getShapeVisibilityFlags()&this.myVisibilityFlag)||this.modelSet.isAtomHidden(b))||c.setClickable(this.myVisibilityFlag)}});Clazz.overrideMethod(c$,"setVisibilityFlags",function(a){for(var b=
this.viewer.getBoolean(603979922),c=this.viewer.getDeletedAtoms(),d=this.atomCount;0<=--d;){var e=this.atoms[d],f=e.getShapeVisibilityFlags(),f=f&-2&~this.myVisibilityFlag;e.setShapeVisibilityFlags(f);null!=c&&c.get(d)||!b&&1==e.getElementNumber()||(f=e.getModelIndex(),a.get(f)&&(e.setShapeVisibility(1,!0),0!=e.madAtom&&!this.modelSet.isAtomHidden(d)&&e.setShapeVisibility(this.myVisibilityFlag,!0)))}},"JU.BS");Clazz.overrideMethod(c$,"getShapeState",function(){return this.viewer.getShapeState(this)})}),
Clazz.declarePackage("J.shape"),Clazz.load(["J.shape.Shape","JU.P3i"],"J.shape.Sticks","java.util.Hashtable JU.BS $.P3 J.constant.EnumPalette J.util.BSUtil $.C $.Escape $.JmolEdge".split(" "),function(){c$=Clazz.decorateAsClass(function(){this.myMask=0;this.reportAll=!1;this.ptXY=this.selectedBonds=this.bsOrderSet=null;Clazz.instantialize(this,arguments)},J.shape,"Sticks",J.shape.Shape);Clazz.prepareFields(c$,function(){this.ptXY=new JU.P3i});$_M(c$,"initShape",function(){Clazz.superCall(this,J.shape.Sticks,
"initShape",[]);this.myMask=1023;this.reportAll=!1});Clazz.overrideMethod(c$,"setSize",function(a,b){if(2147483647==a)this.selectedBonds=J.util.BSUtil.copy(b);else if(-2147483648==a)null==this.bsOrderSet&&(this.bsOrderSet=new JU.BS),this.bsOrderSet.or(b);else{null==this.bsSizeSet&&(this.bsSizeSet=new JU.BS);for(var c=null!=this.selectedBonds?this.modelSet.getBondIterator(this.selectedBonds):this.modelSet.getBondIteratorForType(this.myMask,b);c.hasNext();)this.bsSizeSet.set(c.nextIndex()),c.next().setMad(a)}},
"~N,JU.BS");Clazz.overrideMethod(c$,"setProperty",function(a,b,c){if("type"===a)this.myMask=b.intValue();else if("reportAll"===a)this.reportAll=!0;else if("reset"===a)this.selectedBonds=this.bsColixSet=this.bsSizeSet=this.bsOrderSet=null;else if("bondOrder"===a){null==this.bsOrderSet&&(this.bsOrderSet=new JU.BS);a=b.shortValue();for(c=null!=this.selectedBonds?this.modelSet.getBondIterator(this.selectedBonds):this.modelSet.getBondIteratorForType(65535,c);c.hasNext();)this.bsOrderSet.set(c.nextIndex()),
c.next().setOrder(a)}else if("color"===a)if(null==this.bsColixSet&&(this.bsColixSet=new JU.BS),a=J.util.C.getColixO(b),b=Clazz.instanceOf(b,J.constant.EnumPalette)?b:null,b===J.constant.EnumPalette.TYPE||b===J.constant.EnumPalette.ENERGY){var d=b===J.constant.EnumPalette.ENERGY;for(c=null!=this.selectedBonds?this.modelSet.getBondIterator(this.selectedBonds):this.modelSet.getBondIteratorForType(this.myMask,c);c.hasNext();){this.bsColixSet.set(c.nextIndex());var e=c.next();d?(e.setColix(this.getColixB(a,
b.id,e)),e.setPaletteID(b.id)):e.setColix(J.util.C.getColix(J.util.JmolEdge.getArgbHbondType(e.order)))}}else{if(!(2==a&&b!==J.constant.EnumPalette.CPK))for(c=null!=this.selectedBonds?this.modelSet.getBondIterator(this.selectedBonds):this.modelSet.getBondIteratorForType(this.myMask,c);c.hasNext();)b=c.nextIndex(),e=c.next(),e.setColix(a),this.bsColixSet.setBitTo(b,0!=a&&2!=a)}else if("translucency"===a){null==this.bsColixSet&&(this.bsColixSet=new JU.BS);a=b.equals("translucent");for(c=null!=this.selectedBonds?
this.modelSet.getBondIterator(this.selectedBonds):this.modelSet.getBondIteratorForType(this.myMask,c);c.hasNext();)this.bsColixSet.set(c.nextIndex()),c.next().setTranslucent(a,this.translucentLevel)}else"deleteModelAtoms"!==a&&this.setPropS(a,b,c)},"~S,~O,JU.BS");Clazz.overrideMethod(c$,"getProperty",function(a){return a.equals("selectionState")?null!=this.selectedBonds?"select BONDS "+J.util.Escape.eBS(this.selectedBonds)+"\n":"":a.equals("sets")?[this.bsOrderSet,this.bsSizeSet,this.bsColixSet]:
null},"~S,~N");Clazz.overrideMethod(c$,"setModelClickability",function(){for(var a=this.modelSet.bonds,b=this.modelSet.bondCount;0<=--b;){var c=a[b];0==(c.getShapeVisibilityFlags()&this.myVisibilityFlag)||(this.modelSet.isAtomHidden(c.getAtomIndex1())||this.modelSet.isAtomHidden(c.getAtomIndex2()))||(c.getAtom1().setClickable(this.myVisibilityFlag),c.getAtom2().setClickable(this.myVisibilityFlag))}});Clazz.overrideMethod(c$,"getShapeState",function(){return this.viewer.getBondState(this,this.bsOrderSet,
this.reportAll)});Clazz.overrideMethod(c$,"checkObjectHovered",function(a,b,c){var d=new JU.P3;a=this.findPickedBond(a,b,c,d);if(null==a)return!1;this.viewer.highlightBond(a.index,!0);return!0},"~N,~N,JU.BS");Clazz.overrideMethod(c$,"checkObjectClicked",function(a,b,c,d){c=new JU.P3;a=this.findPickedBond(a,b,d,c);if(null==a)return null;b=a.getAtom1().modelIndex;d=a.getIdentity();var e=new java.util.Hashtable;e.put("pt",c);e.put("index",Integer.$valueOf(a.index));e.put("modelIndex",Integer.$valueOf(b));
e.put("model",this.viewer.getModelNumberDotted(b));e.put("type","bond");e.put("info",d);this.viewer.setStatusAtomPicked(-3,'["bond","'+a.getIdentity()+'",'+c.x+","+c.y+","+c.z+"]");return e},"~N,~N,~N,JU.BS,~B");$_M(c$,"findPickedBond",($fz=function(a,b,c,d){c=100;this.gdata.isAntialiased()&&(a<<=1,b<<=1,c<<=1);for(var e=null,f=new JU.P3,g=this.modelSet.bonds,h=this.modelSet.bondCount;0<=--h;){var k=g[h];if(0!=k.getShapeVisibilityFlags()){var l=k.getAtom1(),m=k.getAtom2();if(l.isVisible(0)&&m.isVisible(0)){f.setT(l);
f.add(m);f.scale(0.5);var n=this.coordinateInRange(a,b,f,c,this.ptXY);0<=n&&(l=1*(this.ptXY.x-l.screenX)/(m.screenX-l.screenX),0.4>l||0.6<l||(c=n,e=k,d.setT(f)))}}}return e},$fz.isPrivate=!0,$fz),"~N,~N,JU.BS,JU.P3");Clazz.defineStatics(c$,"MAX_BOND_CLICK_DISTANCE_SQUARED",100)}),Clazz.declarePackage("J.shape"),Clazz.load(["J.shape.Shape"],"J.shape.FontShape",null,function(){c$=Clazz.decorateAsClass(function(){this.font3d=this.myType=null;Clazz.instantialize(this,arguments)},J.shape,"FontShape",J.shape.Shape);
Clazz.overrideMethod(c$,"initShape",function(){this.translucentAllowed=!1});$_M(c$,"setPropFS",function(a,b){"font"===a&&(this.font3d=b)},"~S,~O")}),Clazz.declarePackage("J.shape"),Clazz.load(["J.shape.FontShape"],"J.shape.FontLineShape",null,function(){c$=Clazz.decorateAsClass(function(){this.tickInfos=null;this.mad=0;Clazz.instantialize(this,arguments)},J.shape,"FontLineShape",J.shape.FontShape);Clazz.prepareFields(c$,function(){this.tickInfos=Array(4)});$_M(c$,"setPropFLS",function(a,b){"tickInfo"===
a?null==b.ticks?b.type.equals(" ")?this.tickInfos[0]=this.tickInfos[1]=this.tickInfos[2]=this.tickInfos[3]=null:this.tickInfos["xyz".indexOf(b.type)+1]=null:this.tickInfos["xyz".indexOf(b.type)+1]=b:this.setPropFS(a,b)},"~S,~O");Clazz.overrideMethod(c$,"getShapeState",function(){var a=this.viewer.getFontState(this.myType,this.font3d);return null==this.tickInfos?a:this.viewer.getFontLineShapeState(a,this.myType,this.tickInfos)})}),Clazz.declarePackage("J.shape"),Clazz.load(["J.shape.FontShape"],"J.shape.Frank",
["J.i18n.GT"],function(){c$=Clazz.decorateAsClass(function(){this.frankString="Jmol";this.baseFont3d=this.currentMetricsFont3d=null;this.dy=this.dx=this.y=this.x=this.frankDescent=this.frankAscent=this.frankWidth=0;Clazz.instantialize(this,arguments)},J.shape,"Frank",J.shape.FontShape);$_M(c$,"initShape",function(){Clazz.superCall(this,J.shape.Frank,"initShape",[]);this.myType="frank";this.baseFont3d=this.font3d=this.gdata.getFont3DFSS("SansSerif","Plain",16);this.calcMetrics()});Clazz.overrideMethod(c$,
"setProperty",function(a,b){this.setPropFS(a,b)},"~S,~O,JU.BS");Clazz.overrideMethod(c$,"wasClicked",function(a,b){var c=this.viewer.getScreenWidth(),d=this.viewer.getScreenHeight();return 0<c&&0<d&&a>c-this.frankWidth-4&&b>d-this.frankAscent-4},"~N,~N");Clazz.overrideMethod(c$,"checkObjectHovered",function(a,b){if(!this.viewer.getShowFrank()||!this.wasClicked(a,b)||!this.viewer.menuEnabled())return!1;this.gdata.isDisplayAntialiased()&&!this.viewer.isSingleThreaded&&(a<<=1,b<<=1);this.viewer.hoverOnPt(a,
b,J.i18n.GT._("Click for menu..."),null,null);return!0},"~N,~N,JU.BS");$_M(c$,"calcMetrics",function(){this.viewer.isJS?this.frankString="JSmol":this.viewer.isSignedApplet()&&(this.frankString="Jmol_S");this.font3d!==this.currentMetricsFont3d&&(this.currentMetricsFont3d=this.font3d,this.frankWidth=this.font3d.stringWidth(this.frankString),this.frankDescent=this.font3d.getDescent(),this.frankAscent=this.font3d.getAscent())});$_M(c$,"getFont",function(a){this.font3d=this.gdata.getFont3DScaled(this.baseFont3d,
a);this.calcMetrics()},"~N");Clazz.overrideMethod(c$,"getShapeState",function(){return this.viewer.getFontState(this.myType,this.font3d)});Clazz.defineStatics(c$,"defaultFontName","SansSerif","defaultFontStyle","Plain","defaultFontSize",16,"frankMargin",4)}),Clazz.declarePackage("J.render"),Clazz.load(null,"J.render.ShapeRenderer",["J.viewer.JC"],function(){c$=Clazz.decorateAsClass(function(){this.shape=this.modelSet=this.g3d=this.viewer=null;this.exportType=this.madEnd=this.madMid=this.madBeg=this.mad=
this.colix=this.shapeID=this.myVisibilityFlag=0;this.isExport=!1;Clazz.instantialize(this,arguments)},J.render,"ShapeRenderer");$_M(c$,"initRenderer",function(){});$_M(c$,"setViewerG3dShapeID",function(a,b){this.viewer=a;this.shapeID=b;this.myVisibilityFlag=J.viewer.JC.getShapeVisibilityFlag(b);this.initRenderer()},"J.viewer.Viewer,~N");$_M(c$,"renderShape",function(a,b,c){this.g3d=a;this.modelSet=b;this.shape=c;this.exportType=a.getExportType();this.isExport=0!=this.exportType;a=this.render();this.exportType=
0;this.isExport=!1;return a},"J.api.JmolRendererInterface,J.modelset.ModelSet,J.shape.Shape")}),Clazz.declarePackage("J.render"),Clazz.load(["J.render.ShapeRenderer"],"J.render.BallsRenderer",["J.shape.Shape"],function(){c$=Clazz.declareType(J.render,"BallsRenderer",J.render.ShapeRenderer);Clazz.overrideMethod(c$,"render",function(){var a=!1;if(this.isExport||this.viewer.checkMotionRendering(1141899265))for(var b=this.modelSet.atoms,c=this.shape.colixes,d=this.viewer.getRenderableBitSet(),e=d.nextSetBit(0);0<=
e;e=d.nextSetBit(e+1)){var f=b[e];0<f.screenDiameter&&0!=(f.getShapeVisibilityFlags()&this.myVisibilityFlag)&&(this.g3d.setColix(null==c?f.getColix():J.shape.Shape.getColix(c,e,f))?this.g3d.drawAtom(f):a=!0)}return a})}),Clazz.declarePackage("J.render"),Clazz.load(["J.render.ShapeRenderer","JU.P3","$.P3i","$.V3"],"J.render.FontLineShapeRenderer",["java.lang.Float","J.constant.EnumAxesMode","J.util.Txt"],function(){c$=Clazz.decorateAsClass(function(){this.imageFontScaling=0;this.tickInfo=this.vectorT3=
this.vectorT2=this.vectorT=this.pointT3=this.pointT2=this.pointT=this.s2=this.s1=this.pt2i=this.pt1i=this.pt0i=this.font3d=this.atomD=this.atomC=this.atomB=this.atomA=null;this.draw000=!0;this.width=0;this.endcap=3;this.colixB=this.colixA=0;this.dotsOrDashes=!1;this.dashDots=null;this.asLineOnly=!1;Clazz.instantialize(this,arguments)},J.render,"FontLineShapeRenderer",J.render.ShapeRenderer);Clazz.prepareFields(c$,function(){this.pt0i=new JU.P3i;this.pt1i=new JU.P3i;this.pt2i=new JU.P3i;this.s1=new JU.P3i;
this.s2=new JU.P3i;this.pointT=new JU.P3;this.pointT2=new JU.P3;this.pointT3=new JU.P3;this.vectorT=new JU.V3;this.vectorT2=new JU.V3;this.vectorT3=new JU.V3});$_M(c$,"getDiameter",function(a,b){var c;c=20<b;switch(this.exportType){case 1:c=c?b:Clazz.doubleToInt(Math.floor(1E3*this.viewer.unscaleToScreen(a,2*b)));break;default:c?c=Clazz.floatToInt(this.viewer.scaleToScreen(a,b)):(this.g3d.isAntialiased()&&(b+=b),c=b)}return c},"~N,~N");$_M(c$,"renderLine",function(a,b,c,d,e,f){d.set(Clazz.doubleToInt(Math.floor(a.x)),
Clazz.doubleToInt(Math.floor(a.y)),Clazz.doubleToInt(Math.floor(a.z)));e.set(Clazz.doubleToInt(Math.floor(b.x)),Clazz.doubleToInt(Math.floor(b.y)),Clazz.doubleToInt(Math.floor(b.z)));0>c?this.g3d.drawDottedLine(d,e):this.g3d.fillCylinder(this.endcap,c,d,e);f&&null!=this.tickInfo&&(this.atomA.screenX=d.x,this.atomA.screenY=d.y,this.atomA.screenZ=d.z,this.atomB.screenX=e.x,this.atomB.screenY=e.y,this.atomB.screenZ=e.z,this.drawTicks(this.atomA,this.atomB,c,!0))},"JU.P3,JU.P3,~N,JU.P3i,JU.P3i,~B");$_M(c$,
"drawTicks",function(a,b,c,d){Float.isNaN(this.tickInfo.first)&&(this.tickInfo.first=0);this.drawTicks2(a,b,this.tickInfo.ticks.x,8,c,!d?null:null==this.tickInfo.tickLabelFormats?["%0.2f"]:this.tickInfo.tickLabelFormats);this.drawTicks2(a,b,this.tickInfo.ticks.y,4,c,null);this.drawTicks2(a,b,this.tickInfo.ticks.z,2,c,null)},"J.util.Point3fi,J.util.Point3fi,~N,~B");$_M(c$,"drawTicks2",($fz=function(a,b,c,d,e,f){if(0!=c&&(this.g3d.isAntialiased()&&(d*=2),this.vectorT2.set(b.screenX,b.screenY,0),this.vectorT.set(a.screenX,
a.screenY,0),this.vectorT2.sub(this.vectorT),!(50>this.vectorT2.length()))){var g=this.tickInfo.signFactor;this.vectorT.setT(b);this.vectorT.sub(a);var h=this.vectorT.length();if(null!=this.tickInfo.scale)if(Float.isNaN(this.tickInfo.scale.x)){var k=this.viewer.getUnitCellInfo(0);Float.isNaN(k)||this.vectorT.set(this.vectorT.x/k,this.vectorT.y/this.viewer.getUnitCellInfo(1),this.vectorT.z/this.viewer.getUnitCellInfo(2))}else this.vectorT.set(this.vectorT.x*this.tickInfo.scale.x,this.vectorT.y*this.tickInfo.scale.y,
this.vectorT.z*this.tickInfo.scale.z);k=this.vectorT.length()+1E-4*c;if(!(k<c)){this.vectorT.scale(c/k*h/k);b=(b.screenZ-a.screenZ)/(k/c);k+=this.tickInfo.first;h=Clazz.doubleToInt(Math.floor(this.tickInfo.first/c))*c-this.tickInfo.first;this.pointT.scaleAdd2(h/c,this.vectorT,a);h+=this.tickInfo.first;a=a.screenZ;0>e&&(e=1);this.vectorT2.set(-this.vectorT2.y,this.vectorT2.x,0);this.vectorT2.scale(d/this.vectorT2.length());d=this.tickInfo.reference;null==d?(this.pointT3.setT(this.viewer.getBoundBoxCenter()),
this.viewer.getAxesMode()===J.constant.EnumAxesMode.BOUNDBOX&&(this.pointT3.x+=1,this.pointT3.y+=1,this.pointT3.z+=1)):this.pointT3.setT(d);this.viewer.transformPtScr(this.pointT3,this.pt2i);d=0.2>Math.abs(this.vectorT2.x/this.vectorT2.y);for(var l=!d,m=!d&&0>this.vectorT2.x,n=null!=f&&0<f.length,q,p,r=Array(1),s=this.draw000?0:-1;h<k;){if(h>=this.tickInfo.first&&(this.pointT2.setT(this.pointT),this.viewer.transformPt3f(this.pointT2,this.pointT2),this.drawLine(Clazz.doubleToInt(Math.floor(this.pointT2.x)),
Clazz.doubleToInt(Math.floor(this.pointT2.y)),Clazz.floatToInt(a),q=Clazz.doubleToInt(Math.floor(this.pointT2.x+this.vectorT2.x)),p=Clazz.doubleToInt(Math.floor(this.pointT2.y+this.vectorT2.y)),Clazz.floatToInt(a),e),n&&(this.draw000||0!=h))){r[0]=Float.$valueOf(0==h?0:h*g);var t=J.util.Txt.sprintf(f[s%f.length],"f",r);this.drawString(q,p,Clazz.floatToInt(a),4,m,d,l,Clazz.doubleToInt(Math.floor(this.pointT2.y)),t)}this.pointT.add(this.vectorT);h+=c;a+=b;s++}}}},$fz.isPrivate=!0,$fz),"J.util.Point3fi,J.util.Point3fi,~N,~N,~N,~A");
$_M(c$,"drawLine",function(a,b,c,d,e,f,g){return this.drawLine2(a,b,c,d,e,f,g)},"~N,~N,~N,~N,~N,~N,~N");$_M(c$,"drawLine2",function(a,b,c,d,e,f,g){this.pt0i.set(a,b,c);this.pt1i.set(d,e,f);if(this.dotsOrDashes)null!=this.dashDots&&this.drawDashed(a,b,c,d,e,f,this.dashDots);else{if(0>g)return this.g3d.drawDashedLine(4,2,this.pt0i,this.pt1i),1;this.g3d.fillCylinder(2,g,this.pt0i,this.pt1i)}return Clazz.doubleToInt((g+1)/2)},"~N,~N,~N,~N,~N,~N,~N");$_M(c$,"drawString",function(a,b,c,d,e,f,g,h,k){if(null!=
k){var l=this.font3d.stringWidth(k),m=this.font3d.getAscent();a=e?a-(Clazz.doubleToInt(d/2)+2+l):f?a-(Clazz.doubleToInt(d/2)+2+Clazz.doubleToInt(l/2)):a+(Clazz.doubleToInt(d/2)+2);e=b;e=g?e+Clazz.doubleToInt(m/2):0==h||h<b?e+m:e-Clazz.doubleToInt(d/2);b=c-d-2;1>b&&(b=1);this.g3d.drawString(k,this.font3d,a,e,b,b,0)}},"~N,~N,~N,~N,~B,~B,~B,~N,~S");$_M(c$,"drawDashed",function(a,b,c,d,e,f,g){if(!(null==g||0>this.width)){var h=g[0];d-=a;e-=b;f-=c;var k=0,l=g===J.render.FontLineShapeRenderer.ndots,m=l||
g===J.render.FontLineShapeRenderer.sixdots;if(m){var n=(d*d+e*e)/(this.width*this.width);l?(h=Math.sqrt(n)/1.5,k=Clazz.floatToInt(h)+3):8>n?g=J.render.FontLineShapeRenderer.twodots:32>n&&(g=J.render.FontLineShapeRenderer.fourdots)}var n=g[1],q=g[2],p=this.colixA,r=0==q?this.colixB:this.colixA;0==k&&(k=g.length);for(var s=0,t=3;t<k;t++){var s=l?s+1:g[t],u=Clazz.doubleToInt(Math.floor(a+d*s/h)),v=Clazz.doubleToInt(Math.floor(b+e*s/h)),y=Clazz.doubleToInt(Math.floor(c+f*s/h));if(m)this.s1.set(u,v,y),
t==n?this.g3d.setColix(this.colixA):t==q&&this.g3d.setColix(this.colixB),this.g3d.fillSphereI(this.width,this.s1);else{t==n&&(p=this.colixB);s=g[++t];t==q&&(r=this.colixB);var A=Clazz.doubleToInt(Math.floor(a+d*s/h)),B=Clazz.doubleToInt(Math.floor(b+e*s/h)),w=Clazz.doubleToInt(Math.floor(c+f*s/h));this.fillCylinder(p,r,2,this.width,u,v,y,A,B,w)}}}},"~N,~N,~N,~N,~N,~N,~A");$_M(c$,"fillCylinder",function(a,b,c,d,e,f,g,h,k,l){this.asLineOnly?this.g3d.drawLine(a,b,e,f,g,h,k,l):this.g3d.fillCylinderXYZ(a,
b,c,!this.isExport||1==this.mad?d:this.mad,e,f,g,h,k,l)},"~N,~N,~N,~N,~N,~N,~N,~N,~N,~N");Clazz.defineStatics(c$,"dashes",[12,0,0,2,5,7,10],"hDashes",[10,7,6,1,3,4,6,7,9],"ndots",[0,3,1E3],"sixdots",[12,3,6,1,3,5,7,9,11],"fourdots",[13,3,5,2,5,8,11],"twodots",[12,3,4,3,9])}),Clazz.declarePackage("J.render"),Clazz.load(["J.render.FontLineShapeRenderer","JU.BS","$.P3","$.V3"],"J.render.SticksRenderer",["java.lang.Float","J.constant.EnumPalette","J.modelset.Bond","J.util.C","$.JmolEdge"],function(){c$=
Clazz.decorateAsClass(function(){this.showMultipleBonds=!1;this.modeMultipleBond=this.multipleBondRadiusFactor=this.multipleBondSpacing=0;this.isCartesianExport=!1;this.endcaps=0;this.hbondsSolid=this.bondsBackbone=this.hbondsBackbone=this.ssbondsBackbone=!1;this.bond=this.b=this.a=null;this.bondOrder=this.mag2d=this.dy=this.dx=this.zB=this.yB=this.xB=this.zA=this.yA=this.xA=0;this.slabByAtom=this.slabbing=this.isAntialiased=this.wireframeOnly=!1;this.bsForPass2=this.p2=this.p1=this.z=this.y=this.x=
null;this.isPass2=!1;this.dyStep=this.dxStep=this.yAxis2=this.xAxis2=this.yAxis1=this.xAxis1=0;Clazz.instantialize(this,arguments)},J.render,"SticksRenderer",J.render.FontLineShapeRenderer);Clazz.prepareFields(c$,function(){this.x=new JU.V3;this.y=new JU.V3;this.z=new JU.V3;this.p1=new JU.P3;this.p2=new JU.P3;this.bsForPass2=JU.BS.newN(64)});Clazz.overrideMethod(c$,"render",function(){var a=this.modelSet.bonds;if(null==a)return!1;(this.isPass2=this.g3d.isPass2())||this.bsForPass2.clearAll();this.slabbing=
this.viewer.getSlabEnabled();this.slabByAtom=this.viewer.getBoolean(603979938);this.endcaps=3;this.dashDots=this.viewer.getBoolean(603979889)?J.render.FontLineShapeRenderer.sixdots:J.render.FontLineShapeRenderer.dashes;this.multipleBondSpacing=this.viewer.getFloat(570425369);this.isCartesianExport=1==this.exportType;0==this.multipleBondSpacing&&this.isCartesianExport&&(this.multipleBondSpacing=0.2);this.multipleBondRadiusFactor=this.viewer.getFloat(570425368);this.modeMultipleBond=this.viewer.getModeMultipleBond();
this.showMultipleBonds=0!=this.multipleBondSpacing&&0!=this.modeMultipleBond&&this.viewer.getBoolean(603979928);this.wireframeOnly=!this.viewer.checkMotionRendering(1678770178);this.ssbondsBackbone=this.viewer.getBoolean(603979952);this.hbondsBackbone=this.viewer.getBoolean(603979852);this.bondsBackbone=(new Boolean(this.hbondsBackbone|this.ssbondsBackbone)).valueOf();this.hbondsSolid=this.viewer.getBoolean(603979854);this.isAntialiased=this.g3d.isAntialiased();var b=!1;if(!this.isExport&&this.isPass2)for(var c=
this.bsForPass2.nextSetBit(0);0<=c;c=this.bsForPass2.nextSetBit(c+1))this.bond=a[c],this.renderBond();else for(c=this.modelSet.bondCount;0<=--c;)this.bond=a[c],0!=(this.bond.getShapeVisibilityFlags()&this.myVisibilityFlag)&&this.renderBond()&&(b=!0,this.bsForPass2.set(c));return b});$_M(c$,"renderBond",($fz=function(){var a,b;this.a=a=this.bond.getAtom1();this.b=b=this.bond.getAtom2();var c=this.bond.order&-131073;this.bondsBackbone&&(this.ssbondsBackbone&&0!=(c&256)?(this.a=this.a.getGroup().getLeadAtomOr(this.a),
this.b=this.b.getGroup().getLeadAtomOr(this.b)):this.hbondsBackbone&&J.modelset.Bond.isOrderH(c)&&(this.a=this.a.getGroup().getLeadAtomOr(this.a),this.b=this.b.getGroup().getLeadAtomOr(this.b)));if(!this.isPass2&&(!this.a.isInFrame()||!this.b.isInFrame()||!this.g3d.isInDisplayRange(this.a.screenX,this.a.screenY)||!this.g3d.isInDisplayRange(this.b.screenX,this.b.screenY)||this.modelSet.isAtomHidden(this.a.getIndex())||this.modelSet.isAtomHidden(this.b.getIndex()))||this.slabbing&&(this.g3d.isClippedZ(this.a.screenZ)&&
this.g3d.isClippedZ(this.b.screenZ)||this.slabByAtom&&(this.g3d.isClippedZ(this.a.screenZ)||this.g3d.isClippedZ(this.b.screenZ))))return!1;this.zA=this.a.screenZ;this.zB=this.b.screenZ;if(1==this.zA||1==this.zB)return!1;this.colixA=a.getColix();this.colixB=b.getColix();2==((this.colix=this.bond.colix)&-30721)?(this.colix&=30720,this.colixA=J.util.C.getColixInherited(this.colix|this.viewer.getColixAtomPalette(a,J.constant.EnumPalette.CPK.id),this.colixA),this.colixB=J.util.C.getColixInherited(this.colix|
this.viewer.getColixAtomPalette(b,J.constant.EnumPalette.CPK.id),this.colixB)):(this.colixA=J.util.C.getColixInherited(this.colix,this.colixA),this.colixB=J.util.C.getColixInherited(this.colix,this.colixB));a=!1;if(!this.isExport&&!this.isPass2){b=!J.util.C.isColixTranslucent(this.colixA);var d=!J.util.C.isColixTranslucent(this.colixB);if(!b||!d){if(!b&&!d&&!a)return this.g3d.setColix(!b?this.colixA:this.colixB),!0;a=!0}}this.bondOrder=c&-131073;if(0==(this.bondOrder&224)&&(0!=(this.bondOrder&256)&&
(this.bondOrder&=-257),0!=(this.bondOrder&1023)&&(!this.showMultipleBonds||2==this.modeMultipleBond&&500<this.mad||0!=(this.bondOrder&65536))))this.bondOrder=1;b=0;switch(this.bondOrder){case 1:case 2:case 3:case 4:break;case 17:case 513:this.bondOrder=1;b=513==c?0:1;break;case 515:case 514:this.bondOrder=2;b=515==c?this.getAromaticDottedBondMask():0;break;default:0!=(this.bondOrder&224)?(this.bondOrder=J.util.JmolEdge.getPartialBondOrder(c),b=J.util.JmolEdge.getPartialBondDotted(c)):J.modelset.Bond.isOrderH(this.bondOrder)?
(this.bondOrder=1,this.hbondsSolid||(b=-1)):32768==this.bondOrder&&(this.bondOrder=1)}this.xA=this.a.screenX;this.yA=this.a.screenY;this.xB=this.b.screenX;this.yB=this.b.screenY;this.mad=this.bond.mad;0<this.multipleBondRadiusFactor&&1<this.bondOrder&&(this.mad*=this.multipleBondRadiusFactor);this.dx=this.xB-this.xA;this.dy=this.yB-this.yA;this.width=Clazz.floatToInt(this.viewer.scaleToScreen(Clazz.doubleToInt((this.zA+this.zB)/2),this.mad));this.wireframeOnly&&0<this.width&&(this.width=1);if(!this.isCartesianExport&&
(this.asLineOnly=1>=this.width)&&this.isAntialiased)this.width=3,this.asLineOnly=!1;switch(b){case -1:this.drawDashed(this.xA,this.yA,this.zA,this.xB,this.yB,this.zB,J.render.FontLineShapeRenderer.hDashes);break;default:this.drawBond(b)}return a},$fz.isPrivate=!0,$fz));$_M(c$,"drawBond",($fz=function(a){if(this.isCartesianExport&&1==this.bondOrder)this.g3d.drawBond(this.a,this.b,this.colixA,this.colixB,this.endcaps,this.mad,-1);else{var b=0==this.dx&&0==this.dy;if(!b||!this.asLineOnly){var c=1<this.bondOrder&&
0<this.multipleBondSpacing,d=c&&(null!=this.viewer.getHybridizationAndAxes(this.a.index,this.z,this.x,"pz")||null!=this.viewer.getHybridizationAndAxes(this.b.index,this.z,this.x,"pz"))&&!Float.isNaN(this.x.x);if(b&&!c){a=Clazz.doubleToInt(this.width/8)+3;a=this.width+a;c=this.yA-Clazz.doubleToInt((this.bondOrder-1)*a/2);do this.fillCylinder(this.colixA,this.colixA,this.endcaps,this.width,this.xA,c,this.zA,this.xA,c,this.zA),c+=a;while(0<--this.bondOrder)}else if(b=0!=(a&1),1==this.bondOrder)b?this.drawDashed(this.xA,
this.yA,this.zA,this.xB,this.yB,this.zB,this.dashDots):this.fillCylinder(this.colixA,this.colixB,this.endcaps,this.width,this.xA,this.yA,this.zA,this.xB,this.yB,this.zB);else if(c){d||this.z.set(3.141592653589793,2.718281828459045,8.539734222673566);this.x.sub2(this.b,this.a);this.y.cross(this.x,this.z);this.y.normalize();Float.isNaN(this.y.x)&&(this.z.set(3.141592653589793,2.718281828459045,8.539734222673566),this.y.cross(this.x,this.z),this.y.cross(this.y,this.x),this.y.normalize());this.y.scale(this.multipleBondSpacing);
this.x.setT(this.y);this.x.scale((this.bondOrder-1)/2);this.p1.sub2(this.a,this.x);for(this.p2.sub2(this.b,this.x);;){this.isCartesianExport&&!b?this.g3d.drawBond(this.p1,this.p2,this.colixA,this.colixB,this.endcaps,this.mad,-2):(this.viewer.transformPtScr(this.p1,this.s1),this.viewer.transformPtScr(this.p2,this.s2),b?this.drawDashed(this.s1.x,this.s1.y,this.s1.z,this.s2.x,this.s2.y,this.s2.z,this.dashDots):this.fillCylinder(this.colixA,this.colixB,this.endcaps,this.width,this.s1.x,this.s1.y,this.s1.z,
this.s2.x,this.s2.y,this.s2.z),a>>=1,b=0!=(a&1));if(0>=--this.bondOrder)break;this.p1.add(this.y);this.p2.add(this.y);this.stepAxisCoordinates()}}else{this.mag2d=Math.round(Math.sqrt(this.dx*this.dx+this.dy*this.dy));for(this.resetAxisCoordinates();;){0!=(a&1)?this.drawDashed(this.xAxis1,this.yAxis1,this.zA,this.xAxis2,this.yAxis2,this.zB,this.dashDots):this.fillCylinder(this.colixA,this.colixB,this.endcaps,this.width,this.xAxis1,this.yAxis1,this.zA,this.xAxis2,this.yAxis2,this.zB);a>>=1;if(0>=--this.bondOrder)break;
this.stepAxisCoordinates()}}}}},$fz.isPrivate=!0,$fz),"~N");$_M(c$,"resetAxisCoordinates",($fz=function(){var a=this.mag2d>>3;-1!=this.multipleBondSpacing&&0>this.multipleBondSpacing&&(a*=-this.multipleBondSpacing);a=this.width+a;this.dxStep=Clazz.doubleToInt(a*this.dy/this.mag2d);this.dyStep=Clazz.doubleToInt(a*-this.dx/this.mag2d);this.xAxis1=this.xA;this.yAxis1=this.yA;this.xAxis2=this.xB;this.yAxis2=this.yB;a=this.bondOrder-1;this.xAxis1-=Clazz.doubleToInt(this.dxStep*a/2);this.yAxis1-=Clazz.doubleToInt(this.dyStep*
a/2);this.xAxis2-=Clazz.doubleToInt(this.dxStep*a/2);this.yAxis2-=Clazz.doubleToInt(this.dyStep*a/2)},$fz.isPrivate=!0,$fz));$_M(c$,"stepAxisCoordinates",($fz=function(){this.xAxis1+=this.dxStep;this.yAxis1+=this.dyStep;this.xAxis2+=this.dxStep;this.yAxis2+=this.dyStep},$fz.isPrivate=!0,$fz));$_M(c$,"getAromaticDottedBondMask",($fz=function(){var a=this.b.findAromaticNeighbor(this.a.getIndex());return null==a?1:0>this.dx*(a.screenY-this.yA)-this.dy*(a.screenX-this.xA)?2:1},$fz.isPrivate=!0,$fz))}),
Clazz.declarePackage("J.util"),Clazz.load(null,"J.util.SimpleUnitCell",["java.lang.Float","JU.ArrayUtil","$.M4","$.V3"],function(){c$=Clazz.decorateAsClass(function(){this.matrixFractionalToCartesian=this.matrixCartesianToFractional=this.notionalUnitcell=null;this.dimension=this.c_=this.b_=this.a_=this.cB_=this.cA_=this.volume=this.sinGamma=this.cosGamma=this.sinBeta=this.cosBeta=this.sinAlpha=this.cosAlpha=this.gamma=this.beta=this.alpha=this.c=this.b=this.a=this.nc=this.nb=this.na=0;this.matrixFtoCAbsolute=
this.matrixCtoFAbsolute=null;Clazz.instantialize(this,arguments)},J.util,"SimpleUnitCell");$_M(c$,"isSupercell",function(){return 1<this.na||1<this.nb||1<this.nc});c$.isValid=$_M(c$,"isValid",function(a){return null!=a&&(0<a[0]||14<a.length&&!Float.isNaN(a[14]))},"~A");Clazz.makeConstructor(c$,function(){});c$.newA=$_M(c$,"newA",function(a){var b=new J.util.SimpleUnitCell;b.set(a);return b},"~A");$_M(c$,"set",function(a){if(J.util.SimpleUnitCell.isValid(a)){this.notionalUnitcell=JU.ArrayUtil.arrayCopyF(a,
a.length);this.a=a[0];this.b=a[1];this.c=a[2];this.alpha=a[3];this.beta=a[4];this.gamma=a[5];this.na=Math.max(1,25<=a.length&&!Float.isNaN(a[22])?Clazz.floatToInt(a[22]):1);this.nb=Math.max(1,25<=a.length&&!Float.isNaN(a[23])?Clazz.floatToInt(a[23]):1);this.nc=Math.max(1,25<=a.length&&!Float.isNaN(a[24])?Clazz.floatToInt(a[24]):1);if(0>=this.a){var b=JU.V3.new3(a[6],a[7],a[8]),c=JU.V3.new3(a[9],a[10],a[11]),d=JU.V3.new3(a[12],a[13],a[14]);this.a=b.length();this.b=c.length();this.c=d.length();if(0==
this.a)return;0==this.b?this.b=this.c=-1:0==this.c&&(this.c=-1);this.alpha=0>this.b||0>this.c?90:c.angle(d)/0.017453292;this.beta=0>this.c?90:b.angle(d)/0.017453292;this.gamma=0>this.b?90:b.angle(c)/0.017453292;0>this.c&&(a=JU.ArrayUtil.arrayCopyF(a,-1),0>this.b&&(c.set(0,0,1),c.cross(c,b),0.001>c.length()&&c.set(0,1,0),c.normalize(),a[9]=c.x,a[10]=c.y,a[11]=c.z),0>this.c&&(d.cross(b,c),d.normalize(),a[12]=d.x,a[13]=d.y,a[14]=d.z))}this.a*=this.na;0>=this.b?this.dimension=this.b=this.c=1:0>=this.c?
(this.c=1,this.b*=this.nb,this.dimension=2):(this.b*=this.nb,this.c*=this.nc,this.dimension=3);this.cosAlpha=Math.cos(0.017453292*this.alpha);this.sinAlpha=Math.sin(0.017453292*this.alpha);this.cosBeta=Math.cos(0.017453292*this.beta);this.sinBeta=Math.sin(0.017453292*this.beta);this.cosGamma=Math.cos(0.017453292*this.gamma);this.sinGamma=Math.sin(0.017453292*this.gamma);b=Math.sqrt(this.sinAlpha*this.sinAlpha+this.sinBeta*this.sinBeta+this.sinGamma*this.sinGamma+2*this.cosAlpha*this.cosBeta*this.cosGamma-
2);this.volume=this.a*this.b*this.c*b;this.cA_=(this.cosAlpha-this.cosBeta*this.cosGamma)/this.sinGamma;this.cB_=b/this.sinGamma;this.a_=this.b*this.c*this.sinAlpha/this.volume;this.b_=this.a*this.c*this.sinBeta/this.volume;this.c_=this.a*this.b*this.sinGamma/this.volume;if(21<a.length&&!Float.isNaN(a[21])){b=Clazz.newFloatArray(16,0);for(c=0;16>c;c++){switch(c%4){case 0:d=this.na;break;case 1:d=this.nb;break;case 2:d=this.nc;break;default:d=1}b[c]=a[6+c]*d}this.matrixCartesianToFractional=JU.M4.newA(b);
this.matrixFractionalToCartesian=new JU.M4;this.matrixFractionalToCartesian.invertM(this.matrixCartesianToFractional)}else 14<a.length&&!Float.isNaN(a[14])?(b=this.matrixFractionalToCartesian=new JU.M4,b.setColumn4(0,a[6]*this.na,a[7]*this.na,a[8]*this.na,0),b.setColumn4(1,a[9]*this.nb,a[10]*this.nb,a[11]*this.nb,0),b.setColumn4(2,a[12]*this.nc,a[13]*this.nc,a[14]*this.nc,0)):(b=this.matrixFractionalToCartesian=new JU.M4,b.setColumn4(0,this.a,0,0,0),b.setColumn4(1,this.b*this.cosGamma,this.b*this.sinGamma,
0,0),b.setColumn4(2,this.c*this.cosBeta,this.c*(this.cosAlpha-this.cosBeta*this.cosGamma)/this.sinGamma,this.volume/(this.a*this.b*this.sinGamma),0)),b.setColumn4(3,0,0,0,1),this.matrixCartesianToFractional=new JU.M4,this.matrixCartesianToFractional.invertM(this.matrixFractionalToCartesian);this.matrixCtoFAbsolute=this.matrixCartesianToFractional;this.matrixFtoCAbsolute=this.matrixFractionalToCartesian}},"~A");$_M(c$,"toSupercell",function(a){a.x/=this.na;a.y/=this.nb;a.z/=this.nc;return a},"JU.P3");
$_M(c$,"toCartesian",function(a,b){null!=this.matrixFractionalToCartesian&&(b?this.matrixFtoCAbsolute:this.matrixFractionalToCartesian).transform(a)},"JU.T3,~B");$_M(c$,"toFractional",function(a,b){null!=this.matrixCartesianToFractional&&(b?this.matrixCtoFAbsolute:this.matrixCartesianToFractional).transform(a)},"JU.T3,~B");$_M(c$,"isPolymer",function(){return 1==this.dimension});$_M(c$,"isSlab",function(){return 2==this.dimension});$_M(c$,"getNotionalUnitCell",function(){return this.notionalUnitcell});
$_M(c$,"getUnitCellAsArray",function(a){var b=this.matrixFractionalToCartesian;return a?[b.m00,b.m10,b.m20,b.m01,b.m11,b.m21,b.m02,b.m12,b.m22]:[this.a,this.b,this.c,this.alpha,this.beta,this.gamma,b.m00,b.m10,b.m20,b.m01,b.m11,b.m21,b.m02,b.m12,b.m22,this.dimension,this.volume]},"~B");$_M(c$,"getInfo",function(a){switch(a){case 0:return this.a;case 1:return this.b;case 2:return this.c;case 3:return this.alpha;case 4:return this.beta;case 5:return this.gamma;case 6:return this.dimension}return NaN},
"~N");c$.ijkToPoint3f=$_M(c$,"ijkToPoint3f",function(a,b,c){c-=5;b.x=Clazz.doubleToInt(a/100)+c;b.y=Clazz.doubleToInt(a%100/10)+c;b.z=a%10+c},"~N,JU.P3,~N");Clazz.defineStatics(c$,"toRadians",0.017453292,"INFO_DIMENSIONS",6,"INFO_GAMMA",5,"INFO_BETA",4,"INFO_ALPHA",3,"INFO_C",2,"INFO_B",1,"INFO_A",0)}),Clazz.declarePackage("J.render"),Clazz.load(["J.render.ShapeRenderer"],"J.render.FrankRenderer",["J.util.C"],function(){c$=Clazz.declareType(J.render,"FrankRenderer",J.render.ShapeRenderer);Clazz.overrideMethod(c$,
"render",function(){var a=this.shape,b=this.viewer.getBooleanProperty("allowKeyStrokes"),c=this.viewer.getBoolean(603979883);this.colix=c?20:this.viewer.isSignedApplet()?b||this.viewer.isJS&&!this.viewer.isWebGL?5:10:b?7:12;if(this.isExport||!this.viewer.getShowFrank())return!1;if(!this.g3d.setColix(J.util.C.getColixTranslucent3(this.colix,this.g3d.haveTranslucentObjects(),0.5)))return!0;b=this.viewer.getImageFontScaling();a.getFont(b);var b=Clazz.floatToInt(a.frankWidth+4*b),d=a.frankDescent;this.g3d.drawStringNoSlab(a.frankString,
a.font3d,this.g3d.getRenderWidth()-b,this.g3d.getRenderHeight()-d,0,0);c&&this.g3d.fillRect(0,0,0,0,2*d,Clazz.doubleToInt(3*b/2));return!1})}),Clazz.declarePackage("J.adapter.readers.molxyz"),Clazz.load(["J.adapter.smarter.AtomSetCollectionReader"],"J.adapter.readers.molxyz.MolReader",["java.lang.Exception","$.Float","J.adapter.smarter.Atom","J.api.JmolAdapter","J.util.Logger"],function(){c$=Clazz.decorateAsClass(function(){this.isV3000=this.is2D=!1;this.dimension=null;this.allow2D=!0;Clazz.instantialize(this,
arguments)},J.adapter.readers.molxyz,"MolReader",J.adapter.smarter.AtomSetCollectionReader);Clazz.overrideMethod(c$,"initializeReader",function(){this.is2D=this.checkFilterKey("2D")});Clazz.overrideMethod(c$,"checkLine",function(){var a=this.line.startsWith("$MDL");if(a&&(this.discardLinesUntilStartsWith("$HDR"),this.readLine(),null==this.line))return J.util.Logger.warn("$HDR not found in MDL RG file"),this.continuing=!1;if(this.doGetModel(++this.modelNumber,null))return this.processMolSdHeader(),
this.processCtab(a),this.isLastModel(this.modelNumber)?this.continuing=!1:!0;this.discardLinesUntilStartsWith("$$$$");return!0});$_M(c$,"readUserData",($fz=function(a){if(!this.isV3000)for(;null!=this.readLine()&&0!=this.line.indexOf("$$$$");)if(this.line.toUpperCase().contains("_PARTIAL_CHARGES"))try{for(var b=this.atomSetCollection.getAtoms(),c=this.parseIntStr(this.readLine());0<=--c;){var d=J.adapter.smarter.AtomSetCollectionReader.getTokensStr(this.readLine()),e=this.parseIntStr(d[0])+a-1,f=
this.parseFloatStr(d[1]);Float.isNaN(f)||(b[e].partialCharge=f)}}catch(g){if(Clazz.exceptionOf(g,Exception))break;else throw g;}},$fz.isPrivate=!0,$fz),"~N");Clazz.overrideMethod(c$,"finalizeReader",function(){this.finalizeReaderMR()});$_M(c$,"finalizeReaderMR",function(){this.is2D&&this.set2D();this.isTrajectory=!1;this.finalizeReaderASCR()});$_M(c$,"processMolSdHeader",($fz=function(){var a,b=this.line;a=""+(this.line+"\n");this.atomSetCollection.setCollectionName(this.line);this.readLine();if(null!=
this.line){a+=this.line+"\n";this.dimension=22>this.line.length?"3D":this.line.substring(20,22);if(!this.allow2D&&this.dimension.equals("2D"))throw new Exception("File is 2D, not 3D");this.atomSetCollection.setAtomSetCollectionAuxiliaryInfo("dimension",this.dimension);this.readLine();null!=this.line&&(a+=this.line+"\n",J.util.Logger.info(a),this.checkCurrentLineForScript(),this.atomSetCollection.setAtomSetCollectionAuxiliaryInfo("fileHeader",a),this.newAtomSet(b))}},$fz.isPrivate=!0,$fz));$_M(c$,
"processCtab",($fz=function(a){var b=null;a&&this.discardLinesUntilStartsWith("$CTAB");if(this.isV3000=null!=this.readLine()&&0<=this.line.indexOf("V3000"))this.is2D=this.dimension.equals("2D"),this.discardLinesUntilContains("COUNTS"),b=this.getTokens();if(null!=this.line){a=this.isV3000?this.parseIntStr(b[3]):this.parseIntRange(this.line,0,3);var b=this.isV3000?this.parseIntStr(b[4]):this.parseIntRange(this.line,3,6),c=this.atomSetCollection.getAtomCount();this.readAtoms(a);this.readBonds(b);this.readUserData(c);
this.isV3000&&this.discardLinesUntilContains("END CTAB");this.applySymmetryAndSetTrajectory()}},$fz.isPrivate=!0,$fz),"~B");$_M(c$,"readAtoms",($fz=function(a){this.isV3000&&this.discardLinesUntilContains("BEGIN ATOM");for(var b=0;b<a;++b){this.readLine();var c,d,e,f,g=0,h=0,k=b+1;if(this.isV3000){this.checkLineContinuation();var l=this.getTokens(),k=this.parseIntStr(l[2]);c=l[3];if(c.equals("*"))continue;d=this.parseFloatStr(l[4]);e=this.parseFloatStr(l[5]);f=this.parseFloatStr(l[6]);for(var m=7;m<
l.length;m++){var n=l[m].toUpperCase();n.startsWith("CHG=")?g=this.parseIntStr(l[m].substring(4)):n.startsWith("MASS=")&&(h=this.parseIntStr(l[m].substring(5)))}1<h&&c.equals("H")&&(h=1-h)}else if(c=34<this.line.length?this.line.substring(31,34).trim():this.line.substring(31).trim(),d=this.parseFloatRange(this.line,0,10),e=this.parseFloatRange(this.line,10,20),f=this.parseFloatRange(this.line,20,30),39<=this.line.length&&(l=this.parseIntRange(this.line,36,39),1<=l&&7>=l&&(g=4-l),l=this.parseIntRange(this.line,
34,36),0!=l&&-3<=l&&4>=l))switch(h=J.api.JmolAdapter.getNaturalIsotope(J.api.JmolAdapter.getElementNumber(c)),h){case 0:break;case 1:h=-l;break;default:h+=l}switch(h){case 0:break;case -1:c="D";break;case -2:c="T";break;default:c=h+c}this.is2D&&0!=f&&(this.is2D=!1);h=new J.adapter.smarter.Atom;h.elementSymbol=c;h.formalCharge=g;this.setAtomCoordXYZ(h,d,e,f);h.atomSerial=k;this.atomSetCollection.addAtomWithMappedSerialNumber(h)}this.isV3000&&this.discardLinesUntilContains("END ATOM")},$fz.isPrivate=
!0,$fz),"~N");$_M(c$,"checkLineContinuation",($fz=function(){for(;this.line.endsWith("-");){var a=this.line;this.readLine();this.line=a+this.line}},$fz.isPrivate=!0,$fz));$_M(c$,"readBonds",($fz=function(a){this.isV3000&&this.discardLinesUntilContains("BEGIN BOND");for(var b=0;b<a;++b){this.readLine();var c,d,e,f=0;if(this.isV3000){this.checkLineContinuation();var g=this.getTokens();e=this.parseIntStr(g[3]);c=this.parseIntStr(g[4]);d=this.parseIntStr(g[5]);for(var h=6;h<g.length;h++){var k=g[h].toUpperCase();
if(k.startsWith("CFG=")){f=this.parseIntStr(g[h].substring(4));break}else if(k.startsWith("ENDPTS=")&&!(0>this.line.indexOf("ATTACH=ALL"))){g=J.adapter.smarter.AtomSetCollectionReader.getTokensAt(this.line,this.line.indexOf("ENDPTS=")+8);h=this.parseIntStr(g[0]);e=this.fixOrder(e,0);for(k=1;k<=h;k++)d=this.parseIntStr(g[k]),this.atomSetCollection.addNewBondWithMappedSerialNumbers(c,d,e);break}}}else c=this.parseIntRange(this.line,0,3),d=this.parseIntRange(this.line,3,6),e=this.parseIntRange(this.line,
6,9),this.is2D&&(1==e&&12<=this.line.length)&&(f=this.parseIntRange(this.line,9,12));e=this.fixOrder(e,f);this.atomSetCollection.addNewBondWithMappedSerialNumbers(c,d,e)}this.isV3000&&this.discardLinesUntilContains("END BOND")},$fz.isPrivate=!0,$fz),"~N");$_M(c$,"fixOrder",($fz=function(a,b){switch(a){default:case 0:case -10:return 1;case 1:switch(b){case 1:return 1025;case 3:case 6:return 1041}break;case 2:case 3:break;case 4:return 515;case 5:return 66;case 6:return 513;case 7:return 514;case 8:case 9:return 33}return a},
$fz.isPrivate=!0,$fz),"~N,~N")}),Clazz.declarePackage("J.adapter.readers.molxyz"),Clazz.load(["J.adapter.smarter.AtomSetCollectionReader"],"J.adapter.readers.molxyz.XyzReader",["java.lang.Float","J.util.Logger"],function(){c$=Clazz.declareType(J.adapter.readers.molxyz,"XyzReader",J.adapter.smarter.AtomSetCollectionReader);Clazz.overrideMethod(c$,"checkLine",function(){var a=this.parseIntStr(this.line);if(-2147483648==a)return this.continuing=!1;this.vibrationNumber=++this.modelNumber;if(0>=this.desiredVibrationNumber?
this.doGetModel(this.modelNumber,null):this.doGetVibration(this.vibrationNumber)){this.readLine();this.checkCurrentLineForScript();this.atomSetCollection.newAtomSet();var b=this.line;this.readAtoms(a);this.applySymmetryAndSetTrajectory();this.atomSetCollection.setAtomSetName(b);if(this.isLastModel(this.modelNumber))return this.continuing=!1}else this.skipAtomSet(a);this.discardLinesUntilNonBlank();return!1});Clazz.overrideMethod(c$,"finalizeReader",function(){this.isTrajectory=!1;this.finalizeReaderASCR()});
$_M(c$,"skipAtomSet",($fz=function(a){for(this.readLine();0<=--a;)this.readLine()},$fz.isPrivate=!0,$fz),"~N");$_M(c$,"readAtoms",($fz=function(a){for(var b=0;b<a;++b){this.readLine();var c=this.getTokens();if(4>c.length)J.util.Logger.warn("line cannot be read for XYZ atom data: "+this.line);else{var d=this.atomSetCollection.addNewAtom();this.setElementAndIsotope(d,c[0]);d.x=this.parseFloatStr(c[1]);d.y=this.parseFloatStr(c[2]);d.z=this.parseFloatStr(c[3]);if(Float.isNaN(d.x)||Float.isNaN(d.y)||Float.isNaN(d.z))J.util.Logger.warn("line cannot be read for XYZ atom data: "+
this.line),d.set(0,0,0);var e=4;this.setAtomCoord(d);switch(c.length){case 4:continue;case 5:case 6:case 8:case 9:if(0<=c[4].indexOf("."))d.partialCharge=this.parseFloatStr(c[4]);else{var f=this.parseIntStr(c[4]);-2147483648!=f&&(d.formalCharge=f)}switch(c.length){case 5:continue;case 6:d.radius=this.parseFloatStr(c[5]);continue;case 9:d.atomSerial=this.parseIntStr(c[8])}e++;default:var f=this.parseFloatStr(c[e++]),g=this.parseFloatStr(c[e++]),c=this.parseFloatStr(c[e++]);if(Float.isNaN(f)||Float.isNaN(g)||
Float.isNaN(c))continue;this.atomSetCollection.addVibrationVector(d.index,f,g,c)}}}},$fz.isPrivate=!0,$fz),"~N")}),Clazz.declarePackage("J.awtjs"),Clazz.load(["J.awtjs2d.Platform"],"J.awtjs.Platform",["J.awtjs.Font","$.Image"],function(){c$=Clazz.declareType(J.awtjs,"Platform",J.awtjs2d.Platform);Clazz.overrideMethod(c$,"allocateRgbImage",function(a,b,c,d,e){return J.awtjs.Image.allocateRgbImage(a,b,c,d,e)},"~N,~N,~A,~N,~B,~B");Clazz.overrideMethod(c$,"disposeGraphics",function(a){J.awtjs.Image.disposeGraphics(a)},
"~O");Clazz.overrideMethod(c$,"drawImage",function(a,b,c,d,e,f){J.awtjs.Image.drawImage(a,b,c,d,e,f)},"~O,~O,~N,~N,~N,~N");Clazz.overrideMethod(c$,"grabPixels",function(){return null},"~O,~N,~N,~A,~N,~N");Clazz.overrideMethod(c$,"drawImageToBuffer",function(a,b,c,d,e,f){return J.awtjs.Image.drawImageToBuffer(a,b,c,d,e,f)},"~O,~O,~O,~N,~N,~N");Clazz.overrideMethod(c$,"getTextPixels",function(a,b,c,d,e,f,g){return J.awtjs.Image.getTextPixels(a,b,c,d,e,f,g)},"~S,J.util.JmolFont,~O,~O,~N,~N,~N");Clazz.overrideMethod(c$,
"flushImage",function(a){J.awtjs.Image.flush(a)},"~O");Clazz.overrideMethod(c$,"getGraphics",function(a){return J.awtjs.Image.getGraphics(a)},"~O");Clazz.overrideMethod(c$,"getStaticGraphics",function(a,b){return J.awtjs.Image.getStaticGraphics(a,b)},"~O,~B");Clazz.overrideMethod(c$,"newBufferedImage",function(a,b,c){return J.awtjs.Image.newBufferedImage(a,b,c)},"~O,~N,~N");Clazz.overrideMethod(c$,"newOffScreenImage",function(a,b){return J.awtjs.Image.newBufferedImage(a,b)},"~N,~N");Clazz.overrideMethod(c$,
"fontStringWidth",function(a,b,c){return J.awtjs.Font.stringWidth(a,b,c)},"J.util.JmolFont,~O,~S");Clazz.overrideMethod(c$,"getFontAscent",function(a){return J.awtjs.Font.getAscent(a)},"~O");Clazz.overrideMethod(c$,"getFontDescent",function(a){return J.awtjs.Font.getDescent(a)},"~O");Clazz.overrideMethod(c$,"getFontMetrics",function(a,b){return J.awtjs.Font.getFontMetrics(b,a)},"J.util.JmolFont,~O");Clazz.overrideMethod(c$,"newFont",function(a,b,c,d){return J.awtjs.Font.newFont(a,b,c,d)},"~S,~B,~B,~N")}),
Clazz.declarePackage("J.awtjs"),c$=Clazz.declareType(J.awtjs,"Font"),c$.newFont=$_M(c$,"newFont",function(){return null},"~S,~B,~B,~N"),c$.getFontMetrics=$_M(c$,"getFontMetrics",function(){return null},"~O,~O"),c$.getAscent=$_M(c$,"getAscent",function(){return 0},"~O"),c$.getDescent=$_M(c$,"getDescent",function(){return 0},"~O"),c$.stringWidth=$_M(c$,"stringWidth",function(){return 0},"J.util.JmolFont,~O,~S"),Clazz.declarePackage("J.awtjs"),c$=Clazz.declareType(J.awtjs,"Image"),c$.grabPixels=$_M(c$,
"grabPixels",function(){return null},"~O,~N,~N"),c$.drawImageToBuffer=$_M(c$,"drawImageToBuffer",function(){return null},"~O,~O,~O,~N,~N,~N"),c$.getTextPixels=$_M(c$,"getTextPixels",function(){return null},"~S,J.util.JmolFont,~O,~O,~N,~N,~N"),c$.newBufferedImage=$_M(c$,"newBufferedImage",function(){return null},"~O,~N,~N"),c$.newBufferedImage=$_M(c$,"newBufferedImage",function(){return null},"~N,~N"),c$.allocateRgbImage=$_M(c$,"allocateRgbImage",function(){return null},"~N,~N,~A,~N,~B"),c$.getStaticGraphics=
$_M(c$,"getStaticGraphics",function(){return null},"~O,~B"),c$.getGraphics=$_M(c$,"getGraphics",function(){return null},"~O"),c$.drawImage=$_M(c$,"drawImage",function(){},"~O,~O,~N,~N,~N,~N"),c$.flush=$_M(c$,"flush",function(){},"~O"),c$.disposeGraphics=$_M(c$,"disposeGraphics",function(){},"~O"))})();Clazz.coreLoaded=!0;
