|
virtual result | do_in (_Statype &, const _Byte *_First1, const _Byte *_Last1, const _Byte *&_Mid1, _Elem *_First2, _Elem *_Last2, _Elem *&_Mid2) const |
|
virtual result | do_out (_Statype &, const _Elem *_First1, const _Elem *_Last1, const _Elem *&_Mid1, _Byte *_First2, _Byte *_Last2, _Byte *&_Mid2) const |
|
virtual result | do_unshift (_Statype &, _Byte *_First2, _Byte *, _Byte *&_Mid2) const |
|
virtual int | do_length (_Statype &_State, const _Byte *_First1, const _Byte *_Last1, size_t _Count) const _THROW0() |
|
virtual bool | do_always_noconv () const _THROW0() |
|
virtual int | do_max_length () const _THROW0() |
|
virtual int | do_encoding () const _THROW0() |
|
template<class _Elem, class _Table, unsigned long _Maxcode = 0xffff>
template<class _Elem, class _Table, unsigned long _Maxcode = 0xffff>
template<class _Elem, class _Table, unsigned long _Maxcode = 0xffff>
template<class _Elem, class _Table, unsigned long _Maxcode = 0xffff>
template<class _Elem, class _Table, unsigned long _Maxcode = 0xffff>
template<class _Elem, class _Table, unsigned long _Maxcode = 0xffff>
template<class _Elem, class _Table, unsigned long _Maxcode = 0xffff>
_STD codecvt< _Elem, char, _Statype > _Mybase
Definition: xtwo_byte:32
template<class _Elem, class _Table, unsigned long _Maxcode = 0xffff>
template<class _Elem, class _Table, unsigned long _Maxcode = 0xffff>
template<class _Elem, class _Table, unsigned long _Maxcode = 0xffff>
template<class _Elem, class _Table, unsigned long _Maxcode = 0xffff>
53 unsigned long _Maxc = _Maxcode;
57 for (; _Mid1 != _Last1 && _Mid2 != _Last2; ++_Mid1)
59 unsigned char _Bytecode = (
unsigned char)*_Mid1;
60 unsigned short _Widecode;
62 if (_Bytecode < _Table::_Nlow)
63 _Widecode = _Bytecode;
65 _Table::_Btw[_Bytecode - _Table::_Nlow]) != 0)
67 else if (_Table::_Nbytes < 2)
68 return (_Mybase::error);
69 else if (_Mid1 + 1 == _Last1)
73 _Widecode = (
unsigned short)(_Bytecode << 8
74 | (
unsigned char)*++_Mid1);
75 unsigned long _Lo = 0;
76 unsigned long _Hi =
sizeof (_Table::_Dbvalid)
77 /
sizeof (_Table::_Dbvalid[0]);
81 unsigned long _Mid = (_Hi + _Lo) / 2;
83 if (_Widecode < _Table::_Dbvalid[_Mid])
85 else if (_Widecode == _Table::_Dbvalid[_Mid])
87 _Widecode = _Table::_Dbtw[_Mid];
94 return (_Mybase::error);
96 if (_Maxc < _Widecode)
97 return (_Mybase::error);
99 *_Mid2++ = (_Elem)_Widecode;
102 return (_First1 == _Mid1 ? _Mybase::partial : _Mybase::ok);
unsigned char
Definition: mbstring.h:107
template<class _Elem, class _Table, unsigned long _Maxcode = 0xffff>
171 for (; _Wchars <
_Count && _First1 != _Last1; )
177 switch (
do_in(_Mystate, _First1, _Last1, _Mid1,
178 &_Ch, &_Ch + 1, _Mid2))
180 case _Mybase::noconv:
181 return ((
int)(_Wchars + (_Last1 - _First1)));
184 if (_Mid2 == &_Ch + 1)
190 return ((
int)_Wchars);
193 return ((
int)_Wchars);
_Check_return_ _In_ wchar_t _Ch
Definition: vcruntime_string.h:89
_In_ size_t _Deref_pre_opt_z_ char const _In_ size_t _Inout_ mbstate_t * _State
Definition: wchar.h:78
char _Byte
Definition: xtwo_byte:34
virtual result do_in(_Statype &, const _Byte *_First1, const _Byte *_Last1, const _Byte *&_Mid1, _Elem *_First2, _Elem *_Last2, _Elem *&_Mid2) const
Definition: xtwo_byte:49
_Diff _Count
Definition: algorithm:1941
_CSTD mbstate_t _Statype
Definition: codecvt:28
template<class _Elem, class _Table, unsigned long _Maxcode = 0xffff>
203 return (_Table::_Nbytes);
template<class _Elem, class _Table, unsigned long _Maxcode = 0xffff>
109 unsigned long _Maxc = _Maxcode;
113 for (; _Mid1 != _Last1 && _Mid2 != _Last2; ++_Mid1)
115 unsigned long _Hugecode = (
unsigned long)*_Mid1;
116 unsigned short _Widecode = (
unsigned short)_Hugecode;
118 if (_Maxc < _Widecode)
119 return (_Mybase::error);
120 else if (_Widecode < _Table::_Nlow || (_Widecode < 0x100
121 && _Table::_Btw[_Widecode - _Table::_Nlow] == _Widecode))
125 unsigned long _Lo = 0;
126 unsigned long _Hi =
sizeof (_Table::_Wvalid)
127 /
sizeof (_Table::_Wvalid[0]);
131 unsigned long _Mid = (_Hi + _Lo) / 2;
133 if (_Widecode < _Table::_Wvalid[_Mid])
135 else if (_Widecode == _Table::_Wvalid[_Mid])
137 _Widecode = _Table::_Wtb[_Mid];
144 return (_Mybase::error);
146 if (_Widecode < 0x100)
148 else if (_Mid2 + 1 == _Last2)
149 return (_Mybase::partial);
151 *_Mid2++ = (
_Byte)(_Widecode >> 8);
152 *_Mid2++ = (
_Byte)_Widecode;
155 return (_First1 == _Mid1 ? _Mybase::partial : _Mybase::ok);
_In_ long
Definition: corecrt_wstdlib.h:88
char _Byte
Definition: xtwo_byte:34
template<class _Elem, class _Table, unsigned long _Maxcode = 0xffff>
162 return (_Mybase::ok);
The documentation for this class was generated from the following file: