Merge branch 'master' of https://source.jalview.org/git/jalviewjs.git
[jalviewjs.git] / site / j2s / java / io / StringBufferInputStream.js
index b31995d..e2ae0b9 100644 (file)
@@ -1,59 +1,59 @@
-Clazz.load(["java.io.InputStream"],"java.io.StringBufferInputStream",["java.lang.ArrayIndexOutOfBoundsException","$.NullPointerException"],function(){\r
-c$=Clazz.decorateAsClass(function(){\r
-this.buffer=null;\r
-this.count=0;\r
-this.pos=0;\r
-Clazz.instantialize(this,arguments);\r
-},java.io,"StringBufferInputStream",java.io.InputStream);\r
-Clazz.makeConstructor(c$,\r
-function(str){\r
-Clazz.superConstructor(this,java.io.StringBufferInputStream,[]);\r
-if(str!=null){\r
-this.buffer=str;\r
-this.count=str.length;\r
-}else{\r
-throw new NullPointerException();\r
-}},"~S");\r
-Clazz.overrideMethod(c$,"available",\r
-function(){\r
-return this.count-this.pos;\r
-});\r
-Clazz.defineMethod(c$,"read",\r
-function(){\r
-return this.pos<this.count?(this.buffer.charAt(this.pos++)).charCodeAt(0)&0xFF:-1;\r
-});\r
-Clazz.defineMethod(c$,"read",\r
-function(b,offset,length){\r
-if(this.pos>=this.count){\r
-return-1;\r
-}if(b!=null){\r
-if(0<=offset&&offset<=b.length&&0<=length&&length<=b.length-offset){\r
-if(length==0){\r
-return 0;\r
-}var copylen=this.count-this.pos<length?this.count-this.pos:length;\r
-for(var i=0;i<copylen;i++){\r
-b[offset+i]=(this.buffer.charAt(this.pos+i)).charCodeAt(0);\r
-}\r
-this.pos+=copylen;\r
-return copylen;\r
-}throw new ArrayIndexOutOfBoundsException();\r
-}throw new NullPointerException(("K0047"));\r
-},"~A,~N,~N");\r
-Clazz.overrideMethod(c$,"reset",\r
-function(){\r
-this.pos=0;\r
-});\r
-Clazz.overrideMethod(c$,"skip",\r
-function(n){\r
-if(n<=0){\r
-return 0;\r
-}var numskipped;\r
-if(this.count-this.pos<n){\r
-numskipped=this.count-this.pos;\r
-this.pos=this.count;\r
-}else{\r
-numskipped=n;\r
-this.pos+=n;\r
-}return numskipped;\r
-},"~N");\r
-});\r
+Clazz.load(["java.io.InputStream"],"java.io.StringBufferInputStream",["java.lang.ArrayIndexOutOfBoundsException","$.NullPointerException"],function(){
+c$=Clazz.decorateAsClass(function(){
+this.buffer=null;
+this.count=0;
+this.pos=0;
+Clazz.instantialize(this,arguments);
+},java.io,"StringBufferInputStream",java.io.InputStream);
+Clazz.makeConstructor(c$,
+function(str){
+Clazz.superConstructor(this,java.io.StringBufferInputStream,[]);
+if(str!=null){
+this.buffer=str;
+this.count=str.length;
+}else{
+throw new NullPointerException();
+}},"~S");
+Clazz.overrideMethod(c$,"available",
+function(){
+return this.count-this.pos;
+});
+Clazz.defineMethod(c$,"read",
+function(){
+return this.pos<this.count?(this.buffer.charAt(this.pos++)).charCodeAt(0)&0xFF:-1;
+});
+Clazz.defineMethod(c$,"read",
+function(b,offset,length){
+if(this.pos>=this.count){
+return-1;
+}if(b!=null){
+if(0<=offset&&offset<=b.length&&0<=length&&length<=b.length-offset){
+if(length==0){
+return 0;
+}var copylen=this.count-this.pos<length?this.count-this.pos:length;
+for(var i=0;i<copylen;i++){
+b[offset+i]=(this.buffer.charAt(this.pos+i)).charCodeAt(0);
+}
+this.pos+=copylen;
+return copylen;
+}throw new ArrayIndexOutOfBoundsException();
+}throw new NullPointerException(("K0047"));
+},"~A,~N,~N");
+Clazz.overrideMethod(c$,"reset",
+function(){
+this.pos=0;
+});
+Clazz.overrideMethod(c$,"skip",
+function(n){
+if(n<=0){
+return 0;
+}var numskipped;
+if(this.count-this.pos<n){
+numskipped=this.count-this.pos;
+this.pos=this.count;
+}else{
+numskipped=n;
+this.pos+=n;
+}return numskipped;
+},"~N");
+});