public member function
<locale>
std::collate::transform
string_type transform (const charT* low, const charT* high) const;
Transform character sequence
Returns a string that, if compared lexicographically (see
lexicographical_compare) with the result of this same function on another string will return the same as comparing the two original strings with
collate::compare, including the interpretaton of multi-byte characters.
This is useful when one string is compared to many other strings.
During its operation, the version of this function in the generic template simply calls the virtual protected member
do_transform, which is the member function in charge of performing the actions described above.
Parameters
- low, high
- Pointers to the beginning and ending characters of the sequence. The range used is [low,high), which contains all the characters between low and high, including the character pointed by low but not the character pointed by high.
charT is the template parameter (i.e., the facet's character type).
Return value
A string that, if compared lexicographically with the result of this same function on another string will return the same as comparing the two original strings with
collate::compare.
string_type is a member alias of
basic_string<charT>, where
charT is the template parameter (i.e., the facet's character type).
See also
- collate::compare
- Compare character sequences (public member function)
- collate::hash
- Get hash value (public member function)
- lexicographical_compare
- Lexicographical less-than comparison (function template
)