libwordring
クラス | 型定義 | 列挙型 | 関数 | 変数
wordring::whatwg::encoding 名前空間

クラス

class  basic_gb18030_encoder
 
class  Big5_decoder
 
class  Big5_encoder
 
class  decoder
 
class  encoder
 
class  error_decoder
 
class  error_encoder
 
class  EUC_JP_decoder
 
class  EUC_JP_encoder
 
class  EUC_KR_decoder
 
class  EUC_KR_encoder
 
class  gb18030_decoder
 gb18030 decoder [詳解]
 
struct  io_item
 文字にキュー終端表現を追加するラッパー [詳解]
 
class  io_queue
 入出力ストリーム [詳解]
 
struct  io_result
 待機状態を追加するラッパー [詳解]
 
class  ISO_2022_JP_decoder
 
class  ISO_2022_JP_encoder
 
class  replacement_decoder
 
class  result_continue
 
struct  result_error
 
class  result_finished
 
class  shared_UTF_16_decoder
 
class  Shift_JIS_decoder
 Shift_JIS decoder [詳解]
 
class  Shift_JIS_encoder
 
class  single_byte_decoder
 single-byte decoder [詳解]
 
class  single_byte_encoder
 single-byte encoder [詳解]
 
class  text_decoder
 TextDecoderCommon [詳解]
 
class  text_decoder_common
 TextDecoderCommon [詳解]
 
class  UTF_8_decoder
 UTF-8 decoder [詳解]
 
class  UTF_8_encoder
 UTF-8 encoder [詳解]
 
class  x_user_defined_decoder
 
class  x_user_defined_encoder
 

型定義

using IBM866_decoder = single_byte_decoder< index_code_point_ibm866 >
 
using IBM866_encoder = single_byte_encoder< index_pointer_ibm866_0, index_pointer_ibm866_1 >
 
using ISO_8859_2_decoder = single_byte_decoder< index_code_point_iso_8859_2 >
 
using ISO_8859_2_encoder = single_byte_encoder< index_pointer_iso_8859_2_0, index_pointer_iso_8859_2_1 >
 
using ISO_8859_3_decoder = single_byte_decoder< index_code_point_iso_8859_3 >
 
using ISO_8859_3_encoder = single_byte_encoder< index_pointer_iso_8859_3_0, index_pointer_iso_8859_3_1 >
 
using ISO_8859_4_decoder = single_byte_decoder< index_code_point_iso_8859_4 >
 
using ISO_8859_4_encoder = single_byte_encoder< index_pointer_iso_8859_4_0, index_pointer_iso_8859_4_1 >
 
using ISO_8859_5_decoder = single_byte_decoder< index_code_point_iso_8859_5 >
 
using ISO_8859_5_encoder = single_byte_encoder< index_pointer_iso_8859_5_0, index_pointer_iso_8859_5_1 >
 
using ISO_8859_6_decoder = single_byte_decoder< index_code_point_iso_8859_6 >
 
using ISO_8859_6_encoder = single_byte_encoder< index_pointer_iso_8859_6_0, index_pointer_iso_8859_6_1 >
 
using ISO_8859_7_decoder = single_byte_decoder< index_code_point_iso_8859_7 >
 
using ISO_8859_7_encoder = single_byte_encoder< index_pointer_iso_8859_7_0, index_pointer_iso_8859_7_1 >
 
using ISO_8859_8_decoder = single_byte_decoder< index_code_point_iso_8859_8 >
 
using ISO_8859_8_encoder = single_byte_encoder< index_pointer_iso_8859_8_0, index_pointer_iso_8859_8_1 >
 
using ISO_8859_8_I_decoder = ISO_8859_8_decoder
 
using ISO_8859_8_I_encoder = ISO_8859_8_encoder
 
using ISO_8859_10_decoder = single_byte_decoder< index_code_point_iso_8859_10 >
 
using ISO_8859_10_encoder = single_byte_encoder< index_pointer_iso_8859_10_0, index_pointer_iso_8859_10_1 >
 
using ISO_8859_13_decoder = single_byte_decoder< index_code_point_iso_8859_13 >
 
