Topic: j2se Unicode 转化为 gb2312

  Print this page

1.j2se Unicode 转化为 gb2312 Copy to clipboard
Posted by: pettyman
Posted on: 2004-08-15 16:05

高手好,有谁知道知道Unicode 转化为 gb2312的规则,请指点!谢谢

2.Re:j2se Unicode 转化为 gb2312 [Re: pettyman] Copy to clipboard
Posted by: href
Posted on: 2004-08-16 11:17

你是指这样子?


String unicode = "\u4444\u8888";
String gb2312 = new String(unicode.getBytes("UTF-8"), "GB2312");

3.Re:j2se Unicode 转化为 gb2312 [Re: href] Copy to clipboard
Posted by: why
Posted on: 2004-08-31 05:25

href wrote:
你是指这样子?


String unicode = "\u4444\u8888";
String gb2312 = new String(unicode.getBytes("UTF-8"), "GB2312");

I am wondering whether this would work. If so, why would someone worked out something like this:

Herong's Notes on GB2312 Character Set
http://www.geocities.com/herong_yang/gb2312/unicode_gb2312.html


   Powered by Jute Powerful Forum® Version Jute 1.5.6 Ent
Copyright © 2002-2021 Cjsdn Team. All Righits Reserved. 闽ICP备05005120号-1
客服电话 18559299278    客服信箱 714923@qq.com    客服QQ 714923