author | sherman |
Tue, 18 May 2010 15:36:47 -0700 | |
changeset 5610 | fd2427610c7f |
parent 3943 | 11abf5578222 |
child 5627 | e636ac7a63a4 |
permissions | -rw-r--r-- |
2 | 1 |
/* |
2497 | 2 |
* Copyright 2002-2009 Sun Microsystems, Inc. All Rights Reserved. |
2 | 3 |
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
4 |
* |
|
5 |
* This code is free software; you can redistribute it and/or modify it |
|
6 |
* under the terms of the GNU General Public License version 2 only, as |
|
7 |
* published by the Free Software Foundation. Sun designates this |
|
8 |
* particular file as subject to the "Classpath" exception as provided |
|
9 |
* by Sun in the LICENSE file that accompanied this code. |
|
10 |
* |
|
11 |
* This code is distributed in the hope that it will be useful, but WITHOUT |
|
12 |
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or |
|
13 |
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License |
|
14 |
* version 2 for more details (a copy is included in the LICENSE file that |
|
15 |
* accompanied this code). |
|
16 |
* |
|
17 |
* You should have received a copy of the GNU General Public License version |
|
18 |
* 2 along with this work; if not, write to the Free Software Foundation, |
|
19 |
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. |
|
20 |
* |
|
21 |
* Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, |
|
22 |
* CA 95054 USA or visit www.sun.com if you need additional information or |
|
23 |
* have any questions. |
|
24 |
*/ |
|
25 |
||
26 |
package java.lang; |
|
5610
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
27 |
import java.util.Arrays; |
2 | 28 |
import java.util.Map; |
29 |
import java.util.HashMap; |
|
30 |
import java.util.Locale; |
|
31 |
||
32 |
/** |
|
33 |
* The <code>Character</code> class wraps a value of the primitive |
|
34 |
* type <code>char</code> in an object. An object of type |
|
35 |
* <code>Character</code> contains a single field whose type is |
|
36 |
* <code>char</code>. |
|
37 |
* <p> |
|
38 |
* In addition, this class provides several methods for determining |
|
39 |
* a character's category (lowercase letter, digit, etc.) and for converting |
|
40 |
* characters from uppercase to lowercase and vice versa. |
|
41 |
* <p> |
|
3501
a3168c7b4011
6866243: Javadoc for java.lang.Character still refers to Unicode 4 instead of 5
peytoia
parents:
3224
diff
changeset
|
42 |
* Character information is based on the Unicode Standard, version 5.1.0. |
2 | 43 |
* <p> |
44 |
* The methods and data of class <code>Character</code> are defined by |
|
45 |
* the information in the <i>UnicodeData</i> file that is part of the |
|
46 |
* Unicode Character Database maintained by the Unicode |
|
47 |
* Consortium. This file specifies various properties including name |
|
48 |
* and general category for every defined Unicode code point or |
|
49 |
* character range. |
|
50 |
* <p> |
|
51 |
* The file and its description are available from the Unicode Consortium at: |
|
52 |
* <ul> |
|
53 |
* <li><a href="http://www.unicode.org">http://www.unicode.org</a> |
|
54 |
* </ul> |
|
55 |
* |
|
56 |
* <h4><a name="unicode">Unicode Character Representations</a></h4> |
|
57 |
* |
|
58 |
* <p>The <code>char</code> data type (and therefore the value that a |
|
59 |
* <code>Character</code> object encapsulates) are based on the |
|
60 |
* original Unicode specification, which defined characters as |
|
61 |
* fixed-width 16-bit entities. The Unicode standard has since been |
|
62 |
* changed to allow for characters whose representation requires more |
|
63 |
* than 16 bits. The range of legal <em>code point</em>s is now |
|
64 |
* U+0000 to U+10FFFF, known as <em>Unicode scalar value</em>. |
|
65 |
* (Refer to the <a |
|
66 |
* href="http://www.unicode.org/reports/tr27/#notation"><i> |
|
67 |
* definition</i></a> of the U+<i>n</i> notation in the Unicode |
|
68 |
* standard.) |
|
69 |
* |
|
70 |
* <p>The set of characters from U+0000 to U+FFFF is sometimes |
|
71 |
* referred to as the <em>Basic Multilingual Plane (BMP)</em>. <a |
|
72 |
* name="supplementary">Characters</a> whose code points are greater |
|
73 |
* than U+FFFF are called <em>supplementary character</em>s. The Java |
|
74 |
* 2 platform uses the UTF-16 representation in <code>char</code> |
|
75 |
* arrays and in the <code>String</code> and <code>StringBuffer</code> |
|
76 |
* classes. In this representation, supplementary characters are |
|
77 |
* represented as a pair of <code>char</code> values, the first from |
|
78 |
* the <em>high-surrogates</em> range, (\uD800-\uDBFF), the |
|
79 |
* second from the <em>low-surrogates</em> range |
|
80 |
* (\uDC00-\uDFFF). |
|
81 |
* |
|
82 |
* <p>A <code>char</code> value, therefore, represents Basic |
|
83 |
* Multilingual Plane (BMP) code points, including the surrogate |
|
84 |
* code points, or code units of the UTF-16 encoding. An |
|
85 |
* <code>int</code> value represents all Unicode code points, |
|
86 |
* including supplementary code points. The lower (least significant) |
|
87 |
* 21 bits of <code>int</code> are used to represent Unicode code |
|
88 |
* points and the upper (most significant) 11 bits must be zero. |
|
89 |
* Unless otherwise specified, the behavior with respect to |
|
90 |
* supplementary characters and surrogate <code>char</code> values is |
|
91 |
* as follows: |
|
92 |
* |
|
93 |
* <ul> |
|
94 |
* <li>The methods that only accept a <code>char</code> value cannot support |
|
95 |
* supplementary characters. They treat <code>char</code> values from the |
|
96 |
* surrogate ranges as undefined characters. For example, |
|
97 |
* <code>Character.isLetter('\uD840')</code> returns <code>false</code>, even though |
|
98 |
* this specific value if followed by any low-surrogate value in a string |
|
99 |
* would represent a letter. |
|
100 |
* |
|
101 |
* <li>The methods that accept an <code>int</code> value support all |
|
102 |
* Unicode characters, including supplementary characters. For |
|
103 |
* example, <code>Character.isLetter(0x2F81A)</code> returns |
|
104 |
* <code>true</code> because the code point value represents a letter |
|
105 |
* (a CJK ideograph). |
|
106 |
* </ul> |
|
107 |
* |
|
108 |
* <p>In the Java SE API documentation, <em>Unicode code point</em> is |
|
109 |
* used for character values in the range between U+0000 and U+10FFFF, |
|
110 |
* and <em>Unicode code unit</em> is used for 16-bit |
|
111 |
* <code>char</code> values that are code units of the <em>UTF-16</em> |
|
112 |
* encoding. For more information on Unicode terminology, refer to the |
|
113 |
* <a href="http://www.unicode.org/glossary/">Unicode Glossary</a>. |
|
114 |
* |
|
115 |
* @author Lee Boynton |
|
116 |
* @author Guy Steele |
|
117 |
* @author Akira Tanaka |
|
118 |
* @since 1.0 |
|
119 |
*/ |
|
120 |
public final |
|
121 |
class Character extends Object implements java.io.Serializable, Comparable<Character> { |
|
122 |
/** |
|
123 |
* The minimum radix available for conversion to and from strings. |
|
124 |
* The constant value of this field is the smallest value permitted |
|
125 |
* for the radix argument in radix-conversion methods such as the |
|
126 |
* <code>digit</code> method, the <code>forDigit</code> |
|
127 |
* method, and the <code>toString</code> method of class |
|
128 |
* <code>Integer</code>. |
|
129 |
* |
|
130 |
* @see java.lang.Character#digit(char, int) |
|
131 |
* @see java.lang.Character#forDigit(int, int) |
|
132 |
* @see java.lang.Integer#toString(int, int) |
|
133 |
* @see java.lang.Integer#valueOf(java.lang.String) |
|
134 |
*/ |
|
135 |
public static final int MIN_RADIX = 2; |
|
136 |
||
137 |
/** |
|
138 |
* The maximum radix available for conversion to and from strings. |
|
139 |
* The constant value of this field is the largest value permitted |
|
140 |
* for the radix argument in radix-conversion methods such as the |
|
141 |
* <code>digit</code> method, the <code>forDigit</code> |
|
142 |
* method, and the <code>toString</code> method of class |
|
143 |
* <code>Integer</code>. |
|
144 |
* |
|
145 |
* @see java.lang.Character#digit(char, int) |
|
146 |
* @see java.lang.Character#forDigit(int, int) |
|
147 |
* @see java.lang.Integer#toString(int, int) |
|
148 |
* @see java.lang.Integer#valueOf(java.lang.String) |
|
149 |
*/ |
|
150 |
public static final int MAX_RADIX = 36; |
|
151 |
||
152 |
/** |
|
153 |
* The constant value of this field is the smallest value of type |
|
154 |
* <code>char</code>, <code>'\u0000'</code>. |
|
155 |
* |
|
156 |
* @since 1.0.2 |
|
157 |
*/ |
|
158 |
public static final char MIN_VALUE = '\u0000'; |
|
159 |
||
160 |
/** |
|
161 |
* The constant value of this field is the largest value of type |
|
162 |
* <code>char</code>, <code>'\uFFFF'</code>. |
|
163 |
* |
|
164 |
* @since 1.0.2 |
|
165 |
*/ |
|
3714 | 166 |
public static final char MAX_VALUE = '\uFFFF'; |
2 | 167 |
|
168 |
/** |
|
169 |
* The <code>Class</code> instance representing the primitive type |
|
170 |
* <code>char</code>. |
|
171 |
* |
|
172 |
* @since 1.1 |
|
173 |
*/ |
|
174 |
public static final Class<Character> TYPE = Class.getPrimitiveClass("char"); |
|
175 |
||
176 |
/* |
|
177 |
* Normative general types |
|
178 |
*/ |
|
179 |
||
180 |
/* |
|
181 |
* General character types |
|
182 |
*/ |
|
183 |
||
184 |
/** |
|
185 |
* General category "Cn" in the Unicode specification. |
|
186 |
* @since 1.1 |
|
187 |
*/ |
|
188 |
public static final byte |
|
189 |
UNASSIGNED = 0; |
|
190 |
||
191 |
/** |
|
192 |
* General category "Lu" in the Unicode specification. |
|
193 |
* @since 1.1 |
|
194 |
*/ |
|
195 |
public static final byte |
|
196 |
UPPERCASE_LETTER = 1; |
|
197 |
||
198 |
/** |
|
199 |
* General category "Ll" in the Unicode specification. |
|
200 |
* @since 1.1 |
|
201 |
*/ |
|
202 |
public static final byte |
|
203 |
LOWERCASE_LETTER = 2; |
|
204 |
||
205 |
/** |
|
206 |
* General category "Lt" in the Unicode specification. |
|
207 |
* @since 1.1 |
|
208 |
*/ |
|
209 |
public static final byte |
|
210 |
TITLECASE_LETTER = 3; |
|
211 |
||
212 |
/** |
|
213 |
* General category "Lm" in the Unicode specification. |
|
214 |
* @since 1.1 |
|
215 |
*/ |
|
216 |
public static final byte |
|
217 |
MODIFIER_LETTER = 4; |
|
218 |
||
219 |
/** |
|
220 |
* General category "Lo" in the Unicode specification. |
|
221 |
* @since 1.1 |
|
222 |
*/ |
|
223 |
public static final byte |
|
224 |
OTHER_LETTER = 5; |
|
225 |
||
226 |
/** |
|
227 |
* General category "Mn" in the Unicode specification. |
|
228 |
* @since 1.1 |
|
229 |
*/ |
|
230 |
public static final byte |
|
231 |
NON_SPACING_MARK = 6; |
|
232 |
||
233 |
/** |
|
234 |
* General category "Me" in the Unicode specification. |
|
235 |
* @since 1.1 |
|
236 |
*/ |
|
237 |
public static final byte |
|
238 |
ENCLOSING_MARK = 7; |
|
239 |
||
240 |
/** |
|
241 |
* General category "Mc" in the Unicode specification. |
|
242 |
* @since 1.1 |
|
243 |
*/ |
|
244 |
public static final byte |
|
245 |
COMBINING_SPACING_MARK = 8; |
|
246 |
||
247 |
/** |
|
248 |
* General category "Nd" in the Unicode specification. |
|
249 |
* @since 1.1 |
|
250 |
*/ |
|
251 |
public static final byte |
|
252 |
DECIMAL_DIGIT_NUMBER = 9; |
|
253 |
||
254 |
/** |
|
255 |
* General category "Nl" in the Unicode specification. |
|
256 |
* @since 1.1 |
|
257 |
*/ |
|
258 |
public static final byte |
|
259 |
LETTER_NUMBER = 10; |
|
260 |
||
261 |
/** |
|
262 |
* General category "No" in the Unicode specification. |
|
263 |
* @since 1.1 |
|
264 |
*/ |
|
265 |
public static final byte |
|
266 |
OTHER_NUMBER = 11; |
|
267 |
||
268 |
/** |
|
269 |
* General category "Zs" in the Unicode specification. |
|
270 |
* @since 1.1 |
|
271 |
*/ |
|
272 |
public static final byte |
|
273 |
SPACE_SEPARATOR = 12; |
|
274 |
||
275 |
/** |
|
276 |
* General category "Zl" in the Unicode specification. |
|
277 |
* @since 1.1 |
|
278 |
*/ |
|
279 |
public static final byte |
|
280 |
LINE_SEPARATOR = 13; |
|
281 |
||
282 |
/** |
|
283 |
* General category "Zp" in the Unicode specification. |
|
284 |
* @since 1.1 |
|
285 |
*/ |
|
286 |
public static final byte |
|
287 |
PARAGRAPH_SEPARATOR = 14; |
|
288 |
||
289 |
/** |
|
290 |
* General category "Cc" in the Unicode specification. |
|
291 |
* @since 1.1 |
|
292 |
*/ |
|
293 |
public static final byte |
|
294 |
CONTROL = 15; |
|
295 |
||
296 |
/** |
|
297 |
* General category "Cf" in the Unicode specification. |
|
298 |
* @since 1.1 |
|
299 |
*/ |
|
300 |
public static final byte |
|
301 |
FORMAT = 16; |
|
302 |
||
303 |
/** |
|
304 |
* General category "Co" in the Unicode specification. |
|
305 |
* @since 1.1 |
|
306 |
*/ |
|
307 |
public static final byte |
|
308 |
PRIVATE_USE = 18; |
|
309 |
||
310 |
/** |
|
311 |
* General category "Cs" in the Unicode specification. |
|
312 |
* @since 1.1 |
|
313 |
*/ |
|
314 |
public static final byte |
|
315 |
SURROGATE = 19; |
|
316 |
||
317 |
/** |
|
318 |
* General category "Pd" in the Unicode specification. |
|
319 |
* @since 1.1 |
|
320 |
*/ |
|
321 |
public static final byte |
|
322 |
DASH_PUNCTUATION = 20; |
|
323 |
||
324 |
/** |
|
325 |
* General category "Ps" in the Unicode specification. |
|
326 |
* @since 1.1 |
|
327 |
*/ |
|
328 |
public static final byte |
|
329 |
START_PUNCTUATION = 21; |
|
330 |
||
331 |
/** |
|
332 |
* General category "Pe" in the Unicode specification. |
|
333 |
* @since 1.1 |
|
334 |
*/ |
|
335 |
public static final byte |
|
336 |
END_PUNCTUATION = 22; |
|
337 |
||
338 |
/** |
|
339 |
* General category "Pc" in the Unicode specification. |
|
340 |
* @since 1.1 |
|
341 |
*/ |
|
342 |
public static final byte |
|
343 |
CONNECTOR_PUNCTUATION = 23; |
|
344 |
||
345 |
/** |
|
346 |
* General category "Po" in the Unicode specification. |
|
347 |
* @since 1.1 |
|
348 |
*/ |
|
349 |
public static final byte |
|
350 |
OTHER_PUNCTUATION = 24; |
|
351 |
||
352 |
/** |
|
353 |
* General category "Sm" in the Unicode specification. |
|
354 |
* @since 1.1 |
|
355 |
*/ |
|
356 |
public static final byte |
|
357 |
MATH_SYMBOL = 25; |
|
358 |
||
359 |
/** |
|
360 |
* General category "Sc" in the Unicode specification. |
|
361 |
* @since 1.1 |
|
362 |
*/ |
|
363 |
public static final byte |
|
364 |
CURRENCY_SYMBOL = 26; |
|
365 |
||
366 |
/** |
|
367 |
* General category "Sk" in the Unicode specification. |
|
368 |
* @since 1.1 |
|
369 |
*/ |
|
370 |
public static final byte |
|
371 |
MODIFIER_SYMBOL = 27; |
|
372 |
||
373 |
/** |
|
374 |
* General category "So" in the Unicode specification. |
|
375 |
* @since 1.1 |
|
376 |
*/ |
|
377 |
public static final byte |
|
378 |
OTHER_SYMBOL = 28; |
|
379 |
||
380 |
/** |
|
381 |
* General category "Pi" in the Unicode specification. |
|
382 |
* @since 1.4 |
|
383 |
*/ |
|
384 |
public static final byte |
|
385 |
INITIAL_QUOTE_PUNCTUATION = 29; |
|
386 |
||
387 |
/** |
|
388 |
* General category "Pf" in the Unicode specification. |
|
389 |
* @since 1.4 |
|
390 |
*/ |
|
391 |
public static final byte |
|
392 |
FINAL_QUOTE_PUNCTUATION = 30; |
|
393 |
||
394 |
/** |
|
395 |
* Error flag. Use int (code point) to avoid confusion with U+FFFF. |
|
396 |
*/ |
|
397 |
static final int ERROR = 0xFFFFFFFF; |
|
398 |
||
399 |
||
400 |
/** |
|
401 |
* Undefined bidirectional character type. Undefined <code>char</code> |
|
402 |
* values have undefined directionality in the Unicode specification. |
|
403 |
* @since 1.4 |
|
404 |
*/ |
|
405 |
public static final byte DIRECTIONALITY_UNDEFINED = -1; |
|
406 |
||
407 |
/** |
|
408 |
* Strong bidirectional character type "L" in the Unicode specification. |
|
409 |
* @since 1.4 |
|
410 |
*/ |
|
411 |
public static final byte DIRECTIONALITY_LEFT_TO_RIGHT = 0; |
|
412 |
||
413 |
/** |
|
414 |
* Strong bidirectional character type "R" in the Unicode specification. |
|
415 |
* @since 1.4 |
|
416 |
*/ |
|
417 |
public static final byte DIRECTIONALITY_RIGHT_TO_LEFT = 1; |
|
418 |
||
419 |
/** |
|
420 |
* Strong bidirectional character type "AL" in the Unicode specification. |
|
421 |
* @since 1.4 |
|
422 |
*/ |
|
423 |
public static final byte DIRECTIONALITY_RIGHT_TO_LEFT_ARABIC = 2; |
|
424 |
||
425 |
/** |
|
426 |
* Weak bidirectional character type "EN" in the Unicode specification. |
|
427 |
* @since 1.4 |
|
428 |
*/ |
|
429 |
public static final byte DIRECTIONALITY_EUROPEAN_NUMBER = 3; |
|
430 |
||
431 |
/** |
|
432 |
* Weak bidirectional character type "ES" in the Unicode specification. |
|
433 |
* @since 1.4 |
|
434 |
*/ |
|
435 |
public static final byte DIRECTIONALITY_EUROPEAN_NUMBER_SEPARATOR = 4; |
|
436 |
||
437 |
/** |
|
438 |
* Weak bidirectional character type "ET" in the Unicode specification. |
|
439 |
* @since 1.4 |
|
440 |
*/ |
|
441 |
public static final byte DIRECTIONALITY_EUROPEAN_NUMBER_TERMINATOR = 5; |
|
442 |
||
443 |
/** |
|
444 |
* Weak bidirectional character type "AN" in the Unicode specification. |
|
445 |
* @since 1.4 |
|
446 |
*/ |
|
447 |
public static final byte DIRECTIONALITY_ARABIC_NUMBER = 6; |
|
448 |
||
449 |
/** |
|
450 |
* Weak bidirectional character type "CS" in the Unicode specification. |
|
451 |
* @since 1.4 |
|
452 |
*/ |
|
453 |
public static final byte DIRECTIONALITY_COMMON_NUMBER_SEPARATOR = 7; |
|
454 |
||
455 |
/** |
|
456 |
* Weak bidirectional character type "NSM" in the Unicode specification. |
|
457 |
* @since 1.4 |
|
458 |
*/ |
|
459 |
public static final byte DIRECTIONALITY_NONSPACING_MARK = 8; |
|
460 |
||
461 |
/** |
|
462 |
* Weak bidirectional character type "BN" in the Unicode specification. |
|
463 |
* @since 1.4 |
|
464 |
*/ |
|
465 |
public static final byte DIRECTIONALITY_BOUNDARY_NEUTRAL = 9; |
|
466 |
||
467 |
/** |
|
468 |
* Neutral bidirectional character type "B" in the Unicode specification. |
|
469 |
* @since 1.4 |
|
470 |
*/ |
|
471 |
public static final byte DIRECTIONALITY_PARAGRAPH_SEPARATOR = 10; |
|
472 |
||
473 |
/** |
|
474 |
* Neutral bidirectional character type "S" in the Unicode specification. |
|
475 |
* @since 1.4 |
|
476 |
*/ |
|
477 |
public static final byte DIRECTIONALITY_SEGMENT_SEPARATOR = 11; |
|
478 |
||
479 |
/** |
|
480 |
* Neutral bidirectional character type "WS" in the Unicode specification. |
|
481 |
* @since 1.4 |
|
482 |
*/ |
|
483 |
public static final byte DIRECTIONALITY_WHITESPACE = 12; |
|
484 |
||
485 |
/** |
|
486 |
* Neutral bidirectional character type "ON" in the Unicode specification. |
|
487 |
* @since 1.4 |
|
488 |
*/ |
|
489 |
public static final byte DIRECTIONALITY_OTHER_NEUTRALS = 13; |
|
490 |
||
491 |
/** |
|
492 |
* Strong bidirectional character type "LRE" in the Unicode specification. |
|
493 |
* @since 1.4 |
|
494 |
*/ |
|
495 |
public static final byte DIRECTIONALITY_LEFT_TO_RIGHT_EMBEDDING = 14; |
|
496 |
||
497 |
/** |
|
498 |
* Strong bidirectional character type "LRO" in the Unicode specification. |
|
499 |
* @since 1.4 |
|
500 |
*/ |
|
501 |
public static final byte DIRECTIONALITY_LEFT_TO_RIGHT_OVERRIDE = 15; |
|
502 |
||
503 |
/** |
|
504 |
* Strong bidirectional character type "RLE" in the Unicode specification. |
|
505 |
* @since 1.4 |
|
506 |
*/ |
|
507 |
public static final byte DIRECTIONALITY_RIGHT_TO_LEFT_EMBEDDING = 16; |
|
508 |
||
509 |
/** |
|
510 |
* Strong bidirectional character type "RLO" in the Unicode specification. |
|
511 |
* @since 1.4 |
|
512 |
*/ |
|
513 |
public static final byte DIRECTIONALITY_RIGHT_TO_LEFT_OVERRIDE = 17; |
|
514 |
||
515 |
/** |
|
516 |
* Weak bidirectional character type "PDF" in the Unicode specification. |
|
517 |
* @since 1.4 |
|
518 |
*/ |
|
519 |
public static final byte DIRECTIONALITY_POP_DIRECTIONAL_FORMAT = 18; |
|
520 |
||
521 |
/** |
|
3714 | 522 |
* The minimum value of a |
523 |
* <a href="http://www.unicode.org/glossary/#high_surrogate_code_unit"> |
|
524 |
* Unicode high-surrogate code unit</a> |
|
525 |
* in the UTF-16 encoding, constant <code>'\uD800'</code>. |
|
526 |
* A high-surrogate is also known as a <i>leading-surrogate</i>. |
|
2 | 527 |
* |
528 |
* @since 1.5 |
|
529 |
*/ |
|
530 |
public static final char MIN_HIGH_SURROGATE = '\uD800'; |
|
531 |
||
532 |
/** |
|
3714 | 533 |
* The maximum value of a |
534 |
* <a href="http://www.unicode.org/glossary/#high_surrogate_code_unit"> |
|
535 |
* Unicode high-surrogate code unit</a> |
|
536 |
* in the UTF-16 encoding, constant <code>'\uDBFF'</code>. |
|
537 |
* A high-surrogate is also known as a <i>leading-surrogate</i>. |
|
2 | 538 |
* |
539 |
* @since 1.5 |
|
540 |
*/ |
|
541 |
public static final char MAX_HIGH_SURROGATE = '\uDBFF'; |
|
542 |
||
543 |
/** |
|
3714 | 544 |
* The minimum value of a |
545 |
* <a href="http://www.unicode.org/glossary/#low_surrogate_code_unit"> |
|
546 |
* Unicode low-surrogate code unit</a> |
|
547 |
* in the UTF-16 encoding, constant <code>'\uDC00'</code>. |
|
548 |
* A low-surrogate is also known as a <i>trailing-surrogate</i>. |
|
2 | 549 |
* |
550 |
* @since 1.5 |
|
551 |
*/ |
|
552 |
public static final char MIN_LOW_SURROGATE = '\uDC00'; |
|
553 |
||
554 |
/** |
|
3714 | 555 |
* The maximum value of a |
556 |
* <a href="http://www.unicode.org/glossary/#low_surrogate_code_unit"> |
|
557 |
* Unicode low-surrogate code unit</a> |
|
558 |
* in the UTF-16 encoding, constant <code>'\uDFFF'</code>. |
|
559 |
* A low-surrogate is also known as a <i>trailing-surrogate</i>. |
|
2 | 560 |
* |
561 |
* @since 1.5 |
|
562 |
*/ |
|
563 |
public static final char MAX_LOW_SURROGATE = '\uDFFF'; |
|
564 |
||
565 |
/** |
|
3714 | 566 |
* The minimum value of a Unicode surrogate code unit in the |
567 |
* UTF-16 encoding, constant <code>'\uD800'</code>. |
|
2 | 568 |
* |
569 |
* @since 1.5 |
|
570 |
*/ |
|
571 |
public static final char MIN_SURROGATE = MIN_HIGH_SURROGATE; |
|
572 |
||
573 |
/** |
|
3714 | 574 |
* The maximum value of a Unicode surrogate code unit in the |
575 |
* UTF-16 encoding, constant <code>'\uDFFF'</code>. |
|
2 | 576 |
* |
577 |
* @since 1.5 |
|
578 |
*/ |
|
579 |
public static final char MAX_SURROGATE = MAX_LOW_SURROGATE; |
|
580 |
||
581 |
/** |
|
3714 | 582 |
* The minimum value of a |
583 |
* <a href="http://www.unicode.org/glossary/#supplementary_code_point"> |
|
584 |
* Unicode supplementary code point</a>, constant {@code U+10000}. |
|
2 | 585 |
* |
586 |
* @since 1.5 |
|
587 |
*/ |
|
588 |
public static final int MIN_SUPPLEMENTARY_CODE_POINT = 0x010000; |
|
589 |
||
590 |
/** |
|
3714 | 591 |
* The minimum value of a |
592 |
* <a href="http://www.unicode.org/glossary/#code_point"> |
|
593 |
* Unicode code point</a>, constant {@code U+0000}. |
|
2 | 594 |
* |
595 |
* @since 1.5 |
|
596 |
*/ |
|
597 |
public static final int MIN_CODE_POINT = 0x000000; |
|
598 |
||
599 |
/** |
|
3714 | 600 |
* The maximum value of a |
601 |
* <a href="http://www.unicode.org/glossary/#code_point"> |
|
602 |
* Unicode code point</a>, constant {@code U+10FFFF}. |
|
2 | 603 |
* |
604 |
* @since 1.5 |
|
605 |
*/ |
|
3714 | 606 |
public static final int MAX_CODE_POINT = 0X10FFFF; |
2 | 607 |
|
608 |
||
609 |
/** |
|
610 |
* Instances of this class represent particular subsets of the Unicode |
|
611 |
* character set. The only family of subsets defined in the |
|
612 |
* <code>Character</code> class is <code>{@link Character.UnicodeBlock |
|
613 |
* UnicodeBlock}</code>. Other portions of the Java API may define other |
|
614 |
* subsets for their own purposes. |
|
615 |
* |
|
616 |
* @since 1.2 |
|
617 |
*/ |
|
618 |
public static class Subset { |
|
619 |
||
620 |
private String name; |
|
621 |
||
622 |
/** |
|
623 |
* Constructs a new <code>Subset</code> instance. |
|
624 |
* |
|
625 |
* @exception NullPointerException if name is <code>null</code> |
|
626 |
* @param name The name of this subset |
|
627 |
*/ |
|
628 |
protected Subset(String name) { |
|
629 |
if (name == null) { |
|
630 |
throw new NullPointerException("name"); |
|
631 |
} |
|
632 |
this.name = name; |
|
633 |
} |
|
634 |
||
635 |
/** |
|
636 |
* Compares two <code>Subset</code> objects for equality. |
|
637 |
* This method returns <code>true</code> if and only if |
|
638 |
* <code>this</code> and the argument refer to the same |
|
639 |
* object; since this method is <code>final</code>, this |
|
640 |
* guarantee holds for all subclasses. |
|
641 |
*/ |
|
642 |
public final boolean equals(Object obj) { |
|
643 |
return (this == obj); |
|
644 |
} |
|
645 |
||
646 |
/** |
|
647 |
* Returns the standard hash code as defined by the |
|
648 |
* <code>{@link Object#hashCode}</code> method. This method |
|
649 |
* is <code>final</code> in order to ensure that the |
|
650 |
* <code>equals</code> and <code>hashCode</code> methods will |
|
651 |
* be consistent in all subclasses. |
|
652 |
*/ |
|
653 |
public final int hashCode() { |
|
654 |
return super.hashCode(); |
|
655 |
} |
|
656 |
||
657 |
/** |
|
658 |
* Returns the name of this subset. |
|
659 |
*/ |
|
660 |
public final String toString() { |
|
661 |
return name; |
|
662 |
} |
|
663 |
} |
|
664 |
||
665 |
/** |
|
666 |
* A family of character subsets representing the character blocks in the |
|
667 |
* Unicode specification. Character blocks generally define characters |
|
668 |
* used for a specific script or purpose. A character is contained by |
|
669 |
* at most one Unicode block. |
|
670 |
* |
|
671 |
* @since 1.2 |
|
672 |
*/ |
|
673 |
public static final class UnicodeBlock extends Subset { |
|
674 |
||
675 |
private static Map map = new HashMap(); |
|
676 |
||
677 |
/** |
|
678 |
* Create a UnicodeBlock with the given identifier name. |
|
679 |
* This name must be the same as the block identifier. |
|
680 |
*/ |
|
681 |
private UnicodeBlock(String idName) { |
|
682 |
super(idName); |
|
683 |
map.put(idName.toUpperCase(Locale.US), this); |
|
684 |
} |
|
685 |
||
686 |
/** |
|
687 |
* Create a UnicodeBlock with the given identifier name and |
|
688 |
* alias name. |
|
689 |
*/ |
|
690 |
private UnicodeBlock(String idName, String alias) { |
|
691 |
this(idName); |
|
692 |
map.put(alias.toUpperCase(Locale.US), this); |
|
693 |
} |
|
694 |
||
695 |
/** |
|
696 |
* Create a UnicodeBlock with the given identifier name and |
|
697 |
* alias names. |
|
698 |
*/ |
|
699 |
private UnicodeBlock(String idName, String[] aliasName) { |
|
700 |
this(idName); |
|
701 |
if (aliasName != null) { |
|
702 |
for(int x=0; x<aliasName.length; ++x) { |
|
703 |
map.put(aliasName[x].toUpperCase(Locale.US), this); |
|
704 |
} |
|
705 |
} |
|
706 |
} |
|
707 |
||
708 |
/** |
|
709 |
* Constant for the "Basic Latin" Unicode character block. |
|
710 |
* @since 1.2 |
|
711 |
*/ |
|
712 |
public static final UnicodeBlock BASIC_LATIN = |
|
713 |
new UnicodeBlock("BASIC_LATIN", new String[] {"Basic Latin", "BasicLatin" }); |
|
714 |
||
715 |
/** |
|
716 |
* Constant for the "Latin-1 Supplement" Unicode character block. |
|
717 |
* @since 1.2 |
|
718 |
*/ |
|
719 |
public static final UnicodeBlock LATIN_1_SUPPLEMENT = |
|
720 |
new UnicodeBlock("LATIN_1_SUPPLEMENT", new String[]{ "Latin-1 Supplement", "Latin-1Supplement"}); |
|
721 |
||
722 |
/** |
|
723 |
* Constant for the "Latin Extended-A" Unicode character block. |
|
724 |
* @since 1.2 |
|
725 |
*/ |
|
726 |
public static final UnicodeBlock LATIN_EXTENDED_A = |
|
727 |
new UnicodeBlock("LATIN_EXTENDED_A", new String[]{ "Latin Extended-A", "LatinExtended-A"}); |
|
728 |
||
729 |
/** |
|
730 |
* Constant for the "Latin Extended-B" Unicode character block. |
|
731 |
* @since 1.2 |
|
732 |
*/ |
|
733 |
public static final UnicodeBlock LATIN_EXTENDED_B = |
|
734 |
new UnicodeBlock("LATIN_EXTENDED_B", new String[] {"Latin Extended-B", "LatinExtended-B"}); |
|
735 |
||
736 |
/** |
|
737 |
* Constant for the "IPA Extensions" Unicode character block. |
|
738 |
* @since 1.2 |
|
739 |
*/ |
|
740 |
public static final UnicodeBlock IPA_EXTENSIONS = |
|
741 |
new UnicodeBlock("IPA_EXTENSIONS", new String[] {"IPA Extensions", "IPAExtensions"}); |
|
742 |
||
743 |
/** |
|
744 |
* Constant for the "Spacing Modifier Letters" Unicode character block. |
|
745 |
* @since 1.2 |
|
746 |
*/ |
|
747 |
public static final UnicodeBlock SPACING_MODIFIER_LETTERS = |
|
748 |
new UnicodeBlock("SPACING_MODIFIER_LETTERS", new String[] { "Spacing Modifier Letters", |
|
749 |
"SpacingModifierLetters"}); |
|
750 |
||
751 |
/** |
|
752 |
* Constant for the "Combining Diacritical Marks" Unicode character block. |
|
753 |
* @since 1.2 |
|
754 |
*/ |
|
755 |
public static final UnicodeBlock COMBINING_DIACRITICAL_MARKS = |
|
756 |
new UnicodeBlock("COMBINING_DIACRITICAL_MARKS", new String[] {"Combining Diacritical Marks", |
|
757 |
"CombiningDiacriticalMarks" }); |
|
758 |
||
759 |
/** |
|
760 |
* Constant for the "Greek and Coptic" Unicode character block. |
|
761 |
* <p> |
|
762 |
* This block was previously known as the "Greek" block. |
|
763 |
* |
|
764 |
* @since 1.2 |
|
765 |
*/ |
|
766 |
public static final UnicodeBlock GREEK |
|
767 |
= new UnicodeBlock("GREEK", new String[] {"Greek and Coptic", "GreekandCoptic"}); |
|
768 |
||
769 |
/** |
|
770 |
* Constant for the "Cyrillic" Unicode character block. |
|
771 |
* @since 1.2 |
|
772 |
*/ |
|
773 |
public static final UnicodeBlock CYRILLIC = |
|
774 |
new UnicodeBlock("CYRILLIC"); |
|
775 |
||
776 |
/** |
|
777 |
* Constant for the "Armenian" Unicode character block. |
|
778 |
* @since 1.2 |
|
779 |
*/ |
|
780 |
public static final UnicodeBlock ARMENIAN = |
|
781 |
new UnicodeBlock("ARMENIAN"); |
|
782 |
||
783 |
/** |
|
784 |
* Constant for the "Hebrew" Unicode character block. |
|
785 |
* @since 1.2 |
|
786 |
*/ |
|
787 |
public static final UnicodeBlock HEBREW = |
|
788 |
new UnicodeBlock("HEBREW"); |
|
789 |
||
790 |
/** |
|
791 |
* Constant for the "Arabic" Unicode character block. |
|
792 |
* @since 1.2 |
|
793 |
*/ |
|
794 |
public static final UnicodeBlock ARABIC = |
|
795 |
new UnicodeBlock("ARABIC"); |
|
796 |
||
797 |
/** |
|
798 |
* Constant for the "Devanagari" Unicode character block. |
|
799 |
* @since 1.2 |
|
800 |
*/ |
|
801 |
public static final UnicodeBlock DEVANAGARI = |
|
802 |
new UnicodeBlock("DEVANAGARI"); |
|
803 |
||
804 |
/** |
|
805 |
* Constant for the "Bengali" Unicode character block. |
|
806 |
* @since 1.2 |
|
807 |
*/ |
|
808 |
public static final UnicodeBlock BENGALI = |
|
809 |
new UnicodeBlock("BENGALI"); |
|
810 |
||
811 |
/** |
|
812 |
* Constant for the "Gurmukhi" Unicode character block. |
|
813 |
* @since 1.2 |
|
814 |
*/ |
|
815 |
public static final UnicodeBlock GURMUKHI = |
|
816 |
new UnicodeBlock("GURMUKHI"); |
|
817 |
||
818 |
/** |
|
819 |
* Constant for the "Gujarati" Unicode character block. |
|
820 |
* @since 1.2 |
|
821 |
*/ |
|
822 |
public static final UnicodeBlock GUJARATI = |
|
823 |
new UnicodeBlock("GUJARATI"); |
|
824 |
||
825 |
/** |
|
826 |
* Constant for the "Oriya" Unicode character block. |
|
827 |
* @since 1.2 |
|
828 |
*/ |
|
829 |
public static final UnicodeBlock ORIYA = |
|
830 |
new UnicodeBlock("ORIYA"); |
|
831 |
||
832 |
/** |
|
833 |
* Constant for the "Tamil" Unicode character block. |
|
834 |
* @since 1.2 |
|
835 |
*/ |
|
836 |
public static final UnicodeBlock TAMIL = |
|
837 |
new UnicodeBlock("TAMIL"); |
|
838 |
||
839 |
/** |
|
840 |
* Constant for the "Telugu" Unicode character block. |
|
841 |
* @since 1.2 |
|
842 |
*/ |
|
843 |
public static final UnicodeBlock TELUGU = |
|
844 |
new UnicodeBlock("TELUGU"); |
|
845 |
||
846 |
/** |
|
847 |
* Constant for the "Kannada" Unicode character block. |
|
848 |
* @since 1.2 |
|
849 |
*/ |
|
850 |
public static final UnicodeBlock KANNADA = |
|
851 |
new UnicodeBlock("KANNADA"); |
|
852 |
||
853 |
/** |
|
854 |
* Constant for the "Malayalam" Unicode character block. |
|
855 |
* @since 1.2 |
|
856 |
*/ |
|
857 |
public static final UnicodeBlock MALAYALAM = |
|
858 |
new UnicodeBlock("MALAYALAM"); |
|
859 |
||
860 |
/** |
|
861 |
* Constant for the "Thai" Unicode character block. |
|
862 |
* @since 1.2 |
|
863 |
*/ |
|
864 |
public static final UnicodeBlock THAI = |
|
865 |
new UnicodeBlock("THAI"); |
|
866 |
||
867 |
/** |
|
868 |
* Constant for the "Lao" Unicode character block. |
|
869 |
* @since 1.2 |
|
870 |
*/ |
|
871 |
public static final UnicodeBlock LAO = |
|
872 |
new UnicodeBlock("LAO"); |
|
873 |
||
874 |
/** |
|
875 |
* Constant for the "Tibetan" Unicode character block. |
|
876 |
* @since 1.2 |
|
877 |
*/ |
|
878 |
public static final UnicodeBlock TIBETAN = |
|
879 |
new UnicodeBlock("TIBETAN"); |
|
880 |
||
881 |
/** |
|
882 |
* Constant for the "Georgian" Unicode character block. |
|
883 |
* @since 1.2 |
|
884 |
*/ |
|
885 |
public static final UnicodeBlock GEORGIAN = |
|
886 |
new UnicodeBlock("GEORGIAN"); |
|
887 |
||
888 |
/** |
|
889 |
* Constant for the "Hangul Jamo" Unicode character block. |
|
890 |
* @since 1.2 |
|
891 |
*/ |
|
892 |
public static final UnicodeBlock HANGUL_JAMO = |
|
893 |
new UnicodeBlock("HANGUL_JAMO", new String[] {"Hangul Jamo", "HangulJamo"}); |
|
894 |
||
895 |
/** |
|
896 |
* Constant for the "Latin Extended Additional" Unicode character block. |
|
897 |
* @since 1.2 |
|
898 |
*/ |
|
899 |
public static final UnicodeBlock LATIN_EXTENDED_ADDITIONAL = |
|
900 |
new UnicodeBlock("LATIN_EXTENDED_ADDITIONAL", new String[] {"Latin Extended Additional", |
|
901 |
"LatinExtendedAdditional"}); |
|
902 |
||
903 |
/** |
|
904 |
* Constant for the "Greek Extended" Unicode character block. |
|
905 |
* @since 1.2 |
|
906 |
*/ |
|
907 |
public static final UnicodeBlock GREEK_EXTENDED = |
|
908 |
new UnicodeBlock("GREEK_EXTENDED", new String[] {"Greek Extended", "GreekExtended"}); |
|
909 |
||
910 |
/** |
|
911 |
* Constant for the "General Punctuation" Unicode character block. |
|
912 |
* @since 1.2 |
|
913 |
*/ |
|
914 |
public static final UnicodeBlock GENERAL_PUNCTUATION = |
|
915 |
new UnicodeBlock("GENERAL_PUNCTUATION", new String[] {"General Punctuation", "GeneralPunctuation"}); |
|
916 |
||
917 |
/** |
|
918 |
* Constant for the "Superscripts and Subscripts" Unicode character block. |
|
919 |
* @since 1.2 |
|
920 |
*/ |
|
921 |
public static final UnicodeBlock SUPERSCRIPTS_AND_SUBSCRIPTS = |
|
922 |
new UnicodeBlock("SUPERSCRIPTS_AND_SUBSCRIPTS", new String[] {"Superscripts and Subscripts", |
|
923 |
"SuperscriptsandSubscripts" }); |
|
924 |
||
925 |
/** |
|
926 |
* Constant for the "Currency Symbols" Unicode character block. |
|
927 |
* @since 1.2 |
|
928 |
*/ |
|
929 |
public static final UnicodeBlock CURRENCY_SYMBOLS = |
|
930 |
new UnicodeBlock("CURRENCY_SYMBOLS", new String[] { "Currency Symbols", "CurrencySymbols"}); |
|
931 |
||
932 |
/** |
|
933 |
* Constant for the "Combining Diacritical Marks for Symbols" Unicode character block. |
|
934 |
* <p> |
|
935 |
* This block was previously known as "Combining Marks for Symbols". |
|
936 |
* @since 1.2 |
|
937 |
*/ |
|
938 |
public static final UnicodeBlock COMBINING_MARKS_FOR_SYMBOLS = |
|
939 |
new UnicodeBlock("COMBINING_MARKS_FOR_SYMBOLS", new String[] {"Combining Diacritical Marks for Symbols", |
|
2497 | 940 |
"CombiningDiacriticalMarksforSymbols", |
941 |
"Combining Marks for Symbols", |
|
942 |
"CombiningMarksforSymbols" }); |
|
2 | 943 |
|
944 |
/** |
|
945 |
* Constant for the "Letterlike Symbols" Unicode character block. |
|
946 |
* @since 1.2 |
|
947 |
*/ |
|
948 |
public static final UnicodeBlock LETTERLIKE_SYMBOLS = |
|
949 |
new UnicodeBlock("LETTERLIKE_SYMBOLS", new String[] { "Letterlike Symbols", "LetterlikeSymbols"}); |
|
950 |
||
951 |
/** |
|
952 |
* Constant for the "Number Forms" Unicode character block. |
|
953 |
* @since 1.2 |
|
954 |
*/ |
|
955 |
public static final UnicodeBlock NUMBER_FORMS = |
|
956 |
new UnicodeBlock("NUMBER_FORMS", new String[] {"Number Forms", "NumberForms"}); |
|
957 |
||
958 |
/** |
|
959 |
* Constant for the "Arrows" Unicode character block. |
|
960 |
* @since 1.2 |
|
961 |
*/ |
|
962 |
public static final UnicodeBlock ARROWS = |
|
963 |
new UnicodeBlock("ARROWS"); |
|
964 |
||
965 |
/** |
|
966 |
* Constant for the "Mathematical Operators" Unicode character block. |
|
967 |
* @since 1.2 |
|
968 |
*/ |
|
969 |
public static final UnicodeBlock MATHEMATICAL_OPERATORS = |
|
970 |
new UnicodeBlock("MATHEMATICAL_OPERATORS", new String[] {"Mathematical Operators", |
|
971 |
"MathematicalOperators"}); |
|
972 |
||
973 |
/** |
|
974 |
* Constant for the "Miscellaneous Technical" Unicode character block. |
|
975 |
* @since 1.2 |
|
976 |
*/ |
|
977 |
public static final UnicodeBlock MISCELLANEOUS_TECHNICAL = |
|
978 |
new UnicodeBlock("MISCELLANEOUS_TECHNICAL", new String[] {"Miscellaneous Technical", |
|
979 |
"MiscellaneousTechnical"}); |
|
980 |
||
981 |
/** |
|
982 |
* Constant for the "Control Pictures" Unicode character block. |
|
983 |
* @since 1.2 |
|
984 |
*/ |
|
985 |
public static final UnicodeBlock CONTROL_PICTURES = |
|
986 |
new UnicodeBlock("CONTROL_PICTURES", new String[] {"Control Pictures", "ControlPictures"}); |
|
987 |
||
988 |
/** |
|
989 |
* Constant for the "Optical Character Recognition" Unicode character block. |
|
990 |
* @since 1.2 |
|
991 |
*/ |
|
992 |
public static final UnicodeBlock OPTICAL_CHARACTER_RECOGNITION = |
|
993 |
new UnicodeBlock("OPTICAL_CHARACTER_RECOGNITION", new String[] {"Optical Character Recognition", |
|
994 |
"OpticalCharacterRecognition"}); |
|
995 |
||
996 |
/** |
|
997 |
* Constant for the "Enclosed Alphanumerics" Unicode character block. |
|
998 |
* @since 1.2 |
|
999 |
*/ |
|
1000 |
public static final UnicodeBlock ENCLOSED_ALPHANUMERICS = |
|
1001 |
new UnicodeBlock("ENCLOSED_ALPHANUMERICS", new String[] {"Enclosed Alphanumerics", |
|
1002 |
"EnclosedAlphanumerics"}); |
|
1003 |
||
1004 |
/** |
|
1005 |
* Constant for the "Box Drawing" Unicode character block. |
|
1006 |
* @since 1.2 |
|
1007 |
*/ |
|
1008 |
public static final UnicodeBlock BOX_DRAWING = |
|
1009 |
new UnicodeBlock("BOX_DRAWING", new String[] {"Box Drawing", "BoxDrawing"}); |
|
1010 |
||
1011 |
/** |
|
1012 |
* Constant for the "Block Elements" Unicode character block. |
|
1013 |
* @since 1.2 |
|
1014 |
*/ |
|
1015 |
public static final UnicodeBlock BLOCK_ELEMENTS = |
|
1016 |
new UnicodeBlock("BLOCK_ELEMENTS", new String[] {"Block Elements", "BlockElements"}); |
|
1017 |
||
1018 |
/** |
|
1019 |
* Constant for the "Geometric Shapes" Unicode character block. |
|
1020 |
* @since 1.2 |
|
1021 |
*/ |
|
1022 |
public static final UnicodeBlock GEOMETRIC_SHAPES = |
|
1023 |
new UnicodeBlock("GEOMETRIC_SHAPES", new String[] {"Geometric Shapes", "GeometricShapes"}); |
|
1024 |
||
1025 |
/** |
|
1026 |
* Constant for the "Miscellaneous Symbols" Unicode character block. |
|
1027 |
* @since 1.2 |
|
1028 |
*/ |
|
1029 |
public static final UnicodeBlock MISCELLANEOUS_SYMBOLS = |
|
1030 |
new UnicodeBlock("MISCELLANEOUS_SYMBOLS", new String[] {"Miscellaneous Symbols", |
|
1031 |
"MiscellaneousSymbols"}); |
|
1032 |
||
1033 |
/** |
|
1034 |
* Constant for the "Dingbats" Unicode character block. |
|
1035 |
* @since 1.2 |
|
1036 |
*/ |
|
1037 |
public static final UnicodeBlock DINGBATS = |
|
1038 |
new UnicodeBlock("DINGBATS"); |
|
1039 |
||
1040 |
/** |
|
1041 |
* Constant for the "CJK Symbols and Punctuation" Unicode character block. |
|
1042 |
* @since 1.2 |
|
1043 |
*/ |
|
1044 |
public static final UnicodeBlock CJK_SYMBOLS_AND_PUNCTUATION = |
|
1045 |
new UnicodeBlock("CJK_SYMBOLS_AND_PUNCTUATION", new String[] {"CJK Symbols and Punctuation", |
|
1046 |
"CJKSymbolsandPunctuation"}); |
|
1047 |
||
1048 |
/** |
|
1049 |
* Constant for the "Hiragana" Unicode character block. |
|
1050 |
* @since 1.2 |
|
1051 |
*/ |
|
1052 |
public static final UnicodeBlock HIRAGANA = |
|
1053 |
new UnicodeBlock("HIRAGANA"); |
|
1054 |
||
1055 |
/** |
|
1056 |
* Constant for the "Katakana" Unicode character block. |
|
1057 |
* @since 1.2 |
|
1058 |
*/ |
|
1059 |
public static final UnicodeBlock KATAKANA = |
|
1060 |
new UnicodeBlock("KATAKANA"); |
|
1061 |
||
1062 |
/** |
|
1063 |
* Constant for the "Bopomofo" Unicode character block. |
|
1064 |
* @since 1.2 |
|
1065 |
*/ |
|
1066 |
public static final UnicodeBlock BOPOMOFO = |
|
1067 |
new UnicodeBlock("BOPOMOFO"); |
|
1068 |
||
1069 |
/** |
|
1070 |
* Constant for the "Hangul Compatibility Jamo" Unicode character block. |
|
1071 |
* @since 1.2 |
|
1072 |
*/ |
|
1073 |
public static final UnicodeBlock HANGUL_COMPATIBILITY_JAMO = |
|
1074 |
new UnicodeBlock("HANGUL_COMPATIBILITY_JAMO", new String[] {"Hangul Compatibility Jamo", |
|
1075 |
"HangulCompatibilityJamo"}); |
|
1076 |
||
1077 |
/** |
|
1078 |
* Constant for the "Kanbun" Unicode character block. |
|
1079 |
* @since 1.2 |
|
1080 |
*/ |
|
1081 |
public static final UnicodeBlock KANBUN = |
|
1082 |
new UnicodeBlock("KANBUN"); |
|
1083 |
||
1084 |
/** |
|
1085 |
* Constant for the "Enclosed CJK Letters and Months" Unicode character block. |
|
1086 |
* @since 1.2 |
|
1087 |
*/ |
|
1088 |
public static final UnicodeBlock ENCLOSED_CJK_LETTERS_AND_MONTHS = |
|
1089 |
new UnicodeBlock("ENCLOSED_CJK_LETTERS_AND_MONTHS", new String[] {"Enclosed CJK Letters and Months", |
|
1090 |
"EnclosedCJKLettersandMonths"}); |
|
1091 |
||
1092 |
/** |
|
1093 |
* Constant for the "CJK Compatibility" Unicode character block. |
|
1094 |
* @since 1.2 |
|
1095 |
*/ |
|
1096 |
public static final UnicodeBlock CJK_COMPATIBILITY = |
|
1097 |
new UnicodeBlock("CJK_COMPATIBILITY", new String[] {"CJK Compatibility", "CJKCompatibility"}); |
|
1098 |
||
1099 |
/** |
|
1100 |
* Constant for the "CJK Unified Ideographs" Unicode character block. |
|
1101 |
* @since 1.2 |
|
1102 |
*/ |
|
1103 |
public static final UnicodeBlock CJK_UNIFIED_IDEOGRAPHS = |
|
1104 |
new UnicodeBlock("CJK_UNIFIED_IDEOGRAPHS", new String[] {"CJK Unified Ideographs", |
|
1105 |
"CJKUnifiedIdeographs"}); |
|
1106 |
||
1107 |
/** |
|
1108 |
* Constant for the "Hangul Syllables" Unicode character block. |
|
1109 |
* @since 1.2 |
|
1110 |
*/ |
|
1111 |
public static final UnicodeBlock HANGUL_SYLLABLES = |
|
1112 |
new UnicodeBlock("HANGUL_SYLLABLES", new String[] {"Hangul Syllables", "HangulSyllables"}); |
|
1113 |
||
1114 |
/** |
|
1115 |
* Constant for the "Private Use Area" Unicode character block. |
|
1116 |
* @since 1.2 |
|
1117 |
*/ |
|
1118 |
public static final UnicodeBlock PRIVATE_USE_AREA = |
|
1119 |
new UnicodeBlock("PRIVATE_USE_AREA", new String[] {"Private Use Area", "PrivateUseArea"}); |
|
1120 |
||
1121 |
/** |
|
1122 |
* Constant for the "CJK Compatibility Ideographs" Unicode character block. |
|
1123 |
* @since 1.2 |
|
1124 |
*/ |
|
1125 |
public static final UnicodeBlock CJK_COMPATIBILITY_IDEOGRAPHS = |
|
1126 |
new UnicodeBlock("CJK_COMPATIBILITY_IDEOGRAPHS", |
|
1127 |
new String[] {"CJK Compatibility Ideographs", |
|
1128 |
"CJKCompatibilityIdeographs"}); |
|
1129 |
||
1130 |
/** |
|
1131 |
* Constant for the "Alphabetic Presentation Forms" Unicode character block. |
|
1132 |
* @since 1.2 |
|
1133 |
*/ |
|
1134 |
public static final UnicodeBlock ALPHABETIC_PRESENTATION_FORMS = |
|
1135 |
new UnicodeBlock("ALPHABETIC_PRESENTATION_FORMS", new String[] {"Alphabetic Presentation Forms", |
|
1136 |
"AlphabeticPresentationForms"}); |
|
1137 |
||
1138 |
/** |
|
1139 |
* Constant for the "Arabic Presentation Forms-A" Unicode character block. |
|
1140 |
* @since 1.2 |
|
1141 |
*/ |
|
1142 |
public static final UnicodeBlock ARABIC_PRESENTATION_FORMS_A = |
|
1143 |
new UnicodeBlock("ARABIC_PRESENTATION_FORMS_A", new String[] {"Arabic Presentation Forms-A", |
|
1144 |
"ArabicPresentationForms-A"}); |
|
1145 |
||
1146 |
/** |
|
1147 |
* Constant for the "Combining Half Marks" Unicode character block. |
|
1148 |
* @since 1.2 |
|
1149 |
*/ |
|
1150 |
public static final UnicodeBlock COMBINING_HALF_MARKS = |
|
1151 |
new UnicodeBlock("COMBINING_HALF_MARKS", new String[] {"Combining Half Marks", |
|
1152 |
"CombiningHalfMarks"}); |
|
1153 |
||
1154 |
/** |
|
1155 |
* Constant for the "CJK Compatibility Forms" Unicode character block. |
|
1156 |
* @since 1.2 |
|
1157 |
*/ |
|
1158 |
public static final UnicodeBlock CJK_COMPATIBILITY_FORMS = |
|
1159 |
new UnicodeBlock("CJK_COMPATIBILITY_FORMS", new String[] {"CJK Compatibility Forms", |
|
1160 |
"CJKCompatibilityForms"}); |
|
1161 |
||
1162 |
/** |
|
1163 |
* Constant for the "Small Form Variants" Unicode character block. |
|
1164 |
* @since 1.2 |
|
1165 |
*/ |
|
1166 |
public static final UnicodeBlock SMALL_FORM_VARIANTS = |
|
1167 |
new UnicodeBlock("SMALL_FORM_VARIANTS", new String[] {"Small Form Variants", |
|
1168 |
"SmallFormVariants"}); |
|
1169 |
||
1170 |
/** |
|
1171 |
* Constant for the "Arabic Presentation Forms-B" Unicode character block. |
|
1172 |
* @since 1.2 |
|
1173 |
*/ |
|
1174 |
public static final UnicodeBlock ARABIC_PRESENTATION_FORMS_B = |
|
1175 |
new UnicodeBlock("ARABIC_PRESENTATION_FORMS_B", new String[] {"Arabic Presentation Forms-B", |
|
1176 |
"ArabicPresentationForms-B"}); |
|
1177 |
||
1178 |
/** |
|
1179 |
* Constant for the "Halfwidth and Fullwidth Forms" Unicode character block. |
|
1180 |
* @since 1.2 |
|
1181 |
*/ |
|
1182 |
public static final UnicodeBlock HALFWIDTH_AND_FULLWIDTH_FORMS = |
|
1183 |
new UnicodeBlock("HALFWIDTH_AND_FULLWIDTH_FORMS", |
|
1184 |
new String[] {"Halfwidth and Fullwidth Forms", |
|
1185 |
"HalfwidthandFullwidthForms"}); |
|
1186 |
||
1187 |
/** |
|
1188 |
* Constant for the "Specials" Unicode character block. |
|
1189 |
* @since 1.2 |
|
1190 |
*/ |
|
1191 |
public static final UnicodeBlock SPECIALS = |
|
1192 |
new UnicodeBlock("SPECIALS"); |
|
1193 |
||
1194 |
/** |
|
1195 |
* @deprecated As of J2SE 5, use {@link #HIGH_SURROGATES}, |
|
1196 |
* {@link #HIGH_PRIVATE_USE_SURROGATES}, and |
|
1197 |
* {@link #LOW_SURROGATES}. These new constants match |
|
1198 |
* the block definitions of the Unicode Standard. |
|
1199 |
* The {@link #of(char)} and {@link #of(int)} methods |
|
1200 |
* return the new constants, not SURROGATES_AREA. |
|
1201 |
*/ |
|
1202 |
@Deprecated |
|
1203 |
public static final UnicodeBlock SURROGATES_AREA = |
|
1204 |
new UnicodeBlock("SURROGATES_AREA"); |
|
1205 |
||
1206 |
/** |
|
1207 |
* Constant for the "Syriac" Unicode character block. |
|
1208 |
* @since 1.4 |
|
1209 |
*/ |
|
1210 |
public static final UnicodeBlock SYRIAC = |
|
1211 |
new UnicodeBlock("SYRIAC"); |
|
1212 |
||
1213 |
/** |
|
1214 |
* Constant for the "Thaana" Unicode character block. |
|
1215 |
* @since 1.4 |
|
1216 |
*/ |
|
1217 |
public static final UnicodeBlock THAANA = |
|
1218 |
new UnicodeBlock("THAANA"); |
|
1219 |
||
1220 |
/** |
|
1221 |
* Constant for the "Sinhala" Unicode character block. |
|
1222 |
* @since 1.4 |
|
1223 |
*/ |
|
1224 |
public static final UnicodeBlock SINHALA = |
|
1225 |
new UnicodeBlock("SINHALA"); |
|
1226 |
||
1227 |
/** |
|
1228 |
* Constant for the "Myanmar" Unicode character block. |
|
1229 |
* @since 1.4 |
|
1230 |
*/ |
|
1231 |
public static final UnicodeBlock MYANMAR = |
|
1232 |
new UnicodeBlock("MYANMAR"); |
|
1233 |
||
1234 |
/** |
|
1235 |
* Constant for the "Ethiopic" Unicode character block. |
|
1236 |
* @since 1.4 |
|
1237 |
*/ |
|
1238 |
public static final UnicodeBlock ETHIOPIC = |
|
1239 |
new UnicodeBlock("ETHIOPIC"); |
|
1240 |
||
1241 |
/** |
|
1242 |
* Constant for the "Cherokee" Unicode character block. |
|
1243 |
* @since 1.4 |
|
1244 |
*/ |
|
1245 |
public static final UnicodeBlock CHEROKEE = |
|
1246 |
new UnicodeBlock("CHEROKEE"); |
|
1247 |
||
1248 |
/** |
|
1249 |
* Constant for the "Unified Canadian Aboriginal Syllabics" Unicode character block. |
|
1250 |
* @since 1.4 |
|
1251 |
*/ |
|
1252 |
public static final UnicodeBlock UNIFIED_CANADIAN_ABORIGINAL_SYLLABICS = |
|
1253 |
new UnicodeBlock("UNIFIED_CANADIAN_ABORIGINAL_SYLLABICS", |
|
1254 |
new String[] {"Unified Canadian Aboriginal Syllabics", |
|
1255 |
"UnifiedCanadianAboriginalSyllabics"}); |
|
1256 |
||
1257 |
/** |
|
1258 |
* Constant for the "Ogham" Unicode character block. |
|
1259 |
* @since 1.4 |
|
1260 |
*/ |
|
1261 |
public static final UnicodeBlock OGHAM = |
|
1262 |
new UnicodeBlock("OGHAM"); |
|
1263 |
||
1264 |
/** |
|
1265 |
* Constant for the "Runic" Unicode character block. |
|
1266 |
* @since 1.4 |
|
1267 |
*/ |
|
1268 |
public static final UnicodeBlock RUNIC = |
|
1269 |
new UnicodeBlock("RUNIC"); |
|
1270 |
||
1271 |
/** |
|
1272 |
* Constant for the "Khmer" Unicode character block. |
|
1273 |
* @since 1.4 |
|
1274 |
*/ |
|
1275 |
public static final UnicodeBlock KHMER = |
|
1276 |
new UnicodeBlock("KHMER"); |
|
1277 |
||
1278 |
/** |
|
1279 |
* Constant for the "Mongolian" Unicode character block. |
|
1280 |
* @since 1.4 |
|
1281 |
*/ |
|
1282 |
public static final UnicodeBlock MONGOLIAN = |
|
1283 |
new UnicodeBlock("MONGOLIAN"); |
|
1284 |
||
1285 |
/** |
|
1286 |
* Constant for the "Braille Patterns" Unicode character block. |
|
1287 |
* @since 1.4 |
|
1288 |
*/ |
|
1289 |
public static final UnicodeBlock BRAILLE_PATTERNS = |
|
1290 |
new UnicodeBlock("BRAILLE_PATTERNS", new String[] {"Braille Patterns", |
|
1291 |
"BraillePatterns"}); |
|
1292 |
||
1293 |
/** |
|
1294 |
* Constant for the "CJK Radicals Supplement" Unicode character block. |
|
1295 |
* @since 1.4 |
|
1296 |
*/ |
|
1297 |
public static final UnicodeBlock CJK_RADICALS_SUPPLEMENT = |
|
1298 |
new UnicodeBlock("CJK_RADICALS_SUPPLEMENT", new String[] {"CJK Radicals Supplement", |
|
1299 |
"CJKRadicalsSupplement"}); |
|
1300 |
||
1301 |
/** |
|
1302 |
* Constant for the "Kangxi Radicals" Unicode character block. |
|
1303 |
* @since 1.4 |
|
1304 |
*/ |
|
1305 |
public static final UnicodeBlock KANGXI_RADICALS = |
|
1306 |
new UnicodeBlock("KANGXI_RADICALS", new String[] {"Kangxi Radicals", "KangxiRadicals"}); |
|
1307 |
||
1308 |
/** |
|
1309 |
* Constant for the "Ideographic Description Characters" Unicode character block. |
|
1310 |
* @since 1.4 |
|
1311 |
*/ |
|
1312 |
public static final UnicodeBlock IDEOGRAPHIC_DESCRIPTION_CHARACTERS = |
|
1313 |
new UnicodeBlock("IDEOGRAPHIC_DESCRIPTION_CHARACTERS", new String[] {"Ideographic Description Characters", |
|
1314 |
"IdeographicDescriptionCharacters"}); |
|
1315 |
||
1316 |
/** |
|
1317 |
* Constant for the "Bopomofo Extended" Unicode character block. |
|
1318 |
* @since 1.4 |
|
1319 |
*/ |
|
1320 |
public static final UnicodeBlock BOPOMOFO_EXTENDED = |
|
1321 |
new UnicodeBlock("BOPOMOFO_EXTENDED", new String[] {"Bopomofo Extended", |
|
1322 |
"BopomofoExtended"}); |
|
1323 |
||
1324 |
/** |
|
1325 |
* Constant for the "CJK Unified Ideographs Extension A" Unicode character block. |
|
1326 |
* @since 1.4 |
|
1327 |
*/ |
|
1328 |
public static final UnicodeBlock CJK_UNIFIED_IDEOGRAPHS_EXTENSION_A = |
|
1329 |
new UnicodeBlock("CJK_UNIFIED_IDEOGRAPHS_EXTENSION_A", new String[] {"CJK Unified Ideographs Extension A", |
|
1330 |
"CJKUnifiedIdeographsExtensionA"}); |
|
1331 |
||
1332 |
/** |
|
1333 |
* Constant for the "Yi Syllables" Unicode character block. |
|
1334 |
* @since 1.4 |
|
1335 |
*/ |
|
1336 |
public static final UnicodeBlock YI_SYLLABLES = |
|
1337 |
new UnicodeBlock("YI_SYLLABLES", new String[] {"Yi Syllables", "YiSyllables"}); |
|
1338 |
||
1339 |
/** |
|
1340 |
* Constant for the "Yi Radicals" Unicode character block. |
|
1341 |
* @since 1.4 |
|
1342 |
*/ |
|
1343 |
public static final UnicodeBlock YI_RADICALS = |
|
1344 |
new UnicodeBlock("YI_RADICALS", new String[] {"Yi Radicals", "YiRadicals"}); |
|
1345 |
||
1346 |
||
1347 |
/** |
|
1348 |
* Constant for the "Cyrillic Supplementary" Unicode character block. |
|
1349 |
* @since 1.5 |
|
1350 |
*/ |
|
1351 |
public static final UnicodeBlock CYRILLIC_SUPPLEMENTARY = |
|
2497 | 1352 |
new UnicodeBlock("CYRILLIC_SUPPLEMENTARY", |
1353 |
new String[] {"Cyrillic Supplementary", |
|
1354 |
"CyrillicSupplementary", |
|
1355 |
"Cyrillic Supplement", |
|
1356 |
"CyrillicSupplement"}); |
|
2 | 1357 |
|
1358 |
/** |
|
1359 |
* Constant for the "Tagalog" Unicode character block. |
|
1360 |
* @since 1.5 |
|
1361 |
*/ |
|
1362 |
public static final UnicodeBlock TAGALOG = |
|
1363 |
new UnicodeBlock("TAGALOG"); |
|
1364 |
||
1365 |
/** |
|
1366 |
* Constant for the "Hanunoo" Unicode character block. |
|
1367 |
* @since 1.5 |
|
1368 |
*/ |
|
1369 |
public static final UnicodeBlock HANUNOO = |
|
1370 |
new UnicodeBlock("HANUNOO"); |
|
1371 |
||
1372 |
/** |
|
1373 |
* Constant for the "Buhid" Unicode character block. |
|
1374 |
* @since 1.5 |
|
1375 |
*/ |
|
1376 |
public static final UnicodeBlock BUHID = |
|
1377 |
new UnicodeBlock("BUHID"); |
|
1378 |
||
1379 |
/** |
|
1380 |
* Constant for the "Tagbanwa" Unicode character block. |
|
1381 |
* @since 1.5 |
|
1382 |
*/ |
|
1383 |
public static final UnicodeBlock TAGBANWA = |
|
1384 |
new UnicodeBlock("TAGBANWA"); |
|
1385 |
||
1386 |
/** |
|
1387 |
* Constant for the "Limbu" Unicode character block. |
|
1388 |
* @since 1.5 |
|
1389 |
*/ |
|
1390 |
public static final UnicodeBlock LIMBU = |
|
1391 |
new UnicodeBlock("LIMBU"); |
|
1392 |
||
1393 |
/** |
|
1394 |
* Constant for the "Tai Le" Unicode character block. |
|
1395 |
* @since 1.5 |
|
1396 |
*/ |
|
1397 |
public static final UnicodeBlock TAI_LE = |
|
1398 |
new UnicodeBlock("TAI_LE", new String[] {"Tai Le", "TaiLe"}); |
|
1399 |
||
1400 |
/** |
|
1401 |
* Constant for the "Khmer Symbols" Unicode character block. |
|
1402 |
* @since 1.5 |
|
1403 |
*/ |
|
1404 |
public static final UnicodeBlock KHMER_SYMBOLS = |
|
1405 |
new UnicodeBlock("KHMER_SYMBOLS", new String[] {"Khmer Symbols", "KhmerSymbols"}); |
|
1406 |
||
1407 |
/** |
|
1408 |
* Constant for the "Phonetic Extensions" Unicode character block. |
|
1409 |
* @since 1.5 |
|
1410 |
*/ |
|
1411 |
public static final UnicodeBlock PHONETIC_EXTENSIONS = |
|
1412 |
new UnicodeBlock("PHONETIC_EXTENSIONS", new String[] {"Phonetic Extensions", "PhoneticExtensions"}); |
|
1413 |
||
1414 |
/** |
|
1415 |
* Constant for the "Miscellaneous Mathematical Symbols-A" Unicode character block. |
|
1416 |
* @since 1.5 |
|
1417 |
*/ |
|
1418 |
public static final UnicodeBlock MISCELLANEOUS_MATHEMATICAL_SYMBOLS_A = |
|
1419 |
new UnicodeBlock("MISCELLANEOUS_MATHEMATICAL_SYMBOLS_A", |
|
1420 |
new String[]{"Miscellaneous Mathematical Symbols-A", |
|
1421 |
"MiscellaneousMathematicalSymbols-A"}); |
|
1422 |
||
1423 |
/** |
|
1424 |
* Constant for the "Supplemental Arrows-A" Unicode character block. |
|
1425 |
* @since 1.5 |
|
1426 |
*/ |
|
1427 |
public static final UnicodeBlock SUPPLEMENTAL_ARROWS_A = |
|
1428 |
new UnicodeBlock("SUPPLEMENTAL_ARROWS_A", new String[] {"Supplemental Arrows-A", |
|
1429 |
"SupplementalArrows-A"}); |
|
1430 |
||
1431 |
/** |
|
1432 |
* Constant for the "Supplemental Arrows-B" Unicode character block. |
|
1433 |
* @since 1.5 |
|
1434 |
*/ |
|
1435 |
public static final UnicodeBlock SUPPLEMENTAL_ARROWS_B = |
|
1436 |
new UnicodeBlock("SUPPLEMENTAL_ARROWS_B", new String[] {"Supplemental Arrows-B", |
|
1437 |
"SupplementalArrows-B"}); |
|
1438 |
||
1439 |
/** |
|
1440 |
* Constant for the "Miscellaneous Mathematical Symbols-B" Unicode character block. |
|
1441 |
* @since 1.5 |
|
1442 |
*/ |
|
1443 |
public static final UnicodeBlock MISCELLANEOUS_MATHEMATICAL_SYMBOLS_B |
|
1444 |
= new UnicodeBlock("MISCELLANEOUS_MATHEMATICAL_SYMBOLS_B", |
|
1445 |
new String[] {"Miscellaneous Mathematical Symbols-B", |
|
1446 |
"MiscellaneousMathematicalSymbols-B"}); |
|
1447 |
||
1448 |
/** |
|
1449 |
* Constant for the "Supplemental Mathematical Operators" Unicode character block. |
|
1450 |
* @since 1.5 |
|
1451 |
*/ |
|
1452 |
public static final UnicodeBlock SUPPLEMENTAL_MATHEMATICAL_OPERATORS = |
|
1453 |
new UnicodeBlock("SUPPLEMENTAL_MATHEMATICAL_OPERATORS", |
|
1454 |
new String[]{"Supplemental Mathematical Operators", |
|
1455 |
"SupplementalMathematicalOperators"} ); |
|
1456 |
||
1457 |
/** |
|
1458 |
* Constant for the "Miscellaneous Symbols and Arrows" Unicode character block. |
|
1459 |
* @since 1.5 |
|
1460 |
*/ |
|
1461 |
public static final UnicodeBlock MISCELLANEOUS_SYMBOLS_AND_ARROWS = |
|
1462 |
new UnicodeBlock("MISCELLANEOUS_SYMBOLS_AND_ARROWS", new String[] {"Miscellaneous Symbols and Arrows", |
|
1463 |
"MiscellaneousSymbolsandArrows"}); |
|
1464 |
||
1465 |
/** |
|
1466 |
* Constant for the "Katakana Phonetic Extensions" Unicode character block. |
|
1467 |
* @since 1.5 |
|
1468 |
*/ |
|
1469 |
public static final UnicodeBlock KATAKANA_PHONETIC_EXTENSIONS = |
|
1470 |
new UnicodeBlock("KATAKANA_PHONETIC_EXTENSIONS", new String[] {"Katakana Phonetic Extensions", |
|
1471 |
"KatakanaPhoneticExtensions"}); |
|
1472 |
||
1473 |
/** |
|
1474 |
* Constant for the "Yijing Hexagram Symbols" Unicode character block. |
|
1475 |
* @since 1.5 |
|
1476 |
*/ |
|
1477 |
public static final UnicodeBlock YIJING_HEXAGRAM_SYMBOLS = |
|
1478 |
new UnicodeBlock("YIJING_HEXAGRAM_SYMBOLS", new String[] {"Yijing Hexagram Symbols", |
|
1479 |
"YijingHexagramSymbols"}); |
|
1480 |
||
1481 |
/** |
|
1482 |
* Constant for the "Variation Selectors" Unicode character block. |
|
1483 |
* @since 1.5 |
|
1484 |
*/ |
|
1485 |
public static final UnicodeBlock VARIATION_SELECTORS = |
|
1486 |
new UnicodeBlock("VARIATION_SELECTORS", new String[] {"Variation Selectors", "VariationSelectors"}); |
|
1487 |
||
1488 |
/** |
|
1489 |
* Constant for the "Linear B Syllabary" Unicode character block. |
|
1490 |
* @since 1.5 |
|
1491 |
*/ |
|
1492 |
public static final UnicodeBlock LINEAR_B_SYLLABARY = |
|
1493 |
new UnicodeBlock("LINEAR_B_SYLLABARY", new String[] {"Linear B Syllabary", "LinearBSyllabary"}); |
|
1494 |
||
1495 |
/** |
|
1496 |
* Constant for the "Linear B Ideograms" Unicode character block. |
|
1497 |
* @since 1.5 |
|
1498 |
*/ |
|
1499 |
public static final UnicodeBlock LINEAR_B_IDEOGRAMS = |
|
1500 |
new UnicodeBlock("LINEAR_B_IDEOGRAMS", new String[] {"Linear B Ideograms", "LinearBIdeograms"}); |
|
1501 |
||
1502 |
/** |
|
1503 |
* Constant for the "Aegean Numbers" Unicode character block. |
|
1504 |
* @since 1.5 |
|
1505 |
*/ |
|
1506 |
public static final UnicodeBlock AEGEAN_NUMBERS = |
|
1507 |
new UnicodeBlock("AEGEAN_NUMBERS", new String[] {"Aegean Numbers", "AegeanNumbers"}); |
|
1508 |
||
1509 |
/** |
|
1510 |
* Constant for the "Old Italic" Unicode character block. |
|
1511 |
* @since 1.5 |
|
1512 |
*/ |
|
1513 |
public static final UnicodeBlock OLD_ITALIC = |
|
1514 |
new UnicodeBlock("OLD_ITALIC", new String[] {"Old Italic", "OldItalic"}); |
|
1515 |
||
1516 |
/** |
|
1517 |
* Constant for the "Gothic" Unicode character block. |
|
1518 |
* @since 1.5 |
|
1519 |
*/ |
|
1520 |
public static final UnicodeBlock GOTHIC = new UnicodeBlock("GOTHIC"); |
|
1521 |
||
1522 |
/** |
|
1523 |
* Constant for the "Ugaritic" Unicode character block. |
|
1524 |
* @since 1.5 |
|
1525 |
*/ |
|
1526 |
public static final UnicodeBlock UGARITIC = new UnicodeBlock("UGARITIC"); |
|
1527 |
||
1528 |
/** |
|
1529 |
* Constant for the "Deseret" Unicode character block. |
|
1530 |
* @since 1.5 |
|
1531 |
*/ |
|
1532 |
public static final UnicodeBlock DESERET = new UnicodeBlock("DESERET"); |
|
1533 |
||
1534 |
/** |
|
1535 |
* Constant for the "Shavian" Unicode character block. |
|
1536 |
* @since 1.5 |
|
1537 |
*/ |
|
1538 |
public static final UnicodeBlock SHAVIAN = new UnicodeBlock("SHAVIAN"); |
|
1539 |
||
1540 |
/** |
|
1541 |
* Constant for the "Osmanya" Unicode character block. |
|
1542 |
* @since 1.5 |
|
1543 |
*/ |
|
1544 |
public static final UnicodeBlock OSMANYA = new UnicodeBlock("OSMANYA"); |
|
1545 |
||
1546 |
/** |
|
1547 |
* Constant for the "Cypriot Syllabary" Unicode character block. |
|
1548 |
* @since 1.5 |
|
1549 |
*/ |
|
1550 |
public static final UnicodeBlock CYPRIOT_SYLLABARY = |
|
1551 |
new UnicodeBlock("CYPRIOT_SYLLABARY", new String[] {"Cypriot Syllabary", "CypriotSyllabary"}); |
|
1552 |
||
1553 |
/** |
|
1554 |
* Constant for the "Byzantine Musical Symbols" Unicode character block. |
|
1555 |
* @since 1.5 |
|
1556 |
*/ |
|
1557 |
public static final UnicodeBlock BYZANTINE_MUSICAL_SYMBOLS = |
|
1558 |
new UnicodeBlock("BYZANTINE_MUSICAL_SYMBOLS", new String[] {"Byzantine Musical Symbols", |
|
1559 |
"ByzantineMusicalSymbols"}); |
|
1560 |
||
1561 |
/** |
|
1562 |
* Constant for the "Musical Symbols" Unicode character block. |
|
1563 |
* @since 1.5 |
|
1564 |
*/ |
|
1565 |
public static final UnicodeBlock MUSICAL_SYMBOLS = |
|
1566 |
new UnicodeBlock("MUSICAL_SYMBOLS", new String[] {"Musical Symbols", "MusicalSymbols"}); |
|
1567 |
||
1568 |
/** |
|
1569 |
* Constant for the "Tai Xuan Jing Symbols" Unicode character block. |
|
1570 |
* @since 1.5 |
|
1571 |
*/ |
|
1572 |
public static final UnicodeBlock TAI_XUAN_JING_SYMBOLS = |
|
1573 |
new UnicodeBlock("TAI_XUAN_JING_SYMBOLS", new String[] {"Tai Xuan Jing Symbols", |
|
1574 |
"TaiXuanJingSymbols"}); |
|
1575 |
||
1576 |
/** |
|
1577 |
* Constant for the "Mathematical Alphanumeric Symbols" Unicode character block. |
|
1578 |
* @since 1.5 |
|
1579 |
*/ |
|
1580 |
public static final UnicodeBlock MATHEMATICAL_ALPHANUMERIC_SYMBOLS = |
|
1581 |
new UnicodeBlock("MATHEMATICAL_ALPHANUMERIC_SYMBOLS", |
|
1582 |
new String[] {"Mathematical Alphanumeric Symbols", "MathematicalAlphanumericSymbols"}); |
|
1583 |
||
1584 |
/** |
|
1585 |
* Constant for the "CJK Unified Ideographs Extension B" Unicode character block. |
|
1586 |
* @since 1.5 |
|
1587 |
*/ |
|
1588 |
public static final UnicodeBlock CJK_UNIFIED_IDEOGRAPHS_EXTENSION_B = |
|
1589 |
new UnicodeBlock("CJK_UNIFIED_IDEOGRAPHS_EXTENSION_B", |
|
1590 |
new String[] {"CJK Unified Ideographs Extension B", "CJKUnifiedIdeographsExtensionB"}); |
|
1591 |
||
1592 |
/** |
|
1593 |
* Constant for the "CJK Compatibility Ideographs Supplement" Unicode character block. |
|
1594 |
* @since 1.5 |
|
1595 |
*/ |
|
1596 |
public static final UnicodeBlock CJK_COMPATIBILITY_IDEOGRAPHS_SUPPLEMENT = |
|
1597 |
new UnicodeBlock("CJK_COMPATIBILITY_IDEOGRAPHS_SUPPLEMENT", |
|
1598 |
new String[]{"CJK Compatibility Ideographs Supplement", |
|
1599 |
"CJKCompatibilityIdeographsSupplement"}); |
|
1600 |
||
1601 |
/** |
|
1602 |
* Constant for the "Tags" Unicode character block. |
|
1603 |
* @since 1.5 |
|
1604 |
*/ |
|
1605 |
public static final UnicodeBlock TAGS = new UnicodeBlock("TAGS"); |
|
1606 |
||
1607 |
/** |
|
1608 |
* Constant for the "Variation Selectors Supplement" Unicode character block. |
|
1609 |
* @since 1.5 |
|
1610 |
*/ |
|
1611 |
public static final UnicodeBlock VARIATION_SELECTORS_SUPPLEMENT = |
|
1612 |
new UnicodeBlock("VARIATION_SELECTORS_SUPPLEMENT", new String[] {"Variation Selectors Supplement", |
|
1613 |
"VariationSelectorsSupplement"}); |
|
1614 |
||
1615 |
/** |
|
1616 |
* Constant for the "Supplementary Private Use Area-A" Unicode character block. |
|
1617 |
* @since 1.5 |
|
1618 |
*/ |
|
1619 |
public static final UnicodeBlock SUPPLEMENTARY_PRIVATE_USE_AREA_A = |
|
1620 |
new UnicodeBlock("SUPPLEMENTARY_PRIVATE_USE_AREA_A", |
|
1621 |
new String[] {"Supplementary Private Use Area-A", |
|
1622 |
"SupplementaryPrivateUseArea-A"}); |
|
1623 |
||
1624 |
/** |
|
1625 |
* Constant for the "Supplementary Private Use Area-B" Unicode character block. |
|
1626 |
* @since 1.5 |
|
1627 |
*/ |
|
1628 |
public static final UnicodeBlock SUPPLEMENTARY_PRIVATE_USE_AREA_B = |
|
1629 |
new UnicodeBlock("SUPPLEMENTARY_PRIVATE_USE_AREA_B", |
|
1630 |
new String[] {"Supplementary Private Use Area-B", |
|
1631 |
"SupplementaryPrivateUseArea-B"}); |
|
1632 |
||
1633 |
/** |
|
1634 |
* Constant for the "High Surrogates" Unicode character block. |
|
1635 |
* This block represents codepoint values in the high surrogate |
|
1636 |
* range: 0xD800 through 0xDB7F |
|
1637 |
* |
|
1638 |
* @since 1.5 |
|
1639 |
*/ |
|
1640 |
public static final UnicodeBlock HIGH_SURROGATES = |
|
1641 |
new UnicodeBlock("HIGH_SURROGATES", new String[] {"High Surrogates", "HighSurrogates"}); |
|
1642 |
||
1643 |
/** |
|
1644 |
* Constant for the "High Private Use Surrogates" Unicode character block. |
|
1645 |
* This block represents codepoint values in the high surrogate |
|
1646 |
* range: 0xDB80 through 0xDBFF |
|
1647 |
* |
|
1648 |
* @since 1.5 |
|
1649 |
*/ |
|
1650 |
public static final UnicodeBlock HIGH_PRIVATE_USE_SURROGATES = |
|
1651 |
new UnicodeBlock("HIGH_PRIVATE_USE_SURROGATES", new String[] { "High Private Use Surrogates", |
|
1652 |
"HighPrivateUseSurrogates"}); |
|
1653 |
||
1654 |
/** |
|
1655 |
* Constant for the "Low Surrogates" Unicode character block. |
|
1656 |
* This block represents codepoint values in the high surrogate |
|
1657 |
* range: 0xDC00 through 0xDFFF |
|
1658 |
* |
|
1659 |
* @since 1.5 |
|
1660 |
*/ |
|
1661 |
public static final UnicodeBlock LOW_SURROGATES = |
|
1662 |
new UnicodeBlock("LOW_SURROGATES", new String[] {"Low Surrogates", "LowSurrogates"}); |
|
1663 |
||
2497 | 1664 |
/** |
1665 |
* Constant for the "Arabic Supplement" Unicode character block. |
|
1666 |
* @since 1.7 |
|
1667 |
*/ |
|
1668 |
public static final UnicodeBlock ARABIC_SUPPLEMENT = |
|
1669 |
new UnicodeBlock("ARABIC_SUPPLEMENT", |
|
1670 |
new String[] { "Arabic Supplement", |
|
1671 |
"ArabicSupplement"}); |
|
1672 |
||
1673 |
/** |
|
1674 |
* Constant for the "NKo" Unicode character block. |
|
1675 |
* @since 1.7 |
|
1676 |
*/ |
|
1677 |
public static final UnicodeBlock NKO = new UnicodeBlock("NKO"); |
|
1678 |
||
1679 |
/** |
|
1680 |
* Constant for the "Ethiopic Supplement" Unicode character block. |
|
1681 |
* @since 1.7 |
|
1682 |
*/ |
|
1683 |
public static final UnicodeBlock ETHIOPIC_SUPPLEMENT = |
|
1684 |
new UnicodeBlock("ETHIOPIC_SUPPLEMENT", |
|
1685 |
new String[] { "Ethiopic Supplement", |
|
1686 |
"EthiopicSupplement"}); |
|
1687 |
||
1688 |
/** |
|
1689 |
* Constant for the "New Tai Lue" Unicode character block. |
|
1690 |
* @since 1.7 |
|
1691 |
*/ |
|
1692 |
public static final UnicodeBlock NEW_TAI_LUE = |
|
1693 |
new UnicodeBlock("NEW_TAI_LUE", |
|
1694 |
new String[] { "New Tai Lue", |
|
1695 |
"NewTaiLue"}); |
|
1696 |
||
1697 |
/** |
|
1698 |
* Constant for the "Buginese" Unicode character block. |
|
1699 |
* @since 1.7 |
|
1700 |
*/ |
|
1701 |
public static final UnicodeBlock BUGINESE = |
|
1702 |
new UnicodeBlock("BUGINESE"); |
|
1703 |
||
1704 |
/** |
|
1705 |
* Constant for the "Balinese" Unicode character block. |
|
1706 |
* @since 1.7 |
|
1707 |
*/ |
|
1708 |
public static final UnicodeBlock BALINESE = |
|
1709 |
new UnicodeBlock("BALINESE"); |
|
1710 |
||
1711 |
/** |
|
1712 |
* Constant for the "Sundanese" Unicode character block. |
|
1713 |
* @since 1.7 |
|
1714 |
*/ |
|
1715 |
public static final UnicodeBlock SUNDANESE = |
|
1716 |
new UnicodeBlock("SUNDANESE"); |
|
1717 |
||
1718 |
/** |
|
1719 |
* Constant for the "Lepcha" Unicode character block. |
|
1720 |
* @since 1.7 |
|
1721 |
*/ |
|
1722 |
public static final UnicodeBlock LEPCHA = new UnicodeBlock("LEPCHA"); |
|
1723 |
||
1724 |
/** |
|
1725 |
* Constant for the "Ol Chiki" Unicode character block. |
|
1726 |
* @since 1.7 |
|
1727 |
*/ |
|
1728 |
public static final UnicodeBlock OL_CHIKI = |
|
1729 |
new UnicodeBlock("OL_CHIKI", |
|
1730 |
new String[] { "Ol Chiki", |
|
1731 |
"OlChiki"}); |
|
1732 |
||
1733 |
/** |
|
1734 |
* Constant for the "Phonetic Extensions Supplement" Unicode character |
|
1735 |
* block. |
|
1736 |
* @since 1.7 |
|
1737 |
*/ |
|
1738 |
public static final UnicodeBlock PHONETIC_EXTENSIONS_SUPPLEMENT = |
|
1739 |
new UnicodeBlock("PHONETIC_EXTENSIONS_SUPPLEMENT", |
|
1740 |
new String[] { "Phonetic Extensions Supplement", |
|
1741 |
"PhoneticExtensionsSupplement"}); |
|
1742 |
||
1743 |
/** |
|
1744 |
* Constant for the "Combining Diacritical Marks Supplement" Unicode |
|
1745 |
* character block. |
|
1746 |
* @since 1.7 |
|
1747 |
*/ |
|
1748 |
public static final UnicodeBlock COMBINING_DIACRITICAL_MARKS_SUPPLEMENT = |
|
1749 |
new UnicodeBlock("COMBINING_DIACRITICAL_MARKS_SUPPLEMENT", |
|
1750 |
new String[] { "Combining Diacritical Marks Supplement", |
|
1751 |
"CombiningDiacriticalMarksSupplement"}); |
|
1752 |
||
1753 |
/** |
|
1754 |
* Constant for the "Glagolitic" Unicode character block. |
|
1755 |
* @since 1.7 |
|
1756 |
*/ |
|
1757 |
public static final UnicodeBlock GLAGOLITIC = |
|
1758 |
new UnicodeBlock("GLAGOLITIC"); |
|
1759 |
||
1760 |
/** |
|
1761 |
* Constant for the "Latin Extended-C" Unicode character block. |
|
1762 |
* @since 1.7 |
|
1763 |
*/ |
|
1764 |
public static final UnicodeBlock LATIN_EXTENDED_C = |
|
1765 |
new UnicodeBlock("LATIN_EXTENDED_C", |
|
1766 |
new String[] { "Latin Extended-C", |
|
1767 |
"LatinExtended-C"}); |
|
1768 |
||
1769 |
/** |
|
1770 |
* Constant for the "Coptic" Unicode character block. |
|
1771 |
* @since 1.7 |
|
1772 |
*/ |
|
1773 |
public static final UnicodeBlock COPTIC = new UnicodeBlock("COPTIC"); |
|
1774 |
||
1775 |
/** |
|
1776 |
* Constant for the "Georgian Supplement" Unicode character block. |
|
1777 |
* @since 1.7 |
|
1778 |
*/ |
|
1779 |
public static final UnicodeBlock GEORGIAN_SUPPLEMENT = |
|
1780 |
new UnicodeBlock("GEORGIAN_SUPPLEMENT", |
|
1781 |
new String[] { "Georgian Supplement", |
|
1782 |
"GeorgianSupplement"}); |
|
1783 |
||
1784 |
/** |
|
1785 |
* Constant for the "Tifinagh" Unicode character block. |
|
1786 |
* @since 1.7 |
|
1787 |
*/ |
|
1788 |
public static final UnicodeBlock TIFINAGH = |
|
1789 |
new UnicodeBlock("TIFINAGH"); |
|
1790 |
||
1791 |
/** |
|
1792 |
* Constant for the "Ethiopic Extended" Unicode character block. |
|
1793 |
* @since 1.7 |
|
1794 |
*/ |
|
1795 |
public static final UnicodeBlock ETHIOPIC_EXTENDED = |
|
1796 |
new UnicodeBlock("ETHIOPIC_EXTENDED", |
|
1797 |
new String[] { "Ethiopic Extended", |
|
1798 |
"EthiopicExtended"}); |
|
1799 |
||
1800 |
/** |
|
1801 |
* Constant for the "Cyrillic Extended-A" Unicode character block. |
|
1802 |
* @since 1.7 |
|
1803 |
*/ |
|
1804 |
public static final UnicodeBlock CYRILLIC_EXTENDED_A = |
|
1805 |
new UnicodeBlock("CYRILLIC_EXTENDED_A", |
|
1806 |
new String[] { "Cyrillic Extended-A", |
|
1807 |
"CyrillicExtended-A"}); |
|
1808 |
||
1809 |
/** |
|
1810 |
* Constant for the "Supplemental Punctuation" Unicode character block. |
|
1811 |
* @since 1.7 |
|
1812 |
*/ |
|
1813 |
public static final UnicodeBlock SUPPLEMENTAL_PUNCTUATION = |
|
1814 |
new UnicodeBlock("SUPPLEMENTAL_PUNCTUATION", |
|
1815 |
new String[] { "Supplemental Punctuation", |
|
1816 |
"SupplementalPunctuation"}); |
|
1817 |
||
1818 |
/** |
|
1819 |
* Constant for the "CJK Strokes" Unicode character block. |
|
1820 |
* @since 1.7 |
|
1821 |
*/ |
|
1822 |
public static final UnicodeBlock CJK_STROKES = |
|
1823 |
new UnicodeBlock("CJK_STROKES", |
|
1824 |
new String[] { "CJK Strokes", |
|
1825 |
"CJKStrokes"}); |
|
1826 |
||
1827 |
/** |
|
1828 |
* Constant for the "Vai" Unicode character block. |
|
1829 |
* @since 1.7 |
|
1830 |
*/ |
|
1831 |
public static final UnicodeBlock VAI = new UnicodeBlock("VAI"); |
|
1832 |
||
1833 |
/** |
|
1834 |
* Constant for the "Cyrillic Extended-B" Unicode character block. |
|
1835 |
* @since 1.7 |
|
1836 |
*/ |
|
1837 |
public static final UnicodeBlock CYRILLIC_EXTENDED_B = |
|
1838 |
new UnicodeBlock("CYRILLIC_EXTENDED_B", |
|
1839 |
new String[] { "Cyrillic Extended-B", |
|
1840 |
"CyrillicExtended-B"}); |
|
1841 |
||
1842 |
/** |
|
1843 |
* Constant for the "Modifier Tone Letters" Unicode character block. |
|
1844 |
* @since 1.7 |
|
1845 |
*/ |
|
1846 |
public static final UnicodeBlock MODIFIER_TONE_LETTERS = |
|
1847 |
new UnicodeBlock("MODIFIER_TONE_LETTERS", |
|
1848 |
new String[] { "Modifier Tone Letters", |
|
1849 |
"ModifierToneLetters"}); |
|
1850 |
||
1851 |
/** |
|
1852 |
* Constant for the "Latin Extended-D" Unicode character block. |
|
1853 |
* @since 1.7 |
|
1854 |
*/ |
|
1855 |
public static final UnicodeBlock LATIN_EXTENDED_D = |
|
1856 |
new UnicodeBlock("LATIN_EXTENDED_D", |
|
1857 |
new String[] { "Latin Extended-D", |
|
1858 |
"LatinExtended-D"}); |
|
1859 |
||
1860 |
/** |
|
1861 |
* Constant for the "Syloti Nagri" Unicode character block. |
|
1862 |
* @since 1.7 |
|
1863 |
*/ |
|
1864 |
public static final UnicodeBlock SYLOTI_NAGRI = |
|
1865 |
new UnicodeBlock("SYLOTI_NAGRI", |
|
1866 |
new String[] { "Syloti Nagri", |
|
1867 |
"SylotiNagri"}); |
|
1868 |
||
1869 |
/** |
|
1870 |
* Constant for the "Phags-pa" Unicode character block. |
|
1871 |
* @since 1.7 |
|
1872 |
*/ |
|
1873 |
public static final UnicodeBlock PHAGS_PA = |
|
1874 |
new UnicodeBlock("PHAGS_PA", new String[] { "Phags-pa"}); |
|
1875 |
||
1876 |
/** |
|
1877 |
* Constant for the "Saurashtra" Unicode character block. |
|
1878 |
* @since 1.7 |
|
1879 |
*/ |
|
1880 |
public static final UnicodeBlock SAURASHTRA = |
|
1881 |
new UnicodeBlock("SAURASHTRA"); |
|
1882 |
||
1883 |
/** |
|
1884 |
* Constant for the "Kayah Li" Unicode character block. |
|
1885 |
* @since 1.7 |
|
1886 |
*/ |
|
1887 |
public static final UnicodeBlock KAYAH_LI = |
|
1888 |
new UnicodeBlock("KAYAH_LI", |
|
1889 |
new String[] { "Kayah Li", |
|
1890 |
"KayahLi"}); |
|
1891 |
||
1892 |
/** |
|
1893 |
* Constant for the "Rejang" Unicode character block. |
|
1894 |
* @since 1.7 |
|
1895 |
*/ |
|
1896 |
public static final UnicodeBlock REJANG = new UnicodeBlock("REJANG"); |
|
1897 |
||
1898 |
/** |
|
1899 |
* Constant for the "Cham" Unicode character block. |
|
1900 |
* @since 1.7 |
|
1901 |
*/ |
|
1902 |
public static final UnicodeBlock CHAM = new UnicodeBlock("CHAM"); |
|
1903 |
||
1904 |
/** |
|
1905 |
* Constant for the "Vertical Forms" Unicode character block. |
|
1906 |
* @since 1.7 |
|
1907 |
*/ |
|
1908 |
public static final UnicodeBlock VERTICAL_FORMS = |
|
1909 |
new UnicodeBlock("VERTICAL_FORMS", |
|
1910 |
new String[] { "Vertical Forms", |
|
1911 |
"VerticalForms"}); |
|
1912 |
||
1913 |
/** |
|
1914 |
* Constant for the "Ancient Greek Numbers" Unicode character block. |
|
1915 |
* @since 1.7 |
|
1916 |
*/ |
|
1917 |
public static final UnicodeBlock ANCIENT_GREEK_NUMBERS = |
|
1918 |
new UnicodeBlock("ANCIENT_GREEK_NUMBERS", |
|
1919 |
new String[] { "Ancient Greek Numbers", |
|
1920 |
"AncientGreekNumbers"}); |
|
1921 |
||
1922 |
/** |
|
1923 |
* Constant for the "Ancient Symbols" Unicode character block. |
|
1924 |
* @since 1.7 |
|
1925 |
*/ |
|
1926 |
public static final UnicodeBlock ANCIENT_SYMBOLS = |
|
1927 |
new UnicodeBlock("ANCIENT_SYMBOLS", |
|
1928 |
new String[] { "Ancient Symbols", |
|
1929 |
"AncientSymbols"}); |
|
1930 |
||
1931 |
/** |
|
1932 |
* Constant for the "Phaistos Disc" Unicode character block. |
|
1933 |
* @since 1.7 |
|
1934 |
*/ |
|
1935 |
public static final UnicodeBlock PHAISTOS_DISC = |
|
1936 |
new UnicodeBlock("PHAISTOS_DISC", |
|
1937 |
new String[] { "Phaistos Disc", |
|
1938 |
"PhaistosDisc"}); |
|
1939 |
||
1940 |
/** |
|
1941 |
* Constant for the "Lycian" Unicode character block. |
|
1942 |
* @since 1.7 |
|
1943 |
*/ |
|
1944 |
public static final UnicodeBlock LYCIAN = new UnicodeBlock("LYCIAN"); |
|
1945 |
||
1946 |
/** |
|
1947 |
* Constant for the "Carian" Unicode character block. |
|
1948 |
* @since 1.7 |
|
1949 |
*/ |
|
1950 |
public static final UnicodeBlock CARIAN = new UnicodeBlock("CARIAN"); |
|
1951 |
||
1952 |
/** |
|
1953 |
* Constant for the "Old Persian" Unicode character block. |
|
1954 |
* @since 1.7 |
|
1955 |
*/ |
|
1956 |
public static final UnicodeBlock OLD_PERSIAN = |
|
1957 |
new UnicodeBlock("OLD_PERSIAN", |
|
1958 |
new String[] { "Old Persian", |
|
1959 |
"OldPersian"}); |
|
1960 |
||
1961 |
/** |
|
1962 |
* Constant for the "Phoenician" Unicode character block. |
|
1963 |
* @since 1.7 |
|
1964 |
*/ |
|
1965 |
public static final UnicodeBlock PHOENICIAN = |
|
1966 |
new UnicodeBlock("PHOENICIAN"); |
|
1967 |
||
1968 |
/** |
|
1969 |
* Constant for the "Lydian" Unicode character block. |
|
1970 |
* @since 1.7 |
|
1971 |
*/ |
|
1972 |
public static final UnicodeBlock LYDIAN = new UnicodeBlock("LYDIAN"); |
|
1973 |
||
1974 |
/** |
|
1975 |
* Constant for the "Kharoshthi" Unicode character block. |
|
1976 |
* @since 1.7 |
|
1977 |
*/ |
|
1978 |
public static final UnicodeBlock KHAROSHTHI = |
|
1979 |
new UnicodeBlock("KHAROSHTHI"); |
|
1980 |
||
1981 |
/** |
|
1982 |
* Constant for the "Cuneiform" Unicode character block. |
|
1983 |
* @since 1.7 |
|
1984 |
*/ |
|
1985 |
public static final UnicodeBlock CUNEIFORM = |
|
1986 |
new UnicodeBlock("CUNEIFORM"); |
|
1987 |
||
1988 |
/** |
|
1989 |
* Constant for the "Cuneiform Numbers and Punctuation" Unicode |
|
1990 |
* character block. |
|
1991 |
* @since 1.7 |
|
1992 |
*/ |
|
1993 |
public static final UnicodeBlock CUNEIFORM_NUMBERS_AND_PUNCTUATION = |
|
1994 |
new UnicodeBlock("CUNEIFORM_NUMBERS_AND_PUNCTUATION", |
|
1995 |
new String[] { "Cuneiform Numbers and Punctuation", |
|
1996 |
"CuneiformNumbersandPunctuation"}); |
|
1997 |
||
1998 |
/** |
|
1999 |
* Constant for the "Ancient Greek Musical Notation" Unicode character |
|
2000 |
* block. |
|
2001 |
* @since 1.7 |
|
2002 |
*/ |
|
2003 |
public static final UnicodeBlock ANCIENT_GREEK_MUSICAL_NOTATION = |
|
2004 |
new UnicodeBlock("ANCIENT_GREEK_MUSICAL_NOTATION", |
|
2005 |
new String[] { "Ancient Greek Musical Notation", |
|
2006 |
"AncientGreekMusicalNotation"}); |
|
2007 |
||
2008 |
/** |
|
2009 |
* Constant for the "Counting Rod Numerals" Unicode character block. |
|
2010 |
* @since 1.7 |
|
2011 |
*/ |
|
2012 |
public static final UnicodeBlock COUNTING_ROD_NUMERALS = |
|
2013 |
new UnicodeBlock("COUNTING_ROD_NUMERALS", |
|
2014 |
new String[] { "Counting Rod Numerals", |
|
2015 |
"CountingRodNumerals"}); |
|
2016 |
||
2017 |
/** |
|
2018 |
* Constant for the "Mahjong Tiles" Unicode character block. |
|
2019 |
* @since 1.7 |
|
2020 |
*/ |
|
2021 |
public static final UnicodeBlock MAHJONG_TILES = |
|
2022 |
new UnicodeBlock("MAHJONG_TILES", |
|
2023 |
new String[] { "Mahjong Tiles", |
|
2024 |
"MahjongTiles"}); |
|
2025 |
||
2026 |
/** |
|
2027 |
* Constant for the "Domino Tiles" Unicode character block. |
|
2028 |
* @since 1.7 |
|
2029 |
*/ |
|
2030 |
public static final UnicodeBlock DOMINO_TILES = |
|
2031 |
new UnicodeBlock("DOMINO_TILES", |
|
2032 |
new String[] { "Domino Tiles", |
|
2033 |
"DominoTiles"}); |
|
2034 |
||
2 | 2035 |
private static final int blockStarts[] = { |
2497 | 2036 |
0x0000, // 0000..007F; Basic Latin |
2037 |
0x0080, // 0080..00FF; Latin-1 Supplement |
|
2038 |
0x0100, // 0100..017F; Latin Extended-A |
|
2039 |
0x0180, // 0180..024F; Latin Extended-B |
|
2040 |
0x0250, // 0250..02AF; IPA Extensions |
|
2041 |
0x02B0, // 02B0..02FF; Spacing Modifier Letters |
|
2042 |
0x0300, // 0300..036F; Combining Diacritical Marks |
|
2043 |
0x0370, // 0370..03FF; Greek and Coptic |
|
2044 |
0x0400, // 0400..04FF; Cyrillic |
|
2045 |
0x0500, // 0500..052F; Cyrillic Supplement |
|
2046 |
0x0530, // 0530..058F; Armenian |
|
2047 |
0x0590, // 0590..05FF; Hebrew |
|
2048 |
0x0600, // 0600..06FF; Arabic |
|
2049 |
0x0700, // 0700..074F; Syria |
|
2050 |
0x0750, // 0750..077F; Arabic Supplement |
|
2051 |
0x0780, // 0780..07BF; Thaana |
|
2052 |
0x07C0, // 07C0..07FF; NKo |
|
2053 |
0x0800, // unassigned |
|
2054 |
0x0900, // 0900..097F; Devanagari |
|
2055 |
0x0980, // 0980..09FF; Bengali |
|
2056 |
0x0A00, // 0A00..0A7F; Gurmukhi |
|
2057 |
0x0A80, // 0A80..0AFF; Gujarati |
|
2058 |
0x0B00, // 0B00..0B7F; Oriya |
|
2059 |
0x0B80, // 0B80..0BFF; Tamil |
|
2060 |
0x0C00, // 0C00..0C7F; Telugu |
|
2061 |
0x0C80, // 0C80..0CFF; Kannada |
|
2062 |
0x0D00, // 0D00..0D7F; Malayalam |
|
2063 |
0x0D80, // 0D80..0DFF; Sinhala |
|
2064 |
0x0E00, // 0E00..0E7F; Thai |
|
2065 |
0x0E80, // 0E80..0EFF; Lao |
|
2066 |
0x0F00, // 0F00..0FFF; Tibetan |
|
2067 |
0x1000, // 1000..109F; Myanmar |
|
2068 |
0x10A0, // 10A0..10FF; Georgian |
|
2069 |
0x1100, // 1100..11FF; Hangul Jamo |
|
2070 |
0x1200, // 1200..137F; Ethiopic |
|
2071 |
0x1380, // 1380..139F; Ethiopic Supplement |
|
2072 |
0x13A0, // 13A0..13FF; Cherokee |
|
2073 |
0x1400, // 1400..167F; Unified Canadian Aboriginal Syllabics |
|
2074 |
0x1680, // 1680..169F; Ogham |
|
2075 |
0x16A0, // 16A0..16FF; Runic |
|
2076 |
0x1700, // 1700..171F; Tagalog |
|
2077 |
0x1720, // 1720..173F; Hanunoo |
|
2078 |
0x1740, // 1740..175F; Buhid |
|
2079 |
0x1760, // 1760..177F; Tagbanwa |
|
2080 |
0x1780, // 1780..17FF; Khmer |
|
2081 |
0x1800, // 1800..18AF; Mongolian |
|
2082 |
0x18B0, // unassigned |
|
2083 |
0x1900, // 1900..194F; Limbu |
|
2084 |
0x1950, // 1950..197F; Tai Le |
|
2085 |
0x1980, // 1980..19DF; New Tai Lue |
|
2086 |
0x19E0, // 19E0..19FF; Khmer Symbols |
|
2087 |
0x1A00, // 1A00..1A1F; Buginese |
|
2088 |
0x1A20, // unassigned |
|
2089 |
0x1B00, // 1B00..1B7F; Balinese |
|
2090 |
0x1B80, // 1B80..1BBF; Sundanese |
|
2091 |
0x1BC0, // unassigned |
|
2092 |
0x1C00, // 1C00..1C4F; Lepcha |
|
2093 |
0x1C50, // 1C50..1C7F; Ol Chiki |
|
2094 |
0x1C80, // unassigned |
|
2095 |
0x1D00, // 1D00..1D7F; Phonetic Extensions |
|
2096 |
0x1D80, // 1D80..1DBF; Phonetic Extensions Supplement |
|
2097 |
0x1DC0, // 1DC0..1DFF; Combining Diacritical Marks Supplement |
|
2098 |
0x1E00, // 1E00..1EFF; Latin Extended Additional |
|
2099 |
0x1F00, // 1F00..1FFF; Greek Extended |
|
2100 |
0x2000, // 2000..206F; General Punctuation |
|
2101 |
0x2070, // 2070..209F; Superscripts and Subscripts |
|
2102 |
0x20A0, // 20A0..20CF; Currency Symbols |
|
2103 |
0x20D0, // 20D0..20FF; Combining Diacritical Marks for Symbols |
|
2104 |
0x2100, // 2100..214F; Letterlike Symbols |
|
2105 |
0x2150, // 2150..218F; Number Forms |
|
2106 |
0x2190, // 2190..21FF; Arrows |
|
2107 |
0x2200, // 2200..22FF; Mathematical Operators |
|
2108 |
0x2300, // 2300..23FF; Miscellaneous Technical |
|
2109 |
0x2400, // 2400..243F; Control Pictures |
|
2110 |
0x2440, // 2440..245F; Optical Character Recognition |
|
2111 |
0x2460, // 2460..24FF; Enclosed Alphanumerics |
|
2112 |
0x2500, // 2500..257F; Box Drawing |
|
2113 |
0x2580, // 2580..259F; Block Elements |
|
2114 |
0x25A0, // 25A0..25FF; Geometric Shapes |
|
2115 |
0x2600, // 2600..26FF; Miscellaneous Symbols |
|
2116 |
0x2700, // 2700..27BF; Dingbats |
|
2117 |
0x27C0, // 27C0..27EF; Miscellaneous Mathematical Symbols-A |
|
2118 |
0x27F0, // 27F0..27FF; Supplemental Arrows-A |
|
2119 |
0x2800, // 2800..28FF; Braille Patterns |
|
2120 |
0x2900, // 2900..297F; Supplemental Arrows-B |
|
2121 |
0x2980, // 2980..29FF; Miscellaneous Mathematical Symbols-B |
|
2122 |
0x2A00, // 2A00..2AFF; Supplemental Mathematical Operators |
|
2123 |
0x2B00, // 2B00..2BFF; Miscellaneous Symbols and Arrows |
|
2124 |
0x2C00, // 2C00..2C5F; Glagolitic |
|
2125 |
0x2C60, // 2C60..2C7F; Latin Extended-C |
|
2126 |
0x2C80, // 2C80..2CFF; Coptic |
|
2127 |
0x2D00, // 2D00..2D2F; Georgian Supplement |
|
2128 |
0x2D30, // 2D30..2D7F; Tifinagh |
|
2129 |
0x2D80, // 2D80..2DDF; Ethiopic Extended |
|
2130 |
0x2DE0, // 2DE0..2DFF; Cyrillic Extended-A |
|
2131 |
0x2E00, // 2E00..2E7F; Supplemental Punctuation |
|
2132 |
0x2E80, // 2E80..2EFF; CJK Radicals Supplement |
|
2133 |
0x2F00, // 2F00..2FDF; Kangxi Radicals |
|
2134 |
0x2FE0, // unassigned |
|
2135 |
0x2FF0, // 2FF0..2FFF; Ideographic Description Characters |
|
2136 |
0x3000, // 3000..303F; CJK Symbols and Punctuation |
|
2137 |
0x3040, // 3040..309F; Hiragana |
|
2138 |
0x30A0, // 30A0..30FF; Katakana |
|
2139 |
0x3100, // 3100..312F; Bopomofo |
|
2140 |
0x3130, // 3130..318F; Hangul Compatibility Jamo |
|
2141 |
0x3190, // 3190..319F; Kanbun |
|
2142 |
0x31A0, // 31A0..31BF; Bopomofo Extended |
|
2143 |
0x31C0, // 31C0..31EF; CJK Strokes |
|
2144 |
0x31F0, // 31F0..31FF; Katakana Phonetic Extensions |
|
2145 |
0x3200, // 3200..32FF; Enclosed CJK Letters and Months |
|
2146 |
0x3300, // 3300..33FF; CJK Compatibility |
|
2147 |
0x3400, // 3400..4DBF; CJK Unified Ideographs Extension A |
|
2148 |
0x4DC0, // 4DC0..4DFF; Yijing Hexagram Symbols |
|
2149 |
0x4E00, // 4E00..9FFF; CJK Unified Ideograph |
|
2150 |
0xA000, // A000..A48F; Yi Syllables |
|
2151 |
0xA490, // A490..A4CF; Yi Radicals |
|
2152 |
0xA4D0, // unassigned |
|
2153 |
0xA500, // A500..A63F; Vai |
|
2154 |
0xA640, // A640..A69F; Cyrillic Extended-B |
|
2155 |
0xA6A0, // unassigned |
|
2156 |
0xA700, // A700..A71F; Modifier Tone Letters |
|
2157 |
0xA720, // A720..A7FF; Latin Extended-D |
|
2158 |
0xA800, // A800..A82F; Syloti Nagri |
|
2159 |
0xA830, // unassigned |
|
2160 |
0xA840, // A840..A87F; Phags-pa |
|
2161 |
0xA880, // A880..A8DF; Saurashtra |
|
2162 |
0xA8E0, // unassigned |
|
2163 |
0xA900, // A900..A92F; Kayah Li |
|
2164 |
0xA930, // A930..A95F; Rejang |
|
2165 |
0xA960, // unassigned |
|
2166 |
0xAA00, // AA00..AA5F; Cham |
|
2167 |
0xAA60, // unassigned |
|
2168 |
0xAC00, // AC00..D7AF; Hangul Syllables |
|
2169 |
0xD7B0, // unassigned |
|
2170 |
0xD800, // D800..DB7F; High Surrogates |
|
2171 |
0xDB80, // DB80..DBFF; High Private Use Surrogates |
|
2172 |
0xDC00, // DC00..DFFF; Low Surrogates |
|
2173 |
0xE000, // E000..F8FF; Private Use Area |
|
2174 |
0xF900, // F900..FAFF; CJK Compatibility Ideographs |
|
2175 |
0xFB00, // FB00..FB4F; Alphabetic Presentation Forms |
|
2176 |
0xFB50, // FB50..FDFF; Arabic Presentation Forms-A |
|
2177 |
0xFE00, // FE00..FE0F; Variation Selectors |
|
2178 |
0xFE10, // FE10..FE1F; Vertical Forms |
|
2179 |
0xFE20, // FE20..FE2F; Combining Half Marks |
|
2180 |
0xFE30, // FE30..FE4F; CJK Compatibility Forms |
|
2181 |
0xFE50, // FE50..FE6F; Small Form Variants |
|
2182 |
0xFE70, // FE70..FEFF; Arabic Presentation Forms-B |
|
2183 |
0xFF00, // FF00..FFEF; Halfwidth and Fullwidth Forms |
|
2184 |
0xFFF0, // FFF0..FFFF; Specials |
|
2185 |
0x10000, // 10000..1007F; Linear B Syllabary |
|
2186 |
0x10080, // 10080..100FF; Linear B Ideograms |
|
2187 |
0x10100, // 10100..1013F; Aegean Numbers |
|
2188 |
0x10140, // 10140..1018F; Ancient Greek Numbers |
|
2189 |
0x10190, // 10190..101CF; Ancient Symbols |
|
2190 |
0x101D0, // 101D0..101FF; Phaistos Disc |
|
2191 |
0x10200, // unassigned |
|
2192 |
0x10280, // 10280..1029F; Lycian |
|
2193 |
0x102A0, // 102A0..102DF; Carian |
|
2194 |
0x102E0, // unassigned |
|
2195 |
0x10300, // 10300..1032F; Old Italic |
|
2196 |
0x10330, // 10330..1034F; Gothic |
|
2197 |
0x10350, // unassigned |
|
2198 |
0x10380, // 10380..1039F; Ugaritic |
|
2199 |
0x103A0, // 103A0..103DF; Old Persian |
|
2200 |
0x103E0, // unassigned |
|
2201 |
0x10400, // 10400..1044F; Desere |
|
2202 |
0x10450, // 10450..1047F; Shavian |
|
2203 |
0x10480, // 10480..104AF; Osmanya |
|
2204 |
0x104B0, // unassigned |
|
2205 |
0x10800, // 10800..1083F; Cypriot Syllabary |
|
2206 |
0x10840, // unassigned |
|
2207 |
0x10900, // 10900..1091F; Phoenician |
|
2208 |
0x10920, // 10920..1093F; Lydian |
|
2209 |
0x10940, // unassigned |
|
2210 |
0x10A00, // 10A00..10A5F; Kharoshthi |
|
2211 |
0x10A60, // unassigned |
|
2212 |
0x12000, // 12000..123FF; Cuneiform |
|
2213 |
0x12400, // 12400..1247F; Cuneiform Numbers and Punctuation |
|
2214 |
0x12480, // unassigned |
|
2215 |
0x1D000, // 1D000..1D0FF; Byzantine Musical Symbols |
|
2216 |
0x1D100, // 1D100..1D1FF; Musical Symbols |
|
2217 |
0x1D200, // 1D200..1D24F; Ancient Greek Musical Notation |
|
2218 |
0x1D250, // unassigned |
|
2219 |
0x1D300, // 1D300..1D35F; Tai Xuan Jing Symbols |
|
2220 |
0x1D360, // 1D360..1D37F; Counting Rod Numerals |
|
2221 |
0x1D380, // unassigned |
|
2222 |
0x1D400, // 1D400..1D7FF; Mathematical Alphanumeric Symbols |
|
2223 |
0x1D800, // unassigned |
|
2224 |
0x1F000, // 1F000..1F02F; Mahjong Tiles |
|
2225 |
0x1F030, // 1F030..1F09F; Domino Tiles |
|
2226 |
0x1F0A0, // unassigned |
|
2227 |
0x20000, // 20000..2A6DF; CJK Unified Ideographs Extension B |
|
2228 |
0x2A6E0, // unassigned |
|
2229 |
0x2F800, // 2F800..2FA1F; CJK Compatibility Ideographs Supplement |
|
2230 |
0x2FA20, // unassigned |
|
2231 |
0xE0000, // E0000..E007F; Tags |
|
2232 |
0xE0080, // unassigned |
|
2233 |
0xE0100, // E0100..E01EF; Variation Selectors Supplement |
|
2234 |
0xE01F0, // unassigned |
|
2235 |
0xF0000, // F0000..FFFFF; Supplementary Private Use Area-A |
|
2236 |
0x100000, // 100000..10FFFF; Supplementary Private Use Area-B |
|
2 | 2237 |
}; |
2238 |
||
2239 |
private static final UnicodeBlock[] blocks = { |
|
2240 |
BASIC_LATIN, |
|
2241 |
LATIN_1_SUPPLEMENT, |
|
2242 |
LATIN_EXTENDED_A, |
|
2243 |
LATIN_EXTENDED_B, |
|
2244 |
IPA_EXTENSIONS, |
|
2245 |
SPACING_MODIFIER_LETTERS, |
|
2246 |
COMBINING_DIACRITICAL_MARKS, |
|
2247 |
GREEK, |
|
2248 |
CYRILLIC, |
|
2249 |
CYRILLIC_SUPPLEMENTARY, |
|
2250 |
ARMENIAN, |
|
2251 |
HEBREW, |
|
2252 |
ARABIC, |
|
2253 |
SYRIAC, |
|
2497 | 2254 |
ARABIC_SUPPLEMENT, |
2 | 2255 |
THAANA, |
2497 | 2256 |
NKO, |
2 | 2257 |
null, |
2258 |
DEVANAGARI, |
|
2259 |
BENGALI, |
|
2260 |
GURMUKHI, |
|
2261 |
GUJARATI, |
|
2262 |
ORIYA, |
|
2263 |
TAMIL, |
|
2264 |
TELUGU, |
|
2265 |
KANNADA, |
|
2266 |
MALAYALAM, |
|
2267 |
SINHALA, |
|
2268 |
THAI, |
|
2269 |
LAO, |
|
2270 |
TIBETAN, |
|
2271 |
MYANMAR, |
|
2272 |
GEORGIAN, |
|
2273 |
HANGUL_JAMO, |
|
2274 |
ETHIOPIC, |
|
2497 | 2275 |
ETHIOPIC_SUPPLEMENT, |
2 | 2276 |
CHEROKEE, |
2277 |
UNIFIED_CANADIAN_ABORIGINAL_SYLLABICS, |
|
2278 |
OGHAM, |
|
2279 |
RUNIC, |
|
2280 |
TAGALOG, |
|
2281 |
HANUNOO, |
|
2282 |
BUHID, |
|
2283 |
TAGBANWA, |
|
2284 |
KHMER, |
|
2285 |
MONGOLIAN, |
|
2286 |
null, |
|
2287 |
LIMBU, |
|
2288 |
TAI_LE, |
|
2497 | 2289 |
NEW_TAI_LUE, |
2290 |
KHMER_SYMBOLS, |
|
2291 |
BUGINESE, |
|
2 | 2292 |
null, |
2497 | 2293 |
BALINESE, |
2294 |
SUNDANESE, |
|
2295 |
null, |
|
2296 |
LEPCHA, |
|
2297 |
OL_CHIKI, |
|
2 | 2298 |
null, |
2299 |
PHONETIC_EXTENSIONS, |
|
2497 | 2300 |
PHONETIC_EXTENSIONS_SUPPLEMENT, |
2301 |
COMBINING_DIACRITICAL_MARKS_SUPPLEMENT, |
|
2 | 2302 |
LATIN_EXTENDED_ADDITIONAL, |
2303 |
GREEK_EXTENDED, |
|
2304 |
GENERAL_PUNCTUATION, |
|
2305 |
SUPERSCRIPTS_AND_SUBSCRIPTS, |
|
2306 |
CURRENCY_SYMBOLS, |
|
2307 |
COMBINING_MARKS_FOR_SYMBOLS, |
|
2308 |
LETTERLIKE_SYMBOLS, |
|
2309 |
NUMBER_FORMS, |
|
2310 |
ARROWS, |
|
2311 |
MATHEMATICAL_OPERATORS, |
|
2312 |
MISCELLANEOUS_TECHNICAL, |
|
2313 |
CONTROL_PICTURES, |
|
2314 |
OPTICAL_CHARACTER_RECOGNITION, |
|
2315 |
ENCLOSED_ALPHANUMERICS, |
|
2316 |
BOX_DRAWING, |
|
2317 |
BLOCK_ELEMENTS, |
|
2318 |
GEOMETRIC_SHAPES, |
|
2319 |
MISCELLANEOUS_SYMBOLS, |
|
2320 |
DINGBATS, |
|
2321 |
MISCELLANEOUS_MATHEMATICAL_SYMBOLS_A, |
|
2322 |
SUPPLEMENTAL_ARROWS_A, |
|
2323 |
BRAILLE_PATTERNS, |
|
2324 |
SUPPLEMENTAL_ARROWS_B, |
|
2325 |
MISCELLANEOUS_MATHEMATICAL_SYMBOLS_B, |
|
2326 |
SUPPLEMENTAL_MATHEMATICAL_OPERATORS, |
|
2327 |
MISCELLANEOUS_SYMBOLS_AND_ARROWS, |
|
2497 | 2328 |
GLAGOLITIC, |
2329 |
LATIN_EXTENDED_C, |
|
2330 |
COPTIC, |
|
2331 |
GEORGIAN_SUPPLEMENT, |
|
2332 |
TIFINAGH, |
|
2333 |
ETHIOPIC_EXTENDED, |
|
2334 |
CYRILLIC_EXTENDED_A, |
|
2335 |
SUPPLEMENTAL_PUNCTUATION, |
|
2 | 2336 |
CJK_RADICALS_SUPPLEMENT, |
2337 |
KANGXI_RADICALS, |
|
2338 |
null, |
|
2339 |
IDEOGRAPHIC_DESCRIPTION_CHARACTERS, |
|
2340 |
CJK_SYMBOLS_AND_PUNCTUATION, |
|
2341 |
HIRAGANA, |
|
2342 |
KATAKANA, |
|
2343 |
BOPOMOFO, |
|
2344 |
HANGUL_COMPATIBILITY_JAMO, |
|
2345 |
KANBUN, |
|
2346 |
BOPOMOFO_EXTENDED, |
|
2497 | 2347 |
CJK_STROKES, |
2 | 2348 |
KATAKANA_PHONETIC_EXTENSIONS, |
2349 |
ENCLOSED_CJK_LETTERS_AND_MONTHS, |
|
2350 |
CJK_COMPATIBILITY, |
|
2351 |
CJK_UNIFIED_IDEOGRAPHS_EXTENSION_A, |
|
2352 |
YIJING_HEXAGRAM_SYMBOLS, |
|
2353 |
CJK_UNIFIED_IDEOGRAPHS, |
|
2354 |
YI_SYLLABLES, |
|
2355 |
YI_RADICALS, |
|
2356 |
null, |
|
2497 | 2357 |
VAI, |
2358 |
CYRILLIC_EXTENDED_B, |
|
2359 |
null, |
|
2360 |
MODIFIER_TONE_LETTERS, |
|
2361 |
LATIN_EXTENDED_D, |
|
2362 |
SYLOTI_NAGRI, |
|
2363 |
null, |
|
2364 |
PHAGS_PA, |
|
2365 |
SAURASHTRA, |
|
2366 |
null, |
|
2367 |
KAYAH_LI, |
|
2368 |
REJANG, |
|
2369 |
null, |
|
2370 |
CHAM, |
|
2371 |
null, |
|
2 | 2372 |
HANGUL_SYLLABLES, |
2373 |
null, |
|
2374 |
HIGH_SURROGATES, |
|
2375 |
HIGH_PRIVATE_USE_SURROGATES, |
|
2376 |
LOW_SURROGATES, |
|
2377 |
PRIVATE_USE_AREA, |
|
2378 |
CJK_COMPATIBILITY_IDEOGRAPHS, |
|
2379 |
ALPHABETIC_PRESENTATION_FORMS, |
|
2380 |
ARABIC_PRESENTATION_FORMS_A, |
|
2381 |
VARIATION_SELECTORS, |
|
2497 | 2382 |
VERTICAL_FORMS, |
2 | 2383 |
COMBINING_HALF_MARKS, |
2384 |
CJK_COMPATIBILITY_FORMS, |
|
2385 |
SMALL_FORM_VARIANTS, |
|
2386 |
ARABIC_PRESENTATION_FORMS_B, |
|
2387 |
HALFWIDTH_AND_FULLWIDTH_FORMS, |
|
2388 |
SPECIALS, |
|
2389 |
LINEAR_B_SYLLABARY, |
|
2390 |
LINEAR_B_IDEOGRAMS, |
|
2391 |
AEGEAN_NUMBERS, |
|
2497 | 2392 |
ANCIENT_GREEK_NUMBERS, |
2393 |
ANCIENT_SYMBOLS, |
|
2394 |
PHAISTOS_DISC, |
|
2395 |
null, |
|
2396 |
LYCIAN, |
|
2397 |
CARIAN, |
|
2 | 2398 |
null, |
2399 |
OLD_ITALIC, |
|
2400 |
GOTHIC, |
|
2401 |
null, |
|
2402 |
UGARITIC, |
|
2497 | 2403 |
OLD_PERSIAN, |
2 | 2404 |
null, |
2405 |
DESERET, |
|
2406 |
SHAVIAN, |
|
2407 |
OSMANYA, |
|
2408 |
null, |
|
2409 |
CYPRIOT_SYLLABARY, |
|
2410 |
null, |
|
2497 | 2411 |
PHOENICIAN, |
2412 |
LYDIAN, |
|
2413 |
null, |
|
2414 |
KHAROSHTHI, |
|
2415 |
null, |
|
2416 |
CUNEIFORM, |
|
2417 |
CUNEIFORM_NUMBERS_AND_PUNCTUATION, |
|
2418 |
null, |
|
2 | 2419 |
BYZANTINE_MUSICAL_SYMBOLS, |
2420 |
MUSICAL_SYMBOLS, |
|
2497 | 2421 |
ANCIENT_GREEK_MUSICAL_NOTATION, |
2 | 2422 |
null, |
2423 |
TAI_XUAN_JING_SYMBOLS, |
|
2497 | 2424 |
COUNTING_ROD_NUMERALS, |
2 | 2425 |
null, |
2426 |
MATHEMATICAL_ALPHANUMERIC_SYMBOLS, |
|
2427 |
null, |
|
2497 | 2428 |
MAHJONG_TILES, |
2429 |
DOMINO_TILES, |
|
2430 |
null, |
|
2 | 2431 |
CJK_UNIFIED_IDEOGRAPHS_EXTENSION_B, |
2432 |
null, |
|
2433 |
CJK_COMPATIBILITY_IDEOGRAPHS_SUPPLEMENT, |
|
2434 |
null, |
|
2435 |
TAGS, |
|
2436 |
null, |
|
2437 |
VARIATION_SELECTORS_SUPPLEMENT, |
|
2438 |
null, |
|
2439 |
SUPPLEMENTARY_PRIVATE_USE_AREA_A, |
|
2440 |
SUPPLEMENTARY_PRIVATE_USE_AREA_B |
|
2441 |
}; |
|
2442 |
||
2443 |
||
2444 |
/** |
|
2445 |
* Returns the object representing the Unicode block containing the |
|
2446 |
* given character, or <code>null</code> if the character is not a |
|
2447 |
* member of a defined block. |
|
2448 |
* |
|
2449 |
* <p><b>Note:</b> This method cannot handle <a |
|
2450 |
* href="Character.html#supplementary"> supplementary |
|
2451 |
* characters</a>. To support all Unicode characters, |
|
2452 |
* including supplementary characters, use the {@link |
|
2453 |
* #of(int)} method. |
|
2454 |
* |
|
2455 |
* @param c The character in question |
|
2456 |
* @return The <code>UnicodeBlock</code> instance representing the |
|
2457 |
* Unicode block of which this character is a member, or |
|
2458 |
* <code>null</code> if the character is not a member of any |
|
2459 |
* Unicode block |
|
2460 |
*/ |
|
2461 |
public static UnicodeBlock of(char c) { |
|
2462 |
return of((int)c); |
|
2463 |
} |
|
2464 |
||
2465 |
||
2466 |
/** |
|
2467 |
* Returns the object representing the Unicode block |
|
2468 |
* containing the given character (Unicode code point), or |
|
2469 |
* <code>null</code> if the character is not a member of a |
|
2470 |
* defined block. |
|
2471 |
* |
|
2472 |
* @param codePoint the character (Unicode code point) in question. |
|
2473 |
* @return The <code>UnicodeBlock</code> instance representing the |
|
2474 |
* Unicode block of which this character is a member, or |
|
2475 |
* <code>null</code> if the character is not a member of any |
|
2476 |
* Unicode block |
|
2477 |
* @exception IllegalArgumentException if the specified |
|
2478 |
* <code>codePoint</code> is an invalid Unicode code point. |
|
2479 |
* @see Character#isValidCodePoint(int) |
|
2480 |
* @since 1.5 |
|
2481 |
*/ |
|
2482 |
public static UnicodeBlock of(int codePoint) { |
|
2483 |
if (!isValidCodePoint(codePoint)) { |
|
2484 |
throw new IllegalArgumentException(); |
|
2485 |
} |
|
2486 |
||
2487 |
int top, bottom, current; |
|
2488 |
bottom = 0; |
|
2489 |
top = blockStarts.length; |
|
2490 |
current = top/2; |
|
2491 |
||
2492 |
// invariant: top > current >= bottom && codePoint >= unicodeBlockStarts[bottom] |
|
2493 |
while (top - bottom > 1) { |
|
2494 |
if (codePoint >= blockStarts[current]) { |
|
2495 |
bottom = current; |
|
2496 |
} else { |
|
2497 |
top = current; |
|
2498 |
} |
|
2499 |
current = (top + bottom) / 2; |
|
2500 |
} |
|
2501 |
return blocks[current]; |
|
2502 |
} |
|
2503 |
||
2504 |
/** |
|
2505 |
* Returns the UnicodeBlock with the given name. Block |
|
2506 |
* names are determined by The Unicode Standard. The file |
|
2507 |
* Blocks-<version>.txt defines blocks for a particular |
|
2508 |
* version of the standard. The {@link Character} class specifies |
|
2509 |
* the version of the standard that it supports. |
|
2510 |
* <p> |
|
2511 |
* This method accepts block names in the following forms: |
|
2512 |
* <ol> |
|
2513 |
* <li> Canonical block names as defined by the Unicode Standard. |
|
2514 |
* For example, the standard defines a "Basic Latin" block. Therefore, this |
|
2515 |
* method accepts "Basic Latin" as a valid block name. The documentation of |
|
2516 |
* each UnicodeBlock provides the canonical name. |
|
2517 |
* <li>Canonical block names with all spaces removed. For example, "BasicLatin" |
|
2518 |
* is a valid block name for the "Basic Latin" block. |
|
2519 |
* <li>The text representation of each constant UnicodeBlock identifier. |
|
2520 |
* For example, this method will return the {@link #BASIC_LATIN} block if |
|
2521 |
* provided with the "BASIC_LATIN" name. This form replaces all spaces and |
|
2522 |
* hyphens in the canonical name with underscores. |
|
2523 |
* </ol> |
|
2524 |
* Finally, character case is ignored for all of the valid block name forms. |
|
2525 |
* For example, "BASIC_LATIN" and "basic_latin" are both valid block names. |
|
2526 |
* The en_US locale's case mapping rules are used to provide case-insensitive |
|
2527 |
* string comparisons for block name validation. |
|
2528 |
* <p> |
|
2529 |
* If the Unicode Standard changes block names, both the previous and |
|
2530 |
* current names will be accepted. |
|
2531 |
* |
|
2532 |
* @param blockName A <code>UnicodeBlock</code> name. |
|
2533 |
* @return The <code>UnicodeBlock</code> instance identified |
|
2534 |
* by <code>blockName</code> |
|
2535 |
* @throws IllegalArgumentException if <code>blockName</code> is an |
|
2536 |
* invalid name |
|
2537 |
* @throws NullPointerException if <code>blockName</code> is null |
|
2538 |
* @since 1.5 |
|
2539 |
*/ |
|
2540 |
public static final UnicodeBlock forName(String blockName) { |
|
2541 |
UnicodeBlock block = (UnicodeBlock)map.get(blockName.toUpperCase(Locale.US)); |
|
2542 |
if (block == null) { |
|
2543 |
throw new IllegalArgumentException(); |
|
2544 |
} |
|
2545 |
return block; |
|
2546 |
} |
|
2547 |
} |
|
2548 |
||
2549 |
||
2550 |
/** |
|
5610
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2551 |
* A family of character subsets representing the character scripts |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2552 |
* defined in the <a href="http://www.unicode.org/reports/tr24/"> |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2553 |
* <i>Unicode Standard Annex #24: Script Names</i></a>. Every Unicode |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2554 |
* character is assigned to a single Unicode script, either a specific |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2555 |
* script, such as {@link Character.UnicodeScript#LATIN Latin}, or |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2556 |
* one of the following three special values, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2557 |
* {@link Character.UnicodeScript#INHERITED Inherited}, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2558 |
* {@link Character.UnicodeScript#COMMON Common} or |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2559 |
* {@link Character.UnicodeScript#UNKNOWN Unknown}. |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2560 |
* |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2561 |
* @since 1.7 |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2562 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2563 |
public static enum UnicodeScript { |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2564 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2565 |
* Unicode script "Common". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2566 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2567 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2568 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2569 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2570 |
* Unicode script "Latin". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2571 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2572 |
LATIN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2573 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2574 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2575 |
* Unicode script "Greek". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2576 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2577 |
GREEK, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2578 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2579 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2580 |
* Unicode script "Cyrillic". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2581 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2582 |
CYRILLIC, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2583 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2584 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2585 |
* Unicode script "Armenian". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2586 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2587 |
ARMENIAN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2588 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2589 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2590 |
* Unicode script "Hebrew". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2591 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2592 |
HEBREW, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2593 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2594 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2595 |
* Unicode script "Arabic". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2596 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2597 |
ARABIC, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2598 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2599 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2600 |
* Unicode script "Syriac". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2601 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2602 |
SYRIAC, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2603 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2604 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2605 |
* Unicode script "Thaana". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2606 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2607 |
THAANA, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2608 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2609 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2610 |
* Unicode script "Devanagari". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2611 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2612 |
DEVANAGARI, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2613 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2614 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2615 |
* Unicode script "Bengali". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2616 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2617 |
BENGALI, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2618 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2619 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2620 |
* Unicode script "Gurmukhi". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2621 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2622 |
GURMUKHI, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2623 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2624 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2625 |
* Unicode script "Gujarati". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2626 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2627 |
GUJARATI, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2628 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2629 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2630 |
* Unicode script "Oriya". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2631 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2632 |
ORIYA, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2633 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2634 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2635 |
* Unicode script "Tamil". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2636 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2637 |
TAMIL, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2638 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2639 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2640 |
* Unicode script "Telugu". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2641 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2642 |
TELUGU, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2643 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2644 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2645 |
* Unicode script "Kannada". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2646 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2647 |
KANNADA, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2648 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2649 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2650 |
* Unicode script "Malayalam". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2651 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2652 |
MALAYALAM, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2653 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2654 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2655 |
* Unicode script "Sinhala". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2656 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2657 |
SINHALA, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2658 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2659 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2660 |
* Unicode script "Thai". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2661 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2662 |
THAI, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2663 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2664 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2665 |
* Unicode script "Lao". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2666 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2667 |
LAO, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2668 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2669 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2670 |
* Unicode script "Tibetan". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2671 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2672 |
TIBETAN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2673 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2674 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2675 |
* Unicode script "Myanmar". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2676 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2677 |
MYANMAR, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2678 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2679 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2680 |
* Unicode script "Georgian". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2681 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2682 |
GEORGIAN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2683 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2684 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2685 |
* Unicode script "Hangul". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2686 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2687 |
HANGUL, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2688 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2689 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2690 |
* Unicode script "Ethiopic". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2691 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2692 |
ETHIOPIC, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2693 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2694 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2695 |
* Unicode script "Cherokee". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2696 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2697 |
CHEROKEE, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2698 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2699 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2700 |
* Unicode script "Canadian_Aboriginal". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2701 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2702 |
CANADIAN_ABORIGINAL, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2703 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2704 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2705 |
* Unicode script "Ogham". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2706 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2707 |
OGHAM, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2708 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2709 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2710 |
* Unicode script "Runic". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2711 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2712 |
RUNIC, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2713 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2714 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2715 |
* Unicode script "Khmer". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2716 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2717 |
KHMER, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2718 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2719 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2720 |
* Unicode script "Mongolian". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2721 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2722 |
MONGOLIAN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2723 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2724 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2725 |
* Unicode script "Hiragana". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2726 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2727 |
HIRAGANA, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2728 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2729 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2730 |
* Unicode script "Katakana". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2731 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2732 |
KATAKANA, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2733 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2734 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2735 |
* Unicode script "Bopomofo". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2736 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2737 |
BOPOMOFO, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2738 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2739 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2740 |
* Unicode script "Han". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2741 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2742 |
HAN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2743 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2744 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2745 |
* Unicode script "Yi". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2746 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2747 |
YI, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2748 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2749 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2750 |
* Unicode script "Old_Italic". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2751 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2752 |
OLD_ITALIC, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2753 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2754 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2755 |
* Unicode script "Gothic". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2756 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2757 |
GOTHIC, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2758 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2759 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2760 |
* Unicode script "Deseret". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2761 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2762 |
DESERET, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2763 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2764 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2765 |
* Unicode script "Inherited". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2766 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2767 |
INHERITED, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2768 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2769 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2770 |
* Unicode script "Tagalog". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2771 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2772 |
TAGALOG, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2773 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2774 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2775 |
* Unicode script "Hanunoo". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2776 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2777 |
HANUNOO, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2778 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2779 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2780 |
* Unicode script "Buhid". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2781 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2782 |
BUHID, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2783 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2784 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2785 |
* Unicode script "Tagbanwa". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2786 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2787 |
TAGBANWA, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2788 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2789 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2790 |
* Unicode script "Limbu". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2791 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2792 |
LIMBU, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2793 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2794 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2795 |
* Unicode script "Tai_Le". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2796 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2797 |
TAI_LE, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2798 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2799 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2800 |
* Unicode script "Linear_B". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2801 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2802 |
LINEAR_B, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2803 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2804 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2805 |
* Unicode script "Ugaritic". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2806 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2807 |
UGARITIC, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2808 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2809 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2810 |
* Unicode script "Shavian". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2811 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2812 |
SHAVIAN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2813 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2814 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2815 |
* Unicode script "Osmanya". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2816 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2817 |
OSMANYA, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2818 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2819 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2820 |
* Unicode script "Cypriot". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2821 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2822 |
CYPRIOT, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2823 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2824 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2825 |
* Unicode script "Braille". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2826 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2827 |
BRAILLE, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2828 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2829 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2830 |
* Unicode script "Buginese". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2831 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2832 |
BUGINESE, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2833 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2834 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2835 |
* Unicode script "Coptic". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2836 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2837 |
COPTIC, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2838 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2839 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2840 |
* Unicode script "New_Tai_Lue". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2841 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2842 |
NEW_TAI_LUE, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2843 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2844 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2845 |
* Unicode script "Glagolitic". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2846 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2847 |
GLAGOLITIC, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2848 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2849 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2850 |
* Unicode script "Tifinagh". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2851 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2852 |
TIFINAGH, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2853 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2854 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2855 |
* Unicode script "Syloti_Nagri". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2856 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2857 |
SYLOTI_NAGRI, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2858 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2859 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2860 |
* Unicode script "Old_Persian". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2861 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2862 |
OLD_PERSIAN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2863 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2864 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2865 |
* Unicode script "Kharoshthi". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2866 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2867 |
KHAROSHTHI, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2868 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2869 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2870 |
* Unicode script "Balinese". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2871 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2872 |
BALINESE, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2873 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2874 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2875 |
* Unicode script "Cuneiform". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2876 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2877 |
CUNEIFORM, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2878 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2879 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2880 |
* Unicode script "Phoenician". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2881 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2882 |
PHOENICIAN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2883 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2884 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2885 |
* Unicode script "Phags_Pa". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2886 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2887 |
PHAGS_PA, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2888 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2889 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2890 |
* Unicode script "Nko". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2891 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2892 |
NKO, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2893 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2894 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2895 |
* Unicode script "Sundanese". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2896 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2897 |
SUNDANESE, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2898 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2899 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2900 |
* Unicode script "Lepcha". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2901 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2902 |
LEPCHA, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2903 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2904 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2905 |
* Unicode script "Ol_Chiki". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2906 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2907 |
OL_CHIKI, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2908 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2909 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2910 |
* Unicode script "Vai". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2911 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2912 |
VAI, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2913 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2914 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2915 |
* Unicode script "Saurashtra". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2916 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2917 |
SAURASHTRA, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2918 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2919 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2920 |
* Unicode script "Kayah_Li". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2921 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2922 |
KAYAH_LI, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2923 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2924 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2925 |
* Unicode script "Rejang". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2926 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2927 |
REJANG, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2928 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2929 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2930 |
* Unicode script "Lycian". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2931 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2932 |
LYCIAN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2933 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2934 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2935 |
* Unicode script "Carian". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2936 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2937 |
CARIAN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2938 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2939 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2940 |
* Unicode script "Lydian". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2941 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2942 |
LYDIAN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2943 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2944 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2945 |
* Unicode script "Cham". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2946 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2947 |
CHAM, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2948 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2949 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2950 |
* Unicode script "Tai_Tham". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2951 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2952 |
TAI_THAM, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2953 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2954 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2955 |
* Unicode script "Tai_Viet". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2956 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2957 |
TAI_VIET, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2958 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2959 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2960 |
* Unicode script "Avestan". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2961 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2962 |
AVESTAN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2963 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2964 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2965 |
* Unicode script "Egyptian_Hieroglyphs". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2966 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2967 |
EGYPTIAN_HIEROGLYPHS, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2968 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2969 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2970 |
* Unicode script "Samaritan". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2971 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2972 |
SAMARITAN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2973 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2974 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2975 |
* Unicode script "Lisu". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2976 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2977 |
LISU, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2978 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2979 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2980 |
* Unicode script "Bamum". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2981 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2982 |
BAMUM, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2983 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2984 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2985 |
* Unicode script "Javanese". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2986 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2987 |
JAVANESE, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2988 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2989 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2990 |
* Unicode script "Meetei_Mayek". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2991 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2992 |
MEETEI_MAYEK, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2993 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2994 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2995 |
* Unicode script "Imperial_Aramaic". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2996 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2997 |
IMPERIAL_ARAMAIC, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2998 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
2999 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3000 |
* Unicode script "Old_South_Arabian". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3001 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3002 |
OLD_SOUTH_ARABIAN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3003 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3004 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3005 |
* Unicode script "Inscriptional_Parthian". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3006 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3007 |
INSCRIPTIONAL_PARTHIAN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3008 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3009 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3010 |
* Unicode script "Inscriptional_Pahlavi". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3011 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3012 |
INSCRIPTIONAL_PAHLAVI, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3013 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3014 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3015 |
* Unicode script "Old_Turkic". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3016 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3017 |
OLD_TURKIC, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3018 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3019 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3020 |
* Unicode script "Kaithi". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3021 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3022 |
KAITHI, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3023 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3024 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3025 |
* Unicode script "Unknown". |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3026 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3027 |
UNKNOWN; |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3028 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3029 |
private static final int[] scriptStarts = { |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3030 |
0x0000, // 0000..0040; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3031 |
0x0041, // 0041..005A; LATIN |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3032 |
0x005B, // 005B..0060; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3033 |
0x0061, // 0061..007A; LATIN |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3034 |
0x007B, // 007B..00A9; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3035 |
0x00AA, // 00AA..00AA; LATIN |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3036 |
0x00AB, // 00AB..00B9; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3037 |
0x00BA, // 00BA..00BA; LATIN |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3038 |
0x00BB, // 00BB..00BF; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3039 |
0x00C0, // 00C0..00D6; LATIN |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3040 |
0x00D7, // 00D7..00D7; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3041 |
0x00D8, // 00D8..00F6; LATIN |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3042 |
0x00F7, // 00F7..00F7; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3043 |
0x00F8, // 00F8..02B8; LATIN |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3044 |
0x02B9, // 02B9..02DF; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3045 |
0x02E0, // 02E0..02E4; LATIN |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3046 |
0x02E5, // 02E5..02FF; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3047 |
0x0300, // 0300..036F; INHERITED |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3048 |
0x0370, // 0370..0373; GREEK |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3049 |
0x0374, // 0374..0374; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3050 |
0x0375, // 0375..037D; GREEK |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3051 |
0x037E, // 037E..0383; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3052 |
0x0384, // 0384..0384; GREEK |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3053 |
0x0385, // 0385..0385; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3054 |
0x0386, // 0386..0386; GREEK |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3055 |
0x0387, // 0387..0387; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3056 |
0x0388, // 0388..03E1; GREEK |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3057 |
0x03E2, // 03E2..03EF; COPTIC |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3058 |
0x03F0, // 03F0..03FF; GREEK |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3059 |
0x0400, // 0400..0484; CYRILLIC |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3060 |
0x0485, // 0485..0486; INHERITED |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3061 |
0x0487, // 0487..0530; CYRILLIC |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3062 |
0x0531, // 0531..0588; ARMENIAN |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3063 |
0x0589, // 0589..0589; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3064 |
0x058A, // 058A..0590; ARMENIAN |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3065 |
0x0591, // 0591..05FF; HEBREW |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3066 |
0x0600, // 0600..0605; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3067 |
0x0606, // 0606..060B; ARABIC |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3068 |
0x060C, // 060C..060C; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3069 |
0x060D, // 060D..061A; ARABIC |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3070 |
0x061B, // 061B..061D; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3071 |
0x061E, // 061E..061E; ARABIC |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3072 |
0x061F, // 061F..0620; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3073 |
0x0621, // 0621..063F; ARABIC |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3074 |
0x0640, // 0640..0640; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3075 |
0x0641, // 0641..064A; ARABIC |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3076 |
0x064B, // 064B..0655; INHERITED |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3077 |
0x0656, // 0656..065F; ARABIC |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3078 |
0x0660, // 0660..0669; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3079 |
0x066A, // 066A..066F; ARABIC |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3080 |
0x0670, // 0670..0670; INHERITED |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3081 |
0x0671, // 0671..06DC; ARABIC |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3082 |
0x06DD, // 06DD..06DD; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3083 |
0x06DE, // 06DE..06FF; ARABIC |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3084 |
0x0700, // 0700..074F; SYRIAC |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3085 |
0x0750, // 0750..077F; ARABIC |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3086 |
0x0780, // 0780..07BF; THAANA |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3087 |
0x07C0, // 07C0..07FF; NKO |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3088 |
0x0800, // 0800..08FF; SAMARITAN |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3089 |
0x0900, // 0900..0950; DEVANAGARI |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3090 |
0x0951, // 0951..0952; INHERITED |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3091 |
0x0953, // 0953..0963; DEVANAGARI |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3092 |
0x0964, // 0964..0965; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3093 |
0x0966, // 0966..096F; DEVANAGARI |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3094 |
0x0970, // 0970..0970; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3095 |
0x0971, // 0971..0980; DEVANAGARI |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3096 |
0x0981, // 0981..0A00; BENGALI |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3097 |
0x0A01, // 0A01..0A80; GURMUKHI |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3098 |
0x0A81, // 0A81..0B00; GUJARATI |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3099 |
0x0B01, // 0B01..0B81; ORIYA |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3100 |
0x0B82, // 0B82..0C00; TAMIL |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3101 |
0x0C01, // 0C01..0C81; TELUGU |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3102 |
0x0C82, // 0C82..0CF0; KANNADA |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3103 |
0x0CF1, // 0CF1..0D01; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3104 |
0x0D02, // 0D02..0D81; MALAYALAM |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3105 |
0x0D82, // 0D82..0E00; SINHALA |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3106 |
0x0E01, // 0E01..0E3E; THAI |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3107 |
0x0E3F, // 0E3F..0E3F; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3108 |
0x0E40, // 0E40..0E80; THAI |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3109 |
0x0E81, // 0E81..0EFF; LAO |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3110 |
0x0F00, // 0F00..0FD4; TIBETAN |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3111 |
0x0FD5, // 0FD5..0FFF; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3112 |
0x1000, // 1000..109F; MYANMAR |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3113 |
0x10A0, // 10A0..10FA; GEORGIAN |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3114 |
0x10FB, // 10FB..10FB; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3115 |
0x10FC, // 10FC..10FF; GEORGIAN |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3116 |
0x1100, // 1100..11FF; HANGUL |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3117 |
0x1200, // 1200..139F; ETHIOPIC |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3118 |
0x13A0, // 13A0..13FF; CHEROKEE |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3119 |
0x1400, // 1400..167F; CANADIAN_ABORIGINAL |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3120 |
0x1680, // 1680..169F; OGHAM |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3121 |
0x16A0, // 16A0..16EA; RUNIC |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3122 |
0x16EB, // 16EB..16ED; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3123 |
0x16EE, // 16EE..16FF; RUNIC |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3124 |
0x1700, // 1700..171F; TAGALOG |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3125 |
0x1720, // 1720..1734; HANUNOO |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3126 |
0x1735, // 1735..173F; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3127 |
0x1740, // 1740..175F; BUHID |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3128 |
0x1760, // 1760..177F; TAGBANWA |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3129 |
0x1780, // 1780..17FF; KHMER |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3130 |
0x1800, // 1800..1801; MONGOLIAN |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3131 |
0x1802, // 1802..1803; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3132 |
0x1804, // 1804..1804; MONGOLIAN |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3133 |
0x1805, // 1805..1805; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3134 |
0x1806, // 1806..18AF; MONGOLIAN |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3135 |
0x18B0, // 18B0..18FF; CANADIAN_ABORIGINAL |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3136 |
0x1900, // 1900..194F; LIMBU |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3137 |
0x1950, // 1950..197F; TAI_LE |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3138 |
0x1980, // 1980..19DF; NEW_TAI_LUE |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3139 |
0x19E0, // 19E0..19FF; KHMER |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3140 |
0x1A00, // 1A00..1A1F; BUGINESE |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3141 |
0x1A20, // 1A20..1AFF; TAI_THAM |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3142 |
0x1B00, // 1B00..1B7F; BALINESE |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3143 |
0x1B80, // 1B80..1BFF; SUNDANESE |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3144 |
0x1C00, // 1C00..1C4F; LEPCHA |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3145 |
0x1C50, // 1C50..1CCF; OL_CHIKI |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3146 |
0x1CD0, // 1CD0..1CD2; INHERITED |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3147 |
0x1CD3, // 1CD3..1CD3; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3148 |
0x1CD4, // 1CD4..1CE0; INHERITED |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3149 |
0x1CE1, // 1CE1..1CE1; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3150 |
0x1CE2, // 1CE2..1CE8; INHERITED |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3151 |
0x1CE9, // 1CE9..1CEC; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3152 |
0x1CED, // 1CED..1CED; INHERITED |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3153 |
0x1CEE, // 1CEE..1CFF; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3154 |
0x1D00, // 1D00..1D25; LATIN |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3155 |
0x1D26, // 1D26..1D2A; GREEK |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3156 |
0x1D2B, // 1D2B..1D2B; CYRILLIC |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3157 |
0x1D2C, // 1D2C..1D5C; LATIN |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3158 |
0x1D5D, // 1D5D..1D61; GREEK |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3159 |
0x1D62, // 1D62..1D65; LATIN |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3160 |
0x1D66, // 1D66..1D6A; GREEK |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3161 |
0x1D6B, // 1D6B..1D77; LATIN |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3162 |
0x1D78, // 1D78..1D78; CYRILLIC |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3163 |
0x1D79, // 1D79..1DBE; LATIN |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3164 |
0x1DBF, // 1DBF..1DBF; GREEK |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3165 |
0x1DC0, // 1DC0..1DFF; INHERITED |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3166 |
0x1E00, // 1E00..1EFF; LATIN |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3167 |
0x1F00, // 1F00..1FFF; GREEK |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3168 |
0x2000, // 2000..200B; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3169 |
0x200C, // 200C..200D; INHERITED |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3170 |
0x200E, // 200E..2070; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3171 |
0x2071, // 2071..2073; LATIN |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3172 |
0x2074, // 2074..207E; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3173 |
0x207F, // 207F..207F; LATIN |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3174 |
0x2080, // 2080..208F; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3175 |
0x2090, // 2090..209F; LATIN |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3176 |
0x20A0, // 20A0..20CF; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3177 |
0x20D0, // 20D0..20FF; INHERITED |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3178 |
0x2100, // 2100..2125; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3179 |
0x2126, // 2126..2126; GREEK |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3180 |
0x2127, // 2127..2129; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3181 |
0x212A, // 212A..212B; LATIN |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3182 |
0x212C, // 212C..2131; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3183 |
0x2132, // 2132..2132; LATIN |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3184 |
0x2133, // 2133..214D; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3185 |
0x214E, // 214E..214E; LATIN |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3186 |
0x214F, // 214F..215F; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3187 |
0x2160, // 2160..2188; LATIN |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3188 |
0x2189, // 2189..27FF; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3189 |
0x2800, // 2800..28FF; BRAILLE |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3190 |
0x2900, // 2900..2BFF; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3191 |
0x2C00, // 2C00..2C5F; GLAGOLITIC |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3192 |
0x2C60, // 2C60..2C7F; LATIN |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3193 |
0x2C80, // 2C80..2CFF; COPTIC |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3194 |
0x2D00, // 2D00..2D2F; GEORGIAN |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3195 |
0x2D30, // 2D30..2D7F; TIFINAGH |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3196 |
0x2D80, // 2D80..2DDF; ETHIOPIC |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3197 |
0x2DE0, // 2DE0..2DFF; CYRILLIC |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3198 |
0x2E00, // 2E00..2E7F; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3199 |
0x2E80, // 2E80..2FEF; HAN |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3200 |
0x2FF0, // 2FF0..3004; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3201 |
0x3005, // 3005..3005; HAN |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3202 |
0x3006, // 3006..3006; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3203 |
0x3007, // 3007..3007; HAN |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3204 |
0x3008, // 3008..3020; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3205 |
0x3021, // 3021..3029; HAN |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3206 |
0x302A, // 302A..302F; INHERITED |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3207 |
0x3030, // 3030..3037; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3208 |
0x3038, // 3038..303B; HAN |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3209 |
0x303C, // 303C..3040; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3210 |
0x3041, // 3041..3098; HIRAGANA |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3211 |
0x3099, // 3099..309A; INHERITED |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3212 |
0x309B, // 309B..309C; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3213 |
0x309D, // 309D..309F; HIRAGANA |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3214 |
0x30A0, // 30A0..30A0; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3215 |
0x30A1, // 30A1..30FA; KATAKANA |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3216 |
0x30FB, // 30FB..30FC; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3217 |
0x30FD, // 30FD..3104; KATAKANA |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3218 |
0x3105, // 3105..3130; BOPOMOFO |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3219 |
0x3131, // 3131..318F; HANGUL |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3220 |
0x3190, // 3190..319F; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3221 |
0x31A0, // 31A0..31BF; BOPOMOFO |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3222 |
0x31C0, // 31C0..31EF; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3223 |
0x31F0, // 31F0..31FF; KATAKANA |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3224 |
0x3200, // 3200..321F; HANGUL |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3225 |
0x3220, // 3220..325F; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3226 |
0x3260, // 3260..327E; HANGUL |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3227 |
0x327F, // 327F..32CF; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3228 |
0x32D0, // 32D0..3357; KATAKANA |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3229 |
0x3358, // 3358..33FF; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3230 |
0x3400, // 3400..4DBF; HAN |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3231 |
0x4DC0, // 4DC0..4DFF; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3232 |
0x4E00, // 4E00..9FFF; HAN |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3233 |
0xA000, // A000..A4CF; YI |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3234 |
0xA4D0, // A4D0..A4FF; LISU |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3235 |
0xA500, // A500..A63F; VAI |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3236 |
0xA640, // A640..A69F; CYRILLIC |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3237 |
0xA6A0, // A6A0..A6FF; BAMUM |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3238 |
0xA700, // A700..A721; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3239 |
0xA722, // A722..A787; LATIN |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3240 |
0xA788, // A788..A78A; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3241 |
0xA78B, // A78B..A7FF; LATIN |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3242 |
0xA800, // A800..A82F; SYLOTI_NAGRI |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3243 |
0xA830, // A830..A83F; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3244 |
0xA840, // A840..A87F; PHAGS_PA |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3245 |
0xA880, // A880..A8DF; SAURASHTRA |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3246 |
0xA8E0, // A8E0..A8FF; DEVANAGARI |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3247 |
0xA900, // A900..A92F; KAYAH_LI |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3248 |
0xA930, // A930..A95F; REJANG |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3249 |
0xA960, // A960..A97F; HANGUL |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3250 |
0xA980, // A980..A9FF; JAVANESE |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3251 |
0xAA00, // AA00..AA5F; CHAM |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3252 |
0xAA60, // AA60..AA7F; MYANMAR |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3253 |
0xAA80, // AA80..ABBF; TAI_VIET |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3254 |
0xABC0, // ABC0..ABFF; MEETEI_MAYEK |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3255 |
0xAC00, // AC00..D7FB; HANGUL |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3256 |
0xD7FC, // D7FC..F8FF; UNKNOWN |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3257 |
0xF900, // F900..FAFF; HAN |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3258 |
0xFB00, // FB00..FB12; LATIN |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3259 |
0xFB13, // FB13..FB1C; ARMENIAN |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3260 |
0xFB1D, // FB1D..FB4F; HEBREW |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3261 |
0xFB50, // FB50..FD3D; ARABIC |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3262 |
0xFD3E, // FD3E..FD4F; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3263 |
0xFD50, // FD50..FDFC; ARABIC |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3264 |
0xFDFD, // FDFD..FDFF; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3265 |
0xFE00, // FE00..FE0F; INHERITED |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3266 |
0xFE10, // FE10..FE1F; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3267 |
0xFE20, // FE20..FE2F; INHERITED |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3268 |
0xFE30, // FE30..FE6F; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3269 |
0xFE70, // FE70..FEFE; ARABIC |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3270 |
0xFEFF, // FEFF..FF20; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3271 |
0xFF21, // FF21..FF3A; LATIN |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3272 |
0xFF3B, // FF3B..FF40; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3273 |
0xFF41, // FF41..FF5A; LATIN |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3274 |
0xFF5B, // FF5B..FF65; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3275 |
0xFF66, // FF66..FF6F; KATAKANA |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3276 |
0xFF70, // FF70..FF70; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3277 |
0xFF71, // FF71..FF9D; KATAKANA |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3278 |
0xFF9E, // FF9E..FF9F; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3279 |
0xFFA0, // FFA0..FFDF; HANGUL |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3280 |
0xFFE0, // FFE0..FFFF; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3281 |
0x10000, // 10000..100FF; LINEAR_B |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3282 |
0x10100, // 10100..1013F; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3283 |
0x10140, // 10140..1018F; GREEK |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3284 |
0x10190, // 10190..101FC; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3285 |
0x101FD, // 101FD..1027F; INHERITED |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3286 |
0x10280, // 10280..1029F; LYCIAN |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3287 |
0x102A0, // 102A0..102FF; CARIAN |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3288 |
0x10300, // 10300..1032F; OLD_ITALIC |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3289 |
0x10330, // 10330..1037F; GOTHIC |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3290 |
0x10380, // 10380..1039F; UGARITIC |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3291 |
0x103A0, // 103A0..103FF; OLD_PERSIAN |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3292 |
0x10400, // 10400..1044F; DESERET |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3293 |
0x10450, // 10450..1047F; SHAVIAN |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3294 |
0x10480, // 10480..107FF; OSMANYA |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3295 |
0x10800, // 10800..1083F; CYPRIOT |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3296 |
0x10840, // 10840..108FF; IMPERIAL_ARAMAIC |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3297 |
0x10900, // 10900..1091F; PHOENICIAN |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3298 |
0x10920, // 10920..109FF; LYDIAN |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3299 |
0x10A00, // 10A00..10A5F; KHAROSHTHI |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3300 |
0x10A60, // 10A60..10AFF; OLD_SOUTH_ARABIAN |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3301 |
0x10B00, // 10B00..10B3F; AVESTAN |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3302 |
0x10B40, // 10B40..10B5F; INSCRIPTIONAL_PARTHIAN |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3303 |
0x10B60, // 10B60..10BFF; INSCRIPTIONAL_PAHLAVI |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3304 |
0x10C00, // 10C00..10E5F; OLD_TURKIC |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3305 |
0x10E60, // 10E60..1107F; ARABIC |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3306 |
0x11080, // 11080..11FFF; KAITHI |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3307 |
0x12000, // 12000..12FFF; CUNEIFORM |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3308 |
0x13000, // 13000..1CFFF; EGYPTIAN_HIEROGLYPHS |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3309 |
0x1D000, // 1D000..1D166; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3310 |
0x1D167, // 1D167..1D169; INHERITED |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3311 |
0x1D16A, // 1D16A..1D17A; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3312 |
0x1D17B, // 1D17B..1D182; INHERITED |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3313 |
0x1D183, // 1D183..1D184; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3314 |
0x1D185, // 1D185..1D18B; INHERITED |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3315 |
0x1D18C, // 1D18C..1D1A9; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3316 |
0x1D1AA, // 1D1AA..1D1AD; INHERITED |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3317 |
0x1D1AE, // 1D1AE..1D1FF; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3318 |
0x1D200, // 1D200..1D2FF; GREEK |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3319 |
0x1D300, // 1D300..1F1FF; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3320 |
0x1F200, // 1F200..1F20F; HIRAGANA |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3321 |
0x1F210, // 1F210..1FFFF; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3322 |
0x20000, // 20000..E0000; HAN |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3323 |
0xE0001, // E0001..E00FF; COMMON |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3324 |
0xE0100, // E0100..E01EF; INHERITED |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3325 |
0xE01F0 // E01F0..10FFFF; UNKNOWN |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3326 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3327 |
}; |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3328 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3329 |
private static final UnicodeScript[] scripts = { |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3330 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3331 |
LATIN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3332 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3333 |
LATIN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3334 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3335 |
LATIN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3336 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3337 |
LATIN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3338 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3339 |
LATIN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3340 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3341 |
LATIN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3342 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3343 |
LATIN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3344 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3345 |
LATIN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3346 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3347 |
INHERITED, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3348 |
GREEK, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3349 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3350 |
GREEK, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3351 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3352 |
GREEK, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3353 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3354 |
GREEK, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3355 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3356 |
GREEK, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3357 |
COPTIC, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3358 |
GREEK, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3359 |
CYRILLIC, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3360 |
INHERITED, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3361 |
CYRILLIC, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3362 |
ARMENIAN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3363 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3364 |
ARMENIAN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3365 |
HEBREW, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3366 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3367 |
ARABIC, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3368 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3369 |
ARABIC, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3370 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3371 |
ARABIC, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3372 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3373 |
ARABIC, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3374 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3375 |
ARABIC, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3376 |
INHERITED, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3377 |
ARABIC, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3378 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3379 |
ARABIC, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3380 |
INHERITED, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3381 |
ARABIC, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3382 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3383 |
ARABIC, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3384 |
SYRIAC, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3385 |
ARABIC, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3386 |
THAANA, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3387 |
NKO, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3388 |
SAMARITAN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3389 |
DEVANAGARI, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3390 |
INHERITED, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3391 |
DEVANAGARI, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3392 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3393 |
DEVANAGARI, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3394 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3395 |
DEVANAGARI, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3396 |
BENGALI, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3397 |
GURMUKHI, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3398 |
GUJARATI, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3399 |
ORIYA, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3400 |
TAMIL, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3401 |
TELUGU, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3402 |
KANNADA, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3403 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3404 |
MALAYALAM, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3405 |
SINHALA, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3406 |
THAI, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3407 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3408 |
THAI, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3409 |
LAO, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3410 |
TIBETAN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3411 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3412 |
MYANMAR, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3413 |
GEORGIAN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3414 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3415 |
GEORGIAN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3416 |
HANGUL, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3417 |
ETHIOPIC, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3418 |
CHEROKEE, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3419 |
CANADIAN_ABORIGINAL, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3420 |
OGHAM, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3421 |
RUNIC, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3422 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3423 |
RUNIC, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3424 |
TAGALOG, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3425 |
HANUNOO, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3426 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3427 |
BUHID, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3428 |
TAGBANWA, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3429 |
KHMER, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3430 |
MONGOLIAN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3431 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3432 |
MONGOLIAN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3433 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3434 |
MONGOLIAN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3435 |
CANADIAN_ABORIGINAL, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3436 |
LIMBU, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3437 |
TAI_LE, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3438 |
NEW_TAI_LUE, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3439 |
KHMER, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3440 |
BUGINESE, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3441 |
TAI_THAM, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3442 |
BALINESE, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3443 |
SUNDANESE, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3444 |
LEPCHA, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3445 |
OL_CHIKI, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3446 |
INHERITED, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3447 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3448 |
INHERITED, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3449 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3450 |
INHERITED, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3451 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3452 |
INHERITED, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3453 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3454 |
LATIN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3455 |
GREEK, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3456 |
CYRILLIC, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3457 |
LATIN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3458 |
GREEK, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3459 |
LATIN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3460 |
GREEK, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3461 |
LATIN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3462 |
CYRILLIC, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3463 |
LATIN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3464 |
GREEK, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3465 |
INHERITED, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3466 |
LATIN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3467 |
GREEK, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3468 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3469 |
INHERITED, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3470 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3471 |
LATIN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3472 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3473 |
LATIN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3474 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3475 |
LATIN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3476 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3477 |
INHERITED, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3478 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3479 |
GREEK, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3480 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3481 |
LATIN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3482 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3483 |
LATIN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3484 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3485 |
LATIN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3486 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3487 |
LATIN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3488 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3489 |
BRAILLE, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3490 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3491 |
GLAGOLITIC, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3492 |
LATIN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3493 |
COPTIC, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3494 |
GEORGIAN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3495 |
TIFINAGH, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3496 |
ETHIOPIC, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3497 |
CYRILLIC, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3498 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3499 |
HAN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3500 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3501 |
HAN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3502 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3503 |
HAN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3504 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3505 |
HAN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3506 |
INHERITED, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3507 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3508 |
HAN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3509 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3510 |
HIRAGANA, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3511 |
INHERITED, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3512 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3513 |
HIRAGANA, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3514 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3515 |
KATAKANA, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3516 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3517 |
KATAKANA, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3518 |
BOPOMOFO, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3519 |
HANGUL, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3520 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3521 |
BOPOMOFO, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3522 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3523 |
KATAKANA, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3524 |
HANGUL, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3525 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3526 |
HANGUL, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3527 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3528 |
KATAKANA, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3529 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3530 |
HAN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3531 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3532 |
HAN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3533 |
YI, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3534 |
LISU, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3535 |
VAI, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3536 |
CYRILLIC, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3537 |
BAMUM, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3538 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3539 |
LATIN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3540 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3541 |
LATIN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3542 |
SYLOTI_NAGRI, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3543 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3544 |
PHAGS_PA, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3545 |
SAURASHTRA, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3546 |
DEVANAGARI, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3547 |
KAYAH_LI, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3548 |
REJANG, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3549 |
HANGUL, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3550 |
JAVANESE, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3551 |
CHAM, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3552 |
MYANMAR, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3553 |
TAI_VIET, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3554 |
MEETEI_MAYEK, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3555 |
HANGUL, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3556 |
UNKNOWN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3557 |
HAN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3558 |
LATIN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3559 |
ARMENIAN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3560 |
HEBREW, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3561 |
ARABIC, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3562 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3563 |
ARABIC, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3564 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3565 |
INHERITED, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3566 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3567 |
INHERITED, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3568 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3569 |
ARABIC, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3570 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3571 |
LATIN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3572 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3573 |
LATIN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3574 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3575 |
KATAKANA, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3576 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3577 |
KATAKANA, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3578 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3579 |
HANGUL, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3580 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3581 |
LINEAR_B, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3582 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3583 |
GREEK, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3584 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3585 |
INHERITED, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3586 |
LYCIAN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3587 |
CARIAN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3588 |
OLD_ITALIC, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3589 |
GOTHIC, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3590 |
UGARITIC, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3591 |
OLD_PERSIAN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3592 |
DESERET, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3593 |
SHAVIAN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3594 |
OSMANYA, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3595 |
CYPRIOT, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3596 |
IMPERIAL_ARAMAIC, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3597 |
PHOENICIAN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3598 |
LYDIAN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3599 |
KHAROSHTHI, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3600 |
OLD_SOUTH_ARABIAN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3601 |
AVESTAN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3602 |
INSCRIPTIONAL_PARTHIAN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3603 |
INSCRIPTIONAL_PAHLAVI, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3604 |
OLD_TURKIC, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3605 |
ARABIC, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3606 |
KAITHI, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3607 |
CUNEIFORM, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3608 |
EGYPTIAN_HIEROGLYPHS, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3609 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3610 |
INHERITED, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3611 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3612 |
INHERITED, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3613 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3614 |
INHERITED, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3615 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3616 |
INHERITED, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3617 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3618 |
GREEK, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3619 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3620 |
HIRAGANA, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3621 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3622 |
HAN, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3623 |
COMMON, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3624 |
INHERITED, |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3625 |
UNKNOWN |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3626 |
}; |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3627 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3628 |
private static HashMap<String, Character.UnicodeScript> aliases; |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3629 |
static { |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3630 |
aliases = new HashMap<String, UnicodeScript>(); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3631 |
aliases.put("ARAB", ARABIC); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3632 |
aliases.put("ARMI", IMPERIAL_ARAMAIC); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3633 |
aliases.put("ARMN", ARMENIAN); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3634 |
aliases.put("AVST", AVESTAN); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3635 |
aliases.put("BALI", BALINESE); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3636 |
aliases.put("BAMU", BAMUM); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3637 |
aliases.put("BENG", BENGALI); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3638 |
aliases.put("BOPO", BOPOMOFO); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3639 |
aliases.put("BRAI", BRAILLE); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3640 |
aliases.put("BUGI", BUGINESE); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3641 |
aliases.put("BUHD", BUHID); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3642 |
aliases.put("CANS", CANADIAN_ABORIGINAL); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3643 |
aliases.put("CARI", CARIAN); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3644 |
aliases.put("CHAM", CHAM); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3645 |
aliases.put("CHER", CHEROKEE); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3646 |
aliases.put("COPT", COPTIC); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3647 |
aliases.put("CPRT", CYPRIOT); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3648 |
aliases.put("CYRL", CYRILLIC); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3649 |
aliases.put("DEVA", DEVANAGARI); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3650 |
aliases.put("DSRT", DESERET); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3651 |
aliases.put("EGYP", EGYPTIAN_HIEROGLYPHS); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3652 |
aliases.put("ETHI", ETHIOPIC); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3653 |
aliases.put("GEOR", GEORGIAN); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3654 |
aliases.put("GLAG", GLAGOLITIC); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3655 |
aliases.put("GOTH", GOTHIC); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3656 |
aliases.put("GREK", GREEK); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3657 |
aliases.put("GUJR", GUJARATI); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3658 |
aliases.put("GURU", GURMUKHI); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3659 |
aliases.put("HANG", HANGUL); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3660 |
aliases.put("HANI", HAN); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3661 |
aliases.put("HANO", HANUNOO); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3662 |
aliases.put("HEBR", HEBREW); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3663 |
aliases.put("HIRA", HIRAGANA); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3664 |
// it appears we don't have the KATAKANA_OR_HIRAGANA |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3665 |
//aliases.put("HRKT", KATAKANA_OR_HIRAGANA); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3666 |
aliases.put("ITAL", OLD_ITALIC); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3667 |
aliases.put("JAVA", JAVANESE); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3668 |
aliases.put("KALI", KAYAH_LI); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3669 |
aliases.put("KANA", KATAKANA); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3670 |
aliases.put("KHAR", KHAROSHTHI); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3671 |
aliases.put("KHMR", KHMER); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3672 |
aliases.put("KNDA", KANNADA); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3673 |
aliases.put("KTHI", KAITHI); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3674 |
aliases.put("LANA", TAI_THAM); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3675 |
aliases.put("LAOO", LAO); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3676 |
aliases.put("LATN", LATIN); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3677 |
aliases.put("LEPC", LEPCHA); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3678 |
aliases.put("LIMB", LIMBU); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3679 |
aliases.put("LINB", LINEAR_B); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3680 |
aliases.put("LISU", LISU); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3681 |
aliases.put("LYCI", LYCIAN); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3682 |
aliases.put("LYDI", LYDIAN); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3683 |
aliases.put("MLYM", MALAYALAM); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3684 |
aliases.put("MONG", MONGOLIAN); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3685 |
aliases.put("MTEI", MEETEI_MAYEK); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3686 |
aliases.put("MYMR", MYANMAR); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3687 |
aliases.put("NKOO", NKO); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3688 |
aliases.put("OGAM", OGHAM); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3689 |
aliases.put("OLCK", OL_CHIKI); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3690 |
aliases.put("ORKH", OLD_TURKIC); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3691 |
aliases.put("ORYA", ORIYA); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3692 |
aliases.put("OSMA", OSMANYA); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3693 |
aliases.put("PHAG", PHAGS_PA); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3694 |
aliases.put("PHLI", INSCRIPTIONAL_PAHLAVI); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3695 |
aliases.put("PHNX", PHOENICIAN); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3696 |
aliases.put("PRTI", INSCRIPTIONAL_PARTHIAN); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3697 |
aliases.put("RJNG", REJANG); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3698 |
aliases.put("RUNR", RUNIC); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3699 |
aliases.put("SAMR", SAMARITAN); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3700 |
aliases.put("SARB", OLD_SOUTH_ARABIAN); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3701 |
aliases.put("SAUR", SAURASHTRA); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3702 |
aliases.put("SHAW", SHAVIAN); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3703 |
aliases.put("SINH", SINHALA); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3704 |
aliases.put("SUND", SUNDANESE); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3705 |
aliases.put("SYLO", SYLOTI_NAGRI); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3706 |
aliases.put("SYRC", SYRIAC); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3707 |
aliases.put("TAGB", TAGBANWA); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3708 |
aliases.put("TALE", TAI_LE); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3709 |
aliases.put("TALU", NEW_TAI_LUE); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3710 |
aliases.put("TAML", TAMIL); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3711 |
aliases.put("TAVT", TAI_VIET); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3712 |
aliases.put("TELU", TELUGU); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3713 |
aliases.put("TFNG", TIFINAGH); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3714 |
aliases.put("TGLG", TAGALOG); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3715 |
aliases.put("THAA", THAANA); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3716 |
aliases.put("THAI", THAI); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3717 |
aliases.put("TIBT", TIBETAN); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3718 |
aliases.put("UGAR", UGARITIC); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3719 |
aliases.put("VAII", VAI); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3720 |
aliases.put("XPEO", OLD_PERSIAN); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3721 |
aliases.put("XSUX", CUNEIFORM); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3722 |
aliases.put("YIII", YI); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3723 |
aliases.put("ZINH", INHERITED); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3724 |
aliases.put("ZYYY", COMMON); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3725 |
aliases.put("ZZZZ", UNKNOWN); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3726 |
} |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3727 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3728 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3729 |
* Returns the enum constant representing the Unicode script of which |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3730 |
* the given character (Unicode code point) is assigned to. |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3731 |
* |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3732 |
* @param codePoint the character (Unicode code point) in question. |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3733 |
* @return The <code>UnicodeScript</code> constant representing the |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3734 |
* Unicode script of which this character is assigned to. |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3735 |
* |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3736 |
* @exception IllegalArgumentException if the specified |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3737 |
* <code>codePoint</code> is an invalid Unicode code point. |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3738 |
* @see Character#isValidCodePoint(int) |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3739 |
* |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3740 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3741 |
public static UnicodeScript of(int codePoint) { |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3742 |
if (!isValidCodePoint(codePoint)) |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3743 |
throw new IllegalArgumentException(); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3744 |
int type = getType(codePoint); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3745 |
// leave SURROGATE and PRIVATE_USE for table lookup |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3746 |
if (type == UNASSIGNED) |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3747 |
return UNKNOWN; |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3748 |
int index = Arrays.binarySearch(scriptStarts, codePoint); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3749 |
if (index < 0) |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3750 |
index = -index - 2; |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3751 |
return scripts[index]; |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3752 |
} |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3753 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3754 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3755 |
* Returns the UnicodeScript constant with the given Unicode script |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3756 |
* name or the script name alias. Script names and their aliases are |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3757 |
* determined by The Unicode Standard. The files Scripts<version>.txt |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3758 |
* and PropertyValueAliases<version>.txt define script names |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3759 |
* and the script name aliases for a particular version of the |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3760 |
* standard. The {@link Character} class specifies the version of |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3761 |
* the standard that it supports. |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3762 |
* <p> |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3763 |
* Character case is ignored for all of the valid script names. |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3764 |
* The en_US locale's case mapping rules are used to provide |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3765 |
* case-insensitive string comparisons for script name validation. |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3766 |
* <p> |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3767 |
* |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3768 |
* @param scriptName A <code>UnicodeScript</code> name. |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3769 |
* @return The <code>UnicodeScript</code> constant identified |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3770 |
* by <code>scriptName</code> |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3771 |
* @throws IllegalArgumentException if <code>scriptName</code> is an |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3772 |
* invalid name |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3773 |
* @throws NullPointerException if <code>scriptName</code> is null |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3774 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3775 |
public static final UnicodeScript forName(String scriptName) { |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3776 |
scriptName = scriptName.toUpperCase(Locale.ENGLISH); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3777 |
//.replace(' ', '_')); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3778 |
UnicodeScript sc = aliases.get(scriptName); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3779 |
if (sc != null) |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3780 |
return sc; |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3781 |
return valueOf(scriptName); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3782 |
} |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3783 |
} |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3784 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
3785 |
/** |
2 | 3786 |
* The value of the <code>Character</code>. |
3787 |
* |
|
3788 |
* @serial |
|
3789 |
*/ |
|
3790 |
private final char value; |
|
3791 |
||
3792 |
/** use serialVersionUID from JDK 1.0.2 for interoperability */ |
|
3793 |
private static final long serialVersionUID = 3786198910865385080L; |
|
3794 |
||
3795 |
/** |
|
3796 |
* Constructs a newly allocated <code>Character</code> object that |
|
3797 |
* represents the specified <code>char</code> value. |
|
3798 |
* |
|
3799 |
* @param value the value to be represented by the |
|
3800 |
* <code>Character</code> object. |
|
3801 |
*/ |
|
3802 |
public Character(char value) { |
|
3803 |
this.value = value; |
|
3804 |
} |
|
3805 |
||
3806 |
private static class CharacterCache { |
|
3807 |
private CharacterCache(){} |
|
3808 |
||
3809 |
static final Character cache[] = new Character[127 + 1]; |
|
3810 |
||
3811 |
static { |
|
3812 |
for(int i = 0; i < cache.length; i++) |
|
3813 |
cache[i] = new Character((char)i); |
|
3814 |
} |
|
3815 |
} |
|
3816 |
||
3817 |
/** |
|
3818 |
* Returns a <tt>Character</tt> instance representing the specified |
|
3819 |
* <tt>char</tt> value. |
|
3820 |
* If a new <tt>Character</tt> instance is not required, this method |
|
3821 |
* should generally be used in preference to the constructor |
|
3822 |
* {@link #Character(char)}, as this method is likely to yield |
|
3823 |
* significantly better space and time performance by caching |
|
3824 |
* frequently requested values. |
|
3825 |
* |
|
3719 | 3826 |
* This method will always cache values in the range {@code |
3827 |
* '\u005Cu0000'} to {@code '\u005Cu007f'}, inclusive, and may |
|
3828 |
* cache other values outside of this range. |
|
3224
3aa65803ae07
6628737: Specification of wrapper class valueOf static factories should require caching
darcy
parents:
2497
diff
changeset
|
3829 |
* |
2 | 3830 |
* @param c a char value. |
3831 |
* @return a <tt>Character</tt> instance representing <tt>c</tt>. |
|
3832 |
* @since 1.5 |
|
3833 |
*/ |
|
3834 |
public static Character valueOf(char c) { |
|
3835 |
if(c <= 127) { // must cache |
|
3836 |
return CharacterCache.cache[(int)c]; |
|
3837 |
} |
|
3838 |
return new Character(c); |
|
3839 |
} |
|
3840 |
||
3841 |
/** |
|
3842 |
* Returns the value of this <code>Character</code> object. |
|
3843 |
* @return the primitive <code>char</code> value represented by |
|
3844 |
* this object. |
|
3845 |
*/ |
|
3846 |
public char charValue() { |
|
3847 |
return value; |
|
3848 |
} |
|
3849 |
||
3850 |
/** |
|
3942
685e04a98396
4245470: algorithm of java.lang.Byte.hashCode() is not specified
martin
parents:
3719
diff
changeset
|
3851 |
* Returns a hash code for this {@code Character}; equal to the result |
685e04a98396
4245470: algorithm of java.lang.Byte.hashCode() is not specified
martin
parents:
3719
diff
changeset
|
3852 |
* of invoking {@code charValue()}. |
685e04a98396
4245470: algorithm of java.lang.Byte.hashCode() is not specified
martin
parents:
3719
diff
changeset
|
3853 |
* |
685e04a98396
4245470: algorithm of java.lang.Byte.hashCode() is not specified
martin
parents:
3719
diff
changeset
|
3854 |
* @return a hash code value for this {@code Character} |
2 | 3855 |
*/ |
3856 |
public int hashCode() { |
|
3857 |
return (int)value; |
|
3858 |
} |
|
3859 |
||
3860 |
/** |
|
3861 |
* Compares this object against the specified object. |
|
3862 |
* The result is <code>true</code> if and only if the argument is not |
|
3863 |
* <code>null</code> and is a <code>Character</code> object that |
|
3864 |
* represents the same <code>char</code> value as this object. |
|
3865 |
* |
|
3866 |
* @param obj the object to compare with. |
|
3867 |
* @return <code>true</code> if the objects are the same; |
|
3868 |
* <code>false</code> otherwise. |
|
3869 |
*/ |
|
3870 |
public boolean equals(Object obj) { |
|
3871 |
if (obj instanceof Character) { |
|
3872 |
return value == ((Character)obj).charValue(); |
|
3873 |
} |
|
3874 |
return false; |
|
3875 |
} |
|
3876 |
||
3877 |
/** |
|
3878 |
* Returns a <code>String</code> object representing this |
|
3879 |
* <code>Character</code>'s value. The result is a string of |
|
3880 |
* length 1 whose sole component is the primitive |
|
3881 |
* <code>char</code> value represented by this |
|
3882 |
* <code>Character</code> object. |
|
3883 |
* |
|
3884 |
* @return a string representation of this object. |
|
3885 |
*/ |
|
3886 |
public String toString() { |
|
3887 |
char buf[] = {value}; |
|
3888 |
return String.valueOf(buf); |
|
3889 |
} |
|
3890 |
||
3891 |
/** |
|
3892 |
* Returns a <code>String</code> object representing the |
|
3893 |
* specified <code>char</code>. The result is a string of length |
|
3894 |
* 1 consisting solely of the specified <code>char</code>. |
|
3895 |
* |
|
3896 |
* @param c the <code>char</code> to be converted |
|
3897 |
* @return the string representation of the specified <code>char</code> |
|
3898 |
* @since 1.4 |
|
3899 |
*/ |
|
3900 |
public static String toString(char c) { |
|
3901 |
return String.valueOf(c); |
|
3902 |
} |
|
3903 |
||
3904 |
/** |
|
3714 | 3905 |
* Determines whether the specified code point is a valid |
3906 |
* <a href="http://www.unicode.org/glossary/#code_point"> |
|
3907 |
* Unicode code point value</a>. |
|
2 | 3908 |
* |
3909 |
* @param codePoint the Unicode code point to be tested |
|
3714 | 3910 |
* @return {@code true} if the specified code point value is between |
3911 |
* {@link #MIN_CODE_POINT} and |
|
3912 |
* {@link #MAX_CODE_POINT} inclusive; |
|
3913 |
* {@code false} otherwise. |
|
2 | 3914 |
* @since 1.5 |
3915 |
*/ |
|
3916 |
public static boolean isValidCodePoint(int codePoint) { |
|
3917 |
return codePoint >= MIN_CODE_POINT && codePoint <= MAX_CODE_POINT; |
|
3918 |
} |
|
3919 |
||
3920 |
/** |
|
3921 |
* Determines whether the specified character (Unicode code point) |
|
3714 | 3922 |
* is in the <a href="#supplementary">supplementary character</a> range. |
2 | 3923 |
* |
3924 |
* @param codePoint the character (Unicode code point) to be tested |
|
3714 | 3925 |
* @return {@code true} if the specified code point is between |
3926 |
* {@link #MIN_SUPPLEMENTARY_CODE_POINT} and |
|
3927 |
* {@link #MAX_CODE_POINT} inclusive; |
|
3928 |
* {@code false} otherwise. |
|
2 | 3929 |
* @since 1.5 |
3930 |
*/ |
|
3931 |
public static boolean isSupplementaryCodePoint(int codePoint) { |
|
3932 |
return codePoint >= MIN_SUPPLEMENTARY_CODE_POINT |
|
3933 |
&& codePoint <= MAX_CODE_POINT; |
|
3934 |
} |
|
3935 |
||
3936 |
/** |
|
3714 | 3937 |
* Determines if the given {@code char} value is a |
3938 |
* <a href="http://www.unicode.org/glossary/#high_surrogate_code_unit"> |
|
3939 |
* Unicode high-surrogate code unit</a> |
|
3940 |
* (also known as <i>leading-surrogate code unit</i>). |
|
2 | 3941 |
* |
3714 | 3942 |
* <p>Such values do not represent characters by themselves, |
3943 |
* but are used in the representation of |
|
3944 |
* <a href="#supplementary">supplementary characters</a> |
|
3945 |
* in the UTF-16 encoding. |
|
2 | 3946 |
* |
3714 | 3947 |
* @param ch the {@code char} value to be tested. |
3948 |
* @return {@code true} if the {@code char} value is between |
|
3949 |
* {@link #MIN_HIGH_SURROGATE} and |
|
3950 |
* {@link #MAX_HIGH_SURROGATE} inclusive; |
|
3951 |
* {@code false} otherwise. |
|
3952 |
* @see #isLowSurrogate(char) |
|
3953 |
* @see Character.UnicodeBlock#of(int) |
|
3954 |
* @since 1.5 |
|
2 | 3955 |
*/ |
3956 |
public static boolean isHighSurrogate(char ch) { |
|
3957 |
return ch >= MIN_HIGH_SURROGATE && ch <= MAX_HIGH_SURROGATE; |
|
3958 |
} |
|
3959 |
||
3960 |
/** |
|
3714 | 3961 |
* Determines if the given {@code char} value is a |
3962 |
* <a href="http://www.unicode.org/glossary/#low_surrogate_code_unit"> |
|
3963 |
* Unicode low-surrogate code unit</a> |
|
3964 |
* (also known as <i>trailing-surrogate code unit</i>). |
|
2 | 3965 |
* |
3714 | 3966 |
* <p>Such values do not represent characters by themselves, |
3967 |
* but are used in the representation of |
|
3968 |
* <a href="#supplementary">supplementary characters</a> |
|
3969 |
* in the UTF-16 encoding. |
|
2 | 3970 |
* |
3714 | 3971 |
* @param ch the {@code char} value to be tested. |
3972 |
* @return {@code true} if the {@code char} value is between |
|
3973 |
* {@link #MIN_LOW_SURROGATE} and |
|
3974 |
* {@link #MAX_LOW_SURROGATE} inclusive; |
|
3975 |
* {@code false} otherwise. |
|
3976 |
* @see #isHighSurrogate(char) |
|
3977 |
* @since 1.5 |
|
2 | 3978 |
*/ |
3979 |
public static boolean isLowSurrogate(char ch) { |
|
3980 |
return ch >= MIN_LOW_SURROGATE && ch <= MAX_LOW_SURROGATE; |
|
3981 |
} |
|
3982 |
||
3983 |
/** |
|
3714 | 3984 |
* Determines if the given {@code char} value is a Unicode |
3985 |
* <i>surrogate code unit</i>. |
|
3986 |
* |
|
3987 |
* <p>Such values do not represent characters by themselves, |
|
3988 |
* but are used in the representation of |
|
3989 |
* <a href="#supplementary">supplementary characters</a> |
|
3990 |
* in the UTF-16 encoding. |
|
3991 |
* |
|
3992 |
* <p>A char value is a surrogate code unit if and only if it is either |
|
3993 |
* a {@linkplain #isLowSurrogate(char) low-surrogate code unit} or |
|
3994 |
* a {@linkplain #isHighSurrogate(char) high-surrogate code unit}. |
|
3995 |
* |
|
3996 |
* @param ch the {@code char} value to be tested. |
|
3997 |
* @return {@code true} if the {@code char} value is between |
|
3998 |
* {@link #MIN_SURROGATE} and |
|
3999 |
* {@link #MAX_SURROGATE} inclusive; |
|
4000 |
* {@code false} otherwise. |
|
4001 |
* @since 1.7 |
|
4002 |
*/ |
|
4003 |
public static boolean isSurrogate(char ch) { |
|
4004 |
return ch >= MIN_SURROGATE && ch <= MAX_SURROGATE; |
|
4005 |
} |
|
4006 |
||
4007 |
/** |
|
2 | 4008 |
* Determines whether the specified pair of <code>char</code> |
3714 | 4009 |
* values is a valid |
4010 |
* <a href="http://www.unicode.org/glossary/#surrogate_pair"> |
|
4011 |
* Unicode surrogate pair</a>. |
|
4012 |
||
4013 |
* <p>This method is equivalent to the expression: |
|
2 | 4014 |
* <blockquote><pre> |
4015 |
* isHighSurrogate(high) && isLowSurrogate(low) |
|
4016 |
* </pre></blockquote> |
|
4017 |
* |
|
4018 |
* @param high the high-surrogate code value to be tested |
|
4019 |
* @param low the low-surrogate code value to be tested |
|
4020 |
* @return <code>true</code> if the specified high and |
|
4021 |
* low-surrogate code values represent a valid surrogate pair; |
|
4022 |
* <code>false</code> otherwise. |
|
4023 |
* @since 1.5 |
|
4024 |
*/ |
|
4025 |
public static boolean isSurrogatePair(char high, char low) { |
|
4026 |
return isHighSurrogate(high) && isLowSurrogate(low); |
|
4027 |
} |
|
4028 |
||
4029 |
/** |
|
4030 |
* Determines the number of <code>char</code> values needed to |
|
4031 |
* represent the specified character (Unicode code point). If the |
|
4032 |
* specified character is equal to or greater than 0x10000, then |
|
4033 |
* the method returns 2. Otherwise, the method returns 1. |
|
4034 |
* |
|
4035 |
* <p>This method doesn't validate the specified character to be a |
|
4036 |
* valid Unicode code point. The caller must validate the |
|
4037 |
* character value using {@link #isValidCodePoint(int) isValidCodePoint} |
|
4038 |
* if necessary. |
|
4039 |
* |
|
4040 |
* @param codePoint the character (Unicode code point) to be tested. |
|
4041 |
* @return 2 if the character is a valid supplementary character; 1 otherwise. |
|
4042 |
* @see #isSupplementaryCodePoint(int) |
|
4043 |
* @since 1.5 |
|
4044 |
*/ |
|
4045 |
public static int charCount(int codePoint) { |
|
4046 |
return codePoint >= MIN_SUPPLEMENTARY_CODE_POINT? 2 : 1; |
|
4047 |
} |
|
4048 |
||
4049 |
/** |
|
4050 |
* Converts the specified surrogate pair to its supplementary code |
|
4051 |
* point value. This method does not validate the specified |
|
4052 |
* surrogate pair. The caller must validate it using {@link |
|
4053 |
* #isSurrogatePair(char, char) isSurrogatePair} if necessary. |
|
4054 |
* |
|
4055 |
* @param high the high-surrogate code unit |
|
4056 |
* @param low the low-surrogate code unit |
|
4057 |
* @return the supplementary code point composed from the |
|
4058 |
* specified surrogate pair. |
|
4059 |
* @since 1.5 |
|
4060 |
*/ |
|
4061 |
public static int toCodePoint(char high, char low) { |
|
3323
29b6893c6188
6639443: Character.toCodePoint and Character.toSurrogates can be optimized
martin
parents:
3224
diff
changeset
|
4062 |
// Optimized form of: |
29b6893c6188
6639443: Character.toCodePoint and Character.toSurrogates can be optimized
martin
parents:
3224
diff
changeset
|
4063 |
// return ((high - MIN_HIGH_SURROGATE) << 10) |
29b6893c6188
6639443: Character.toCodePoint and Character.toSurrogates can be optimized
martin
parents:
3224
diff
changeset
|
4064 |
// + (low - MIN_LOW_SURROGATE) |
29b6893c6188
6639443: Character.toCodePoint and Character.toSurrogates can be optimized
martin
parents:
3224
diff
changeset
|
4065 |
// + MIN_SUPPLEMENTARY_CODE_POINT; |
29b6893c6188
6639443: Character.toCodePoint and Character.toSurrogates can be optimized
martin
parents:
3224
diff
changeset
|
4066 |
return ((high << 10) + low) + (MIN_SUPPLEMENTARY_CODE_POINT |
29b6893c6188
6639443: Character.toCodePoint and Character.toSurrogates can be optimized
martin
parents:
3224
diff
changeset
|
4067 |
- (MIN_HIGH_SURROGATE << 10) |
29b6893c6188
6639443: Character.toCodePoint and Character.toSurrogates can be optimized
martin
parents:
3224
diff
changeset
|
4068 |
- MIN_LOW_SURROGATE); |
2 | 4069 |
} |
4070 |
||
4071 |
/** |
|
4072 |
* Returns the code point at the given index of the |
|
4073 |
* <code>CharSequence</code>. If the <code>char</code> value at |
|
4074 |
* the given index in the <code>CharSequence</code> is in the |
|
4075 |
* high-surrogate range, the following index is less than the |
|
4076 |
* length of the <code>CharSequence</code>, and the |
|
4077 |
* <code>char</code> value at the following index is in the |
|
4078 |
* low-surrogate range, then the supplementary code point |
|
4079 |
* corresponding to this surrogate pair is returned. Otherwise, |
|
4080 |
* the <code>char</code> value at the given index is returned. |
|
4081 |
* |
|
4082 |
* @param seq a sequence of <code>char</code> values (Unicode code |
|
4083 |
* units) |
|
4084 |
* @param index the index to the <code>char</code> values (Unicode |
|
4085 |
* code units) in <code>seq</code> to be converted |
|
4086 |
* @return the Unicode code point at the given index |
|
4087 |
* @exception NullPointerException if <code>seq</code> is null. |
|
4088 |
* @exception IndexOutOfBoundsException if the value |
|
4089 |
* <code>index</code> is negative or not less than |
|
4090 |
* {@link CharSequence#length() seq.length()}. |
|
4091 |
* @since 1.5 |
|
4092 |
*/ |
|
4093 |
public static int codePointAt(CharSequence seq, int index) { |
|
4094 |
char c1 = seq.charAt(index++); |
|
4095 |
if (isHighSurrogate(c1)) { |
|
4096 |
if (index < seq.length()) { |
|
4097 |
char c2 = seq.charAt(index); |
|
4098 |
if (isLowSurrogate(c2)) { |
|
4099 |
return toCodePoint(c1, c2); |
|
4100 |
} |
|
4101 |
} |
|
4102 |
} |
|
4103 |
return c1; |
|
4104 |
} |
|
4105 |
||
4106 |
/** |
|
4107 |
* Returns the code point at the given index of the |
|
4108 |
* <code>char</code> array. If the <code>char</code> value at |
|
4109 |
* the given index in the <code>char</code> array is in the |
|
4110 |
* high-surrogate range, the following index is less than the |
|
4111 |
* length of the <code>char</code> array, and the |
|
4112 |
* <code>char</code> value at the following index is in the |
|
4113 |
* low-surrogate range, then the supplementary code point |
|
4114 |
* corresponding to this surrogate pair is returned. Otherwise, |
|
4115 |
* the <code>char</code> value at the given index is returned. |
|
4116 |
* |
|
4117 |
* @param a the <code>char</code> array |
|
4118 |
* @param index the index to the <code>char</code> values (Unicode |
|
4119 |
* code units) in the <code>char</code> array to be converted |
|
4120 |
* @return the Unicode code point at the given index |
|
4121 |
* @exception NullPointerException if <code>a</code> is null. |
|
4122 |
* @exception IndexOutOfBoundsException if the value |
|
4123 |
* <code>index</code> is negative or not less than |
|
4124 |
* the length of the <code>char</code> array. |
|
4125 |
* @since 1.5 |
|
4126 |
*/ |
|
4127 |
public static int codePointAt(char[] a, int index) { |
|
4128 |
return codePointAtImpl(a, index, a.length); |
|
4129 |
} |
|
4130 |
||
4131 |
/** |
|
4132 |
* Returns the code point at the given index of the |
|
4133 |
* <code>char</code> array, where only array elements with |
|
4134 |
* <code>index</code> less than <code>limit</code> can be used. If |
|
4135 |
* the <code>char</code> value at the given index in the |
|
4136 |
* <code>char</code> array is in the high-surrogate range, the |
|
4137 |
* following index is less than the <code>limit</code>, and the |
|
4138 |
* <code>char</code> value at the following index is in the |
|
4139 |
* low-surrogate range, then the supplementary code point |
|
4140 |
* corresponding to this surrogate pair is returned. Otherwise, |
|
4141 |
* the <code>char</code> value at the given index is returned. |
|
4142 |
* |
|
4143 |
* @param a the <code>char</code> array |
|
4144 |
* @param index the index to the <code>char</code> values (Unicode |
|
4145 |
* code units) in the <code>char</code> array to be converted |
|
4146 |
* @param limit the index after the last array element that can be used in the |
|
4147 |
* <code>char</code> array |
|
4148 |
* @return the Unicode code point at the given index |
|
4149 |
* @exception NullPointerException if <code>a</code> is null. |
|
4150 |
* @exception IndexOutOfBoundsException if the <code>index</code> |
|
4151 |
* argument is negative or not less than the <code>limit</code> |
|
4152 |
* argument, or if the <code>limit</code> argument is negative or |
|
4153 |
* greater than the length of the <code>char</code> array. |
|
4154 |
* @since 1.5 |
|
4155 |
*/ |
|
4156 |
public static int codePointAt(char[] a, int index, int limit) { |
|
4157 |
if (index >= limit || limit < 0 || limit > a.length) { |
|
4158 |
throw new IndexOutOfBoundsException(); |
|
4159 |
} |
|
4160 |
return codePointAtImpl(a, index, limit); |
|
4161 |
} |
|
4162 |
||
4163 |
static int codePointAtImpl(char[] a, int index, int limit) { |
|
4164 |
char c1 = a[index++]; |
|
4165 |
if (isHighSurrogate(c1)) { |
|
4166 |
if (index < limit) { |
|
4167 |
char c2 = a[index]; |
|
4168 |
if (isLowSurrogate(c2)) { |
|
4169 |
return toCodePoint(c1, c2); |
|
4170 |
} |
|
4171 |
} |
|
4172 |
} |
|
4173 |
return c1; |
|
4174 |
} |
|
4175 |
||
4176 |
/** |
|
4177 |
* Returns the code point preceding the given index of the |
|
4178 |
* <code>CharSequence</code>. If the <code>char</code> value at |
|
4179 |
* <code>(index - 1)</code> in the <code>CharSequence</code> is in |
|
4180 |
* the low-surrogate range, <code>(index - 2)</code> is not |
|
4181 |
* negative, and the <code>char</code> value at <code>(index - |
|
4182 |
* 2)</code> in the <code>CharSequence</code> is in the |
|
4183 |
* high-surrogate range, then the supplementary code point |
|
4184 |
* corresponding to this surrogate pair is returned. Otherwise, |
|
4185 |
* the <code>char</code> value at <code>(index - 1)</code> is |
|
4186 |
* returned. |
|
4187 |
* |
|
4188 |
* @param seq the <code>CharSequence</code> instance |
|
4189 |
* @param index the index following the code point that should be returned |
|
4190 |
* @return the Unicode code point value before the given index. |
|
4191 |
* @exception NullPointerException if <code>seq</code> is null. |
|
4192 |
* @exception IndexOutOfBoundsException if the <code>index</code> |
|
4193 |
* argument is less than 1 or greater than {@link |
|
4194 |
* CharSequence#length() seq.length()}. |
|
4195 |
* @since 1.5 |
|
4196 |
*/ |
|
4197 |
public static int codePointBefore(CharSequence seq, int index) { |
|
4198 |
char c2 = seq.charAt(--index); |
|
4199 |
if (isLowSurrogate(c2)) { |
|
4200 |
if (index > 0) { |
|
4201 |
char c1 = seq.charAt(--index); |
|
4202 |
if (isHighSurrogate(c1)) { |
|
4203 |
return toCodePoint(c1, c2); |
|
4204 |
} |
|
4205 |
} |
|
4206 |
} |
|
4207 |
return c2; |
|
4208 |
} |
|
4209 |
||
4210 |
/** |
|
4211 |
* Returns the code point preceding the given index of the |
|
4212 |
* <code>char</code> array. If the <code>char</code> value at |
|
4213 |
* <code>(index - 1)</code> in the <code>char</code> array is in |
|
4214 |
* the low-surrogate range, <code>(index - 2)</code> is not |
|
4215 |
* negative, and the <code>char</code> value at <code>(index - |
|
4216 |
* 2)</code> in the <code>char</code> array is in the |
|
4217 |
* high-surrogate range, then the supplementary code point |
|
4218 |
* corresponding to this surrogate pair is returned. Otherwise, |
|
4219 |
* the <code>char</code> value at <code>(index - 1)</code> is |
|
4220 |
* returned. |
|
4221 |
* |
|
4222 |
* @param a the <code>char</code> array |
|
4223 |
* @param index the index following the code point that should be returned |
|
4224 |
* @return the Unicode code point value before the given index. |
|
4225 |
* @exception NullPointerException if <code>a</code> is null. |
|
4226 |
* @exception IndexOutOfBoundsException if the <code>index</code> |
|
4227 |
* argument is less than 1 or greater than the length of the |
|
4228 |
* <code>char</code> array |
|
4229 |
* @since 1.5 |
|
4230 |
*/ |
|
4231 |
public static int codePointBefore(char[] a, int index) { |
|
4232 |
return codePointBeforeImpl(a, index, 0); |
|
4233 |
} |
|
4234 |
||
4235 |
/** |
|
4236 |
* Returns the code point preceding the given index of the |
|
4237 |
* <code>char</code> array, where only array elements with |
|
4238 |
* <code>index</code> greater than or equal to <code>start</code> |
|
4239 |
* can be used. If the <code>char</code> value at <code>(index - |
|
4240 |
* 1)</code> in the <code>char</code> array is in the |
|
4241 |
* low-surrogate range, <code>(index - 2)</code> is not less than |
|
4242 |
* <code>start</code>, and the <code>char</code> value at |
|
4243 |
* <code>(index - 2)</code> in the <code>char</code> array is in |
|
4244 |
* the high-surrogate range, then the supplementary code point |
|
4245 |
* corresponding to this surrogate pair is returned. Otherwise, |
|
4246 |
* the <code>char</code> value at <code>(index - 1)</code> is |
|
4247 |
* returned. |
|
4248 |
* |
|
4249 |
* @param a the <code>char</code> array |
|
4250 |
* @param index the index following the code point that should be returned |
|
4251 |
* @param start the index of the first array element in the |
|
4252 |
* <code>char</code> array |
|
4253 |
* @return the Unicode code point value before the given index. |
|
4254 |
* @exception NullPointerException if <code>a</code> is null. |
|
4255 |
* @exception IndexOutOfBoundsException if the <code>index</code> |
|
4256 |
* argument is not greater than the <code>start</code> argument or |
|
4257 |
* is greater than the length of the <code>char</code> array, or |
|
4258 |
* if the <code>start</code> argument is negative or not less than |
|
4259 |
* the length of the <code>char</code> array. |
|
4260 |
* @since 1.5 |
|
4261 |
*/ |
|
4262 |
public static int codePointBefore(char[] a, int index, int start) { |
|
4263 |
if (index <= start || start < 0 || start >= a.length) { |
|
4264 |
throw new IndexOutOfBoundsException(); |
|
4265 |
} |
|
4266 |
return codePointBeforeImpl(a, index, start); |
|
4267 |
} |
|
4268 |
||
4269 |
static int codePointBeforeImpl(char[] a, int index, int start) { |
|
4270 |
char c2 = a[--index]; |
|
4271 |
if (isLowSurrogate(c2)) { |
|
4272 |
if (index > start) { |
|
4273 |
char c1 = a[--index]; |
|
4274 |
if (isHighSurrogate(c1)) { |
|
4275 |
return toCodePoint(c1, c2); |
|
4276 |
} |
|
4277 |
} |
|
4278 |
} |
|
4279 |
return c2; |
|
4280 |
} |
|
4281 |
||
4282 |
/** |
|
4283 |
* Converts the specified character (Unicode code point) to its |
|
4284 |
* UTF-16 representation. If the specified code point is a BMP |
|
4285 |
* (Basic Multilingual Plane or Plane 0) value, the same value is |
|
4286 |
* stored in <code>dst[dstIndex]</code>, and 1 is returned. If the |
|
4287 |
* specified code point is a supplementary character, its |
|
4288 |
* surrogate values are stored in <code>dst[dstIndex]</code> |
|
4289 |
* (high-surrogate) and <code>dst[dstIndex+1]</code> |
|
4290 |
* (low-surrogate), and 2 is returned. |
|
4291 |
* |
|
4292 |
* @param codePoint the character (Unicode code point) to be converted. |
|
4293 |
* @param dst an array of <code>char</code> in which the |
|
4294 |
* <code>codePoint</code>'s UTF-16 value is stored. |
|
4295 |
* @param dstIndex the start index into the <code>dst</code> |
|
4296 |
* array where the converted value is stored. |
|
4297 |
* @return 1 if the code point is a BMP code point, 2 if the |
|
4298 |
* code point is a supplementary code point. |
|
4299 |
* @exception IllegalArgumentException if the specified |
|
4300 |
* <code>codePoint</code> is not a valid Unicode code point. |
|
4301 |
* @exception NullPointerException if the specified <code>dst</code> is null. |
|
4302 |
* @exception IndexOutOfBoundsException if <code>dstIndex</code> |
|
4303 |
* is negative or not less than <code>dst.length</code>, or if |
|
4304 |
* <code>dst</code> at <code>dstIndex</code> doesn't have enough |
|
4305 |
* array element(s) to store the resulting <code>char</code> |
|
4306 |
* value(s). (If <code>dstIndex</code> is equal to |
|
4307 |
* <code>dst.length-1</code> and the specified |
|
4308 |
* <code>codePoint</code> is a supplementary character, the |
|
4309 |
* high-surrogate value is not stored in |
|
4310 |
* <code>dst[dstIndex]</code>.) |
|
4311 |
* @since 1.5 |
|
4312 |
*/ |
|
4313 |
public static int toChars(int codePoint, char[] dst, int dstIndex) { |
|
4314 |
if (codePoint < 0 || codePoint > MAX_CODE_POINT) { |
|
4315 |
throw new IllegalArgumentException(); |
|
4316 |
} |
|
4317 |
if (codePoint < MIN_SUPPLEMENTARY_CODE_POINT) { |
|
4318 |
dst[dstIndex] = (char) codePoint; |
|
4319 |
return 1; |
|
4320 |
} |
|
4321 |
toSurrogates(codePoint, dst, dstIndex); |
|
4322 |
return 2; |
|
4323 |
} |
|
4324 |
||
4325 |
/** |
|
4326 |
* Converts the specified character (Unicode code point) to its |
|
4327 |
* UTF-16 representation stored in a <code>char</code> array. If |
|
4328 |
* the specified code point is a BMP (Basic Multilingual Plane or |
|
4329 |
* Plane 0) value, the resulting <code>char</code> array has |
|
4330 |
* the same value as <code>codePoint</code>. If the specified code |
|
4331 |
* point is a supplementary code point, the resulting |
|
4332 |
* <code>char</code> array has the corresponding surrogate pair. |
|
4333 |
* |
|
4334 |
* @param codePoint a Unicode code point |
|
4335 |
* @return a <code>char</code> array having |
|
4336 |
* <code>codePoint</code>'s UTF-16 representation. |
|
4337 |
* @exception IllegalArgumentException if the specified |
|
4338 |
* <code>codePoint</code> is not a valid Unicode code point. |
|
4339 |
* @since 1.5 |
|
4340 |
*/ |
|
4341 |
public static char[] toChars(int codePoint) { |
|
4342 |
if (codePoint < 0 || codePoint > MAX_CODE_POINT) { |
|
4343 |
throw new IllegalArgumentException(); |
|
4344 |
} |
|
4345 |
if (codePoint < MIN_SUPPLEMENTARY_CODE_POINT) { |
|
4346 |
return new char[] { (char) codePoint }; |
|
4347 |
} |
|
4348 |
char[] result = new char[2]; |
|
4349 |
toSurrogates(codePoint, result, 0); |
|
4350 |
return result; |
|
4351 |
} |
|
4352 |
||
4353 |
static void toSurrogates(int codePoint, char[] dst, int index) { |
|
3323
29b6893c6188
6639443: Character.toCodePoint and Character.toSurrogates can be optimized
martin
parents:
3224
diff
changeset
|
4354 |
// We write elements "backwards" to guarantee all-or-nothing |
29b6893c6188
6639443: Character.toCodePoint and Character.toSurrogates can be optimized
martin
parents:
3224
diff
changeset
|
4355 |
dst[index+1] = (char)((codePoint & 0x3ff) + MIN_LOW_SURROGATE); |
29b6893c6188
6639443: Character.toCodePoint and Character.toSurrogates can be optimized
martin
parents:
3224
diff
changeset
|
4356 |
dst[index] = (char)((codePoint >>> 10) |
29b6893c6188
6639443: Character.toCodePoint and Character.toSurrogates can be optimized
martin
parents:
3224
diff
changeset
|
4357 |
+ (MIN_HIGH_SURROGATE - (MIN_SUPPLEMENTARY_CODE_POINT >>> 10))); |
2 | 4358 |
} |
4359 |
||
4360 |
/** |
|
4361 |
* Returns the number of Unicode code points in the text range of |
|
4362 |
* the specified char sequence. The text range begins at the |
|
4363 |
* specified <code>beginIndex</code> and extends to the |
|
4364 |
* <code>char</code> at index <code>endIndex - 1</code>. Thus the |
|
4365 |
* length (in <code>char</code>s) of the text range is |
|
4366 |
* <code>endIndex-beginIndex</code>. Unpaired surrogates within |
|
4367 |
* the text range count as one code point each. |
|
4368 |
* |
|
4369 |
* @param seq the char sequence |
|
4370 |
* @param beginIndex the index to the first <code>char</code> of |
|
4371 |
* the text range. |
|
4372 |
* @param endIndex the index after the last <code>char</code> of |
|
4373 |
* the text range. |
|
4374 |
* @return the number of Unicode code points in the specified text |
|
4375 |
* range |
|
4376 |
* @exception NullPointerException if <code>seq</code> is null. |
|
4377 |
* @exception IndexOutOfBoundsException if the |
|
4378 |
* <code>beginIndex</code> is negative, or <code>endIndex</code> |
|
4379 |
* is larger than the length of the given sequence, or |
|
4380 |
* <code>beginIndex</code> is larger than <code>endIndex</code>. |
|
4381 |
* @since 1.5 |
|
4382 |
*/ |
|
4383 |
public static int codePointCount(CharSequence seq, int beginIndex, int endIndex) { |
|
4384 |
int length = seq.length(); |
|
4385 |
if (beginIndex < 0 || endIndex > length || beginIndex > endIndex) { |
|
4386 |
throw new IndexOutOfBoundsException(); |
|
4387 |
} |
|
4388 |
int n = 0; |
|
4389 |
for (int i = beginIndex; i < endIndex; ) { |
|
4390 |
n++; |
|
4391 |
if (isHighSurrogate(seq.charAt(i++))) { |
|
4392 |
if (i < endIndex && isLowSurrogate(seq.charAt(i))) { |
|
4393 |
i++; |
|
4394 |
} |
|
4395 |
} |
|
4396 |
} |
|
4397 |
return n; |
|
4398 |
} |
|
4399 |
||
4400 |
/** |
|
4401 |
* Returns the number of Unicode code points in a subarray of the |
|
4402 |
* <code>char</code> array argument. The <code>offset</code> |
|
4403 |
* argument is the index of the first <code>char</code> of the |
|
4404 |
* subarray and the <code>count</code> argument specifies the |
|
4405 |
* length of the subarray in <code>char</code>s. Unpaired |
|
4406 |
* surrogates within the subarray count as one code point each. |
|
4407 |
* |
|
4408 |
* @param a the <code>char</code> array |
|
4409 |
* @param offset the index of the first <code>char</code> in the |
|
4410 |
* given <code>char</code> array |
|
4411 |
* @param count the length of the subarray in <code>char</code>s |
|
4412 |
* @return the number of Unicode code points in the specified subarray |
|
4413 |
* @exception NullPointerException if <code>a</code> is null. |
|
4414 |
* @exception IndexOutOfBoundsException if <code>offset</code> or |
|
4415 |
* <code>count</code> is negative, or if <code>offset + |
|
4416 |
* count</code> is larger than the length of the given array. |
|
4417 |
* @since 1.5 |
|
4418 |
*/ |
|
4419 |
public static int codePointCount(char[] a, int offset, int count) { |
|
4420 |
if (count > a.length - offset || offset < 0 || count < 0) { |
|
4421 |
throw new IndexOutOfBoundsException(); |
|
4422 |
} |
|
4423 |
return codePointCountImpl(a, offset, count); |
|
4424 |
} |
|
4425 |
||
4426 |
static int codePointCountImpl(char[] a, int offset, int count) { |
|
4427 |
int endIndex = offset + count; |
|
4428 |
int n = 0; |
|
4429 |
for (int i = offset; i < endIndex; ) { |
|
4430 |
n++; |
|
4431 |
if (isHighSurrogate(a[i++])) { |
|
4432 |
if (i < endIndex && isLowSurrogate(a[i])) { |
|
4433 |
i++; |
|
4434 |
} |
|
4435 |
} |
|
4436 |
} |
|
4437 |
return n; |
|
4438 |
} |
|
4439 |
||
4440 |
/** |
|
4441 |
* Returns the index within the given char sequence that is offset |
|
4442 |
* from the given <code>index</code> by <code>codePointOffset</code> |
|
4443 |
* code points. Unpaired surrogates within the text range given by |
|
4444 |
* <code>index</code> and <code>codePointOffset</code> count as |
|
4445 |
* one code point each. |
|
4446 |
* |
|
4447 |
* @param seq the char sequence |
|
4448 |
* @param index the index to be offset |
|
4449 |
* @param codePointOffset the offset in code points |
|
4450 |
* @return the index within the char sequence |
|
4451 |
* @exception NullPointerException if <code>seq</code> is null. |
|
4452 |
* @exception IndexOutOfBoundsException if <code>index</code> |
|
4453 |
* is negative or larger then the length of the char sequence, |
|
4454 |
* or if <code>codePointOffset</code> is positive and the |
|
4455 |
* subsequence starting with <code>index</code> has fewer than |
|
4456 |
* <code>codePointOffset</code> code points, or if |
|
4457 |
* <code>codePointOffset</code> is negative and the subsequence |
|
4458 |
* before <code>index</code> has fewer than the absolute value |
|
4459 |
* of <code>codePointOffset</code> code points. |
|
4460 |
* @since 1.5 |
|
4461 |
*/ |
|
4462 |
public static int offsetByCodePoints(CharSequence seq, int index, |
|
4463 |
int codePointOffset) { |
|
4464 |
int length = seq.length(); |
|
4465 |
if (index < 0 || index > length) { |
|
4466 |
throw new IndexOutOfBoundsException(); |
|
4467 |
} |
|
4468 |
||
4469 |
int x = index; |
|
4470 |
if (codePointOffset >= 0) { |
|
4471 |
int i; |
|
4472 |
for (i = 0; x < length && i < codePointOffset; i++) { |
|
4473 |
if (isHighSurrogate(seq.charAt(x++))) { |
|
4474 |
if (x < length && isLowSurrogate(seq.charAt(x))) { |
|
4475 |
x++; |
|
4476 |
} |
|
4477 |
} |
|
4478 |
} |
|
4479 |
if (i < codePointOffset) { |
|
4480 |
throw new IndexOutOfBoundsException(); |
|
4481 |
} |
|
4482 |
} else { |
|
4483 |
int i; |
|
4484 |
for (i = codePointOffset; x > 0 && i < 0; i++) { |
|
4485 |
if (isLowSurrogate(seq.charAt(--x))) { |
|
4486 |
if (x > 0 && isHighSurrogate(seq.charAt(x-1))) { |
|
4487 |
x--; |
|
4488 |
} |
|
4489 |
} |
|
4490 |
} |
|
4491 |
if (i < 0) { |
|
4492 |
throw new IndexOutOfBoundsException(); |
|
4493 |
} |
|
4494 |
} |
|
4495 |
return x; |
|
4496 |
} |
|
4497 |
||
4498 |
/** |
|
4499 |
* Returns the index within the given <code>char</code> subarray |
|
4500 |
* that is offset from the given <code>index</code> by |
|
4501 |
* <code>codePointOffset</code> code points. The |
|
4502 |
* <code>start</code> and <code>count</code> arguments specify a |
|
4503 |
* subarray of the <code>char</code> array. Unpaired surrogates |
|
4504 |
* within the text range given by <code>index</code> and |
|
4505 |
* <code>codePointOffset</code> count as one code point each. |
|
4506 |
* |
|
4507 |
* @param a the <code>char</code> array |
|
4508 |
* @param start the index of the first <code>char</code> of the |
|
4509 |
* subarray |
|
4510 |
* @param count the length of the subarray in <code>char</code>s |
|
4511 |
* @param index the index to be offset |
|
4512 |
* @param codePointOffset the offset in code points |
|
4513 |
* @return the index within the subarray |
|
4514 |
* @exception NullPointerException if <code>a</code> is null. |
|
4515 |
* @exception IndexOutOfBoundsException |
|
4516 |
* if <code>start</code> or <code>count</code> is negative, |
|
4517 |
* or if <code>start + count</code> is larger than the length of |
|
4518 |
* the given array, |
|
4519 |
* or if <code>index</code> is less than <code>start</code> or |
|
4520 |
* larger then <code>start + count</code>, |
|
4521 |
* or if <code>codePointOffset</code> is positive and the text range |
|
4522 |
* starting with <code>index</code> and ending with <code>start |
|
4523 |
* + count - 1</code> has fewer than <code>codePointOffset</code> code |
|
4524 |
* points, |
|
4525 |
* or if <code>codePointOffset</code> is negative and the text range |
|
4526 |
* starting with <code>start</code> and ending with <code>index |
|
4527 |
* - 1</code> has fewer than the absolute value of |
|
4528 |
* <code>codePointOffset</code> code points. |
|
4529 |
* @since 1.5 |
|
4530 |
*/ |
|
4531 |
public static int offsetByCodePoints(char[] a, int start, int count, |
|
4532 |
int index, int codePointOffset) { |
|
4533 |
if (count > a.length-start || start < 0 || count < 0 |
|
4534 |
|| index < start || index > start+count) { |
|
4535 |
throw new IndexOutOfBoundsException(); |
|
4536 |
} |
|
4537 |
return offsetByCodePointsImpl(a, start, count, index, codePointOffset); |
|
4538 |
} |
|
4539 |
||
4540 |
static int offsetByCodePointsImpl(char[]a, int start, int count, |
|
4541 |
int index, int codePointOffset) { |
|
4542 |
int x = index; |
|
4543 |
if (codePointOffset >= 0) { |
|
4544 |
int limit = start + count; |
|
4545 |
int i; |
|
4546 |
for (i = 0; x < limit && i < codePointOffset; i++) { |
|
4547 |
if (isHighSurrogate(a[x++])) { |
|
4548 |
if (x < limit && isLowSurrogate(a[x])) { |
|
4549 |
x++; |
|
4550 |
} |
|
4551 |
} |
|
4552 |
} |
|
4553 |
if (i < codePointOffset) { |
|
4554 |
throw new IndexOutOfBoundsException(); |
|
4555 |
} |
|
4556 |
} else { |
|
4557 |
int i; |
|
4558 |
for (i = codePointOffset; x > start && i < 0; i++) { |
|
4559 |
if (isLowSurrogate(a[--x])) { |
|
4560 |
if (x > start && isHighSurrogate(a[x-1])) { |
|
4561 |
x--; |
|
4562 |
} |
|
4563 |
} |
|
4564 |
} |
|
4565 |
if (i < 0) { |
|
4566 |
throw new IndexOutOfBoundsException(); |
|
4567 |
} |
|
4568 |
} |
|
4569 |
return x; |
|
4570 |
} |
|
4571 |
||
4572 |
/** |
|
4573 |
* Determines if the specified character is a lowercase character. |
|
4574 |
* <p> |
|
4575 |
* A character is lowercase if its general category type, provided |
|
4576 |
* by <code>Character.getType(ch)</code>, is |
|
4577 |
* <code>LOWERCASE_LETTER</code>. |
|
4578 |
* <p> |
|
4579 |
* The following are examples of lowercase characters: |
|
4580 |
* <p><blockquote><pre> |
|
4581 |
* a b c d e f g h i j k l m n o p q r s t u v w x y z |
|
4582 |
* '\u00DF' '\u00E0' '\u00E1' '\u00E2' '\u00E3' '\u00E4' '\u00E5' '\u00E6' |
|
4583 |
* '\u00E7' '\u00E8' '\u00E9' '\u00EA' '\u00EB' '\u00EC' '\u00ED' '\u00EE' |
|
4584 |
* '\u00EF' '\u00F0' '\u00F1' '\u00F2' '\u00F3' '\u00F4' '\u00F5' '\u00F6' |
|
4585 |
* '\u00F8' '\u00F9' '\u00FA' '\u00FB' '\u00FC' '\u00FD' '\u00FE' '\u00FF' |
|
4586 |
* </pre></blockquote> |
|
4587 |
* <p> Many other Unicode characters are lowercase too. |
|
4588 |
* |
|
4589 |
* <p><b>Note:</b> This method cannot handle <a |
|
4590 |
* href="#supplementary"> supplementary characters</a>. To support |
|
4591 |
* all Unicode characters, including supplementary characters, use |
|
4592 |
* the {@link #isLowerCase(int)} method. |
|
4593 |
* |
|
4594 |
* @param ch the character to be tested. |
|
4595 |
* @return <code>true</code> if the character is lowercase; |
|
4596 |
* <code>false</code> otherwise. |
|
4597 |
* @see java.lang.Character#isLowerCase(char) |
|
4598 |
* @see java.lang.Character#isTitleCase(char) |
|
4599 |
* @see java.lang.Character#toLowerCase(char) |
|
4600 |
* @see java.lang.Character#getType(char) |
|
4601 |
*/ |
|
4602 |
public static boolean isLowerCase(char ch) { |
|
4603 |
return isLowerCase((int)ch); |
|
4604 |
} |
|
4605 |
||
4606 |
/** |
|
4607 |
* Determines if the specified character (Unicode code point) is a |
|
4608 |
* lowercase character. |
|
4609 |
* <p> |
|
4610 |
* A character is lowercase if its general category type, provided |
|
4611 |
* by {@link Character#getType getType(codePoint)}, is |
|
4612 |
* <code>LOWERCASE_LETTER</code>. |
|
4613 |
* <p> |
|
4614 |
* The following are examples of lowercase characters: |
|
4615 |
* <p><blockquote><pre> |
|
4616 |
* a b c d e f g h i j k l m n o p q r s t u v w x y z |
|
4617 |
* '\u00DF' '\u00E0' '\u00E1' '\u00E2' '\u00E3' '\u00E4' '\u00E5' '\u00E6' |
|
4618 |
* '\u00E7' '\u00E8' '\u00E9' '\u00EA' '\u00EB' '\u00EC' '\u00ED' '\u00EE' |
|
4619 |
* '\u00EF' '\u00F0' '\u00F1' '\u00F2' '\u00F3' '\u00F4' '\u00F5' '\u00F6' |
|
4620 |
* '\u00F8' '\u00F9' '\u00FA' '\u00FB' '\u00FC' '\u00FD' '\u00FE' '\u00FF' |
|
4621 |
* </pre></blockquote> |
|
4622 |
* <p> Many other Unicode characters are lowercase too. |
|
4623 |
* |
|
4624 |
* @param codePoint the character (Unicode code point) to be tested. |
|
4625 |
* @return <code>true</code> if the character is lowercase; |
|
4626 |
* <code>false</code> otherwise. |
|
4627 |
* @see java.lang.Character#isLowerCase(int) |
|
4628 |
* @see java.lang.Character#isTitleCase(int) |
|
4629 |
* @see java.lang.Character#toLowerCase(int) |
|
4630 |
* @see java.lang.Character#getType(int) |
|
4631 |
* @since 1.5 |
|
4632 |
*/ |
|
4633 |
public static boolean isLowerCase(int codePoint) { |
|
4634 |
return getType(codePoint) == Character.LOWERCASE_LETTER; |
|
4635 |
} |
|
4636 |
||
4637 |
/** |
|
4638 |
* Determines if the specified character is an uppercase character. |
|
4639 |
* <p> |
|
4640 |
* A character is uppercase if its general category type, provided by |
|
4641 |
* <code>Character.getType(ch)</code>, is <code>UPPERCASE_LETTER</code>. |
|
4642 |
* <p> |
|
4643 |
* The following are examples of uppercase characters: |
|
4644 |
* <p><blockquote><pre> |
|
4645 |
* A B C D E F G H I J K L M N O P Q R S T U V W X Y Z |
|
4646 |
* '\u00C0' '\u00C1' '\u00C2' '\u00C3' '\u00C4' '\u00C5' '\u00C6' '\u00C7' |
|
4647 |
* '\u00C8' '\u00C9' '\u00CA' '\u00CB' '\u00CC' '\u00CD' '\u00CE' '\u00CF' |
|
4648 |
* '\u00D0' '\u00D1' '\u00D2' '\u00D3' '\u00D4' '\u00D5' '\u00D6' '\u00D8' |
|
4649 |
* '\u00D9' '\u00DA' '\u00DB' '\u00DC' '\u00DD' '\u00DE' |
|
4650 |
* </pre></blockquote> |
|
4651 |
* <p> Many other Unicode characters are uppercase too.<p> |
|
4652 |
* |
|
4653 |
* <p><b>Note:</b> This method cannot handle <a |
|
4654 |
* href="#supplementary"> supplementary characters</a>. To support |
|
4655 |
* all Unicode characters, including supplementary characters, use |
|
4656 |
* the {@link #isUpperCase(int)} method. |
|
4657 |
* |
|
4658 |
* @param ch the character to be tested. |
|
4659 |
* @return <code>true</code> if the character is uppercase; |
|
4660 |
* <code>false</code> otherwise. |
|
4661 |
* @see java.lang.Character#isLowerCase(char) |
|
4662 |
* @see java.lang.Character#isTitleCase(char) |
|
4663 |
* @see java.lang.Character#toUpperCase(char) |
|
4664 |
* @see java.lang.Character#getType(char) |
|
4665 |
* @since 1.0 |
|
4666 |
*/ |
|
4667 |
public static boolean isUpperCase(char ch) { |
|
4668 |
return isUpperCase((int)ch); |
|
4669 |
} |
|
4670 |
||
4671 |
/** |
|
4672 |
* Determines if the specified character (Unicode code point) is an uppercase character. |
|
4673 |
* <p> |
|
4674 |
* A character is uppercase if its general category type, provided by |
|
4675 |
* {@link Character#getType(int) getType(codePoint)}, is <code>UPPERCASE_LETTER</code>. |
|
4676 |
* <p> |
|
4677 |
* The following are examples of uppercase characters: |
|
4678 |
* <p><blockquote><pre> |
|
4679 |
* A B C D E F G H I J K L M N O P Q R S T U V W X Y Z |
|
4680 |
* '\u00C0' '\u00C1' '\u00C2' '\u00C3' '\u00C4' '\u00C5' '\u00C6' '\u00C7' |
|
4681 |
* '\u00C8' '\u00C9' '\u00CA' '\u00CB' '\u00CC' '\u00CD' '\u00CE' '\u00CF' |
|
4682 |
* '\u00D0' '\u00D1' '\u00D2' '\u00D3' '\u00D4' '\u00D5' '\u00D6' '\u00D8' |
|
4683 |
* '\u00D9' '\u00DA' '\u00DB' '\u00DC' '\u00DD' '\u00DE' |
|
4684 |
* </pre></blockquote> |
|
4685 |
* <p> Many other Unicode characters are uppercase too.<p> |
|
4686 |
* |
|
4687 |
* @param codePoint the character (Unicode code point) to be tested. |
|
4688 |
* @return <code>true</code> if the character is uppercase; |
|
4689 |
* <code>false</code> otherwise. |
|
4690 |
* @see java.lang.Character#isLowerCase(int) |
|
4691 |
* @see java.lang.Character#isTitleCase(int) |
|
4692 |
* @see java.lang.Character#toUpperCase(int) |
|
4693 |
* @see java.lang.Character#getType(int) |
|
4694 |
* @since 1.5 |
|
4695 |
*/ |
|
4696 |
public static boolean isUpperCase(int codePoint) { |
|
4697 |
return getType(codePoint) == Character.UPPERCASE_LETTER; |
|
4698 |
} |
|
4699 |
||
4700 |
/** |
|
4701 |
* Determines if the specified character is a titlecase character. |
|
4702 |
* <p> |
|
4703 |
* A character is a titlecase character if its general |
|
4704 |
* category type, provided by <code>Character.getType(ch)</code>, |
|
4705 |
* is <code>TITLECASE_LETTER</code>. |
|
4706 |
* <p> |
|
4707 |
* Some characters look like pairs of Latin letters. For example, there |
|
4708 |
* is an uppercase letter that looks like "LJ" and has a corresponding |
|
4709 |
* lowercase letter that looks like "lj". A third form, which looks like "Lj", |
|
4710 |
* is the appropriate form to use when rendering a word in lowercase |
|
4711 |
* with initial capitals, as for a book title. |
|
4712 |
* <p> |
|
4713 |
* These are some of the Unicode characters for which this method returns |
|
4714 |
* <code>true</code>: |
|
4715 |
* <ul> |
|
4716 |
* <li><code>LATIN CAPITAL LETTER D WITH SMALL LETTER Z WITH CARON</code> |
|
4717 |
* <li><code>LATIN CAPITAL LETTER L WITH SMALL LETTER J</code> |
|
4718 |
* <li><code>LATIN CAPITAL LETTER N WITH SMALL LETTER J</code> |
|
4719 |
* <li><code>LATIN CAPITAL LETTER D WITH SMALL LETTER Z</code> |
|
4720 |
* </ul> |
|
4721 |
* <p> Many other Unicode characters are titlecase too.<p> |
|
4722 |
* |
|
4723 |
* <p><b>Note:</b> This method cannot handle <a |
|
4724 |
* href="#supplementary"> supplementary characters</a>. To support |
|
4725 |
* all Unicode characters, including supplementary characters, use |
|
4726 |
* the {@link #isTitleCase(int)} method. |
|
4727 |
* |
|
4728 |
* @param ch the character to be tested. |
|
4729 |
* @return <code>true</code> if the character is titlecase; |
|
4730 |
* <code>false</code> otherwise. |
|
4731 |
* @see java.lang.Character#isLowerCase(char) |
|
4732 |
* @see java.lang.Character#isUpperCase(char) |
|
4733 |
* @see java.lang.Character#toTitleCase(char) |
|
4734 |
* @see java.lang.Character#getType(char) |
|
4735 |
* @since 1.0.2 |
|
4736 |
*/ |
|
4737 |
public static boolean isTitleCase(char ch) { |
|
4738 |
return isTitleCase((int)ch); |
|
4739 |
} |
|
4740 |
||
4741 |
/** |
|
4742 |
* Determines if the specified character (Unicode code point) is a titlecase character. |
|
4743 |
* <p> |
|
4744 |
* A character is a titlecase character if its general |
|
4745 |
* category type, provided by {@link Character#getType(int) getType(codePoint)}, |
|
4746 |
* is <code>TITLECASE_LETTER</code>. |
|
4747 |
* <p> |
|
4748 |
* Some characters look like pairs of Latin letters. For example, there |
|
4749 |
* is an uppercase letter that looks like "LJ" and has a corresponding |
|
4750 |
* lowercase letter that looks like "lj". A third form, which looks like "Lj", |
|
4751 |
* is the appropriate form to use when rendering a word in lowercase |
|
4752 |
* with initial capitals, as for a book title. |
|
4753 |
* <p> |
|
4754 |
* These are some of the Unicode characters for which this method returns |
|
4755 |
* <code>true</code>: |
|
4756 |
* <ul> |
|
4757 |
* <li><code>LATIN CAPITAL LETTER D WITH SMALL LETTER Z WITH CARON</code> |
|
4758 |
* <li><code>LATIN CAPITAL LETTER L WITH SMALL LETTER J</code> |
|
4759 |
* <li><code>LATIN CAPITAL LETTER N WITH SMALL LETTER J</code> |
|
4760 |
* <li><code>LATIN CAPITAL LETTER D WITH SMALL LETTER Z</code> |
|
4761 |
* </ul> |
|
4762 |
* <p> Many other Unicode characters are titlecase too.<p> |
|
4763 |
* |
|
4764 |
* @param codePoint the character (Unicode code point) to be tested. |
|
4765 |
* @return <code>true</code> if the character is titlecase; |
|
4766 |
* <code>false</code> otherwise. |
|
4767 |
* @see java.lang.Character#isLowerCase(int) |
|
4768 |
* @see java.lang.Character#isUpperCase(int) |
|
4769 |
* @see java.lang.Character#toTitleCase(int) |
|
4770 |
* @see java.lang.Character#getType(int) |
|
4771 |
* @since 1.5 |
|
4772 |
*/ |
|
4773 |
public static boolean isTitleCase(int codePoint) { |
|
4774 |
return getType(codePoint) == Character.TITLECASE_LETTER; |
|
4775 |
} |
|
4776 |
||
4777 |
/** |
|
4778 |
* Determines if the specified character is a digit. |
|
4779 |
* <p> |
|
4780 |
* A character is a digit if its general category type, provided |
|
4781 |
* by <code>Character.getType(ch)</code>, is |
|
4782 |
* <code>DECIMAL_DIGIT_NUMBER</code>. |
|
4783 |
* <p> |
|
4784 |
* Some Unicode character ranges that contain digits: |
|
4785 |
* <ul> |
|
4786 |
* <li><code>'\u0030'</code> through <code>'\u0039'</code>, |
|
4787 |
* ISO-LATIN-1 digits (<code>'0'</code> through <code>'9'</code>) |
|
4788 |
* <li><code>'\u0660'</code> through <code>'\u0669'</code>, |
|
4789 |
* Arabic-Indic digits |
|
4790 |
* <li><code>'\u06F0'</code> through <code>'\u06F9'</code>, |
|
4791 |
* Extended Arabic-Indic digits |
|
4792 |
* <li><code>'\u0966'</code> through <code>'\u096F'</code>, |
|
4793 |
* Devanagari digits |
|
4794 |
* <li><code>'\uFF10'</code> through <code>'\uFF19'</code>, |
|
4795 |
* Fullwidth digits |
|
4796 |
* </ul> |
|
4797 |
* |
|
4798 |
* Many other character ranges contain digits as well. |
|
4799 |
* |
|
4800 |
* <p><b>Note:</b> This method cannot handle <a |
|
4801 |
* href="#supplementary"> supplementary characters</a>. To support |
|
4802 |
* all Unicode characters, including supplementary characters, use |
|
4803 |
* the {@link #isDigit(int)} method. |
|
4804 |
* |
|
4805 |
* @param ch the character to be tested. |
|
4806 |
* @return <code>true</code> if the character is a digit; |
|
4807 |
* <code>false</code> otherwise. |
|
4808 |
* @see java.lang.Character#digit(char, int) |
|
4809 |
* @see java.lang.Character#forDigit(int, int) |
|
4810 |
* @see java.lang.Character#getType(char) |
|
4811 |
*/ |
|
4812 |
public static boolean isDigit(char ch) { |
|
4813 |
return isDigit((int)ch); |
|
4814 |
} |
|
4815 |
||
4816 |
/** |
|
4817 |
* Determines if the specified character (Unicode code point) is a digit. |
|
4818 |
* <p> |
|
4819 |
* A character is a digit if its general category type, provided |
|
4820 |
* by {@link Character#getType(int) getType(codePoint)}, is |
|
4821 |
* <code>DECIMAL_DIGIT_NUMBER</code>. |
|
4822 |
* <p> |
|
4823 |
* Some Unicode character ranges that contain digits: |
|
4824 |
* <ul> |
|
4825 |
* <li><code>'\u0030'</code> through <code>'\u0039'</code>, |
|
4826 |
* ISO-LATIN-1 digits (<code>'0'</code> through <code>'9'</code>) |
|
4827 |
* <li><code>'\u0660'</code> through <code>'\u0669'</code>, |
|
4828 |
* Arabic-Indic digits |
|
4829 |
* <li><code>'\u06F0'</code> through <code>'\u06F9'</code>, |
|
4830 |
* Extended Arabic-Indic digits |
|
4831 |
* <li><code>'\u0966'</code> through <code>'\u096F'</code>, |
|
4832 |
* Devanagari digits |
|
4833 |
* <li><code>'\uFF10'</code> through <code>'\uFF19'</code>, |
|
4834 |
* Fullwidth digits |
|
4835 |
* </ul> |
|
4836 |
* |
|
4837 |
* Many other character ranges contain digits as well. |
|
4838 |
* |
|
4839 |
* @param codePoint the character (Unicode code point) to be tested. |
|
4840 |
* @return <code>true</code> if the character is a digit; |
|
4841 |
* <code>false</code> otherwise. |
|
4842 |
* @see java.lang.Character#forDigit(int, int) |
|
4843 |
* @see java.lang.Character#getType(int) |
|
4844 |
* @since 1.5 |
|
4845 |
*/ |
|
4846 |
public static boolean isDigit(int codePoint) { |
|
4847 |
return getType(codePoint) == Character.DECIMAL_DIGIT_NUMBER; |
|
4848 |
} |
|
4849 |
||
4850 |
/** |
|
4851 |
* Determines if a character is defined in Unicode. |
|
4852 |
* <p> |
|
4853 |
* A character is defined if at least one of the following is true: |
|
4854 |
* <ul> |
|
4855 |
* <li>It has an entry in the UnicodeData file. |
|
4856 |
* <li>It has a value in a range defined by the UnicodeData file. |
|
4857 |
* </ul> |
|
4858 |
* |
|
4859 |
* <p><b>Note:</b> This method cannot handle <a |
|
4860 |
* href="#supplementary"> supplementary characters</a>. To support |
|
4861 |
* all Unicode characters, including supplementary characters, use |
|
4862 |
* the {@link #isDefined(int)} method. |
|
4863 |
* |
|
4864 |
* @param ch the character to be tested |
|
4865 |
* @return <code>true</code> if the character has a defined meaning |
|
4866 |
* in Unicode; <code>false</code> otherwise. |
|
4867 |
* @see java.lang.Character#isDigit(char) |
|
4868 |
* @see java.lang.Character#isLetter(char) |
|
4869 |
* @see java.lang.Character#isLetterOrDigit(char) |
|
4870 |
* @see java.lang.Character#isLowerCase(char) |
|
4871 |
* @see java.lang.Character#isTitleCase(char) |
|
4872 |
* @see java.lang.Character#isUpperCase(char) |
|
4873 |
* @since 1.0.2 |
|
4874 |
*/ |
|
4875 |
public static boolean isDefined(char ch) { |
|
4876 |
return isDefined((int)ch); |
|
4877 |
} |
|
4878 |
||
4879 |
/** |
|
4880 |
* Determines if a character (Unicode code point) is defined in Unicode. |
|
4881 |
* <p> |
|
4882 |
* A character is defined if at least one of the following is true: |
|
4883 |
* <ul> |
|
4884 |
* <li>It has an entry in the UnicodeData file. |
|
4885 |
* <li>It has a value in a range defined by the UnicodeData file. |
|
4886 |
* </ul> |
|
4887 |
* |
|
4888 |
* @param codePoint the character (Unicode code point) to be tested. |
|
4889 |
* @return <code>true</code> if the character has a defined meaning |
|
4890 |
* in Unicode; <code>false</code> otherwise. |
|
4891 |
* @see java.lang.Character#isDigit(int) |
|
4892 |
* @see java.lang.Character#isLetter(int) |
|
4893 |
* @see java.lang.Character#isLetterOrDigit(int) |
|
4894 |
* @see java.lang.Character#isLowerCase(int) |
|
4895 |
* @see java.lang.Character#isTitleCase(int) |
|
4896 |
* @see java.lang.Character#isUpperCase(int) |
|
4897 |
* @since 1.5 |
|
4898 |
*/ |
|
4899 |
public static boolean isDefined(int codePoint) { |
|
4900 |
return getType(codePoint) != Character.UNASSIGNED; |
|
4901 |
} |
|
4902 |
||
4903 |
/** |
|
4904 |
* Determines if the specified character is a letter. |
|
4905 |
* <p> |
|
4906 |
* A character is considered to be a letter if its general |
|
4907 |
* category type, provided by <code>Character.getType(ch)</code>, |
|
4908 |
* is any of the following: |
|
4909 |
* <ul> |
|
4910 |
* <li> <code>UPPERCASE_LETTER</code> |
|
4911 |
* <li> <code>LOWERCASE_LETTER</code> |
|
4912 |
* <li> <code>TITLECASE_LETTER</code> |
|
4913 |
* <li> <code>MODIFIER_LETTER</code> |
|
4914 |
* <li> <code>OTHER_LETTER</code> |
|
4915 |
* </ul> |
|
4916 |
* |
|
4917 |
* Not all letters have case. Many characters are |
|
4918 |
* letters but are neither uppercase nor lowercase nor titlecase. |
|
4919 |
* |
|
4920 |
* <p><b>Note:</b> This method cannot handle <a |
|
4921 |
* href="#supplementary"> supplementary characters</a>. To support |
|
4922 |
* all Unicode characters, including supplementary characters, use |
|
4923 |
* the {@link #isLetter(int)} method. |
|
4924 |
* |
|
4925 |
* @param ch the character to be tested. |
|
4926 |
* @return <code>true</code> if the character is a letter; |
|
4927 |
* <code>false</code> otherwise. |
|
4928 |
* @see java.lang.Character#isDigit(char) |
|
4929 |
* @see java.lang.Character#isJavaIdentifierStart(char) |
|
4930 |
* @see java.lang.Character#isJavaLetter(char) |
|
4931 |
* @see java.lang.Character#isJavaLetterOrDigit(char) |
|
4932 |
* @see java.lang.Character#isLetterOrDigit(char) |
|
4933 |
* @see java.lang.Character#isLowerCase(char) |
|
4934 |
* @see java.lang.Character#isTitleCase(char) |
|
4935 |
* @see java.lang.Character#isUnicodeIdentifierStart(char) |
|
4936 |
* @see java.lang.Character#isUpperCase(char) |
|
4937 |
*/ |
|
4938 |
public static boolean isLetter(char ch) { |
|
4939 |
return isLetter((int)ch); |
|
4940 |
} |
|
4941 |
||
4942 |
/** |
|
4943 |
* Determines if the specified character (Unicode code point) is a letter. |
|
4944 |
* <p> |
|
4945 |
* A character is considered to be a letter if its general |
|
4946 |
* category type, provided by {@link Character#getType(int) getType(codePoint)}, |
|
4947 |
* is any of the following: |
|
4948 |
* <ul> |
|
4949 |
* <li> <code>UPPERCASE_LETTER</code> |
|
4950 |
* <li> <code>LOWERCASE_LETTER</code> |
|
4951 |
* <li> <code>TITLECASE_LETTER</code> |
|
4952 |
* <li> <code>MODIFIER_LETTER</code> |
|
4953 |
* <li> <code>OTHER_LETTER</code> |
|
4954 |
* </ul> |
|
4955 |
* |
|
4956 |
* Not all letters have case. Many characters are |
|
4957 |
* letters but are neither uppercase nor lowercase nor titlecase. |
|
4958 |
* |
|
4959 |
* @param codePoint the character (Unicode code point) to be tested. |
|
4960 |
* @return <code>true</code> if the character is a letter; |
|
4961 |
* <code>false</code> otherwise. |
|
4962 |
* @see java.lang.Character#isDigit(int) |
|
4963 |
* @see java.lang.Character#isJavaIdentifierStart(int) |
|
4964 |
* @see java.lang.Character#isLetterOrDigit(int) |
|
4965 |
* @see java.lang.Character#isLowerCase(int) |
|
4966 |
* @see java.lang.Character#isTitleCase(int) |
|
4967 |
* @see java.lang.Character#isUnicodeIdentifierStart(int) |
|
4968 |
* @see java.lang.Character#isUpperCase(int) |
|
4969 |
* @since 1.5 |
|
4970 |
*/ |
|
4971 |
public static boolean isLetter(int codePoint) { |
|
4972 |
return ((((1 << Character.UPPERCASE_LETTER) | |
|
4973 |
(1 << Character.LOWERCASE_LETTER) | |
|
4974 |
(1 << Character.TITLECASE_LETTER) | |
|
4975 |
(1 << Character.MODIFIER_LETTER) | |
|
4976 |
(1 << Character.OTHER_LETTER)) >> getType(codePoint)) & 1) |
|
4977 |
!= 0; |
|
4978 |
} |
|
4979 |
||
4980 |
/** |
|
4981 |
* Determines if the specified character is a letter or digit. |
|
4982 |
* <p> |
|
4983 |
* A character is considered to be a letter or digit if either |
|
4984 |
* <code>Character.isLetter(char ch)</code> or |
|
4985 |
* <code>Character.isDigit(char ch)</code> returns |
|
4986 |
* <code>true</code> for the character. |
|
4987 |
* |
|
4988 |
* <p><b>Note:</b> This method cannot handle <a |
|
4989 |
* href="#supplementary"> supplementary characters</a>. To support |
|
4990 |
* all Unicode characters, including supplementary characters, use |
|
4991 |
* the {@link #isLetterOrDigit(int)} method. |
|
4992 |
* |
|
4993 |
* @param ch the character to be tested. |
|
4994 |
* @return <code>true</code> if the character is a letter or digit; |
|
4995 |
* <code>false</code> otherwise. |
|
4996 |
* @see java.lang.Character#isDigit(char) |
|
4997 |
* @see java.lang.Character#isJavaIdentifierPart(char) |
|
4998 |
* @see java.lang.Character#isJavaLetter(char) |
|
4999 |
* @see java.lang.Character#isJavaLetterOrDigit(char) |
|
5000 |
* @see java.lang.Character#isLetter(char) |
|
5001 |
* @see java.lang.Character#isUnicodeIdentifierPart(char) |
|
5002 |
* @since 1.0.2 |
|
5003 |
*/ |
|
5004 |
public static boolean isLetterOrDigit(char ch) { |
|
5005 |
return isLetterOrDigit((int)ch); |
|
5006 |
} |
|
5007 |
||
5008 |
/** |
|
5009 |
* Determines if the specified character (Unicode code point) is a letter or digit. |
|
5010 |
* <p> |
|
5011 |
* A character is considered to be a letter or digit if either |
|
5012 |
* {@link #isLetter(int) isLetter(codePoint)} or |
|
5013 |
* {@link #isDigit(int) isDigit(codePoint)} returns |
|
5014 |
* <code>true</code> for the character. |
|
5015 |
* |
|
5016 |
* @param codePoint the character (Unicode code point) to be tested. |
|
5017 |
* @return <code>true</code> if the character is a letter or digit; |
|
5018 |
* <code>false</code> otherwise. |
|
5019 |
* @see java.lang.Character#isDigit(int) |
|
5020 |
* @see java.lang.Character#isJavaIdentifierPart(int) |
|
5021 |
* @see java.lang.Character#isLetter(int) |
|
5022 |
* @see java.lang.Character#isUnicodeIdentifierPart(int) |
|
5023 |
* @since 1.5 |
|
5024 |
*/ |
|
5025 |
public static boolean isLetterOrDigit(int codePoint) { |
|
5026 |
return ((((1 << Character.UPPERCASE_LETTER) | |
|
5027 |
(1 << Character.LOWERCASE_LETTER) | |
|
5028 |
(1 << Character.TITLECASE_LETTER) | |
|
5029 |
(1 << Character.MODIFIER_LETTER) | |
|
5030 |
(1 << Character.OTHER_LETTER) | |
|
5031 |
(1 << Character.DECIMAL_DIGIT_NUMBER)) >> getType(codePoint)) & 1) |
|
5032 |
!= 0; |
|
5033 |
} |
|
5034 |
||
5035 |
/** |
|
5036 |
* Determines if the specified character is permissible as the first |
|
5037 |
* character in a Java identifier. |
|
5038 |
* <p> |
|
5039 |
* A character may start a Java identifier if and only if |
|
5040 |
* one of the following is true: |
|
5041 |
* <ul> |
|
5042 |
* <li> {@link #isLetter(char) isLetter(ch)} returns <code>true</code> |
|
5043 |
* <li> {@link #getType(char) getType(ch)} returns <code>LETTER_NUMBER</code> |
|
5044 |
* <li> ch is a currency symbol (such as "$") |
|
5045 |
* <li> ch is a connecting punctuation character (such as "_"). |
|
5046 |
* </ul> |
|
5047 |
* |
|
5048 |
* @param ch the character to be tested. |
|
5049 |
* @return <code>true</code> if the character may start a Java |
|
5050 |
* identifier; <code>false</code> otherwise. |
|
5051 |
* @see java.lang.Character#isJavaLetterOrDigit(char) |
|
5052 |
* @see java.lang.Character#isJavaIdentifierStart(char) |
|
5053 |
* @see java.lang.Character#isJavaIdentifierPart(char) |
|
5054 |
* @see java.lang.Character#isLetter(char) |
|
5055 |
* @see java.lang.Character#isLetterOrDigit(char) |
|
5056 |
* @see java.lang.Character#isUnicodeIdentifierStart(char) |
|
5057 |
* @since 1.02 |
|
5058 |
* @deprecated Replaced by isJavaIdentifierStart(char). |
|
5059 |
*/ |
|
5060 |
@Deprecated |
|
5061 |
public static boolean isJavaLetter(char ch) { |
|
5062 |
return isJavaIdentifierStart(ch); |
|
5063 |
} |
|
5064 |
||
5065 |
/** |
|
5066 |
* Determines if the specified character may be part of a Java |
|
5067 |
* identifier as other than the first character. |
|
5068 |
* <p> |
|
5069 |
* A character may be part of a Java identifier if and only if any |
|
5070 |
* of the following are true: |
|
5071 |
* <ul> |
|
5072 |
* <li> it is a letter |
|
5073 |
* <li> it is a currency symbol (such as <code>'$'</code>) |
|
5074 |
* <li> it is a connecting punctuation character (such as <code>'_'</code>) |
|
5075 |
* <li> it is a digit |
|
5076 |
* <li> it is a numeric letter (such as a Roman numeral character) |
|
5077 |
* <li> it is a combining mark |
|
5078 |
* <li> it is a non-spacing mark |
|
5079 |
* <li> <code>isIdentifierIgnorable</code> returns |
|
5080 |
* <code>true</code> for the character. |
|
5081 |
* </ul> |
|
5082 |
* |
|
5083 |
* @param ch the character to be tested. |
|
5084 |
* @return <code>true</code> if the character may be part of a |
|
5085 |
* Java identifier; <code>false</code> otherwise. |
|
5086 |
* @see java.lang.Character#isJavaLetter(char) |
|
5087 |
* @see java.lang.Character#isJavaIdentifierStart(char) |
|
5088 |
* @see java.lang.Character#isJavaIdentifierPart(char) |
|
5089 |
* @see java.lang.Character#isLetter(char) |
|
5090 |
* @see java.lang.Character#isLetterOrDigit(char) |
|
5091 |
* @see java.lang.Character#isUnicodeIdentifierPart(char) |
|
5092 |
* @see java.lang.Character#isIdentifierIgnorable(char) |
|
5093 |
* @since 1.02 |
|
5094 |
* @deprecated Replaced by isJavaIdentifierPart(char). |
|
5095 |
*/ |
|
5096 |
@Deprecated |
|
5097 |
public static boolean isJavaLetterOrDigit(char ch) { |
|
5098 |
return isJavaIdentifierPart(ch); |
|
5099 |
} |
|
5100 |
||
5101 |
/** |
|
5102 |
* Determines if the specified character is |
|
5103 |
* permissible as the first character in a Java identifier. |
|
5104 |
* <p> |
|
5105 |
* A character may start a Java identifier if and only if |
|
5106 |
* one of the following conditions is true: |
|
5107 |
* <ul> |
|
5108 |
* <li> {@link #isLetter(char) isLetter(ch)} returns <code>true</code> |
|
5109 |
* <li> {@link #getType(char) getType(ch)} returns <code>LETTER_NUMBER</code> |
|
5110 |
* <li> ch is a currency symbol (such as "$") |
|
5111 |
* <li> ch is a connecting punctuation character (such as "_"). |
|
5112 |
* </ul> |
|
5113 |
* |
|
5114 |
* <p><b>Note:</b> This method cannot handle <a |
|
5115 |
* href="#supplementary"> supplementary characters</a>. To support |
|
5116 |
* all Unicode characters, including supplementary characters, use |
|
5117 |
* the {@link #isJavaIdentifierStart(int)} method. |
|
5118 |
* |
|
5119 |
* @param ch the character to be tested. |
|
5120 |
* @return <code>true</code> if the character may start a Java identifier; |
|
5121 |
* <code>false</code> otherwise. |
|
5122 |
* @see java.lang.Character#isJavaIdentifierPart(char) |
|
5123 |
* @see java.lang.Character#isLetter(char) |
|
5124 |
* @see java.lang.Character#isUnicodeIdentifierStart(char) |
|
5125 |
* @see javax.lang.model.SourceVersion#isIdentifier(CharSequence) |
|
5126 |
* @since 1.1 |
|
5127 |
*/ |
|
5128 |
public static boolean isJavaIdentifierStart(char ch) { |
|
5129 |
return isJavaIdentifierStart((int)ch); |
|
5130 |
} |
|
5131 |
||
5132 |
/** |
|
5133 |
* Determines if the character (Unicode code point) is |
|
5134 |
* permissible as the first character in a Java identifier. |
|
5135 |
* <p> |
|
5136 |
* A character may start a Java identifier if and only if |
|
5137 |
* one of the following conditions is true: |
|
5138 |
* <ul> |
|
5139 |
* <li> {@link #isLetter(int) isLetter(codePoint)} |
|
5140 |
* returns <code>true</code> |
|
5141 |
* <li> {@link #getType(int) getType(codePoint)} |
|
5142 |
* returns <code>LETTER_NUMBER</code> |
|
5143 |
* <li> the referenced character is a currency symbol (such as "$") |
|
5144 |
* <li> the referenced character is a connecting punctuation character |
|
5145 |
* (such as "_"). |
|
5146 |
* </ul> |
|
5147 |
* |
|
5148 |
* @param codePoint the character (Unicode code point) to be tested. |
|
5149 |
* @return <code>true</code> if the character may start a Java identifier; |
|
5150 |
* <code>false</code> otherwise. |
|
5151 |
* @see java.lang.Character#isJavaIdentifierPart(int) |
|
5152 |
* @see java.lang.Character#isLetter(int) |
|
5153 |
* @see java.lang.Character#isUnicodeIdentifierStart(int) |
|
5154 |
* @see javax.lang.model.SourceVersion#isIdentifier(CharSequence) |
|
5155 |
* @since 1.5 |
|
5156 |
*/ |
|
5157 |
public static boolean isJavaIdentifierStart(int codePoint) { |
|
5158 |
return CharacterData.of(codePoint).isJavaIdentifierStart(codePoint); |
|
5159 |
} |
|
5160 |
||
5161 |
/** |
|
5162 |
* Determines if the specified character may be part of a Java |
|
5163 |
* identifier as other than the first character. |
|
5164 |
* <p> |
|
5165 |
* A character may be part of a Java identifier if any of the following |
|
5166 |
* are true: |
|
5167 |
* <ul> |
|
5168 |
* <li> it is a letter |
|
5169 |
* <li> it is a currency symbol (such as <code>'$'</code>) |
|
5170 |
* <li> it is a connecting punctuation character (such as <code>'_'</code>) |
|
5171 |
* <li> it is a digit |
|
5172 |
* <li> it is a numeric letter (such as a Roman numeral character) |
|
5173 |
* <li> it is a combining mark |
|
5174 |
* <li> it is a non-spacing mark |
|
5175 |
* <li> <code>isIdentifierIgnorable</code> returns |
|
5176 |
* <code>true</code> for the character |
|
5177 |
* </ul> |
|
5178 |
* |
|
5179 |
* <p><b>Note:</b> This method cannot handle <a |
|
5180 |
* href="#supplementary"> supplementary characters</a>. To support |
|
5181 |
* all Unicode characters, including supplementary characters, use |
|
5182 |
* the {@link #isJavaIdentifierPart(int)} method. |
|
5183 |
* |
|
5184 |
* @param ch the character to be tested. |
|
5185 |
* @return <code>true</code> if the character may be part of a |
|
5186 |
* Java identifier; <code>false</code> otherwise. |
|
5187 |
* @see java.lang.Character#isIdentifierIgnorable(char) |
|
5188 |
* @see java.lang.Character#isJavaIdentifierStart(char) |
|
5189 |
* @see java.lang.Character#isLetterOrDigit(char) |
|
5190 |
* @see java.lang.Character#isUnicodeIdentifierPart(char) |
|
5191 |
* @see javax.lang.model.SourceVersion#isIdentifier(CharSequence) |
|
5192 |
* @since 1.1 |
|
5193 |
*/ |
|
5194 |
public static boolean isJavaIdentifierPart(char ch) { |
|
5195 |
return isJavaIdentifierPart((int)ch); |
|
5196 |
} |
|
5197 |
||
5198 |
/** |
|
5199 |
* Determines if the character (Unicode code point) may be part of a Java |
|
5200 |
* identifier as other than the first character. |
|
5201 |
* <p> |
|
5202 |
* A character may be part of a Java identifier if any of the following |
|
5203 |
* are true: |
|
5204 |
* <ul> |
|
5205 |
* <li> it is a letter |
|
5206 |
* <li> it is a currency symbol (such as <code>'$'</code>) |
|
5207 |
* <li> it is a connecting punctuation character (such as <code>'_'</code>) |
|
5208 |
* <li> it is a digit |
|
5209 |
* <li> it is a numeric letter (such as a Roman numeral character) |
|
5210 |
* <li> it is a combining mark |
|
5211 |
* <li> it is a non-spacing mark |
|
5212 |
* <li> {@link #isIdentifierIgnorable(int) |
|
5213 |
* isIdentifierIgnorable(codePoint)} returns <code>true</code> for |
|
5214 |
* the character |
|
5215 |
* </ul> |
|
5216 |
* |
|
5217 |
* @param codePoint the character (Unicode code point) to be tested. |
|
5218 |
* @return <code>true</code> if the character may be part of a |
|
5219 |
* Java identifier; <code>false</code> otherwise. |
|
5220 |
* @see java.lang.Character#isIdentifierIgnorable(int) |
|
5221 |
* @see java.lang.Character#isJavaIdentifierStart(int) |
|
5222 |
* @see java.lang.Character#isLetterOrDigit(int) |
|
5223 |
* @see java.lang.Character#isUnicodeIdentifierPart(int) |
|
5224 |
* @see javax.lang.model.SourceVersion#isIdentifier(CharSequence) |
|
5225 |
* @since 1.5 |
|
5226 |
*/ |
|
5227 |
public static boolean isJavaIdentifierPart(int codePoint) { |
|
5228 |
return CharacterData.of(codePoint).isJavaIdentifierPart(codePoint); |
|
5229 |
} |
|
5230 |
||
5231 |
/** |
|
5232 |
* Determines if the specified character is permissible as the |
|
5233 |
* first character in a Unicode identifier. |
|
5234 |
* <p> |
|
5235 |
* A character may start a Unicode identifier if and only if |
|
5236 |
* one of the following conditions is true: |
|
5237 |
* <ul> |
|
5238 |
* <li> {@link #isLetter(char) isLetter(ch)} returns <code>true</code> |
|
5239 |
* <li> {@link #getType(char) getType(ch)} returns |
|
5240 |
* <code>LETTER_NUMBER</code>. |
|
5241 |
* </ul> |
|
5242 |
* |
|
5243 |
* <p><b>Note:</b> This method cannot handle <a |
|
5244 |
* href="#supplementary"> supplementary characters</a>. To support |
|
5245 |
* all Unicode characters, including supplementary characters, use |
|
5246 |
* the {@link #isUnicodeIdentifierStart(int)} method. |
|
5247 |
* |
|
5248 |
* @param ch the character to be tested. |
|
5249 |
* @return <code>true</code> if the character may start a Unicode |
|
5250 |
* identifier; <code>false</code> otherwise. |
|
5251 |
* @see java.lang.Character#isJavaIdentifierStart(char) |
|
5252 |
* @see java.lang.Character#isLetter(char) |
|
5253 |
* @see java.lang.Character#isUnicodeIdentifierPart(char) |
|
5254 |
* @since 1.1 |
|
5255 |
*/ |
|
5256 |
public static boolean isUnicodeIdentifierStart(char ch) { |
|
5257 |
return isUnicodeIdentifierStart((int)ch); |
|
5258 |
} |
|
5259 |
||
5260 |
/** |
|
5261 |
* Determines if the specified character (Unicode code point) is permissible as the |
|
5262 |
* first character in a Unicode identifier. |
|
5263 |
* <p> |
|
5264 |
* A character may start a Unicode identifier if and only if |
|
5265 |
* one of the following conditions is true: |
|
5266 |
* <ul> |
|
5267 |
* <li> {@link #isLetter(int) isLetter(codePoint)} |
|
5268 |
* returns <code>true</code> |
|
5269 |
* <li> {@link #getType(int) getType(codePoint)} |
|
5270 |
* returns <code>LETTER_NUMBER</code>. |
|
5271 |
* </ul> |
|
5272 |
* @param codePoint the character (Unicode code point) to be tested. |
|
5273 |
* @return <code>true</code> if the character may start a Unicode |
|
5274 |
* identifier; <code>false</code> otherwise. |
|
5275 |
* @see java.lang.Character#isJavaIdentifierStart(int) |
|
5276 |
* @see java.lang.Character#isLetter(int) |
|
5277 |
* @see java.lang.Character#isUnicodeIdentifierPart(int) |
|
5278 |
* @since 1.5 |
|
5279 |
*/ |
|
5280 |
public static boolean isUnicodeIdentifierStart(int codePoint) { |
|
5281 |
return CharacterData.of(codePoint).isUnicodeIdentifierStart(codePoint); |
|
5282 |
} |
|
5283 |
||
5284 |
/** |
|
5285 |
* Determines if the specified character may be part of a Unicode |
|
5286 |
* identifier as other than the first character. |
|
5287 |
* <p> |
|
5288 |
* A character may be part of a Unicode identifier if and only if |
|
5289 |
* one of the following statements is true: |
|
5290 |
* <ul> |
|
5291 |
* <li> it is a letter |
|
5292 |
* <li> it is a connecting punctuation character (such as <code>'_'</code>) |
|
5293 |
* <li> it is a digit |
|
5294 |
* <li> it is a numeric letter (such as a Roman numeral character) |
|
5295 |
* <li> it is a combining mark |
|
5296 |
* <li> it is a non-spacing mark |
|
5297 |
* <li> <code>isIdentifierIgnorable</code> returns |
|
5298 |
* <code>true</code> for this character. |
|
5299 |
* </ul> |
|
5300 |
* |
|
5301 |
* <p><b>Note:</b> This method cannot handle <a |
|
5302 |
* href="#supplementary"> supplementary characters</a>. To support |
|
5303 |
* all Unicode characters, including supplementary characters, use |
|
5304 |
* the {@link #isUnicodeIdentifierPart(int)} method. |
|
5305 |
* |
|
5306 |
* @param ch the character to be tested. |
|
5307 |
* @return <code>true</code> if the character may be part of a |
|
5308 |
* Unicode identifier; <code>false</code> otherwise. |
|
5309 |
* @see java.lang.Character#isIdentifierIgnorable(char) |
|
5310 |
* @see java.lang.Character#isJavaIdentifierPart(char) |
|
5311 |
* @see java.lang.Character#isLetterOrDigit(char) |
|
5312 |
* @see java.lang.Character#isUnicodeIdentifierStart(char) |
|
5313 |
* @since 1.1 |
|
5314 |
*/ |
|
5315 |
public static boolean isUnicodeIdentifierPart(char ch) { |
|
5316 |
return isUnicodeIdentifierPart((int)ch); |
|
5317 |
} |
|
5318 |
||
5319 |
/** |
|
5320 |
* Determines if the specified character (Unicode code point) may be part of a Unicode |
|
5321 |
* identifier as other than the first character. |
|
5322 |
* <p> |
|
5323 |
* A character may be part of a Unicode identifier if and only if |
|
5324 |
* one of the following statements is true: |
|
5325 |
* <ul> |
|
5326 |
* <li> it is a letter |
|
5327 |
* <li> it is a connecting punctuation character (such as <code>'_'</code>) |
|
5328 |
* <li> it is a digit |
|
5329 |
* <li> it is a numeric letter (such as a Roman numeral character) |
|
5330 |
* <li> it is a combining mark |
|
5331 |
* <li> it is a non-spacing mark |
|
5332 |
* <li> <code>isIdentifierIgnorable</code> returns |
|
5333 |
* <code>true</code> for this character. |
|
5334 |
* </ul> |
|
5335 |
* @param codePoint the character (Unicode code point) to be tested. |
|
5336 |
* @return <code>true</code> if the character may be part of a |
|
5337 |
* Unicode identifier; <code>false</code> otherwise. |
|
5338 |
* @see java.lang.Character#isIdentifierIgnorable(int) |
|
5339 |
* @see java.lang.Character#isJavaIdentifierPart(int) |
|
5340 |
* @see java.lang.Character#isLetterOrDigit(int) |
|
5341 |
* @see java.lang.Character#isUnicodeIdentifierStart(int) |
|
5342 |
* @since 1.5 |
|
5343 |
*/ |
|
5344 |
public static boolean isUnicodeIdentifierPart(int codePoint) { |
|
5345 |
return CharacterData.of(codePoint).isUnicodeIdentifierPart(codePoint); |
|
5346 |
} |
|
5347 |
||
5348 |
/** |
|
5349 |
* Determines if the specified character should be regarded as |
|
5350 |
* an ignorable character in a Java identifier or a Unicode identifier. |
|
5351 |
* <p> |
|
5352 |
* The following Unicode characters are ignorable in a Java identifier |
|
5353 |
* or a Unicode identifier: |
|
5354 |
* <ul> |
|
5355 |
* <li>ISO control characters that are not whitespace |
|
5356 |
* <ul> |
|
5357 |
* <li><code>'\u0000'</code> through <code>'\u0008'</code> |
|
5358 |
* <li><code>'\u000E'</code> through <code>'\u001B'</code> |
|
5359 |
* <li><code>'\u007F'</code> through <code>'\u009F'</code> |
|
5360 |
* </ul> |
|
5361 |
* |
|
5362 |
* <li>all characters that have the <code>FORMAT</code> general |
|
5363 |
* category value |
|
5364 |
* </ul> |
|
5365 |
* |
|
5366 |
* <p><b>Note:</b> This method cannot handle <a |
|
5367 |
* href="#supplementary"> supplementary characters</a>. To support |
|
5368 |
* all Unicode characters, including supplementary characters, use |
|
5369 |
* the {@link #isIdentifierIgnorable(int)} method. |
|
5370 |
* |
|
5371 |
* @param ch the character to be tested. |
|
5372 |
* @return <code>true</code> if the character is an ignorable control |
|
5373 |
* character that may be part of a Java or Unicode identifier; |
|
5374 |
* <code>false</code> otherwise. |
|
5375 |
* @see java.lang.Character#isJavaIdentifierPart(char) |
|
5376 |
* @see java.lang.Character#isUnicodeIdentifierPart(char) |
|
5377 |
* @since 1.1 |
|
5378 |
*/ |
|
5379 |
public static boolean isIdentifierIgnorable(char ch) { |
|
5380 |
return isIdentifierIgnorable((int)ch); |
|
5381 |
} |
|
5382 |
||
5383 |
/** |
|
5384 |
* Determines if the specified character (Unicode code point) should be regarded as |
|
5385 |
* an ignorable character in a Java identifier or a Unicode identifier. |
|
5386 |
* <p> |
|
5387 |
* The following Unicode characters are ignorable in a Java identifier |
|
5388 |
* or a Unicode identifier: |
|
5389 |
* <ul> |
|
5390 |
* <li>ISO control characters that are not whitespace |
|
5391 |
* <ul> |
|
5392 |
* <li><code>'\u0000'</code> through <code>'\u0008'</code> |
|
5393 |
* <li><code>'\u000E'</code> through <code>'\u001B'</code> |
|
5394 |
* <li><code>'\u007F'</code> through <code>'\u009F'</code> |
|
5395 |
* </ul> |
|
5396 |
* |
|
5397 |
* <li>all characters that have the <code>FORMAT</code> general |
|
5398 |
* category value |
|
5399 |
* </ul> |
|
5400 |
* |
|
5401 |
* @param codePoint the character (Unicode code point) to be tested. |
|
5402 |
* @return <code>true</code> if the character is an ignorable control |
|
5403 |
* character that may be part of a Java or Unicode identifier; |
|
5404 |
* <code>false</code> otherwise. |
|
5405 |
* @see java.lang.Character#isJavaIdentifierPart(int) |
|
5406 |
* @see java.lang.Character#isUnicodeIdentifierPart(int) |
|
5407 |
* @since 1.5 |
|
5408 |
*/ |
|
5409 |
public static boolean isIdentifierIgnorable(int codePoint) { |
|
5410 |
return CharacterData.of(codePoint).isIdentifierIgnorable(codePoint); |
|
5411 |
} |
|
5412 |
||
5413 |
/** |
|
5414 |
* Converts the character argument to lowercase using case |
|
5415 |
* mapping information from the UnicodeData file. |
|
5416 |
* <p> |
|
5417 |
* Note that |
|
5418 |
* <code>Character.isLowerCase(Character.toLowerCase(ch))</code> |
|
5419 |
* does not always return <code>true</code> for some ranges of |
|
5420 |
* characters, particularly those that are symbols or ideographs. |
|
5421 |
* |
|
5422 |
* <p>In general, {@link java.lang.String#toLowerCase()} should be used to map |
|
5423 |
* characters to lowercase. <code>String</code> case mapping methods |
|
5424 |
* have several benefits over <code>Character</code> case mapping methods. |
|
5425 |
* <code>String</code> case mapping methods can perform locale-sensitive |
|
5426 |
* mappings, context-sensitive mappings, and 1:M character mappings, whereas |
|
5427 |
* the <code>Character</code> case mapping methods cannot. |
|
5428 |
* |
|
5429 |
* <p><b>Note:</b> This method cannot handle <a |
|
5430 |
* href="#supplementary"> supplementary characters</a>. To support |
|
5431 |
* all Unicode characters, including supplementary characters, use |
|
5432 |
* the {@link #toLowerCase(int)} method. |
|
5433 |
* |
|
5434 |
* @param ch the character to be converted. |
|
5435 |
* @return the lowercase equivalent of the character, if any; |
|
5436 |
* otherwise, the character itself. |
|
5437 |
* @see java.lang.Character#isLowerCase(char) |
|
5438 |
* @see java.lang.String#toLowerCase() |
|
5439 |
*/ |
|
5440 |
public static char toLowerCase(char ch) { |
|
5441 |
return (char)toLowerCase((int)ch); |
|
5442 |
} |
|
5443 |
||
5444 |
/** |
|
5445 |
* Converts the character (Unicode code point) argument to |
|
5446 |
* lowercase using case mapping information from the UnicodeData |
|
5447 |
* file. |
|
5448 |
* |
|
5449 |
* <p> Note that |
|
5450 |
* <code>Character.isLowerCase(Character.toLowerCase(codePoint))</code> |
|
5451 |
* does not always return <code>true</code> for some ranges of |
|
5452 |
* characters, particularly those that are symbols or ideographs. |
|
5453 |
* |
|
5454 |
* <p>In general, {@link java.lang.String#toLowerCase()} should be used to map |
|
5455 |
* characters to lowercase. <code>String</code> case mapping methods |
|
5456 |
* have several benefits over <code>Character</code> case mapping methods. |
|
5457 |
* <code>String</code> case mapping methods can perform locale-sensitive |
|
5458 |
* mappings, context-sensitive mappings, and 1:M character mappings, whereas |
|
5459 |
* the <code>Character</code> case mapping methods cannot. |
|
5460 |
* |
|
5461 |
* @param codePoint the character (Unicode code point) to be converted. |
|
5462 |
* @return the lowercase equivalent of the character (Unicode code |
|
5463 |
* point), if any; otherwise, the character itself. |
|
5464 |
* @see java.lang.Character#isLowerCase(int) |
|
5465 |
* @see java.lang.String#toLowerCase() |
|
5466 |
* |
|
5467 |
* @since 1.5 |
|
5468 |
*/ |
|
5469 |
public static int toLowerCase(int codePoint) { |
|
5470 |
return CharacterData.of(codePoint).toLowerCase(codePoint); |
|
5471 |
} |
|
5472 |
||
5473 |
/** |
|
5474 |
* Converts the character argument to uppercase using case mapping |
|
5475 |
* information from the UnicodeData file. |
|
5476 |
* <p> |
|
5477 |
* Note that |
|
5478 |
* <code>Character.isUpperCase(Character.toUpperCase(ch))</code> |
|
5479 |
* does not always return <code>true</code> for some ranges of |
|
5480 |
* characters, particularly those that are symbols or ideographs. |
|
5481 |
* |
|
5482 |
* <p>In general, {@link java.lang.String#toUpperCase()} should be used to map |
|
5483 |
* characters to uppercase. <code>String</code> case mapping methods |
|
5484 |
* have several benefits over <code>Character</code> case mapping methods. |
|
5485 |
* <code>String</code> case mapping methods can perform locale-sensitive |
|
5486 |
* mappings, context-sensitive mappings, and 1:M character mappings, whereas |
|
5487 |
* the <code>Character</code> case mapping methods cannot. |
|
5488 |
* |
|
5489 |
* <p><b>Note:</b> This method cannot handle <a |
|
5490 |
* href="#supplementary"> supplementary characters</a>. To support |
|
5491 |
* all Unicode characters, including supplementary characters, use |
|
5492 |
* the {@link #toUpperCase(int)} method. |
|
5493 |
* |
|
5494 |
* @param ch the character to be converted. |
|
5495 |
* @return the uppercase equivalent of the character, if any; |
|
5496 |
* otherwise, the character itself. |
|
5497 |
* @see java.lang.Character#isUpperCase(char) |
|
5498 |
* @see java.lang.String#toUpperCase() |
|
5499 |
*/ |
|
5500 |
public static char toUpperCase(char ch) { |
|
5501 |
return (char)toUpperCase((int)ch); |
|
5502 |
} |
|
5503 |
||
5504 |
/** |
|
5505 |
* Converts the character (Unicode code point) argument to |
|
5506 |
* uppercase using case mapping information from the UnicodeData |
|
5507 |
* file. |
|
5508 |
* |
|
5509 |
* <p>Note that |
|
5510 |
* <code>Character.isUpperCase(Character.toUpperCase(codePoint))</code> |
|
5511 |
* does not always return <code>true</code> for some ranges of |
|
5512 |
* characters, particularly those that are symbols or ideographs. |
|
5513 |
* |
|
5514 |
* <p>In general, {@link java.lang.String#toUpperCase()} should be used to map |
|
5515 |
* characters to uppercase. <code>String</code> case mapping methods |
|
5516 |
* have several benefits over <code>Character</code> case mapping methods. |
|
5517 |
* <code>String</code> case mapping methods can perform locale-sensitive |
|
5518 |
* mappings, context-sensitive mappings, and 1:M character mappings, whereas |
|
5519 |
* the <code>Character</code> case mapping methods cannot. |
|
5520 |
* |
|
5521 |
* @param codePoint the character (Unicode code point) to be converted. |
|
5522 |
* @return the uppercase equivalent of the character, if any; |
|
5523 |
* otherwise, the character itself. |
|
5524 |
* @see java.lang.Character#isUpperCase(int) |
|
5525 |
* @see java.lang.String#toUpperCase() |
|
5526 |
* |
|
5527 |
* @since 1.5 |
|
5528 |
*/ |
|
5529 |
public static int toUpperCase(int codePoint) { |
|
5530 |
return CharacterData.of(codePoint).toUpperCase(codePoint); |
|
5531 |
} |
|
5532 |
||
5533 |
/** |
|
5534 |
* Converts the character argument to titlecase using case mapping |
|
5535 |
* information from the UnicodeData file. If a character has no |
|
5536 |
* explicit titlecase mapping and is not itself a titlecase char |
|
5537 |
* according to UnicodeData, then the uppercase mapping is |
|
5538 |
* returned as an equivalent titlecase mapping. If the |
|
5539 |
* <code>char</code> argument is already a titlecase |
|
5540 |
* <code>char</code>, the same <code>char</code> value will be |
|
5541 |
* returned. |
|
5542 |
* <p> |
|
5543 |
* Note that |
|
5544 |
* <code>Character.isTitleCase(Character.toTitleCase(ch))</code> |
|
5545 |
* does not always return <code>true</code> for some ranges of |
|
5546 |
* characters. |
|
5547 |
* |
|
5548 |
* <p><b>Note:</b> This method cannot handle <a |
|
5549 |
* href="#supplementary"> supplementary characters</a>. To support |
|
5550 |
* all Unicode characters, including supplementary characters, use |
|
5551 |
* the {@link #toTitleCase(int)} method. |
|
5552 |
* |
|
5553 |
* @param ch the character to be converted. |
|
5554 |
* @return the titlecase equivalent of the character, if any; |
|
5555 |
* otherwise, the character itself. |
|
5556 |
* @see java.lang.Character#isTitleCase(char) |
|
5557 |
* @see java.lang.Character#toLowerCase(char) |
|
5558 |
* @see java.lang.Character#toUpperCase(char) |
|
5559 |
* @since 1.0.2 |
|
5560 |
*/ |
|
5561 |
public static char toTitleCase(char ch) { |
|
5562 |
return (char)toTitleCase((int)ch); |
|
5563 |
} |
|
5564 |
||
5565 |
/** |
|
5566 |
* Converts the character (Unicode code point) argument to titlecase using case mapping |
|
5567 |
* information from the UnicodeData file. If a character has no |
|
5568 |
* explicit titlecase mapping and is not itself a titlecase char |
|
5569 |
* according to UnicodeData, then the uppercase mapping is |
|
5570 |
* returned as an equivalent titlecase mapping. If the |
|
5571 |
* character argument is already a titlecase |
|
5572 |
* character, the same character value will be |
|
5573 |
* returned. |
|
5574 |
* |
|
5575 |
* <p>Note that |
|
5576 |
* <code>Character.isTitleCase(Character.toTitleCase(codePoint))</code> |
|
5577 |
* does not always return <code>true</code> for some ranges of |
|
5578 |
* characters. |
|
5579 |
* |
|
5580 |
* @param codePoint the character (Unicode code point) to be converted. |
|
5581 |
* @return the titlecase equivalent of the character, if any; |
|
5582 |
* otherwise, the character itself. |
|
5583 |
* @see java.lang.Character#isTitleCase(int) |
|
5584 |
* @see java.lang.Character#toLowerCase(int) |
|
5585 |
* @see java.lang.Character#toUpperCase(int) |
|
5586 |
* @since 1.5 |
|
5587 |
*/ |
|
5588 |
public static int toTitleCase(int codePoint) { |
|
5589 |
return CharacterData.of(codePoint).toTitleCase(codePoint); |
|
5590 |
} |
|
5591 |
||
5592 |
/** |
|
5593 |
* Returns the numeric value of the character <code>ch</code> in the |
|
5594 |
* specified radix. |
|
5595 |
* <p> |
|
5596 |
* If the radix is not in the range <code>MIN_RADIX</code> <= |
|
5597 |
* <code>radix</code> <= <code>MAX_RADIX</code> or if the |
|
5598 |
* value of <code>ch</code> is not a valid digit in the specified |
|
5599 |
* radix, <code>-1</code> is returned. A character is a valid digit |
|
5600 |
* if at least one of the following is true: |
|
5601 |
* <ul> |
|
5602 |
* <li>The method <code>isDigit</code> is <code>true</code> of the character |
|
5603 |
* and the Unicode decimal digit value of the character (or its |
|
5604 |
* single-character decomposition) is less than the specified radix. |
|
5605 |
* In this case the decimal digit value is returned. |
|
5606 |
* <li>The character is one of the uppercase Latin letters |
|
5607 |
* <code>'A'</code> through <code>'Z'</code> and its code is less than |
|
5608 |
* <code>radix + 'A' - 10</code>. |
|
5609 |
* In this case, <code>ch - 'A' + 10</code> |
|
5610 |
* is returned. |
|
5611 |
* <li>The character is one of the lowercase Latin letters |
|
5612 |
* <code>'a'</code> through <code>'z'</code> and its code is less than |
|
5613 |
* <code>radix + 'a' - 10</code>. |
|
5614 |
* In this case, <code>ch - 'a' + 10</code> |
|
5615 |
* is returned. |
|
5616 |
* </ul> |
|
5617 |
* |
|
5618 |
* <p><b>Note:</b> This method cannot handle <a |
|
5619 |
* href="#supplementary"> supplementary characters</a>. To support |
|
5620 |
* all Unicode characters, including supplementary characters, use |
|
5621 |
* the {@link #digit(int, int)} method. |
|
5622 |
* |
|
5623 |
* @param ch the character to be converted. |
|
5624 |
* @param radix the radix. |
|
5625 |
* @return the numeric value represented by the character in the |
|
5626 |
* specified radix. |
|
5627 |
* @see java.lang.Character#forDigit(int, int) |
|
5628 |
* @see java.lang.Character#isDigit(char) |
|
5629 |
*/ |
|
5630 |
public static int digit(char ch, int radix) { |
|
5631 |
return digit((int)ch, radix); |
|
5632 |
} |
|
5633 |
||
5634 |
/** |
|
5635 |
* Returns the numeric value of the specified character (Unicode |
|
5636 |
* code point) in the specified radix. |
|
5637 |
* |
|
5638 |
* <p>If the radix is not in the range <code>MIN_RADIX</code> <= |
|
5639 |
* <code>radix</code> <= <code>MAX_RADIX</code> or if the |
|
5640 |
* character is not a valid digit in the specified |
|
5641 |
* radix, <code>-1</code> is returned. A character is a valid digit |
|
5642 |
* if at least one of the following is true: |
|
5643 |
* <ul> |
|
5644 |
* <li>The method {@link #isDigit(int) isDigit(codePoint)} is <code>true</code> of the character |
|
5645 |
* and the Unicode decimal digit value of the character (or its |
|
5646 |
* single-character decomposition) is less than the specified radix. |
|
5647 |
* In this case the decimal digit value is returned. |
|
5648 |
* <li>The character is one of the uppercase Latin letters |
|
5649 |
* <code>'A'</code> through <code>'Z'</code> and its code is less than |
|
5650 |
* <code>radix + 'A' - 10</code>. |
|
5651 |
* In this case, <code>ch - 'A' + 10</code> |
|
5652 |
* is returned. |
|
5653 |
* <li>The character is one of the lowercase Latin letters |
|
5654 |
* <code>'a'</code> through <code>'z'</code> and its code is less than |
|
5655 |
* <code>radix + 'a' - 10</code>. |
|
5656 |
* In this case, <code>ch - 'a' + 10</code> |
|
5657 |
* is returned. |
|
5658 |
* </ul> |
|
5659 |
* |
|
5660 |
* @param codePoint the character (Unicode code point) to be converted. |
|
5661 |
* @param radix the radix. |
|
5662 |
* @return the numeric value represented by the character in the |
|
5663 |
* specified radix. |
|
5664 |
* @see java.lang.Character#forDigit(int, int) |
|
5665 |
* @see java.lang.Character#isDigit(int) |
|
5666 |
* @since 1.5 |
|
5667 |
*/ |
|
5668 |
public static int digit(int codePoint, int radix) { |
|
5669 |
return CharacterData.of(codePoint).digit(codePoint, radix); |
|
5670 |
} |
|
5671 |
||
5672 |
/** |
|
5673 |
* Returns the <code>int</code> value that the specified Unicode |
|
5674 |
* character represents. For example, the character |
|
5675 |
* <code>'\u216C'</code> (the roman numeral fifty) will return |
|
5676 |
* an int with a value of 50. |
|
5677 |
* <p> |
|
5678 |
* The letters A-Z in their uppercase (<code>'\u0041'</code> through |
|
5679 |
* <code>'\u005A'</code>), lowercase |
|
5680 |
* (<code>'\u0061'</code> through <code>'\u007A'</code>), and |
|
5681 |
* full width variant (<code>'\uFF21'</code> through |
|
5682 |
* <code>'\uFF3A'</code> and <code>'\uFF41'</code> through |
|
5683 |
* <code>'\uFF5A'</code>) forms have numeric values from 10 |
|
5684 |
* through 35. This is independent of the Unicode specification, |
|
5685 |
* which does not assign numeric values to these <code>char</code> |
|
5686 |
* values. |
|
5687 |
* <p> |
|
5688 |
* If the character does not have a numeric value, then -1 is returned. |
|
5689 |
* If the character has a numeric value that cannot be represented as a |
|
5690 |
* nonnegative integer (for example, a fractional value), then -2 |
|
5691 |
* is returned. |
|
5692 |
* |
|
5693 |
* <p><b>Note:</b> This method cannot handle <a |
|
5694 |
* href="#supplementary"> supplementary characters</a>. To support |
|
5695 |
* all Unicode characters, including supplementary characters, use |
|
5696 |
* the {@link #getNumericValue(int)} method. |
|
5697 |
* |
|
5698 |
* @param ch the character to be converted. |
|
5699 |
* @return the numeric value of the character, as a nonnegative <code>int</code> |
|
5700 |
* value; -2 if the character has a numeric value that is not a |
|
5701 |
* nonnegative integer; -1 if the character has no numeric value. |
|
5702 |
* @see java.lang.Character#forDigit(int, int) |
|
5703 |
* @see java.lang.Character#isDigit(char) |
|
5704 |
* @since 1.1 |
|
5705 |
*/ |
|
5706 |
public static int getNumericValue(char ch) { |
|
5707 |
return getNumericValue((int)ch); |
|
5708 |
} |
|
5709 |
||
5710 |
/** |
|
5711 |
* Returns the <code>int</code> value that the specified |
|
5712 |
* character (Unicode code point) represents. For example, the character |
|
5713 |
* <code>'\u216C'</code> (the Roman numeral fifty) will return |
|
5714 |
* an <code>int</code> with a value of 50. |
|
5715 |
* <p> |
|
5716 |
* The letters A-Z in their uppercase (<code>'\u0041'</code> through |
|
5717 |
* <code>'\u005A'</code>), lowercase |
|
5718 |
* (<code>'\u0061'</code> through <code>'\u007A'</code>), and |
|
5719 |
* full width variant (<code>'\uFF21'</code> through |
|
5720 |
* <code>'\uFF3A'</code> and <code>'\uFF41'</code> through |
|
5721 |
* <code>'\uFF5A'</code>) forms have numeric values from 10 |
|
5722 |
* through 35. This is independent of the Unicode specification, |
|
5723 |
* which does not assign numeric values to these <code>char</code> |
|
5724 |
* values. |
|
5725 |
* <p> |
|
5726 |
* If the character does not have a numeric value, then -1 is returned. |
|
5727 |
* If the character has a numeric value that cannot be represented as a |
|
5728 |
* nonnegative integer (for example, a fractional value), then -2 |
|
5729 |
* is returned. |
|
5730 |
* |
|
5731 |
* @param codePoint the character (Unicode code point) to be converted. |
|
5732 |
* @return the numeric value of the character, as a nonnegative <code>int</code> |
|
5733 |
* value; -2 if the character has a numeric value that is not a |
|
5734 |
* nonnegative integer; -1 if the character has no numeric value. |
|
5735 |
* @see java.lang.Character#forDigit(int, int) |
|
5736 |
* @see java.lang.Character#isDigit(int) |
|
5737 |
* @since 1.5 |
|
5738 |
*/ |
|
5739 |
public static int getNumericValue(int codePoint) { |
|
5740 |
return CharacterData.of(codePoint).getNumericValue(codePoint); |
|
5741 |
} |
|
5742 |
||
5743 |
/** |
|
5744 |
* Determines if the specified character is ISO-LATIN-1 white space. |
|
5745 |
* This method returns <code>true</code> for the following five |
|
5746 |
* characters only: |
|
5747 |
* <table> |
|
5748 |
* <tr><td><code>'\t'</code></td> <td><code>'\u0009'</code></td> |
|
5749 |
* <td><code>HORIZONTAL TABULATION</code></td></tr> |
|
5750 |
* <tr><td><code>'\n'</code></td> <td><code>'\u000A'</code></td> |
|
5751 |
* <td><code>NEW LINE</code></td></tr> |
|
5752 |
* <tr><td><code>'\f'</code></td> <td><code>'\u000C'</code></td> |
|
5753 |
* <td><code>FORM FEED</code></td></tr> |
|
5754 |
* <tr><td><code>'\r'</code></td> <td><code>'\u000D'</code></td> |
|
5755 |
* <td><code>CARRIAGE RETURN</code></td></tr> |
|
5756 |
* <tr><td><code>' '</code></td> <td><code>'\u0020'</code></td> |
|
5757 |
* <td><code>SPACE</code></td></tr> |
|
5758 |
* </table> |
|
5759 |
* |
|
5760 |
* @param ch the character to be tested. |
|
5761 |
* @return <code>true</code> if the character is ISO-LATIN-1 white |
|
5762 |
* space; <code>false</code> otherwise. |
|
5763 |
* @see java.lang.Character#isSpaceChar(char) |
|
5764 |
* @see java.lang.Character#isWhitespace(char) |
|
5765 |
* @deprecated Replaced by isWhitespace(char). |
|
5766 |
*/ |
|
5767 |
@Deprecated |
|
5768 |
public static boolean isSpace(char ch) { |
|
5769 |
return (ch <= 0x0020) && |
|
5770 |
(((((1L << 0x0009) | |
|
5771 |
(1L << 0x000A) | |
|
5772 |
(1L << 0x000C) | |
|
5773 |
(1L << 0x000D) | |
|
5774 |
(1L << 0x0020)) >> ch) & 1L) != 0); |
|
5775 |
} |
|
5776 |
||
5777 |
||
5778 |
/** |
|
5779 |
* Determines if the specified character is a Unicode space character. |
|
5780 |
* A character is considered to be a space character if and only if |
|
5781 |
* it is specified to be a space character by the Unicode standard. This |
|
5782 |
* method returns true if the character's general category type is any of |
|
5783 |
* the following: |
|
5784 |
* <ul> |
|
5785 |
* <li> <code>SPACE_SEPARATOR</code> |
|
5786 |
* <li> <code>LINE_SEPARATOR</code> |
|
5787 |
* <li> <code>PARAGRAPH_SEPARATOR</code> |
|
5788 |
* </ul> |
|
5789 |
* |
|
5790 |
* <p><b>Note:</b> This method cannot handle <a |
|
5791 |
* href="#supplementary"> supplementary characters</a>. To support |
|
5792 |
* all Unicode characters, including supplementary characters, use |
|
5793 |
* the {@link #isSpaceChar(int)} method. |
|
5794 |
* |
|
5795 |
* @param ch the character to be tested. |
|
5796 |
* @return <code>true</code> if the character is a space character; |
|
5797 |
* <code>false</code> otherwise. |
|
5798 |
* @see java.lang.Character#isWhitespace(char) |
|
5799 |
* @since 1.1 |
|
5800 |
*/ |
|
5801 |
public static boolean isSpaceChar(char ch) { |
|
5802 |
return isSpaceChar((int)ch); |
|
5803 |
} |
|
5804 |
||
5805 |
/** |
|
5806 |
* Determines if the specified character (Unicode code point) is a |
|
5807 |
* Unicode space character. A character is considered to be a |
|
5808 |
* space character if and only if it is specified to be a space |
|
5809 |
* character by the Unicode standard. This method returns true if |
|
5810 |
* the character's general category type is any of the following: |
|
5811 |
* |
|
5812 |
* <ul> |
|
5813 |
* <li> {@link #SPACE_SEPARATOR} |
|
5814 |
* <li> {@link #LINE_SEPARATOR} |
|
5815 |
* <li> {@link #PARAGRAPH_SEPARATOR} |
|
5816 |
* </ul> |
|
5817 |
* |
|
5818 |
* @param codePoint the character (Unicode code point) to be tested. |
|
5819 |
* @return <code>true</code> if the character is a space character; |
|
5820 |
* <code>false</code> otherwise. |
|
5821 |
* @see java.lang.Character#isWhitespace(int) |
|
5822 |
* @since 1.5 |
|
5823 |
*/ |
|
5824 |
public static boolean isSpaceChar(int codePoint) { |
|
5825 |
return ((((1 << Character.SPACE_SEPARATOR) | |
|
5826 |
(1 << Character.LINE_SEPARATOR) | |
|
5827 |
(1 << Character.PARAGRAPH_SEPARATOR)) >> getType(codePoint)) & 1) |
|
5828 |
!= 0; |
|
5829 |
} |
|
5830 |
||
5831 |
/** |
|
5832 |
* Determines if the specified character is white space according to Java. |
|
5833 |
* A character is a Java whitespace character if and only if it satisfies |
|
5834 |
* one of the following criteria: |
|
5835 |
* <ul> |
|
5836 |
* <li> It is a Unicode space character (<code>SPACE_SEPARATOR</code>, |
|
5837 |
* <code>LINE_SEPARATOR</code>, or <code>PARAGRAPH_SEPARATOR</code>) |
|
5838 |
* but is not also a non-breaking space (<code>'\u00A0'</code>, |
|
5839 |
* <code>'\u2007'</code>, <code>'\u202F'</code>). |
|
5840 |
* <li> It is <code>'\u0009'</code>, HORIZONTAL TABULATION. |
|
5841 |
* <li> It is <code>'\u000A'</code>, LINE FEED. |
|
5842 |
* <li> It is <code>'\u000B'</code>, VERTICAL TABULATION. |
|
5843 |
* <li> It is <code>'\u000C'</code>, FORM FEED. |
|
5844 |
* <li> It is <code>'\u000D'</code>, CARRIAGE RETURN. |
|
5845 |
* <li> It is <code>'\u001C'</code>, FILE SEPARATOR. |
|
5846 |
* <li> It is <code>'\u001D'</code>, GROUP SEPARATOR. |
|
5847 |
* <li> It is <code>'\u001E'</code>, RECORD SEPARATOR. |
|
5848 |
* <li> It is <code>'\u001F'</code>, UNIT SEPARATOR. |
|
5849 |
* </ul> |
|
5850 |
* |
|
5851 |
* <p><b>Note:</b> This method cannot handle <a |
|
5852 |
* href="#supplementary"> supplementary characters</a>. To support |
|
5853 |
* all Unicode characters, including supplementary characters, use |
|
5854 |
* the {@link #isWhitespace(int)} method. |
|
5855 |
* |
|
5856 |
* @param ch the character to be tested. |
|
5857 |
* @return <code>true</code> if the character is a Java whitespace |
|
5858 |
* character; <code>false</code> otherwise. |
|
5859 |
* @see java.lang.Character#isSpaceChar(char) |
|
5860 |
* @since 1.1 |
|
5861 |
*/ |
|
5862 |
public static boolean isWhitespace(char ch) { |
|
5863 |
return isWhitespace((int)ch); |
|
5864 |
} |
|
5865 |
||
5866 |
/** |
|
5867 |
* Determines if the specified character (Unicode code point) is |
|
5868 |
* white space according to Java. A character is a Java |
|
5869 |
* whitespace character if and only if it satisfies one of the |
|
5870 |
* following criteria: |
|
5871 |
* <ul> |
|
5872 |
* <li> It is a Unicode space character ({@link #SPACE_SEPARATOR}, |
|
5873 |
* {@link #LINE_SEPARATOR}, or {@link #PARAGRAPH_SEPARATOR}) |
|
5874 |
* but is not also a non-breaking space (<code>'\u00A0'</code>, |
|
5875 |
* <code>'\u2007'</code>, <code>'\u202F'</code>). |
|
5876 |
* <li> It is <code>'\u0009'</code>, HORIZONTAL TABULATION. |
|
5877 |
* <li> It is <code>'\u000A'</code>, LINE FEED. |
|
5878 |
* <li> It is <code>'\u000B'</code>, VERTICAL TABULATION. |
|
5879 |
* <li> It is <code>'\u000C'</code>, FORM FEED. |
|
5880 |
* <li> It is <code>'\u000D'</code>, CARRIAGE RETURN. |
|
5881 |
* <li> It is <code>'\u001C'</code>, FILE SEPARATOR. |
|
5882 |
* <li> It is <code>'\u001D'</code>, GROUP SEPARATOR. |
|
5883 |
* <li> It is <code>'\u001E'</code>, RECORD SEPARATOR. |
|
5884 |
* <li> It is <code>'\u001F'</code>, UNIT SEPARATOR. |
|
5885 |
* </ul> |
|
5886 |
* <p> |
|
5887 |
* |
|
5888 |
* @param codePoint the character (Unicode code point) to be tested. |
|
5889 |
* @return <code>true</code> if the character is a Java whitespace |
|
5890 |
* character; <code>false</code> otherwise. |
|
5891 |
* @see java.lang.Character#isSpaceChar(int) |
|
5892 |
* @since 1.5 |
|
5893 |
*/ |
|
5894 |
public static boolean isWhitespace(int codePoint) { |
|
5895 |
return CharacterData.of(codePoint).isWhitespace(codePoint); |
|
5896 |
} |
|
5897 |
||
5898 |
/** |
|
5899 |
* Determines if the specified character is an ISO control |
|
5900 |
* character. A character is considered to be an ISO control |
|
5901 |
* character if its code is in the range <code>'\u0000'</code> |
|
5902 |
* through <code>'\u001F'</code> or in the range |
|
5903 |
* <code>'\u007F'</code> through <code>'\u009F'</code>. |
|
5904 |
* |
|
5905 |
* <p><b>Note:</b> This method cannot handle <a |
|
5906 |
* href="#supplementary"> supplementary characters</a>. To support |
|
5907 |
* all Unicode characters, including supplementary characters, use |
|
5908 |
* the {@link #isISOControl(int)} method. |
|
5909 |
* |
|
5910 |
* @param ch the character to be tested. |
|
5911 |
* @return <code>true</code> if the character is an ISO control character; |
|
5912 |
* <code>false</code> otherwise. |
|
5913 |
* |
|
5914 |
* @see java.lang.Character#isSpaceChar(char) |
|
5915 |
* @see java.lang.Character#isWhitespace(char) |
|
5916 |
* @since 1.1 |
|
5917 |
*/ |
|
5918 |
public static boolean isISOControl(char ch) { |
|
5919 |
return isISOControl((int)ch); |
|
5920 |
} |
|
5921 |
||
5922 |
/** |
|
5923 |
* Determines if the referenced character (Unicode code point) is an ISO control |
|
5924 |
* character. A character is considered to be an ISO control |
|
5925 |
* character if its code is in the range <code>'\u0000'</code> |
|
5926 |
* through <code>'\u001F'</code> or in the range |
|
5927 |
* <code>'\u007F'</code> through <code>'\u009F'</code>. |
|
5928 |
* |
|
5929 |
* @param codePoint the character (Unicode code point) to be tested. |
|
5930 |
* @return <code>true</code> if the character is an ISO control character; |
|
5931 |
* <code>false</code> otherwise. |
|
5932 |
* @see java.lang.Character#isSpaceChar(int) |
|
5933 |
* @see java.lang.Character#isWhitespace(int) |
|
5934 |
* @since 1.5 |
|
5935 |
*/ |
|
5936 |
public static boolean isISOControl(int codePoint) { |
|
5937 |
return (codePoint >= 0x0000 && codePoint <= 0x001F) || |
|
5938 |
(codePoint >= 0x007F && codePoint <= 0x009F); |
|
5939 |
} |
|
5940 |
||
5941 |
/** |
|
5942 |
* Returns a value indicating a character's general category. |
|
5943 |
* |
|
5944 |
* <p><b>Note:</b> This method cannot handle <a |
|
5945 |
* href="#supplementary"> supplementary characters</a>. To support |
|
5946 |
* all Unicode characters, including supplementary characters, use |
|
5947 |
* the {@link #getType(int)} method. |
|
5948 |
* |
|
5949 |
* @param ch the character to be tested. |
|
5950 |
* @return a value of type <code>int</code> representing the |
|
5951 |
* character's general category. |
|
5952 |
* @see java.lang.Character#COMBINING_SPACING_MARK |
|
5953 |
* @see java.lang.Character#CONNECTOR_PUNCTUATION |
|
5954 |
* @see java.lang.Character#CONTROL |
|
5955 |
* @see java.lang.Character#CURRENCY_SYMBOL |
|
5956 |
* @see java.lang.Character#DASH_PUNCTUATION |
|
5957 |
* @see java.lang.Character#DECIMAL_DIGIT_NUMBER |
|
5958 |
* @see java.lang.Character#ENCLOSING_MARK |
|
5959 |
* @see java.lang.Character#END_PUNCTUATION |
|
5960 |
* @see java.lang.Character#FINAL_QUOTE_PUNCTUATION |
|
5961 |
* @see java.lang.Character#FORMAT |
|
5962 |
* @see java.lang.Character#INITIAL_QUOTE_PUNCTUATION |
|
5963 |
* @see java.lang.Character#LETTER_NUMBER |
|
5964 |
* @see java.lang.Character#LINE_SEPARATOR |
|
5965 |
* @see java.lang.Character#LOWERCASE_LETTER |
|
5966 |
* @see java.lang.Character#MATH_SYMBOL |
|
5967 |
* @see java.lang.Character#MODIFIER_LETTER |
|
5968 |
* @see java.lang.Character#MODIFIER_SYMBOL |
|
5969 |
* @see java.lang.Character#NON_SPACING_MARK |
|
5970 |
* @see java.lang.Character#OTHER_LETTER |
|
5971 |
* @see java.lang.Character#OTHER_NUMBER |
|
5972 |
* @see java.lang.Character#OTHER_PUNCTUATION |
|
5973 |
* @see java.lang.Character#OTHER_SYMBOL |
|
5974 |
* @see java.lang.Character#PARAGRAPH_SEPARATOR |
|
5975 |
* @see java.lang.Character#PRIVATE_USE |
|
5976 |
* @see java.lang.Character#SPACE_SEPARATOR |
|
5977 |
* @see java.lang.Character#START_PUNCTUATION |
|
5978 |
* @see java.lang.Character#SURROGATE |
|
5979 |
* @see java.lang.Character#TITLECASE_LETTER |
|
5980 |
* @see java.lang.Character#UNASSIGNED |
|
5981 |
* @see java.lang.Character#UPPERCASE_LETTER |
|
5982 |
* @since 1.1 |
|
5983 |
*/ |
|
5984 |
public static int getType(char ch) { |
|
5985 |
return getType((int)ch); |
|
5986 |
} |
|
5987 |
||
5988 |
/** |
|
5989 |
* Returns a value indicating a character's general category. |
|
5990 |
* |
|
5991 |
* @param codePoint the character (Unicode code point) to be tested. |
|
5992 |
* @return a value of type <code>int</code> representing the |
|
5993 |
* character's general category. |
|
5994 |
* @see Character#COMBINING_SPACING_MARK COMBINING_SPACING_MARK |
|
5995 |
* @see Character#CONNECTOR_PUNCTUATION CONNECTOR_PUNCTUATION |
|
5996 |
* @see Character#CONTROL CONTROL |
|
5997 |
* @see Character#CURRENCY_SYMBOL CURRENCY_SYMBOL |
|
5998 |
* @see Character#DASH_PUNCTUATION DASH_PUNCTUATION |
|
5999 |
* @see Character#DECIMAL_DIGIT_NUMBER DECIMAL_DIGIT_NUMBER |
|
6000 |
* @see Character#ENCLOSING_MARK ENCLOSING_MARK |
|
6001 |
* @see Character#END_PUNCTUATION END_PUNCTUATION |
|
6002 |
* @see Character#FINAL_QUOTE_PUNCTUATION FINAL_QUOTE_PUNCTUATION |
|
6003 |
* @see Character#FORMAT FORMAT |
|
6004 |
* @see Character#INITIAL_QUOTE_PUNCTUATION INITIAL_QUOTE_PUNCTUATION |
|
6005 |
* @see Character#LETTER_NUMBER LETTER_NUMBER |
|
6006 |
* @see Character#LINE_SEPARATOR LINE_SEPARATOR |
|
6007 |
* @see Character#LOWERCASE_LETTER LOWERCASE_LETTER |
|
6008 |
* @see Character#MATH_SYMBOL MATH_SYMBOL |
|
6009 |
* @see Character#MODIFIER_LETTER MODIFIER_LETTER |
|
6010 |
* @see Character#MODIFIER_SYMBOL MODIFIER_SYMBOL |
|
6011 |
* @see Character#NON_SPACING_MARK NON_SPACING_MARK |
|
6012 |
* @see Character#OTHER_LETTER OTHER_LETTER |
|
6013 |
* @see Character#OTHER_NUMBER OTHER_NUMBER |
|
6014 |
* @see Character#OTHER_PUNCTUATION OTHER_PUNCTUATION |
|
6015 |
* @see Character#OTHER_SYMBOL OTHER_SYMBOL |
|
6016 |
* @see Character#PARAGRAPH_SEPARATOR PARAGRAPH_SEPARATOR |
|
6017 |
* @see Character#PRIVATE_USE PRIVATE_USE |
|
6018 |
* @see Character#SPACE_SEPARATOR SPACE_SEPARATOR |
|
6019 |
* @see Character#START_PUNCTUATION START_PUNCTUATION |
|
6020 |
* @see Character#SURROGATE SURROGATE |
|
6021 |
* @see Character#TITLECASE_LETTER TITLECASE_LETTER |
|
6022 |
* @see Character#UNASSIGNED UNASSIGNED |
|
6023 |
* @see Character#UPPERCASE_LETTER UPPERCASE_LETTER |
|
6024 |
* @since 1.5 |
|
6025 |
*/ |
|
6026 |
public static int getType(int codePoint) { |
|
6027 |
return CharacterData.of(codePoint).getType(codePoint); |
|
6028 |
} |
|
6029 |
||
6030 |
/** |
|
6031 |
* Determines the character representation for a specific digit in |
|
6032 |
* the specified radix. If the value of <code>radix</code> is not a |
|
6033 |
* valid radix, or the value of <code>digit</code> is not a valid |
|
6034 |
* digit in the specified radix, the null character |
|
6035 |
* (<code>'\u0000'</code>) is returned. |
|
6036 |
* <p> |
|
6037 |
* The <code>radix</code> argument is valid if it is greater than or |
|
6038 |
* equal to <code>MIN_RADIX</code> and less than or equal to |
|
6039 |
* <code>MAX_RADIX</code>. The <code>digit</code> argument is valid if |
|
6040 |
* <code>0 <=digit < radix</code>. |
|
6041 |
* <p> |
|
6042 |
* If the digit is less than 10, then |
|
6043 |
* <code>'0' + digit</code> is returned. Otherwise, the value |
|
6044 |
* <code>'a' + digit - 10</code> is returned. |
|
6045 |
* |
|
6046 |
* @param digit the number to convert to a character. |
|
6047 |
* @param radix the radix. |
|
6048 |
* @return the <code>char</code> representation of the specified digit |
|
6049 |
* in the specified radix. |
|
6050 |
* @see java.lang.Character#MIN_RADIX |
|
6051 |
* @see java.lang.Character#MAX_RADIX |
|
6052 |
* @see java.lang.Character#digit(char, int) |
|
6053 |
*/ |
|
6054 |
public static char forDigit(int digit, int radix) { |
|
6055 |
if ((digit >= radix) || (digit < 0)) { |
|
6056 |
return '\0'; |
|
6057 |
} |
|
6058 |
if ((radix < Character.MIN_RADIX) || (radix > Character.MAX_RADIX)) { |
|
6059 |
return '\0'; |
|
6060 |
} |
|
6061 |
if (digit < 10) { |
|
6062 |
return (char)('0' + digit); |
|
6063 |
} |
|
6064 |
return (char)('a' - 10 + digit); |
|
6065 |
} |
|
6066 |
||
6067 |
/** |
|
6068 |
* Returns the Unicode directionality property for the given |
|
6069 |
* character. Character directionality is used to calculate the |
|
6070 |
* visual ordering of text. The directionality value of undefined |
|
6071 |
* <code>char</code> values is <code>DIRECTIONALITY_UNDEFINED</code>. |
|
6072 |
* |
|
6073 |
* <p><b>Note:</b> This method cannot handle <a |
|
6074 |
* href="#supplementary"> supplementary characters</a>. To support |
|
6075 |
* all Unicode characters, including supplementary characters, use |
|
6076 |
* the {@link #getDirectionality(int)} method. |
|
6077 |
* |
|
6078 |
* @param ch <code>char</code> for which the directionality property |
|
6079 |
* is requested. |
|
6080 |
* @return the directionality property of the <code>char</code> value. |
|
6081 |
* |
|
6082 |
* @see Character#DIRECTIONALITY_UNDEFINED |
|
6083 |
* @see Character#DIRECTIONALITY_LEFT_TO_RIGHT |
|
6084 |
* @see Character#DIRECTIONALITY_RIGHT_TO_LEFT |
|
6085 |
* @see Character#DIRECTIONALITY_RIGHT_TO_LEFT_ARABIC |
|
6086 |
* @see Character#DIRECTIONALITY_EUROPEAN_NUMBER |
|
6087 |
* @see Character#DIRECTIONALITY_EUROPEAN_NUMBER_SEPARATOR |
|
6088 |
* @see Character#DIRECTIONALITY_EUROPEAN_NUMBER_TERMINATOR |
|
6089 |
* @see Character#DIRECTIONALITY_ARABIC_NUMBER |
|
6090 |
* @see Character#DIRECTIONALITY_COMMON_NUMBER_SEPARATOR |
|
6091 |
* @see Character#DIRECTIONALITY_NONSPACING_MARK |
|
6092 |
* @see Character#DIRECTIONALITY_BOUNDARY_NEUTRAL |
|
6093 |
* @see Character#DIRECTIONALITY_PARAGRAPH_SEPARATOR |
|
6094 |
* @see Character#DIRECTIONALITY_SEGMENT_SEPARATOR |
|
6095 |
* @see Character#DIRECTIONALITY_WHITESPACE |
|
6096 |
* @see Character#DIRECTIONALITY_OTHER_NEUTRALS |
|
6097 |
* @see Character#DIRECTIONALITY_LEFT_TO_RIGHT_EMBEDDING |
|
6098 |
* @see Character#DIRECTIONALITY_LEFT_TO_RIGHT_OVERRIDE |
|
6099 |
* @see Character#DIRECTIONALITY_RIGHT_TO_LEFT_EMBEDDING |
|
6100 |
* @see Character#DIRECTIONALITY_RIGHT_TO_LEFT_OVERRIDE |
|
6101 |
* @see Character#DIRECTIONALITY_POP_DIRECTIONAL_FORMAT |
|
6102 |
* @since 1.4 |
|
6103 |
*/ |
|
6104 |
public static byte getDirectionality(char ch) { |
|
6105 |
return getDirectionality((int)ch); |
|
6106 |
} |
|
6107 |
||
6108 |
/** |
|
6109 |
* Returns the Unicode directionality property for the given |
|
6110 |
* character (Unicode code point). Character directionality is |
|
6111 |
* used to calculate the visual ordering of text. The |
|
6112 |
* directionality value of undefined character is {@link |
|
6113 |
* #DIRECTIONALITY_UNDEFINED}. |
|
6114 |
* |
|
6115 |
* @param codePoint the character (Unicode code point) for which |
|
6116 |
* the directionality property is requested. |
|
6117 |
* @return the directionality property of the character. |
|
6118 |
* |
|
6119 |
* @see Character#DIRECTIONALITY_UNDEFINED DIRECTIONALITY_UNDEFINED |
|
6120 |
* @see Character#DIRECTIONALITY_LEFT_TO_RIGHT DIRECTIONALITY_LEFT_TO_RIGHT |
|
6121 |
* @see Character#DIRECTIONALITY_RIGHT_TO_LEFT DIRECTIONALITY_RIGHT_TO_LEFT |
|
6122 |
* @see Character#DIRECTIONALITY_RIGHT_TO_LEFT_ARABIC DIRECTIONALITY_RIGHT_TO_LEFT_ARABIC |
|
6123 |
* @see Character#DIRECTIONALITY_EUROPEAN_NUMBER DIRECTIONALITY_EUROPEAN_NUMBER |
|
6124 |
* @see Character#DIRECTIONALITY_EUROPEAN_NUMBER_SEPARATOR DIRECTIONALITY_EUROPEAN_NUMBER_SEPARATOR |
|
6125 |
* @see Character#DIRECTIONALITY_EUROPEAN_NUMBER_TERMINATOR DIRECTIONALITY_EUROPEAN_NUMBER_TERMINATOR |
|
6126 |
* @see Character#DIRECTIONALITY_ARABIC_NUMBER DIRECTIONALITY_ARABIC_NUMBER |
|
6127 |
* @see Character#DIRECTIONALITY_COMMON_NUMBER_SEPARATOR DIRECTIONALITY_COMMON_NUMBER_SEPARATOR |
|
6128 |
* @see Character#DIRECTIONALITY_NONSPACING_MARK DIRECTIONALITY_NONSPACING_MARK |
|
6129 |
* @see Character#DIRECTIONALITY_BOUNDARY_NEUTRAL DIRECTIONALITY_BOUNDARY_NEUTRAL |
|
6130 |
* @see Character#DIRECTIONALITY_PARAGRAPH_SEPARATOR DIRECTIONALITY_PARAGRAPH_SEPARATOR |
|
6131 |
* @see Character#DIRECTIONALITY_SEGMENT_SEPARATOR DIRECTIONALITY_SEGMENT_SEPARATOR |
|
6132 |
* @see Character#DIRECTIONALITY_WHITESPACE DIRECTIONALITY_WHITESPACE |
|
6133 |
* @see Character#DIRECTIONALITY_OTHER_NEUTRALS DIRECTIONALITY_OTHER_NEUTRALS |
|
6134 |
* @see Character#DIRECTIONALITY_LEFT_TO_RIGHT_EMBEDDING DIRECTIONALITY_LEFT_TO_RIGHT_EMBEDDING |
|
6135 |
* @see Character#DIRECTIONALITY_LEFT_TO_RIGHT_OVERRIDE DIRECTIONALITY_LEFT_TO_RIGHT_OVERRIDE |
|
6136 |
* @see Character#DIRECTIONALITY_RIGHT_TO_LEFT_EMBEDDING DIRECTIONALITY_RIGHT_TO_LEFT_EMBEDDING |
|
6137 |
* @see Character#DIRECTIONALITY_RIGHT_TO_LEFT_OVERRIDE DIRECTIONALITY_RIGHT_TO_LEFT_OVERRIDE |
|
6138 |
* @see Character#DIRECTIONALITY_POP_DIRECTIONAL_FORMAT DIRECTIONALITY_POP_DIRECTIONAL_FORMAT |
|
6139 |
* @since 1.5 |
|
6140 |
*/ |
|
6141 |
public static byte getDirectionality(int codePoint) { |
|
6142 |
return CharacterData.of(codePoint).getDirectionality(codePoint); |
|
6143 |
} |
|
6144 |
||
6145 |
/** |
|
6146 |
* Determines whether the character is mirrored according to the |
|
6147 |
* Unicode specification. Mirrored characters should have their |
|
6148 |
* glyphs horizontally mirrored when displayed in text that is |
|
6149 |
* right-to-left. For example, <code>'\u0028'</code> LEFT |
|
6150 |
* PARENTHESIS is semantically defined to be an <i>opening |
|
6151 |
* parenthesis</i>. This will appear as a "(" in text that is |
|
6152 |
* left-to-right but as a ")" in text that is right-to-left. |
|
6153 |
* |
|
6154 |
* <p><b>Note:</b> This method cannot handle <a |
|
6155 |
* href="#supplementary"> supplementary characters</a>. To support |
|
6156 |
* all Unicode characters, including supplementary characters, use |
|
6157 |
* the {@link #isMirrored(int)} method. |
|
6158 |
* |
|
6159 |
* @param ch <code>char</code> for which the mirrored property is requested |
|
6160 |
* @return <code>true</code> if the char is mirrored, <code>false</code> |
|
6161 |
* if the <code>char</code> is not mirrored or is not defined. |
|
6162 |
* @since 1.4 |
|
6163 |
*/ |
|
6164 |
public static boolean isMirrored(char ch) { |
|
6165 |
return isMirrored((int)ch); |
|
6166 |
} |
|
6167 |
||
6168 |
/** |
|
6169 |
* Determines whether the specified character (Unicode code point) |
|
6170 |
* is mirrored according to the Unicode specification. Mirrored |
|
6171 |
* characters should have their glyphs horizontally mirrored when |
|
6172 |
* displayed in text that is right-to-left. For example, |
|
6173 |
* <code>'\u0028'</code> LEFT PARENTHESIS is semantically |
|
6174 |
* defined to be an <i>opening parenthesis</i>. This will appear |
|
6175 |
* as a "(" in text that is left-to-right but as a ")" in text |
|
6176 |
* that is right-to-left. |
|
6177 |
* |
|
6178 |
* @param codePoint the character (Unicode code point) to be tested. |
|
6179 |
* @return <code>true</code> if the character is mirrored, <code>false</code> |
|
6180 |
* if the character is not mirrored or is not defined. |
|
6181 |
* @since 1.5 |
|
6182 |
*/ |
|
6183 |
public static boolean isMirrored(int codePoint) { |
|
6184 |
return CharacterData.of(codePoint).isMirrored(codePoint); |
|
6185 |
} |
|
6186 |
||
6187 |
/** |
|
6188 |
* Compares two <code>Character</code> objects numerically. |
|
6189 |
* |
|
6190 |
* @param anotherCharacter the <code>Character</code> to be compared. |
|
6191 |
||
6192 |
* @return the value <code>0</code> if the argument <code>Character</code> |
|
6193 |
* is equal to this <code>Character</code>; a value less than |
|
6194 |
* <code>0</code> if this <code>Character</code> is numerically less |
|
6195 |
* than the <code>Character</code> argument; and a value greater than |
|
6196 |
* <code>0</code> if this <code>Character</code> is numerically greater |
|
6197 |
* than the <code>Character</code> argument (unsigned comparison). |
|
6198 |
* Note that this is strictly a numerical comparison; it is not |
|
6199 |
* locale-dependent. |
|
6200 |
* @since 1.2 |
|
6201 |
*/ |
|
6202 |
public int compareTo(Character anotherCharacter) { |
|
3943
11abf5578222
6582946: Add suite of compare(T, T) methods for ints, longs etc
martin
parents:
3942
diff
changeset
|
6203 |
return compare(this.value, anotherCharacter.value); |
11abf5578222
6582946: Add suite of compare(T, T) methods for ints, longs etc
martin
parents:
3942
diff
changeset
|
6204 |
} |
11abf5578222
6582946: Add suite of compare(T, T) methods for ints, longs etc
martin
parents:
3942
diff
changeset
|
6205 |
|
11abf5578222
6582946: Add suite of compare(T, T) methods for ints, longs etc
martin
parents:
3942
diff
changeset
|
6206 |
/** |
11abf5578222
6582946: Add suite of compare(T, T) methods for ints, longs etc
martin
parents:
3942
diff
changeset
|
6207 |
* Compares two {@code char} values numerically. |
11abf5578222
6582946: Add suite of compare(T, T) methods for ints, longs etc
martin
parents:
3942
diff
changeset
|
6208 |
* The value returned is identical to what would be returned by: |
11abf5578222
6582946: Add suite of compare(T, T) methods for ints, longs etc
martin
parents:
3942
diff
changeset
|
6209 |
* <pre> |
11abf5578222
6582946: Add suite of compare(T, T) methods for ints, longs etc
martin
parents:
3942
diff
changeset
|
6210 |
* Character.valueOf(x).compareTo(Character.valueOf(y)) |
11abf5578222
6582946: Add suite of compare(T, T) methods for ints, longs etc
martin
parents:
3942
diff
changeset
|
6211 |
* </pre> |
11abf5578222
6582946: Add suite of compare(T, T) methods for ints, longs etc
martin
parents:
3942
diff
changeset
|
6212 |
* |
11abf5578222
6582946: Add suite of compare(T, T) methods for ints, longs etc
martin
parents:
3942
diff
changeset
|
6213 |
* @param x the first {@code char} to compare |
11abf5578222
6582946: Add suite of compare(T, T) methods for ints, longs etc
martin
parents:
3942
diff
changeset
|
6214 |
* @param y the second {@code char} to compare |
11abf5578222
6582946: Add suite of compare(T, T) methods for ints, longs etc
martin
parents:
3942
diff
changeset
|
6215 |
* @return the value {@code 0} if {@code x == y}; |
11abf5578222
6582946: Add suite of compare(T, T) methods for ints, longs etc
martin
parents:
3942
diff
changeset
|
6216 |
* a value less than {@code 0} if {@code x < y}; and |
11abf5578222
6582946: Add suite of compare(T, T) methods for ints, longs etc
martin
parents:
3942
diff
changeset
|
6217 |
* a value greater than {@code 0} if {@code x > y} |
11abf5578222
6582946: Add suite of compare(T, T) methods for ints, longs etc
martin
parents:
3942
diff
changeset
|
6218 |
* @since 1.7 |
11abf5578222
6582946: Add suite of compare(T, T) methods for ints, longs etc
martin
parents:
3942
diff
changeset
|
6219 |
*/ |
11abf5578222
6582946: Add suite of compare(T, T) methods for ints, longs etc
martin
parents:
3942
diff
changeset
|
6220 |
public static int compare(char x, char y) { |
11abf5578222
6582946: Add suite of compare(T, T) methods for ints, longs etc
martin
parents:
3942
diff
changeset
|
6221 |
return x - y; |
2 | 6222 |
} |
6223 |
||
6224 |
/** |
|
6225 |
* Converts the character (Unicode code point) argument to uppercase using |
|
6226 |
* information from the UnicodeData file. |
|
6227 |
* <p> |
|
6228 |
* |
|
6229 |
* @param codePoint the character (Unicode code point) to be converted. |
|
6230 |
* @return either the uppercase equivalent of the character, if |
|
6231 |
* any, or an error flag (<code>Character.ERROR</code>) |
|
6232 |
* that indicates that a 1:M <code>char</code> mapping exists. |
|
6233 |
* @see java.lang.Character#isLowerCase(char) |
|
6234 |
* @see java.lang.Character#isUpperCase(char) |
|
6235 |
* @see java.lang.Character#toLowerCase(char) |
|
6236 |
* @see java.lang.Character#toTitleCase(char) |
|
6237 |
* @since 1.4 |
|
6238 |
*/ |
|
6239 |
static int toUpperCaseEx(int codePoint) { |
|
6240 |
assert isValidCodePoint(codePoint); |
|
6241 |
return CharacterData.of(codePoint).toUpperCaseEx(codePoint); |
|
6242 |
} |
|
6243 |
||
6244 |
/** |
|
6245 |
* Converts the character (Unicode code point) argument to uppercase using case |
|
6246 |
* mapping information from the SpecialCasing file in the Unicode |
|
6247 |
* specification. If a character has no explicit uppercase |
|
6248 |
* mapping, then the <code>char</code> itself is returned in the |
|
6249 |
* <code>char[]</code>. |
|
6250 |
* |
|
6251 |
* @param codePoint the character (Unicode code point) to be converted. |
|
6252 |
* @return a <code>char[]</code> with the uppercased character. |
|
6253 |
* @since 1.4 |
|
6254 |
*/ |
|
6255 |
static char[] toUpperCaseCharArray(int codePoint) { |
|
6256 |
// As of Unicode 4.0, 1:M uppercasings only happen in the BMP. |
|
6257 |
assert isValidCodePoint(codePoint) && |
|
6258 |
!isSupplementaryCodePoint(codePoint); |
|
6259 |
return CharacterData.of(codePoint).toUpperCaseCharArray(codePoint); |
|
6260 |
} |
|
6261 |
||
6262 |
/** |
|
6263 |
* The number of bits used to represent a <tt>char</tt> value in unsigned |
|
3714 | 6264 |
* binary form, constant {@code 16}. |
2 | 6265 |
* |
6266 |
* @since 1.5 |
|
6267 |
*/ |
|
6268 |
public static final int SIZE = 16; |
|
6269 |
||
6270 |
/** |
|
6271 |
* Returns the value obtained by reversing the order of the bytes in the |
|
6272 |
* specified <tt>char</tt> value. |
|
6273 |
* |
|
6274 |
* @return the value obtained by reversing (or, equivalently, swapping) |
|
6275 |
* the bytes in the specified <tt>char</tt> value. |
|
6276 |
* @since 1.5 |
|
6277 |
*/ |
|
6278 |
public static char reverseBytes(char ch) { |
|
6279 |
return (char) (((ch & 0xFF00) >> 8) | (ch << 8)); |
|
6280 |
} |
|
5610
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
6281 |
|
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
6282 |
/** |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
6283 |
* Returns the Unicode name of the specified character |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
6284 |
* <code>codePoint</code>, or null if the code point is |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
6285 |
* {@link #UNASSIGNED unassigned}. |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
6286 |
* <p> |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
6287 |
* Note: if the specified character is not assigned a name by |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
6288 |
* the <i>UnicodeData</i> file (part of the Unicode Character |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
6289 |
* Database maintained by the Unicode Consortium), the returned |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
6290 |
* name is the same as the result of expression |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
6291 |
* |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
6292 |
* <blockquote><code> |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
6293 |
* Character.UnicodeBlock.of(codePoint) |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
6294 |
* .toString() |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
6295 |
* .replace('_', ' ') |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
6296 |
* + " " |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
6297 |
* + Integer.toHexString(codePoint).toUpperCase(Locale.ENGLISH); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
6298 |
* |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
6299 |
* </code></blockquote> |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
6300 |
* |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
6301 |
* @param codePoint the character (Unicode code point) |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
6302 |
* |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
6303 |
* @return the Unicode name of the specified character, or null if |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
6304 |
* the code point is unassigned. |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
6305 |
* |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
6306 |
* @exception IllegalArgumentException if the specified |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
6307 |
* <code>codePoint</code> is not a valid Unicode |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
6308 |
* code point. |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
6309 |
* |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
6310 |
* @since 1.7 |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
6311 |
*/ |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
6312 |
public static String getName(int codePoint) { |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
6313 |
if (!isValidCodePoint(codePoint)) { |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
6314 |
throw new IllegalArgumentException(); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
6315 |
} |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
6316 |
String name = CharacterName.get(codePoint); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
6317 |
if (name != null) |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
6318 |
return name; |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
6319 |
if (getType(codePoint) == UNASSIGNED) |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
6320 |
return null; |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
6321 |
UnicodeBlock block = UnicodeBlock.of(codePoint); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
6322 |
if (block != null) |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
6323 |
return block.toString().replace('_', ' ') + " " |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
6324 |
+ Integer.toHexString(codePoint).toUpperCase(Locale.ENGLISH); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
6325 |
// should never come here |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
6326 |
return Integer.toHexString(codePoint).toUpperCase(Locale.ENGLISH); |
fd2427610c7f
6945564: Unicode script support in Character class
sherman
parents:
3943
diff
changeset
|
6327 |
} |
2 | 6328 |
} |