encoding.java
来自「这是书上<java毕业设计与项目实践>的第8章:基于Struts的电」· Java 代码 · 共 34 行
JAVA
34 行
/*
* Created on 2005-8-5
*
*/
package banksystem;
import banksystem.Constants;
/**
* @author 曲本盛
*
* TODO Struts 项目实践
*/
public class Encoding {
public static String CNtoISO(String str){
String temp = "";
try{
temp = new String(str.getBytes(Constants.ISO_ENCODING),Constants.CN_ENODING);
}
catch(Exception e){
throw new RuntimeException(e);
}
return temp;
}
public static String ISOtoCN(String str){
String temp = "";
try{
temp = new String(str.getBytes(Constants.CN_ENODING),Constants.ISO_ENCODING);
}
catch(Exception e){
throw new RuntimeException(e);
}
return temp;
}
}
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?