org.hibernate.sql.ast.common
Class HibernateToken

java.lang.Object
  extended by org.antlr.runtime.CommonToken
      extended by org.hibernate.sql.ast.common.HibernateToken
All Implemented Interfaces:
Serializable, org.antlr.runtime.Token

public class HibernateToken
extends org.antlr.runtime.CommonToken

Models the token-type/text portion of an Antlr tree for a specific node in said tree.

Author:
Steve Ebersole, Alexandre Porcelli
See Also:
Serialized Form

Field Summary
 
Fields inherited from class org.antlr.runtime.CommonToken
channel, charPositionInLine, index, input, line, start, stop, text, type
 
Fields inherited from interface org.antlr.runtime.Token
DEFAULT_CHANNEL, DOWN, EOF, EOF_TOKEN, EOR_TOKEN_TYPE, HIDDEN_CHANNEL, INVALID_TOKEN, INVALID_TOKEN_TYPE, MIN_TOKEN_TYPE, SKIP_TOKEN, UP
 
Constructor Summary
HibernateToken(org.antlr.runtime.CharStream input, int type, int channel, int start, int stop)
           
HibernateToken(int type)
           
HibernateToken(int type, String text)
           
HibernateToken(org.antlr.runtime.Token oldToken)
          Constructor that preserves the char offset
HibernateToken(org.antlr.runtime.Token oldToken, int type, String text)
          Constructor form used to track origination position information via the passed 'oldToken' param, but to utilize a new token type and text.
 
Method Summary
 
Methods inherited from class org.antlr.runtime.CommonToken
getChannel, getCharPositionInLine, getInputStream, getLine, getStartIndex, getStopIndex, getText, getTokenIndex, getType, setChannel, setCharPositionInLine, setInputStream, setLine, setStartIndex, setStopIndex, setText, setTokenIndex, setType, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

HibernateToken

public HibernateToken(int type)

HibernateToken

public HibernateToken(org.antlr.runtime.CharStream input,
                      int type,
                      int channel,
                      int start,
                      int stop)

HibernateToken

public HibernateToken(int type,
                      String text)

HibernateToken

public HibernateToken(org.antlr.runtime.Token oldToken)
Constructor that preserves the char offset

Parameters:
oldToken - A token to use to template the creation of this new one.

HibernateToken

public HibernateToken(org.antlr.runtime.Token oldToken,
                      int type,
                      String text)
Constructor form used to track origination position information via the passed 'oldToken' param, but to utilize a new token type and text.

Parameters:
oldToken - The original token type (used for position tracking info).
type - The type of the new (this) token
text - The test of the new (this) token.


Copyright © 2012 Hibernate. All Rights Reserved.