All Implemented Interfaces:
MatchResult

  • Method Summary

    Implements a non-terminal append-and-replace step.

    Implements a non-terminal append-and-replace step.

    Implements a terminal append-and-replace step.

    Implements a terminal append-and-replace step.

    int

    end()

    Returns the offset after the last character matched.

    int

    end(int group)

    Returns the offset after the last character of the subsequence captured by the given group during the previous match operation.

    int

    Returns the offset after the last character of the subsequence captured by the given named-capturing group during the previous match operation.

    boolean

    find()

    Attempts to find the next subsequence of the input sequence that matches the pattern.

    boolean

    find(int start)

    Resets this matcher and then attempts to find the next subsequence of the input sequence that matches the pattern, starting at the specified index.

    group()

    Returns the input subsequence matched by the previous match.

    group(int group)

    Returns the input subsequence captured by the given group during the previous match operation.

    Returns the input subsequence captured by the given named-capturing group during the previous match operation.

    int

    Returns the number of capturing groups in this matcher's pattern.

    boolean

    Queries the anchoring of region bounds for this matcher.

    boolean

    hasMatch()

    Returns whether this contains a valid match from a previous match or find operation.

    boolean

    Queries the transparency of region bounds for this matcher.

    boolean

    hitEnd()

    Returns true if the end of input was hit by the search engine in the last match operation performed by this matcher.

    boolean

    lookingAt()

    Attempts to match the input sequence, starting at the beginning of the region, against the pattern.

    boolean

    matches()

    Attempts to match the entire region against the pattern.

    Returns an unmodifiable map from capturing group names to group numbers.

    pattern()

    Returns the pattern that is interpreted by this matcher.

    Returns a literal replacement String for the specified String.

    region(int start, int end)

    Sets the limits of this matcher's region.

    int

    regionEnd()

    Reports the end index (exclusive) of this matcher's region.

    int

    Reports the start index of this matcher's region.

    Replaces every subsequence of the input sequence that matches the pattern with the given replacement string.

    Replaces every subsequence of the input sequence that matches the pattern with the result of applying the given replacer function to the match result of this matcher corresponding to that subsequence.

    Replaces the first subsequence of the input sequence that matches the pattern with the given replacement string.

    Replaces the first subsequence of the input sequence that matches the pattern with the result of applying the given replacer function to the match result of this matcher corresponding to that subsequence.

    boolean

    Returns true if more input could change a positive match into a negative one.

    reset()

    Resets this matcher with a new input sequence.

    results()

    Returns a stream of match results for each subsequence of the input sequence that matches the pattern.

    int

    start()

    Returns the start index of the previous match.

    int

    start(int group)

    Returns the start index of the subsequence captured by the given group during the previous match operation.

    int

    Returns the start index of the subsequence captured by the given named-capturing group during the previous match operation.

    Returns the match state of this matcher as a MatchResult.

    toString()

    Returns the string representation of this matcher.

    useAnchoringBounds(boolean b)

    Sets the anchoring of region bounds for this matcher.

    Changes the Pattern that this Matcher uses to find matches with.

    useTransparentBounds(boolean b)

    Sets the transparency of region bounds for this matcher.

    Methods declared in class Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait

    Creates and returns a copy of this object.

    boolean

    Indicates whether some other object is "equal to" this one.

    protected void

    Deprecated, for removal: This API element is subject to removal in a future version.

    Returns the runtime class of this Object.

    int

    Returns a hash code value for this object.

    final void

    Wakes up a single thread that is waiting on this object's monitor.

    final void

    Wakes up all threads that are waiting on this object's monitor.

    final void

    Causes the current thread to wait until it is awakened, typically by being notified or interrupted.

    final void

    wait(long timeoutMillis)

    Causes the current thread to wait until it is awakened, typically by being notified or interrupted, or until a certain amount of real time has elapsed.

    final void

    wait(long timeoutMillis, int nanos)

    Causes the current thread to wait until it is awakened, typically by being notified or interrupted, or until a certain amount of real time has elapsed.

  • Method Details

    • pattern

    • toMatchResult

    • usePattern

    • reset

    • reset

    • start

    • start

    • start

    • end

    • end

    • end

    • group

    • group

    • group

    • groupCount

    • matches

    • find

    • find

    • lookingAt

    • quoteReplacement

    • appendReplacement

    • appendReplacement

    • appendTail

    • appendTail

    • replaceAll

    • replaceAll

    • results

    • replaceFirst

    • replaceFirst

    • region

    • regionStart

    • regionEnd

    • hasTransparentBounds

    • useTransparentBounds

    • hasAnchoringBounds

    • useAnchoringBounds

    • toString

    • hitEnd

    • requireEnd

    • namedGroups

    • hasMatch