Package org.eclipse.rdf4j.spin
Class SpinParser.SpinVisitor
- java.lang.Object
-
- org.eclipse.rdf4j.spin.SpinParser.SpinVisitor
-
- Enclosing class:
- SpinParser
private class SpinParser.SpinVisitor extends java.lang.Object
-
-
Field Summary
Fields Modifier and Type Field Description (package private) java.util.Collection<AggregateOperator>
aggregates
(package private) Group
group
(package private) Var
namedGraph
(package private) java.util.Map<java.lang.String,ProjectionElem>
projElems
(package private) TripleSource
store
(package private) TupleExpr
tupleNode
(package private) TupleExpr
tupleRoot
(package private) UpdateExpr
updateRoot
(package private) java.util.Map<Resource,java.lang.String>
vars
-
Constructor Summary
Constructors Constructor Description SpinVisitor(TripleSource store)
-
Method Summary
-
-
-
Field Detail
-
store
final TripleSource store
-
tupleRoot
TupleExpr tupleRoot
-
tupleNode
TupleExpr tupleNode
-
updateRoot
UpdateExpr updateRoot
-
namedGraph
Var namedGraph
-
projElems
java.util.Map<java.lang.String,ProjectionElem> projElems
-
group
Group group
-
vars
java.util.Map<Resource,java.lang.String> vars
-
aggregates
java.util.Collection<AggregateOperator> aggregates
-
-
Constructor Detail
-
SpinVisitor
SpinVisitor(TripleSource store)
-
-
Method Detail
-
getTupleExpr
public TupleExpr getTupleExpr()
-
getUpdateExpr
public UpdateExpr getUpdateExpr()
-
visitConstruct
public void visitConstruct(Resource construct) throws RDF4JException
- Throws:
RDF4JException
-
visitDescribe
public void visitDescribe(Resource describe) throws RDF4JException
- Throws:
RDF4JException
-
visitSelect
public void visitSelect(Resource select) throws RDF4JException
- Throws:
RDF4JException
-
visitAsk
public void visitAsk(Resource ask) throws RDF4JException
- Throws:
RDF4JException
-
addSourceExpressions
private void addSourceExpressions(UnaryTupleOperator op, java.util.Collection<ProjectionElem> elems)
-
visitTemplates
private UnaryTupleOperator visitTemplates(Resource templates) throws RDF4JException
- Throws:
RDF4JException
-
visitTemplate
private ProjectionElemList visitTemplate(Resource r) throws RDF4JException
- Throws:
RDF4JException
-
visitResultNodes
private Projection visitResultNodes(Resource resultNodes) throws RDF4JException
- Throws:
RDF4JException
-
visitResultNode
private ProjectionElem visitResultNode(Resource r) throws RDF4JException
- Throws:
RDF4JException
-
visitResultVariables
private Projection visitResultVariables(Resource resultVars, java.util.Map<java.lang.String,ProjectionElem> previousProjElems) throws RDF4JException
- Throws:
RDF4JException
-
visitResultVariable
private ProjectionElem visitResultVariable(Resource r, java.util.Map<java.lang.String,ProjectionElem> previousProjElems) throws RDF4JException
- Throws:
RDF4JException
-
visitGroupBy
private void visitGroupBy(Resource groupby) throws RDF4JException
- Throws:
RDF4JException
-
visitHaving
private TupleExpr visitHaving(Resource having) throws RDF4JException
- Throws:
RDF4JException
-
visitOrderBy
private Order visitOrderBy(Resource orderby) throws RDF4JException
- Throws:
RDF4JException
-
visitOrderByCondition
private OrderElem visitOrderByCondition(Resource r) throws RDF4JException
- Throws:
RDF4JException
-
createProjectionElem
private ProjectionElem createProjectionElem(Value v, java.lang.String projName, java.util.Map<java.lang.String,ProjectionElem> previousProjElems) throws RDF4JException
- Throws:
RDF4JException
-
visitModify
public void visitModify(Resource query) throws RDF4JException
- Throws:
RDF4JException
-
visitDeleteWhere
public void visitDeleteWhere(Resource query) throws RDF4JException
- Throws:
RDF4JException
-
visitInsertData
public void visitInsertData(Resource query) throws RDF4JException
- Throws:
RDF4JException
-
visitDeleteData
public void visitDeleteData(Resource query) throws RDF4JException
- Throws:
RDF4JException
-
visitLoad
public void visitLoad(Resource query) throws RDF4JException
- Throws:
RDF4JException
-
visitClear
public void visitClear(Resource query) throws RDF4JException
- Throws:
RDF4JException
-
visitCreate
public void visitCreate(Resource query) throws RDF4JException
- Throws:
RDF4JException
-
visitWhere
public TupleExpr visitWhere(Resource query) throws RDF4JException
- Throws:
RDF4JException
-
visitGroupGraphPattern
public TupleExpr visitGroupGraphPattern(Resource group) throws RDF4JException
- Throws:
RDF4JException
-
visitInsert
private void visitInsert(Resource insert) throws RDF4JException
- Throws:
RDF4JException
-
visitDelete
private void visitDelete(Resource delete) throws RDF4JException
- Throws:
RDF4JException
-
visitPattern
private void visitPattern(Resource r, java.util.Set<IRI> types, TupleExpr currentGroupExpr) throws RDF4JException
- Throws:
RDF4JException
-
visitFilter
private void visitFilter(Resource r) throws RDF4JException
- Throws:
RDF4JException
-
visitBind
private void visitBind(Resource r) throws RDF4JException
- Throws:
RDF4JException
-
visitExpression
private ValueExpr visitExpression(Value v) throws RDF4JException
- Throws:
RDF4JException
-
toValueExpr
private ValueExpr toValueExpr(Resource r, IRI func) throws RDF4JException
- Throws:
RDF4JException
-
toCompareOp
private Compare.CompareOp toCompareOp(IRI func)
-
toMathOp
private MathExpr.MathOp toMathOp(IRI func)
-
getArgs
private java.util.List<ValueExpr> getArgs(Resource r, IRI func, IRI... knownArgs) throws RDF4JException
- Parameters:
knownArgs
- empty for vararg, null for unknown.- Throws:
RDF4JException
-
getVarName
private java.lang.String getVarName(Resource r) throws RDF4JException
- Throws:
RDF4JException
-
getVar
private Var getVar(Value v) throws RDF4JException
- Throws:
RDF4JException
-
createVar
private Var createVar(java.lang.String varName)
-
-