Example usage for Java java.util.regex Pattern fields, constructors, methods, implement or subclass
The text is from its open source code.
int | UNIX_LINES Enables Unix lines mode. |
int | CASE_INSENSITIVE Enables case-insensitive matching. |
int | COMMENTS Permits whitespace and comments in pattern. |
int | MULTILINE Enables multiline mode. |
int | LITERAL Enables literal parsing of the pattern. |
int | DOTALL Enables dotall mode. |
int | UNICODE_CASE Enables Unicode-aware case folding. |
int | CANON_EQ Enables canonical equivalence. |
int | UNICODE_CHARACTER_CLASS Enables the Unicode version of Predefined character classes and POSIX character classes. |
String | pattern The original regular-expression pattern string. |
int | flags The original pattern flags. |
Predicate | asPredicate() Creates a predicate that tests if this pattern is found in a given input string. |
Pattern | compile(String regex) Compiles the given regular expression into a pattern. |
Pattern | compile(String regex, int flags) Compiles the given regular expression into a pattern with the given flags. |
boolean | equals(Object obj) Indicates whether some other object is "equal to" this one. |
Matcher | matcher(CharSequence input) Creates a matcher that will match the given input against this pattern. |
boolean | matches(String regex, CharSequence input) Compiles the given regular expression and attempts to match the given input against it. |
String | quote(String s) Returns a literal pattern String for the specified String . |
String[] | split(CharSequence input) Splits the given input sequence around matches of this pattern. |
String[] | split(CharSequence input, int limit) Splits the given input sequence around matches of this pattern. |
Stream | splitAsStream(final CharSequence input) Creates a stream from the given input sequence around matches of this pattern. |
String | toString() Returns the string representation of this pattern. |