RegEx packages

From Free Pascal wiki
Revision as of 09:46, 17 June 2007 by Paulatreides (talk | contribs)
Jump to navigationJump to search

Template:Regexpr

Regexpr is a very basic regex (Regular Expression) unit. The use of regex is to search patterns inside a string.

The current unit is far from complete, and still misses very simple syntax support of POSIX or more complex syntax such as Perl regex, Java Regex, Ruby Regex etc...

The unit contains 4 functions for now:

  • GenerateRegExprEngine – This function compiles the regex pattern.
  • RegExprPos – Finds the pattern inside a given string.
  • DestroyRegExprEngine – Free the compilation of the pattern
  • RegExprEscapeStr – Escape reserve syntax of regular expression language so it will be understood as string instead of regex syntax.