字符转为unicode编码
来源:互联网 发布:淘宝商品分类数据库 编辑:程序博客网 时间:2024/05/21 09:07
将字符转为unicode编码。
public class ConvertCode { public static void main(String[] args) throws Exception{ encodeUnicode("₃"); } //转换为unicode public static void encodeUnicode(String gbString) { char[] utfBytes = gbString.toCharArray(); String unicodeBytes = ""; for (int byteIndex = 0; byteIndex < utfBytes.length; byteIndex++) { String hexB = Integer.toHexString(utfBytes[byteIndex]); if (hexB.length() <= 2) { hexB = "00" + hexB; } unicodeBytes = unicodeBytes + "\\u" + hexB; } System.out.println(unicodeBytes); }}
- 字符转为unicode编码
- 字符转为Unicode编码的小方法
- 中文转为unicode编码
- 中文转为unicode编码
- 字符编码(unicode编码)
- Unicode字符编码规范
- Unicode字符编码规范
- Unicode 与 字符编码
- Unicode字符编码规范
- Unicode字符编码规范
- Unicode字符编码标准
- Unicode字符编码规范
- 字符与UNICODE编码
- unicode宽字符编码
- Unicode字符编码规
- Unicode字符编码规范
- Unicode字符编码
- Unicode字符编码规范
- 微信公众平台PHP开发,学习资料
- 编程常用网站在线工具收集(一)
- 庞果英雄会 数组排序
- jQuery Validation详解
- 1062. Talent and Virtue (25)
- 字符转为unicode编码
- AC自动机数组写法
- SOA,不看你永远不知道的事
- php虚拟机配置
- gentoo 网卡命名
- Lua程序设计第二版(笔记)第九章协同程序
- 04_N阶楼梯上楼问题、输入一个ip地址串,判断是否合法、输入一个四行五列的矩阵,找出每列最大的两个数
- jQuery.extend 函数详解
- HTTP header 详解