public class ManualRegexIterator extends ManualIterator<StringValue> implements RegexIterator
RegexIterator.MatchHandler
ATOMIZING, GROUNDED, LAST_POSITION_FINDER, LOOKAHEAD
Constructor and Description |
---|
ManualRegexIterator(RegexIterator base) |
Modifier and Type | Method and Description |
---|---|
int |
getNumberOfGroups()
Get the number of captured groups
|
java.lang.String |
getRegexGroup(int number)
Get a substring that matches a parenthesised group within the regular expression
|
boolean |
isMatching()
Determine whether the current item in the sequence is a matching item or a non-matching item
|
void |
processMatchingSubstring(RegexIterator.MatchHandler action)
Process a matching substring, performing specified actions at the start and end of each matching
group
|
close, current, getLength, getProperties, getResidue, getReverseIterator, hasNext, incrementPosition, materialize, next, position, setContextItem, setLastPositionFinder, setPosition
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
close, forEachOrFail, getProperties, materialize, next
firstWith, forEach, toGroundedValue, toList
public ManualRegexIterator(RegexIterator base)
public int getNumberOfGroups()
getNumberOfGroups
in interface RegexIterator
public boolean isMatching()
isMatching
in interface RegexIterator
public java.lang.String getRegexGroup(int number)
getRegexGroup
in interface RegexIterator
number
- the number of the group to be obtainedpublic void processMatchingSubstring(RegexIterator.MatchHandler action)
processMatchingSubstring
in interface RegexIterator
action
- the action to be performed on a matching substringCopyright (c) 2004-2020 Saxonica Limited. All rights reserved.