⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 tablescanner.java

📁 该工具也是用于字节码插桩
💻 JAVA
📖 第 1 页 / 共 2 页
字号:
  }  /**   * Returns the current lexical state.   */  final public int yystate() {    return yy_lexical_state;  }  /**   * Enters a new lexical state   *   * @param newState the new lexical state   */  final public void yybegin(int newState) {    yy_lexical_state = newState;  }  /**   * Returns the text matched by the current regular expression.   */  final public String yytext() {    return new String( yy_buffer, yy_startRead, yy_markedPos-yy_startRead );  }  /**   * Returns the character at position <tt>pos</tt> from the    * matched text.    *    * It is equivalent to yytext().charAt(pos), but faster   *   * @param pos the position of the character to fetch.    *            A value from 0 to yylength()-1.   *   * @return the character at position pos   */  final public char yycharat(int pos) {    return yy_buffer[yy_startRead+pos];  }  /**   * Returns the length of the matched text region.   */  final public int yylength() {    return yy_markedPos-yy_startRead;  }  /**   * Reports an error that occured while scanning.   *   * In a wellformed scanner (no or only correct usage of    * yypushback(int) and a match-all fallback rule) this method    * will only be called with things that "Can't Possibly Happen".   * If this method is called, something is seriously wrong   * (e.g. a JFlex bug producing a faulty scanner etc.).   *   * Usual syntax/scanner level error handling should be done   * in error fallback rules.   *   * @param   errorCode  the code of the errormessage to display   */  private void yy_ScanError(int errorCode) {    String message;    try {      message = YY_ERROR_MSG[errorCode];    }    catch (ArrayIndexOutOfBoundsException e) {      message = YY_ERROR_MSG[YY_UNKNOWN_ERROR];    }    throw new Error(message);  }   /**   * Pushes the specified amount of characters back into the input stream.   *   * They will be read again by then next call of the scanning method   *   * @param number  the number of characters to be read again.   *                This number must not be greater than yylength()!   */  private void yypushback(int number)  {    if ( number > yylength() )      yy_ScanError(YY_PUSHBACK_2BIG);    yy_markedPos -= number;  }  /**   * Contains user EOF-code, which will be executed exactly once,   * when the end of file is reached   */  private void yy_do_eof() throws java.io.IOException {    if (!yy_eof_done) {      yy_eof_done = true;      yyclose();    }  }  /**   * Resumes scanning until the next regular expression is matched,   * the end of input is encountered or an I/O-Error occurs.   *   * @return      the next token   * @exception   IOException  if any I/O-Error occurs   */  public java_cup.runtime.Symbol next_token() throws java.io.IOException {    int yy_input;    int yy_action;    // cached fields:    int yy_currentPos_l;    int yy_startRead_l;    int yy_markedPos_l;    int yy_endRead_l = yy_endRead;    char [] yy_buffer_l = yy_buffer;    char [] yycmap_l = yycmap;    int [] yytrans_l = yytrans;    int [] yy_rowMap_l = yy_rowMap;    byte [] yy_attr_l = YY_ATTRIBUTE;    while (true) {      yy_markedPos_l = yy_markedPos;      boolean yy_r = false;      for (yy_currentPos_l = yy_startRead; yy_currentPos_l < yy_markedPos_l;                                                             yy_currentPos_l++) {        switch (yy_buffer_l[yy_currentPos_l]) {        case '\u000B':        case '\u000C':        case '\u0085':        case '\u2028':        case '\u2029':          yyline++;          yycolumn = 0;          yy_r = false;          break;        case '\r':          yyline++;          yycolumn = 0;          yy_r = true;          break;        case '\n':          if (yy_r)            yy_r = false;          else {            yyline++;            yycolumn = 0;          }          break;        default:          yy_r = false;          yycolumn++;        }      }      if (yy_r) {        // peek one character ahead if it is \n (if we have counted one line too much)        boolean yy_peek;        if (yy_markedPos_l < yy_endRead_l)          yy_peek = yy_buffer_l[yy_markedPos_l] == '\n';        else if (yy_atEOF)          yy_peek = false;        else {          boolean eof = yy_refill();          yy_markedPos_l = yy_markedPos;          yy_buffer_l = yy_buffer;          if (eof)             yy_peek = false;          else             yy_peek = yy_buffer_l[yy_markedPos_l] == '\n';        }        if (yy_peek) yyline--;      }      yy_action = -1;      yy_startRead_l = yy_currentPos_l = yy_currentPos =                        yy_startRead = yy_markedPos_l;      yy_state = yy_lexical_state;      yy_forAction: {        while (true) {          if (yy_currentPos_l < yy_endRead_l)            yy_input = yy_buffer_l[yy_currentPos_l++];          else if (yy_atEOF) {            yy_input = YYEOF;            break yy_forAction;          }          else {            // store back cached positions            yy_currentPos  = yy_currentPos_l;            yy_markedPos   = yy_markedPos_l;            boolean eof = yy_refill();            // get translated positions and possibly new buffer            yy_currentPos_l  = yy_currentPos;            yy_markedPos_l   = yy_markedPos;            yy_buffer_l      = yy_buffer;            yy_endRead_l     = yy_endRead;            if (eof) {              yy_input = YYEOF;              break yy_forAction;            }            else {              yy_input = yy_buffer_l[yy_currentPos_l++];            }          }          int yy_next = yytrans_l[ yy_rowMap_l[yy_state] + yycmap_l[yy_input] ];          if (yy_next == -1) break yy_forAction;          yy_state = yy_next;          int yy_attributes = yy_attr_l[yy_state];          if ( (yy_attributes & 1) == 1 ) {            yy_action = yy_state;             yy_markedPos_l = yy_currentPos_l;             if ( (yy_attributes & 8) == 8 ) break yy_forAction;          }        }      }      // store back cached position      yy_markedPos = yy_markedPos_l;      switch (yy_action) {        case 2:         case 3:         case 5:         case 11:           { 		throw new RuntimeException("Illegal character (" +			yytext() + ") in input, at line " + (yyline + 1) +			", character " + (yycolumn + 1));	 }        case 65: break;        case 8:           {  sb.setLength(0); yybegin(STRING);  }        case 66: break;        case 17:           {  sb.append('\\');  }        case 67: break;        case 63:           {  return new Symbol(sym.STARTREFERENCED);  }        case 68: break;        case 9:           {  sb.append(yytext());  }        case 69: break;        case 10:           {  yybegin(YYINITIAL);  return new Symbol(sym.STRING, sb.toString());  }        case 70: break;        case 6:           {  /* do nothing */  }        case 71: break;        case 4:           { 			int val;			try			{				val = Integer.parseInt(yytext());			}			catch (Exception e)			{				if (!yytext().startsWith("-"))					val = Integer.MIN_VALUE;				else					val = Integer.MAX_VALUE;			}			return new Symbol(sym.NUMBER, new Integer(val));		 }        case 72: break;        case 33:           { 				char c = (char)Integer.parseInt(yytext().substring(2), 16);				sb.append(c);			 }        case 73: break;        case 16:           {  sb.append('"');  }        case 74: break;        case 58:           {  return new Symbol(sym.STARTPROBED);  }        case 75: break;        case 57:           {  return new Symbol(sym.STARTROOTS);  }        case 76: break;        case 7:           {  return new Symbol(sym.SEMICOLON);  }        case 77: break;        default:           if (yy_input == YYEOF && yy_startRead == yy_currentPos) {            yy_atEOF = true;            yy_do_eof();              { return new java_cup.runtime.Symbol(sym.EOF); }          }           else {            yy_ScanError(YY_NO_MATCH);          }      }    }  }}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -