Package net.sf.saxon.regex
Class Operation.OpGreedyFixed
- java.lang.Object
- 
- net.sf.saxon.regex.Operation
- 
- net.sf.saxon.regex.Operation.OpRepeat
- 
- net.sf.saxon.regex.Operation.OpGreedyFixed
 
 
 
- 
- Enclosing class:
- Operation
 
 public static class Operation.OpGreedyFixed extends Operation.OpRepeat Handle a greedy repetition (with possible min and max) where the size of the repeated unit is fixed.
- 
- 
Nested Class Summary- 
Nested classes/interfaces inherited from class net.sf.saxon.regex.OperationOperation.OpAtom, Operation.OpBackReference, Operation.OpBOL, Operation.OpCapture, Operation.OpCharClass, Operation.OpChoice, Operation.OpEndProgram, Operation.OpEOL, Operation.OpGreedyFixed, Operation.OpNothing, Operation.OpReluctantFixed, Operation.OpRepeat, Operation.OpSequence, Operation.OpTrace, Operation.OpUnambiguousRepeat
 
- 
 - 
Field Summary- 
Fields inherited from class net.sf.saxon.regex.Operation.OpRepeatmax, min, op
 
- 
 - 
Method SummaryAll Methods Instance Methods Concrete Methods Modifier and Type Method Description intgetMatchLength()Get the length of the matches returned by this operation if they are fixed-lengthIntIteratoriterateMatches(REMatcher matcher, int position)Get an iterator returning all the matches for this operationintmatchesEmptyString()Ask whether the regular expression is known, after static analysis, to match a zero-length stringOperationoptimize(REProgram program, REFlags flags)Optimize the operation- 
Methods inherited from class net.sf.saxon.regex.Operation.OpRepeatcontainsCapturingExpressions, display, getInitialCharacterClass, getMinimumMatchLength
 
- 
 
- 
- 
- 
Method Detail- 
getMatchLengthpublic int getMatchLength() Description copied from class:OperationGet the length of the matches returned by this operation if they are fixed-length- Overrides:
- getMatchLengthin class- Operation.OpRepeat
- Returns:
- the length of the matches, or -1 if the length is variable
 
 - 
matchesEmptyStringpublic int matchesEmptyString() Description copied from class:OperationAsk whether the regular expression is known, after static analysis, to match a zero-length string- Overrides:
- matchesEmptyStringin class- Operation.OpRepeat
- Returns:
- a value indicating whether the regex is statically known to match
 a zero-length string. Specifically:
 - returns Operation.MATCHES_ZLS_AT_STARTif the expression is statically known to match a zero-length string at the start of the supplied input;
- returns
 Operation.MATCHES_ZLS_AT_ENDif it is statically known to return a zero-length string at the end of the supplied input;
- returns Operation.MATCHES_ZLS_ANYWHEREif it is statically known to match a zero-length string anywhere in the input.
- returns Operation.MATCHES_ZLS_NEVERif it is statically known that the regex will never match a zero length string.
 
- returns 
 
 - 
optimizepublic Operation optimize(REProgram program, REFlags flags) Description copied from class:OperationOptimize the operation- Overrides:
- optimizein class- Operation.OpRepeat
- Parameters:
- program- the program being optimized
- flags- the regular expression flags
- Returns:
- the optimized operation
 
 - 
iterateMatchespublic IntIterator iterateMatches(REMatcher matcher, int position) Description copied from class:OperationGet an iterator returning all the matches for this operation- Overrides:
- iterateMatchesin class- Operation.OpRepeat
- Parameters:
- matcher- supplies the context for the matching; may be updated with information about captured groups
- position- the start position to seek a match
- Returns:
- an iterator returning the endpoints of all matches starting at the supplied position
 
 
- 
 
-