org.hibernate.hql.ast
Class CollectionFunction

java.lang.Object
  extended byantlr.BaseAST
      extended byantlr.CommonAST
          extended byorg.hibernate.hql.ast.SqlNode
              extended byorg.hibernate.hql.ast.HqlSqlWalkerNode
                  extended byorg.hibernate.hql.ast.AbstractSelectExpression
                      extended byorg.hibernate.hql.ast.MethodNode
                          extended byorg.hibernate.hql.ast.CollectionFunction
All Implemented Interfaces:
antlr.collections.AST, DisplayableNode, org.hibernate.hql.ast.InitializeableNode, SelectExpression, Serializable

public class CollectionFunction
extends org.hibernate.hql.ast.MethodNode
implements DisplayableNode

Represents 'elements()' or 'indices()'.

Author:
josh Dec 6, 2004 8:36:42 AM
See Also:
Serialized Form

Field Summary
 
Fields inherited from class antlr.BaseAST
down, right
 
Constructor Summary
CollectionFunction()
           
 
Method Summary
 String getAlias()
           
 org.hibernate.hql.ast.AliasGenerator getAliasGenerator()
           
 antlr.ASTFactory getASTFactory()
           
 Type getDataType()
          Returns the data type of the select expression.
 String getDisplayText()
          Returns additional display text for the AST node.
 FromElement getFromElement()
          Returns the FROM element that this expression refers to.
 org.hibernate.hql.ast.SessionFactoryHelper getSessionFactoryHelper()
           
 SQLFunction getSQLFunction()
           
 HqlSqlWalker getWalker()
           
 void initialize(Object param)
          Initializes the node with the parameter.
 boolean isConstructor()
          Returns true if the element is a constructor (e.g.
 boolean isReturnableEntity()
          Returns true if this select expression represents an entity that can be returned.
 boolean isScalar()
           
protected  void prepareSelectColumns(String[] selectColumns)
           
 void resolve(boolean inSelect)
           
 void setAlias(String alias)
           
 void setScalarColumnText(int i)
          Appends AST nodes that represent the columns after the current AST node.
 void setText(String s)
          Sets the text of the node.
 
Methods inherited from class antlr.CommonAST
getText, getType, initialize, initialize, initialize, setType
 
Methods inherited from class antlr.BaseAST
addChild, decode, encode, equals, equalsList, equalsListPartial, equalsTree, equalsTreePartial, findAll, findAllPartial, getColumn, getFirstChild, getLine, getNextSibling, getNumberOfChildren, getTokenNames, removeChildren, setFirstChild, setNextSibling, setVerboseStringConversion, toString, toStringList, toStringTree, xmlSerialize, xmlSerializeNode, xmlSerializeRootClose, xmlSerializeRootOpen
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface org.hibernate.hql.ast.DisplayableNode
getDisplayText
 
Methods inherited from interface org.hibernate.hql.ast.SelectExpression
getAlias, getDataType, isConstructor, isReturnableEntity, setAlias, setText
 

Constructor Detail

CollectionFunction

public CollectionFunction()
Method Detail

resolve

public void resolve(boolean inSelect)
             throws antlr.SemanticException
Throws:
antlr.SemanticException

prepareSelectColumns

protected void prepareSelectColumns(String[] selectColumns)

getSQLFunction

public SQLFunction getSQLFunction()

isScalar

public boolean isScalar()
                 throws antlr.SemanticException
Specified by:
isScalar in interface SelectExpression
Throws:
antlr.SemanticException

setScalarColumnText

public void setScalarColumnText(int i)
                         throws antlr.SemanticException
Description copied from interface: SelectExpression
Appends AST nodes that represent the columns after the current AST node. (e.g. 'as col0_O_')

Specified by:
setScalarColumnText in interface SelectExpression
Parameters:
i - The index of the select expression in the projection list.
Throws:
antlr.SemanticException

getFromElement

public FromElement getFromElement()
Description copied from interface: SelectExpression
Returns the FROM element that this expression refers to.

Specified by:
getFromElement in interface SelectExpression

getDisplayText

public String getDisplayText()

setAlias

public final void setAlias(String alias)
Specified by:
setAlias in interface SelectExpression

getAlias

public final String getAlias()
Specified by:
getAlias in interface SelectExpression

isConstructor

public boolean isConstructor()
Description copied from interface: SelectExpression
Returns true if the element is a constructor (e.g. new Foo).

Specified by:
isConstructor in interface SelectExpression
Returns:
true if the element is a constructor (e.g. new Foo).

isReturnableEntity

public boolean isReturnableEntity()
                           throws antlr.SemanticException
Description copied from interface: SelectExpression
Returns true if this select expression represents an entity that can be returned.

Specified by:
isReturnableEntity in interface SelectExpression
Returns:
true if this select expression represents an entity that can be returned.
Throws:
antlr.SemanticException

initialize

public void initialize(Object param)
Description copied from interface: org.hibernate.hql.ast.InitializeableNode
Initializes the node with the parameter.

Specified by:
initialize in interface org.hibernate.hql.ast.InitializeableNode
Parameters:
param - the initialization parameter.

getWalker

public HqlSqlWalker getWalker()

getSessionFactoryHelper

public org.hibernate.hql.ast.SessionFactoryHelper getSessionFactoryHelper()

getASTFactory

public antlr.ASTFactory getASTFactory()

getAliasGenerator

public org.hibernate.hql.ast.AliasGenerator getAliasGenerator()

setText

public void setText(String s)

getDataType

public Type getDataType()