1
// $Id: AggregateNode.java 7460 2005-07-12 20:27:29Z steveebersole $
2
package org.hibernate.hql.ast.tree;
4
import org.hibernate.hql.ast.util.ColumnHelper;
5
import org.hibernate.type.Type;
7
import antlr.SemanticException;
10
* Represents an aggregate function i.e. min, max, sum, avg.
12
* @author josh Sep 21, 2004 9:22:02 PM
14
public class AggregateNode extends AbstractSelectExpression implements SelectExpression {
16
public AggregateNode() {
19
public Type getDataType() {
20
// Get the function return value type, based on the type of the first argument.
21
return getSessionFactoryHelper().findFunctionReturnType( getText(), getFirstChild() );
24
public void setScalarColumnText(int i) throws SemanticException {
25
ColumnHelper.generateSingleScalarColumn( this, i );