private Token word(CharSequence value) { return new Token(Type.WORD, value, line, column); }
public Token subSequence(int start, int end) { int line = this.line; int col = this.column; for (int i = this.start; i < this.start + start; i++) { if (ch[i] == '\n') { line++; col = 0; } else { col++; } } return new Token(this.ch, this.start + start, end - start, line, col); }
public Token subSequence(int start, int end) { int line = this.line; int col = this.column; for (int i = this.start; i < this.start + start; i++) { if (ch[i] == '\n') { line++; col = 0; } else { col++; } } return new Token(this.ch, this.start + start, end - start, line, col); }
public BaseTokenizer(CharSequence text) { this.text = text instanceof Token ? (Token) text : new Token(text); getch(); }
public BaseTokenizer(CharSequence text) { this.text = text instanceof Token ? (Token) text : new Token(text); getch(); }
public Object expand(CharSequence word, short line, short column) throws Exception { return expand(new Token(Type.WORD, word, line, column), evaluate, inQuote); }
val = evaluate.eval(new Token(Type.EXECUTION, group(), sLine, sCol)); getch();
token = new Token(type, value, tLine, tColumn);