Class \Prado\Util\Helpers\TEscCharsetConverter
TEscCharsetConverter class.
TEscCharsetConverter is the ESC Charset Converter for converting between ESC character sets] encodings and their iConv character encodings.
Each Esc charset Encoding has 4 versions for G0, G1, G2, and G3.
Class hierarchy
Author: Brad Anderson <belisoful@icloud.com>Since: 4.3.0
public
static
|
decodeEscapeCharset(string $charset) : string|null
Convert an Escape Character Code Encoding to the iconv character
encoding.
|
public
static
|
encodeEscapeCharset(string $charset) : string|null
Convert an Escape Character Code Encoding to the iconv character
encoding.
|
|
public
mixed
|
ESC_CHAR_ENCODINGS_MAP
|
[
"\x1b%G" => 'UTF-8',
// ESC-'%G'
"\x1b(@" => 'ASCII',
"\x1b)@" => 'ASCII',
"\x1b*@" => 'ASCII',
"\x1b+@" => 'ASCII',
"\x1b(A" => 'ASCII.en_GB',
"\x1b)A" => 'ASCII.en_GB',
"\x1b*A" => 'ASCII.en_GB',
"\x1b+A" => 'ASCII.en_GB',
"\x1b(B" => 'ASCII.en_US',
"\x1b)B" => 'ASCII.en_US',
"\x1b*B" => 'ASCII.en_US',
"\x1b+B" => 'ASCII.en_US',
"\x1b(C" => 'ASCII.fi',
"\x1b)C" => 'ASCII.fi',
"\x1b*C" => 'ASCII.fi',
"\x1b+C" => 'ASCII.fi',
"\x1b(D" => 'ASCII.sv',
"\x1b)D" => 'ASCII.sv',
"\x1b*D" => 'ASCII.sv',
"\x1b+D" => 'ASCII.sv',
"\x1b(E" => 'ASCII.no',
"\x1b)E" => 'ASCII.no',
"\x1b*E" => 'ASCII.no',
"\x1b+E" => 'ASCII.no',
"\x1b(F" => 'ASCII.no',
"\x1b)F" => 'ASCII.no',
"\x1b*F" => 'ASCII.no',
"\x1b+F" => 'ASCII.no',
"\x1b(G" => 'ASCII.se',
"\x1b)G" => 'ASCII.se',
"\x1b*G" => 'ASCII.se',
"\x1b+G" => 'ASCII.se',
"\x1b(I" => 'JIS_X0201',
"\x1b)I" => 'JIS_X0201',
"\x1b*I" => 'JIS_X0201',
"\x1b+I" => 'JIS_X0201',
"\x1b(J" => 'JIS_X0201',
"\x1b)J" => 'JIS_X0201',
"\x1b*J" => 'JIS_X0201',
"\x1b+J" => 'JIS_X0201',
"\x1b(K" => 'ASCII.de',
"\x1b)K" => 'ASCII.de',
"\x1b*K" => 'ASCII.de',
"\x1b+K" => 'ASCII.de',
"\x1b(L" => 'ASCII.pt',
"\x1b)L" => 'ASCII.pt',
"\x1b*L" => 'ASCII.pt',
"\x1b+L" => 'ASCII.pt',
"\x1b(N" => 'ISO-5427',
"\x1b)N" => 'ISO-5427',
"\x1b*N" => 'ISO-5427',
"\x1b+N" => 'ISO-5427',
"\x1b(T" => 'ISO646-CN',
"\x1b)T" => 'ISO646-CN',
"\x1b*T" => 'ISO646-CN',
"\x1b+T" => 'ISO646-CN',
"\x1b(Y" => 'ASCII.it',
"\x1b)Y" => 'ASCII.it',
"\x1b*Y" => 'ASCII.it',
"\x1b+Y" => 'ASCII.it',
"\x1b(Z" => 'ASCII.es',
"\x1b)Z" => 'ASCII.es',
"\x1b*Z" => 'ASCII.es',
"\x1b+Z" => 'ASCII.es',
"\x1b([" => 'ASCII.el',
"\x1b)[" => 'ASCII.el',
"\x1b*[" => 'ASCII.el',
"\x1b+[" => 'ASCII.el',
"\x1b(`" => 'ASCII.no',
"\x1b)`" => 'ASCII.no',
"\x1b*`" => 'ASCII.no',
"\x1b+`" => 'ASCII.no',
"\x1b(f" => 'ASCII.fr',
"\x1b)f" => 'ASCII.fr',
"\x1b*f" => 'ASCII.fr',
"\x1b+f" => 'ASCII.fr',
"\x1b(g" => 'ASCII.pt',
"\x1b)g" => 'ASCII.pt',
"\x1b*g" => 'ASCII.pt',
"\x1b+g" => 'ASCII.pt',
"\x1b(h" => 'ASCII.es',
"\x1b)h" => 'ASCII.es',
"\x1b*h" => 'ASCII.es',
"\x1b+h" => 'ASCII.es',
"\x1b(i" => 'ASCII.hu',
"\x1b)i" => 'ASCII.hu',
"\x1b*i" => 'ASCII.hu',
"\x1b+i" => 'ASCII.hu',
"\x1b(w" => 'ASCII.fr_CA',
"\x1b)w" => 'ASCII.fr_CA',
"\x1b*w" => 'ASCII.fr_CA',
"\x1b+w" => 'ASCII.fr_CA',
"\x1b(x" => 'ASCII.fr_CA',
"\x1b)x" => 'ASCII.fr_CA',
"\x1b*x" => 'ASCII.fr_CA',
"\x1b+x" => 'ASCII.fr_CA',
"\x1b(z" => 'ASCII.yu',
"\x1b)z" => 'ASCII.yu',
"\x1b*z" => 'ASCII.yu',
"\x1b+z" => 'ASCII.yu',
"\x1b,A" => 'ISO-8859-1',
"\x1b-A" => 'ISO-8859-1',
"\x1b.A" => 'ISO-8859-1',
"\x1b/A" => 'ISO-8859-1',
"\x1b,B" => 'ISO-8859-2',
"\x1b-B" => 'ISO-8859-2',
"\x1b.B" => 'ISO-8859-2',
"\x1b/B" => 'ISO-8859-2',
"\x1b,C" => 'ISO-8859-3',
"\x1b-C" => 'ISO-8859-3',
"\x1b.C" => 'ISO-8859-3',
"\x1b/C" => 'ISO-8859-3',
"\x1b,D" => 'ISO-8859-4',
"\x1b-D" => 'ISO-8859-4',
"\x1b.D" => 'ISO-8859-4',
"\x1b/D" => 'ISO-8859-4',
"\x1b,E" => 'ISO-8859-5',
"\x1b-E" => 'ISO-8859-5',
"\x1b.E" => 'ISO-8859-5',
"\x1b/E" => 'ISO-8859-5',
"\x1b,F" => 'ISO-8859-7',
"\x1b-F" => 'ISO-8859-7',
"\x1b.F" => 'ISO-8859-7',
"\x1b/F" => 'ISO-8859-7',
"\x1b,G" => 'ISO-8859-6',
"\x1b-G" => 'ISO-8859-6',
"\x1b.G" => 'ISO-8859-6',
"\x1b/G" => 'ISO-8859-6',
"\x1b,H" => 'ISO-8859-8',
"\x1b-H" => 'ISO-8859-8',
"\x1b.H" => 'ISO-8859-8',
"\x1b/H" => 'ISO-8859-8',
"\x1b,I" => 'CSN 369103',
"\x1b-I" => 'CSN 369103',
"\x1b.I" => 'CSN 369103',
"\x1b/I" => 'CSN 369103',
"\x1b\$(@" => 'JIS0208',
"\x1b\$)@" => 'JIS0208',
"\x1b\$*@" => 'JIS0208',
"\x1b\$+@" => 'JIS0208',
"\x1b\$(B" => 'JIS0208',
"\x1b\$)B" => 'JIS0208',
"\x1b\$*B" => 'JIS0208',
"\x1b\$+B" => 'JIS0208',
"\x1b\$(D" => 'JIS_X0212',
"\x1b\$)D" => 'JIS_X0212',
"\x1b\$*D" => 'JIS_X0212',
"\x1b\$+D" => 'JIS_X0212',
"\x1b\$(O" => 'ISO-2022-JP-3',
"\x1b\$)O" => 'ISO-2022-JP-3',
"\x1b\$*O" => 'ISO-2022-JP-3',
"\x1b\$+O" => 'ISO-2022-JP-3',
"\x1b\$(P" => 'ISO-2022-JP-3',
"\x1b\$)P" => 'ISO-2022-JP-3',
"\x1b\$*P" => 'ISO-2022-JP-3',
"\x1b\$+P" => 'ISO-2022-JP-3',
]
|