利用java的native2ascii工具进行资源文件的转化

1 说明文件

Usage: native2ascii [-reverse] [-encoding encoding] [inputfile [outputfile]]
选项[-reverse]为反向转换

 

2 可以将文本文件转成资源文件或反之,如下
native2ascii -encoding GBK -reverse resources_zh_CN.properties resources_zh_CN.properties.source
native2ascii -encoding GBK resources_zh_CN.properties.source resources_zh_CN.properties
native2ascii -encoding UTF-8 -reverse resources_zh_CN.properties resources_zh_CN.properties.source
native2ascii -encoding UTF-8 resources_zh_CN.properties.source resources_zh_CN.properties

3 备注

在开发过程中,将整个文件转化,不用一个个key转化,比较方便

你可能感兴趣的:(java)