marf.nlp.Parsing
Class Token

java.lang.Object
  extended by marf.nlp.Parsing.Token
All Implemented Interfaces:
java.io.Serializable

public class Token
extends java.lang.Object
implements java.io.Serializable

This class denotes a Token data structure. $Id: Token.java,v 1.9 2005/06/16 19:58:57 mokhov Exp $

Since:
0.3.0
Version:
$Revision: 1.9 $
Author:
Serguei Mokhov
See Also:
Serialized Form

Field Summary
protected  java.lang.String Lexeme
          Parts of a Token.
protected  TokenSubType oTokenType
           
protected  java.awt.Point Position
           
 
Constructor Summary
Token(java.lang.String pstrLexeme, java.awt.Point poPosition, TokenSubType poTokenType)
          Constructor.
Token(Token poToken)
          Simulation of a copy-constructor.
 
Method Summary
 java.lang.String getLexeme()
          Access method for the Lexeme property.
static java.lang.String getMARFSourceCodeRevision()
          Retrieves class' revision.
 java.awt.Point getPosition()
          Access method for the Position property.
 TokenSubType getTokenType()
          Access method for the TokenType property.
 boolean serialize(int piOperation, java.io.FileWriter poFileWriter)
          Loads/Saves the token to a text file.
 void setLexeme(java.lang.String pstrLexeme)
          Sets the value of the Lexeme property.
 void setPosition(java.awt.Point aPosition)
          Sets the value of the Position property.
 void setTokenType(TokenSubType aTokenType)
          Sets the value of the TokenType property.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

Lexeme

protected java.lang.String Lexeme
Parts of a Token.


Position

protected java.awt.Point Position

oTokenType

protected TokenSubType oTokenType
Constructor Detail

Token

public Token(java.lang.String pstrLexeme,
             java.awt.Point poPosition,
             TokenSubType poTokenType)
Constructor.


Token

public Token(Token poToken)
Simulation of a copy-constructor.

Method Detail

serialize

public boolean serialize(int piOperation,
                         java.io.FileWriter poFileWriter)
Loads/Saves the token to a text file.


getLexeme

public java.lang.String getLexeme()
Access method for the Lexeme property.

Returns:
the current value of the Lexeme property

setLexeme

public void setLexeme(java.lang.String pstrLexeme)
Sets the value of the Lexeme property.

Parameters:
pstrLexeme - the new value of the Lexeme property

getPosition

public java.awt.Point getPosition()
Access method for the Position property.

Returns:
the current value of the Position property

setPosition

public void setPosition(java.awt.Point aPosition)
Sets the value of the Position property.

Parameters:
aPosition - the new value of the Position property

getTokenType

public TokenSubType getTokenType()
Access method for the TokenType property.

Returns:
the current value of the TokenType property

setTokenType

public void setTokenType(TokenSubType aTokenType)
Sets the value of the TokenType property.

Parameters:
aTokenType - the new value of the TokenType property

getMARFSourceCodeRevision

public static java.lang.String getMARFSourceCodeRevision()
Retrieves class' revision.

Returns:
revision string