using ISO_8859_13_encoder = single_byte_encoder< index_pointer_iso_8859_13_0, index_pointer_iso_8859_13_1 >
 
using ISO_8859_14_decoder = single_byte_decoder< index_code_point_iso_8859_14 >
 
using ISO_8859_14_encoder = single_byte_encoder< index_pointer_iso_8859_14_0, index_pointer_iso_8859_14_1 >
 
using ISO_8859_15_decoder = single_byte_decoder< index_code_point_iso_8859_15 >
 
using ISO_8859_15_encoder = single_byte_encoder< index_pointer_iso_8859_15_0, index_pointer_iso_8859_15_1 >
 
using ISO_8859_16_decoder = single_byte_decoder< index_code_point_iso_8859_16 >
 
using ISO_8859_16_encoder = single_byte_encoder< index_pointer_iso_8859_16_0, index_pointer_iso_8859_16_1 >
 
using KOI8_R_decoder = single_byte_decoder< index_code_point_koi8_r >
 
using KOI8_R_encoder = single_byte_encoder< index_pointer_koi8_r_0, index_pointer_koi8_r_1 >
 
using KOI8_U_decoder = single_byte_decoder< index_code_point_koi8_u >
 
using KOI8_U_encoder = single_byte_encoder< index_pointer_koi8_u_0, index_pointer_koi8_u_1 >
 
using macintosh_decoder = single_byte_decoder< index_code_point_macintosh >
 
using macintosh_encoder = single_byte_encoder< index_pointer_macintosh_0, index_pointer_macintosh_1 >
 
using windows_874_decoder = single_byte_decoder< index_code_point_windows_874 >
 
using windows_874_encoder = single_byte_encoder< index_pointer_windows_874_0, index_pointer_windows_874_1 >
 
using windows_1250_decoder = single_byte_decoder< index_code_point_windows_1250 >
 
using windows_1250_encoder = single_byte_encoder< index_pointer_windows_1250_0, index_pointer_windows_1250_1 >
 
using windows_1251_decoder = single_byte_decoder< index_code_point_windows_1251 >
 
using windows_1251_encoder = single_byte_encoder< index_pointer_windows_1251_0, index_pointer_windows_1251_1 >
 
using windows_1252_decoder = single_byte_decoder< index_code_point_windows_1252 >
 
using windows_1252_encoder = single_byte_encoder< index_pointer_windows_1252_0, index_pointer_windows_1252_1 >
 
using windows_1253_decoder = single_byte_decoder< index_code_point_windows_1253 >
 
using windows_1253_encoder = single_byte_encoder< index_pointer_windows_1253_0, index_pointer_windows_1253_1 >
 
using windows_1254_decoder = single_byte_decoder< index_code_point_windows_1254 >
 
using windows_1254_encoder = single_byte_encoder< index_pointer_windows_1254_0, index_pointer_windows_1254_1 >
 
using windows_1255_decoder = single_byte_decoder< index_code_point_windows_1255 >
 
using windows_1255_encoder = single_byte_encoder< index_pointer_windows_1255_0, index_pointer_windows_1255_1 >
 
using windows_1256_decoder = single_byte_decoder< index_code_point_windows_1256 >
 
using windows_1256_encoder = single_byte_encoder< index_pointer_windows_1256_0, index_pointer_windows_1256_1 >
 
using windows_1257_decoder = single_byte_decoder< index_code_point_windows_1257 >
 
using windows_1257_encoder = single_byte_encoder< index_pointer_windows_1257_0, index_pointer_windows_1257_1 >
 
using windows_1258_decoder = single_byte_decoder< index_code_point_windows_1258 >
 
using windows_1258_encoder = single_byte_encoder< index_pointer_windows_1258_0, index_pointer_windows_1258_1 >
 
using x_mac_cyrillic_decoder = single_byte_decoder< index_code_point_x_mac_cyrillic >
 
using x_mac_cyrillic_encoder = single_byte_encoder< index_pointer_x_mac_cyrillic_0, index_pointer_x_mac_cyrillic_1 >
 
using gb18030_encoder = basic_gb18030_encoder< false >
 
using GBK_decoder = gb18030_decoder
 
