|
AGX Dynamics 2.41.3.0
|
#include <String.h>
Inheritance diagram for agx::AgXString< T >:Public Types | |
| typedef std::string::const_iterator | const_iterator |
| typedef std::string::iterator | iterator |
| typedef std::string::size_type | size_type |
Public Member Functions | |
| AgXString () | |
| Default constructor. | |
| AgXString (const AgXString &str) | |
| Copy constructors. | |
| AgXString (const char *str) | |
| Element type pointer constructor. | |
| AgXString (const char *str, size_type index, size_type length) | |
Construct sub-string of str from index and length characters forward. | |
| AgXString (const char *str, size_type length) | |
Construct given str, final length of this string will be length. | |
| AgXString (const std::string &str) | |
| Create a AgXString from stl string. | |
| AgXString (const_iterator begin, const_iterator end) | |
| Construct sub-string given iterators. | |
| AgXString (size_type length, char ch) | |
Construct length number of ch. | |
| AgXString | capitalize () const |
| AgXString | center (int width) const |
| bool | contains (const AgXString &sub, size_t start=0) const |
| AgXString | copy () const |
| Copy method, if implementation of this class is changed. | |
| int | count (const AgXString &substr, int start=0, int end=MAX_32BIT_INT) const |
| bool | endswith (const AgXString &suffix, int start=0, int end=MAX_32BIT_INT) const |
| bool | endswithCI (const AgXString &suffix, int start=0, int end=MAX_32BIT_INT) const |
| AgXString | expandtabs (int tabsize=8) const |
| size_t | find (const AgXString &sub, int start=0, int end=MAX_32BIT_INT) const |
| int | index (const AgXString &sub, int start=0, int end=MAX_32BIT_INT) const |
| Synonym of find right now. | |
| bool | isalnum () const |
| bool | isalpha () const |
| bool | isdigit () const |
| bool | islower () const |
| bool | isspace () const |
| bool | istitle () const |
| bool | isupper () const |
| AgXString | ljust (int width) const |
| AgXString | lower () const |
| AgXString | lstrip (const AgXString &chars="") const |
| bool | operator!= (const char *other) const |
| bool | operator!= (const std::string &other) const |
| AgXString | operator+ (const AgXString &other) const |
| Operator +, AgXString b = thisAgXString + other. | |
| AgXString | operator+ (const char *other) const |
| Operator +, AgXString b = thisAgXString + "other". | |
| AgXString | operator+ (const char elem) const |
| Operator +, AgXString b = thisAgXString + 'o'. | |
| bool | operator== (const AgXString &other) const |
| bool | operator== (const char *other) const |
| bool | operator== (const std::string &other) const |
| void | partition (const AgXString &sep, StringVector &result) const |
| Split the string around first occurrence of sep. | |
| AgXString | replace (const AgXString &oldstr, const AgXString &newstr, int count=-1) const |
| size_t | rfind (const AgXString &sub, int start=0, int end=MAX_32BIT_INT) const |
| AgXString | rjust (int width) const |
| void | rpartition (const AgXString &sep, StringVector &result) const |
| Split the string around last occurrence of sep. | |
| void | rsplit (StringVector &result, const AgXString &sep="", int maxsplit=-1) const |
| Fills the "result" list with the words in the string, using sep as the delimiter string. | |
| AgXString | rstrip (const AgXString &chars="") const |
| AgXString | slice (int start=0, int end=MAX_32BIT_INT) const |
| function matching python's slice functionality. | |
| void | split (StringVector &result, const AgXString &sep="", int maxsplit=-1) const |
| Fills the "result" list with the words in the string, using sep as the delimiter string. | |
| void | splitlines (StringVector &result, bool keepends=false) const |
| bool | startswith (const AgXString &prefix, int start=0, int end=MAX_32BIT_INT) const |
| bool | startswithCI (const AgXString &prefix, int start=0, int end=MAX_32BIT_INT) const |
| AgXString | strip (const AgXString &chars="") const |
| AgXString | stripLeadingString (const AgXString &toBeRemoved) const |
If this string begins with toBeRemoved, it will be removed and returned. | |
| AgXString | substr (size_type index) const |
| AgXString | substr (size_type index, size_type length) const |
| AgXString | swapcase () const |
| AgXString | title () const |
| AgXString | translate (const AgXString &table, const AgXString &deletechars="") const |
| AgXString | upper () const |
| AgXString | zfill (int width) const |
Static Public Member Functions | |
| static AgXString | format (const char *format,...) |
| C printf formatting of a string. | |
| static AgXString | formatVA (const char *format, va_list ap) |
| typedef std::string::const_iterator agx::AgXString< T >::const_iterator |
| typedef std::string::iterator agx::AgXString< T >::iterator |
| typedef std::string::size_type agx::AgXString< T >::size_type |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
| AgXString< T > agx::AgXString< T >::capitalize |
| AgXString< T > agx::AgXString< T >::center | ( | int | width | ) | const |
|
inline |
|
inline |
| int agx::AgXString< T >::count | ( | const AgXString< T > & | substr, |
| int | start = 0, |
||
| int | end = MAX_32BIT_INT |
||
| ) | const |
Definition at line 665 of file String.h.
References agx::end().
| bool agx::AgXString< T >::endswith | ( | const AgXString< T > & | suffix, |
| int | start = 0, |
||
| int | end = MAX_32BIT_INT |
||
| ) | const |
Definition at line 671 of file String.h.
References agx::end().
| bool agx::AgXString< T >::endswithCI | ( | const AgXString< T > & | suffix, |
| int | start = 0, |
||
| int | end = MAX_32BIT_INT |
||
| ) | const |
Definition at line 677 of file String.h.
References agx::end().
| AgXString< T > agx::AgXString< T >::expandtabs | ( | int | tabsize = 8 | ) | const |
| size_t agx::AgXString< T >::find | ( | const AgXString< T > & | sub, |
| int | start = 0, |
||
| int | end = MAX_32BIT_INT |
||
| ) | const |
Definition at line 790 of file String.h.
References agx::end().
|
inlinestatic |
C printf formatting of a string.
E.g., agx::AgXString s = agx::AgXString::format( "%s%d", "a number: ", 10 );.
Definition at line 471 of file String.h.
References agx::AgXString< T >::formatVA().
|
inlinestatic |
Definition at line 481 of file String.h.
References agxAssert, and agxVerifyN.
Referenced by agx::AgXString< T >::format().
| int agx::AgXString< T >::index | ( | const AgXString< T > & | sub, |
| int | start = 0, |
||
| int | end = MAX_32BIT_INT |
||
| ) | const |
Synonym of find right now.
Python version throws exceptions. This one currently doesn't
Definition at line 696 of file String.h.
References agx::end().
| bool agx::AgXString< T >::isalnum |
| bool agx::AgXString< T >::isalpha |
| bool agx::AgXString< T >::isdigit |
| bool agx::AgXString< T >::islower |
| bool agx::AgXString< T >::isspace |
| bool agx::AgXString< T >::istitle |
| bool agx::AgXString< T >::isupper |
| AgXString< T > agx::AgXString< T >::ljust | ( | int | width | ) | const |
| AgXString< T > agx::AgXString< T >::lower |
Definition at line 751 of file String.h.
Referenced by agx::GenericJsonParameter< T >::isDefault(), and agx::GenericJsonParameter< T >::parseBool().
| AgXString< T > agx::AgXString< T >::lstrip | ( | const AgXString< T > & | chars = "" | ) | const |
| bool agx::AgXString< T >::operator!= | ( | const char * | other | ) | const |
| bool agx::AgXString< T >::operator!= | ( | const std::string & | other | ) | const |
|
inline |
|
inline |
|
inline |
| bool agx::AgXString< T >::operator== | ( | const AgXString< T > & | other | ) | const |
| bool agx::AgXString< T >::operator== | ( | const char * | other | ) | const |
| bool agx::AgXString< T >::operator== | ( | const std::string & | other | ) | const |
| void agx::AgXString< T >::partition | ( | const AgXString< T > & | sep, |
| StringVector & | result | ||
| ) | const |
Split the string around first occurrence of sep.
Three strings will always placed into result. If sep is found, the strings will be the text before sep, sep itself, and the remaining text. If sep is not found, the original string will be returned with two empty strings.
| AgXString< T > agx::AgXString< T >::replace | ( | const AgXString< T > & | oldstr, |
| const AgXString< T > & | newstr, | ||
| int | count = -1 |
||
| ) | const |
| size_t agx::AgXString< T >::rfind | ( | const AgXString< T > & | sub, |
| int | start = 0, |
||
| int | end = MAX_32BIT_INT |
||
| ) | const |
Definition at line 797 of file String.h.
References agx::end().
| AgXString< T > agx::AgXString< T >::rjust | ( | int | width | ) | const |
| void agx::AgXString< T >::rpartition | ( | const AgXString< T > & | sep, |
| StringVector & | result | ||
| ) | const |
Split the string around last occurrence of sep.
Three strings will always placed into result. If sep is found, the strings will be the text before sep, sep itself, and the remaining text. If sep is not found, the original string will be returned with two empty strings.
| void agx::AgXString< T >::rsplit | ( | StringVector & | result, |
| const AgXString< T > & | sep = "", |
||
| int | maxsplit = -1 |
||
| ) | const |
Fills the "result" list with the words in the string, using sep as the delimiter string.
Does a number of splits starting at the end of the string, the result still has the split strings in their original order. If maxsplit is > -1, at most maxsplit splits are done. If sep is "", any whitespace string is a separator.
| AgXString< T > agx::AgXString< T >::rstrip | ( | const AgXString< T > & | chars = "" | ) | const |
| AgXString< T > agx::AgXString< T >::slice | ( | int | start = 0, |
| int | end = MAX_32BIT_INT |
||
| ) | const |
function matching python's slice functionality.
Definition at line 892 of file String.h.
References agx::end().
| void agx::AgXString< T >::split | ( | StringVector & | result, |
| const AgXString< T > & | sep = "", |
||
| int | maxsplit = -1 |
||
| ) | const |
| void agx::AgXString< T >::splitlines | ( | StringVector & | result, |
| bool | keepends = false |
||
| ) | const |
| bool agx::AgXString< T >::startswith | ( | const AgXString< T > & | prefix, |
| int | start = 0, |
||
| int | end = MAX_32BIT_INT |
||
| ) | const |
Definition at line 841 of file String.h.
References agx::end().
| bool agx::AgXString< T >::startswithCI | ( | const AgXString< T > & | prefix, |
| int | start = 0, |
||
| int | end = MAX_32BIT_INT |
||
| ) | const |
Definition at line 847 of file String.h.
References agx::end().
| AgXString< T > agx::AgXString< T >::strip | ( | const AgXString< T > & | chars = "" | ) | const |
| AgXString< T > agx::AgXString< T >::stripLeadingString | ( | const AgXString< T > & | toBeRemoved | ) | const |
|
inline |
|
inline |
| AgXString< T > agx::AgXString< T >::swapcase |
| AgXString< T > agx::AgXString< T >::title |
| AgXString< T > agx::AgXString< T >::translate | ( | const AgXString< T > & | table, |
| const AgXString< T > & | deletechars = "" |
||
| ) | const |
| AgXString< T > agx::AgXString< T >::upper |
| AgXString< T > agx::AgXString< T >::zfill | ( | int | width | ) | const |