X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/06b466c74fae8f27544f143abdcabcd2385602e4..c7e9e7584f4c53996a6be854f0830c9aa9885f14:/include/wx/tokenzr.h?ds=sidebyside diff --git a/include/wx/tokenzr.h b/include/wx/tokenzr.h index 34fd063032..e9e11c30df 100644 --- a/include/wx/tokenzr.h +++ b/include/wx/tokenzr.h @@ -2,7 +2,7 @@ // Name: wx/tokenzr.h // Purpose: String tokenizer - a C++ replacement for strtok(3) // Author: Guilhem Lavaux -// Modified by: Vadim Zeitlin +// Modified by: (or rather rewritten by) Vadim Zeitlin // Created: 04/22/98 // RCS-ID: $Id$ // Copyright: (c) Guilhem Lavaux @@ -117,4 +117,15 @@ protected: bool m_hasMore; // do we have more (possible empty) tokens? }; +// ---------------------------------------------------------------------------- +// convenience function which returns all tokens at once +// ---------------------------------------------------------------------------- + +// the function takes the same parameters as wxStringTokenizer ctor and returns +// the array containing all tokens +wxArrayString WXDLLEXPORT +wxStringTokenize(const wxString& str, + const wxString& delims = wxDEFAULT_DELIMITERS, + wxStringTokenizerMode mode = wxTOKEN_DEFAULT); + #endif // _WX_TOKENZRH