using GBK_encoder = basic_gb18030_encoder< true >
 
using UTF_16BE_decoder = shared_UTF_16_decoder< true >
 
using UTF_16LE_decoder = shared_UTF_16_decoder<>
 
using coder = std::variant< error_encoder, error_decoder, UTF_8_decoder, UTF_8_encoder, IBM866_decoder, IBM866_encoder, ISO_8859_2_decoder, ISO_8859_2_encoder, ISO_8859_3_decoder, ISO_8859_3_encoder, ISO_8859_4_decoder, ISO_8859_4_encoder, ISO_8859_5_decoder, ISO_8859_5_encoder, ISO_8859_6_decoder, ISO_8859_6_encoder, ISO_8859_7_decoder, ISO_8859_7_encoder, ISO_8859_8_decoder, ISO_8859_8_encoder, ISO_8859_10_decoder, ISO_8859_10_encoder, ISO_8859_13_decoder, ISO_8859_13_encoder, ISO_8859_14_decoder, ISO_8859_14_encoder, ISO_8859_15_decoder, ISO_8859_15_encoder, ISO_8859_16_decoder, ISO_8859_16_encoder, KOI8_R_decoder, KOI8_R_encoder, KOI8_U_decoder, KOI8_U_encoder, macintosh_decoder, macintosh_encoder, windows_874_decoder, windows_874_encoder, windows_1250_decoder, windows_1250_encoder, windows_1251_decoder, windows_1251_encoder, windows_1252_decoder, windows_1252_encoder, windows_1253_decoder, windows_1253_encoder, windows_1254_decoder, windows_1254_encoder, windows_1255_decoder, windows_1255_encoder, windows_1256_decoder, windows_1256_encoder, windows_1257_decoder, windows_1257_encoder, windows_1258_decoder, windows_1258_encoder, x_mac_cyrillic_decoder, x_mac_cyrillic_encoder, gb18030_decoder, gb18030_encoder, GBK_encoder, Big5_decoder, Big5_encoder, EUC_JP_decoder, EUC_JP_encoder, ISO_2022_JP_decoder, ISO_2022_JP_encoder, Shift_JIS_decoder, Shift_JIS_encoder, EUC_KR_decoder, EUC_KR_encoder, replacement_decoder, UTF_16BE_decoder, UTF_16LE_decoder, x_user_defined_decoder, x_user_defined_encoder >
 
using result_code_point = uint32_t
 
using result_code_points_2 = std::array< uint32_t, 2 >
 
using result_byte = uint8_t
 
using result_bytes_2 = std::array< uint8_t, 2 >
 
using result_bytes_3 = std::array< uint8_t, 3 >
 
using result_bytes_4 = std::array< uint8_t, 4 >
 
using result_value = std::variant< result_finished, result_continue, result_code_point, result_code_points_2, result_byte, result_bytes_2, result_bytes_3, result_bytes_4, result_error >
 

列挙型

enum  error_mode_name : uint32_t { None = 0, Replacement = 1, Fatal = 2, Html = 3 }
 
enum  encoding_name : uint32_t {
  UTF_8 = 1, IBM866, ISO_8859_2, ISO_8859_3,
  ISO_8859_4, ISO_8859_5, ISO_8859_6, ISO_8859_7,
  ISO_8859_8, ISO_8859_8_I, ISO_8859_10, ISO_8859_13,
  ISO_8859_14, ISO_8859_15, ISO_8859_16, KOI8_R,
  KOI8_U, macintosh, windows_874, windows_1250,
  windows_1251, windows_1252, windows_1253, windows_1254,
  windows_1255, windows_1256, windows_1257, windows_1258,
  x_mac_cyrillic, GBK, gb18030, Big5,
  EUC_JP, ISO_2022_JP, Shift_JIS, EUC_KR,
  replacement, UTF_16BE, UTF_16LE, x_user_defined
}
 

関数

std::u32string serialize_io_queue (text_decoder_common &c, io_queue< char32_t > &in)
 IO キューを直列化する [詳解]
 
template<auto const & index>
std::optional< std::uint32_t > get_index_code_point (std::uint16_t pointer)
 
