Class Identifier

  • All Implemented Interfaces:
    Token

    public class Identifier
    extends java.lang.Object
    implements Token
    Class to capture reserved words.
    Version:
    $Revision$
    Author:
    Jens Voeckler, Karan Vahi, Gaurang Mehta
    • Field Summary

      Fields 
      Modifier and Type Field Description
      private java.lang.String m_value
      This instance variable captures the token value for the reserved word.
    • Constructor Summary

      Constructors 
      Constructor Description
      Identifier​(java.lang.String tokenValue)
      Initializes an instance of an identifier.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.lang.String getValue()
      Obtains the token value of a given reserved word token.
      java.lang.String toString()
      Returns the textual description of the object.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
    • Field Detail

      • m_value

        private java.lang.String m_value
        This instance variable captures the token value for the reserved word.
    • Constructor Detail

      • Identifier

        public Identifier​(java.lang.String tokenValue)
        Initializes an instance of an identifier.
        Parameters:
        tokenValue - is the identifier to remember.
    • Method Detail

      • getValue

        public java.lang.String getValue()
        Obtains the token value of a given reserved word token.
        Returns:
        the token value.
      • toString

        public java.lang.String toString()
        Returns the textual description of the object.
        Overrides:
        toString in class java.lang.Object
        Returns:
        the description as String.