KickJava   Java API By Example, From Geeks To Geeks.

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


1 // $Id: DeleteStatement.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.antlr.SqlTokenTypes;
6
7 import org.apache.commons.logging.Log;
8 import org.apache.commons.logging.LogFactory;
9
10 /**
11  * Defines a top-level AST node representing an HQL delete statement.
12  *
13  * @author Steve Ebersole
14  */

15 public class DeleteStatement extends AbstractRestrictableStatement {
16
17     private static final Log log = LogFactory.getLog( DeleteStatement.class );
18
19     /**
20      * @see org.hibernate.hql.ast.tree.Statement#getStatementType()
21      */

22     public int getStatementType() {
23         return HqlSqlTokenTypes.DELETE;
24     }
25
26     /**
27      * @see org.hibernate.hql.ast.tree.Statement#needsExecutor()
28      */

29     public boolean needsExecutor() {
30         return true;
31     }
32
33     protected int getWhereClauseParentTokenType() {
34         return SqlTokenTypes.FROM;
35     }
36
37     protected Log getLog() {
38         return log;
39     }
40 }
41
Popular Tags