您的位置:首页 > 其它

汉字转换成拼音

2016-01-07 19:50 316 查看
java代码
City entity=null;
if(city.getId()!=null){
entity =
this.getById(city.getId());
entity.setName(city.getName());
entity.setPid(city.getPid());
entity.setPinying(ChineseUtils.toPinyin(city.getName(),
PinyinFormat.TONELESS_PINYIN_FORMAT));


引用资源包
com/luhuiguo/chinese-utils/1.0/chinese-utils-1.0.jar
引用类

import com.luhuiguo.chinese.pinyin.Pinyin;
import com.luhuiguo.chinese.pinyin.PinyinFormat;
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: