Class for representing native character strings and handling common string operations This class is Unicode compliant
Class for representing native character strings and handling common string operations This class is Unicode compliant. This class is designed primarily for internal use, but due to popular demand, it is being made publicly available. Users of this class must understand that this is not an officially supported class. All public methods of this class are static functions.
static void binToText( const unsigned int toFormat, XMLCh* const toFill, const unsigned int maxChars, const unsigned int radix )
toFill - The buffer that will hold the output on return
maxChars - The maximum number of charcters to convert
radix - The radix of the input data, based on which the conversion
will be done static void binToText( const unsigned long toFormat, char* const toFill, const unsigned int maxChars, const unsigned int radix )
toFill - The buffer that will hold the output on return
maxChars - The maximum number of charcters to convert
radix - The radix of the input data, based on which the conversion
will be done static void binToText( const unsigned long toFormat, XMLCh* const toFill, const unsigned int maxChars, const unsigned int radix )
toFill - The buffer that will hold the output on return
maxChars - The maximum number of charcters to convert
radix - The radix of the input data, based on which the conversion
will be done static void binToText( const long toFormat, char* const toFill, const unsigned int maxChars, const unsigned int radix )
toFill - The buffer that will hold the output on return
maxChars - The maximum number of charcters to convert
radix - The radix of the input data, based on which the conversion
will be done static void binToText( const long toFormat, XMLCh* const toFill, const unsigned int maxChars, const unsigned int radix )
toFill - The buffer that will hold the output on return
maxChars - The maximum number of charcters to convert
radix - The radix of the input data, based on which the conversion
will be done static void binToText( const int toFormat, char* const toFill, const unsigned int maxChars, const unsigned int radix )
toFill - The buffer that will hold the output on return
maxChars - The maximum number of charcters to convert
radix - The radix of the input data, based on which the conversion
will be done static void binToText( const int toFormat, XMLCh* const toFill, const unsigned int maxChars, const unsigned int radix )
toFill - The buffer that will hold the output on return
maxChars - The maximum number of charcters to convert
radix - The radix of the input data, based on which the conversion
will be done
catString
appends src
to target
and
terminates the resulting string with a null character. The initial character
of src
overwrites the terminating character of target
.
No overflow checking is performed when strings are copied or appended.
The behavior of catString
is undefined if source and
destination strings overlap.
static void catString( XMLCh* const target, const XMLCh* const src )
catString
appends src
to target
and
terminates the resulting string with a null character. The initial character of
src
overwrites the terminating character of target
.
No overflow checking is performed when strings are copied or appended.
The behavior of catString
is undefined if source and destination
strings overlap.
src - Null-terminated source string
str1
and
str2
and returns a value indicating their relationship
str1
to
str2
as follows
Less than 0 means str1
is less than str2
Equal to 0 means str1
is identical to str2
Greater than 0 means str1
is more than str2
static int compareIString( const XMLCh* const str1, const XMLCh* const str2 )
str1
and
str2
and returns a value indicating their relationship
str1
to
str2
as follows
Less than 0 means str1
is less than str2
Equal to 0 means str1
is identical to str2
Greater than 0 means str1
is more than str2
str2 - Null-terminated string to compare
static int compareNString( const char* const str1, const char* const str2, const unsigned int count )
str1
and str2
and returns a value indicating the
relationship between the substrings
str1
to
str2
as follows
Less than 0 means str1
is less than str2
Equal to 0 means str1
is identical to str2
Greater than 0 means str1
is more than str2
str2 - Null-terminated string to compare
count - The number of characters to compare
static int compareNString( const XMLCh* const str1, const XMLCh* const str2, const unsigned int count )
str1
and str2
and returns a value indicating
the relationship between the substrings
str1
to
str2
as follows
Less than 0 means str1
is less than str2
Equal to 0 means str1
is identical to str2
Greater than 0 means str1
is more than str2
str2 - Null-terminated string to compare
count - The number of characters to compare
static int compareNIString( const char* const str1, const char* const str2, const unsigned int count )
str1
and str2
without regard to case and
returns a value indicating the relationship between the substrings.
str1
to
str2
as follows
Less than 0 means str1
is less than str2
Equal to 0 means str1
is identical to str2
Greater than 0 means str1
is more than str2
str2 - Null-terminated string to compare
count - The number of characters to compare
static int compareNIString( const XMLCh* const str1, const XMLCh* const str2, const unsigned int count )
str1
and str2
without regard to case and
returns a value indicating the relationship between the substrings.
str1
to
str2
as follows
Less than 0 means str1
is less than str2
Equal to 0 means str1
is identical to str2
Greater than 0 means str1
is more than str2
str2 - Null-terminated string to compare
count - The number of characters to compare
static int compareString( const char* const str1, const char* const str2 )
str1
and str2
and
returns a value indicating their relationship.
str1
to
str2
as follows
Less than 0 means str1
is less than str2
Equal to 0 means str1
is identical to str2
Greater than 0 means str1
is more than str2
str2 - Null-terminated string to compare
static int compareString( const XMLCh* const str1, const XMLCh* const str2 )
str1
and str2
and
returns a value indicating their relationship.
str1
to
str2
as follows
Less than 0 means str1
is less than str2
Equal to 0 means str1
is identical to str2
Greater than 0 means str1
is more than str2
str2 - Null-terminated string to compare
src
, including the terminating null character, to the
location specified by target
.
No overflow checking is performed when strings are copied or appended.
The behavior of strcpy is undefined if the source and destination strings
overlap.
static void copyString( XMLCh* const target, const XMLCh* const src )
src
, including the terminating null character, to
the location specified by target
.
No overflow checking is performed when strings are copied or appended.
The behavior of copyString
is undefined if the source and
destination strings overlap.
src - Null-terminated source string static bool copyNString( XMLCh* const target, const XMLCh* const src, const unsigned int maxChars )
src
, upto a fixed number of characters, to the
location specified by target
.
No overflow checking is performed when strings are copied or appended.
The behavior of copyNString
is undefined if the source and
destination strings overlap.
src - Null-terminated source string
maxChars - The maximum number of characters to copy
static unsigned int hash( const XMLCh* const toHash, const unsigned int hashModulus )
hashModulus - The divisor to be used for hashing
static unsigned int hashN( const XMLCh* const toHash, const unsigned int numChars, const unsigned int hashModulus )
numChars - The maximum number of characters to consider for hashing
hashModulus - The divisor to be used for hashing
static int indexOf(const XMLCh* const toSearch, const XMLCh ch)
ch - The character to search within the string
static int lastIndexOf(const char* const toSearch, const char ch)
ch - The character to search within the string
static int lastIndexOf(const XMLCh* const toSearch, const XMLCh ch)
ch - The character to search within the string
static int lastIndexOf( const char* const toSearch, const char chToFind, const unsigned int fromIndex )
chToFInd - The character to search within the string
fromIndex - The index to start backward search from
static int lastIndexOf( const XMLCh* const toSearch, const XMLCh ch, const unsigned int fromIndex )
chToFInd - The character to search within the string
fromIndex - The index to start backward search from
static XMLCh* replicate(const XMLCh* const toRep)
toTest
, else false
static bool startsWith( const XMLCh* const toTest, const XMLCh* const prefix )
toTest
, else false
prefix - The sub-string that needs to be checked
static bool startsWithI( const char* const toTest, const char* const prefix )
toTest
, else false
prefix - The sub-string that needs to be checked
static bool startsWithI( const XMLCh* const toTest, const XMLCh* const prefix )
toTest
, else false
prefix - The sub-string that needs to be checked
static const XMLCh* findAny( const XMLCh* const toSearch, const XMLCh* const searchList )
searchList - The sub-string to be searched within the string
static XMLCh* findAny( XMLCh* const toSearch, const XMLCh* const searchList )
searchList - The sub-string to be searched within the string
static unsigned int stringLen(const char* const src)
static unsigned int stringLen(const XMLCh* const src)
static bool transcode( const XMLCh* const toTranscode, char* const toFill, const unsigned int maxChars )
toFill - The buffer that is filled with the transcoded value
maxChars - The maximum number of characters to transcode
static XMLCh* transcode( const char* const toTranscode )
static bool transcode( const char* const toTranscode, XMLCh* const toFill, const unsigned int maxChars )
toFill - The buffer that is filled with the transcoded value
maxChars - The maximum number of characters to transcode
static void trim(char* const toTrim)
static void trim(XMLCh* const toTrim)
static unsigned int replaceTokens( XMLCh* const errText, const unsigned int maxChars, const XMLCh* const text1, const XMLCh* const text2, const XMLCh* const text3, const XMLCh* const text4 )
maxChars - The maximum number of characters to consider for
replacement
text1 - Replacement text-one
text2 - Replacement text-two
text3 - Replacement text-three
text4 - Replacement text-four
static void upperCase(XMLCh* const toUpperCase)
alphabetic index hierarchy of classes
Xerces-C XML Parser for C++ Version 1.1 |
|
generated by doc++