View | Details | Raw Unified | Return to bug 39488
Collapse All | Expand All

(-)src\java\org\apache\poi\hpsf\Constants.java.orig (-2 / +99 lines)
Lines 26-41 Link Here
26
 */
26
 */
27
public class Constants
27
public class Constants
28
{
28
{
29
    /** <p>Codepage 037, a special case.</p> */
30
    public static final int CP_037 = 37;
29
31
30
    /** <p>Codepage for SJIS</p> */
32
    /** <p>Codepage for SJIS</p> */
31
    public static final int CP_SJIS = 932;
33
    public static final int CP_SJIS = 932;
32
34
35
    /** <p>Codepage for GBK, aka MS936.</p> */
36
    public static final int CP_GBK = 936;
37
33
    /** <p>Codepage for MS949</p> */
38
    /** <p>Codepage for MS949</p> */
34
    public static final int CP_MS949 = 949;
39
    public static final int CP_MS949 = 949;
35
40
36
    /** <p>Codepage for UTF-16</p> */
41
    /** <p>Codepage for UTF-16 (little-endian.)</p> */
37
    public static final int CP_UTF16 = 1200;
42
    public static final int CP_UTF16 = 1200;
38
43
44
    /** <p>Codepage for UTF-16 big-endian.</p> */
45
    public static final int CP_UTF16_BE = 1201;
46
47
    /** <p>Codepage for Windows 1250.</p> */
48
    public static final int CP_WINDOWS_1250 = 1250;
49
50
    /** <p>Codepage for Windows 1251.</p> */
51
    public static final int CP_WINDOWS_1251 = 1251;
52
53
    /** <p>Codepage for Windows 1252.</p> */
54
    public static final int CP_WINDOWS_1252 = 1252;
55
56
    /** <p>Codepage for Windows 1253.</p> */
57
    public static final int CP_WINDOWS_1253 = 1253;
58
59
    /** <p>Codepage for Windows 1254.</p> */
60
    public static final int CP_WINDOWS_1254 = 1254;
61
62
    /** <p>Codepage for Windows 1255.</p> */
63
    public static final int CP_WINDOWS_1255 = 1255;
64
65
    /** <p>Codepage for Windows 1256.</p> */
66
    public static final int CP_WINDOWS_1256 = 1256;
67
68
    /** <p>Codepage for Windows 1257.</p> */
69
    public static final int CP_WINDOWS_1257 = 1257;
70
71
    /** <p>Codepage for Windows 1258.</p> */
72
    public static final int CP_WINDOWS_1258 = 1258;
73
74
    /** <p>Codepage for Johab.</p> */
75
    public static final int CP_JOHAB = 1361;
76
39
    /** <p>Codepage for Macintosh Roman (Java: MacRoman)</p> */
77
    /** <p>Codepage for Macintosh Roman (Java: MacRoman)</p> */
40
    public static final int CP_MAC_ROMAN = 10000;
78
    public static final int CP_MAC_ROMAN = 10000;
41
79
Lines 89-98 Link Here
89
    /** <p>Codepage for Macintosh Croatian (Java: MacCroatian)</p> */
127
    /** <p>Codepage for Macintosh Croatian (Java: MacCroatian)</p> */
90
    public static final int CP_MAC_CROATIAN = 10082;
128
    public static final int CP_MAC_CROATIAN = 10082;
91
129
130
    /** <p>Codepage for US-ASCII.</p> */
131
    public static final int CP_US_ACSII = 20127;
132
133
    /** <p>Codepage for KOI8-R</p> */
134
    public static final int CP_KOI8_R = 20866;
135
136
    /** <p>Codepage for ISO-8859-1.</p> */
137
    public static final int CP_ISO_8859_1 = 28591;
138
139
    /** <p>Codepage for ISO-8859-2.</p> */
140
    public static final int CP_ISO_8859_2 = 28592;
141
142
    /** <p>Codepage for ISO-8859-3.</p> */
143
    public static final int CP_ISO_8859_3 = 28593;
144
145
    /** <p>Codepage for ISO-8859-4.</p> */
146
    public static final int CP_ISO_8859_4 = 28594;
147
148
    /** <p>Codepage for ISO-8859-5.</p> */
149
    public static final int CP_ISO_8859_5 = 28595;
150
151
    /** <p>Codepage for ISO-8859-6.</p> */
152
    public static final int CP_ISO_8859_6 = 28596;
153
154
    /** <p>Codepage for ISO-8859-7.</p> */
155
    public static final int CP_ISO_8859_7 = 28597;
156
157
    /** <p>Codepage for ISO-8859-8.</p> */
158
    public static final int CP_ISO_8859_8 = 28598;
159
160
    /** <p>Codepage for ISO-8859-9.</p> */
161
    public static final int CP_ISO_8859_9 = 28599;
162
163
    /** <p>Codepage for ISO-2022-JP</p> */
164
    public static final int CP_ISO_2022_JP1 = 50220;
165
166
    /** <p>Another codepage for ISO-2022-JP</p> */
167
    public static final int CP_ISO_2022_JP2 = 50221;
168
169
    /** <p>Yet another codepage for ISO-2022-JP</p> */
170
    public static final int CP_ISO_2022_JP3 = 50222;
171
172
    /** <p>Codepage for ISO-2022-KR</p> */
173
    public static final int CP_ISO_2022_KR = 50225;
174
175
    /** <p>Codepage for EUC-JP</p> */
176
    public static final int CP_EUC_JP = 51932;
177
178
    /** <p>Codepage for EUC-KR</p> */
179
    public static final int CP_EUC_KR = 51949;
180
181
    /** <p>Codepage for GB2312.</p> */
182
    public static final int CP_GB2312 = 52936;
183
184
    /** <p>Codepage for GB18030.</p> */
185
    public static final int CP_GB18030 = 54936;
186
187
    /** <p>Another codepage for US-ASCII.</p> */
188
    public static final int CP_US_ASCII2 = 65000;
189
92
    /** <p>Codepage for UTF-8</p> */
190
    /** <p>Codepage for UTF-8</p> */
93
    public static final int CP_UTF8 = 65001;
191
    public static final int CP_UTF8 = 65001;
94
192
95
    /** <p>Codepage for Unicode</p> */
193
    /** <p>Codepage for Unicode</p> */
96
    public static final int CP_UNICODE = CP_UTF16;
194
    public static final int CP_UNICODE = CP_UTF16;
97
98
}
195
}
(-)src\java\org\apache\poi\hpsf\VariantSupport.java.orig (+63 lines)
Lines 305-314 Link Here
305
        {
305
        {
306
            case Constants.CP_UTF16:
306
            case Constants.CP_UTF16:
307
                return "UTF-16";
307
                return "UTF-16";
308
            case Constants.CP_UTF16_BE:
309
                return "UTF-16BE";
308
            case Constants.CP_UTF8:
310
            case Constants.CP_UTF8:
309
                return "UTF-8";
311
                return "UTF-8";
312
            case Constants.CP_037:
313
                return "cp037";
314
            case Constants.CP_GBK:
315
                return "GBK";
310
            case Constants.CP_MS949:
316
            case Constants.CP_MS949:
311
                return "ms949";
317
                return "ms949";
318
            case Constants.CP_WINDOWS_1250:
319
                return "windows-1250";
320
            case Constants.CP_WINDOWS_1251:
321
                return "windows-1251";
322
            case Constants.CP_WINDOWS_1252:
323
                return "windows-1252";
324
            case Constants.CP_WINDOWS_1253:
325
                return "windows-1253";
326
            case Constants.CP_WINDOWS_1254:
327
                return "windows-1254";
328
            case Constants.CP_WINDOWS_1255:
329
                return "windows-1255";
330
            case Constants.CP_WINDOWS_1256:
331
                return "windows-1256";
332
            case Constants.CP_WINDOWS_1257:
333
                return "windows-1257";
334
            case Constants.CP_WINDOWS_1258:
335
                return "windows-1258";
336
            case Constants.CP_JOHAB:
337
                return "johab";
312
            case Constants.CP_MAC_ROMAN:
338
            case Constants.CP_MAC_ROMAN:
313
                return "MacRoman";
339
                return "MacRoman";
314
            case Constants.CP_MAC_JAPAN:
340
            case Constants.CP_MAC_JAPAN:
Lines 341-346 Link Here
341
                return "MacTurkish";
367
                return "MacTurkish";
342
            case Constants.CP_MAC_CROATIAN:
368
            case Constants.CP_MAC_CROATIAN:
343
                return "MacCroatian";
369
                return "MacCroatian";
370
            case Constants.CP_US_ACSII:
371
            case Constants.CP_US_ASCII2:
372
                return "US-ASCII";
373
            case Constants.CP_KOI8_R:
374
                return "KOI8-R";
375
            case Constants.CP_ISO_8859_1:
376
                return "ISO-8859-1";
377
            case Constants.CP_ISO_8859_2:
378
                return "ISO-8859-2";
379
            case Constants.CP_ISO_8859_3:
380
                return "ISO-8859-3";
381
            case Constants.CP_ISO_8859_4:
382
                return "ISO-8859-4";
383
            case Constants.CP_ISO_8859_5:
384
                return "ISO-8859-5";
385
            case Constants.CP_ISO_8859_6:
386
                return "ISO-8859-6";
387
            case Constants.CP_ISO_8859_7:
388
                return "ISO-8859-7";
389
            case Constants.CP_ISO_8859_8:
390
                return "ISO-8859-8";
391
            case Constants.CP_ISO_8859_9:
392
                return "ISO-8859-9";
393
            case Constants.CP_ISO_2022_JP1:
394
            case Constants.CP_ISO_2022_JP2:
395
            case Constants.CP_ISO_2022_JP3:
396
                return "ISO-2022-JP";
397
            case Constants.CP_ISO_2022_KR:
398
                return "ISO-2022-KR";
399
            case Constants.CP_EUC_JP:
400
                return "EUC-JP";
401
            case Constants.CP_EUC_KR:
402
                return "EUC-KR";
403
            case Constants.CP_GB2312:
404
                return "GB2312";
405
            case Constants.CP_GB18030:
406
                return "GB18030";
344
            case Constants.CP_SJIS:
407
            case Constants.CP_SJIS:
345
                return "SJIS";
408
                return "SJIS";
346
            default:
409
            default:

Return to bug 39488