template<auto const & index_0, auto const & index_1>
std::optional< std::uint16_t > get_index_pointer (std::uint32_t code_point)
 
std::optional< std::uint32_t > get_index_gb18030_ranges_code_point (std::uint32_t pointer)
 
std::optional< std::uint32_t > get_index_gb18030_ranges_pointer (std::uint32_t code_point)
 
std::optional< std::uint16_t > get_index_shift_jis_pointer (std::uint32_t code_point)
 
std::optional< std::uint16_t > get_index_big5_pointer (std::uint32_t code_point)
 
template<typename IoItem , typename Coder , typename InQueue , typename OutQueue >
result_value process_item (IoItem item, Coder &c, InQueue &in, OutQueue &out, error_mode_name mode)
 文字アイテムを処理する
 
template<typename Coder , typename InQueue , typename OutQueue >
result_value process_queue (Coder &c, InQueue &in, OutQueue &out, error_mode_name mode)
 キューを処理する [詳解]
 
encoding_name get_encoding_name (std::u32string label)
 
template<typename String , typename std::enable_if_t< std::negation_v< std::is_same< String, std::u32string >>, nullptr_t > = nullptr>
encoding_name get_encoding_name (String label)
 
std::u32string get_encoding_label (encoding_name name)
 エンコーディングに対応するラベルを返す [詳解]
 
coder get_encoding_decoder (encoding_name name)
 
coder get_encoding_encoder (encoding_name name)
 
encoding_name get_output_encoding_name (encoding_name name)
 ラベルからエンコーディングを取得する [詳解]
 
template<typename InQueue >
io_result< encoding_name > bom_sniff (InQueue &in)
 BOM を探知する [詳解]
 
template<typename InQueue , typename OutQueue >
result_value encode (InQueue &in, encoding_name name, OutQueue &out)
 エンコード [詳解]
 
template<typename InQueue , typename OutQueue >
result_value utf8_decode (InQueue &in, OutQueue &out)
 UTF8 をデコードする [詳解]
 
template<typename OutQueue , typename InQueue >
OutQueue utf8_decode (InQueue &in)
 UTF8 をデコードする [詳解]
 
template<typename InQueue , typename OutQueue >
result_value utf8_decode_without_bom (InQueue &in, OutQueue &out)
 BOM に関知せず UTF8 をデコードする [詳解]
 
template<typename InQueue , typename OutQueue >
result_value utf8_decode_without_bom_or_fail (InQueue &in, OutQueue &out)
 BOM や失敗に関知せず UTF8 をデコードする [詳解]
 
template<typename InQueue , typename OutQueue >
result_value utf8_encode (InQueue &in, OutQueue &out)
 UTF-8 へエンコードする [詳解]
 
coder get_encoder (encoding_name name)
 エンコーダを取得する [詳解]
 
template<typename InQueue , typename OutQueue >
result_value decode (InQueue &in, encoding_name name, OutQueue &out)
 デコード [詳解]
 
template<typename InQueue , typename OutQueue >
result_value encode_or_fail (InQueue &in, coder c, OutQueue &out)
 エンコードするか失敗する [詳解]
 
template<typename T , typename OutputIterator >
void from_io_queue_convert (io_queue< T > q, OutputIterator out)
 io_queue を文字列へ変換する [詳解]
 
template<typename InputIterator >
auto to_io_queue_convert (InputIterator first, InputIterator last)
 文字列を io_queue へ変換する [詳解]
 

変数

const std::array< uint32_t, 19782 > index_code_point_big5
 
const std::vector< uint32_t > index_code_point_euc_kr
 
const std::array< uint32_t, 23940 > index_code_point_gb18030
 
const std::vector< uint32_t > index_code_point_jis0208
 
const std::vector< uint32_t > index_code_point_jis0212
 
const std::vector< uint32_t > index_code_point_ibm866
 
const std::vector< uint32_t > index_code_point_iso_2022_jp_katakana
 
const std::vector< uint32_t > index_code_point_iso_8859_2
 
const std::vector< uint32_t > index_code_point_iso_8859_3
 
const std::vector< uint32_t > index_code_point_iso_8859_4
 
