find() The find() method matches the pattern against the character sequence
beginning at the character after the last match or at the beginning of
the sequence if called immediately after reset().
replaceFirst(String replacement) This is very similar to replaceAll except only the first occurrence of a
sequence matching the pattern is replaced.
Parameters: replacement - A string to replace occurrences of character sequencesmatching the pattern.
The find() method matches the pattern against the character sequence
beginning at the character after the last match or at the beginning of
the sequence if called immediately after reset(). The method returns true
if and only if a match is found.
A boolean indicating if the pattern was matched.
This method attempts to match the pattern against the character sequence
starting at the beginning. If the pattern matches even a prefix of the
input character sequence, lookingAt() will return true. Otherwise it will
return false.
A boolean indicating if the pattern matches a prefix of the inputcharacter sequence.
This method is identical in function to the Pattern.matches() method. It
returns true if and only if the regular expression pattern matches the
entire input character sequence.
A boolean indicating if the pattern matches the entire inputcharacter sequence.
Replace all occurrences of character sequences which match the pattern
with the given replacement string. The replacement string may refer to
capturing groups using the syntax "$".
Parameters: replacement - A string to replace occurrences of character sequencesmatching the pattern. A new string with replacements inserted
This is very similar to replaceAll except only the first occurrence of a
sequence matching the pattern is replaced.
Parameters: replacement - A string to replace occurrences of character sequencesmatching the pattern. A new string with replacements inserted