// // This software is now distributed according to // the Lesser Gnu Public License. Please see // http://www.gnu.org/copyleft/lesser.txt for // the details. // -- Happy Computing! // package com.stevesoft.pat; import java.util.Hashtable; /** This class implements the (?@<>) syntax that matches a balanced parenthesis. Not in perl 5. */ class Group extends Pattern { char op,cl; Group(char opi,char cli) { op = opi; cl = cli; } public int matchInternal(int pos,Pthings pt) { int i,count=1; if(pos < pt.src.length()) if(!Masked(pos,pt) && pt.src.charAt(pos) != op) return -1; for(i=pos+1;i