📄 sacparsertokenmanager.java
字号:
/* Generated By:JavaCC: Do not edit this line. SACParserTokenManager.java */package com.steadystate.css.parser;import java.io.*;import java.net.*;import java.util.*;import org.w3c.css.sac.*;import com.steadystate.css.parser.selectors.*;public class SACParserTokenManager implements SACParserConstants{ private boolean _quiet = true;/* private int getLastNumPos(StringBuffer sb) { int i; for( i = 0; i < sb.length(); i++ ) if( Character.isLetter( sb.charAt( i ) ) ) break; return i - 1; }*/ private String trimBy(StringBuffer s, int left, int right) { int end = s.length(); return s.toString().substring(left, end-right); } private String trimUrl(StringBuffer s) { StringBuffer s1 = new StringBuffer( trimBy(s, 4, 1).trim() ); int end = s1.length() - 1; if ((s1.charAt(0) == '"' && s1.charAt(end) == '"') || (s1.charAt(0) == '\'' && s1.charAt(end) == '\'')) return trimBy(s1, 1, 1); else return s1.toString(); } public java.io.PrintStream debugStream = System.out; public void setDebugStream(java.io.PrintStream ds) { debugStream = ds; }private final int jjStopStringLiteralDfa_0(int pos, long active0){ switch (pos) { case 0: if ((active0 & 0x1f0000000L) != 0L) return 61; if ((active0 & 0x40000800000000L) != 0L) { jjmatchedKind = 56; return 426; } if ((active0 & 0x100L) != 0L) return 427; return -1; case 1: if ((active0 & 0x40000800000000L) != 0L) { jjmatchedKind = 56; jjmatchedPos = 1; return 426; } if ((active0 & 0x1f0000000L) != 0L) { jjmatchedKind = 33; jjmatchedPos = 1; return 428; } return -1; case 2: if ((active0 & 0x1f0000000L) != 0L) { jjmatchedKind = 33; jjmatchedPos = 2; return 428; } if ((active0 & 0x40000800000000L) != 0L) { jjmatchedKind = 56; jjmatchedPos = 2; return 426; } return -1; case 3: if ((active0 & 0x800000000L) != 0L) { jjmatchedKind = 56; jjmatchedPos = 3; return 426; } if ((active0 & 0x1f0000000L) != 0L) { jjmatchedKind = 33; jjmatchedPos = 3; return 428; } return -1; case 4: if ((active0 & 0x800000000L) != 0L) { jjmatchedKind = 56; jjmatchedPos = 4; return 426; } if ((active0 & 0x20000000L) != 0L) return 428; if ((active0 & 0x1d0000000L) != 0L) { jjmatchedKind = 33; jjmatchedPos = 4; return 428; } return -1; case 5: if ((active0 & 0x190000000L) != 0L) { jjmatchedKind = 33; jjmatchedPos = 5; return 428; } if ((active0 & 0x40000000L) != 0L) return 428; if ((active0 & 0x800000000L) != 0L) { jjmatchedKind = 56; jjmatchedPos = 5; return 426; } return -1; case 6: if ((active0 & 0x10000000L) != 0L) return 428; if ((active0 & 0x180000000L) != 0L) { jjmatchedKind = 33; jjmatchedPos = 6; return 428; } if ((active0 & 0x800000000L) != 0L) return 426; return -1; case 7: if ((active0 & 0x100000000L) != 0L) return 428; if ((active0 & 0x80000000L) != 0L) { jjmatchedKind = 33; jjmatchedPos = 7; return 428; } return -1; case 8: if ((active0 & 0x80000000L) != 0L) { jjmatchedKind = 33; jjmatchedPos = 8; return 428; } return -1; default : return -1; }}private final int jjStartNfa_0(int pos, long active0){ return jjMoveNfa_0(jjStopStringLiteralDfa_0(pos, active0), pos + 1);}private final int jjStopAtPos(int pos, int kind){ jjmatchedKind = kind; jjmatchedPos = pos; return pos + 1;}private final int jjStartNfaWithStates_0(int pos, int kind, int state){ jjmatchedKind = kind; jjmatchedPos = pos; try { curChar = input_stream.readChar(); } catch(java.io.IOException e) { return pos + 1; } return jjMoveNfa_0(state, pos + 1);}private final int jjMoveStringLiteralDfa0_0(){ switch(curChar) { case 41: return jjStopAtPos(0, 21); case 42: return jjStopAtPos(0, 11); case 43: return jjStopAtPos(0, 13); case 44: return jjStopAtPos(0, 7); case 45: jjmatchedKind = 14; return jjMoveStringLiteralDfa1_0(0x2000000L); case 46: return jjStartNfaWithStates_0(0, 8, 427); case 47: jjmatchedKind = 12; return jjMoveStringLiteralDfa1_0(0x4L); case 58: return jjStopAtPos(0, 10); case 59: return jjStopAtPos(0, 9); case 60: return jjMoveStringLiteralDfa1_0(0x1000000L); case 61: return jjStopAtPos(0, 15); case 62: return jjStopAtPos(0, 16); case 64: return jjMoveStringLiteralDfa1_0(0x1f0000000L); case 91: return jjStopAtPos(0, 17); case 93: return jjStopAtPos(0, 18); case 73: case 105: return jjMoveStringLiteralDfa1_0(0x800000000L); case 82: case 114: return jjMoveStringLiteralDfa1_0(0x40000000000000L); case 123: return jjStopAtPos(0, 5); case 124: return jjMoveStringLiteralDfa1_0(0x8000000L); case 125: return jjStopAtPos(0, 6); case 126: return jjMoveStringLiteralDfa1_0(0x4000000L); default : return jjMoveNfa_0(1, 0); }}private final int jjMoveStringLiteralDfa1_0(long active0){ try { curChar = input_stream.readChar(); } catch(java.io.IOException e) { jjStopStringLiteralDfa_0(0, active0); return 1; } switch(curChar) { case 33: return jjMoveStringLiteralDfa2_0(active0, 0x1000000L); case 42: if ((active0 & 0x4L) != 0L) return jjStopAtPos(1, 2); break; case 45: return jjMoveStringLiteralDfa2_0(active0, 0x2000000L); case 61: if ((active0 & 0x4000000L) != 0L) return jjStopAtPos(1, 26); else if ((active0 & 0x8000000L) != 0L) return jjStopAtPos(1, 27); break; case 67: case 99: return jjMoveStringLiteralDfa2_0(active0, 0x100000000L); case 70: case 102: return jjMoveStringLiteralDfa2_0(active0, 0x80000000L); case 71: case 103: return jjMoveStringLiteralDfa2_0(active0, 0x40000000000000L); case 73: case 105: return jjMoveStringLiteralDfa2_0(active0, 0x10000000L); case 77: case 109: return jjMoveStringLiteralDfa2_0(active0, 0x40000000L); case 78: case 110: return jjMoveStringLiteralDfa2_0(active0, 0x800000000L); case 80: case 112: return jjMoveStringLiteralDfa2_0(active0, 0x20000000L); default : break; } return jjStartNfa_0(0, active0);}private final int jjMoveStringLiteralDfa2_0(long old0, long active0){ if (((active0 &= old0)) == 0L) return jjStartNfa_0(0, old0); try { curChar = input_stream.readChar(); } catch(java.io.IOException e) { jjStopStringLiteralDfa_0(1, active0); return 2; } switch(curChar) { case 45: return jjMoveStringLiteralDfa3_0(active0, 0x1000000L); case 62: if ((active0 & 0x2000000L) != 0L) return jjStopAtPos(2, 25); break; case 65: case 97: return jjMoveStringLiteralDfa3_0(active0, 0x20000000L); case 66: case 98: return jjMoveStringLiteralDfa3_0(active0, 0x40000000000000L); case 69: case 101: return jjMoveStringLiteralDfa3_0(active0, 0x40000000L); case 72: case 104: return jjMoveStringLiteralDfa3_0(active0, 0x900000000L); case 77: case 109: return jjMoveStringLiteralDfa3_0(active0, 0x10000000L); case 79: case 111: return jjMoveStringLiteralDfa3_0(active0, 0x80000000L); default : break; } return jjStartNfa_0(1, active0);}private final int jjMoveStringLiteralDfa3_0(long old0, long active0){ if (((active0 &= old0)) == 0L) return jjStartNfa_0(1, old0); try { curChar = input_stream.readChar(); } catch(java.io.IOException e) { jjStopStringLiteralDfa_0(2, active0); return 3; } switch(curChar) { case 40: if ((active0 & 0x40000000000000L) != 0L) return jjStopAtPos(3, 54); break; case 45: if ((active0 & 0x1000000L) != 0L) return jjStopAtPos(3, 24); break; case 65: case 97: return jjMoveStringLiteralDfa4_0(active0, 0x100000000L); case 68: case 100: return jjMoveStringLiteralDfa4_0(active0, 0x40000000L); case 69: case 101: return jjMoveStringLiteralDfa4_0(active0, 0x800000000L); case 71: case 103: return jjMoveStringLiteralDfa4_0(active0, 0x20000000L); case 78: case 110: return jjMoveStringLiteralDfa4_0(active0, 0x80000000L); case 80: case 112: return jjMoveStringLiteralDfa4_0(active0, 0x10000000L); default : break; } return jjStartNfa_0(2, active0);}private final int jjMoveStringLiteralDfa4_0(long old0, long active0){ if (((active0 &= old0)) == 0L) return jjStartNfa_0(2, old0); try { curChar = input_stream.readChar(); } catch(java.io.IOException e) { jjStopStringLiteralDfa_0(3, active0); return 4; } switch(curChar) { case 69: case 101: if ((active0 & 0x20000000L) != 0L) return jjStartNfaWithStates_0(4, 29, 428); break; case 73: case 105: return jjMoveStringLiteralDfa5_0(active0, 0x40000000L); case 79: case 111: return jjMoveStringLiteralDfa5_0(active0, 0x10000000L); case 82: case 114:
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -