ASTPathElt.java

/*******************************************************************************
 * Copyright (c) 2015 Eclipse RDF4J contributors, Aduna, and others.
 *
 * All rights reserved. This program and the accompanying materials
 * are made available under the terms of the Eclipse Distribution License v1.0
 * which accompanies this distribution, and is available at
 * http://www.eclipse.org/org/documents/edl-v10.php.
 *
 * SPDX-License-Identifier: BSD-3-Clause
 *******************************************************************************/

package org.eclipse.rdf4j.query.parser.sparql.ast;

/* Generated By:JJTree: Do not edit this line. ASTPathElt.java Version 4.3 */
/* JavaCCOptions:MULTI=true,NODE_USES_PARSER=false,VISITOR=true,TRACK_TOKENS=false,NODE_PREFIX=AST,NODE_EXTENDS=,NODE_FACTORY=,SUPPORT_CLASS_VISIBILITY_PUBLIC=true */

public class ASTPathElt extends SimpleNode {

	private boolean inverse;

	public ASTPathElt(int id) {
		super(id);
	}

	public ASTPathElt(SyntaxTreeBuilder p, int id) {
		super(p, id);
	}

	/** Accept the visitor. **/
	@Override
	public Object jjtAccept(SyntaxTreeBuilderVisitor visitor, Object data) throws VisitorException {
		return visitor.visit(this, data);
	}

	public void setInverse(boolean inverse) {
		this.inverse = inverse;
	}

	public boolean isInverse() {
		return this.inverse;
	}

	public boolean isNegatedPropertySet() {
		return jjtGetChild(0) instanceof ASTPathOneInPropertySet;
	}

	public boolean isNestedPath() {
		return jjtGetChild(0) instanceof ASTPathAlternative;
	}

	public ASTPathMod getPathMod() {
		return jjtGetChild(ASTPathMod.class);
	}
}
/* JavaCC - OriginalChecksum=775f2a21c17018fa87a23bafe7b048dd (do not edit this line) */