ReactOS 0.4.15-dev-7953-g1f49173
codecvt< wchar_t, char, mbstate_t > Class Reference

#include <_codecvt.h>

Inheritance diagram for codecvt< wchar_t, char, mbstate_t >:
Collaboration diagram for codecvt< wchar_t, char, mbstate_t >:

Public Types

typedef wchar_t intern_type
 
typedef char extern_type
 
typedef mbstate_t state_type
 
- Public Types inherited from codecvt_base
enum  result { ok , partial , error , noconv }
 

Public Member Functions

 codecvt (size_t __refs=0)
 
result out (state_type &__state, const wchar_t *__from, const wchar_t *__from_end, const wchar_t *&__from_next, char *__to, char *__to_limit, char *&__to_next) const
 
result unshift (state_type &__state, char *__to, char *__to_limit, char *&__to_next) const
 
result in (state_type &__state, const char *__from, const char *__from_end, const char *&__from_next, wchar_t *__to, wchar_t *__to_limit, wchar_t *&__to_next) const
 
int encoding () const _STLP_NOTHROW
 
bool always_noconv () const _STLP_NOTHROW
 
int length (state_type &__state, const char *__from, const char *__from_end, size_t __max) const
 
int max_length () const _STLP_NOTHROW
 

Static Public Attributes

static _STLP_STATIC_DECLSPEC locale::id id = { 16 }
 

Protected Member Functions

 ~codecvt ()
 
virtual result do_out (state_type &__state, const wchar_t *__from, const wchar_t *__from_end, const wchar_t *&__from_next, char *__to, char *__to_limit, char *&__to_next) const
 
virtual result do_in (state_type &__state, const char *__from, const char *__from_end, const char *&__from_next, wchar_t *__to, wchar_t *__to_limit, wchar_t *&__to_next) const
 
virtual result do_unshift (state_type &__state, char *__to, char *__to_limit, char *&__to_next) const
 
virtual int do_encoding () const _STLP_NOTHROW
 
virtual bool do_always_noconv () const _STLP_NOTHROW
 
virtual int do_length (state_type &__state, const char *__from, const char *__end, size_t __max) const
 
virtual int do_max_length () const _STLP_NOTHROW
 
- Protected Member Functions inherited from locale::facet
 facet (size_t __init_count=0)
 
virtual ~facet ()
 
- Protected Member Functions inherited from _Refcount_Base
 _Refcount_Base (__stl_atomic_t __n)
 
__stl_atomic_t _M_incr ()
 
__stl_atomic_t _M_decr ()
 

Private Member Functions

 codecvt (const codecvt< wchar_t, char, mbstate_t > &)
 
codecvt< wchar_t, char, mbstate_t > & operator= (const codecvt< wchar_t, char, mbstate_t > &)
 

Detailed Description

Definition at line 270 of file _codecvt.h.

Member Typedef Documentation

◆ extern_type

typedef char codecvt< wchar_t, char, mbstate_t >::extern_type

Definition at line 274 of file _codecvt.h.

◆ intern_type

typedef wchar_t codecvt< wchar_t, char, mbstate_t >::intern_type

Definition at line 273 of file _codecvt.h.

◆ state_type

typedef mbstate_t codecvt< wchar_t, char, mbstate_t >::state_type

Definition at line 275 of file _codecvt.h.

Constructor & Destructor Documentation

◆ codecvt() [1/2]

codecvt< wchar_t, char, mbstate_t >::codecvt ( size_t  __refs = 0)
inlineexplicit

Definition at line 277 of file _codecvt.h.

277: locale::facet(__refs) {}

◆ ~codecvt()

codecvt< wchar_t, char, mbstate_t >::~codecvt ( )
protected

Definition at line 79 of file codecvt.cpp.

79{}

◆ codecvt() [2/2]

Member Function Documentation

◆ always_noconv()

bool codecvt< wchar_t, char, mbstate_t >::always_noconv ( ) const
inline

