Java Utililty Methods ISO to GB String

List of utility methods to do ISO to GB String

Description

The list of methods to do ISO to GB String are organized into topic(s).

Method

Stringiso2Gb(String gbString)
Converts string from GB2312 encoding ISO8859-1 (Latin-1) encoding.
if (gbString == null)
    return null;
String outString = "";
try {
    byte[] temp = null;
    temp = gbString.getBytes("ISO8859-1");
    outString = new String(temp, "GB2312");
} catch (java.io.UnsupportedEncodingException e) {
...
StringISO2GB(String text)
ISOGB
String result = "";
try {
    result = new String(text.getBytes("ISO-8859-1"), "GB2312");
} catch (UnsupportedEncodingException e) {
    result = e.toString();
return result;