System::Text::Decoder::Convert 方法

Decoder::Convert(ArrayPtr<uint8_t>, int, int, ArrayPtr<char_t>, int, int, bool, int&, int&, bool&) method

将字节转换为字符。

virtual void System::Text::Decoder::Convert(ArrayPtr<uint8_t> bytes, int byteIndex, int byteCount, ArrayPtr<char_t> chars, int charIndex, int charCount, bool flush, int &bytesUsed, int &charsUsed, bool &completed)
参数类型描述
字节ArrayPtr<uint8_t>待解码的字节。
byteIndexint输入缓冲区偏移量。
byteCountint输入缓冲区大小。
charsArrayPtr<char_t>目标字符缓冲区。
charIndexint目标数组偏移量。
charCountint目标数组大小。
flushbool如果为 true,则在计算后清除内部解码器状态。
bytesUsedint&用于存储已读取字节计数的变量引用。
charsUsedint&用于存储已写入字符计数的变量引用。
completedbool&如果输入缓冲区已耗尽则设为 true,否则设为 false 的变量引用。

另见

Decoder::Convert(const uint8_t *, int, char_t *, int, bool, int&, int&, bool&) method

将字节转换为字符。

virtual void System::Text::Decoder::Convert(const uint8_t *bytes, int byteCount, char_t *chars, int charCount, bool flush, int &bytesUsed, int &charsUsed, bool &completed)
参数类型描述
字节const uint8_t *待解码的字节。
byteCountint输入缓冲区大小。
charschar_t *目标字符缓冲区。
charCountint目标数组大小。
flushbool如果为 true,则在计算后清除内部解码器状态。
bytesUsedint&用于存储已读取字节计数的变量引用。
charsUsedint&用于存储已写入字符计数的变量引用。
completedbool&如果输入缓冲区已耗尽则设为 true,否则设为 false 的变量引用。

另见