convertToSimplifiedChinese static method

String convertToSimplifiedChinese(
  1. String str
)

将繁体字转换为简体字 @param str 需要转换的繁体字 @return 转换后的简体字

Implementation

static String convertToSimplifiedChinese(String str) {
  StringBuffer sb = StringBuffer();
  for (int i = 0, len = str.length; i < len; i++) {
    sb.write(convertCharToSimplifiedChinese(str[i]));
  }
  return sb.toString();
}