Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( UTF32BE = &utf32be{} UTF32LE = &utf32le{} )
提供给用户使用的并发安全的编解码器接口
View Source
var Codec = map[string]encoding.Encoding{ "utf-8": encoding.Nop, "utf-16be": unicode.UTF16(unicode.BigEndian, unicode.IgnoreBOM), "utf-16le": unicode.UTF16(unicode.LittleEndian, unicode.IgnoreBOM), "hz-gb2312": simplifiedchinese.HZGB2312, "gbk": simplifiedchinese.GBK, "big5": traditionalchinese.Big5, "gb18030": simplifiedchinese.GB18030, "euc-kr": korean.EUCKR, "euc-jp": japanese.EUCJP, "iso-2022-jp": japanese.ISO2022JP, "shift-jis": japanese.ShiftJIS, }
Codec映射编码格式字符串到对应的编解码器,因此不需在导入encoding等包
View Source
var ErrUnknown = errors.New("unknown codec")
提供的编码格式字符串未知时,会返回本错误
Functions ¶
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.