X-Git-Url: http://source.jalview.org/gitweb/?p=jalviewjs.git;a=blobdiff_plain;f=site%2Fj2s%2Fcom%2Fstevesoft%2Fpat%2FGroup.js;h=89fdd10d4d49b68086e09f2f6344db48f5c1a654;hp=a9ebd1bf5d9c3d3a04aa11653bf5589cc8a5418d;hb=b9b7a352eee79b7764c3b09c9d19663075061d8c;hpb=7301a2415adab88038b291fc54caeeb3a5a47a44 diff --git a/site/j2s/com/stevesoft/pat/Group.js b/site/j2s/com/stevesoft/pat/Group.js index a9ebd1b..89fdd10 100644 --- a/site/j2s/com/stevesoft/pat/Group.js +++ b/site/j2s/com/stevesoft/pat/Group.js @@ -1,48 +1,48 @@ -Clazz.declarePackage ("com.stevesoft.pat"); -Clazz.load (["com.stevesoft.pat.Pattern"], "com.stevesoft.pat.Group", ["com.stevesoft.pat.patInt"], function () { -c$ = Clazz.decorateAsClass (function () { -this.op = '\0'; -this.cl = '\0'; -Clazz.instantialize (this, arguments); -}, com.stevesoft.pat, "Group", com.stevesoft.pat.Pattern); -Clazz.makeConstructor (c$, -function (opi, cli) { -Clazz.superConstructor (this, com.stevesoft.pat.Group, []); -this.op = opi; -this.cl = cli; -}, "~S,~S"); -Clazz.overrideMethod (c$, "matchInternal", -function (pos, pt) { -var i; -var count = 1; -if (pos < pt.src.length ()) { -if (!this.Masked (pos, pt) && pt.src.charAt (pos) != this.op) { -return -1; -}}for (i = pos + 1; i < pt.src.length (); i++) { -var c = pt.src.charAt (i); -var b = !this.Masked (i, pt); -if (b && c == '\\') { -i++; -} else { -if (b && c == this.cl) { -count--; -}if (count == 0) { -return this.nextMatch (i + 1, pt); -}if (b && c == this.op) { -count++; -}}} -return -1; -}, "~N,com.stevesoft.pat.Pthings"); -Clazz.overrideMethod (c$, "toString", -function () { -return "(?@" + this.op + this.cl + ")" + this.nextString (); -}); -Clazz.overrideMethod (c$, "minChars", -function () { -return new com.stevesoft.pat.patInt (2); -}); -Clazz.overrideMethod (c$, "clone1", -function (h) { -return new com.stevesoft.pat.Group (this.op, this.cl); -}, "java.util.Hashtable"); -}); +Clazz.declarePackage ("com.stevesoft.pat"); +Clazz.load (["com.stevesoft.pat.Pattern"], "com.stevesoft.pat.Group", ["com.stevesoft.pat.patInt"], function () { +c$ = Clazz.decorateAsClass (function () { +this.op = '\0'; +this.cl = '\0'; +Clazz.instantialize (this, arguments); +}, com.stevesoft.pat, "Group", com.stevesoft.pat.Pattern); +Clazz.makeConstructor (c$, +function (opi, cli) { +Clazz.superConstructor (this, com.stevesoft.pat.Group, []); +this.op = opi; +this.cl = cli; +}, "~S,~S"); +Clazz.overrideMethod (c$, "matchInternal", +function (pos, pt) { +var i; +var count = 1; +if (pos < pt.src.length ()) { +if (!this.Masked (pos, pt) && pt.src.charAt (pos) != this.op) { +return -1; +}}for (i = pos + 1; i < pt.src.length (); i++) { +var c = pt.src.charAt (i); +var b = !this.Masked (i, pt); +if (b && c == '\\') { +i++; +} else { +if (b && c == this.cl) { +count--; +}if (count == 0) { +return this.nextMatch (i + 1, pt); +}if (b && c == this.op) { +count++; +}}} +return -1; +}, "~N,com.stevesoft.pat.Pthings"); +Clazz.overrideMethod (c$, "toString", +function () { +return "(?@" + this.op + this.cl + ")" + this.nextString (); +}); +Clazz.overrideMethod (c$, "minChars", +function () { +return new com.stevesoft.pat.patInt (2); +}); +Clazz.overrideMethod (c$, "clone1", +function (h) { +return new com.stevesoft.pat.Group (this.op, this.cl); +}, "java.util.Hashtable"); +});