![]() |
PDFix SDK
6.5.0
|
Public Member Functions | |
virtual void | Destroy ()=0 |
Destroys PsRegex resources. More... | |
virtual bool | SetPattern (const wchar_t *pattern)=0 |
Sets a regular expression to search for. More... | |
virtual bool | Search (const wchar_t *text, int position)=0 |
Searches for a match in a string. Use positions parameter to find more patterns. More... | |
virtual int | GetText (wchar_t *buffer, int len)=0 |
Gets a buffer containing the matched text if it finds a match, otherwise it returns 0. More... | |
virtual int | GetPosition ()=0 |
virtual int | GetLength ()=0 |
Gets a length of the matched text. More... | |
virtual int | GetNumMatches ()=0 |
Gets the number of matched text in pattern. More... | |
virtual int | GetMatchText (int index, wchar_t *buffer, int len)=0 |
Gets the matched text by index. More... | |
PsRegex class.
A regular expression is an object that describes a pattern of characters. Regular expressions are used to perform pattern-matching functions on text. It helps to recognize a logical structure in a document. NOTE: Use Perl Regular Expression Syntax to create a new pattern.
|
pure virtual |
Destroys PsRegex resources.
|
pure virtual |
Gets a length of the matched text.
|
pure virtual |
Gets the matched text by index.
index | The match index to get. |
buffer | (filled by method) If the buffer is null function returns required length of string |
len | Length of a buffer to be filled in. |
|
pure virtual |
Gets the number of matched text in pattern.
|
pure virtual |
Gets a position of the matched text from the start position defined in PsRegex::Search method. NOTE: It's not a position from text buffer beginning.
|
pure virtual |
Gets a buffer containing the matched text if it finds a match, otherwise it returns 0.
buffer | (filled by method) If the buffer is null function returns required length of string |
len | Length of a buffer to be filled in. |
|
pure virtual |
Searches for a match in a string. Use positions parameter to find more patterns.
text | The string to be searched. |
position | A position in the text where to start search. |
|
pure virtual |
Sets a regular expression to search for.
pattern | The Regular expression. |