CyberEngineMkIII
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
CYBUTF16String.hpp
Go to the documentation of this file.
1 
3 namespace CYB {
4  namespace API {
5  namespace String {
7  class UTF16 : public Dynamic {
8  private:
19  static char* SetupData(const UTF8& AUTF8, unsigned long long& ALengthReference);
20 
30  UTF16(const UTF8& AUTF8, unsigned long long ALengthReference);
31  public:
41  static UTF8 ToUTF8(const wchar_t* AWString);
42 
48  UTF16() noexcept = default;
57  UTF16(const UTF8& AUTF8);
58 
65  wchar_t* WideData(void) noexcept;
72  const wchar_t* WString(void) const noexcept;
73  };
74  };
75  };
76 };
A variable length UTF-8 string.
Definition: UTF8String.hpp:8
UTF16() noexcept=default
Empty string constructor.
wchar_t * WideData(void) noexcept
Get the underlying wide char array.
UTF-16 String enabled only under windows.
Used for string of allocated variable length.
static UTF8 ToUTF8(const wchar_t *AWString)
Create a new UTF8 string given a wide char array.
const wchar_t * WString(void) const noexcept
Get the underlying const wide char array.
static char * SetupData(const UTF8 &AUTF8, unsigned long long &ALengthReference)
Construct a raw allocated UTF16 wide char array casted to a char array given a UTF8 string...