Add a length parameter for wxRegEx::Matches

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@36182 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Michael Wetherell
2005-11-15 15:51:10 +00:00
parent 58b59bb7d5
commit c9eee7f035
3 changed files with 52 additions and 13 deletions

View File

@@ -94,9 +94,13 @@ public:
// true if matches and false otherwise
//
// flags may be combination of wxRE_NOTBOL and wxRE_NOTEOL
// len may be the length of text (ignored except by built-in regex lib)
//
// may only be called after successful call to Compile()
bool Matches(const wxChar *text, int flags = 0) const;
bool Matches(const wxChar *text, int flags, size_t len) const;
bool Matches(const wxString& text, int flags = 0) const
{ return Matches(text.c_str(), flags, text.length()); }
// get the start index and the length of the match of the expression
// (index 0) or a bracketed subexpression (index != 0)