FXString provides essential string manipulation capabilities
Public Methods
-
FXString()
- Create empty string
-
FXString(const FXString& s)
- Copy construct
-
FXString(const FXchar* s)
- Construct and init
-
FXString(const FXchar* s, FXint n)
- Construct and init with substring
-
FXString(FXchar c, FXint n)
- Construct and fill with constant
-
FXString(const FXchar* s1, const FXchar* s2)
- Construct string from two parts
-
void size(FXint sz)
- Size to some desired capacity
-
FXint size() const
- Size of text data, 0 for empty string
-
FXint length() const
- Length of text
-
const FXchar* text() const
- Get text contents
-
FXbool empty() const
- See if string is empty
-
FXchar& operator[](FXint i)
- Return a non-const reference to the ith character
-
const FXchar& operator[](FXint i) const
- Return a const reference to the ith character
-
FXString& operator=(const FXString& s)
- Assign another string to this
-
FXString& operator=(const FXchar* s)
- Assign a C-style string to this
-
FXString& fill(FXchar c, FXint n)
- Fill with a constant
-
FXString& fill(FXchar c)
- Fill up to current length
-
FXString& lower()
- Convert to lower case
-
FXString& upper()
- Convert to upper case
-
FXString extract(FXint part, FXchar delim) const
- Extract partition of delimiter separated string
-
FXString extract(FXint part, FXchar delim, FXchar esc) const
- Extract partition of delimiter separated string
-
FXString& insert(FXint pos, FXchar c)
- Insert character at specified position
-
FXString& insert(FXint pos, FXchar c, FXint n)
- Insert n characters c at specified position
-
FXString& insert(FXint pos, const FXchar* s, FXint n)
- Insert first n characters of string at specified position
-
FXString& insert(FXint pos, const FXString& s)
- Insert string at specified position
-
FXString& insert(FXint pos, const FXchar* s)
- Insert string at specified position
-
FXString& prepend(FXchar c)
- Prepend string with input character
-
FXString& prepend(FXchar c, FXint n)
- Prepend string with n characters c
-
FXString& prepend(const FXchar* s, FXint n)
- Prepend string with first n characters of input string
-
FXString& prepend(const FXString& s)
- Prepend string with input string
-
FXString& prepend(const FXchar* s)
- Prepend string with input string
-
FXString& append(FXchar c)
- Append input character to this string
-
FXString& append(FXchar c, FXint n)
- Append input n characters c to this string
-
FXString& append(const FXchar* s, FXint n)
- Append first n characters of input string to this string
-
FXString& append(const FXString& s)
- Append input string to this string
-
FXString& append(const FXchar* s)
- Append input string to this string
-
FXString& replace(FXint pos, FXchar c)
- Replace a single character
-
FXString& replace(FXint pos, FXint m, FXchar c, FXint n)
- Replace the m characters at pos with n characters c
-
FXString& replace(FXint pos, FXint m, const FXchar* s, FXint n)
- Replaces the m characters at pos with first n characters of input string
-
FXString& replace(FXint pos, FXint m, const FXString& s)
- Replace the m characters at pos with input string
-
FXString& replace(FXint pos, FXint m, const FXchar* s)
- Replace the m characters at pos with input string
-
FXString& remove(FXint pos, FXint n=1)
- Remove substring
-
FXString& substitute(FXchar orig, FXchar sub)
- Substitute one character by another
-
FXString& trim()
- Remove leading and trailing whitespace
-
FXString& trimBegin()
- Remove leading whitespace
-
FXString& trimEnd()
- Remove trailing whitespace
-
FXString& trunc(FXint pos)
- Truncate string at pos
-
FXString& clear()
- Clear
-
FXString left(FXint n) const
- Get leftmost part
-
FXString right(FXint n) const
- Get rightmost part
-
FXString mid(FXint pos, FXint n) const
- Get some part in the middle
-
FXString before(FXchar ch, FXint n=1) const
- Return all characters before the n-th occurrence of ch, counting from the beginning of the string if n>0, or from the end if n<0.
-
FXString after(FXchar ch, FXint n=1) const
- Return all characters after the nth occurrence of ch, counting from the beginning of the string if n>0, or from the end if n<0.
-
FXint findf(FXchar c, FXint pos=0) const
- Find a character, searching forward; return position or -1
-
FXint findb(FXchar c, FXint pos=2147483647) const
- Find a character, searching backward; return position or -1
-
FXint findf(const FXchar* substr, FXint n, FXint pos) const
- Find a substring of length n, searching forward; return position or -1
-
FXint findb(const FXchar* substr, FXint n, FXint pos) const
- Find a substring of length n, searching backward; return position or -1
-
FXint findf(const FXchar* substr, FXint pos=0) const
- Find a substring, searching forward; return position or -1
-
FXint findb(const FXchar* substr, FXint pos=2147483647) const
- Find a substring, searching backward; return position or -1
-
FXint findf(const FXString &substr, FXint pos=0) const
- Find a substring, searching forward; return position or -1
-
FXint findb(const FXString &substr, FXint pos=2147483647) const
- Find a substring, searching backward; return position or -1
-
FXint count(FXchar c) const
- Find number of occurances of character in string
-
FXString&format (const char *fmt, ...)(2, 3)
- Format a string a-la printf
-
FXintscan (const char *fmt, ...) const (2, 3)
- Scan a string a-la scanf
-
FXint hash() const
- Get hash value
-
FXString& operator+=(const FXString& s)
- Append operators
-
~FXString()
- Delete
Documentation
FXString provides essential string manipulation capabilities
- FXString()
- Create empty string
- FXString(const FXString& s)
- Copy construct
- FXString(const FXchar* s)
- Construct and init
- FXString(const FXchar* s, FXint n)
- Construct and init with substring
- FXString(FXchar c, FXint n)
- Construct and fill with constant
- FXString(const FXchar* s1, const FXchar* s2)
- Construct string from two parts
- void size(FXint sz)
- Size to some desired capacity
- FXint size() const
- Size of text data, 0 for empty string
- FXint length() const
- Length of text
- const FXchar* text() const
- Get text contents
- FXbool empty() const
- See if string is empty
- FXchar& operator[](FXint i)
- Return a non-const reference to the ith character
- const FXchar& operator[](FXint i) const
- Return a const reference to the ith character
- FXString& operator=(const FXString& s)
- Assign another string to this
- FXString& operator=(const FXchar* s)
- Assign a C-style string to this
- FXString& fill(FXchar c, FXint n)
- Fill with a constant
- FXString& fill(FXchar c)
- Fill up to current length
- FXString& lower()
- Convert to lower case
- FXString& upper()
- Convert to upper case
- FXString extract(FXint part, FXchar delim) const
- Extract partition of delimiter separated string
- FXString extract(FXint part, FXchar delim, FXchar esc) const
- Extract partition of delimiter separated string
- FXString& insert(FXint pos, FXchar c)
- Insert character at specified position
- FXString& insert(FXint pos, FXchar c, FXint n)
- Insert n characters c at specified position
- FXString& insert(FXint pos, const FXchar* s, FXint n)
- Insert first n characters of string at specified position
- FXString& insert(FXint pos, const FXString& s)
- Insert string at specified position
- FXString& insert(FXint pos, const FXchar* s)
- Insert string at specified position
- FXString& prepend(FXchar c)
- Prepend string with input character
- FXString& prepend(FXchar c, FXint n)
- Prepend string with n characters c
- FXString& prepend(const FXchar* s, FXint n)
- Prepend string with first n characters of input string
- FXString& prepend(const FXString& s)
- Prepend string with input string
- FXString& prepend(const FXchar* s)
- Prepend string with input string
- FXString& append(FXchar c)
- Append input character to this string
- FXString& append(FXchar c, FXint n)
- Append input n characters c to this string
- FXString& append(const FXchar* s, FXint n)
- Append first n characters of input string to this string
- FXString& append(const FXString& s)
- Append input string to this string
- FXString& append(const FXchar* s)
- Append input string to this string
- FXString& replace(FXint pos, FXchar c)
- Replace a single character
- FXString& replace(FXint pos, FXint m, FXchar c, FXint n)
- Replace the m characters at pos with n characters c
- FXString& replace(FXint pos, FXint m, const FXchar* s, FXint n)
- Replaces the m characters at pos with first n characters of input string
- FXString& replace(FXint pos, FXint m, const FXString& s)
- Replace the m characters at pos with input string
- FXString& replace(FXint pos, FXint m, const FXchar* s)
- Replace the m characters at pos with input string
- FXString& remove(FXint pos, FXint n=1)
- Remove substring
- FXString& substitute(FXchar orig, FXchar sub)
- Substitute one character by another
- FXString& trim()
- Remove leading and trailing whitespace
- FXString& trimBegin()
- Remove leading whitespace
- FXString& trimEnd()
- Remove trailing whitespace
- FXString& trunc(FXint pos)
- Truncate string at pos
- FXString& clear()
- Clear
- FXString left(FXint n) const
- Get leftmost part
- FXString right(FXint n) const
- Get rightmost part
- FXString mid(FXint pos, FXint n) const
- Get some part in the middle
- FXString before(FXchar ch, FXint n=1) const
-
Return all characters before the n-th occurrence of ch,
counting from the beginning of the string if n>0, or
from the end if n<0.
If the character ch is not found, the entire string,
or the empty string, is returned, respectively.
A NULL string is returned if n==0.
- FXString after(FXchar ch, FXint n=1) const
-
Return all characters after the nth occurrence of ch,
counting from the beginning of the string if n>0, or from
the end if n<0.
If the character ch is not found, the empty string, or
the entire string, is returned, respectively.
A NULL string is returned if n==0.
- FXint findf(FXchar c, FXint pos=0) const
- Find a character, searching forward; return position or -1
- FXint findb(FXchar c, FXint pos=2147483647) const
- Find a character, searching backward; return position or -1
- FXint findf(const FXchar* substr, FXint n, FXint pos) const
- Find a substring of length n, searching forward; return position or -1
- FXint findb(const FXchar* substr, FXint n, FXint pos) const
- Find a substring of length n, searching backward; return position or -1
- FXint findf(const FXchar* substr, FXint pos=0) const
- Find a substring, searching forward; return position or -1
- FXint findb(const FXchar* substr, FXint pos=2147483647) const
- Find a substring, searching backward; return position or -1
- FXint findf(const FXString &substr, FXint pos=0) const
- Find a substring, searching forward; return position or -1
- FXint findb(const FXString &substr, FXint pos=2147483647) const
- Find a substring, searching backward; return position or -1
- FXint count(FXchar c) const
- Find number of occurances of character in string
- FXString&format (const char *fmt, ...)(2, 3)
- Format a string a-la printf
- FXintscan (const char *fmt, ...) const (2, 3)
- Scan a string a-la scanf
- FXint hash() const
- Get hash value
- FXString& operator+=(const FXString& s)
- Append operators
- ~FXString()
- Delete
- This class has no child classes.
- Friends:
- FXint compare(const FXchar *s1,const FXchar *s2)
FXint compare(const FXchar *s1,const FXString &s2)
FXint compare(const FXString &s1,const FXchar *s2)
FXint compare(const FXString &s1,const FXString &s2)
FXint compare(const FXchar *s1,const FXchar *s2,FXint n)
FXint compare(const FXchar *s1,const FXString &s2,FXint n)
FXint compare(const FXString &s1,const FXchar *s2,FXint n)
FXint compare(const FXString &s1,const FXString &s2,FXint n)
FXint comparecase(const FXchar *s1,const FXchar *s2)
FXint comparecase(const FXchar *s1,const FXString &s2)
FXint comparecase(const FXString &s1,const FXchar *s2)
FXint comparecase(const FXString &s1,const FXString &s2)
FXint comparecase(const FXchar *s1,const FXchar *s2,FXint n)
FXint comparecase(const FXchar *s1,const FXString &s2,FXint n)
FXint comparecase(const FXString &s1,const FXchar *s2,FXint n)
FXint comparecase(const FXString &s1,const FXString &s2,FXint n)
FXbool operator==(const FXString &s1,const FXString &s2)
FXbool operator==(const FXString &s1,const FXchar *s2)
FXbool operator==(const FXchar *s1,const FXString &s2)
FXbool operator!=(const FXString &s1,const FXString &s2)
FXbool operator!=(const FXString &s1,const FXchar *s2)
FXbool operator!=(const FXchar *s1,const FXString &s2)
FXbool operator<(const FXString &s1,const FXString &s2)
FXbool operator<(const FXString &s1,const FXchar *s2)
FXbool operator<(const FXchar *s1,const FXString &s2)
FXbool operator<=(const FXString &s1,const FXString &s2)
FXbool operator<=(const FXString &s1,const FXchar *s2)
FXbool operator<=(const FXchar *s1,const FXString &s2)
FXbool operator>(const FXString &s1,const FXString &s2)
FXbool operator>(const FXString &s1,const FXchar *s2)
FXbool operator>(const FXchar *s1,const FXString &s2)
FXbool operator>=(const FXString &s1,const FXString &s2)
FXbool operator>=(const FXString &s1,const FXchar *s2)
FXbool operator>=(const FXchar *s1,const FXString &s2)
FXString operator+(const FXString& s1,const FXString& s2)
FXString operator+(const FXString& s1,const FXchar* s2)
FXString operator+(const FXchar* s1,const FXString& s2)
FXString operator+(const FXString& s,FXchar c)
FXString operator+(FXchar c,const FXString& s)
FXStream& operator<<(FXStream& store,const FXString& s)
FXStream& operator>>(FXStream& store,FXString& s)
FXString FXStringFormat(const FXchar *fmt,...) FX_PRINTF(1,2)
FXString FXStringVFormat(const FXchar *fmt,va_list args)
FXString FXStringVal(FXint num,FXint base=10)
FXString FXStringVal(FXuint num,FXint base=10)
FXString FXStringVal(FXfloat num,FXint prec=6,FXbool exp=MAYBE)
FXString FXStringVal(FXdouble num,FXint prec=6,FXbool exp=MAYBE)
FXint FXIntVal(const FXString& s,FXint base=10)
FXuint FXUIntVal(const FXString& s,FXint base=10)
FXfloat FXFloatVal(const FXString& s)
FXdouble FXDoubleVal(const FXString& s)
Alphabetic index HTML hierarchy of classes or Java
This page was generated with the help of DOC++.