1 28 package org.jruby.lexer.yacc; 29 30 31 public class Token implements ISourcePositionHolder { 32 ISourcePosition position = null; 33 Object value; 34 35 public Token(Object value, ISourcePosition position) { 36 this.value = value; 37 this.position = position; 38 } 39 40 public void setValue(Object value) { 41 this.value = value; 42 } 43 44 public Object getValue() { 45 return value; 46 } 47 48 public ISourcePosition getPosition() { 49 return position; 50 } 51 52 public void setPosition(ISourcePosition position) { 53 this.position = position; 54 } 55 56 public String toString() { 57 return "Token { Value=" + value + ", Position=" + position + "}"; 58 } 59 } 60 | Popular Tags |