Codemesh Runtime v3 C++ API Reference  3.9.205
xmog_java_string.h
1 //
2 // Copyright (c) 1999-2020 by Codemesh, Inc.. ALL RIGHTS RESERVED.
3 //
4 
5 
6 #ifndef xmog_java_string_inc
7 #define xmog_java_string_inc
8 
10 
11 struct xmog_base;
12 class xmog_localenv;
13 
15 
16 
17 #include "xmog.h"
18 
228 
238 class XMOG_DECLSPEC xmog_java_string
239 {
240 public:
241 
245  static xmog_base * US_ASCII;
246 
251 
255  static xmog_base * UTF_8;
256 
260  static xmog_base * UTF_16BE;
261 
265  static xmog_base * UTF_16LE;
266 
270  static xmog_base * UTF_16;
271 
278  static void init_encodings( xmog_localenv * env = NULL );
279 
289  static void set_default_encoding( const char * _enc, xmog_localenv * env = NULL );
290 
300  static void set_default_encoding( const XMOG_WCHAR * _enc, xmog_localenv * env = NULL );
301 
311  static void set_default_encoding( xmog_base * _enc, xmog_localenv * env = NULL );
312 
313 #if (XMOG_SUPPORTS_WCHAR_T==1)
314  static jstring from_wchar( const XMOG_WCHAR * _wstr, jint _len = -1, xmog_localenv * env = NULL );
325 #endif
326 
327 # if (XMOG_REQUIRES_UNSIGNED_SHORT_OVERLOAD==1)
328  static jstring from_wchar( const unsigned short * _wstr, jint _len = -1, xmog_localenv * env = NULL );
339 # endif
340 
341 # if (XMOG_SUPPORTS_WCHAR_T==1)
342  static void from_wchar( xmog_base * _this, xmog_flags _flags, const XMOG_WCHAR * _wstr, jint _len = -1, xmog_localenv * env = NULL );
355 # endif
356 
357 # if (XMOG_REQUIRES_UNSIGNED_SHORT_OVERLOAD==1)
358  static void from_wchar( xmog_base * _this, xmog_flags _flags, const unsigned short * _wstr, jint _len = -1, xmog_localenv * env = NULL );
371 # endif
372 
386  static jstring from_char( const char * _str, jint _len = -1, xmog_base * _enc = NULL, xmog_localenv * env = NULL, xmog_base * pStr = NULL, char** pCache = NULL );
387 
403  static void from_char( xmog_base * _this, xmog_flags _flags, const char * _str, jint _len = -1, xmog_base * _enc = NULL, xmog_localenv * env = NULL, xmog_base * pStr = NULL, char** pCache = NULL );
404 
412  static jstring from_charUtf8( const char * _strUTF, xmog_localenv * env = NULL );
413 
423  static void from_charUtf8( xmog_base * _this, xmog_flags _flags, const char * _strUTF, xmog_localenv * env = NULL );
424 
435  static char * to_char( jstring _str, xmog_localenv * env = NULL, xmog_base * pStr = NULL, char** pCache = NULL );
436 
448  static char * to_char( jstring _str, xmog_base * _enc, xmog_localenv * env = NULL, xmog_base * pStr = NULL, char** pCache = NULL );
449 
460  static char * to_charUtf8( jstring _str, xmog_localenv * env = NULL, xmog_base * pStr = NULL, char** pCache = NULL );
461 
462 # if (XMOG_SUPPORTS_WCHAR_T==1)
463  static XMOG_WCHAR * to_wchar( jstring _str, xmog_localenv * env = NULL );
472 # endif
473 
482  static unsigned short * to_u16( jstring _str, xmog_localenv * env = NULL );
483 
492  static void free( char * & str );
493 
494 # if (XMOG_SUPPORTS_WCHAR_T==1)
495  static void free( XMOG_WCHAR * & str );
504 # endif
505 
506 # if (XMOG_REQUIRES_UNSIGNED_SHORT_OVERLOAD==1)
507  static void free( unsigned short * & str );
516 # endif
517 
526  static void free_u16( unsigned short * & str );
527 };
528 
529 
530 #if (XMOG_PRE_3_0_SUPPORT == 1 )
531 
532 class cmjstr
533 {
534 private:
535 
536  char * pch;
537 
538 public:
539 
540 };
541 
542 #endif /* XMOG_PRE_3_0_SUPPORT */
543 
544 #endif /* xmog_java_string_inc */
cmjstr
Definition: xmog_java_string.h:532
xmog_java_string::UTF_16LE
static xmog_base * UTF_16LE
The UTF-16LE character set.
Definition: xmog_java_string.h:265
xmog_base
The baseclass for all proxy types in the framework.
Definition: xmog_base.h:29
xmog_java_string::US_ASCII
static xmog_base * US_ASCII
The US-ASCII character set.
Definition: xmog_java_string.h:245
xmog_java_string
A mixin or utility class for Java string features.
Definition: xmog_java_string.h:238
xmog_localenv
A class representing per-thread information for the integration runtime.
Definition: xmog_localenv.h:32
xmog_java_string::UTF_16
static xmog_base * UTF_16
The UTF-16 character set.
Definition: xmog_java_string.h:270
xmog_java_string::ISO_8859_1
static xmog_base * ISO_8859_1
The ISO-8859-1 character set.
Definition: xmog_java_string.h:250
xmog_java_string::UTF_16BE
static xmog_base * UTF_16BE
The UTF-16BE character set.
Definition: xmog_java_string.h:260
xmog_java_string::UTF_8
static xmog_base * UTF_8
The UTF-8 character set.
Definition: xmog_java_string.h:255

Copyright (c) 1999-2020 by Codemesh, Inc., ALL RIGHTS RESERVED.