Class StringMatcher
java.lang.Object
org.parboiled.trees.ImmutableGraphNode<Matcher>
org.parboiled.matchers.AbstractMatcher
org.parboiled.matchers.SequenceMatcher
org.parboiled.matchers.StringMatcher
A
SequenceMatcher specialization for sequences of CharMatchers. Performs fast string matching if the
current context has it enabled.-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiondefaultLabel(String defaultLabel) getLabel()booleanbooleanmatch(MatcherContext context) Tries a match on the given MatcherContext.Methods inherited from class SequenceMatcher
acceptMethods inherited from class AbstractMatcher
areMismatchesMemoed, areSubnodesSuppressed, getSubContext, getTag, isNodeSkipped, isNodeSuppressed, label, memoMismatches, setTag, skipNode, suppressNode, suppressSubnodes, toStringMethods inherited from class ImmutableGraphNode
getChildrenMethods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface GraphNode
getChildren
-
Field Details
-
characters
public final char[] characters
-
-
Constructor Details
-
StringMatcher
-
-
Method Details
-
getLabel
-
hasCustomLabel
public boolean hasCustomLabel()- Specified by:
hasCustomLabelin interfaceMatcher- Returns:
- true if this matcher has been assigned a custom label
-
match
Description copied from interface:MatcherTries a match on the given MatcherContext.- Specified by:
matchin interfaceMatcher- Overrides:
matchin classSequenceMatcher- Parameters:
context- the MatcherContext- Returns:
- true if the match was successful
-
defaultLabel
-