com.croftsoft.core.util.jlex
Class Token

java.lang.Object
  extended by com.croftsoft.core.util.jlex.Token

public class Token
extends Object

Token data class for use with JLex. Reference:

"JLex: A Lexical Analyzer Generator for Java"
http://www.cs.princeton.edu/~appel/modern/java/JLex/

Since:
1999-02-10
Version:
$Id: Token.java,v 1.3 2008/09/20 05:51:55 croft Exp $
Author:
David Wallace Croft

Field Summary
 int charBegin
          Defaults to -1.
 int charEnd
          Defaults to -1.
 int id
          The token type identifier number.
 int line
          Defaults to -1.
 String text
           
 
Constructor Summary
Token(int id)
           
Token(int id, String text)
           
Token(int id, String text, int line, int charBegin, int charEnd)
           
 
Method Summary
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

id

public int id
The token type identifier number.


text

public String text

line

public int line
Defaults to -1.


charBegin

public int charBegin
Defaults to -1.


charEnd

public int charEnd
Defaults to -1.

Constructor Detail

Token

public Token(int id,
             String text,
             int line,
             int charBegin,
             int charEnd)

Token

public Token(int id,
             String text)

Token

public Token(int id)
Method Detail

toString

public String toString()
Overrides:
toString in class Object

CroftSoft Javadoc

CroftSoft Core Javadoc (2008-09-28 20:58:02)