KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > hibernate > hql > ast > tree > OrderByClause


1 // $Id: OrderByClause.java,v 1.1 2005/07/12 20:27:16 steveebersole Exp $
2
package org.hibernate.hql.ast.tree;
3
4 import org.hibernate.hql.antlr.HqlSqlTokenTypes;
5 import org.hibernate.hql.ast.util.ASTUtil;
6
7 import antlr.collections.AST;
8
9 /**
10  * Implementation of OrderByClause.
11  *
12  * @author Steve Ebersole
13  */

14 public class OrderByClause extends HqlSqlWalkerNode implements HqlSqlTokenTypes {
15
16     public void addOrderFragment(String JavaDoc orderByFragment) {
17         AST fragment = ASTUtil.create( getASTFactory(), SQL_TOKEN, orderByFragment );
18         if ( getFirstChild() == null ) {
19             setFirstChild( fragment );
20         }
21         else {
22             addChild( fragment );
23         }
24     }
25
26 }
27
Popular Tags