const std::vector< uint32_t > index_code_point_iso_8859_5
 
const std::vector< uint32_t > index_code_point_iso_8859_6
 
const std::vector< uint32_t > index_code_point_iso_8859_7
 
const std::vector< uint32_t > index_code_point_iso_8859_8
 
const std::vector< uint32_t > index_code_point_iso_8859_10
 
const std::vector< uint32_t > index_code_point_iso_8859_13
 
const std::vector< uint32_t > index_code_point_iso_8859_14
 
const std::vector< uint32_t > index_code_point_iso_8859_15
 
const std::vector< uint32_t > index_code_point_iso_8859_16
 
const std::vector< uint32_t > index_code_point_koi8_r
 
const std::vector< uint32_t > index_code_point_koi8_u
 
const std::vector< uint32_t > index_code_point_macintosh
 
const std::vector< uint32_t > index_code_point_windows_874
 
const std::vector< uint32_t > index_code_point_windows_1250
 
const std::vector< uint32_t > index_code_point_windows_1251
 
const std::vector< uint32_t > index_code_point_windows_1252
 
const std::vector< uint32_t > index_code_point_windows_1253
 
const std::vector< uint32_t > index_code_point_windows_1254
 
const std::vector< uint32_t > index_code_point_windows_1255
 
const std::vector< uint32_t > index_code_point_windows_1256
 
const std::vector< uint32_t > index_code_point_windows_1257
 
const std::vector< uint32_t > index_code_point_windows_1258
 
const std::vector< uint32_t > index_code_point_x_mac_cyrillic
 
const std::multimap< uint32_t, uint32_t > index_code_point_gb18030_ranges
 
const std::vector< uint32_t > index_pointer_big5_0
 
const std::vector< uint16_t > index_pointer_big5_1
 
const std::vector< uint32_t > index_pointer_euc_kr_0
 
const std::vector< uint16_t > index_pointer_euc_kr_1
 
const std::vector< uint32_t > index_pointer_gb18030_0
 
const std::vector< uint16_t > index_pointer_gb18030_1
 
const std::vector< uint32_t > index_pointer_jis0208_0
 
const std::vector< uint16_t > index_pointer_jis0208_1
 
const std::vector< uint32_t > index_pointer_jis0212_0
 
const std::vector< uint16_t > index_pointer_jis0212_1
 
const std::vector< uint32_t > index_pointer_ibm866_0
 
const std::vector< uint16_t > index_pointer_ibm866_1
 
const std::vector< uint32_t > index_pointer_iso_2022_jp_katakana_0
 
const std::vector< uint16_t > index_pointer_iso_2022_jp_katakana_1
 
const std::vector< uint32_t > index_pointer_iso_8859_2_0
 
const std::vector< uint16_t > index_pointer_iso_8859_2_1
 
const std::vector< uint32_t > index_pointer_iso_8859_3_0
 
const std::vector< uint16_t > index_pointer_iso_8859_3_1
 
const std::vector< uint32_t > index_pointer_iso_8859_4_0
 
const std::vector< uint16_t > index_pointer_iso_8859_4_1
 
const std::vector< uint32_t > index_pointer_iso_8859_5_0
 
const std::vector< uint16_t > index_pointer_iso_8859_5_1
 
const std::vector< uint32_t > index_pointer_iso_8859_6_0
 
const std::vector< uint16_t > index_pointer_iso_8859_6_1
 
const std::vector< uint32_t > index_pointer_iso_8859_7_0
 
const std::vector< uint16_t > index_pointer_iso_8859_7_1
 
const std::vector< uint32_t > index_pointer_iso_8859_8_0
 
const std::vector< uint16_t > index_pointer_iso_8859_8_1
 
const std::vector< uint32_t > index_pointer_iso_8859_10_0
 
const std::vector< uint16_t > index_pointer_iso_8859_10_1
 
const std::vector< uint32_t > index_pointer_iso_8859_13_0
 
const std::vector< uint16_t > index_pointer_iso_8859_13_1
 
const std::vector< uint32_t > index_pointer_iso_8859_14_0
 
const std::vector< uint16_t > index_pointer_iso_8859_14_1
 
