Re: Global matches, eq, @matches = ($str=~/('[^']+')/g)

"Daniel F. Savarese" <[email protected]> Fri, 25 Apr 2003 17:46:41 -0400
Newsgroups gmane.comp.jakarta.oro.user
Message-ID <[email protected]>
In message <000b01c30b71$1bf11420$0d00a8c0@luckplane>, "Dean Arnold" writes:
>It doesn't appear that Perl5Util supports the global match (except in
...
>If I'm overlooking some method that already does this, I'd appreciate
>any pointers...

This is what the PatternMatcherInput class is for.  For example:

Perl5Util perl;
PatternMatcherInput input;

....

while(perl.match("m/foo/imsx", input)) {
  MatchResult match = perl.getMatch();
...
}

See the documentation for Perl5Util.match(String, PatternMatcherInput) and
org.apache.oro.text.regex.PatternMatcherInput for more details.

daniel