|
AndroMeta
2.0.0
|
Extends the standard string type, adding some useful convenience methods. More...
#include <MStr.h>
Public Types | |
| typedef std::string::iterator | iterator |
| typedef std::string::const_iterator | const_iterator |
|
typedef std::string::reverse_iterator | reverse_iterator |
|
typedef std::string::const_reverse_iterator | const_reverse_iterator |
Public Member Functions | |
| MStr (const std::string &str) | |
| MStr (const char *s) | |
| bool | operator!= (const MStr &str) const |
| bool | operator== (const MStr &str) const |
| MStr & | operator= (const MStr &str) |
| bool | operator< (const MStr &str) const |
| bool | operator> (const MStr &str) const |
| bool | operator<= (const MStr &str) const |
| bool | operator>= (const MStr &str) const |
| MStr | operator+ (const MStr &str) const |
| MStr & | operator+= (const MStr &str) |
| MStr & | operator+= (char c) |
| const char & | operator[] (size_t pos) const |
| char & | operator[] (size_t pos) |
| const char & | at (size_t pos) const |
| char & | at (size_t pos) |
| MStr & | append (const MStr &str) |
| MStr & | append (const MStr &str, size_t pos, size_t n) |
| MStr & | append (const char *s, size_t n) |
| MStr & | append (const char *s) |
| MStr & | append (size_t n, char c) |
| iterator | begin () |
| const_iterator | begin () const |
| iterator | end () |
| const_iterator | end () const |
| reverse_iterator | rbegin () |
| const_reverse_iterator | rbegin () const |
| reverse_iterator | rend () |
| const_reverse_iterator | rend () const |
| MStr & | insert (size_t pos1, const MStr &str) |
| MStr & | insert (size_t pos1, const MStr &str, size_t pos2, size_t n) |
| MStr & | insert (size_t pos1, const char *s, size_t n) |
| MStr & | insert (size_t pos1, const char *s) |
| MStr & | insert (size_t pos1, size_t n, char c) |
| iterator | insert (iterator p, char c) |
| void | insert (iterator p, size_t n, char c) |
| template<class InputIterator > | |
| void | insert (iterator p, InputIterator first, InputIterator last) |
| size_t | copy (char *s, size_t n, size_t pos=0) const |
| template<class InputIterator > | |
| MStr & | append (InputIterator first, InputIterator last) |
| MStr | substr (size_t pos=0, size_t n=std::string::npos) const |
| const char * | c_str () const |
| const char * | cstr () const |
| size_t | find (const MStr &str, size_t pos=0) const |
| size_t | find (const char *s, size_t pos, size_t n) const |
| size_t | find (const char *s, size_t pos=0) const |
| size_t | find (char c, size_t pos=0) const |
| size_t | rfind (const MStr &str, size_t pos=npos) const |
| size_t | rfind (const char *s, size_t pos, size_t n) const |
| size_t | rfind (const char *s, size_t pos=npos) const |
| size_t | rfind (char c, size_t pos=npos) const |
| size_t | findReplace (const MStr &value, const MStr &replacement, bool all=true, size_t pos=0) |
| size_t | findCount (const MStr &str) const |
| operator std::string () const | |
| std::string & | str () |
| const std::string & | str () const |
| size_t | length () const |
| void | resize (size_t n, char c) |
| void | resize (size_t n) |
| size_t | size () const |
| size_t | max_size () const |
| size_t | maxSize () const |
| size_t | capacity () const |
| void | reserve (size_t res_arg=0) |
| void | clear () |
| MStr & | erase (size_t pos=0, size_t n=npos) |
| MStr & | replace (size_t pos1, size_t n1, const MStr &str) |
| MStr | allCaps () const |
| MStr | allLower () const |
| MStr | uppercase () const |
| MStr | lowercase () const |
| void | strip (bool start=true, bool end=true) |
| MStr | quote () const |
| bool | isIdentifier () const |
| bool | isAllCapsIdentifier () const |
| bool | isNumeric () const |
| bool | empty () const |
| void | convertEscapes () |
| template<typename T > | |
| void | split (T &out, const MStr &delimiter, int maxTokens=-1) const |
| void | push_back (char c) |
| void | pushBack (char c) |
| MStr & | assign (const MStr &str) |
| MStr & | assign (const MStr &str, size_t pos, size_t n) |
| MStr & | assign (const char *s, size_t n) |
| MStr & | assign (const char *s) |
| MStr & | assign (size_t n, char c) |
| template<class InputIterator > | |
| MStr & | assign (InputIterator first, InputIterator last) |
| void | swap (MStr &str) |
| const char * | data () const |
| std::allocator< char > | get_allocator () const |
| size_t | find_first_of (const MStr &str, size_t pos=0) const |
| size_t | findFirstOf (const MStr &str, size_t pos=0) const |
| size_t | find_first_of (const char *s, size_t pos, size_t n) const |
| size_t | findFirstOf (const char *s, size_t pos, size_t n) const |
| size_t | find_first_of (const char *s, size_t pos=0) const |
| size_t | findFirstOf (const char *s, size_t pos=0) const |
| size_t | find_first_of (char c, size_t pos=0) const |
| size_t | findFirstOf (char c, size_t pos=0) const |
| size_t | find_last_of (const MStr &str, size_t pos=npos) const |
| size_t | findLastOf (const MStr &str, size_t pos=npos) const |
| size_t | find_last_of (const char *s, size_t pos, size_t n) const |
| size_t | findLastOf (const char *s, size_t pos, size_t n) const |
| size_t | find_last_of (const char *s, size_t pos=npos) const |
| size_t | findLastOf (const char *s, size_t pos=npos) const |
| size_t | find_last_of (char c, size_t pos=npos) const |
| size_t | findLastOf (char c, size_t pos=npos) const |
| size_t | find_first_not_of (const MStr &str, size_t pos=0) const |
| size_t | findFirstNotOf (const MStr &str, size_t pos=0) const |
| size_t | find_first_not_of (const char *s, size_t pos, size_t n) const |
| size_t | findFirstNotOf (const char *s, size_t pos, size_t n) const |
| size_t | find_first_not_of (const char *s, size_t pos=0) const |
| size_t | findFirstNotOf (const char *s, size_t pos=0) const |
| size_t | find_first_not_of (char c, size_t pos=0) const |
| size_t | findFirstNotOf (char c, size_t pos=0) const |
| size_t | find_last_not_of (const MStr &str, size_t pos=npos) const |
| size_t | findLastNotOf (const MStr &str, size_t pos=npos) const |
| size_t | find_last_not_of (const char *s, size_t pos, size_t n) const |
| size_t | findLastNotOf (const char *s, size_t pos, size_t n) const |
| size_t | find_last_not_of (const char *s, size_t pos=npos) const |
| size_t | findLastNotOf (const char *s, size_t pos=npos) const |
| size_t | find_last_not_of (char c, size_t pos=npos) const |
| size_t | findLastNotOf (char c, size_t pos=npos) const |
Static Public Member Functions | |
| static MStr | toStr (const MVar &v, bool concise=true, bool quote=true) |
| static bool | isLower (int c) |
| static bool | isUpper (int c) |
| static bool | isDigit (int c) |
| static bool | isAlpha (int c) |
| static int | toLower (int c) |
| static int | toUpper (int c) |
| template<typename T > | |
| static MStr | join (const T &v, const MStr &delimiter, bool concise=true, bool quote=false) |
Static Public Attributes | |
| static const size_t | npos = std::string::npos |
Extends the standard string type, adding some useful convenience methods.
MStr provides a string data type which is fully compatible with the standard string.
| size_t Meta::MStr::findCount | ( | const MStr & | str | ) | const |
1.7.6.1