Functions

regex.inc

amxmodx 1.8.2 hg65

Function Type Description
regex_compile native Precompile a regular expression. Use this if you intend on using the
same expression multiple times. Pass the regex handle returned here to
regex_match_c to check for matches.
regex_free native Frees the memory associated with a regex result, and sets the handle to 0.
This must be called on all results from regex_match() when you are done extracting
the results with regex_substr().
The results of regex_compile() (and subsequently, regex_match_c()) only need to be freed
when you are done using the pattern.
regex_match native Matches a string against a regular expression pattern.
regex_match_c native Matches a string against a pre-compiled regular expression pattern.
regex_substr native Returns a matched substring from a regex handle.
Substring ids start at 0 and end at ret-1, where ret is from the corresponding
regex_match or regex_match_c function call.