Package totalcross.util.regex
Interface REFlags
-
- All Known Implementing Classes:
Pattern,WildcardPattern
public interface REFlags
-
-
Field Summary
Fields Modifier and Type Field Description static intDEFAULTAll the foolowing options turned offstatic intDOTALLAffects the behaviour of dot(".") tag.static intIGNORE_CASEPattern "a" matches both "a" and "A".static intIGNORE_SPACESAffects how the space characters are interpeted in the expression.static intMULTILINEAffects the behaviour of "^" and "$" tags.static intUNICODEAffects whether the predefined classes("\d","\s","\w",etc) in the expression are interpreted as belonging to Unicode.static intXML_SCHEMATurns on the compatibility with XML Schema regular expressions.
-
-
-
Field Detail
-
DEFAULT
static final int DEFAULT
All the foolowing options turned off- See Also:
- Constant Field Values
-
IGNORE_CASE
static final int IGNORE_CASE
Pattern "a" matches both "a" and "A". Corresponds to "i" in Perl notation.- See Also:
- Constant Field Values
-
MULTILINE
static final int MULTILINE
Affects the behaviour of "^" and "$" tags. When switched off:- the "^" matches the beginning of the whole text;
- the "$" matches the end of the whole text, or just before the '\n' or "\r\n" at the end of text. When switched on:
- the "^" additionally matches the line beginnings (that is just after the '\n');
- the "$" additionally matches the line ends (that is just before "\r\n" or '\n'); Corresponds to "m" in Perl notation.
- See Also:
- Constant Field Values
-
DOTALL
static final int DOTALL
Affects the behaviour of dot(".") tag. When switched off:- the dot matches any character but EOLs('\r','\n'); When switched on:
- the dot matches any character, including EOLs. This flag is sometimes referenced in regex tutorials as SINGLELINE, which confusingly seems opposite to MULTILINE, but in fact is orthogonal. Corresponds to "s" in Perl notation.
- See Also:
- Constant Field Values
-
IGNORE_SPACES
static final int IGNORE_SPACES
Affects how the space characters are interpeted in the expression. When switched off:- the spaces are interpreted literally; When switched on:
- the spaces are ingnored, allowing an expression to be slightly more readable. Corresponds to "x" in Perl notation.
- See Also:
- Constant Field Values
-
UNICODE
static final int UNICODE
Affects whether the predefined classes("\d","\s","\w",etc) in the expression are interpreted as belonging to Unicode. When switched off:- the predefined classes are interpreted as ASCII; When switched on:
- the predefined classes are interpreted as Unicode categories;
- See Also:
- Constant Field Values
-
XML_SCHEMA
static final int XML_SCHEMA
Turns on the compatibility with XML Schema regular expressions.- See Also:
- Constant Field Values
-
-