Definition at line 315 of file _codecvt.h.

315{ return do_always_noconv(); }
virtual bool do_always_noconv() const _STLP_NOTHROW
Definition: codecvt.cpp:125

◆ do_always_noconv()

bool codecvt< wchar_t, char, mbstate_t >::do_always_noconv ( ) const
protectedvirtual

Reimplemented in codecvt_byname< wchar_t, char, mbstate_t >.

Definition at line 125 of file codecvt.cpp.

126{ return true; }

◆ do_encoding()

int codecvt< wchar_t, char, mbstate_t >::do_encoding ( ) const
protectedvirtual

Reimplemented in codecvt_byname< wchar_t, char, mbstate_t >.

Definition at line 122 of file codecvt.cpp.

123{ return 1; }

◆ do_in()

codecvt< wchar_t, char, mbstate_t >::result codecvt< wchar_t, char, mbstate_t >::do_in ( state_type __state,
const char __from,
const char __from_end,
const char *&  __from_next,
wchar_t __to,
wchar_t __to_limit,
wchar_t *&  __to_next 
) const
protectedvirtual

Reimplemented in codecvt_byname< wchar_t, char, mbstate_t >.

Definition at line 98 of file codecvt.cpp.

104 {
105 ptrdiff_t len = (min) (from_end - from, to_limit - to);
106 copy(__REINTERPRET_CAST(const unsigned char*, from),
107 __REINTERPRET_CAST(const unsigned char*, from) + len, to);
108 from_next = from + len;
109 to_next = to + len;
110 return ok;
111}
INT copy(TCHAR source[MAX_PATH], TCHAR dest[MAX_PATH], INT append, DWORD lpdwFlags, BOOL bTouch)
Definition: copy.c:51
__kernel_ptrdiff_t ptrdiff_t
Definition: linux.h:247
#define __REINTERPRET_CAST(__x, __y)
Definition: features.h:586
GLenum GLsizei len
Definition: glext.h:6722
#define min(a, b)
Definition: monoChain.cc:55
CardRegion * from
Definition: spigame.cpp:19

◆ do_length()

int codecvt< wchar_t, char, mbstate_t >::do_length ( state_type __state,
const char __from,
const char __end,
size_t  __max 
) const
protectedvirtual

Reimplemented in codecvt_byname< wchar_t, char, mbstate_t >.

Definition at line 128 of file codecvt.cpp.

132{ return (int)(min) ((size_t) (end - from), mx); }
GLuint GLuint end
Definition: gl.h:1545

◆ do_max_length()

int codecvt< wchar_t, char, mbstate_t >::do_max_length ( ) const
protectedvirtual

Reimplemented in codecvt_byname< wchar_t, char, mbstate_t >.

Definition at line 134 of file codecvt.cpp.

135{ return 1; }

◆ do_out()

codecvt< wchar_t, char, mbstate_t >::result codecvt< wchar_t, char, mbstate_t >::do_out ( state_type __state,
const wchar_t __from,
const wchar_t __from_end,
const wchar_t *&  __from_next,
char __to,
char __to_limit,
char *&  __to_next 
) const
protectedvirtual

Reimplemented in codecvt_byname< wchar_t, char, mbstate_t >.

Definition at line 83 of file codecvt.cpp.

89 {
90 ptrdiff_t len = (min) (from_end - from, to_limit - to);
91 copy(from, from + len, to);
92 from_next = from + len;
93 to_next = to + len;
94 return ok;
95}

◆ do_unshift()

codecvt< wchar_t, char, mbstate_t >::result codecvt< wchar_t, char, mbstate_t >::do_unshift ( state_type __state,
char __to,
char __to_limit,
char *&  __to_next 
) const
protectedvirtual

Reimplemented in codecvt_byname< wchar_t, char, mbstate_t >.

Definition at line 114 of file codecvt.cpp.

