| org.apache.tools.ant.util.regexp.RegexpMatcher
All known Subclasses: org.apache.tools.ant.util.regexp.JakartaOroMatcher, org.apache.tools.ant.util.regexp.Jdk14RegexpMatcher, org.apache.tools.ant.util.regexp.JakartaRegexpMatcher,
RegexpMatcher | public interface RegexpMatcher (Code) | | Interface describing a regular expression matcher.
|
Method Summary | |
Vector | getGroups(String argument) Returns a Vector of matched groups found in the argument
using default options. | Vector | getGroups(String input, int options) Get the match groups from this regular expression. | String | getPattern() | boolean | matches(String argument) | boolean | matches(String input, int options) Does this regular expression match the input, given
certain options
Parameters: input - The string to check for a match Parameters: options - The list of options for the match. | void | setPattern(String pattern) Set the regexp pattern from the String description. |
MATCH_CASE_INSENSITIVE | int MATCH_CASE_INSENSITIVE(Code) | | Perform a case insenstive match
|
MATCH_DEFAULT | int MATCH_DEFAULT(Code) | | Default Mask (case insensitive, neither multiline nor
singleline specified).
|
MATCH_MULTILINE | int MATCH_MULTILINE(Code) | | Treat the input as a multiline input
|
MATCH_SINGLELINE | int MATCH_SINGLELINE(Code) | | Treat the input as singleline input ('.' matches newline)
|
getGroups | Vector getGroups(String argument) throws BuildException(Code) | | Returns a Vector of matched groups found in the argument
using default options.
Group 0 will be the full match, the rest are the
parenthesized subexpressions .
Parameters: argument - the string to match against the vector of groups throws: BuildException - on error |
getGroups | Vector getGroups(String input, int options) throws BuildException(Code) | | Get the match groups from this regular expression. The return
type of the elements is always String.
Parameters: input - The string to check for a match Parameters: options - The list of options for the match. See theMATCH_ constants above. the vector of groups throws: BuildException - on error |
matches | boolean matches(String argument) throws BuildException(Code) | | Does the given argument match the pattern?
Parameters: argument - the string to match against true if the pattern matches throws: BuildException - on error |
matches | boolean matches(String input, int options) throws BuildException(Code) | | Does this regular expression match the input, given
certain options
Parameters: input - The string to check for a match Parameters: options - The list of options for the match. See theMATCH_ constants above. true if the pattern matches throws: BuildException - on error |
|
|