org.jboss.ejb.plugins.cmp.ejbql
Class AggregateFunction

java.lang.Object
  extended byorg.jboss.ejb.plugins.cmp.ejbql.SimpleNode (src) 
      extended byorg.jboss.ejb.plugins.cmp.ejbql.AggregateFunction
All Implemented Interfaces:
SelectFunction (src)
Direct Known Subclasses:
ASTAvg (src) , ASTCount (src) , ASTMax (src) , ASTMin (src) , ASTSum (src)

public abstract class AggregateFunction
extends SimpleNode (src)
implements SelectFunction (src)


Field Summary
 java.lang.String distinct
           
 
Fields inherited from class org.jboss.ejb.plugins.cmp.ejbql.SimpleNode (src)
children, id, parent
 
Constructor Summary
AggregateFunction(int i)
           
 
Method Summary
protected  java.lang.Class getDefaultResultType()
           
 java.lang.Object readResult(java.sql.ResultSet rs)
          Reads results.
 void setResultType(java.lang.Class type)
           
 
Methods inherited from class org.jboss.ejb.plugins.cmp.ejbql.SimpleNode (src)
dump, jjtAccept, jjtAddChild, jjtClose, jjtGetChild, jjtGetNumChildren, jjtGetParent, jjtOpen, jjtSetParent, toString, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

distinct

public java.lang.String distinct
Constructor Detail

AggregateFunction

public AggregateFunction(int i)
Method Detail

setResultType

public void setResultType(java.lang.Class type)

getDefaultResultType

protected java.lang.Class getDefaultResultType()

readResult

public java.lang.Object readResult(java.sql.ResultSet rs)
                            throws java.sql.SQLException
Description copied from interface: SelectFunction (src)
Reads results.

Specified by:
readResult in interface SelectFunction (src)
Parameters:
rs - the result set to read from.
Returns:
the result of the function
Throws:
java.sql.SQLException