const std::vector< uint32_t > index_pointer_iso_8859_15_0
 
const std::vector< uint16_t > index_pointer_iso_8859_15_1
 
const std::vector< uint32_t > index_pointer_iso_8859_16_0
 
const std::vector< uint16_t > index_pointer_iso_8859_16_1
 
const std::vector< uint32_t > index_pointer_koi8_r_0
 
const std::vector< uint16_t > index_pointer_koi8_r_1
 
const std::vector< uint32_t > index_pointer_koi8_u_0
 
const std::vector< uint16_t > index_pointer_koi8_u_1
 
const std::vector< uint32_t > index_pointer_macintosh_0
 
const std::vector< uint16_t > index_pointer_macintosh_1
 
const std::vector< uint32_t > index_pointer_windows_874_0
 
const std::vector< uint16_t > index_pointer_windows_874_1
 
const std::vector< uint32_t > index_pointer_windows_1250_0
 
const std::vector< uint16_t > index_pointer_windows_1250_1
 
const std::vector< uint32_t > index_pointer_windows_1251_0
 
const std::vector< uint16_t > index_pointer_windows_1251_1
 
const std::vector< uint32_t > index_pointer_windows_1252_0
 
const std::vector< uint16_t > index_pointer_windows_1252_1
 
const std::vector< uint32_t > index_pointer_windows_1253_0
 
const std::vector< uint16_t > index_pointer_windows_1253_1
 
const std::vector< uint32_t > index_pointer_windows_1254_0
 
const std::vector< uint16_t > index_pointer_windows_1254_1
 
const std::vector< uint32_t > index_pointer_windows_1255_0
 
const std::vector< uint16_t > index_pointer_windows_1255_1
 
const std::vector< uint32_t > index_pointer_windows_1256_0
 
const std::vector< uint16_t > index_pointer_windows_1256_1
 
const std::vector< uint32_t > index_pointer_windows_1257_0
 
const std::vector< uint16_t > index_pointer_windows_1257_1
 
const std::vector< uint32_t > index_pointer_windows_1258_0
 
const std::vector< uint16_t > index_pointer_windows_1258_1
 
const std::vector< uint32_t > index_pointer_x_mac_cyrillic_0
 
const std::vector< uint16_t > index_pointer_x_mac_cyrillic_1
 
const std::multimap< uint32_t, uint32_t > index_pointer_gb18030_ranges
 
const std::vector< uint32_t > index_pointer_Shift_JIS_0
 
const std::vector< uint16_t > index_pointer_Shift_JIS_1
 

詳解

非公開の名前空間。

関数詳解

◆ serialize_io_queue()

std::u32string wordring::whatwg::encoding::serialize_io_queue ( text_decoder_common c,
io_queue< char32_t > &  in 
)
inline

IO キューを直列化する

参照
https://encoding.spec.whatwg.org/#concept-td-serialize

◆ get_index_gb18030_ranges_pointer()

std::optional<std::uint32_t> wordring::whatwg::encoding::get_index_gb18030_ranges_pointer ( std::uint32_t  code_point)
inline

ranges_pointerに限り32ビットの戻り値が必要。

参照
https://triple-underscore.github.io/Encoding-ja.html#index-gb18030-ranges-pointer

◆ process_queue()

template<typename Coder , typename InQueue , typename OutQueue >
result_value wordring::whatwg::encoding::process_queue ( Coder &  c,
InQueue &  in,
OutQueue &  out,
error_mode_name  mode 
)
inline

キューを処理する

引数
[in]cエンコーダ、あるいはデコーダ
[in]in入力キュー
[out]out出力イテレータ
[in]modeエラーモード
参照
https://encoding.spec.whatwg.org/#concept-encoding-run
https://triple-underscore.github.io/Encoding-ja.html#concept-encoding-run

◆ get_encoding_label()

std::u32string wordring::whatwg::encoding::get_encoding_label ( encoding_name  name)
inline

エンコーディングに対応するラベルを返す

参照
https://encoding.spec.whatwg.org/#dom-textdecoder-encoding

◆ get_encoding_decoder()

coder wordring::whatwg::encoding::get_encoding_decoder ( encoding_name  name)
inline

