?? chineseutils.java
字號(hào):
package utils;
/**
* @author lixiaoqing
*
*/
public class ChineseUtils {
/**
* 從數(shù)據(jù)庫(kù)讀出數(shù)據(jù)時(shí)的編碼轉(zhuǎn)換
* @param chi 輸入字符串
* @return 轉(zhuǎn)換后的字符串
*/
public static String transToEn(String chi)
{
String result = null;
byte temp[];
try
{
temp = chi.getBytes("iso-8859-1");
result = new String(temp);
}
catch(Exception e)
{
}
return result;
}
public static String transToCh(String chi)
{
String result = null;
byte temp[];
try
{
temp = chi.getBytes("gb2312");
result = new String(temp);
}
catch(Exception e)
{
}
return result;
}
}
?? 快捷鍵說(shuō)明
復(fù)制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號(hào)
Ctrl + =
減小字號(hào)
Ctrl + -