Source Code Cross Referenced for ParserTokenManager.java in  » PDF » jPod » de » intarsys » pdf » postscript » 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 » PDF » jPod » de.intarsys.pdf.postscript 
Source Cross Referenced  Class Diagram Java Document (Java Doc) 


001:        /*
002:         * Copyright (c) 2007, intarsys consulting GmbH
003:         *
004:         * Redistribution and use in source and binary forms, with or without
005:         * modification, are permitted provided that the following conditions are met:
006:         *
007:         * - Redistributions of source code must retain the above copyright notice,
008:         *   this list of conditions and the following disclaimer.
009:         *
010:         * - Redistributions in binary form must reproduce the above copyright notice,
011:         *   this list of conditions and the following disclaimer in the documentation
012:         *   and/or other materials provided with the distribution.
013:         *
014:         * - Neither the name of intarsys nor the names of its contributors may be used
015:         *   to endorse or promote products derived from this software without specific
016:         *   prior written permission.
017:         *
018:         * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
019:         * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
020:         * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
021:         * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
022:         * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
023:         * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
024:         * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
025:         * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
026:         * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
027:         * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
028:         * POSSIBILITY OF SUCH DAMAGE.
029:         */
030:        /* Generated By:JavaCC: Do not edit this line. ParserTokenManager.java */
031:        package de.intarsys.pdf.postscript;
032:
033:        public class ParserTokenManager implements  ParserConstants {
034:            static final long[] jjbitVec0 = { 0xfffffffffffffffeL,
035:                    0xffffffffffffffffL, 0xffffffffffffffffL,
036:                    0xffffffffffffffffL };
037:
038:            static final long[] jjbitVec2 = { 0x0L, 0x0L, 0xffffffffffffffffL,
039:                    0xffffffffffffffffL };
040:
041:            static final long[] jjbitVec3 = { 0x1ff00000fffffffeL,
042:                    0xffffffffffffc000L, 0xffffffffL, 0x600000000000000L };
043:
044:            static final long[] jjbitVec4 = { 0x0L, 0x0L, 0x0L,
045:                    0xff7fffffff7fffffL };
046:
047:            static final long[] jjbitVec5 = { 0x0L, 0xffffffffffffffffL,
048:                    0xffffffffffffffffL, 0xffffffffffffffffL };
049:
050:            static final long[] jjbitVec6 = { 0xffffffffffffffffL,
051:                    0xffffffffffffffffL, 0xffffL, 0x0L };
052:
053:            static final long[] jjbitVec7 = { 0xffffffffffffffffL,
054:                    0xffffffffffffffffL, 0x0L, 0x0L };
055:
056:            static final long[] jjbitVec8 = { 0x3fffffffffffL, 0x0L, 0x0L, 0x0L };
057:
058:            static final int[] jjnextStates = { 33, 7, 54, 55, 60, 61, 64, 65,
059:                    13, 33, 4, 34, 40, 45, 49, 15, 16, 18, 9, 10, 13, 15, 16,
060:                    20, 18, 36, 37, 13, 41, 42, 13, 49, 50, 13, 56, 57, 13, 64,
061:                    65, 13, 2, 3, 11, 12, 17, 19, 21, 38, 39, 43, 44, 47, 48,
062:                    51, 52, 58, 59, 62, 63, 66, 67, };
063:
064:            public static final String[] jjstrLiteralImages = { "", null, null,
065:                    null, null, null, null, null, null, null, null, null, null,
066:                    null, "\173", "\175", "\133", "\135", };
067:
068:            static final long[] jjtoSkip = { 0x6L, };
069:
070:            static final long[] jjtoToken = { 0x3cf49L, };
071:
072:            public static final String[] lexStateNames = { "DEFAULT", };
073:
074:            private static final boolean jjCanMove_0(int hiByte, int i1,
075:                    int i2, long l1, long l2) {
076:                switch (hiByte) {
077:                case 0:
078:                    return ((jjbitVec2[i2] & l2) != 0L);
079:                default:
080:                    if ((jjbitVec0[i1] & l1) != 0L) {
081:                        return true;
082:                    }
083:                    return false;
084:                }
085:            }
086:
087:            private static final boolean jjCanMove_1(int hiByte, int i1,
088:                    int i2, long l1, long l2) {
089:                switch (hiByte) {
090:                case 0:
091:                    return ((jjbitVec4[i2] & l2) != 0L);
092:                case 48:
093:                    return ((jjbitVec5[i2] & l2) != 0L);
094:                case 49:
095:                    return ((jjbitVec6[i2] & l2) != 0L);
096:                case 51:
097:                    return ((jjbitVec7[i2] & l2) != 0L);
098:                case 61:
099:                    return ((jjbitVec8[i2] & l2) != 0L);
100:                default:
101:                    if ((jjbitVec3[i1] & l1) != 0L) {
102:                        return true;
103:                    }
104:                    return false;
105:                }
106:            }
107:
108:            protected char curChar;
109:
110:            int curLexState = 0;
111:
112:            public java.io.PrintStream debugStream = System.out;
113:
114:            int defaultLexState = 0;
115:
116:            protected JavaCharStream input_stream;
117:
118:            int jjmatchedKind;
119:
120:            int jjmatchedPos;
121:
122:            int jjnewStateCnt;
123:
124:            int jjround;
125:
126:            private final int[] jjrounds = new int[68];
127:
128:            private final int[] jjstateSet = new int[136];
129:
130:            public ParserTokenManager(JavaCharStream stream) {
131:                if (JavaCharStream.staticFlag) {
132:                    throw new Error(
133:                            "ERROR: Cannot use a static CharStream class with a non-static lexical analyzer.");
134:                }
135:                input_stream = stream;
136:            }
137:
138:            public ParserTokenManager(JavaCharStream stream, int lexState) {
139:                this (stream);
140:                SwitchTo(lexState);
141:            }
142:
143:            public Token getNextToken() {
144:                // int kind;
145:                // Token specialToken = null;
146:                Token matchedToken;
147:                int curPos = 0;
148:
149:                EOFLoop: for (;;) {
150:                    try {
151:                        curChar = input_stream.BeginToken();
152:                    } catch (java.io.IOException e) {
153:                        jjmatchedKind = 0;
154:                        matchedToken = jjFillToken();
155:                        return matchedToken;
156:                    }
157:
158:                    jjmatchedKind = 0x7fffffff;
159:                    jjmatchedPos = 0;
160:                    curPos = jjMoveStringLiteralDfa0_0();
161:                    if (jjmatchedKind != 0x7fffffff) {
162:                        if ((jjmatchedPos + 1) < curPos) {
163:                            input_stream.backup(curPos - jjmatchedPos - 1);
164:                        }
165:                        if ((jjtoToken[jjmatchedKind >> 6] & (1L << (jjmatchedKind & 077))) != 0L) {
166:                            matchedToken = jjFillToken();
167:                            return matchedToken;
168:                        } else {
169:                            continue EOFLoop;
170:                        }
171:                    }
172:                    int error_line = input_stream.getEndLine();
173:                    int error_column = input_stream.getEndColumn();
174:                    String error_after = null;
175:                    boolean EOFSeen = false;
176:                    try {
177:                        input_stream.readChar();
178:                        input_stream.backup(1);
179:                    } catch (java.io.IOException e1) {
180:                        EOFSeen = true;
181:                        error_after = (curPos <= 1) ? "" : input_stream
182:                                .GetImage();
183:                        if ((curChar == '\n') || (curChar == '\r')) {
184:                            error_line++;
185:                            error_column = 0;
186:                        } else {
187:                            error_column++;
188:                        }
189:                    }
190:                    if (!EOFSeen) {
191:                        input_stream.backup(1);
192:                        error_after = (curPos <= 1) ? "" : input_stream
193:                                .GetImage();
194:                    }
195:                    throw new TokenMgrError(EOFSeen, curLexState, error_line,
196:                            error_column, error_after, curChar,
197:                            TokenMgrError.LEXICAL_ERROR);
198:                }
199:            }
200:
201:            private final void jjAddStates(int start, int end) {
202:                do {
203:                    jjstateSet[jjnewStateCnt++] = jjnextStates[start];
204:                } while (start++ != end);
205:            }
206:
207:            private final void jjCheckNAdd(int state) {
208:                if (jjrounds[state] != jjround) {
209:                    jjstateSet[jjnewStateCnt++] = state;
210:                    jjrounds[state] = jjround;
211:                }
212:            }
213:
214:            private final void jjCheckNAddStates(int start) {
215:                jjCheckNAdd(jjnextStates[start]);
216:                jjCheckNAdd(jjnextStates[start + 1]);
217:            }
218:
219:            private final void jjCheckNAddStates(int start, int end) {
220:                do {
221:                    jjCheckNAdd(jjnextStates[start]);
222:                } while (start++ != end);
223:            }
224:
225:            private final void jjCheckNAddTwoStates(int state1, int state2) {
226:                jjCheckNAdd(state1);
227:                jjCheckNAdd(state2);
228:            }
229:
230:            protected Token jjFillToken() {
231:                Token t = Token.newToken(jjmatchedKind);
232:                t.kind = jjmatchedKind;
233:                String im = jjstrLiteralImages[jjmatchedKind];
234:                t.image = (im == null) ? input_stream.GetImage() : im;
235:                t.beginLine = input_stream.getBeginLine();
236:                t.beginColumn = input_stream.getBeginColumn();
237:                t.endLine = input_stream.getEndLine();
238:                t.endColumn = input_stream.getEndColumn();
239:                return t;
240:            }
241:
242:            private final int jjMoveNfa_0(int startState, int curPos) {
243:                // int[] nextStates;
244:                int startsAt = 0;
245:                jjnewStateCnt = 68;
246:                int i = 1;
247:                jjstateSet[0] = startState;
248:                int kind = 0x7fffffff;
249:                for (;;) {
250:                    if (++jjround == 0x7fffffff) {
251:                        ReInitRounds();
252:                    }
253:                    if (curChar < 64) {
254:                        long l = 1L << curChar;
255:                        MatchLoop: do {
256:                            switch (jjstateSet[--i]) {
257:                            case 0:
258:                                if ((0x3ff000000000000L & l) != 0L) {
259:                                    if (kind > 3) {
260:                                        kind = 3;
261:                                    }
262:                                    jjCheckNAddStates(0, 8);
263:                                } else if ((0x100003600L & l) != 0L) {
264:                                    if (kind > 1) {
265:                                        kind = 1;
266:                                    }
267:                                } else if (curChar == 45) {
268:                                    jjCheckNAddStates(9, 14);
269:                                } else if (curChar == 47) {
270:                                    jjstateSet[jjnewStateCnt++] = 28;
271:                                } else if (curChar == 36) {
272:                                    if (kind > 9) {
273:                                        kind = 9;
274:                                    }
275:                                    jjCheckNAdd(24);
276:                                } else if (curChar == 40) {
277:                                    jjCheckNAddStates(15, 17);
278:                                } else if (curChar == 46) {
279:                                    jjCheckNAdd(9);
280:                                } else if (curChar == 37) {
281:                                    jjCheckNAddTwoStates(2, 3);
282:                                }
283:                                if (curChar == 47) {
284:                                    jjstateSet[jjnewStateCnt++] = 26;
285:                                } else if (curChar == 48) {
286:                                    jjstateSet[jjnewStateCnt++] = 5;
287:                                }
288:                                break;
289:                            case 1:
290:                                if (curChar == 37) {
291:                                    jjCheckNAddTwoStates(2, 3);
292:                                }
293:                                break;
294:                            case 2:
295:                                if ((0xfffffffffffffbffL & l) != 0L) {
296:                                    jjCheckNAddTwoStates(2, 3);
297:                                }
298:                                break;
299:                            case 3:
300:                                if ((curChar == 10) && (kind > 2)) {
301:                                    kind = 2;
302:                                }
303:                                break;
304:                            case 4:
305:                                if (curChar == 48) {
306:                                    jjstateSet[jjnewStateCnt++] = 5;
307:                                }
308:                                break;
309:                            case 6:
310:                                if ((0x3ff000000000000L & l) == 0L) {
311:                                    break;
312:                                }
313:                                if (kind > 3) {
314:                                    kind = 3;
315:                                }
316:                                jjCheckNAddTwoStates(6, 7);
317:                                break;
318:                            case 8:
319:                                if (curChar == 46) {
320:                                    jjCheckNAdd(9);
321:                                }
322:                                break;
323:                            case 9:
324:                                if ((0x3ff000000000000L & l) == 0L) {
325:                                    break;
326:                                }
327:                                if (kind > 6) {
328:                                    kind = 6;
329:                                }
330:                                jjCheckNAddStates(18, 20);
331:                                break;
332:                            case 11:
333:                                if ((0x280000000000L & l) != 0L) {
334:                                    jjCheckNAdd(12);
335:                                }
336:                                break;
337:                            case 12:
338:                                if ((0x3ff000000000000L & l) == 0L) {
339:                                    break;
340:                                }
341:                                if (kind > 6) {
342:                                    kind = 6;
343:                                }
344:                                jjCheckNAddTwoStates(12, 13);
345:                                break;
346:                            case 14:
347:                                if (curChar == 40) {
348:                                    jjCheckNAddStates(15, 17);
349:                                }
350:                                break;
351:                            case 15:
352:                                if ((0xfffffdffffffdbffL & l) != 0L) {
353:                                    jjCheckNAddStates(15, 17);
354:                                }
355:                                break;
356:                            case 17:
357:                                if ((0x28000000400L & l) != 0L) {
358:                                    jjCheckNAddStates(15, 17);
359:                                }
360:                                break;
361:                            case 18:
362:                                if ((curChar == 41) && (kind > 8)) {
363:                                    kind = 8;
364:                                }
365:                                break;
366:                            case 19:
367:                                if ((0xff000000000000L & l) != 0L) {
368:                                    jjCheckNAddStates(21, 24);
369:                                }
370:                                break;
371:                            case 20:
372:                                if ((0xff000000000000L & l) != 0L) {
373:                                    jjCheckNAddStates(15, 17);
374:                                }
375:                                break;
376:                            case 21:
377:                                if ((0xf000000000000L & l) != 0L) {
378:                                    jjstateSet[jjnewStateCnt++] = 22;
379:                                }
380:                                break;
381:                            case 22:
382:                                if ((0xff000000000000L & l) != 0L) {
383:                                    jjCheckNAdd(20);
384:                                }
385:                                break;
386:                            case 23:
387:                                if (curChar != 36) {
388:                                    break;
389:                                }
390:                                if (kind > 9) {
391:                                    kind = 9;
392:                                }
393:                                jjCheckNAdd(24);
394:                                break;
395:                            case 24:
396:                                if ((0x3ff601000000000L & l) == 0L) {
397:                                    break;
398:                                }
399:                                if (kind > 9) {
400:                                    kind = 9;
401:                                }
402:                                jjCheckNAdd(24);
403:                                break;
404:                            case 25:
405:                                if (curChar == 47) {
406:                                    jjstateSet[jjnewStateCnt++] = 26;
407:                                }
408:                                break;
409:                            case 26:
410:                                if (curChar != 36) {
411:                                    break;
412:                                }
413:                                if (kind > 10) {
414:                                    kind = 10;
415:                                }
416:                                jjCheckNAdd(27);
417:                                break;
418:                            case 27:
419:                                if ((0x3ff601000000000L & l) == 0L) {
420:                                    break;
421:                                }
422:                                if (kind > 10) {
423:                                    kind = 10;
424:                                }
425:                                jjCheckNAdd(27);
426:                                break;
427:                            case 28:
428:                                if (curChar == 47) {
429:                                    jjstateSet[jjnewStateCnt++] = 29;
430:                                }
431:                                break;
432:                            case 29:
433:                                if (curChar != 36) {
434:                                    break;
435:                                }
436:                                if (kind > 11) {
437:                                    kind = 11;
438:                                }
439:                                jjCheckNAdd(30);
440:                                break;
441:                            case 30:
442:                                if ((0x3ff601000000000L & l) == 0L) {
443:                                    break;
444:                                }
445:                                if (kind > 11) {
446:                                    kind = 11;
447:                                }
448:                                jjCheckNAdd(30);
449:                                break;
450:                            case 31:
451:                                if (curChar == 47) {
452:                                    jjstateSet[jjnewStateCnt++] = 28;
453:                                }
454:                                break;
455:                            case 32:
456:                                if (curChar == 45) {
457:                                    jjCheckNAddStates(9, 14);
458:                                }
459:                                break;
460:                            case 33:
461:                                if ((0x3ff000000000000L & l) == 0L) {
462:                                    break;
463:                                }
464:                                if (kind > 3) {
465:                                    kind = 3;
466:                                }
467:                                jjCheckNAddTwoStates(33, 7);
468:                                break;
469:                            case 34:
470:                                if ((0x3ff000000000000L & l) != 0L) {
471:                                    jjCheckNAddTwoStates(34, 35);
472:                                }
473:                                break;
474:                            case 35:
475:                                if (curChar != 46) {
476:                                    break;
477:                                }
478:                                if (kind > 6) {
479:                                    kind = 6;
480:                                }
481:                                jjCheckNAddStates(25, 27);
482:                                break;
483:                            case 36:
484:                                if ((0x3ff000000000000L & l) == 0L) {
485:                                    break;
486:                                }
487:                                if (kind > 6) {
488:                                    kind = 6;
489:                                }
490:                                jjCheckNAddStates(25, 27);
491:                                break;
492:                            case 38:
493:                                if ((0x280000000000L & l) != 0L) {
494:                                    jjCheckNAdd(39);
495:                                }
496:                                break;
497:                            case 39:
498:                                if ((0x3ff000000000000L & l) == 0L) {
499:                                    break;
500:                                }
501:                                if (kind > 6) {
502:                                    kind = 6;
503:                                }
504:                                jjCheckNAddTwoStates(39, 13);
505:                                break;
506:                            case 40:
507:                                if (curChar == 46) {
508:                                    jjCheckNAdd(41);
509:                                }
510:                                break;
511:                            case 41:
512:                                if ((0x3ff000000000000L & l) == 0L) {
513:                                    break;
514:                                }
515:                                if (kind > 6) {
516:                                    kind = 6;
517:                                }
518:                                jjCheckNAddStates(28, 30);
519:                                break;
520:                            case 43:
521:                                if ((0x280000000000L & l) != 0L) {
522:                                    jjCheckNAdd(44);
523:                                }
524:                                break;
525:                            case 44:
526:                                if ((0x3ff000000000000L & l) == 0L) {
527:                                    break;
528:                                }
529:                                if (kind > 6) {
530:                                    kind = 6;
531:                                }
532:                                jjCheckNAddTwoStates(44, 13);
533:                                break;
534:                            case 45:
535:                                if ((0x3ff000000000000L & l) != 0L) {
536:                                    jjCheckNAddTwoStates(45, 46);
537:                                }
538:                                break;
539:                            case 47:
540:                                if ((0x280000000000L & l) != 0L) {
541:                                    jjCheckNAdd(48);
542:                                }
543:                                break;
544:                            case 48:
545:                                if ((0x3ff000000000000L & l) == 0L) {
546:                                    break;
547:                                }
548:                                if (kind > 6) {
549:                                    kind = 6;
550:                                }
551:                                jjCheckNAddTwoStates(48, 13);
552:                                break;
553:                            case 49:
554:                                if ((0x3ff000000000000L & l) != 0L) {
555:                                    jjCheckNAddStates(31, 33);
556:                                }
557:                                break;
558:                            case 51:
559:                                if ((0x280000000000L & l) != 0L) {
560:                                    jjCheckNAdd(52);
561:                                }
562:                                break;
563:                            case 52:
564:                                if ((0x3ff000000000000L & l) != 0L) {
565:                                    jjCheckNAddTwoStates(52, 13);
566:                                }
567:                                break;
568:                            case 53:
569:                                if ((0x3ff000000000000L & l) == 0L) {
570:                                    break;
571:                                }
572:                                if (kind > 3) {
573:                                    kind = 3;
574:                                }
575:                                jjCheckNAddStates(0, 8);
576:                                break;
577:                            case 54:
578:                                if ((0x3ff000000000000L & l) != 0L) {
579:                                    jjCheckNAddTwoStates(54, 55);
580:                                }
581:                                break;
582:                            case 55:
583:                                if (curChar != 46) {
584:                                    break;
585:                                }
586:                                if (kind > 6) {
587:                                    kind = 6;
588:                                }
589:                                jjCheckNAddStates(34, 36);
590:                                break;
591:                            case 56:
592:                                if ((0x3ff000000000000L & l) == 0L) {
593:                                    break;
594:                                }
595:                                if (kind > 6) {
596:                                    kind = 6;
597:                                }
598:                                jjCheckNAddStates(34, 36);
599:                                break;
600:                            case 58:
601:                                if ((0x280000000000L & l) != 0L) {
602:                                    jjCheckNAdd(59);
603:                                }
604:                                break;
605:                            case 59:
606:                                if ((0x3ff000000000000L & l) == 0L) {
607:                                    break;
608:                                }
609:                                if (kind > 6) {
610:                                    kind = 6;
611:                                }
612:                                jjCheckNAddTwoStates(59, 13);
613:                                break;
614:                            case 60:
615:                                if ((0x3ff000000000000L & l) != 0L) {
616:                                    jjCheckNAddTwoStates(60, 61);
617:                                }
618:                                break;
619:                            case 62:
620:                                if ((0x280000000000L & l) != 0L) {
621:                                    jjCheckNAdd(63);
622:                                }
623:                                break;
624:                            case 63:
625:                                if ((0x3ff000000000000L & l) == 0L) {
626:                                    break;
627:                                }
628:                                if (kind > 6) {
629:                                    kind = 6;
630:                                }
631:                                jjCheckNAddTwoStates(63, 13);
632:                                break;
633:                            case 64:
634:                                if ((0x3ff000000000000L & l) != 0L) {
635:                                    jjCheckNAddStates(37, 39);
636:                                }
637:                                break;
638:                            case 66:
639:                                if ((0x280000000000L & l) != 0L) {
640:                                    jjCheckNAdd(67);
641:                                }
642:                                break;
643:                            case 67:
644:                                if ((0x3ff000000000000L & l) != 0L) {
645:                                    jjCheckNAddTwoStates(67, 13);
646:                                }
647:                                break;
648:                            default:
649:                                break;
650:                            }
651:                        } while (i != startsAt);
652:                    } else if (curChar < 128) {
653:                        long l = 1L << (curChar & 077);
654:                        MatchLoop: do {
655:                            switch (jjstateSet[--i]) {
656:                            case 0:
657:                            case 24:
658:                                if ((0x7fffffe87fffffeL & l) == 0L) {
659:                                    break;
660:                                }
661:                                if (kind > 9) {
662:                                    kind = 9;
663:                                }
664:                                jjCheckNAdd(24);
665:                                break;
666:                            case 2:
667:                                jjAddStates(40, 41);
668:                                break;
669:                            case 5:
670:                                if ((0x100000001000000L & l) != 0L) {
671:                                    jjCheckNAdd(6);
672:                                }
673:                                break;
674:                            case 6:
675:                                if ((0x7e0000007eL & l) == 0L) {
676:                                    break;
677:                                }
678:                                if (kind > 3) {
679:                                    kind = 3;
680:                                }
681:                                jjCheckNAddTwoStates(6, 7);
682:                                break;
683:                            case 7:
684:                                if (((0x100000001000L & l) != 0L) && (kind > 3)) {
685:                                    kind = 3;
686:                                }
687:                                break;
688:                            case 10:
689:                                if ((0x2000000020L & l) != 0L) {
690:                                    jjAddStates(42, 43);
691:                                }
692:                                break;
693:                            case 13:
694:                                if (((0x5000000050L & l) != 0L) && (kind > 6)) {
695:                                    kind = 6;
696:                                }
697:                                break;
698:                            case 15:
699:                                if ((0xffffffffefffffffL & l) != 0L) {
700:                                    jjCheckNAddStates(15, 17);
701:                                }
702:                                break;
703:                            case 16:
704:                                if (curChar == 92) {
705:                                    jjAddStates(44, 46);
706:                                }
707:                                break;
708:                            case 17:
709:                                if ((0x14404410000000L & l) != 0L) {
710:                                    jjCheckNAddStates(15, 17);
711:                                }
712:                                break;
713:                            case 26:
714:                            case 27:
715:                                if ((0x7fffffe87fffffeL & l) == 0L) {
716:                                    break;
717:                                }
718:                                if (kind > 10) {
719:                                    kind = 10;
720:                                }
721:                                jjCheckNAdd(27);
722:                                break;
723:                            case 29:
724:                            case 30:
725:                                if ((0x7fffffe87fffffeL & l) == 0L) {
726:                                    break;
727:                                }
728:                                if (kind > 11) {
729:                                    kind = 11;
730:                                }
731:                                jjCheckNAdd(30);
732:                                break;
733:                            case 37:
734:                                if ((0x2000000020L & l) != 0L) {
735:                                    jjAddStates(47, 48);
736:                                }
737:                                break;
738:                            case 42:
739:                                if ((0x2000000020L & l) != 0L) {
740:                                    jjAddStates(49, 50);
741:                                }
742:                                break;
743:                            case 46:
744:                                if ((0x2000000020L & l) != 0L) {
745:                                    jjAddStates(51, 52);
746:                                }
747:                                break;
748:                            case 50:
749:                                if ((0x2000000020L & l) != 0L) {
750:                                    jjAddStates(53, 54);
751:                                }
752:                                break;
753:                            case 57:
754:                                if ((0x2000000020L & l) != 0L) {
755:                                    jjAddStates(55, 56);
756:                                }
757:                                break;
758:                            case 61:
759:                                if ((0x2000000020L & l) != 0L) {
760:                                    jjAddStates(57, 58);
761:                                }
762:                                break;
763:                            case 65:
764:                                if ((0x2000000020L & l) != 0L) {
765:                                    jjAddStates(59, 60);
766:                                }
767:                                break;
768:                            default:
769:                                break;
770:                            }
771:                        } while (i != startsAt);
772:                    } else {
773:                        int hiByte = (int) (curChar >> 8);
774:                        int i1 = hiByte >> 6;
775:                        long l1 = 1L << (hiByte & 077);
776:                        int i2 = (curChar & 0xff) >> 6;
777:                        long l2 = 1L << (curChar & 077);
778:                        MatchLoop: do {
779:                            switch (jjstateSet[--i]) {
780:                            case 0:
781:                            case 24:
782:                                if (!jjCanMove_1(hiByte, i1, i2, l1, l2)) {
783:                                    break;
784:                                }
785:                                if (kind > 9) {
786:                                    kind = 9;
787:                                }
788:                                jjCheckNAdd(24);
789:                                break;
790:                            case 2:
791:                                if (jjCanMove_0(hiByte, i1, i2, l1, l2)) {
792:                                    jjAddStates(40, 41);
793:                                }
794:                                break;
795:                            case 15:
796:                                if (jjCanMove_0(hiByte, i1, i2, l1, l2)) {
797:                                    jjAddStates(15, 17);
798:                                }
799:                                break;
800:                            case 26:
801:                            case 27:
802:                                if (!jjCanMove_1(hiByte, i1, i2, l1, l2)) {
803:                                    break;
804:                                }
805:                                if (kind > 10) {
806:                                    kind = 10;
807:                                }
808:                                jjCheckNAdd(27);
809:                                break;
810:                            case 29:
811:                            case 30:
812:                                if (!jjCanMove_1(hiByte, i1, i2, l1, l2)) {
813:                                    break;
814:                                }
815:                                if (kind > 11) {
816:                                    kind = 11;
817:                                }
818:                                jjCheckNAdd(30);
819:                                break;
820:                            default:
821:                                break;
822:                            }
823:                        } while (i != startsAt);
824:                    }
825:                    if (kind != 0x7fffffff) {
826:                        jjmatchedKind = kind;
827:                        jjmatchedPos = curPos;
828:                        kind = 0x7fffffff;
829:                    }
830:                    ++curPos;
831:                    if ((i = jjnewStateCnt) == (startsAt = 68 - (jjnewStateCnt = startsAt))) {
832:                        return curPos;
833:                    }
834:                    try {
835:                        curChar = input_stream.readChar();
836:                    } catch (java.io.IOException e) {
837:                        return curPos;
838:                    }
839:                }
840:            }
841:
842:            private final int jjMoveStringLiteralDfa0_0() {
843:                switch (curChar) {
844:                case 91:
845:                    return jjStopAtPos(0, 16);
846:                case 93:
847:                    return jjStopAtPos(0, 17);
848:                case 123:
849:                    return jjStopAtPos(0, 14);
850:                case 125:
851:                    return jjStopAtPos(0, 15);
852:                default:
853:                    return jjMoveNfa_0(0, 0);
854:                }
855:            }
856:
857:            private final int jjStartNfa_0(int pos, long active0) {
858:                return jjMoveNfa_0(jjStopStringLiteralDfa_0(pos, active0),
859:                        pos + 1);
860:            }
861:
862:            private final int jjStartNfaWithStates_0(int pos, int kind,
863:                    int state) {
864:                jjmatchedKind = kind;
865:                jjmatchedPos = pos;
866:                try {
867:                    curChar = input_stream.readChar();
868:                } catch (java.io.IOException e) {
869:                    return pos + 1;
870:                }
871:                return jjMoveNfa_0(state, pos + 1);
872:            }
873:
874:            private final int jjStopAtPos(int pos, int kind) {
875:                jjmatchedKind = kind;
876:                jjmatchedPos = pos;
877:                return pos + 1;
878:            }
879:
880:            private final int jjStopStringLiteralDfa_0(int pos, long active0) {
881:                switch (pos) {
882:                default:
883:                    return -1;
884:                }
885:            }
886:
887:            public void ReInit(JavaCharStream stream) {
888:                jjmatchedPos = jjnewStateCnt = 0;
889:                curLexState = defaultLexState;
890:                input_stream = stream;
891:                ReInitRounds();
892:            }
893:
894:            public void ReInit(JavaCharStream stream, int lexState) {
895:                ReInit(stream);
896:                SwitchTo(lexState);
897:            }
898:
899:            private final void ReInitRounds() {
900:                int i;
901:                jjround = 0x80000001;
902:                for (i = 68; i-- > 0;)
903:                    jjrounds[i] = 0x80000000;
904:            }
905:
906:            public void setDebugStream(java.io.PrintStream ds) {
907:                debugStream = ds;
908:            }
909:
910:            public void SwitchTo(int lexState) {
911:                if ((lexState >= 1) || (lexState < 0)) {
912:                    throw new TokenMgrError(
913:                            "Error: Ignoring invalid lexical state : "
914:                                    + lexState + ". State unchanged.",
915:                            TokenMgrError.INVALID_LEXICAL_STATE);
916:                } else {
917:                    curLexState = lexState;
918:                }
919:            }
920:        }
www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.