Encoding name | Description |
---|---|
8859_1 | Latin-1 ASCII (the default). This just takes the low order 8 bits and tacks on a high order 0 byte. |
Big5 | Chinese |
Cp1250 .. Cp1258 | Windows code pages. Code sets for various versions of Windows. For example, the Microsoft J++ JVM uses cp1252 for the English version of NT. |
Default | 7-bit ASCII (not the actual default!) Strips off the high order bit 7 and tacks on a high order 0 byte. |
GB2312 | Chinese |
JIS | Japanese |
JIS0208 | Japanese |
KSC5601 | Korean |
SingleByte | This does not expand low order eight-bits with high order zero as its name implies. It looks to be a complex encoding for some Asian language. |
SJIS | Shift JIS. Japanese. A Microsoft code that extends csHalfWidthKatakana to include kanji by adding a second byte when the value of the first byte is in the ranges 81-9F or E0-EF. |
UTF8 | counted strings |
public class Vegetable { public static final int unknown = 0; public static final int beet = 1; public static final int brocolli = 2; public static final int carrot = 3; } // end class Vegetable public class JuiceBar { public void mixIn (int v) { switch (v) { case Vegetable.brocolli: ... break; case Vegetable.carrot: ... break; default: ... } } // end mixIn } // end class Juicebar
public class Vegetable { protected Vegetable () { /* constructor has no fields to initialise */ } public static final Vegetable unknown = new Vegetable(); public static final Vegetable beet = new Vegetable(); public static final Vegetable brocolli = new Vegetable(); public static final Vegetable carrot = new Vegetable(); } // end class Vegetable public class JuiceBar { public void mixIn (Vegetable v) { if (v == Vegetable.brocolli) ... } ... } // end class JuiceBar
![]() |
![]() |
![]() |
|
Canadian Mind Products | The Mining Company's Focus on Java Best of the Net Award |
You can get an updated copy of this page from http://mindprod.com/jglosse.html |