Name
java.util.regex.Matcher
Description
Models a stateful regular expression pattern matcher and pattern matching results.
Methods
Matcher appendReplacement(StringBuffersb, Stringreplacement)Append substring preceding match and
replacementtosb.StringBuffer appendTail(StringBuffersb)Append substring following end of match to
sb.int end( )Index of the first character after the end of the match.
int end(intgroup)Index of the first character after the text captured by
group.boolean find( )Find the next match in the input string.
boolean find(intstart)Find the next match after character position
start.String group( )Text matched by this
Pattern.String group(intgroup)Text captured by capture group
group.int groupCount( )Number of capturing groups in
Pattern.boolean hasAnchoringBounds( )Return true if this
Matcheruses anchoring bounds so that anchor operators match at the region boundaries, not just at the start and end of the target string.boolean hasTransparentBounds( )True if this
Matcheruses transparent bounds so that lookaround operators can see outside the current search bounds. Defaults to false.boolean hitEnd( )True if the last match attempts to inspect beyond the end of the input. In scanners, this is an indication that more input may have resulted in a longer match.
boolean lookingAt( )True if the pattern matches at the beginning of the input.
boolean matches( )Return true if
Patternmatches entire input string.Pattern pattern( )Return
Patternobject used by thisMatcher.static ...