Gjsify LogoGjsify Logo

Flags specifying compile-time options.

bitfield

Index

Enumeration Members

ANCHORED: number

The pattern is forced to be "anchored", that is, it is constrained to match only at the first matching point in the string that is being searched. This effect can also be achieved by appropriate constructs in the pattern itself such as the "^" metacharacter.

BSR_ANYCRLF: number

Usually any newline character or character sequence is recognised. If this option is set, then "\R" only recognizes the newline characters '\r', '\n' and '\r\n'. Since: 2.34

CASELESS: number

Letters in the pattern match both upper- and lowercase letters. This option can be changed within a pattern by a "(?i)" option setting.

DOLLAR_ENDONLY: number

A dollar metacharacter ("$") in the pattern matches only at the end of the string. Without this option, a dollar also matches immediately before the final character if it is a newline (but not before any other newlines). This option is ignored if %G_REGEX_MULTILINE is set.

DOTALL: number

A dot metacharacter (".") in the pattern matches all characters, including newlines. Without it, newlines are excluded. This option can be changed within a pattern by a ("?s") option setting.

DUPNAMES: number

Names used to identify capturing subpatterns need not be unique. This can be helpful for certain types of pattern when it is known that only one instance of the named subpattern can ever be matched.

EXTENDED: number

Whitespace data characters in the pattern are totally ignored except when escaped or inside a character class. Whitespace does not include the VT character (code 11). In addition, characters between an unescaped "#" outside a character class and the next newline character, inclusive, are also ignored. This can be changed within a pattern by a "(?x)" option setting.

FIRSTLINE: number

Limits an unanchored pattern to match before (or at) the first newline. Since: 2.34

JAVASCRIPT_COMPAT: number

Changes behaviour so that it is compatible with JavaScript rather than PCRE. Since: 2.34

MULTILINE: number

By default, GRegex treats the strings as consisting of a single line of characters (even if it actually contains newlines). The "start of line" metacharacter ("^") matches only at the start of the string, while the "end of line" metacharacter ("$") matches only at the end of the string, or before a terminating newline (unless %G_REGEX_DOLLAR_ENDONLY is set). When %G_REGEX_MULTILINE is set, the "start of line" and "end of line" constructs match immediately following or immediately before any newline in the string, respectively, as well as at the very start and end. This can be changed within a pattern by a "(?m)" option setting.

NEWLINE_ANYCRLF: number

Usually any newline character or character sequence is recognized. If this option is set, the only recognized newline character sequences are '\r', '\n', and '\r\n'. Since: 2.34

NEWLINE_CR: number

Usually any newline character or character sequence is recognized. If this option is set, the only recognized newline character is '\r'.

NEWLINE_CRLF: number

Usually any newline character or character sequence is recognized. If this option is set, the only recognized newline character sequence is '\r\n'.

NEWLINE_LF: number

Usually any newline character or character sequence is recognized. If this option is set, the only recognized newline character is '\n'.

NO_AUTO_CAPTURE: number

Disables the use of numbered capturing parentheses in the pattern. Any opening parenthesis that is not followed by "?" behaves as if it were followed by "?:" but named parentheses can still be used for capturing (and they acquire numbers in the usual way).

OPTIMIZE: number

Optimize the regular expression. If the pattern will be used many times, then it may be worth the effort to optimize it to improve the speed of matches.

RAW: number

Usually strings must be valid UTF-8 strings, using this flag they are considered as a raw sequence of bytes.

UNGREEDY: number

Inverts the "greediness" of the quantifiers so that they are not greedy by default, but become greedy if followed by "?". It can also be set by a "(?U)" option setting within the pattern.

Legend

  • Module
  • Object literal
  • Variable
  • Function
  • Function with type parameter
  • Index signature
  • Type alias
  • Type alias with type parameter
  • Enumeration
  • Enumeration member
  • Property
  • Method
  • Interface
  • Interface with type parameter
  • Constructor
  • Property
  • Method
  • Index signature
  • Class
  • Class with type parameter
  • Constructor
  • Property
  • Method
  • Accessor
  • Index signature
  • Inherited constructor
  • Inherited property
  • Inherited method
  • Inherited accessor
  • Protected property
  • Protected method
  • Protected accessor
  • Private property
  • Private method
  • Private accessor
  • Static property
  • Static method