Class SparqlTupleExprRenderer
- java.lang.Object
-
- org.eclipse.rdf4j.query.algebra.helpers.AbstractQueryModelVisitor<Exception>
-
- org.eclipse.rdf4j.queryrender.BaseTupleExprRenderer
-
- org.eclipse.rdf4j.queryrender.sparql.SparqlTupleExprRenderer
-
- All Implemented Interfaces:
QueryModelVisitor<Exception>
public final class SparqlTupleExprRenderer extends BaseTupleExprRenderer
Extends the BaseTupleExprRenderer to provide support for rendering tuple expressions as SPARQL queries.
- Author:
- Michael Grove
-
-
Field Summary
-
Fields inherited from class org.eclipse.rdf4j.queryrender.BaseTupleExprRenderer
mDistinct, mExtensions, mLimit, mOffset, mOrdering, mProjection, mReduced
-
-
Constructor Summary
Constructors Constructor Description SparqlTupleExprRenderer()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidmeet(And node)voidmeet(ArbitraryLengthPath node)voidmeet(Bound node)voidmeet(Compare node)voidmeet(Datatype node)voidmeet(Difference theOp)voidmeet(Extension node)voidmeet(ExtensionElem node)voidmeet(Filter theFilter)voidmeet(FunctionCall node)voidmeet(If theOp)voidmeet(In node)voidmeet(Intersection theOp)voidmeet(IRIFunction node)voidmeet(IsBNode node)voidmeet(IsLiteral node)voidmeet(IsNumeric node)voidmeet(IsURI node)voidmeet(Join theJoin)voidmeet(Lang node)voidmeet(LangMatches node)voidmeet(LeftJoin theJoin)voidmeet(Or node)voidmeet(Regex node)voidmeet(SameTerm node)voidmeet(StatementPattern thePattern)voidmeet(Str node)voidmeet(Union theOp)voidmeet(ValueConstant node)voidmeet(Var node)Stringrender(TupleExpr theExpr)Render the TupleExpr as a query or query fragment depending on what kind of TupleExpr it isprotected StringrenderValueExpr(ValueExpr theExpr)Render the given ValueExprvoidreset()Reset the state of the renderer-
Methods inherited from class org.eclipse.rdf4j.queryrender.BaseTupleExprRenderer
getExtensions, getLimit, getOffset, getOrdering, getProjection, isDistinct, isReduced, isSelect, isSPOElemList, meet, meet, meet, meet, meet, render, scrubVarName, toStatementPattern
-
Methods inherited from class org.eclipse.rdf4j.query.algebra.helpers.AbstractQueryModelVisitor
meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meet, meetBinaryTupleOperator, meetBinaryValueOperator, meetCompareSubQueryValueOperator, meetNAryValueOperator, meetNode, meetOther, meetSubQueryValueOperator, meetUnaryTupleOperator, meetUnaryValueOperator, meetUpdateExpr
-
-
-
-
Method Detail
-
reset
public void reset()
Reset the state of the renderer- Overrides:
resetin classBaseTupleExprRenderer
-
render
public String render(TupleExpr theExpr) throws Exception
Render the TupleExpr as a query or query fragment depending on what kind of TupleExpr it is- Specified by:
renderin classBaseTupleExprRenderer- Parameters:
theExpr- the expression to render- Returns:
- the TupleExpr rendered in the query language syntax
- Throws:
Exception- if there is an error while rendering
-
renderValueExpr
protected String renderValueExpr(ValueExpr theExpr) throws Exception
Render the given ValueExpr- Specified by:
renderValueExprin classBaseTupleExprRenderer- Parameters:
theExpr- the expr to render- Returns:
- the rendered expression
- Throws:
Exception- if there is an error while rendering
-
meet
public void meet(Join theJoin) throws Exception
- Specified by:
meetin interfaceQueryModelVisitor<Exception>- Overrides:
meetin classAbstractQueryModelVisitor<Exception>- Throws:
Exception
-
meet
public void meet(LeftJoin theJoin) throws Exception
- Specified by:
meetin interfaceQueryModelVisitor<Exception>- Overrides:
meetin classAbstractQueryModelVisitor<Exception>- Throws:
Exception
-
meet
public void meet(Union theOp) throws Exception
- Specified by:
meetin interfaceQueryModelVisitor<Exception>- Overrides:
meetin classAbstractQueryModelVisitor<Exception>- Throws:
Exception
-
meet
public void meet(Difference theOp) throws Exception
- Specified by:
meetin interfaceQueryModelVisitor<Exception>- Overrides:
meetin classAbstractQueryModelVisitor<Exception>- Throws:
Exception
-
meet
public void meet(Intersection theOp) throws Exception
- Specified by:
meetin interfaceQueryModelVisitor<Exception>- Overrides:
meetin classAbstractQueryModelVisitor<Exception>- Throws:
Exception
-
meet
public void meet(Filter theFilter) throws Exception
- Specified by:
meetin interfaceQueryModelVisitor<Exception>- Overrides:
meetin classAbstractQueryModelVisitor<Exception>- Throws:
Exception
-
meet
public void meet(StatementPattern thePattern) throws Exception
- Specified by:
meetin interfaceQueryModelVisitor<Exception>- Overrides:
meetin classBaseTupleExprRenderer- Throws:
Exception
-
meet
public void meet(Extension node) throws Exception
- Specified by:
meetin interfaceQueryModelVisitor<Exception>- Overrides:
meetin classAbstractQueryModelVisitor<Exception>- Throws:
Exception
-
meet
public void meet(ExtensionElem node) throws Exception
- Specified by:
meetin interfaceQueryModelVisitor<Exception>- Overrides:
meetin classBaseTupleExprRenderer- Throws:
Exception
-
meet
public void meet(FunctionCall node) throws Exception
- Specified by:
meetin interfaceQueryModelVisitor<Exception>- Overrides:
meetin classAbstractQueryModelVisitor<Exception>- Throws:
Exception
-
meet
public void meet(And node) throws Exception
- Specified by:
meetin interfaceQueryModelVisitor<Exception>- Overrides:
meetin classAbstractQueryModelVisitor<Exception>- Throws:
Exception
-
meet
public void meet(Or node) throws Exception
- Specified by:
meetin interfaceQueryModelVisitor<Exception>- Overrides:
meetin classAbstractQueryModelVisitor<Exception>- Throws:
Exception
-
meet
public void meet(Compare node) throws Exception
- Specified by:
meetin interfaceQueryModelVisitor<Exception>- Overrides:
meetin classAbstractQueryModelVisitor<Exception>- Throws:
Exception
-
meet
public void meet(Bound node) throws Exception
- Specified by:
meetin interfaceQueryModelVisitor<Exception>- Overrides:
meetin classAbstractQueryModelVisitor<Exception>- Throws:
Exception
-
meet
public void meet(If theOp) throws Exception
- Specified by:
meetin interfaceQueryModelVisitor<Exception>- Overrides:
meetin classAbstractQueryModelVisitor<Exception>- Throws:
Exception
-
meet
public void meet(In node) throws Exception
- Specified by:
meetin interfaceQueryModelVisitor<Exception>- Overrides:
meetin classAbstractQueryModelVisitor<Exception>- Throws:
Exception
-
meet
public void meet(SameTerm node) throws Exception
- Specified by:
meetin interfaceQueryModelVisitor<Exception>- Overrides:
meetin classAbstractQueryModelVisitor<Exception>- Throws:
Exception
-
meet
public void meet(IsURI node) throws Exception
- Specified by:
meetin interfaceQueryModelVisitor<Exception>- Overrides:
meetin classAbstractQueryModelVisitor<Exception>- Throws:
Exception
-
meet
public void meet(IsBNode node) throws Exception
- Specified by:
meetin interfaceQueryModelVisitor<Exception>- Overrides:
meetin classAbstractQueryModelVisitor<Exception>- Throws:
Exception
-
meet
public void meet(IsLiteral node) throws Exception
- Specified by:
meetin interfaceQueryModelVisitor<Exception>- Overrides:
meetin classAbstractQueryModelVisitor<Exception>- Throws:
Exception
-
meet
public void meet(IsNumeric node) throws Exception
- Specified by:
meetin interfaceQueryModelVisitor<Exception>- Overrides:
meetin classAbstractQueryModelVisitor<Exception>- Throws:
Exception
-
meet
public void meet(Datatype node) throws Exception
- Specified by:
meetin interfaceQueryModelVisitor<Exception>- Overrides:
meetin classAbstractQueryModelVisitor<Exception>- Throws:
Exception
-
meet
public void meet(IRIFunction node) throws Exception
- Specified by:
meetin interfaceQueryModelVisitor<Exception>- Overrides:
meetin classAbstractQueryModelVisitor<Exception>- Throws:
Exception
-
meet
public void meet(Str node) throws Exception
- Specified by:
meetin interfaceQueryModelVisitor<Exception>- Overrides:
meetin classAbstractQueryModelVisitor<Exception>- Throws:
Exception
-
meet
public void meet(Regex node) throws Exception
- Specified by:
meetin interfaceQueryModelVisitor<Exception>- Overrides:
meetin classAbstractQueryModelVisitor<Exception>- Throws:
Exception
-
meet
public void meet(Lang node) throws Exception
- Specified by:
meetin interfaceQueryModelVisitor<Exception>- Overrides:
meetin classAbstractQueryModelVisitor<Exception>- Throws:
Exception
-
meet
public void meet(LangMatches node) throws Exception
- Specified by:
meetin interfaceQueryModelVisitor<Exception>- Overrides:
meetin classAbstractQueryModelVisitor<Exception>- Throws:
Exception
-
meet
public void meet(ArbitraryLengthPath node) throws Exception
- Specified by:
meetin interfaceQueryModelVisitor<Exception>- Overrides:
meetin classAbstractQueryModelVisitor<Exception>- Throws:
Exception
-
meet
public void meet(ValueConstant node) throws Exception
- Specified by:
meetin interfaceQueryModelVisitor<Exception>- Overrides:
meetin classAbstractQueryModelVisitor<Exception>- Throws:
Exception
-
meet
public void meet(Var node) throws Exception
- Specified by:
meetin interfaceQueryModelVisitor<Exception>- Overrides:
meetin classAbstractQueryModelVisitor<Exception>- Throws:
Exception
-
-