private static String unknow2chines(String str){
String result = "";
int start = 0, end = 0;
while(start < str.length())
{
start = str.indexOf("&#", end);
if(start >= 0){
result += str.substring(end, start);
start = start + 2;
end = str.indexOf(";", start);
if(end >= 0)
{
String temp = str.substring(start, end);
int a = Integer.valueOf(temp);
char[] ch = new char[]{(char) a};
result += new String(ch);
start = ++end;
}else{
return result + "&#" + str.substring(start);
}
}else{
return result + str.substring(end);
}
}
return result.trim();
}