brief エンコーディング名に対応するデコーダを返す

◆ get_encoding_encoder()

coder wordring::whatwg::encoding::get_encoding_encoder ( encoding_name  name)
inline

brief エンコーディング名に対応するエンコーダを返す

◆ get_output_encoding_name()

encoding_name wordring::whatwg::encoding::get_output_encoding_name ( encoding_name  name)
inline

◆ bom_sniff()

template<typename InQueue >
io_result< encoding_name > wordring::whatwg::encoding::bom_sniff ( InQueue &  in)
inline

◆ encode()

template<typename InQueue , typename OutQueue >
result_value wordring::whatwg::encoding::encode ( InQueue &  in,
encoding_name  name,
OutQueue &  out 
)
inline

◆ utf8_decode() [1/2]

template<typename InQueue , typename OutQueue >
result_value wordring::whatwg::encoding::utf8_decode ( InQueue &  in,
OutQueue &  out 
)
inline

UTF8 をデコードする

戻り値
完了、継続あるいはエラーを示す
参照
https://encoding.spec.whatwg.org/#utf-8-decode
https://triple-underscore.github.io/Encoding-ja.html#decode

EOQ によってデコードの完了を表現できるか?

◆ utf8_decode() [2/2]

template<typename OutQueue , typename InQueue >
OutQueue wordring::whatwg::encoding::utf8_decode ( InQueue &  in)
inline

UTF8 をデコードする

参照
inline void utf8_decode(InQueue& in, OutQueue& out)

待機状態をどう伝えるか?

◆ utf8_decode_without_bom()

template<typename InQueue , typename OutQueue >
result_value wordring::whatwg::encoding::utf8_decode_without_bom ( InQueue &  in,
OutQueue &  out 
)
inline

BOM に関知せず UTF8 をデコードする

参照
https://triple-underscore.github.io/Encoding-ja.html#utf-8-decode-without-bom

◆ utf8_decode_without_bom_or_fail()

template<typename InQueue , typename OutQueue >
result_value wordring::whatwg::encoding::utf8_decode_without_bom_or_fail ( InQueue &  in,
OutQueue &  out 
)
inline

BOM や失敗に関知せず UTF8 をデコードする

参照
https://encoding.spec.whatwg.org/#utf-8-decode-without-bom-or-fail

◆ utf8_encode()

template<typename InQueue , typename OutQueue >
result_value wordring::whatwg::encoding::utf8_encode ( InQueue &  in,
OutQueue &  out 
)
inline

UTF-8 へエンコードする

引数
[in]inchar32_t 入力キュー
[out]inchar 出力キュー
参照
https://encoding.spec.whatwg.org/#utf-8-encode

◆ get_encoder()

coder wordring::whatwg::encoding::get_encoder ( encoding_name  name)
inline

エンコーダを取得する

参照
https://encoding.spec.whatwg.org/#get-an-encoder

◆ decode()

template<typename InQueue , typename OutQueue >
result_value wordring::whatwg::encoding::decode ( InQueue &  in,
encoding_name  name,
OutQueue &  out 
)
inline

デコード

参照
https://triple-underscore.github.io/Encoding-ja.html#decode

規格の戻り値は、I/O Queue となっているが、改変している。

◆ encode_or_fail()

template<typename InQueue , typename OutQueue >
result_value wordring::whatwg::encoding::encode_or_fail ( InQueue &  in,
coder  c,
OutQueue &  out 
)
inline

エンコードするか失敗する

参照
https://triple-underscore.github.io/Encoding-ja.html#encode-or-fail

◆ from_io_queue_convert()

template<typename T , typename OutputIterator >
void wordring::whatwg::encoding::from_io_queue_convert ( io_queue< T >  q,
OutputIterator  out 
)
inline

io_queue を文字列へ変換する

参照
https://encoding.spec.whatwg.org/#from-i-o-queue-convert

読み込んだ文字はキューから消費されるらしい。

◆ to_io_queue_convert()

template<typename InputIterator >
auto wordring::whatwg::encoding::to_io_queue_convert ( InputIterator  first,
InputIterator  last 
)
inline