Adding KOI8-U support to JDK-1.5
Mikhail T.
mi at aldan.algebra.com
Fri Jul 22 03:03:28 GMT 2005
Hello!
Below is code to add the support for the KOI8-U charset to JDK.
Please, let me know if I can commit it. It is even simpler to add this
support to earlier JDKs (no need for the additional KOI8_U.java, just
follow the patch author's instructions), but let's start with the
"experimental" JDK-1.5 first.
Thank you!
-mi
-------------- next part --------------
A non-text attachment was scrubbed...
Name: jdk15-koi8-u.patch
Type: text/x-patch
Size: 1814 bytes
Desc: Patch for the port itself
Url : http://lists.freebsd.org/pipermail/freebsd-java/attachments/20050721/0543cf4b/jdk15-koi8-u.bin
-------------- next part --------------
--- ../../j2se/src/share/classes/sun/nio/cs/standard-charsets Tue Oct 19 14:57:57 2004
+++ ../../j2se/src/share/classes/sun/nio/cs/standard-charsets Wed Jul 20 00:02:11 2005
@@ -172,6 +172,11 @@
charset KOI8-R KOI8_R
alias koi8_r # JDK historical
- alias koi8
alias cskoi8r
+
+charset KOI8-U KOI8_U # Superset of KOI8-R covering other
+ alias koi8_u # Cyrillics-using alphabets
+ alias koi8
+ alias cskoi8u
+ alias koi8u
charset windows-1250 MS1250
--- ../../j2se/src/share/classes/sun/io/CharacterEncoding.java Tue Oct 19 14:57:28 2004
+++ ../../j2se/src/share/classes/sun/io/CharacterEncoding.java Wed Jul 20 01:10:16 2005
@@ -75,4 +75,5 @@
aliasTable.put("gbk", "GBK");
aliasTable.put("koi8-r", "KOI8_R");
+ aliasTable.put("koi8-u", "KOI8_U");
aliasTable.put("tis620.2533", "TIS620");
@@ -763,6 +764,11 @@
// Russian KOI8-R
aliasTable.put("koi8-r", "KOI8_R");
- aliasTable.put("koi8", "KOI8_R");
aliasTable.put("cskoi8r", "KOI8_R");
+
+ // Ukrainian and Bielorussian KOI8-U (includes KOI8-R)
+ aliasTable.put("koi8-u", "KOI8_U");
+ aliasTable.put("koi8", "KOI8_U");
+ aliasTable.put("koi8u", "KOI8_U");
+ aliasTable.put("cskoi8u", "KOI8_U");
// Simplified Chinese
--- ../../j2se/make/java/sun_io/FILES_java.gmk Tue Oct 19 14:44:54 2004
+++ ../../j2se/make/java/sun_io/FILES_java.gmk Wed Jul 20 01:20:35 2005
@@ -65,4 +65,6 @@
$(TARGDIR)sun/io/ByteToCharKOI8_R.java \
$(TARGDIR)sun/io/CharToByteKOI8_R.java \
+ $(TARGDIR)sun/io/ByteToCharKOI8_U.java \
+ $(TARGDIR)sun/io/CharToByteKOI8_U.java \
$(TARGDIR)sun/io/ByteToCharSingleByte.java \
$(TARGDIR)sun/io/CharToByteSingleByte.java \
More information about the freebsd-java
mailing list