src/java.base/share/classes/sun/nio/cs/HKSCS.java
Print this page
*** 21,39 ****
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
* or visit www.oracle.com if you need additional information or have any
* questions.
*/
! package sun.nio.cs.ext;
import java.nio.ByteBuffer;
import java.nio.CharBuffer;
import java.nio.charset.Charset;
import java.nio.charset.CharsetDecoder;
import java.nio.charset.CharsetEncoder;
import java.nio.charset.CoderResult;
import java.util.Arrays;
import sun.nio.cs.Surrogate;
import static sun.nio.cs.CharsetMapping.*;
public class HKSCS {
--- 21,40 ----
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
* or visit www.oracle.com if you need additional information or have any
* questions.
*/
! package sun.nio.cs;
import java.nio.ByteBuffer;
import java.nio.CharBuffer;
import java.nio.charset.Charset;
import java.nio.charset.CharsetDecoder;
import java.nio.charset.CharsetEncoder;
import java.nio.charset.CoderResult;
import java.util.Arrays;
+ import sun.nio.cs.DoubleByte;
import sun.nio.cs.Surrogate;
import static sun.nio.cs.CharsetMapping.*;
public class HKSCS {
*** 214,224 ****
return decodeArrayLoop(src, dst);
else
return decodeBufferLoop(src, dst);
}
! static void initb2c(char[][]b2c, String[] b2cStr)
{
for (int i = 0; i < b2cStr.length; i++) {
if (b2cStr[i] == null)
b2c[i] = DoubleByte.B2C_UNMAPPABLE;
else
--- 215,225 ----
return decodeArrayLoop(src, dst);
else
return decodeBufferLoop(src, dst);
}
! public static void initb2c(char[][]b2c, String[] b2cStr)
{
for (int i = 0; i < b2cStr.length; i++) {
if (b2cStr[i] == null)
b2c[i] = DoubleByte.B2C_UNMAPPABLE;
else
*** 393,403 ****
static char[] C2B_UNMAPPABLE = new char[0x100];
static {
Arrays.fill(C2B_UNMAPPABLE, (char)UNMAPPABLE_ENCODING);
}
! static void initc2b(char[][] c2b, String[] b2cStr, String pua) {
// init c2b/c2bSupp from b2cStr and supp
int b2Min = 0x40;
Arrays.fill(c2b, C2B_UNMAPPABLE);
for (int b1 = 0; b1 < 0x100; b1++) {
String s = b2cStr[b1];
--- 394,404 ----
static char[] C2B_UNMAPPABLE = new char[0x100];
static {
Arrays.fill(C2B_UNMAPPABLE, (char)UNMAPPABLE_ENCODING);
}
! public static void initc2b(char[][] c2b, String[] b2cStr, String pua) {
// init c2b/c2bSupp from b2cStr and supp
int b2Min = 0x40;
Arrays.fill(c2b, C2B_UNMAPPABLE);
for (int b1 = 0; b1 < 0x100; b1++) {
String s = b2cStr[b1];