| ||use extended RE syntax
||use advanced RE syntax
||use basic RE syntax
||ignore case in match
||only check match, don't set back references
||if not set, treat '\n' as an
ordinary character, otherwise it is special: it is not matched by '.' and
'^' and '$' always match after/before it regardless of the setting of wxRE_NOT[BE]OL
||'^' doesn't match at the start of line
||'$' doesn't match at the end of line
For more information, see the on-line wxWidgets documentation:
Create and compile the regular expression, use is_valid_regex to test for compilation errors.
Deletes a wxRegEx object.
Get the start index and the length of the match of the expression (if index is 0) or a bracketed subexpression (index different from 0).
May only be called after successful call to Matches() and only if wxRE_NOSUB was not used in compile_regex.
Returns false if no match or if an error occurred.
Returns the size of the array of matches, i.e. the number of bracketed subexpressions plus one for the expression itself, or 0 on error.
May only be called after successful call to Compile(). and only if wxRE_NOSUB was not used.
Return 1 if this is a valid compiled regular expression, 0 otherwise.
Matches the precompiled regular expression against the string text, returns true if matches and false otherwise.
Flags may be combination of wxRE_NOTBOL and wxRE_NOTEOL.
May only be called after successful call to compile_regex.
Replaces the current regular expression in the string pointed to by text, with the text in replacement. If in_place is 1, then only the modified text is returned. If in_place is 1, then the return value is a sequence, with the first element the number of replaces made, and the second element the modified text.
The replacement text may contain back references \number which will be replaced with the value of the corresponding subexpression in the pattern match. \0 corresponds to the entire match and & is a synonym for it. Backslash may be used to quote itself or & character.
max_matches may be used to limit the number of replacements made, setting it to 1, for example, will only replace first occurrence (if any) of the pattern in the text while default value of 0 means replace all.