SophiaFramework UNIVERSE 5.3 |
SFXAnsiString and SFXWideString
In the BREW environment, there are two kinds of character types: one is the char type that represents the single/multi byte character(or the ANSI character) and the other is the AECHAR type that represents the double byte character of the uint16 type.
In SophiaFramewok UNIVERSE, these two kinds of character types are defined as AChar and WChar using typedef respectively. And two kinds of the following string classes are available:
All the functions of these two string classes are the same except their string types.
How to Empty a String
There are two methods to empty a string:
In the former method, its heap is not released. By block allocation support, to allocate new memory is unnecessary when a string is newly created in this heap. Therefore its processing speed is very fast.
In the latter method, its heap is released. Though the released heap is free for other tasks, its processing speed slows down.
Which method to choose depends upon the trade-off between processing speed and memory usage.
Example 847. Method 1: Substitute an empty string or call the SFXWideString::SetLength function:
SFXWideString str = "The best C++ Programming Environment for BREW"; str = "; // OR: str.SetLength(0); // the heap is not released
Example 848. Method 2: Call the Clear Function:
SFXWideString str = "The best C++ Programming Environment for BREW";
str.Clear();
// the heap is released
When short strings are frequently processed, the method of calling the SFXWideString::SetLength function is more efficient.
SFXWideString str; str = "BREW"; ... str.SetLength(0); ... str = "C++"; ... str.SetLength(0); ... str = "GUI"; ... str.SetLength(0); ... str = "XML"; ...
Attach Function and Detach Function
The SFXWideString::Attach function attaches the string area to the SFXWideString object. The SFXWideString::Detach function has the reverse functionality.
Though the data is copied by using the SFXWideString::Set function and the substitution operator(=), while using the SFXWideString::Attach function and the SFXWideString::Detach function, data will not be copied.
When there is not enough heap for copying a several hundreds KB string, or to avoid the performance deterioration, use these functions.
Constructor/Destructor |
---|
SFXWideString( Void ) Constructor of the SFXWideString class.
|
SFXWideString(
SFXWideStringConstRef string
) Constructor of the SFXWideString class.
|
SFXWideString(
SFXWideStringConstRef string
) Constructor of the SFXWideString class.
|
SFXWideString(
ACharConstPtr string
, SInt32 length = -1
) Constructor of the SFXWideString class.
|
SFXWideString(
WCharConstPtr string
, SInt32 length = -1
) Constructor of the SFXWideString class.
|
SFXWideString(
WChar character
) Constructor of the SFXWideString class.
|
SFXWideString(
SFXBufferConstRef buffer
) Constructor of the SFXWideString class.
|
SFXWideString(
UInt16 threshold
, UInt16 cluster
) Constructor of the SFXWideString class.
|
~SFXWideString( Void ) Destructor of the SFXWideString class.
|
Public Functions | |
---|---|
SFCError |
Add(
SFXWideStringConstRef string
) Add the specified string to the end of this string.
|
SFCError |
Add(
WCharConstPtr string
, SInt32 length = -1
) Add the specified string to the end of this string.
|
SFCError |
Add(
WChar character
) Add the specified string to the end of this string.
|
SFXWideString |
AsLower( Void ) Get this string converted to lower case.
|
SInt32 |
AsSInt32(
SInt32 substitute = 0
) Convert this string into the integer of the SInt32 type.
|
UInt32 |
AsUInt32(
UInt32 substitute = 0
) Convert this string into the integer of the UInt32 type.
|
SFXWideString |
AsUpper( Void ) Get this string converted to upper case.
|
SFCError |
Attach(
SFXWideStringPtr string
) Attach the specified string to this string object.
|
SFCError |
Attach(
WCharPtr string
, SInt32 length = -1
) Attach the specified string to this string object.
|
SFCError |
Attach(
SFXBufferPtr buffer
) Attach the specified string to this string object.
|
SFCError |
AttachSFXBuffer(
SFXBufferPtr buffer
) [DEPRECATED]Attach the specified buffer to this string object.
|
Void |
Clear( Void ) Clear this string.
|
SInt32 |
Compare(
SFXWideStringConstRef string
, Bool sensitive = true
) Compare this string with the specified string in dictionary order.
|
SInt32 |
Compare(
WCharConstPtr string
, Bool sensitive = true
) Compare this string with the specified string in dictionary order.
|
SFXWideString |
Concat(
SFXWideStringConstRef string
) Get the string obtained by concatenating this string and the specified string.
|
SFXWideString |
Concat(
WCharConstPtr string
, SInt32 length = -1
) Get the string obtained by concatenating this string and the specified string.
|
SFXWideString |
Concat(
WChar character
) Get the string obtained by concatenating this string and the specified string.
|
SFCError |
Copy(
SInt32 index
, SFXWideStringConstRef string
) Overwrite the specified substring of this string with the specified string.
|
SFCError |
Copy(
SInt32 index
, WCharConstPtr string
, SInt32 length = -1
) Overwrite the specified substring of this string with the specified string.
|
SFCError |
Detach(
SFXWideStringPtr string
) Detach the string area from this string object.
|
WCharPtr |
Detach(
SInt32Ptr length = null
) Detach the string area from this string object.
|
SFCError |
Detach(
SFXBufferPtr buffer
) Detach the string area from this string object.
|
SFCError |
DetachSFXBuffer(
SFXBufferPtr buffer
) [DEPRECATED]Detach the string area from this string object.
|
static SFXWideStringConstRef |
EmptyInstance( Void ) Get the empty string.
|
Bool |
EndsWith(
SFXWideStringConstRef string
, Bool sensitive = true
) Check whether the string ends with the specified string or not.
|
Bool |
EndsWith(
WCharConstPtr string
, Bool sensitive = true
) Check whether the string ends with the specified string or not.
|
Bool |
EndsWith(
WChar character
, Bool sensitive = true
) Check whether the string ends with the specified string or not.
|
Bool |
Equals(
SFXWideStringConstRef string
, Bool sensitive = true
) Check whether or not this string equals the specified string.
|
Bool |
Equals(
WCharConstPtr string
, Bool sensitive = true
) Check whether or not this string equals the specified string.
|
Void |
Fill(
WChar character
) Fill this string with specified character.
|
SInt32 |
FirstIndexOf(
SFXWideStringConstRef string
, SInt32 index = SINT32_MINIMUM
, Bool sensitive = true
) Get the first index of this string to match the specified value, searching from the beginning.
|
SInt32 |
FirstIndexOf(
WCharConstPtr string
, SInt32 index = SINT32_MINIMUM
, Bool sensitive = true
) Get the first index of this string to match the specified value, searching from the beginning.
|
SInt32 |
FirstIndexOf(
WChar character
, SInt32 index = SINT32_MINIMUM
, Bool sensitive = true
) Get the first index of this string to match the specified value, searching from the beginning.
|
static SFXWideString |
Format(
va_ref< SFXWideStringConst > format
, ...
) Create a string from the specified data by using the specified format.
|
static SFXWideString |
Format(
va_ref< SFXWideStringConst > format
, ...
) Create a string from the specified data by using the specified format.
|
static SFXWideString |
Format(
WCharConstPtr format
, ...
) Create a string from the specified data by using the specified format.
|
static SFXWideString |
Format(
WCharConstPtr format
, ...
) Create a string from the specified data by using the specified format.
|
static SFXWideString |
FormatV(
SFXWideStringConstRef format
, va_list argument
) Create a string from the variable-length argument by using the specified format.
|
static SFXWideString |
FormatV(
SFXWideStringConstRef format
, va_list argument
) Create a string from the variable-length argument by using the specified format.
|
static SFXWideString |
FormatV(
WCharConstPtr format
, va_list argument
) Create a string from the variable-length argument by using the specified format.
|
static SFXWideString |
FormatV(
WCharConstPtr format
, va_list argument
) Create a string from the variable-length argument by using the specified format.
|
WCharPtr |
GetBuffer( Void ) Get the pointer to the internal buffer of this string.
|
WCharConstPtr |
GetBuffer( Void ) Get the pointer to the internal buffer of this string.
|
WCharConstPtr |
GetCString( Void ) Get the const pointer to the internal buffer of this string.
|
WChar |
GetChar(
SInt32 index
) Get the character at the specified index of this string.
|
UInt16 |
GetCluster( Void ) Get the cluster size of the internal buffer memory of this string. [in bytes]
|
SInt32 |
GetLength( Void ) Get the length(number of the characters) of this string.
|
SInt32 |
GetLengthCString( Void ) Get the length(number of the characters) until the first "\0" character of this string.
|
UInt16 |
GetThreshold( Void ) Get the minimum size of the internal buffer memory of this string. [in bytes]
|
SFXWideString |
Insert(
SInt32 index
, SFXWideStringConstRef string
) Get the string obtained by inserting the specified string or character at the specified index of this string.
|
SFXWideString |
Insert(
SInt32 index
, WCharConstPtr string
, SInt32 length = -1
) Get the string obtained by inserting the specified string or character at the specified index of this string.
|
SFXWideString |
Insert(
SInt32 index
, WChar character
) Get the string obtained by inserting the specified string or character at the specified index of this string.
|
Bool |
IsAlpha( Void ) Check whether or not all the characters of this string are alphabetic.
|
Bool |
IsAlphaDigit( Void ) Check whether or not all the characters of this string are alphanumeric.
|
Bool |
IsAscii( Void ) Check whether or not all the characters of this string are ASCII.
|
Bool |
IsControl( Void ) Check whether or not all the characters of this string are the control characters.
|
Bool |
IsDigit( Void ) Check whether or not all the characters of this string are digit.
|
Bool |
IsEmpty( Void ) Check whether or not the length of this string is 0(this string is empty).
|
Bool |
IsEmptyCString( Void ) Check whether or not the first character of this string is null('\0').
|
Bool |
IsGraph( Void ) Check whether or not all the characters of this string are graphic.
|
Bool |
IsHexDigit( Void ) Check whether or not all the characters of this string are Hex digit.
|
Bool |
IsLower( Void ) Check whether or not all the characters of this string are lower-case.
|
Bool |
IsPrint( Void ) Check whether or not all the characters of this string are printable.
|
Bool |
IsPunct( Void ) Check whether or not all the characters of this string are not space nor alphanumeric but printable.
|
Bool |
IsSpace( Void ) Check whether or not all the characters of this string are space.
|
Bool |
IsUpper( Void ) Check whether or not all the characters of this string are upper-case.
|
Bool |
Isnull( Void ) Check whether or not all the characters of this string are null('\0').
|
SInt32 |
LastIndexOf(
SFXWideStringConstRef string
, SInt32 index = SINT32_MAXIMUM
, Bool sensitive = true
) Get the last index of this string to match the specified value, searching from the end.
|
SInt32 |
LastIndexOf(
WCharConstPtr string
, SInt32 index = SINT32_MAXIMUM
, Bool sensitive = true
) Get the last index of this string to match the specified value, searching from the end.
|
SInt32 |
LastIndexOf(
WChar character
, SInt32 index = SINT32_MAXIMUM
, Bool sensitive = true
) Get the last index of this string to match the specified value, searching from the end.
|
SFCError |
Mul(
SInt32 repeat
) Make this string repeated by the specified times.
|
SFXWideString |
Remove(
SInt32 begin
, SInt32 end
) Get the string obtained by removing characters in the specified range from this string.
|
SFXWideString |
Replace(
SFXWideStringConstRef fstring
, SFXWideStringConstRef tstring
, Bool sensitive = true
) Get the string obtained by replacing the specified substring in this string with the specified string.
|
SFXWideString |
Replace(
SFXWideStringConstRef fstring
, WCharConstPtr tstring
, Bool sensitive = true
) Get the string obtained by replacing the specified substring in this string with the specified string.
|
SFXWideString |
Replace(
SFXWideStringConstRef fstring
, WCharConstPtr tstring
, SInt32 tlength
, Bool sensitive = true
) Get the string obtained by replacing the specified substring in this string with the specified string.
|
SFXWideString |
Replace(
WCharConstPtr fstring
, SFXWideStringConstRef tstring
, Bool sensitive = true
) Get the string obtained by replacing the specified substring in this string with the specified string.
|
SFXWideString |
Replace(
WCharConstPtr fstring
, SInt32 flength
, SFXWideStringConstRef tstring
, Bool sensitive = true
) Get the string obtained by replacing the specified substring in this string with the specified string.
|
SFXWideString |
Replace(
WCharConstPtr fstring
, WCharConstPtr tstring
, Bool sensitive = true
) Get the string obtained by replacing the specified substring in this string with the specified string.
|
SFXWideString |
Replace(
WCharConstPtr fstring
, SInt32 flength
, WCharConstPtr tstring
, SInt32 tlength
, Bool sensitive = true
) Get the string obtained by replacing the specified substring in this string with the specified string.
|
SFXWideString |
Replace(
SFXWideStringConstRef fstring
, WChar tcharacter
, Bool sensitive = true
) Get the string obtained by replacing the specified substring in this string with the specified string.
|
SFXWideString |
Replace(
WChar fcharacter
, SFXWideStringConstRef tstring
, Bool sensitive = true
) Get the string obtained by replacing the specified substring in this string with the specified string.
|
SFXWideString |
Replace(
WChar fcharacter
, WChar tcharacter
, Bool sensitive = true
) Get the string obtained by replacing the specified substring in this string with the specified string.
|
SFXWideString |
Replace(
WCharConstPtr fstring
, WChar tcharacter
, Bool sensitive = true
) Get the string obtained by replacing the specified substring in this string with the specified string.
|
SFXWideString |
Replace(
WCharConstPtr fstring
, SInt32 flength
, WChar tcharacter
, Bool sensitive = true
) Get the string obtained by replacing the specified substring in this string with the specified string.
|
SFXWideString |
Replace(
WChar fcharacter
, WCharConstPtr tstring
, Bool sensitive = true
) Get the string obtained by replacing the specified substring in this string with the specified string.
|
SFXWideString |
Replace(
WChar fcharacter
, WCharConstPtr tstring
, SInt32 tlength
, Bool sensitive = true
) Get the string obtained by replacing the specified substring in this string with the specified string.
|
SFCError |
Set(
SFXWideStringConstRef string
) Set this string to the specified string, character, or buffer.
|
SFCError |
Set(
SFXWideStringConstRef string
) Set this string to the specified string, character, or buffer.
|
SFCError |
Set(
WCharConstPtr string
, SInt32 length = -1
) Set this string to the specified string, character, or buffer.
|
SFCError |
Set(
WCharConstPtr string
, SInt32 length = -1
) Set this string to the specified string, character, or buffer.
|
SFCError |
Set(
WChar character
) Set this string to the specified string, character, or buffer.
|
SFCError |
Set(
SFXBufferConstRef buffer
) Set this string to the specified string, character, or buffer.
|
SFCError |
SetChar(
SInt32 index
, WChar character
) Set the specified character at the specified index of this string.
|
Void |
SetCluster(
UInt16 size
) Set the cluster size of the internal buffer memory of this string. [in bytes]
|
SFCError |
SetLength(
SInt32 length
) Set the length of this string.
|
Void |
SetThreshold(
UInt16 size
) Set the minimum size of the internal buffer memory of this string. [in bytes]
|
Bool |
StartsWith(
SFXWideStringConstRef string
, Bool sensitive = true
) Check whether or not this string starts with the specified string.
|
Bool |
StartsWith(
WCharConstPtr string
, Bool sensitive = true
) Check whether or not this string starts with the specified string.
|
Bool |
StartsWith(
WChar character
, Bool sensitive = true
) Check whether or not this string starts with the specified string.
|
SFCError |
Sub(
SFXWideStringConstRef string
) Delete the specified string at the end of this string.
|
SFCError |
Sub(
WCharConstPtr string
, SInt32 length = -1
) Delete the specified string at the end of this string.
|
SFCError |
Sub(
WChar character
) Delete the specified string at the end of this string.
|
SFXWideString |
Substring(
SInt32 begin
, SInt32 end
) Get the sub-string in the specified range of this string.
|
Void |
ToLower( Void ) Convert this string to lower-case.
|
Void |
ToUpper( Void ) Convert this string to upper-case.
|
SFXWideString |
Trim(
SFXWideStringConstRef string
, Bool sensitive = true
) Get the string obtained by trimming the blank characters or the specified string/character from the head and tail of this string.
|
SFXWideString |
Trim(
WCharConstPtr string
, Bool sensitive = true
) Get the string obtained by trimming the blank characters or the specified string/character from the head and tail of this string.
|
SFXWideString |
Trim(
WChar character
, Bool sensitive = true
) Get the string obtained by trimming the blank characters or the specified string/character from the head and tail of this string.
|
SFXWideString |
Trim( Void ) Get the string obtained by trimming the blank characters or the specified string/character from the head and tail of this string.
|
SFXWideString |
TrimLeft(
SFXWideStringConstRef string
, Bool sensitive = true
) Get the string obtained by trimming the blank characters or the specified string/character from the head of this string.
|
SFXWideString |
TrimLeft(
WCharConstPtr string
, Bool sensitive = true
) Get the string obtained by trimming the blank characters or the specified string/character from the head of this string.
|
SFXWideString |
TrimLeft(
WChar character
, Bool sensitive = true
) Get the string obtained by trimming the blank characters or the specified string/character from the head of this string.
|
SFXWideString |
TrimLeft( Void ) Get the string obtained by trimming the blank characters or the specified string/character from the head of this string.
|
SFXWideString |
TrimRight(
SFXWideStringConstRef string
, Bool sensitive = true
) Get the string obtained by trimming the blank characters or the specified string/character from the tail of this string.
|
SFXWideString |
TrimRight(
WCharConstPtr string
, Bool sensitive = true
) Get the string obtained by trimming the blank characters or the specified string/character from the tail of this string.
|
SFXWideString |
TrimRight(
WChar character
, Bool sensitive = true
) Get the string obtained by trimming the blank characters or the specified string/character from the tail of this string.
|
SFXWideString |
TrimRight( Void ) Get the string obtained by trimming the blank characters or the specified string/character from the tail of this string.
|
SFXWideString |
Truncate( Void ) Get the string until the first null('\0') character of this string.
|
SFXWideStringRef |
operator*=(
SInt32 repeat
) Repeat the left-hand string by the right-hand times.
|
SFXWideStringRef |
operator+=(
SFXWideStringConstRef string
) Add the right-hand string to the end of the left-hand string.
|
SFXWideStringRef |
operator+=(
WCharConstPtr string
) Add the right-hand string to the end of the left-hand string.
|
SFXWideStringRef |
operator+=(
WChar character
) Add the right-hand string to the end of the left-hand string.
|
SFXWideStringRef |
operator-=(
SFXWideStringConstRef string
) Delete the right-hand string from the end of the left-hand string.
|
SFXWideStringRef |
operator-=(
WCharConstPtr string
) Delete the right-hand string from the end of the left-hand string.
|
SFXWideStringRef |
operator-=(
WChar character
) Delete the right-hand string from the end of the left-hand string.
|
SFXWideStringRef |
operator<<(
SFXWideStringRef left
, SFXWideStringConstRef right
) Add the right-hand string to the end of the left-hand string.
|
SFXWideStringRef |
operator<<(
SFXWideStringRef left
, SFXWideStringConstRef right
) Add the right-hand string to the end of the left-hand string.
|
SFXWideStringRef |
operator<<(
SFXWideStringRef left
, WCharConstPtr right
) Add the right-hand string to the end of the left-hand string.
|
SFXWideStringRef |
operator<<(
SFXWideStringRef left
, WCharConstPtr right
) Add the right-hand string to the end of the left-hand string.
|
SFXWideStringRef |
operator<<(
SFXWideStringRef left
, WChar right
) Add the right-hand string to the end of the left-hand string.
|
SFXWideStringRef |
operator=(
SFXWideStringConstRef string
) Assign the right-hand string to the left-hand string.
|
SFXWideStringRef |
operator=(
SFXWideStringConstRef string
) Assign the right-hand string to the left-hand string.
|
SFXWideStringRef |
operator=(
ACharConstPtr string
) Assign the right-hand string to the left-hand string.
|
SFXWideStringRef |
operator=(
WCharConstPtr string
) Assign the right-hand string to the left-hand string.
|
WCharRef |
operator[](
SInt32 index
) Get the character at the right-hand index of the left-hand string.
|
WCharConstRef |
operator[](
SInt32 index
) Get the character at the right-hand index of the left-hand string.
|
Bool |
operator==(
SFXWideStringConstRef left
, SFXWideStringConstRef right
) Check whether or not the left-hand string is the same with the right-hand string.
|
Bool |
operator==(
SFXWideStringConstRef left
, SFXWideStringConstRef right
) Check whether or not the left-hand string is the same with the right-hand string.
|
Bool |
operator==(
SFXWideStringConstRef left
, WCharConstPtr right
) Check whether or not the left-hand string is the same with the right-hand string.
|
Bool |
operator==(
SFXWideStringConstRef left
, WCharConstPtr right
) Check whether or not the left-hand string is the same with the right-hand string.
|
Bool |
operator==(
WCharConstPtr left
, SFXWideStringConstRef right
) Check whether or not the left-hand string is the same with the right-hand string.
|
Bool |
operator==(
WCharConstPtr left
, SFXWideStringConstRef right
) Check whether or not the left-hand string is the same with the right-hand string.
|
Bool |
operator>=(
SFXWideStringConstRef left
, SFXWideStringConstRef right
) Check whether or not the left-hand string is greater than or equals the right-hand string.
|
Bool |
operator>=(
SFXWideStringConstRef left
, SFXWideStringConstRef right
) Check whether or not the left-hand string is greater than or equals the right-hand string.
|
Bool |
operator>=(
SFXWideStringConstRef left
, WCharConstPtr right
) Check whether or not the left-hand string is greater than or equals the right-hand string.
|
Bool |
operator>=(
SFXWideStringConstRef left
, WCharConstPtr right
) Check whether or not the left-hand string is greater than or equals the right-hand string.
|
Bool |
operator>=(
WCharConstPtr left
, SFXWideStringConstRef right
) Check whether or not the left-hand string is greater than or equals the right-hand string.
|
Bool |
operator>=(
WCharConstPtr left
, SFXWideStringConstRef right
) Check whether or not the left-hand string is greater than or equals the right-hand string.
|
Bool |
operator>(
SFXWideStringConstRef left
, SFXWideStringConstRef right
) Check whether or not the left-hand string is greater than the right-hand string.
|
Bool |
operator>(
SFXWideStringConstRef left
, SFXWideStringConstRef right
) Check whether or not the left-hand string is greater than the right-hand string.
|
Bool |
operator>(
SFXWideStringConstRef left
, WCharConstPtr right
) Check whether or not the left-hand string is greater than the right-hand string.
|
Bool |
operator>(
SFXWideStringConstRef left
, WCharConstPtr right
) Check whether or not the left-hand string is greater than the right-hand string.
|
Bool |
operator>(
WCharConstPtr left
, SFXWideStringConstRef right
) Check whether or not the left-hand string is greater than the right-hand string.
|
Bool |
operator>(
WCharConstPtr left
, SFXWideStringConstRef right
) Check whether or not the left-hand string is greater than the right-hand string.
|
Bool |
operator<=(
SFXWideStringConstRef left
, SFXWideStringConstRef right
) Check whether or not the left-hand string is less than or equals the right-hand string.
|
Bool |
operator<=(
SFXWideStringConstRef left
, SFXWideStringConstRef right
) Check whether or not the left-hand string is less than or equals the right-hand string.
|
Bool |
operator<=(
SFXWideStringConstRef left
, WCharConstPtr right
) Check whether or not the left-hand string is less than or equals the right-hand string.
|
Bool |
operator<=(
SFXWideStringConstRef left
, WCharConstPtr right
) Check whether or not the left-hand string is less than or equals the right-hand string.
|
Bool |
operator<=(
WCharConstPtr left
, SFXWideStringConstRef right
) Check whether or not the left-hand string is less than or equals the right-hand string.
|
Bool |
operator<=(
WCharConstPtr left
, SFXWideStringConstRef right
) Check whether or not the left-hand string is less than or equals the right-hand string.
|
Bool |
operator<(
SFXWideStringConstRef left
, SFXWideStringConstRef right
) Check whether or not the left-hand string is less than the right-hand string.
|
Bool |
operator<(
SFXWideStringConstRef left
, SFXWideStringConstRef right
) Check whether or not the left-hand string is less than the right-hand string.
|
Bool |
operator<(
SFXWideStringConstRef left
, WCharConstPtr right
) Check whether or not the left-hand string is less than the right-hand string.
|
Bool |
operator<(
SFXWideStringConstRef left
, WCharConstPtr right
) Check whether or not the left-hand string is less than the right-hand string.
|
Bool |
operator<(
WCharConstPtr left
, SFXWideStringConstRef right
) Check whether or not the left-hand string is less than the right-hand string.
|
Bool |
operator<(
WCharConstPtr left
, SFXWideStringConstRef right
) Check whether or not the left-hand string is less than the right-hand string.
|
SFXWideString |
operator-(
SFXWideStringConstRef left
, SFXWideStringConstRef right
) Return the string obtained by deleting the right-hand string from the end of the left-hand string.
|
SFXWideString |
operator-(
SFXWideStringConstRef left
, SFXWideStringConstRef right
) Return the string obtained by deleting the right-hand string from the end of the left-hand string.
|
SFXWideString |
operator-(
SFXWideStringConstRef left
, WCharConstPtr right
) Return the string obtained by deleting the right-hand string from the end of the left-hand string.
|
SFXWideString |
operator-(
SFXWideStringConstRef left
, WCharConstPtr right
) Return the string obtained by deleting the right-hand string from the end of the left-hand string.
|
SFXWideString |
operator-(
WCharConstPtr left
, SFXWideStringConstRef right
) Return the string obtained by deleting the right-hand string from the end of the left-hand string.
|
SFXWideString |
operator-(
WCharConstPtr left
, SFXWideStringConstRef right
) Return the string obtained by deleting the right-hand string from the end of the left-hand string.
|
SFXWideString |
operator-(
SFXWideStringConstRef left
, WChar right
) Return the string obtained by deleting the right-hand string from the end of the left-hand string.
|
SFXWideString |
operator-(
WChar left
, SFXWideStringConstRef right
) Return the string obtained by deleting the right-hand string from the end of the left-hand string.
|
SFXWideString |
operator*(
SFXWideStringConstRef left
, SInt32 right
) Return the string obtained by repeating the left-hand string by the right-hand times.
|
Bool |
operator!=(
SFXWideStringConstRef left
, SFXWideStringConstRef right
) Check whether or not the left-hand string is different from the right-hand string.
|
Bool |
operator!=(
SFXWideStringConstRef left
, SFXWideStringConstRef right
) Check whether or not the left-hand string is different from the right-hand string.
|
Bool |
operator!=(
SFXWideStringConstRef left
, WCharConstPtr right
) Check whether or not the left-hand string is different from the right-hand string.
|
Bool |
operator!=(
SFXWideStringConstRef left
, WCharConstPtr right
) Check whether or not the left-hand string is different from the right-hand string.
|
Bool |
operator!=(
WCharConstPtr left
, SFXWideStringConstRef right
) Check whether or not the left-hand string is different from the right-hand string.
|
Bool |
operator!=(
WCharConstPtr left
, SFXWideStringConstRef right
) Check whether or not the left-hand string is different from the right-hand string.
|
SFXWideString |
operator+(
SFXWideStringConstRef left
, SFXWideStringConstRef right
) Return the string obtained by adding the right-hand string to the end of the left-hand string.
|
SFXWideString |
operator+(
SFXWideStringConstRef left
, SFXWideStringConstRef right
) Return the string obtained by adding the right-hand string to the end of the left-hand string.
|
SFXWideString |
operator+(
SFXWideStringConstRef left
, WCharConstPtr right
) Return the string obtained by adding the right-hand string to the end of the left-hand string.
|
SFXWideString |
operator+(
SFXWideStringConstRef left
, WCharConstPtr right
) Return the string obtained by adding the right-hand string to the end of the left-hand string.
|
SFXWideString |
operator+(
WCharConstPtr left
, SFXWideStringConstRef right
) Return the string obtained by adding the right-hand string to the end of the left-hand string.
|
SFXWideString |
operator+(
WCharConstPtr left
, SFXWideStringConstRef right
) Return the string obtained by adding the right-hand string to the end of the left-hand string.
|
SFXWideString |
operator+(
SFXWideStringConstRef left
, WChar right
) Return the string obtained by adding the right-hand string to the end of the left-hand string.
|
SFXWideString |
operator+(
WChar left
, SFXWideStringConstRef right
) Return the string obtained by adding the right-hand string to the end of the left-hand string.
|
Types |
---|
DefaultEnum Constants that represent the default values for the minimum size and the cluster size of the internal buffer memory. [in bytes]
|
Global Functions | |
---|---|
Bool |
operator==(
SFXWideStringConstRef left
, SFXWideStringConstRef right
) Check whether or not the left-hand string is the same with the right-hand string.
|
Bool |
operator==(
SFXWideStringConstRef left
, SFXWideStringConstRef right
) Check whether or not the left-hand string is the same with the right-hand string.
|
Bool |
operator==(
SFXWideStringConstRef left
, WCharConstPtr right
) Check whether or not the left-hand string is the same with the right-hand string.
|
Bool |
operator==(
SFXWideStringConstRef left
, WCharConstPtr right
) Check whether or not the left-hand string is the same with the right-hand string.
|
Bool |
operator==(
WCharConstPtr left
, SFXWideStringConstRef right
) Check whether or not the left-hand string is the same with the right-hand string.
|
Bool |
operator==(
WCharConstPtr left
, SFXWideStringConstRef right
) Check whether or not the left-hand string is the same with the right-hand string.
|
Bool |
operator>=(
SFXWideStringConstRef left
, SFXWideStringConstRef right
) Check whether or not the left-hand string is greater than or equals the right-hand string.
|
Bool |
operator>=(
SFXWideStringConstRef left
, SFXWideStringConstRef right
) Check whether or not the left-hand string is greater than or equals the right-hand string.
|
Bool |
operator>=(
SFXWideStringConstRef left
, WCharConstPtr right
) Check whether or not the left-hand string is greater than or equals the right-hand string.
|
Bool |
operator>=(
SFXWideStringConstRef left
, WCharConstPtr right
) Check whether or not the left-hand string is greater than or equals the right-hand string.
|
Bool |
operator>=(
WCharConstPtr left
, SFXWideStringConstRef right
) Check whether or not the left-hand string is greater than or equals the right-hand string.
|
Bool |
operator>=(
WCharConstPtr left
, SFXWideStringConstRef right
) Check whether or not the left-hand string is greater than or equals the right-hand string.
|
Bool |
operator>(
SFXWideStringConstRef left
, SFXWideStringConstRef right
) Check whether or not the left-hand string is greater than the right-hand string.
|
Bool |
operator>(
SFXWideStringConstRef left
, SFXWideStringConstRef right
) Check whether or not the left-hand string is greater than the right-hand string.
|
Bool |
operator>(
SFXWideStringConstRef left
, WCharConstPtr right
) Check whether or not the left-hand string is greater than the right-hand string.
|
Bool |
operator>(
SFXWideStringConstRef left
, WCharConstPtr right
) Check whether or not the left-hand string is greater than the right-hand string.
|
Bool |
operator>(
WCharConstPtr left
, SFXWideStringConstRef right
) Check whether or not the left-hand string is greater than the right-hand string.
|
Bool |
operator>(
WCharConstPtr left
, SFXWideStringConstRef right
) Check whether or not the left-hand string is greater than the right-hand string.
|
Bool |
operator<=(
SFXWideStringConstRef left
, SFXWideStringConstRef right
) Check whether or not the left-hand string is less than or equals the right-hand string.
|
Bool |
operator<=(
SFXWideStringConstRef left
, SFXWideStringConstRef right
) Check whether or not the left-hand string is less than or equals the right-hand string.
|
Bool |
operator<=(
SFXWideStringConstRef left
, WCharConstPtr right
) Check whether or not the left-hand string is less than or equals the right-hand string.
|
Bool |
operator<=(
SFXWideStringConstRef left
, WCharConstPtr right
) Check whether or not the left-hand string is less than or equals the right-hand string.
|
Bool |
operator<=(
WCharConstPtr left
, SFXWideStringConstRef right
) Check whether or not the left-hand string is less than or equals the right-hand string.
|
Bool |
operator<=(
WCharConstPtr left
, SFXWideStringConstRef right
) Check whether or not the left-hand string is less than or equals the right-hand string.
|
Bool |
operator<(
SFXWideStringConstRef left
, SFXWideStringConstRef right
) Check whether or not the left-hand string is less than the right-hand string.
|
Bool |
operator<(
SFXWideStringConstRef left
, SFXWideStringConstRef right
) Check whether or not the left-hand string is less than the right-hand string.
|
Bool |
operator<(
SFXWideStringConstRef left
, WCharConstPtr right
) Check whether or not the left-hand string is less than the right-hand string.
|
Bool |
operator<(
SFXWideStringConstRef left
, WCharConstPtr right
) Check whether or not the left-hand string is less than the right-hand string.
|
Bool |
operator<(
WCharConstPtr left
, SFXWideStringConstRef right
) Check whether or not the left-hand string is less than the right-hand string.
|
Bool |
operator<(
WCharConstPtr left
, SFXWideStringConstRef right
) Check whether or not the left-hand string is less than the right-hand string.
|
SFXWideString |
operator-(
SFXWideStringConstRef left
, SFXWideStringConstRef right
) Return the string obtained by deleting the right-hand string from the end of the left-hand string.
|
SFXWideString |
operator-(
SFXWideStringConstRef left
, SFXWideStringConstRef right
) Return the string obtained by deleting the right-hand string from the end of the left-hand string.
|
SFXWideString |
operator-(
SFXWideStringConstRef left
, WCharConstPtr right
) Return the string obtained by deleting the right-hand string from the end of the left-hand string.
|
SFXWideString |
operator-(
SFXWideStringConstRef left
, WCharConstPtr right
) Return the string obtained by deleting the right-hand string from the end of the left-hand string.
|
SFXWideString |
operator-(
WCharConstPtr left
, SFXWideStringConstRef right
) Return the string obtained by deleting the right-hand string from the end of the left-hand string.
|
SFXWideString |
operator-(
WCharConstPtr left
, SFXWideStringConstRef right
) Return the string obtained by deleting the right-hand string from the end of the left-hand string.
|
SFXWideString |
operator-(
SFXWideStringConstRef left
, WChar right
) Return the string obtained by deleting the right-hand string from the end of the left-hand string.
|
SFXWideString |
operator-(
WChar left
, SFXWideStringConstRef right
) Return the string obtained by deleting the right-hand string from the end of the left-hand string.
|
SFXWideString |
operator*(
SFXWideStringConstRef left
, SInt32 right
) Return the string obtained by repeating the left-hand string by the right-hand times.
|
Bool |
operator!=(
SFXWideStringConstRef left
, SFXWideStringConstRef right
) Check whether or not the left-hand string is different from the right-hand string.
|
Bool |
operator!=(
SFXWideStringConstRef left
, SFXWideStringConstRef right
) Check whether or not the left-hand string is different from the right-hand string.
|
Bool |
operator!=(
SFXWideStringConstRef left
, WCharConstPtr right
) Check whether or not the left-hand string is different from the right-hand string.
|
Bool |
operator!=(
SFXWideStringConstRef left
, WCharConstPtr right
) Check whether or not the left-hand string is different from the right-hand string.
|
Bool |
operator!=(
WCharConstPtr left
, SFXWideStringConstRef right
) Check whether or not the left-hand string is different from the right-hand string.
|
Bool |
operator!=(
WCharConstPtr left
, SFXWideStringConstRef right
) Check whether or not the left-hand string is different from the right-hand string.
|
SFXWideString |
operator+(
SFXWideStringConstRef left
, SFXWideStringConstRef right
) Return the string obtained by adding the right-hand string to the end of the left-hand string.
|
SFXWideString |
operator+(
SFXWideStringConstRef left
, SFXWideStringConstRef right
) Return the string obtained by adding the right-hand string to the end of the left-hand string.
|
SFXWideString |
operator+(
SFXWideStringConstRef left
, WCharConstPtr right
) Return the string obtained by adding the right-hand string to the end of the left-hand string.
|
SFXWideString |
operator+(
SFXWideStringConstRef left
, WCharConstPtr right
) Return the string obtained by adding the right-hand string to the end of the left-hand string.
|
SFXWideString |
operator+(
WCharConstPtr left
, SFXWideStringConstRef right
) Return the string obtained by adding the right-hand string to the end of the left-hand string.
|
SFXWideString |
operator+(
WCharConstPtr left
, SFXWideStringConstRef right
) Return the string obtained by adding the right-hand string to the end of the left-hand string.
|
SFXWideString |
operator+(
SFXWideStringConstRef left
, WChar right
) Return the string obtained by adding the right-hand string to the end of the left-hand string.
|
SFXWideString |
operator+(
WChar left
, SFXWideStringConstRef right
) Return the string obtained by adding the right-hand string to the end of the left-hand string.
|
[ public, explicit ] SFXWideString(Void);
[ public ] SFXAnsiString( SFXWideStringConstRef string // SFXAnsiString string to copy );
[ public ] SFXWideString( SFXWideStringConstRef string // SFXWideString string to copy );
[ public ] SFXWideString( ACharConstPtr string // pointer to the AChar string to copy SInt32 length = -1 // length of the AChar string );
[ public ] SFXWideString( WCharConstPtr string // pointer to the WChar string to copy SInt32 length = -1 // length of the WChar string to copy );
[ public, explicit ] SFXWideString( WChar character // character to set );
[ public, explicit ] SFXWideString( SFXBufferConstRef buffer // SFXBuffer buffer to copy );
[ public, explicit ] SFXWideString( UInt16 threshold // mininum size of the internal buffer memory UInt16 cluster // cluster size of the internal buffer memory );
If a string, character or buffer is specified in the argument, this constructer will set this string to the specified values by calling the SFXWideString::Set function internally.
If the cluster argument and the threshold argument are specified, the cluster size and the mininum size of the internal buffer memory will be set to the specified values by calling the SFXWideString::SetCluster function the SFXWideString::SetThreshold function internally.
[ public ] ~SFXWideString(Void);
This destructor releases the internal buffer memory of this string.
[ public ] SFCError Add( SFXWideStringConstRef string // string to add );
[ public ] SFCError Add( WCharConstPtr string // string to add SInt32 length = -1 // length of the string );
[ public ] SFCError Add( WChar character // character to add );
This function adds the specified string to the end of this string.
If the pointer to the WChar string is specified as an argument, the specified string will be regarded as the null-terminated string. Moreover, by specifying the length argument, a string including several null('\0') characters can be specified.
Note | |
---|---|
The value that is less than or equals the length of the string specified in the string argument must be specified in the length argument. If a negative value is specified, the length of the null-terminated string specified in the string argument will be assumed to be set. The default value of the length argument is "-1". |
Tip | |
---|---|
This function influences the content of this string. If you want to keep it unmodified, use the SFXWideString::Concat function. |
SFXWideString::Concat | SFXWideString::Sub | SFXWideString::Mul | SFXWideString::operator<< | operator+ | SFXWideString::operator+=
[ public, const ] SFXWideString AsLower(Void);
This string converted to lower case
This function gets this string converted to lower case.
Note | |
---|---|
This string will not be modified after this function is executed. |
[ public, const ] SInt32 AsSInt32( SInt32 substitute = 0 // the value when the conversion is failed );
Integer of the SInt32 type converted from this string
This function converts this string into the integer of the SInt32 type.
The " " chraracter in the head of this string will be ignored. The "+" or "-" character can be permitted to be placed at most once before the numeric string. If omitted, the numeric string will be regarded as the positive integer.
Tip | |
---|---|
If this conversion fails since characters other than " ", "+", "-", or number are included in this string, the value specified in the substitute argument will be returned. |
[ public, const ] UInt32 AsUInt32( UInt32 substitute = 0 // the value when the conversion is failed );
Integer of the UInt32 type converted from this string
This function converts this string into the integer of the UInt32 type.
The " " chraracter in the head of this string will be ignored. The "+" character can be permitted to be placed at most once before the numeric string.
Tip | |
---|---|
If this conversion fails since characters other than " ", "+", or number are included in this string, the value specified in the substitute argument will be returned. For instance, in case the "-" character appears before the numeric string, this conversion will fail. |
[ public, const ] SFXWideString AsUpper(Void);
This string converted to upper case
This function gets this string converted to upper case.
Note | |
---|---|
This string will not be modified after this function is executed. |
[ public ] SFCError Attach( SFXWideStringPtr string // SFXWideString string );
[ public ] SFCError Attach( WCharPtr string // WChar string SInt32 length = -1 // length of the string );
[ public ] SFCError Attach( SFXBufferPtr buffer // SFXBuffer buffer );
This function attaches the specified string to this string object. After this function is executed, the specified string can be handled as the SFXWideString object.
This function is more efficient than the SFXWideString::Set function, since the string is not copied and the problem on insufficient memory or performance deterioration can be avoided.
Note | |
---|---|
When this string object is released, the specified string will be released automatically together with this string object. |
SFXWideString string; WCharPtr char_ptr; // allocate the 10240-byte string area to char_ptr char_ptr = static_cast<WCharPtr>(MemoryAllocate(10240)); ... // attach the allocated char_ptr area to the string object string.Attach(char_ptr, 10240); // hereafter, the allocated char_ptr area can be handled as the string object ・・・ // after used, the allocated char_ptr area will be released automatically
[ public ] SFCError AttachSFXBuffer( SFXBufferPtr buffer // buffer );
Caution | |
---|---|
Since this function is deprecated, use the SFXWideString::Attach function. |
[ public ] Void Clear(Void);
This function clears this string.
Note | |
---|---|
The memory area allocated to this string before this function is executed will be released. |
[ public, const ] SInt32 Compare( SFXWideStringConstRef string // string to cpmpare with Bool sensitive = true // case-sensitive or not );
[ public, const ] SInt32 Compare( WCharConstPtr string // string to cpmpare with Bool sensitive = true // case-sensitive or not );
This function compares this string with the specified string in dictionary order.
Tip | |
---|---|
Case sensitive comparison can be specified in the sensitive argument. |
[ public, const ] SFXWideString Concat( SFXWideStringConstRef string // string to concatenate );
[ public, const ] SFXWideString Concat( WCharConstPtr string // string to concatenate SInt32 length = -1 // length of the string );
[ public, const ] SFXWideString Concat( WChar character // character to concatenate );
String obtained by concatenating this string and the specified string.
This function gets the string obtained by concatenating this string and the specified string.
If the pointer to the WChar string is specified as an argument, the specified string will be regarded as the null-terminated string. Moreover, by specifying the length argument, a string including several null('\0') characters can be specified.
Note | |
---|---|
The value that is less than or equals the length of the string specified in the string argument must be specified in the length argument. If a negative value is specified, the length of the null-terminated string specified in the string argument will be assumed to be set. The default value of the length argument is "-1". |
Tip | |
---|---|
Different from the SFXWideString::Add function, this string will not be modified after this function is executed. |
[ public ] SFCError Copy( SInt32 index // starting position to overwrite SFXWideStringConstRef string // string to overwrite with );
[ public ] SFCError Copy( SInt32 index // starting position to overwrite WCharConstPtr string // string to overwrite with SInt32 length = -1 // length of the string );
This function overwrites the specified substring of this string with the specified string.
If the end of the copied string exceeds that of this string or the index argument points to out of this string, SFERR_INVALID_PARAM will be return. This string will not be overwritten.
If the pointer to the WChar string is specified as an argument, the specified string will be regarded as the null-terminated string. Moreover, by specifying the length argument, a string including several null('\0') characters can be specified.
Note | |
---|---|
The value that is less than or equals the length of the string specified in the string argument must be specified in the length argument. If a negative value is specified, the length of the null-terminated string specified in the string argument will be assumed to be set. The default value of the length argument is "-1". |
[ public ] SFCError Detach( SFXWideStringPtr string // SFXWideString string to be detached );
[ public ] WCharPtr Detach( SInt32Ptr length = null // the pointer to the length of the WChar string to be detached );
[ public ] SFCError Detach( SFXBufferPtr buffer // SFXBuffer string to be detached );
Return the string which this string object has in case it is detached to the WChar string. Otherwise, return the SFCError object.
This function is more efficient than the SFXWideString::GetChar function, since the string area is not copied and the problem on insufficient memory or performance deterioration can be avoided.
SFXWideString string; WCharPtr char_ptr; SInt32 length; string = "The best application for BREW."; ... // detach the string area from this string object and set the char_ptr variable to this pointer // the size of the detached string area will be stored into the length variable char_ptr = string.Detach(&length); // hereafter, the string area of the string object will be handled via the char_ptr variable ... // after used, the detached string area must be released explicitly MemoryFree(char_ptr);
[ public ] SFCError DetachSFXBuffer( SFXBufferPtr buffer // pointer to the buffer to be detached );
Caution | |
---|---|
Since this function is deprecated, use the SFXWideString::Detach function. |
[ public, static ] SFXWideStringConstRef EmptyInstance(Void);
Empty string
This function gets the empty string.
Tip | |
---|---|
This function will used to return the reference to the empty string as the return value of a function. |
[ public, const ] Bool EndsWith( SFXWideStringConstRef string // string to check with Bool sensitive = true // case-sensitive or not );
[ public, const ] Bool EndsWith( WCharConstPtr string // string to check with Bool sensitive = true // case-sensitive or not );
[ public, const ] Bool EndsWith( WChar character // string to check with Bool sensitive = true // case-sensitive or not );
This function checks whether or not this string ends with the specified string.
Tip | |
---|---|
Case sensitive comparison can be specified in the sensitive argument. |
[ public, const ] Bool Equals( SFXWideStringConstRef string // string to compare with Bool sensitive = true // case-sensitive or not );
[ public, const ] Bool Equals( WCharConstPtr string // string to compare with Bool sensitive = true // case-sensitive or not );
This function checks whether or not this string equals the specified string.
Tip | |
---|---|
Case sensitive comparison can be specified in the sensitive argument. |
This function fills this string with the specified character.
[ public, const ] SInt32 FirstIndexOf( SFXWideStringConstRef string // string to match SInt32 index = SINT32_MINIMUM // beginning index to search from Bool sensitive = true // case-sensitive or not );
[ public, const ] SInt32 FirstIndexOf( WCharConstPtr string // string to match SInt32 index = SINT32_MINIMUM // beginning index to search from Bool sensitive = true // case-sensitive or not );
[ public, const ] SInt32 FirstIndexOf( WChar character // character to match SInt32 index = SINT32_MINIMUM // beginning index to search from Bool sensitive = true // case-sensitive or not );
This function gets the first index of this string to match the specified value, searching from the beginning.
The index argument is used to search from other than the beginning. (The origin index is 0.)
Tip | |
---|---|
Case sensitive comparison can be specified in the sensitive argument. |
[ public, static ] SFXWideString Format( va_ref< SFXWideStringConst > format // string that represents a format ... // data );
[ public, static ] SFXWideString Format( va_ref< SFXWideStringConst > format // string that represents a format ... // data );
[ public, static ] SFXWideString Format( WCharConstPtr format // string that represents a format ... // data );
[ public, static ] SFXWideString Format( WCharConstPtr format // string that represents a format ... // data );
This function creates a string from the specified data by using the specified format.
This function is almost the same as the printf function in C language, except that the floating-point format is not available.
Note | |
---|---|
For more details on the format, see BREW API SPRINTF. |
SIntN year = 2003; SIntN month = 8; SFXWideString str = SFXWideString::Format("%d Year %d Month ", year, month);
[ public, static ] SFXWideString FormatV( SFXWideStringConstRef format // string that represents a format va_list argument // variable-length argument );
[ public, static ] SFXWideString FormatV( SFXWideStringConstRef format // string that represents a format va_list argument // variable-length argument );
[ public, static ] SFXWideString FormatV( WCharConstPtr format // string that represents a format va_list argument // variable-length argument );
[ public, static ] SFXWideString FormatV( WCharConstPtr format // string that represents a format va_list argument // variable-length argument );
This function creates a string from the variable-length argument by using the specified format.
This function is almost the same as the printf function in C language, except that the floating-point format is not available.
Note | |
---|---|
For more details on the format, see BREW API SPRINTF. |
SFXWideString MyClass::variableArgument(SInt32 arg_num , ...)
{
va_list argument;
va_start(argument, arg_num);
SFXWideString str = SFXWideString::FormatV("%d Year %d Month %d Day %d Time %d Minute %d Second, It is %s today.", argument);
va_end(argument);
return str;
}
SFXWideString str = variableArgument(7, 2007, 7, 17, 17, 37, 50,"rainy");
// str = " 2007 Year 7 Month 17 Day 17 Time 37 Minute 50 Second, It is rainy today."
[ public ] WCharPtr GetBuffer(Void);
[ public, const ] WCharConstPtr GetBuffer(Void);
Pointer to the internal buffer of this string.
This function gets the pointer to the internal buffer of this string, through which data can be written into the internal buffer.
If this string is empty, null will be returned.
Caution | |
---|---|
You should not access the position over the length returned obtained by the SFXWideString::GetLength function from the position that the pointer to the internal buffer of this string. |
Difference between the GetBuffer function and the GetCString function | |
---|---|
When this string is empty, the SFXWideString::GetCString function will return the pointer to "\0", on the other hand, the SFXWideString::GetBuffer function will return null. Since the pointer returned by the SFXWideString::GetCString function is of the const type, no data can be written into the internal buffer through this pointer. To write data into the internal buffer, use the SFXWideString::GetBuffer function. |
[ public, const ] WCharConstPtr GetCString(Void);
Pointer of the WCharConstPtr type to the internal buffer of this string
This function gets the pointer of the WCharConstPtr type to the internal buffer of this string, through which data cannot be written into the internal buffer.
If this string is empty, the pointer to "\0" will be returned.
Difference between the GetBuffer function and the GetCString function | |
---|---|
When this string is empty, the SFXWideString::GetCString function will return the pointer to "\0", on the other hand, the SFXWideString::GetBuffer function will return null. Since the pointer returned by the SFXWideString::GetCString function is of the const type, no data can be written into the internal buffer through this pointer. To write data into the internal buffer, use the SFXWideString::GetBuffer function. |
Character at the specified index of this string. If this string is empty or the specified index is out of range of this string , null('\0') will be returned.
This function gets the character at the specified index of this string.
Caution | |
---|---|
If this string is empty or the specified index is out of range of this string , null('\0') will be returned. |
[ public, const ] UInt16 GetCluster(Void);
Cluster size of the internal buffer memory of this string. [in bytes]
This function gets cluster size of the internal buffer memory of this string. [in bytes]
[ public, const ] SInt32 GetLength(Void);
Length(number of the characters) of this string.
This function gets the length(number of the characters) of this string.
Note | |
---|---|
If this string includes "\0", "\0" will be counted. |
SFXWideString str("abc\0abc", 7); int i; i = str.GetLengthCString(); // i = 3 i = str.GetLength(); // i = 7
[ public, const ] SInt32 GetLengthCString(Void);
Length(number of the characters) until the first "\0" character of this string.
This function gets the length(number of the characters) until the first "\0" character of this string.
Note | |
---|---|
The first "\0" character will not be counted. |
SFXWideString str("abc\0abc", 7); int i; i = str.GetLengthCString(); // i = 3 i = str.GetLength(); // i = 7
[ public, const ] UInt16 GetThreshold(Void);
Minimum size of the internal buffer memory of this string. [in bytes]
This function gets the minimum size of the internal buffer memory of this string. [in bytes]
[ public, const ] SFXWideString Insert( SInt32 index // index to insert SFXWideStringConstRef string // string to insert );
[ public, const ] SFXWideString Insert( SInt32 index // index to insert WCharConstPtr string // string to insert SInt32 length = -1 // lengh of string to insert );
[ public, const ] SFXWideString Insert( SInt32 index // index to insert WChar character // character to insert );
String obtained by inserting the specified string or character at the specified index of this string.
This function gets the string obtained by inserting the specified string or character at the specified index of this string.
If the index argument is less than 0, 0 will be assumed to be specified. And if the index argument is greater than or equals the length of this string, "lenght of this string" will be assumed to be specified.
Caution | |
---|---|
The content of this string will not be modified by this operation. |
[ public, const ] Bool IsAlpha(Void);
This function checks whether or not all the characters of this string are alphabetic.
Caution | |
---|---|
If this string is empty, true will be returned. |
[ public, const ] Bool IsAlphaDigit(Void);
This function checks whether or not all the characters of this string are alphanumeric.
Caution | |
---|---|
If this string is empty, true will be returned. |
[ public, const ] Bool IsAscii(Void);
This function checks whether or not all the characters of this string are ASCII.
ASCII character | |
---|---|
The code of the ASCII character is greater than or equals 0x00 and less than or equals 0x7F. |
Caution | |
---|---|
If this string is empty, true will be returned. |
[ public, const ] Bool IsControl(Void);
This function checks whether or not all the characters of this string are the control characters.
Control character | |
---|---|
The code of the control character is less than 0x20, or equals 0x7F. |
Caution | |
---|---|
If this string is empty, true will be returned. |
[ public, const ] Bool IsDigit(Void);
This function checks whether or not all the characters of this string are digit.
Caution | |
---|---|
If this string is empty, true will be returned. |
[ public, const ] Bool IsEmpty(Void);
This function checks whether or not the length of this string is 0(this string is empty).
SFXWideString str("\0abc", 4); Bool b; b = str.IsEmptyCString(); // b = true b = str.IsEmpty(); // b = false
[ public, const ] Bool IsEmptyCString(Void);
This function checks whether or not the first character of this string is null('\0').
SFXWideString str("\0abc", 4); Bool b; b = str.IsEmptyCString(); // b = true b = str.IsEmpty(); // b = false
[ public, const ] Bool IsGraph(Void);
This function checks whether or not all the characters of this string are graphic.
Graphic character | |
---|---|
The graphic character is a printable character except the space character( 0x20 ). The code of the graphic character is greater than 0x20 and less than 0x7E. |
Caution | |
---|---|
If this string is empty, true will be returned. |
[ public, const ] Bool IsHexDigit(Void);
This function checks whether or not all the characters of this string are Hex digit(digit, or a, b, c, d, e, f, A, B, C, D, E, F).
Caution | |
---|---|
If this string is empty, true will be returned. |
[ public, const ] Bool IsLower(Void);
This function checks whether or not all the characters of this string are lower-case.
Caution | |
---|---|
If this string is empty, true will be returned. |
[ public, const ] Bool Isnull(Void);
This function checks whether or not all the characters of this string are null('\0').
Caution | |
---|---|
If this string is empty, true will be returned. |
[ public, const ] Bool IsPrint(Void);
This function checks whether or not all the characters of this string are printable.
Printable character | |
---|---|
The printable character is the character that can be displayed. The code of the printable character is greater than or equals 0x20 and less than 0x7E. |
Caution | |
---|---|
If this string is empty, true will be returned. |
[ public, const ] Bool IsPunct(Void);
This function checks whether or not all the characters of this string are not space nor alphanumeric but printable.
Caution | |
---|---|
If this string is empty, true will be returned. |
[ public, const ] Bool IsSpace(Void);
This function checks whether or not all the characters of this string are space.
Space character | |
---|---|
The code of the space character including tab, line-feed, and carriage return is from 0x09 to 0x0D or 0x20. |
Caution | |
---|---|
If this string is empty, true will be returned. |
[ public, const ] Bool IsUpper(Void);
This function checks whether or not all the characters of this string are upper-case.
Caution | |
---|---|
If this string is empty, true will be returned. |
[ public, const ] SInt32 LastIndexOf( SFXWideStringConstRef string // string to match SInt32 index = SINT32_MAXIMUM // beginning index to search from Bool sensitive = true // case-sensitive or not );
[ public, const ] SInt32 LastIndexOf( WCharConstPtr string // string to match SInt32 index = SINT32_MAXIMUM // beginning index to search from Bool sensitive = true // case-sensitive or not );
[ public, const ] SInt32 LastIndexOf( WChar character // character to match SInt32 index = SINT32_MAXIMUM // beginning index to search from Bool sensitive = true // case-sensitive or not );
This function gets the last index of this string to match the specified value, searching from the end.
The index argument is used to search from other than the end. (The origin index is 0.)
Tip | |
---|---|
Case sensitive comparison can be specified in the sensitive argument. |
This function makes this string repeated by the specified times.
This string will be updated after this function is executed. To presereve this string, copy it somewhere beforehand.
SFXWideString str("abc");
str.Mul(3); // str = "abcabcabc"
SFXWideString::Add | SFXWideString::Sub | operator* | SFXWideString::operator*=
[ public, const ] SFXWideString Remove( SInt32 begin // beginning index(this index is included) SInt32 end // ending index(this index is not included) );
String obtained by removing characters in the specified range from this string.
This function gets the string obtained by removing characters in the specified range from this string.
If the begin argument is greater than or equals the end argument, no character will be removed from this string.
If the begin argument is less than 0, 0 will be assumed to be specified. And if the end argument is greater than the length of this string, "the length of this string" will be assumed to be specified.
Note | |
---|---|
This function will not change the content of this string. |
[ public, const ] SFXWideString Replace( SFXWideStringConstRef fstring // string to be replaced SFXWideStringConstRef tstring // string to replace with Bool sensitive = true // case-sensitive or not );
[ public, const ] SFXWideString Replace( SFXWideStringConstRef fstring // string to be replaced WCharConstPtr tstring // string to replace with Bool sensitive = true // case-sensitive or not );
[ public, const ] SFXWideString Replace( SFXWideStringConstRef fstring // string to be replaced WCharConstPtr tstring // string to replace with SInt32 tlength // length of string to replace with Bool sensitive = true // case-sensitive or not );
[ public, const ] SFXWideString Replace( WCharConstPtr fstring // string to be replaced SFXWideStringConstRef tstring // string to replace with Bool sensitive = true // case-sensitive or not );
[ public, const ] SFXWideString Replace( WCharConstPtr fstring // string to be replaced SInt32 flength // length of string to be replaced SFXWideStringConstRef tstring // string to replace with Bool sensitive = true // case-sensitive or not );
[ public, const ] SFXWideString Replace( WCharConstPtr fstring // string to be replaced WCharConstPtr tstring // string to replace with Bool sensitive = true // case-sensitive or not );
[ public, const ] SFXWideString Replace( WCharConstPtr fstring // string to be replaced SInt32 flength // length of string to be replaced WCharConstPtr tstring // string to replace with SInt32 tlength // length of string to replace with Bool sensitive = true // case-sensitive or not );
[ public, const ] SFXWideString Replace( SFXWideStringConstRef fstring // string to be replaced WChar tcharacter // character to replace with Bool sensitive = true // case-sensitive or not );
[ public, const ] SFXWideString Replace( WChar fcharacter // character to be replaced SFXWideStringConstRef tstring // string to replace with Bool sensitive = true // case-sensitive or not );
[ public, const ] SFXWideString Replace( WChar fcharacter // character to be replaced WChar tcharacter // character to replace with Bool sensitive = true // case-sensitive or not );
[ public, const ] SFXWideString Replace( WCharConstPtr fstring // string to be replaced WChar tcharacter // character to replace with Bool sensitive = true // case-sensitive or not );
[ public, const ] SFXWideString Replace( WCharConstPtr fstring // string to be replaced SInt32 flength // length of string to be replaced WChar tcharacter // character to replace with Bool sensitive = true // case-sensitive or not );
[ public, const ] SFXWideString Replace( WChar fcharacter // character to be replaced WCharConstPtr tstring // string to replace with Bool sensitive = true // case-sensitive or not );
[ public, const ] SFXWideString Replace( WChar fcharacter // character to be replaced WCharConstPtr tstring // string to replace with SInt32 tlength // length of string to replace with Bool sensitive = true // case-sensitive or not );
String obtained by replacing the specified substring in this string with the specified string.
This function gets the string obtained by replacing the specified substring in this string with the specified string.
Note | |
---|---|
The value that is less than or equals the length of the string specified in the fstring / tstring argument must be specified in the flength / tlength argument. If a negative value is specified, the length of the string specified in the fstring / tstring argument will be assumed to be set. |
Tip | |
---|---|
Case sensitive comparison can be specified in the sensitive argument. |
Note | |
---|---|
This function will not change the content of this string. |
[ public ] SFCError Set( SFXWideStringConstRef string // source string of WChar type );
[ public ] SFCError Set( SFXWideStringConstRef string // source string of WChar type );
[ public ] SFCError Set( WCharConstPtr string // WChar pointer to the source string SInt32 length = -1 // length of the string );
[ public ] SFCError Set( WCharConstPtr string // WChar pointer to the source string SInt32 length = -1 // length of the string );
[ public ] SFCError Set( WChar character // WChar character of source string );
[ public ] SFCError Set( SFXBufferConstRef buffer // buffer of source string );
This function sets this string to the specified string, character, or buffer.
If the SFXAnsiString or SFXWideString instance is specified as an argument, its string value will be copied and set.
If the pointer to the AChar or WChar string is specified as an argument, the specified string will be regarded as the null-terminated string. Moreover, by specifying the length argument, a string including several null('\0') characters can be specified.
Note | |
---|---|
The value that is less than or equals the length of the string specified in the string argument must be specified in the length argument. If a negative value is specified, the length of the null-terminated string specified in the string argument will be assumed to be set. The default value of the length argument is "-1". |
Note | |
---|---|
If this function fails due to insufficient memory, the content of this string will not be modified. |
[ public ] SFCError SetChar( SInt32 index // index where a character is set WChar character // character to set );
This function sets the specified character at the specified index of this string.
Concretely, the specified character will be set at the specified index of the internal buffer of this string.
Note | |
---|---|
If the specified index is out of range of the internal buffer of this string or this string is empty, SFERR_INVALID_PARAM will be returned. |
This function sets the minimum unit to allocate the internal buffer memory(SFXClusterHeap) of this string to the specified value. [in bytes]
Default: SFXWideString::DEFAULT_CLUSTER bytes
For the value of SFXWideString::DEFAULT_CLUSTER, see SFXWideString::DefaultEnum.
SFXWideString::GetCluster | SFXWideString::DefaultEnum | SFXClusterHeap::SetCluster | SFXClusterHeap
This function sets the length of this string to the specified value.
If the specified length is shorter than this string, the characters after the specified length of this string will be lost. On the other hand, if the specified length is longer than this string, this string will be extended with a null('\0') character.
This function sets the minimum memory of the internal buffer memory(SFXClusterHeap) of this string to the specified value. [in bytes]
Default: SFXWideString::DEFAULT_THRESHOLD bytes
For the value of SFXWideString::DEFAULT_THRESHOLD, see SFXWideString::DefaultEnum.
SFXWideString::GetThreshold | SFXWideString::DefaultEnum | SFXClusterHeap::SetThreshold | SFXClusterHeap
[ public, const ] Bool StartsWith( SFXWideStringConstRef string // string to check with Bool sensitive = true // case-sensitive or not );
[ public, const ] Bool StartsWith( WCharConstPtr string // string to check with Bool sensitive = true // case-sensitive or not );
[ public, const ] Bool StartsWith( WChar character // character to check with Bool sensitive = true // case-sensitive or not );
This function checks whether or not this string starts with the specified string.
[ public ] SFCError Sub( SFXWideStringConstRef string // string to delete );
[ public ] SFCError Sub( WCharConstPtr string // string to delete SInt32 length = -1 // length of the string );
[ public ] SFCError Sub( WChar character // character to delete );
This function deletes the specified string at the end of this string.
If this string ends with the specified string, the specified string will be deleted from this string. Otherwise, nothing will happen.
If the pointer to the WChar string is specified as an argument, the specified string will be regarded as the null-terminated string. Moreover, by specifying the length argument, a string including several null('\0') characters can be specified.
Note | |
---|---|
The value that is less than or equals the length of the string specified in the string argument must be specified in the length argument. If a negative value is specified, the length of the null-terminated string specified in the string argument will be assumed to be set. The default value of the length argument is "-1". |
Tip | |
---|---|
This function influences the content of this string. If you want to keep it unmodified, use the operator- operator. |
[ public, const ] SFXWideString Substring( SInt32 begin // beginning index(this index is included) SInt32 end // ending index(this index is not included) );
Sub-string in the specified range of this string.
This function gets the sub-string in the specified range of this string.
The string from the ("begin" + 1)th character to the ("end")th character will be returned. Its length is (end - begin).
If the begin argument is greater than or equals the end argument, the null string is returned.
If the begin argument is less than 0, 0 will be assumed to be specified. And if the end argument is greater than the length of this string, "the length of this string" will be assumed to be specified.
Tip | |
---|---|
This string will not be modified after this function is executed. |
SFXWideString str1("American");
SFXWideString str2 = str1.Substring(2, 6); // str2 = "eric"
[ public ] Void ToLower(Void);
This function converts this string to lower-case.
Note | |
---|---|
This function influences the content of this string. If you want to keep it unmodified, use the SFXWideString::AsLower function. |
[ public ] Void ToUpper(Void);
This function converts this string to upper-case.
Note | |
---|---|
This function influences the content of this string. If you want to keep it unmodified, use the SFXWideString::AsUpper function. |
[ public, const ] SFXWideString Trim( SFXWideStringConstRef string // string to trim Bool sensitive = true // case-sensitive or not );
[ public, const ] SFXWideString Trim( WCharConstPtr string // string to trim Bool sensitive = true // case-sensitive or not );
[ public, const ] SFXWideString Trim( WChar character // string to trim Bool sensitive = true // case-sensitive or not );
[ public, const ] SFXWideString Trim(Void);
String obtained by trimming the blank characters or the specified string/character from the head and tail of this string.
This function gets the string obtained by trimming the blank characters or the specified string/character from the head and tail of this string.
If no argument is specified, the blank characters(space, tab, vertical tab, linefeed, return, formfeed) will be trimmed from the head and tail of this string.
If arguments are specified, the specified string/character will be trimmed from the head and tail of this string.
Tip | |
---|---|
Case sensitive comparison can be specified in the sensitive argument. |
Note | |
---|---|
This function will not change the content of this string. |
SFXWideString str1("\t delicious beef "); SFXWideString str2 = str1.Trim(); // str2 = "delicious beef" SFXWideString str3 = str2.Trim("adef"); // str3 = "licious b"
[ public, const ] SFXWideString TrimLeft( SFXWideStringConstRef string // string to trim Bool sensitive = true // case-sensitive or not );
[ public, const ] SFXWideString TrimLeft( WCharConstPtr string // string to trim Bool sensitive = true // case-sensitive or not );
[ public, const ] SFXWideString TrimLeft( WChar character // string to trim Bool sensitive = true // case-sensitive or not );
[ public, const ] SFXWideString TrimLeft(Void);
String obtained by trimming the blank characters or the specified string/character from the head of this string.
This function gets the string obtained by trimming the blank characters or the specified string/character from the head of this string.
If no argument is specified, the blank characters(space, tab, vertical tab, linefeed, return, formfeed) will be trimmed from the head of this string.
If arguments are specified, the specified string/character will be trimmed from the head of this string.
Tip | |
---|---|
Case sensitive comparison can be specified in the sensitive argument. |
Note | |
---|---|
This function will not change the content of this string. |
SFXWideString str1("\t delicious beef "); SFXWideString str2 = str1.TrimLeft(); // str2 = "delicious beef " SFXWideString str3 = str2.TrimLeft("adef"); // str3 = "licious beef "
[ public, const ] SFXWideString TrimRight( SFXWideStringConstRef string // string to trim Bool sensitive = true // case-sensitive or not );
[ public, const ] SFXWideString TrimRight( WCharConstPtr string // string to trim Bool sensitive = true // case-sensitive or not );
[ public, const ] SFXWideString TrimRight( WChar character // string to trim Bool sensitive = true // case-sensitive or not );
[ public, const ] SFXWideString TrimRight(Void);
String obtained by trimming the blank characters or the specified string/character from the tail of this string.
This function gets the string obtained by trimming the blank characters or the specified string/character from the tail of this string.
If no argument is specified, the blank characters(space, tab, vertical tab, linefeed, return, formfeed) will be trimmed from the tail of this string.
If arguments are specified, the specified string/character will be trimmed from the tail of this string.
Tip | |
---|---|
Case sensitive comparison can be specified in the sensitive argument. |
Note | |
---|---|
This function will not change the content of this string. |
SFXWideString str1("\t delicious beef "); SFXWideString str2 = str1.TrimRight(); // str2 = "\t delicious beef" SFXWideString str3 = str2.TrimRight("adef"); // str3 = "\t delicious b"
[ public, const ] SFXWideString Truncate(Void);
String until the first null('\0') character of this string.
Note | |
---|---|
This function will not change the content of this string. |
This function gets the string until the first null('\0') character of this string.
SFXWideString str1("abc\0abc", 7);
SFXWideString str2 = str1.Truncate(); // str2 = "abc"
[ public ] SFXWideStringRef operator=( SFXWideStringConstRef string // source string of WChar type );
[ public ] SFXWideStringRef operator=( SFXWideStringConstRef string // source string of WChar type );
[ public ] SFXWideStringRef operator=( ACharConstPtr string // AChar pointer of source string );
[ public ] SFXWideStringRef operator=( WCharConstPtr string // WChar pointer of source string );
This operator assigns the right-hand string to the left-hand string.
If the SFXAnsiString or SFXWideString instance is specified as the right-hand string, it will be copied and assigned.
If the pointer to the AChar or WChar string is specified as the right-hand string, it will be regarded as the null-terminated string.
Tip | |
---|---|
This operator influences the content of the left-hand string. |
[ public, friend ] Bool operator==( SFXWideStringConstRef left // string to compare SFXWideStringConstRef right // string to compare );
[ public, friend ] Bool operator==( SFXWideStringConstRef left // string to compare SFXWideStringConstRef right // string to compare );
[ public, friend ] Bool operator==( SFXWideStringConstRef left // string to compare WCharConstPtr right // string to compare );
[ public, friend ] Bool operator==( SFXWideStringConstRef left // string to compare WCharConstPtr right // string to compare );
[ public, friend ] Bool operator==( WCharConstPtr left // string to compare SFXWideStringConstRef right // string to compare );
[ public, friend ] Bool operator==( WCharConstPtr left // string to compare SFXWideStringConstRef right // string to compare );
This operator checks whether or not the left-hand string is the same with the right-hand string.
[ public, friend ] Bool operator>=( SFXWideStringConstRef left // string to compare SFXWideStringConstRef right // string to compare );
[ public, friend ] Bool operator>=( SFXWideStringConstRef left // string to compare SFXWideStringConstRef right // string to compare );
[ public, friend ] Bool operator>=( SFXWideStringConstRef left // string to compare WCharConstPtr right // string to compare );
[ public, friend ] Bool operator>=( SFXWideStringConstRef left // string to compare WCharConstPtr right // string to compare );
[ public, friend ] Bool operator>=( WCharConstPtr left // string to compare SFXWideStringConstRef right // string to compare );
[ public, friend ] Bool operator>=( WCharConstPtr left // string to compare SFXWideStringConstRef right // string to compare );
This operator checks whether or not the left-hand string is greater than or equals the right-hand string.
[ public, friend ] Bool operator>( SFXWideStringConstRef left // string to compare SFXWideStringConstRef right // string to compare );
[ public, friend ] Bool operator>( SFXWideStringConstRef left // string to compare SFXWideStringConstRef right // string to compare );
[ public, friend ] Bool operator>( SFXWideStringConstRef left // string to compare WCharConstPtr right // string to compare );
[ public, friend ] Bool operator>( SFXWideStringConstRef left // string to compare WCharConstPtr right // string to compare );
[ public, friend ] Bool operator>( WCharConstPtr left // string to compare SFXWideStringConstRef right // string to compare );
[ public, friend ] Bool operator>( WCharConstPtr left // string to compare SFXWideStringConstRef right // string to compare );
This operator checks whether or not the left-hand string is greater than the right-hand string.
SFXWideString::Compare | operator>= | operator< | operator<=
[ public ] WCharRef operator[]( SInt32 index // index position of string to get );
[ public, const ] WCharConstRef operator[]( SInt32 index // index position of string to get );
This operator gets the character at the right-hand index of the left-hand string.
Caution | |
---|---|
If the left-hand string is empty or the right-hand index is out of range of the left-hand string, null('\0') will be returned. |
[ public, friend ] SFXWideStringRef operator<<( SFXWideStringRef left // target string SFXWideStringConstRef right // string to append );
[ public, friend ] SFXWideStringRef operator<<( SFXWideStringRef left // target string SFXWideStringConstRef right // string to append );
[ public, friend ] SFXWideStringRef operator<<( SFXWideStringRef left // target string WCharConstPtr right // string to append );
[ public, friend ] SFXWideStringRef operator<<( SFXWideStringRef left // target string WCharConstPtr right // string to append );
[ public, friend ] SFXWideStringRef operator<<( SFXWideStringRef left // target string WChar right // string to append );
This operator adds the right-hand string to the end of the left-hand string.
Tip | |
---|---|
This operator influences the content of the left-hand string. This operator is very useful to concatenate multiple strings. |
SFXWideString str = "abc";
str << "def" << "ghi"; // str = "abcdefghi"
[ public, friend ] Bool operator<=( SFXWideStringConstRef left // string to compare SFXWideStringConstRef right // string to compare );
[ public, friend ] Bool operator<=( SFXWideStringConstRef left // string to compare SFXWideStringConstRef right // string to compare );
[ public, friend ] Bool operator<=( SFXWideStringConstRef left // string to compare WCharConstPtr right // string to compare );
[ public, friend ] Bool operator<=( SFXWideStringConstRef left // string to compare WCharConstPtr right // string to compare );
[ public, friend ] Bool operator<=( WCharConstPtr left // string to compare SFXWideStringConstRef right // string to compare );
[ public, friend ] Bool operator<=( WCharConstPtr left // string to compare SFXWideStringConstRef right // string to compare );
This operator checks whether or not the left-hand string is less than or equals the right-hand string.
[ public, friend ] Bool operator<( SFXWideStringConstRef left // string to compare SFXWideStringConstRef right // string to compare );
[ public, friend ] Bool operator<( SFXWideStringConstRef left // string to compare SFXWideStringConstRef right // string to compare );
[ public, friend ] Bool operator<( SFXWideStringConstRef left // string to compare WCharConstPtr right // string to compare );
[ public, friend ] Bool operator<( SFXWideStringConstRef left // string to compare WCharConstPtr right // string to compare );
[ public, friend ] Bool operator<( WCharConstPtr left // string to compare SFXWideStringConstRef right // string to compare );
[ public, friend ] Bool operator<( WCharConstPtr left // string to compare SFXWideStringConstRef right // string to compare );
This operator checks whether or not the left-hand string is less than the right-hand string.
SFXWideString::Compare | operator> | operator>= | operator<=
[ public ] SFXWideStringRef operator-=( SFXWideStringConstRef string // string to delete from the end );
[ public ] SFXWideStringRef operator-=( WCharConstPtr string // string to delete from the end );
[ public ] SFXWideStringRef operator-=( WChar character // character to delete from the end );
This operator deletes the right-hand string from the end of the left-hand string.
If the right-hand string exists at the end of the left-hand string, the right-hand string will be deleted from the end of the left-hand string.
Otherwise, nothing will happen.
Tip | |
---|---|
This operator influences the content of the left-hand string. |
[ public, friend ] SFXWideString operator-( SFXWideStringConstRef left // target string SFXWideStringConstRef right // string to delete from the end );
[ public, friend ] SFXWideString operator-( SFXWideStringConstRef left // target string SFXWideStringConstRef right // string to delete from the end );
[ public, friend ] SFXWideString operator-( SFXWideStringConstRef left // target string WCharConstPtr right // string to delete from the end );
[ public, friend ] SFXWideString operator-( SFXWideStringConstRef left // target string WCharConstPtr right // string to delete from the end );
[ public, friend ] SFXWideString operator-( WCharConstPtr left // target string SFXWideStringConstRef right // string to delete from the end );
[ public, friend ] SFXWideString operator-( WCharConstPtr left // target string SFXWideStringConstRef right // string to delete from the end );
[ public, friend ] SFXWideString operator-( SFXWideStringConstRef left // target string WChar right // character to delete from the end );
[ public, friend ] SFXWideString operator-( WChar left // target Character SFXWideStringConstRef right // string to delete from the end );
This operator returns the string obtained by deleting the right-hand string from the end of the left-hand string.
If the right-hand string exists at the end of the left-hand string, the string by deleting the right-hand string from the end of the left-hand string will be returned.
Otherwise, the left-hand string at it is will be returned.
SFXWideString str1("Hello World");
SFXWideString str2(" World");
SFXWideString str3 = str1 - str2; // str3 = "Hello"
[ public ] SFXWideStringRef operator*=( SInt32 repeat // times to repeat );
This operator repeats the left-hand string by the right-hand times.
Tip | |
---|---|
This operator influences the content of the left-hand string. |
[ public, friend ] SFXWideString operator*( SFXWideStringConstRef left // string to repeat SInt32 right // times to repeat );
This operator returns the string obtained by repeating the left-hand string by the right-hand times.
[ public, friend ] Bool operator!=( SFXWideStringConstRef left // string to compare SFXWideStringConstRef right // string to compare );
[ public, friend ] Bool operator!=( SFXWideStringConstRef left // string to compare SFXWideStringConstRef right // string to compare );
[ public, friend ] Bool operator!=( SFXWideStringConstRef left // string to compare WCharConstPtr right // string to compare );
[ public, friend ] Bool operator!=( SFXWideStringConstRef left // string to compare WCharConstPtr right // string to compare );
[ public, friend ] Bool operator!=( WCharConstPtr left // string to compare SFXWideStringConstRef right // string to compare );
[ public, friend ] Bool operator!=( WCharConstPtr left // string to compare SFXWideStringConstRef right // string to compare );
This operator checks whether or not the left-hand string is different from the right-hand string.
[ public ] SFXWideStringRef operator+=( SFXWideStringConstRef string // string to add );
[ public ] SFXWideStringRef operator+=( WCharConstPtr string // string to add );
[ public ] SFXWideStringRef operator+=( WChar character // 追加する文字 );
This operator adds the right-hand string to the end of the left-hand string.
Tip | |
---|---|
This operator influences the content of the left-hand string. |
[ public, friend ] SFXWideString operator+( SFXWideStringConstRef left // source string SFXWideStringConstRef right // string to add );
[ public, friend ] SFXWideString operator+( SFXWideStringConstRef left // source string SFXWideStringConstRef right // string to add );
[ public, friend ] SFXWideString operator+( SFXWideStringConstRef left // source string WCharConstPtr right // string to add );
[ public, friend ] SFXWideString operator+( SFXWideStringConstRef left // source string WCharConstPtr right // string to add );
[ public, friend ] SFXWideString operator+( WCharConstPtr left // source string SFXWideStringConstRef right // string to add );
[ public, friend ] SFXWideString operator+( WCharConstPtr left // source string SFXWideStringConstRef right // string to add );
[ public, friend ] SFXWideString operator+( SFXWideStringConstRef left // source string WChar right // character to add );
[ public, friend ] SFXWideString operator+( WChar left // source character SFXWideStringConstRef right // character to add );
This operator returns the string obtained by adding the right-hand string to the end of the left-hand string.
enum DefaultEnum { DEFAULT_THRESHOLD = 4 * sizeof(WChar), // default minimum size of the internal buffer memory [in bytes] DEFAULT_CLUSTER = 8 * sizeof(WChar) // default cluster size to allocate the internal buffer memory [in bytes] };
DEFAULT_THRESHOLD and DEFAULT_CLUSTER are the constants that represent the default values for the minimum size and the cluster size of the internal buffer memory(SFXClusterHeap). [in bytes]
Copyright(c) 2002 - 2024 Sophia Cradle Incorporated All Rights Reserved. |