117 {
118 to_next = to;
119 return noconv;
120}

◆ encoding()

int codecvt< wchar_t, char, mbstate_t >::encoding ( ) const
inline

Definition at line 313 of file _codecvt.h.

313{ return do_encoding(); }
virtual int do_encoding() const _STLP_NOTHROW
Definition: codecvt.cpp:122

◆ in()

result codecvt< wchar_t, char, mbstate_t >::in ( state_type __state,
const char __from,
const char __from_end,
const char *&  __from_next,
wchar_t __to,
wchar_t __to_limit,
wchar_t *&  __to_next 
) const
inline

Definition at line 299 of file _codecvt.h.

305 {
306 _STLP_VERBOSE_ASSERT(__from <= __from_end, _StlMsg_INVALID_ARGUMENT)
307 _STLP_VERBOSE_ASSERT(__to <= __to_limit, _StlMsg_INVALID_ARGUMENT)
308 return do_in(__state,
309 __from, __from_end, __from_next,
310 __to, __to_limit, __to_next);
311 }
#define _STLP_VERBOSE_ASSERT(expr, diagnostic)
Definition: _debug.h:439
virtual result do_in(state_type &__state, const char *__from, const char *__from_end, const char *&__from_next, wchar_t *__to, wchar_t *__to_limit, wchar_t *&__to_next) const
Definition: codecvt.cpp:98

◆ length()

int codecvt< wchar_t, char, mbstate_t >::length ( state_type __state,
const char __from,
const char __from_end,
size_t  __max 
) const
inline

Definition at line 317 of file _codecvt.h.

319 {
320 _STLP_VERBOSE_ASSERT(__from <= __from_end, _StlMsg_INVALID_ARGUMENT)
321 return do_length(__state, __from, __from_end, __max);
322 }
virtual int do_length(state_type &__state, const char *__from, const char *__end, size_t __max) const
Definition: codecvt.cpp:128
#define __max(a, b)
Definition: stdlib.h:101

◆ max_length()

int codecvt< wchar_t, char, mbstate_t >::max_length ( ) const
inline

Definition at line 324 of file _codecvt.h.

324{ return do_max_length(); }
virtual int do_max_length() const _STLP_NOTHROW
Definition: codecvt.cpp:134

◆ operator=()

◆ out()

result codecvt< wchar_t, char, mbstate_t >::out ( state_type __state,
const wchar_t __from,
const wchar_t __from_end,
const wchar_t *&  __from_next,
char __to,
char __to_limit,
char *&  __to_next 
) const
inline

Definition at line 279 of file _codecvt.h.

285 {
286 _STLP_VERBOSE_ASSERT(__from <= __from_end, _StlMsg_INVALID_ARGUMENT)
287 _STLP_VERBOSE_ASSERT(__to <= __to_limit, _StlMsg_INVALID_ARGUMENT)
288 return do_out(__state,
289 __from, __from_end, __from_next,
290 __to, __to_limit, __to_next);
291 }
virtual result do_out(state_type &__state, const wchar_t *__from, const wchar_t *__from_end, const wchar_t *&__from_next, char *__to, char *__to_limit, char *&__to_next) const
Definition: codecvt.cpp:83

◆ unshift()

result codecvt< wchar_t, char, mbstate_t >::unshift ( state_type __state,
char __to,
char __to_limit,
char *&  __to_next 
) const
inline

Definition at line 293 of file _codecvt.h.

294 {
295 _STLP_VERBOSE_ASSERT(__to <= __to_limit, _StlMsg_INVALID_ARGUMENT)
296 return do_unshift(__state, __to, __to_limit, __to_next);
297 }
virtual result do_unshift(state_type &__state, char *__to, char *__to_limit, char *&__to_next) const
Definition: codecvt.cpp:114

Member Data Documentation

◆ id

Definition at line 326 of file _codecvt.h.


The documentation for this class was generated from the following files: