Version: 1.0.0
string_converter.h
Go to the documentation of this file.
1 #ifndef _WX_DATABASE_STRING_CONVERTER_H_
2 #define _WX_DATABASE_STRING_CONVERTER_H_
3 
4 #include "wx/database/wxprec.h"
5 
7 {
8 public:
9  // ctor
11  wxDatabaseStringConverter(const wxChar* charset);
12 
13  // dtor
15 
16  void SetEncoding(wxFontEncoding encoding);
17  void SetEncoding(const wxCSConv* conv);
18  const wxCSConv* GetEncoding() { return &m_Encoding; }
19 
20  virtual const wxCharBuffer ConvertToUnicodeStream(const wxString& inputString);
21  virtual size_t GetEncodedStreamLength(const wxString& inputString);
22  virtual wxString ConvertFromUnicodeStream(const char* inputBuffer);
23  virtual wxString ConvertFromUnicodeStream(const wxChar* inputBuffer);
24 
25  static const wxCharBuffer ConvertToUnicodeStream(const wxString& inputString, const char* encoding);
26  static wxString ConvertFromUnicodeStream(const char* inputBuffer, const char* encoding);
27  static size_t GetEncodedStreamLength(const wxString& inputString, const char* encoding);
28  static wxString ConvertFromUnicodeStream(const wxChar* inputBuffer,const char* encoding);
29 
30 private:
31  wxCSConv m_Encoding;
32 };
33 
34 #endif//_WX_DATABASE_STRING_CONVERTER_H_
#define WXDLLIMPEXP_DATABASE
const wxCSConv * GetEncoding()