Crazy Eddie's GUI System  0.8.4
CEGUI::StringTranscoder Class Reference

Interface for a string transcoding utility. Instances of classes that implement this interface can be used to transcode CEGUI::Strings to and from some other character encodings not directly supported by the CEGUI::String class. More...

+ Inheritance diagram for CEGUI::StringTranscoder:
+ Collaboration diagram for CEGUI::StringTranscoder:

List of all members.

Public Member Functions

virtual uint16 * stringToUTF16 (const String &input) const =0
 Transcode the given string to a UTF-16 encoded buffer.
virtual std::wstring stringToStdWString (const String &input) const =0
 Transcode the given string to a std::wstring object.
virtual String stringFromUTF16 (const uint16 *input) const =0
virtual String stringFromStdWString (const std::wstring &input) const =0
virtual void deleteUTF16Buffer (uint16 *input) const =0
 deletes a buffer returned from the stringToUTF16 function.

Detailed Description

Interface for a string transcoding utility. Instances of classes that implement this interface can be used to transcode CEGUI::Strings to and from some other character encodings not directly supported by the CEGUI::String class.


Member Function Documentation

virtual std::wstring CEGUI::StringTranscoder::stringToStdWString ( const String input) const [pure virtual]

Transcode the given string to a std::wstring object.

Parameters:
inputString object with the text to be transcoded.
Returns:
std::wstring holding the transcoded data in some appropriate encoding.
Note:
What is represented by std::wstring and how it should be interpreted is implementation specific. This means that the content of the returned std::wstring may vary according to the operating system and compiler used - although what is returned should be consistent with other std::wstring data running on the same implementation. This largely means that on Microsoft Windows you will have UTF-16 and on *nix type environments you will have UTF-32.

Implemented in CEGUI::IconvStringTranscoder, and CEGUI::Win32StringTranscoder.

virtual uint16* CEGUI::StringTranscoder::stringToUTF16 ( const String input) const [pure virtual]

Transcode the given string to a UTF-16 encoded buffer.

Parameters:
inputString object with the text to be transcoded.
Returns:
Pointer to an array of utf16 values. This buffer should be deleted by calling the deleteUTF16Buffer function.

Implemented in CEGUI::IconvStringTranscoder, and CEGUI::Win32StringTranscoder.

 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Friends