Source Code Cross Referenced for XMLChar.java in  » XML » xerces-2_9_1 » org » apache » xerces » util » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » XML » xerces 2_9_1 » org.apache.xerces.util 
Source Cross Referenced  Class Diagram Java Document (Java Doc) 


0001:        /*
0002:         * Licensed to the Apache Software Foundation (ASF) under one or more
0003:         * contributor license agreements.  See the NOTICE file distributed with
0004:         * this work for additional information regarding copyright ownership.
0005:         * The ASF licenses this file to You under the Apache License, Version 2.0
0006:         * (the "License"); you may not use this file except in compliance with
0007:         * the License.  You may obtain a copy of the License at
0008:         * 
0009:         *      http://www.apache.org/licenses/LICENSE-2.0
0010:         * 
0011:         * Unless required by applicable law or agreed to in writing, software
0012:         * distributed under the License is distributed on an "AS IS" BASIS,
0013:         * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
0014:         * See the License for the specific language governing permissions and
0015:         * limitations under the License.
0016:         */
0017:
0018:        package org.apache.xerces.util;
0019:
0020:        import java.util.Arrays;
0021:
0022:        /**
0023:         * This class defines the basic XML character properties. The data
0024:         * in this class can be used to verify that a character is a valid
0025:         * XML character or if the character is a space, name start, or name
0026:         * character.
0027:         * <p>
0028:         * A series of convenience methods are supplied to ease the burden
0029:         * of the developer. Because inlining the checks can improve per
0030:         * character performance, the tables of character properties are
0031:         * public. Using the character as an index into the <code>CHARS</code>
0032:         * array and applying the appropriate mask flag (e.g.
0033:         * <code>MASK_VALID</code>), yields the same results as calling the
0034:         * convenience methods. There is one exception: check the comments
0035:         * for the <code>isValid</code> method for details.
0036:         *
0037:         * @author Glenn Marcy, IBM
0038:         * @author Andy Clark, IBM
0039:         * @author Eric Ye, IBM
0040:         * @author Arnaud  Le Hors, IBM
0041:         * @author Michael Glavassevich, IBM
0042:         * @author Rahul Srivastava, Sun Microsystems Inc.
0043:         *
0044:         * @version $Id: XMLChar.java 469584 2006-10-31 17:57:34Z mrglavas $
0045:         */
0046:        public class XMLChar {
0047:
0048:            //
0049:            // Constants
0050:            //
0051:
0052:            /** Character flags. */
0053:            private static final byte[] CHARS = new byte[1 << 16];
0054:
0055:            /** Valid character mask. */
0056:            public static final int MASK_VALID = 0x01;
0057:
0058:            /** Space character mask. */
0059:            public static final int MASK_SPACE = 0x02;
0060:
0061:            /** Name start character mask. */
0062:            public static final int MASK_NAME_START = 0x04;
0063:
0064:            /** Name character mask. */
0065:            public static final int MASK_NAME = 0x08;
0066:
0067:            /** Pubid character mask. */
0068:            public static final int MASK_PUBID = 0x10;
0069:
0070:            /** 
0071:             * Content character mask. Special characters are those that can
0072:             * be considered the start of markup, such as '&lt;' and '&amp;'. 
0073:             * The various newline characters are considered special as well.
0074:             * All other valid XML characters can be considered content.
0075:             * <p>
0076:             * This is an optimization for the inner loop of character scanning.
0077:             */
0078:            public static final int MASK_CONTENT = 0x20;
0079:
0080:            /** NCName start character mask. */
0081:            public static final int MASK_NCNAME_START = 0x40;
0082:
0083:            /** NCName character mask. */
0084:            public static final int MASK_NCNAME = 0x80;
0085:
0086:            //
0087:            // Static initialization
0088:            //
0089:
0090:            static {
0091:
0092:                // Initializing the Character Flag Array
0093:                // Code generated by: XMLCharGenerator.
0094:
0095:                CHARS[9] = 35;
0096:                CHARS[10] = 19;
0097:                CHARS[13] = 19;
0098:                CHARS[32] = 51;
0099:                CHARS[33] = 49;
0100:                CHARS[34] = 33;
0101:                Arrays.fill(CHARS, 35, 38, (byte) 49); // Fill 3 of value (byte) 49
0102:                CHARS[38] = 1;
0103:                Arrays.fill(CHARS, 39, 45, (byte) 49); // Fill 6 of value (byte) 49
0104:                Arrays.fill(CHARS, 45, 47, (byte) -71); // Fill 2 of value (byte) -71
0105:                CHARS[47] = 49;
0106:                Arrays.fill(CHARS, 48, 58, (byte) -71); // Fill 10 of value (byte) -71
0107:                CHARS[58] = 61;
0108:                CHARS[59] = 49;
0109:                CHARS[60] = 1;
0110:                CHARS[61] = 49;
0111:                CHARS[62] = 33;
0112:                Arrays.fill(CHARS, 63, 65, (byte) 49); // Fill 2 of value (byte) 49
0113:                Arrays.fill(CHARS, 65, 91, (byte) -3); // Fill 26 of value (byte) -3
0114:                Arrays.fill(CHARS, 91, 93, (byte) 33); // Fill 2 of value (byte) 33
0115:                CHARS[93] = 1;
0116:                CHARS[94] = 33;
0117:                CHARS[95] = -3;
0118:                CHARS[96] = 33;
0119:                Arrays.fill(CHARS, 97, 123, (byte) -3); // Fill 26 of value (byte) -3
0120:                Arrays.fill(CHARS, 123, 183, (byte) 33); // Fill 60 of value (byte) 33
0121:                CHARS[183] = -87;
0122:                Arrays.fill(CHARS, 184, 192, (byte) 33); // Fill 8 of value (byte) 33
0123:                Arrays.fill(CHARS, 192, 215, (byte) -19); // Fill 23 of value (byte) -19
0124:                CHARS[215] = 33;
0125:                Arrays.fill(CHARS, 216, 247, (byte) -19); // Fill 31 of value (byte) -19
0126:                CHARS[247] = 33;
0127:                Arrays.fill(CHARS, 248, 306, (byte) -19); // Fill 58 of value (byte) -19
0128:                Arrays.fill(CHARS, 306, 308, (byte) 33); // Fill 2 of value (byte) 33
0129:                Arrays.fill(CHARS, 308, 319, (byte) -19); // Fill 11 of value (byte) -19
0130:                Arrays.fill(CHARS, 319, 321, (byte) 33); // Fill 2 of value (byte) 33
0131:                Arrays.fill(CHARS, 321, 329, (byte) -19); // Fill 8 of value (byte) -19
0132:                CHARS[329] = 33;
0133:                Arrays.fill(CHARS, 330, 383, (byte) -19); // Fill 53 of value (byte) -19
0134:                CHARS[383] = 33;
0135:                Arrays.fill(CHARS, 384, 452, (byte) -19); // Fill 68 of value (byte) -19
0136:                Arrays.fill(CHARS, 452, 461, (byte) 33); // Fill 9 of value (byte) 33
0137:                Arrays.fill(CHARS, 461, 497, (byte) -19); // Fill 36 of value (byte) -19
0138:                Arrays.fill(CHARS, 497, 500, (byte) 33); // Fill 3 of value (byte) 33
0139:                Arrays.fill(CHARS, 500, 502, (byte) -19); // Fill 2 of value (byte) -19
0140:                Arrays.fill(CHARS, 502, 506, (byte) 33); // Fill 4 of value (byte) 33
0141:                Arrays.fill(CHARS, 506, 536, (byte) -19); // Fill 30 of value (byte) -19
0142:                Arrays.fill(CHARS, 536, 592, (byte) 33); // Fill 56 of value (byte) 33
0143:                Arrays.fill(CHARS, 592, 681, (byte) -19); // Fill 89 of value (byte) -19
0144:                Arrays.fill(CHARS, 681, 699, (byte) 33); // Fill 18 of value (byte) 33
0145:                Arrays.fill(CHARS, 699, 706, (byte) -19); // Fill 7 of value (byte) -19
0146:                Arrays.fill(CHARS, 706, 720, (byte) 33); // Fill 14 of value (byte) 33
0147:                Arrays.fill(CHARS, 720, 722, (byte) -87); // Fill 2 of value (byte) -87
0148:                Arrays.fill(CHARS, 722, 768, (byte) 33); // Fill 46 of value (byte) 33
0149:                Arrays.fill(CHARS, 768, 838, (byte) -87); // Fill 70 of value (byte) -87
0150:                Arrays.fill(CHARS, 838, 864, (byte) 33); // Fill 26 of value (byte) 33
0151:                Arrays.fill(CHARS, 864, 866, (byte) -87); // Fill 2 of value (byte) -87
0152:                Arrays.fill(CHARS, 866, 902, (byte) 33); // Fill 36 of value (byte) 33
0153:                CHARS[902] = -19;
0154:                CHARS[903] = -87;
0155:                Arrays.fill(CHARS, 904, 907, (byte) -19); // Fill 3 of value (byte) -19
0156:                CHARS[907] = 33;
0157:                CHARS[908] = -19;
0158:                CHARS[909] = 33;
0159:                Arrays.fill(CHARS, 910, 930, (byte) -19); // Fill 20 of value (byte) -19
0160:                CHARS[930] = 33;
0161:                Arrays.fill(CHARS, 931, 975, (byte) -19); // Fill 44 of value (byte) -19
0162:                CHARS[975] = 33;
0163:                Arrays.fill(CHARS, 976, 983, (byte) -19); // Fill 7 of value (byte) -19
0164:                Arrays.fill(CHARS, 983, 986, (byte) 33); // Fill 3 of value (byte) 33
0165:                CHARS[986] = -19;
0166:                CHARS[987] = 33;
0167:                CHARS[988] = -19;
0168:                CHARS[989] = 33;
0169:                CHARS[990] = -19;
0170:                CHARS[991] = 33;
0171:                CHARS[992] = -19;
0172:                CHARS[993] = 33;
0173:                Arrays.fill(CHARS, 994, 1012, (byte) -19); // Fill 18 of value (byte) -19
0174:                Arrays.fill(CHARS, 1012, 1025, (byte) 33); // Fill 13 of value (byte) 33
0175:                Arrays.fill(CHARS, 1025, 1037, (byte) -19); // Fill 12 of value (byte) -19
0176:                CHARS[1037] = 33;
0177:                Arrays.fill(CHARS, 1038, 1104, (byte) -19); // Fill 66 of value (byte) -19
0178:                CHARS[1104] = 33;
0179:                Arrays.fill(CHARS, 1105, 1117, (byte) -19); // Fill 12 of value (byte) -19
0180:                CHARS[1117] = 33;
0181:                Arrays.fill(CHARS, 1118, 1154, (byte) -19); // Fill 36 of value (byte) -19
0182:                CHARS[1154] = 33;
0183:                Arrays.fill(CHARS, 1155, 1159, (byte) -87); // Fill 4 of value (byte) -87
0184:                Arrays.fill(CHARS, 1159, 1168, (byte) 33); // Fill 9 of value (byte) 33
0185:                Arrays.fill(CHARS, 1168, 1221, (byte) -19); // Fill 53 of value (byte) -19
0186:                Arrays.fill(CHARS, 1221, 1223, (byte) 33); // Fill 2 of value (byte) 33
0187:                Arrays.fill(CHARS, 1223, 1225, (byte) -19); // Fill 2 of value (byte) -19
0188:                Arrays.fill(CHARS, 1225, 1227, (byte) 33); // Fill 2 of value (byte) 33
0189:                Arrays.fill(CHARS, 1227, 1229, (byte) -19); // Fill 2 of value (byte) -19
0190:                Arrays.fill(CHARS, 1229, 1232, (byte) 33); // Fill 3 of value (byte) 33
0191:                Arrays.fill(CHARS, 1232, 1260, (byte) -19); // Fill 28 of value (byte) -19
0192:                Arrays.fill(CHARS, 1260, 1262, (byte) 33); // Fill 2 of value (byte) 33
0193:                Arrays.fill(CHARS, 1262, 1270, (byte) -19); // Fill 8 of value (byte) -19
0194:                Arrays.fill(CHARS, 1270, 1272, (byte) 33); // Fill 2 of value (byte) 33
0195:                Arrays.fill(CHARS, 1272, 1274, (byte) -19); // Fill 2 of value (byte) -19
0196:                Arrays.fill(CHARS, 1274, 1329, (byte) 33); // Fill 55 of value (byte) 33
0197:                Arrays.fill(CHARS, 1329, 1367, (byte) -19); // Fill 38 of value (byte) -19
0198:                Arrays.fill(CHARS, 1367, 1369, (byte) 33); // Fill 2 of value (byte) 33
0199:                CHARS[1369] = -19;
0200:                Arrays.fill(CHARS, 1370, 1377, (byte) 33); // Fill 7 of value (byte) 33
0201:                Arrays.fill(CHARS, 1377, 1415, (byte) -19); // Fill 38 of value (byte) -19
0202:                Arrays.fill(CHARS, 1415, 1425, (byte) 33); // Fill 10 of value (byte) 33
0203:                Arrays.fill(CHARS, 1425, 1442, (byte) -87); // Fill 17 of value (byte) -87
0204:                CHARS[1442] = 33;
0205:                Arrays.fill(CHARS, 1443, 1466, (byte) -87); // Fill 23 of value (byte) -87
0206:                CHARS[1466] = 33;
0207:                Arrays.fill(CHARS, 1467, 1470, (byte) -87); // Fill 3 of value (byte) -87
0208:                CHARS[1470] = 33;
0209:                CHARS[1471] = -87;
0210:                CHARS[1472] = 33;
0211:                Arrays.fill(CHARS, 1473, 1475, (byte) -87); // Fill 2 of value (byte) -87
0212:                CHARS[1475] = 33;
0213:                CHARS[1476] = -87;
0214:                Arrays.fill(CHARS, 1477, 1488, (byte) 33); // Fill 11 of value (byte) 33
0215:                Arrays.fill(CHARS, 1488, 1515, (byte) -19); // Fill 27 of value (byte) -19
0216:                Arrays.fill(CHARS, 1515, 1520, (byte) 33); // Fill 5 of value (byte) 33
0217:                Arrays.fill(CHARS, 1520, 1523, (byte) -19); // Fill 3 of value (byte) -19
0218:                Arrays.fill(CHARS, 1523, 1569, (byte) 33); // Fill 46 of value (byte) 33
0219:                Arrays.fill(CHARS, 1569, 1595, (byte) -19); // Fill 26 of value (byte) -19
0220:                Arrays.fill(CHARS, 1595, 1600, (byte) 33); // Fill 5 of value (byte) 33
0221:                CHARS[1600] = -87;
0222:                Arrays.fill(CHARS, 1601, 1611, (byte) -19); // Fill 10 of value (byte) -19
0223:                Arrays.fill(CHARS, 1611, 1619, (byte) -87); // Fill 8 of value (byte) -87
0224:                Arrays.fill(CHARS, 1619, 1632, (byte) 33); // Fill 13 of value (byte) 33
0225:                Arrays.fill(CHARS, 1632, 1642, (byte) -87); // Fill 10 of value (byte) -87
0226:                Arrays.fill(CHARS, 1642, 1648, (byte) 33); // Fill 6 of value (byte) 33
0227:                CHARS[1648] = -87;
0228:                Arrays.fill(CHARS, 1649, 1720, (byte) -19); // Fill 71 of value (byte) -19
0229:                Arrays.fill(CHARS, 1720, 1722, (byte) 33); // Fill 2 of value (byte) 33
0230:                Arrays.fill(CHARS, 1722, 1727, (byte) -19); // Fill 5 of value (byte) -19
0231:                CHARS[1727] = 33;
0232:                Arrays.fill(CHARS, 1728, 1743, (byte) -19); // Fill 15 of value (byte) -19
0233:                CHARS[1743] = 33;
0234:                Arrays.fill(CHARS, 1744, 1748, (byte) -19); // Fill 4 of value (byte) -19
0235:                CHARS[1748] = 33;
0236:                CHARS[1749] = -19;
0237:                Arrays.fill(CHARS, 1750, 1765, (byte) -87); // Fill 15 of value (byte) -87
0238:                Arrays.fill(CHARS, 1765, 1767, (byte) -19); // Fill 2 of value (byte) -19
0239:                Arrays.fill(CHARS, 1767, 1769, (byte) -87); // Fill 2 of value (byte) -87
0240:                CHARS[1769] = 33;
0241:                Arrays.fill(CHARS, 1770, 1774, (byte) -87); // Fill 4 of value (byte) -87
0242:                Arrays.fill(CHARS, 1774, 1776, (byte) 33); // Fill 2 of value (byte) 33
0243:                Arrays.fill(CHARS, 1776, 1786, (byte) -87); // Fill 10 of value (byte) -87
0244:                Arrays.fill(CHARS, 1786, 2305, (byte) 33); // Fill 519 of value (byte) 33
0245:                Arrays.fill(CHARS, 2305, 2308, (byte) -87); // Fill 3 of value (byte) -87
0246:                CHARS[2308] = 33;
0247:                Arrays.fill(CHARS, 2309, 2362, (byte) -19); // Fill 53 of value (byte) -19
0248:                Arrays.fill(CHARS, 2362, 2364, (byte) 33); // Fill 2 of value (byte) 33
0249:                CHARS[2364] = -87;
0250:                CHARS[2365] = -19;
0251:                Arrays.fill(CHARS, 2366, 2382, (byte) -87); // Fill 16 of value (byte) -87
0252:                Arrays.fill(CHARS, 2382, 2385, (byte) 33); // Fill 3 of value (byte) 33
0253:                Arrays.fill(CHARS, 2385, 2389, (byte) -87); // Fill 4 of value (byte) -87
0254:                Arrays.fill(CHARS, 2389, 2392, (byte) 33); // Fill 3 of value (byte) 33
0255:                Arrays.fill(CHARS, 2392, 2402, (byte) -19); // Fill 10 of value (byte) -19
0256:                Arrays.fill(CHARS, 2402, 2404, (byte) -87); // Fill 2 of value (byte) -87
0257:                Arrays.fill(CHARS, 2404, 2406, (byte) 33); // Fill 2 of value (byte) 33
0258:                Arrays.fill(CHARS, 2406, 2416, (byte) -87); // Fill 10 of value (byte) -87
0259:                Arrays.fill(CHARS, 2416, 2433, (byte) 33); // Fill 17 of value (byte) 33
0260:                Arrays.fill(CHARS, 2433, 2436, (byte) -87); // Fill 3 of value (byte) -87
0261:                CHARS[2436] = 33;
0262:                Arrays.fill(CHARS, 2437, 2445, (byte) -19); // Fill 8 of value (byte) -19
0263:                Arrays.fill(CHARS, 2445, 2447, (byte) 33); // Fill 2 of value (byte) 33
0264:                Arrays.fill(CHARS, 2447, 2449, (byte) -19); // Fill 2 of value (byte) -19
0265:                Arrays.fill(CHARS, 2449, 2451, (byte) 33); // Fill 2 of value (byte) 33
0266:                Arrays.fill(CHARS, 2451, 2473, (byte) -19); // Fill 22 of value (byte) -19
0267:                CHARS[2473] = 33;
0268:                Arrays.fill(CHARS, 2474, 2481, (byte) -19); // Fill 7 of value (byte) -19
0269:                CHARS[2481] = 33;
0270:                CHARS[2482] = -19;
0271:                Arrays.fill(CHARS, 2483, 2486, (byte) 33); // Fill 3 of value (byte) 33
0272:                Arrays.fill(CHARS, 2486, 2490, (byte) -19); // Fill 4 of value (byte) -19
0273:                Arrays.fill(CHARS, 2490, 2492, (byte) 33); // Fill 2 of value (byte) 33
0274:                CHARS[2492] = -87;
0275:                CHARS[2493] = 33;
0276:                Arrays.fill(CHARS, 2494, 2501, (byte) -87); // Fill 7 of value (byte) -87
0277:                Arrays.fill(CHARS, 2501, 2503, (byte) 33); // Fill 2 of value (byte) 33
0278:                Arrays.fill(CHARS, 2503, 2505, (byte) -87); // Fill 2 of value (byte) -87
0279:                Arrays.fill(CHARS, 2505, 2507, (byte) 33); // Fill 2 of value (byte) 33
0280:                Arrays.fill(CHARS, 2507, 2510, (byte) -87); // Fill 3 of value (byte) -87
0281:                Arrays.fill(CHARS, 2510, 2519, (byte) 33); // Fill 9 of value (byte) 33
0282:                CHARS[2519] = -87;
0283:                Arrays.fill(CHARS, 2520, 2524, (byte) 33); // Fill 4 of value (byte) 33
0284:                Arrays.fill(CHARS, 2524, 2526, (byte) -19); // Fill 2 of value (byte) -19
0285:                CHARS[2526] = 33;
0286:                Arrays.fill(CHARS, 2527, 2530, (byte) -19); // Fill 3 of value (byte) -19
0287:                Arrays.fill(CHARS, 2530, 2532, (byte) -87); // Fill 2 of value (byte) -87
0288:                Arrays.fill(CHARS, 2532, 2534, (byte) 33); // Fill 2 of value (byte) 33
0289:                Arrays.fill(CHARS, 2534, 2544, (byte) -87); // Fill 10 of value (byte) -87
0290:                Arrays.fill(CHARS, 2544, 2546, (byte) -19); // Fill 2 of value (byte) -19
0291:                Arrays.fill(CHARS, 2546, 2562, (byte) 33); // Fill 16 of value (byte) 33
0292:                CHARS[2562] = -87;
0293:                Arrays.fill(CHARS, 2563, 2565, (byte) 33); // Fill 2 of value (byte) 33
0294:                Arrays.fill(CHARS, 2565, 2571, (byte) -19); // Fill 6 of value (byte) -19
0295:                Arrays.fill(CHARS, 2571, 2575, (byte) 33); // Fill 4 of value (byte) 33
0296:                Arrays.fill(CHARS, 2575, 2577, (byte) -19); // Fill 2 of value (byte) -19
0297:                Arrays.fill(CHARS, 2577, 2579, (byte) 33); // Fill 2 of value (byte) 33
0298:                Arrays.fill(CHARS, 2579, 2601, (byte) -19); // Fill 22 of value (byte) -19
0299:                CHARS[2601] = 33;
0300:                Arrays.fill(CHARS, 2602, 2609, (byte) -19); // Fill 7 of value (byte) -19
0301:                CHARS[2609] = 33;
0302:                Arrays.fill(CHARS, 2610, 2612, (byte) -19); // Fill 2 of value (byte) -19
0303:                CHARS[2612] = 33;
0304:                Arrays.fill(CHARS, 2613, 2615, (byte) -19); // Fill 2 of value (byte) -19
0305:                CHARS[2615] = 33;
0306:                Arrays.fill(CHARS, 2616, 2618, (byte) -19); // Fill 2 of value (byte) -19
0307:                Arrays.fill(CHARS, 2618, 2620, (byte) 33); // Fill 2 of value (byte) 33
0308:                CHARS[2620] = -87;
0309:                CHARS[2621] = 33;
0310:                Arrays.fill(CHARS, 2622, 2627, (byte) -87); // Fill 5 of value (byte) -87
0311:                Arrays.fill(CHARS, 2627, 2631, (byte) 33); // Fill 4 of value (byte) 33
0312:                Arrays.fill(CHARS, 2631, 2633, (byte) -87); // Fill 2 of value (byte) -87
0313:                Arrays.fill(CHARS, 2633, 2635, (byte) 33); // Fill 2 of value (byte) 33
0314:                Arrays.fill(CHARS, 2635, 2638, (byte) -87); // Fill 3 of value (byte) -87
0315:                Arrays.fill(CHARS, 2638, 2649, (byte) 33); // Fill 11 of value (byte) 33
0316:                Arrays.fill(CHARS, 2649, 2653, (byte) -19); // Fill 4 of value (byte) -19
0317:                CHARS[2653] = 33;
0318:                CHARS[2654] = -19;
0319:                Arrays.fill(CHARS, 2655, 2662, (byte) 33); // Fill 7 of value (byte) 33
0320:                Arrays.fill(CHARS, 2662, 2674, (byte) -87); // Fill 12 of value (byte) -87
0321:                Arrays.fill(CHARS, 2674, 2677, (byte) -19); // Fill 3 of value (byte) -19
0322:                Arrays.fill(CHARS, 2677, 2689, (byte) 33); // Fill 12 of value (byte) 33
0323:                Arrays.fill(CHARS, 2689, 2692, (byte) -87); // Fill 3 of value (byte) -87
0324:                CHARS[2692] = 33;
0325:                Arrays.fill(CHARS, 2693, 2700, (byte) -19); // Fill 7 of value (byte) -19
0326:                CHARS[2700] = 33;
0327:                CHARS[2701] = -19;
0328:                CHARS[2702] = 33;
0329:                Arrays.fill(CHARS, 2703, 2706, (byte) -19); // Fill 3 of value (byte) -19
0330:                CHARS[2706] = 33;
0331:                Arrays.fill(CHARS, 2707, 2729, (byte) -19); // Fill 22 of value (byte) -19
0332:                CHARS[2729] = 33;
0333:                Arrays.fill(CHARS, 2730, 2737, (byte) -19); // Fill 7 of value (byte) -19
0334:                CHARS[2737] = 33;
0335:                Arrays.fill(CHARS, 2738, 2740, (byte) -19); // Fill 2 of value (byte) -19
0336:                CHARS[2740] = 33;
0337:                Arrays.fill(CHARS, 2741, 2746, (byte) -19); // Fill 5 of value (byte) -19
0338:                Arrays.fill(CHARS, 2746, 2748, (byte) 33); // Fill 2 of value (byte) 33
0339:                CHARS[2748] = -87;
0340:                CHARS[2749] = -19;
0341:                Arrays.fill(CHARS, 2750, 2758, (byte) -87); // Fill 8 of value (byte) -87
0342:                CHARS[2758] = 33;
0343:                Arrays.fill(CHARS, 2759, 2762, (byte) -87); // Fill 3 of value (byte) -87
0344:                CHARS[2762] = 33;
0345:                Arrays.fill(CHARS, 2763, 2766, (byte) -87); // Fill 3 of value (byte) -87
0346:                Arrays.fill(CHARS, 2766, 2784, (byte) 33); // Fill 18 of value (byte) 33
0347:                CHARS[2784] = -19;
0348:                Arrays.fill(CHARS, 2785, 2790, (byte) 33); // Fill 5 of value (byte) 33
0349:                Arrays.fill(CHARS, 2790, 2800, (byte) -87); // Fill 10 of value (byte) -87
0350:                Arrays.fill(CHARS, 2800, 2817, (byte) 33); // Fill 17 of value (byte) 33
0351:                Arrays.fill(CHARS, 2817, 2820, (byte) -87); // Fill 3 of value (byte) -87
0352:                CHARS[2820] = 33;
0353:                Arrays.fill(CHARS, 2821, 2829, (byte) -19); // Fill 8 of value (byte) -19
0354:                Arrays.fill(CHARS, 2829, 2831, (byte) 33); // Fill 2 of value (byte) 33
0355:                Arrays.fill(CHARS, 2831, 2833, (byte) -19); // Fill 2 of value (byte) -19
0356:                Arrays.fill(CHARS, 2833, 2835, (byte) 33); // Fill 2 of value (byte) 33
0357:                Arrays.fill(CHARS, 2835, 2857, (byte) -19); // Fill 22 of value (byte) -19
0358:                CHARS[2857] = 33;
0359:                Arrays.fill(CHARS, 2858, 2865, (byte) -19); // Fill 7 of value (byte) -19
0360:                CHARS[2865] = 33;
0361:                Arrays.fill(CHARS, 2866, 2868, (byte) -19); // Fill 2 of value (byte) -19
0362:                Arrays.fill(CHARS, 2868, 2870, (byte) 33); // Fill 2 of value (byte) 33
0363:                Arrays.fill(CHARS, 2870, 2874, (byte) -19); // Fill 4 of value (byte) -19
0364:                Arrays.fill(CHARS, 2874, 2876, (byte) 33); // Fill 2 of value (byte) 33
0365:                CHARS[2876] = -87;
0366:                CHARS[2877] = -19;
0367:                Arrays.fill(CHARS, 2878, 2884, (byte) -87); // Fill 6 of value (byte) -87
0368:                Arrays.fill(CHARS, 2884, 2887, (byte) 33); // Fill 3 of value (byte) 33
0369:                Arrays.fill(CHARS, 2887, 2889, (byte) -87); // Fill 2 of value (byte) -87
0370:                Arrays.fill(CHARS, 2889, 2891, (byte) 33); // Fill 2 of value (byte) 33
0371:                Arrays.fill(CHARS, 2891, 2894, (byte) -87); // Fill 3 of value (byte) -87
0372:                Arrays.fill(CHARS, 2894, 2902, (byte) 33); // Fill 8 of value (byte) 33
0373:                Arrays.fill(CHARS, 2902, 2904, (byte) -87); // Fill 2 of value (byte) -87
0374:                Arrays.fill(CHARS, 2904, 2908, (byte) 33); // Fill 4 of value (byte) 33
0375:                Arrays.fill(CHARS, 2908, 2910, (byte) -19); // Fill 2 of value (byte) -19
0376:                CHARS[2910] = 33;
0377:                Arrays.fill(CHARS, 2911, 2914, (byte) -19); // Fill 3 of value (byte) -19
0378:                Arrays.fill(CHARS, 2914, 2918, (byte) 33); // Fill 4 of value (byte) 33
0379:                Arrays.fill(CHARS, 2918, 2928, (byte) -87); // Fill 10 of value (byte) -87
0380:                Arrays.fill(CHARS, 2928, 2946, (byte) 33); // Fill 18 of value (byte) 33
0381:                Arrays.fill(CHARS, 2946, 2948, (byte) -87); // Fill 2 of value (byte) -87
0382:                CHARS[2948] = 33;
0383:                Arrays.fill(CHARS, 2949, 2955, (byte) -19); // Fill 6 of value (byte) -19
0384:                Arrays.fill(CHARS, 2955, 2958, (byte) 33); // Fill 3 of value (byte) 33
0385:                Arrays.fill(CHARS, 2958, 2961, (byte) -19); // Fill 3 of value (byte) -19
0386:                CHARS[2961] = 33;
0387:                Arrays.fill(CHARS, 2962, 2966, (byte) -19); // Fill 4 of value (byte) -19
0388:                Arrays.fill(CHARS, 2966, 2969, (byte) 33); // Fill 3 of value (byte) 33
0389:                Arrays.fill(CHARS, 2969, 2971, (byte) -19); // Fill 2 of value (byte) -19
0390:                CHARS[2971] = 33;
0391:                CHARS[2972] = -19;
0392:                CHARS[2973] = 33;
0393:                Arrays.fill(CHARS, 2974, 2976, (byte) -19); // Fill 2 of value (byte) -19
0394:                Arrays.fill(CHARS, 2976, 2979, (byte) 33); // Fill 3 of value (byte) 33
0395:                Arrays.fill(CHARS, 2979, 2981, (byte) -19); // Fill 2 of value (byte) -19
0396:                Arrays.fill(CHARS, 2981, 2984, (byte) 33); // Fill 3 of value (byte) 33
0397:                Arrays.fill(CHARS, 2984, 2987, (byte) -19); // Fill 3 of value (byte) -19
0398:                Arrays.fill(CHARS, 2987, 2990, (byte) 33); // Fill 3 of value (byte) 33
0399:                Arrays.fill(CHARS, 2990, 2998, (byte) -19); // Fill 8 of value (byte) -19
0400:                CHARS[2998] = 33;
0401:                Arrays.fill(CHARS, 2999, 3002, (byte) -19); // Fill 3 of value (byte) -19
0402:                Arrays.fill(CHARS, 3002, 3006, (byte) 33); // Fill 4 of value (byte) 33
0403:                Arrays.fill(CHARS, 3006, 3011, (byte) -87); // Fill 5 of value (byte) -87
0404:                Arrays.fill(CHARS, 3011, 3014, (byte) 33); // Fill 3 of value (byte) 33
0405:                Arrays.fill(CHARS, 3014, 3017, (byte) -87); // Fill 3 of value (byte) -87
0406:                CHARS[3017] = 33;
0407:                Arrays.fill(CHARS, 3018, 3022, (byte) -87); // Fill 4 of value (byte) -87
0408:                Arrays.fill(CHARS, 3022, 3031, (byte) 33); // Fill 9 of value (byte) 33
0409:                CHARS[3031] = -87;
0410:                Arrays.fill(CHARS, 3032, 3047, (byte) 33); // Fill 15 of value (byte) 33
0411:                Arrays.fill(CHARS, 3047, 3056, (byte) -87); // Fill 9 of value (byte) -87
0412:                Arrays.fill(CHARS, 3056, 3073, (byte) 33); // Fill 17 of value (byte) 33
0413:                Arrays.fill(CHARS, 3073, 3076, (byte) -87); // Fill 3 of value (byte) -87
0414:                CHARS[3076] = 33;
0415:                Arrays.fill(CHARS, 3077, 3085, (byte) -19); // Fill 8 of value (byte) -19
0416:                CHARS[3085] = 33;
0417:                Arrays.fill(CHARS, 3086, 3089, (byte) -19); // Fill 3 of value (byte) -19
0418:                CHARS[3089] = 33;
0419:                Arrays.fill(CHARS, 3090, 3113, (byte) -19); // Fill 23 of value (byte) -19
0420:                CHARS[3113] = 33;
0421:                Arrays.fill(CHARS, 3114, 3124, (byte) -19); // Fill 10 of value (byte) -19
0422:                CHARS[3124] = 33;
0423:                Arrays.fill(CHARS, 3125, 3130, (byte) -19); // Fill 5 of value (byte) -19
0424:                Arrays.fill(CHARS, 3130, 3134, (byte) 33); // Fill 4 of value (byte) 33
0425:                Arrays.fill(CHARS, 3134, 3141, (byte) -87); // Fill 7 of value (byte) -87
0426:                CHARS[3141] = 33;
0427:                Arrays.fill(CHARS, 3142, 3145, (byte) -87); // Fill 3 of value (byte) -87
0428:                CHARS[3145] = 33;
0429:                Arrays.fill(CHARS, 3146, 3150, (byte) -87); // Fill 4 of value (byte) -87
0430:                Arrays.fill(CHARS, 3150, 3157, (byte) 33); // Fill 7 of value (byte) 33
0431:                Arrays.fill(CHARS, 3157, 3159, (byte) -87); // Fill 2 of value (byte) -87
0432:                Arrays.fill(CHARS, 3159, 3168, (byte) 33); // Fill 9 of value (byte) 33
0433:                Arrays.fill(CHARS, 3168, 3170, (byte) -19); // Fill 2 of value (byte) -19
0434:                Arrays.fill(CHARS, 3170, 3174, (byte) 33); // Fill 4 of value (byte) 33
0435:                Arrays.fill(CHARS, 3174, 3184, (byte) -87); // Fill 10 of value (byte) -87
0436:                Arrays.fill(CHARS, 3184, 3202, (byte) 33); // Fill 18 of value (byte) 33
0437:                Arrays.fill(CHARS, 3202, 3204, (byte) -87); // Fill 2 of value (byte) -87
0438:                CHARS[3204] = 33;
0439:                Arrays.fill(CHARS, 3205, 3213, (byte) -19); // Fill 8 of value (byte) -19
0440:                CHARS[3213] = 33;
0441:                Arrays.fill(CHARS, 3214, 3217, (byte) -19); // Fill 3 of value (byte) -19
0442:                CHARS[3217] = 33;
0443:                Arrays.fill(CHARS, 3218, 3241, (byte) -19); // Fill 23 of value (byte) -19
0444:                CHARS[3241] = 33;
0445:                Arrays.fill(CHARS, 3242, 3252, (byte) -19); // Fill 10 of value (byte) -19
0446:                CHARS[3252] = 33;
0447:                Arrays.fill(CHARS, 3253, 3258, (byte) -19); // Fill 5 of value (byte) -19
0448:                Arrays.fill(CHARS, 3258, 3262, (byte) 33); // Fill 4 of value (byte) 33
0449:                Arrays.fill(CHARS, 3262, 3269, (byte) -87); // Fill 7 of value (byte) -87
0450:                CHARS[3269] = 33;
0451:                Arrays.fill(CHARS, 3270, 3273, (byte) -87); // Fill 3 of value (byte) -87
0452:                CHARS[3273] = 33;
0453:                Arrays.fill(CHARS, 3274, 3278, (byte) -87); // Fill 4 of value (byte) -87
0454:                Arrays.fill(CHARS, 3278, 3285, (byte) 33); // Fill 7 of value (byte) 33
0455:                Arrays.fill(CHARS, 3285, 3287, (byte) -87); // Fill 2 of value (byte) -87
0456:                Arrays.fill(CHARS, 3287, 3294, (byte) 33); // Fill 7 of value (byte) 33
0457:                CHARS[3294] = -19;
0458:                CHARS[3295] = 33;
0459:                Arrays.fill(CHARS, 3296, 3298, (byte) -19); // Fill 2 of value (byte) -19
0460:                Arrays.fill(CHARS, 3298, 3302, (byte) 33); // Fill 4 of value (byte) 33
0461:                Arrays.fill(CHARS, 3302, 3312, (byte) -87); // Fill 10 of value (byte) -87
0462:                Arrays.fill(CHARS, 3312, 3330, (byte) 33); // Fill 18 of value (byte) 33
0463:                Arrays.fill(CHARS, 3330, 3332, (byte) -87); // Fill 2 of value (byte) -87
0464:                CHARS[3332] = 33;
0465:                Arrays.fill(CHARS, 3333, 3341, (byte) -19); // Fill 8 of value (byte) -19
0466:                CHARS[3341] = 33;
0467:                Arrays.fill(CHARS, 3342, 3345, (byte) -19); // Fill 3 of value (byte) -19
0468:                CHARS[3345] = 33;
0469:                Arrays.fill(CHARS, 3346, 3369, (byte) -19); // Fill 23 of value (byte) -19
0470:                CHARS[3369] = 33;
0471:                Arrays.fill(CHARS, 3370, 3386, (byte) -19); // Fill 16 of value (byte) -19
0472:                Arrays.fill(CHARS, 3386, 3390, (byte) 33); // Fill 4 of value (byte) 33
0473:                Arrays.fill(CHARS, 3390, 3396, (byte) -87); // Fill 6 of value (byte) -87
0474:                Arrays.fill(CHARS, 3396, 3398, (byte) 33); // Fill 2 of value (byte) 33
0475:                Arrays.fill(CHARS, 3398, 3401, (byte) -87); // Fill 3 of value (byte) -87
0476:                CHARS[3401] = 33;
0477:                Arrays.fill(CHARS, 3402, 3406, (byte) -87); // Fill 4 of value (byte) -87
0478:                Arrays.fill(CHARS, 3406, 3415, (byte) 33); // Fill 9 of value (byte) 33
0479:                CHARS[3415] = -87;
0480:                Arrays.fill(CHARS, 3416, 3424, (byte) 33); // Fill 8 of value (byte) 33
0481:                Arrays.fill(CHARS, 3424, 3426, (byte) -19); // Fill 2 of value (byte) -19
0482:                Arrays.fill(CHARS, 3426, 3430, (byte) 33); // Fill 4 of value (byte) 33
0483:                Arrays.fill(CHARS, 3430, 3440, (byte) -87); // Fill 10 of value (byte) -87
0484:                Arrays.fill(CHARS, 3440, 3585, (byte) 33); // Fill 145 of value (byte) 33
0485:                Arrays.fill(CHARS, 3585, 3631, (byte) -19); // Fill 46 of value (byte) -19
0486:                CHARS[3631] = 33;
0487:                CHARS[3632] = -19;
0488:                CHARS[3633] = -87;
0489:                Arrays.fill(CHARS, 3634, 3636, (byte) -19); // Fill 2 of value (byte) -19
0490:                Arrays.fill(CHARS, 3636, 3643, (byte) -87); // Fill 7 of value (byte) -87
0491:                Arrays.fill(CHARS, 3643, 3648, (byte) 33); // Fill 5 of value (byte) 33
0492:                Arrays.fill(CHARS, 3648, 3654, (byte) -19); // Fill 6 of value (byte) -19
0493:                Arrays.fill(CHARS, 3654, 3663, (byte) -87); // Fill 9 of value (byte) -87
0494:                CHARS[3663] = 33;
0495:                Arrays.fill(CHARS, 3664, 3674, (byte) -87); // Fill 10 of value (byte) -87
0496:                Arrays.fill(CHARS, 3674, 3713, (byte) 33); // Fill 39 of value (byte) 33
0497:                Arrays.fill(CHARS, 3713, 3715, (byte) -19); // Fill 2 of value (byte) -19
0498:                CHARS[3715] = 33;
0499:                CHARS[3716] = -19;
0500:                Arrays.fill(CHARS, 3717, 3719, (byte) 33); // Fill 2 of value (byte) 33
0501:                Arrays.fill(CHARS, 3719, 3721, (byte) -19); // Fill 2 of value (byte) -19
0502:                CHARS[3721] = 33;
0503:                CHARS[3722] = -19;
0504:                Arrays.fill(CHARS, 3723, 3725, (byte) 33); // Fill 2 of value (byte) 33
0505:                CHARS[3725] = -19;
0506:                Arrays.fill(CHARS, 3726, 3732, (byte) 33); // Fill 6 of value (byte) 33
0507:                Arrays.fill(CHARS, 3732, 3736, (byte) -19); // Fill 4 of value (byte) -19
0508:                CHARS[3736] = 33;
0509:                Arrays.fill(CHARS, 3737, 3744, (byte) -19); // Fill 7 of value (byte) -19
0510:                CHARS[3744] = 33;
0511:                Arrays.fill(CHARS, 3745, 3748, (byte) -19); // Fill 3 of value (byte) -19
0512:                CHARS[3748] = 33;
0513:                CHARS[3749] = -19;
0514:                CHARS[3750] = 33;
0515:                CHARS[3751] = -19;
0516:                Arrays.fill(CHARS, 3752, 3754, (byte) 33); // Fill 2 of value (byte) 33
0517:                Arrays.fill(CHARS, 3754, 3756, (byte) -19); // Fill 2 of value (byte) -19
0518:                CHARS[3756] = 33;
0519:                Arrays.fill(CHARS, 3757, 3759, (byte) -19); // Fill 2 of value (byte) -19
0520:                CHARS[3759] = 33;
0521:                CHARS[3760] = -19;
0522:                CHARS[3761] = -87;
0523:                Arrays.fill(CHARS, 3762, 3764, (byte) -19); // Fill 2 of value (byte) -19
0524:                Arrays.fill(CHARS, 3764, 3770, (byte) -87); // Fill 6 of value (byte) -87
0525:                CHARS[3770] = 33;
0526:                Arrays.fill(CHARS, 3771, 3773, (byte) -87); // Fill 2 of value (byte) -87
0527:                CHARS[3773] = -19;
0528:                Arrays.fill(CHARS, 3774, 3776, (byte) 33); // Fill 2 of value (byte) 33
0529:                Arrays.fill(CHARS, 3776, 3781, (byte) -19); // Fill 5 of value (byte) -19
0530:                CHARS[3781] = 33;
0531:                CHARS[3782] = -87;
0532:                CHARS[3783] = 33;
0533:                Arrays.fill(CHARS, 3784, 3790, (byte) -87); // Fill 6 of value (byte) -87
0534:                Arrays.fill(CHARS, 3790, 3792, (byte) 33); // Fill 2 of value (byte) 33
0535:                Arrays.fill(CHARS, 3792, 3802, (byte) -87); // Fill 10 of value (byte) -87
0536:                Arrays.fill(CHARS, 3802, 3864, (byte) 33); // Fill 62 of value (byte) 33
0537:                Arrays.fill(CHARS, 3864, 3866, (byte) -87); // Fill 2 of value (byte) -87
0538:                Arrays.fill(CHARS, 3866, 3872, (byte) 33); // Fill 6 of value (byte) 33
0539:                Arrays.fill(CHARS, 3872, 3882, (byte) -87); // Fill 10 of value (byte) -87
0540:                Arrays.fill(CHARS, 3882, 3893, (byte) 33); // Fill 11 of value (byte) 33
0541:                CHARS[3893] = -87;
0542:                CHARS[3894] = 33;
0543:                CHARS[3895] = -87;
0544:                CHARS[3896] = 33;
0545:                CHARS[3897] = -87;
0546:                Arrays.fill(CHARS, 3898, 3902, (byte) 33); // Fill 4 of value (byte) 33
0547:                Arrays.fill(CHARS, 3902, 3904, (byte) -87); // Fill 2 of value (byte) -87
0548:                Arrays.fill(CHARS, 3904, 3912, (byte) -19); // Fill 8 of value (byte) -19
0549:                CHARS[3912] = 33;
0550:                Arrays.fill(CHARS, 3913, 3946, (byte) -19); // Fill 33 of value (byte) -19
0551:                Arrays.fill(CHARS, 3946, 3953, (byte) 33); // Fill 7 of value (byte) 33
0552:                Arrays.fill(CHARS, 3953, 3973, (byte) -87); // Fill 20 of value (byte) -87
0553:                CHARS[3973] = 33;
0554:                Arrays.fill(CHARS, 3974, 3980, (byte) -87); // Fill 6 of value (byte) -87
0555:                Arrays.fill(CHARS, 3980, 3984, (byte) 33); // Fill 4 of value (byte) 33
0556:                Arrays.fill(CHARS, 3984, 3990, (byte) -87); // Fill 6 of value (byte) -87
0557:                CHARS[3990] = 33;
0558:                CHARS[3991] = -87;
0559:                CHARS[3992] = 33;
0560:                Arrays.fill(CHARS, 3993, 4014, (byte) -87); // Fill 21 of value (byte) -87
0561:                Arrays.fill(CHARS, 4014, 4017, (byte) 33); // Fill 3 of value (byte) 33
0562:                Arrays.fill(CHARS, 4017, 4024, (byte) -87); // Fill 7 of value (byte) -87
0563:                CHARS[4024] = 33;
0564:                CHARS[4025] = -87;
0565:                Arrays.fill(CHARS, 4026, 4256, (byte) 33); // Fill 230 of value (byte) 33
0566:                Arrays.fill(CHARS, 4256, 4294, (byte) -19); // Fill 38 of value (byte) -19
0567:                Arrays.fill(CHARS, 4294, 4304, (byte) 33); // Fill 10 of value (byte) 33
0568:                Arrays.fill(CHARS, 4304, 4343, (byte) -19); // Fill 39 of value (byte) -19
0569:                Arrays.fill(CHARS, 4343, 4352, (byte) 33); // Fill 9 of value (byte) 33
0570:                CHARS[4352] = -19;
0571:                CHARS[4353] = 33;
0572:                Arrays.fill(CHARS, 4354, 4356, (byte) -19); // Fill 2 of value (byte) -19
0573:                CHARS[4356] = 33;
0574:                Arrays.fill(CHARS, 4357, 4360, (byte) -19); // Fill 3 of value (byte) -19
0575:                CHARS[4360] = 33;
0576:                CHARS[4361] = -19;
0577:                CHARS[4362] = 33;
0578:                Arrays.fill(CHARS, 4363, 4365, (byte) -19); // Fill 2 of value (byte) -19
0579:                CHARS[4365] = 33;
0580:                Arrays.fill(CHARS, 4366, 4371, (byte) -19); // Fill 5 of value (byte) -19
0581:                Arrays.fill(CHARS, 4371, 4412, (byte) 33); // Fill 41 of value (byte) 33
0582:                CHARS[4412] = -19;
0583:                CHARS[4413] = 33;
0584:                CHARS[4414] = -19;
0585:                CHARS[4415] = 33;
0586:                CHARS[4416] = -19;
0587:                Arrays.fill(CHARS, 4417, 4428, (byte) 33); // Fill 11 of value (byte) 33
0588:                CHARS[4428] = -19;
0589:                CHARS[4429] = 33;
0590:                CHARS[4430] = -19;
0591:                CHARS[4431] = 33;
0592:                CHARS[4432] = -19;
0593:                Arrays.fill(CHARS, 4433, 4436, (byte) 33); // Fill 3 of value (byte) 33
0594:                Arrays.fill(CHARS, 4436, 4438, (byte) -19); // Fill 2 of value (byte) -19
0595:                Arrays.fill(CHARS, 4438, 4441, (byte) 33); // Fill 3 of value (byte) 33
0596:                CHARS[4441] = -19;
0597:                Arrays.fill(CHARS, 4442, 4447, (byte) 33); // Fill 5 of value (byte) 33
0598:                Arrays.fill(CHARS, 4447, 4450, (byte) -19); // Fill 3 of value (byte) -19
0599:                CHARS[4450] = 33;
0600:                CHARS[4451] = -19;
0601:                CHARS[4452] = 33;
0602:                CHARS[4453] = -19;
0603:                CHARS[4454] = 33;
0604:                CHARS[4455] = -19;
0605:                CHARS[4456] = 33;
0606:                CHARS[4457] = -19;
0607:                Arrays.fill(CHARS, 4458, 4461, (byte) 33); // Fill 3 of value (byte) 33
0608:                Arrays.fill(CHARS, 4461, 4463, (byte) -19); // Fill 2 of value (byte) -19
0609:                Arrays.fill(CHARS, 4463, 4466, (byte) 33); // Fill 3 of value (byte) 33
0610:                Arrays.fill(CHARS, 4466, 4468, (byte) -19); // Fill 2 of value (byte) -19
0611:                CHARS[4468] = 33;
0612:                CHARS[4469] = -19;
0613:                Arrays.fill(CHARS, 4470, 4510, (byte) 33); // Fill 40 of value (byte) 33
0614:                CHARS[4510] = -19;
0615:                Arrays.fill(CHARS, 4511, 4520, (byte) 33); // Fill 9 of value (byte) 33
0616:                CHARS[4520] = -19;
0617:                Arrays.fill(CHARS, 4521, 4523, (byte) 33); // Fill 2 of value (byte) 33
0618:                CHARS[4523] = -19;
0619:                Arrays.fill(CHARS, 4524, 4526, (byte) 33); // Fill 2 of value (byte) 33
0620:                Arrays.fill(CHARS, 4526, 4528, (byte) -19); // Fill 2 of value (byte) -19
0621:                Arrays.fill(CHARS, 4528, 4535, (byte) 33); // Fill 7 of value (byte) 33
0622:                Arrays.fill(CHARS, 4535, 4537, (byte) -19); // Fill 2 of value (byte) -19
0623:                CHARS[4537] = 33;
0624:                CHARS[4538] = -19;
0625:                CHARS[4539] = 33;
0626:                Arrays.fill(CHARS, 4540, 4547, (byte) -19); // Fill 7 of value (byte) -19
0627:                Arrays.fill(CHARS, 4547, 4587, (byte) 33); // Fill 40 of value (byte) 33
0628:                CHARS[4587] = -19;
0629:                Arrays.fill(CHARS, 4588, 4592, (byte) 33); // Fill 4 of value (byte) 33
0630:                CHARS[4592] = -19;
0631:                Arrays.fill(CHARS, 4593, 4601, (byte) 33); // Fill 8 of value (byte) 33
0632:                CHARS[4601] = -19;
0633:                Arrays.fill(CHARS, 4602, 7680, (byte) 33); // Fill 3078 of value (byte) 33
0634:                Arrays.fill(CHARS, 7680, 7836, (byte) -19); // Fill 156 of value (byte) -19
0635:                Arrays.fill(CHARS, 7836, 7840, (byte) 33); // Fill 4 of value (byte) 33
0636:                Arrays.fill(CHARS, 7840, 7930, (byte) -19); // Fill 90 of value (byte) -19
0637:                Arrays.fill(CHARS, 7930, 7936, (byte) 33); // Fill 6 of value (byte) 33
0638:                Arrays.fill(CHARS, 7936, 7958, (byte) -19); // Fill 22 of value (byte) -19
0639:                Arrays.fill(CHARS, 7958, 7960, (byte) 33); // Fill 2 of value (byte) 33
0640:                Arrays.fill(CHARS, 7960, 7966, (byte) -19); // Fill 6 of value (byte) -19
0641:                Arrays.fill(CHARS, 7966, 7968, (byte) 33); // Fill 2 of value (byte) 33
0642:                Arrays.fill(CHARS, 7968, 8006, (byte) -19); // Fill 38 of value (byte) -19
0643:                Arrays.fill(CHARS, 8006, 8008, (byte) 33); // Fill 2 of value (byte) 33
0644:                Arrays.fill(CHARS, 8008, 8014, (byte) -19); // Fill 6 of value (byte) -19
0645:                Arrays.fill(CHARS, 8014, 8016, (byte) 33); // Fill 2 of value (byte) 33
0646:                Arrays.fill(CHARS, 8016, 8024, (byte) -19); // Fill 8 of value (byte) -19
0647:                CHARS[8024] = 33;
0648:                CHARS[8025] = -19;
0649:                CHARS[8026] = 33;
0650:                CHARS[8027] = -19;
0651:                CHARS[8028] = 33;
0652:                CHARS[8029] = -19;
0653:                CHARS[8030] = 33;
0654:                Arrays.fill(CHARS, 8031, 8062, (byte) -19); // Fill 31 of value (byte) -19
0655:                Arrays.fill(CHARS, 8062, 8064, (byte) 33); // Fill 2 of value (byte) 33
0656:                Arrays.fill(CHARS, 8064, 8117, (byte) -19); // Fill 53 of value (byte) -19
0657:                CHARS[8117] = 33;
0658:                Arrays.fill(CHARS, 8118, 8125, (byte) -19); // Fill 7 of value (byte) -19
0659:                CHARS[8125] = 33;
0660:                CHARS[8126] = -19;
0661:                Arrays.fill(CHARS, 8127, 8130, (byte) 33); // Fill 3 of value (byte) 33
0662:                Arrays.fill(CHARS, 8130, 8133, (byte) -19); // Fill 3 of value (byte) -19
0663:                CHARS[8133] = 33;
0664:                Arrays.fill(CHARS, 8134, 8141, (byte) -19); // Fill 7 of value (byte) -19
0665:                Arrays.fill(CHARS, 8141, 8144, (byte) 33); // Fill 3 of value (byte) 33
0666:                Arrays.fill(CHARS, 8144, 8148, (byte) -19); // Fill 4 of value (byte) -19
0667:                Arrays.fill(CHARS, 8148, 8150, (byte) 33); // Fill 2 of value (byte) 33
0668:                Arrays.fill(CHARS, 8150, 8156, (byte) -19); // Fill 6 of value (byte) -19
0669:                Arrays.fill(CHARS, 8156, 8160, (byte) 33); // Fill 4 of value (byte) 33
0670:                Arrays.fill(CHARS, 8160, 8173, (byte) -19); // Fill 13 of value (byte) -19
0671:                Arrays.fill(CHARS, 8173, 8178, (byte) 33); // Fill 5 of value (byte) 33
0672:                Arrays.fill(CHARS, 8178, 8181, (byte) -19); // Fill 3 of value (byte) -19
0673:                CHARS[8181] = 33;
0674:                Arrays.fill(CHARS, 8182, 8189, (byte) -19); // Fill 7 of value (byte) -19
0675:                Arrays.fill(CHARS, 8189, 8400, (byte) 33); // Fill 211 of value (byte) 33
0676:                Arrays.fill(CHARS, 8400, 8413, (byte) -87); // Fill 13 of value (byte) -87
0677:                Arrays.fill(CHARS, 8413, 8417, (byte) 33); // Fill 4 of value (byte) 33
0678:                CHARS[8417] = -87;
0679:                Arrays.fill(CHARS, 8418, 8486, (byte) 33); // Fill 68 of value (byte) 33
0680:                CHARS[8486] = -19;
0681:                Arrays.fill(CHARS, 8487, 8490, (byte) 33); // Fill 3 of value (byte) 33
0682:                Arrays.fill(CHARS, 8490, 8492, (byte) -19); // Fill 2 of value (byte) -19
0683:                Arrays.fill(CHARS, 8492, 8494, (byte) 33); // Fill 2 of value (byte) 33
0684:                CHARS[8494] = -19;
0685:                Arrays.fill(CHARS, 8495, 8576, (byte) 33); // Fill 81 of value (byte) 33
0686:                Arrays.fill(CHARS, 8576, 8579, (byte) -19); // Fill 3 of value (byte) -19
0687:                Arrays.fill(CHARS, 8579, 12293, (byte) 33); // Fill 3714 of value (byte) 33
0688:                CHARS[12293] = -87;
0689:                CHARS[12294] = 33;
0690:                CHARS[12295] = -19;
0691:                Arrays.fill(CHARS, 12296, 12321, (byte) 33); // Fill 25 of value (byte) 33
0692:                Arrays.fill(CHARS, 12321, 12330, (byte) -19); // Fill 9 of value (byte) -19
0693:                Arrays.fill(CHARS, 12330, 12336, (byte) -87); // Fill 6 of value (byte) -87
0694:                CHARS[12336] = 33;
0695:                Arrays.fill(CHARS, 12337, 12342, (byte) -87); // Fill 5 of value (byte) -87
0696:                Arrays.fill(CHARS, 12342, 12353, (byte) 33); // Fill 11 of value (byte) 33
0697:                Arrays.fill(CHARS, 12353, 12437, (byte) -19); // Fill 84 of value (byte) -19
0698:                Arrays.fill(CHARS, 12437, 12441, (byte) 33); // Fill 4 of value (byte) 33
0699:                Arrays.fill(CHARS, 12441, 12443, (byte) -87); // Fill 2 of value (byte) -87
0700:                Arrays.fill(CHARS, 12443, 12445, (byte) 33); // Fill 2 of value (byte) 33
0701:                Arrays.fill(CHARS, 12445, 12447, (byte) -87); // Fill 2 of value (byte) -87
0702:                Arrays.fill(CHARS, 12447, 12449, (byte) 33); // Fill 2 of value (byte) 33
0703:                Arrays.fill(CHARS, 12449, 12539, (byte) -19); // Fill 90 of value (byte) -19
0704:                CHARS[12539] = 33;
0705:                Arrays.fill(CHARS, 12540, 12543, (byte) -87); // Fill 3 of value (byte) -87
0706:                Arrays.fill(CHARS, 12543, 12549, (byte) 33); // Fill 6 of value (byte) 33
0707:                Arrays.fill(CHARS, 12549, 12589, (byte) -19); // Fill 40 of value (byte) -19
0708:                Arrays.fill(CHARS, 12589, 19968, (byte) 33); // Fill 7379 of value (byte) 33
0709:                Arrays.fill(CHARS, 19968, 40870, (byte) -19); // Fill 20902 of value (byte) -19
0710:                Arrays.fill(CHARS, 40870, 44032, (byte) 33); // Fill 3162 of value (byte) 33
0711:                Arrays.fill(CHARS, 44032, 55204, (byte) -19); // Fill 11172 of value (byte) -19
0712:                Arrays.fill(CHARS, 55204, 55296, (byte) 33); // Fill 92 of value (byte) 33
0713:                Arrays.fill(CHARS, 57344, 65534, (byte) 33); // Fill 8190 of value (byte) 33
0714:
0715:            } // <clinit>()
0716:
0717:            //
0718:            // Public static methods
0719:            //
0720:
0721:            /**
0722:             * Returns true if the specified character is a supplemental character.
0723:             *
0724:             * @param c The character to check.
0725:             */
0726:            public static boolean isSupplemental(int c) {
0727:                return (c >= 0x10000 && c <= 0x10FFFF);
0728:            }
0729:
0730:            /**
0731:             * Returns true the supplemental character corresponding to the given
0732:             * surrogates.
0733:             *
0734:             * @param h The high surrogate.
0735:             * @param l The low surrogate.
0736:             */
0737:            public static int supplemental(char h, char l) {
0738:                return (h - 0xD800) * 0x400 + (l - 0xDC00) + 0x10000;
0739:            }
0740:
0741:            /**
0742:             * Returns the high surrogate of a supplemental character
0743:             *
0744:             * @param c The supplemental character to "split".
0745:             */
0746:            public static char highSurrogate(int c) {
0747:                return (char) (((c - 0x00010000) >> 10) + 0xD800);
0748:            }
0749:
0750:            /**
0751:             * Returns the low surrogate of a supplemental character
0752:             *
0753:             * @param c The supplemental character to "split".
0754:             */
0755:            public static char lowSurrogate(int c) {
0756:                return (char) (((c - 0x00010000) & 0x3FF) + 0xDC00);
0757:            }
0758:
0759:            /**
0760:             * Returns whether the given character is a high surrogate
0761:             *
0762:             * @param c The character to check.
0763:             */
0764:            public static boolean isHighSurrogate(int c) {
0765:                return (0xD800 <= c && c <= 0xDBFF);
0766:            }
0767:
0768:            /**
0769:             * Returns whether the given character is a low surrogate
0770:             *
0771:             * @param c The character to check.
0772:             */
0773:            public static boolean isLowSurrogate(int c) {
0774:                return (0xDC00 <= c && c <= 0xDFFF);
0775:            }
0776:
0777:            /**
0778:             * Returns true if the specified character is valid. This method
0779:             * also checks the surrogate character range from 0x10000 to 0x10FFFF.
0780:             * <p>
0781:             * If the program chooses to apply the mask directly to the
0782:             * <code>CHARS</code> array, then they are responsible for checking
0783:             * the surrogate character range.
0784:             *
0785:             * @param c The character to check.
0786:             */
0787:            public static boolean isValid(int c) {
0788:                return (c < 0x10000 && (CHARS[c] & MASK_VALID) != 0)
0789:                        || (0x10000 <= c && c <= 0x10FFFF);
0790:            } // isValid(int):boolean
0791:
0792:            /**
0793:             * Returns true if the specified character is invalid.
0794:             *
0795:             * @param c The character to check.
0796:             */
0797:            public static boolean isInvalid(int c) {
0798:                return !isValid(c);
0799:            } // isInvalid(int):boolean
0800:
0801:            /**
0802:             * Returns true if the specified character can be considered content.
0803:             *
0804:             * @param c The character to check.
0805:             */
0806:            public static boolean isContent(int c) {
0807:                return (c < 0x10000 && (CHARS[c] & MASK_CONTENT) != 0)
0808:                        || (0x10000 <= c && c <= 0x10FFFF);
0809:            } // isContent(int):boolean
0810:
0811:            /**
0812:             * Returns true if the specified character can be considered markup.
0813:             * Markup characters include '&lt;', '&amp;', and '%'.
0814:             *
0815:             * @param c The character to check.
0816:             */
0817:            public static boolean isMarkup(int c) {
0818:                return c == '<' || c == '&' || c == '%';
0819:            } // isMarkup(int):boolean
0820:
0821:            /**
0822:             * Returns true if the specified character is a space character
0823:             * as defined by production [3] in the XML 1.0 specification.
0824:             *
0825:             * @param c The character to check.
0826:             */
0827:            public static boolean isSpace(int c) {
0828:                return c <= 0x20 && (CHARS[c] & MASK_SPACE) != 0;
0829:            } // isSpace(int):boolean
0830:
0831:            /**
0832:             * Returns true if the specified character is a valid name start
0833:             * character as defined by production [5] in the XML 1.0
0834:             * specification.
0835:             *
0836:             * @param c The character to check.
0837:             */
0838:            public static boolean isNameStart(int c) {
0839:                return c < 0x10000 && (CHARS[c] & MASK_NAME_START) != 0;
0840:            } // isNameStart(int):boolean
0841:
0842:            /**
0843:             * Returns true if the specified character is a valid name
0844:             * character as defined by production [4] in the XML 1.0
0845:             * specification.
0846:             *
0847:             * @param c The character to check.
0848:             */
0849:            public static boolean isName(int c) {
0850:                return c < 0x10000 && (CHARS[c] & MASK_NAME) != 0;
0851:            } // isName(int):boolean
0852:
0853:            /**
0854:             * Returns true if the specified character is a valid NCName start
0855:             * character as defined by production [4] in Namespaces in XML
0856:             * recommendation.
0857:             *
0858:             * @param c The character to check.
0859:             */
0860:            public static boolean isNCNameStart(int c) {
0861:                return c < 0x10000 && (CHARS[c] & MASK_NCNAME_START) != 0;
0862:            } // isNCNameStart(int):boolean
0863:
0864:            /**
0865:             * Returns true if the specified character is a valid NCName
0866:             * character as defined by production [5] in Namespaces in XML
0867:             * recommendation.
0868:             *
0869:             * @param c The character to check.
0870:             */
0871:            public static boolean isNCName(int c) {
0872:                return c < 0x10000 && (CHARS[c] & MASK_NCNAME) != 0;
0873:            } // isNCName(int):boolean
0874:
0875:            /**
0876:             * Returns true if the specified character is a valid Pubid
0877:             * character as defined by production [13] in the XML 1.0
0878:             * specification.
0879:             *
0880:             * @param c The character to check.
0881:             */
0882:            public static boolean isPubid(int c) {
0883:                return c < 0x10000 && (CHARS[c] & MASK_PUBID) != 0;
0884:            } // isPubid(int):boolean
0885:
0886:            /*
0887:             * [5] Name ::= (Letter | '_' | ':') (NameChar)*
0888:             */
0889:            /**
0890:             * Check to see if a string is a valid Name according to [5]
0891:             * in the XML 1.0 Recommendation
0892:             *
0893:             * @param name string to check
0894:             * @return true if name is a valid Name
0895:             */
0896:            public static boolean isValidName(String name) {
0897:                if (name.length() == 0)
0898:                    return false;
0899:                char ch = name.charAt(0);
0900:                if (isNameStart(ch) == false)
0901:                    return false;
0902:                for (int i = 1; i < name.length(); i++) {
0903:                    ch = name.charAt(i);
0904:                    if (isName(ch) == false) {
0905:                        return false;
0906:                    }
0907:                }
0908:                return true;
0909:            } // isValidName(String):boolean
0910:
0911:            /*
0912:             * from the namespace rec
0913:             * [4] NCName ::= (Letter | '_') (NCNameChar)*
0914:             */
0915:            /**
0916:             * Check to see if a string is a valid NCName according to [4]
0917:             * from the XML Namespaces 1.0 Recommendation
0918:             *
0919:             * @param ncName string to check
0920:             * @return true if name is a valid NCName
0921:             */
0922:            public static boolean isValidNCName(String ncName) {
0923:                if (ncName.length() == 0)
0924:                    return false;
0925:                char ch = ncName.charAt(0);
0926:                if (isNCNameStart(ch) == false)
0927:                    return false;
0928:                for (int i = 1; i < ncName.length(); i++) {
0929:                    ch = ncName.charAt(i);
0930:                    if (isNCName(ch) == false) {
0931:                        return false;
0932:                    }
0933:                }
0934:                return true;
0935:            } // isValidNCName(String):boolean
0936:
0937:            /*
0938:             * [7] Nmtoken ::= (NameChar)+
0939:             */
0940:            /**
0941:             * Check to see if a string is a valid Nmtoken according to [7]
0942:             * in the XML 1.0 Recommendation
0943:             *
0944:             * @param nmtoken string to check
0945:             * @return true if nmtoken is a valid Nmtoken 
0946:             */
0947:            public static boolean isValidNmtoken(String nmtoken) {
0948:                if (nmtoken.length() == 0)
0949:                    return false;
0950:                for (int i = 0; i < nmtoken.length(); i++) {
0951:                    char ch = nmtoken.charAt(i);
0952:                    if (!isName(ch)) {
0953:                        return false;
0954:                    }
0955:                }
0956:                return true;
0957:            } // isValidName(String):boolean
0958:
0959:            // encodings
0960:
0961:            /**
0962:             * Returns true if the encoding name is a valid IANA encoding.
0963:             * This method does not verify that there is a decoder available
0964:             * for this encoding, only that the characters are valid for an
0965:             * IANA encoding name.
0966:             *
0967:             * @param ianaEncoding The IANA encoding name.
0968:             */
0969:            public static boolean isValidIANAEncoding(String ianaEncoding) {
0970:                if (ianaEncoding != null) {
0971:                    int length = ianaEncoding.length();
0972:                    if (length > 0) {
0973:                        char c = ianaEncoding.charAt(0);
0974:                        if ((c >= 'A' && c <= 'Z') || (c >= 'a' && c <= 'z')) {
0975:                            for (int i = 1; i < length; i++) {
0976:                                c = ianaEncoding.charAt(i);
0977:                                if ((c < 'A' || c > 'Z')
0978:                                        && (c < 'a' || c > 'z')
0979:                                        && (c < '0' || c > '9') && c != '.'
0980:                                        && c != '_' && c != '-') {
0981:                                    return false;
0982:                                }
0983:                            }
0984:                            return true;
0985:                        }
0986:                    }
0987:                }
0988:                return false;
0989:            } // isValidIANAEncoding(String):boolean
0990:
0991:            /**
0992:             * Returns true if the encoding name is a valid Java encoding.
0993:             * This method does not verify that there is a decoder available
0994:             * for this encoding, only that the characters are valid for an
0995:             * Java encoding name.
0996:             *
0997:             * @param javaEncoding The Java encoding name.
0998:             */
0999:            public static boolean isValidJavaEncoding(String javaEncoding) {
1000:                if (javaEncoding != null) {
1001:                    int length = javaEncoding.length();
1002:                    if (length > 0) {
1003:                        for (int i = 1; i < length; i++) {
1004:                            char c = javaEncoding.charAt(i);
1005:                            if ((c < 'A' || c > 'Z') && (c < 'a' || c > 'z')
1006:                                    && (c < '0' || c > '9') && c != '.'
1007:                                    && c != '_' && c != '-') {
1008:                                return false;
1009:                            }
1010:                        }
1011:                        return true;
1012:                    }
1013:                }
1014:                return false;
1015:            } // isValidIANAEncoding(String):boolean
1016:
1017:            // other methods
1018:
1019:            /**
1020:             * Trims space characters as defined by production [3] in 
1021:             * the XML 1.0 specification from both ends of the given string.
1022:             * 
1023:             * @param value the string to be trimmed
1024:             * @return the given string with the space characters trimmed
1025:             * from both ends
1026:             */
1027:            public static String trim(String value) {
1028:                int start;
1029:                int end;
1030:                final int lengthMinusOne = value.length() - 1;
1031:                for (start = 0; start <= lengthMinusOne; ++start) {
1032:                    if (!isSpace(value.charAt(start))) {
1033:                        break;
1034:                    }
1035:                }
1036:                for (end = lengthMinusOne; end >= start; --end) {
1037:                    if (!isSpace(value.charAt(end))) {
1038:                        break;
1039:                    }
1040:                }
1041:                if (start == 0 && end == lengthMinusOne) {
1042:                    return value;
1043:                }
1044:                if (start > lengthMinusOne) {
1045:                    return "";
1046:                }
1047:                return value.substring(start, end + 1);
1048:            } // trim(String):String
1049:
1050:        } // class XMLChar
www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.