01: /*
02: * Copyright Aduna (http://www.aduna-software.com/) (c) 1997-2006.
03: *
04: * Licensed under the Aduna BSD-style license.
05: */
06: package org.openrdf.query.parser.sparql.ast;
07:
08: import java.util.List;
09:
10: public abstract class ASTQuery extends SimpleNode {
11:
12: public ASTQuery(int id) {
13: super (id);
14: }
15:
16: public ASTQuery(SyntaxTreeBuilder p, int id) {
17: super (p, id);
18: }
19:
20: public List<ASTDatasetClause> getDatasetClauseList() {
21: return jjtGetChildren(ASTDatasetClause.class);
22: }
23:
24: public ASTWhereClause getWhereClause() {
25: return jjtGetChild(ASTWhereClause.class);
26: }
27:
28: public ASTOrderClause getOrderClause() {
29: return jjtGetChild(ASTOrderClause.class);
30: }
31:
32: public boolean hasLimit() {
33: return getLimit() != null;
34: }
35:
36: public ASTLimit getLimit() {
37: return jjtGetChild(ASTLimit.class);
38: }
39:
40: public boolean hasOffset() {
41: return getOffset() != null;
42: }
43:
44: public ASTOffset getOffset() {
45: return jjtGetChild(ASTOffset.class);
46: }
47: }
|