es.uned.compiler.lexical
Class TokenBase

java.lang.Object
  extended by java_cup.runtime.Symbol
      extended by es.uned.compiler.lexical.TokenBase
All Implemented Interfaces:
TokenIF
Direct Known Subclasses:
Token

public abstract class TokenBase
extends java_cup.runtime.Symbol
implements TokenIF


Field Summary
 
Fields inherited from class java_cup.runtime.Symbol
left, parse_state, right, sym, value
 
Constructor Summary
TokenBase()
          Constructor for TokenBase.
TokenBase(int id)
          Constructor for TokenBase.
 
Method Summary
 boolean equals(java.lang.Object other)
          Compares this object with another one.
 int hashCode()
          Returns a hash code for the object.
 java.lang.String toString()
          Return a string representing the object.
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface es.uned.compiler.lexical.TokenIF
getColumn, getId, getLexema, getLine, setColumn, setId, setLexema, setLine
 

Constructor Detail

TokenBase

public TokenBase()
Constructor for TokenBase.


TokenBase

public TokenBase(int id)
Constructor for TokenBase.

Parameters:
id - The token id.
Method Detail

equals

public final boolean equals(java.lang.Object other)
Compares this object with another one.

Overrides:
equals in class java.lang.Object
Parameters:
other - the other object.
Returns:
true if two objects has the same properties.

hashCode

public final int hashCode()
Returns a hash code for the object.

Overrides:
hashCode in class java.lang.Object

toString

public final java.lang.String toString()
Return a string representing the object.

Overrides:
toString in class java_cup.runtime.Symbol
Returns:
a string representing the object.