JAL-1807 still testing
[jalviewjs.git] / unused / com / stevesoft / pat / Prop.java
1 //\r
2 // This software is now distributed according to\r
3 // the Lesser Gnu Public License.  Please see\r
4 // http://www.gnu.org/copyleft/lesser.txt for\r
5 // the details.\r
6 //    -- Happy Computing!\r
7 //\r
8 package com.stevesoft.pat;\r
9 \r
10 /**\r
11  * Get Unicode properties for a character. See <a\r
12  * href="http://unicode.org">http://unicode.org</a>.\r
13  */\r
14 public class Prop\r
15 {\r
16   /** Is this a "Decimal Digit" according to Unicode? */\r
17   public final static boolean isDecimalDigit(char c)\r
18   {\r
19     if (Bits.decimal_digit == null)\r
20     {\r
21       Bits.decimal_digit_f();\r
22     }\r
23     return Bits.decimal_digit.get(c);\r
24   }\r
25 \r
26   /** Is this a "Alphabetic" according to Unicode? */\r
27   public final static boolean isAlphabetic(char c)\r
28   {\r
29     if (Bits.letter == null)\r
30     {\r
31       Bits.letter_f();\r
32     }\r
33     return Bits.letter.get(c);\r
34   }\r
35 \r
36   /** Is this a "Math" according to Unicode? */\r
37   public final static boolean isMath(char c)\r
38   {\r
39     if (Bits.math == null)\r
40     {\r
41       Bits.math_f();\r
42     }\r
43     return Bits.math.get(c);\r
44   }\r
45 \r
46   /** Is this a "Currency" according to Unicode? */\r
47   public final static boolean isCurrency(char c)\r
48   {\r
49     if (Bits.currency == null)\r
50     {\r
51       Bits.currency_f();\r
52     }\r
53     return Bits.currency.get(c);\r
54   }\r
55 \r
56   /** Is c a white space character according to Unicode? */\r
57   public final static boolean isWhite(char c)\r
58   {\r
59     if (Bits.white == null)\r
60     {\r
61       Bits.white_f();\r
62     }\r
63     return Bits.white.get(c);\r
64   }\r
65 \r
66   /** Is c a punctuation character according to Unicode? */\r
67   public final static boolean isPunct(char c)\r
68   {\r
69     if (Bits.punct == null)\r
70     {\r
71       Bits.punct_f();\r
72     }\r
73     return Bits.punct.get(c);\r
74   }\r
75 }\r