Language

RegexOptions Enum

Definition

Enumerates values returned by several types and taken as a parameter of the F:Java.Util.Regex.Pattern.Compile member.

public enum RegexOptions
type RegexOptions = 
Inheritance
RegexOptions

Fields

Name Value Description
UnixLines 1

This constant specifies that a pattern matches Unix line endings ('\n') only against the '.', '^', and '$' meta characters.

CaseInsensitive 2

This constant specifies that a Patternis matched case-insensitively.

Comments 4

This constant specifies that a Patternmay contain whitespace or comments.

Multiline 8

This constant specifies that the meta characters '^' and '$' match only the beginning and end of an input line, respectively.

Literal 16

This constant specifies that the whole Patternis to be taken literally, that is, all meta characters lose their meanings.

Dotall 32

This constant specifies that the '.' meta character matches arbitrary characters, including line endings, which is normally not the case. Corresponds to (?s).

UnicodeCase 64

This flag is ignored on Android; case-insensitive matching is always Unicode-aware.

CanonEq 128

This flag is not supported on Android. Compile(String, RegexOptions) throws an exception if this flag is set.

UnicodeCharacterClass 256

This flag is not supported on Android, and Unicode character classes are always used.

Unicode versions of predefined and POSIX character classes conform to Unicode Technical Standard #18: Unicode Regular Expressions, Annex C: Compatibility Properties.

Android reference for java.util.regex.Pattern.UNICODE_CHARACTER_CLASS.

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Remarks

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to