org.eclipse.rdf4j.queryrender.sparql.experimental

## Class SparqlQueryRenderer

- java.lang.Object
- - org.eclipse.rdf4j.query.algebra.helpers.AbstractQueryModelVisitor<Exception>
  - - org.eclipse.rdf4j.queryrender.BaseTupleExprRenderer
    - - org.eclipse.rdf4j.queryrender.sparql.experimental.SparqlQueryRenderer

- All Implemented Interfaces:
    QueryModelVisitor<Exception>, QueryRenderer

      @Experimental
      public class SparqlQueryRenderer
      extends BaseTupleExprRenderer
      implements QueryRenderer

  An alternative implementation of the SPARQL query renderer (more complete than the default `SPARQLQueryRenderer`)
  Author:
    Andriy Nikolov, Jeen Broekstra, Andreas Schwarte

- - ### Field Summary

    - ### Fields inherited from class org.eclipse.rdf4j.queryrender.BaseTupleExprRenderer

      `mDistinct, mExtensions, mLimit, mOffset, mOrdering, mProjection, mReduced`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `SparqlQueryRenderer()`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `QueryLanguage` | `getLanguage()` Return the language this QueryRenderer will render queries in.
    `String` | `render(ParsedOperation theOperation)`
    `String` | `render(ParsedQuery theQuery)` Render the ParsedQuery as a query string
    `String` | `render(TupleExpr theExpr)` Render the TupleExpr as a query or query fragment depending on what kind of TupleExpr it is
    `String` | `renderValueExpr(ValueExpr theExpr)` Render the given ValueExpr

    - ### Methods inherited from class org.eclipse.rdf4j.queryrender.BaseTupleExprRenderer

      `getExtensions, getLimit, getOffset, getOrdering, getProjection, isDistinct, isReduced, isSelect, isSPOElemList, meet, meet, meet, meet, meet, meet, meet, reset, 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, 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`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### SparqlQueryRenderer

          public SparqlQueryRenderer()

  - ### Method Detail

    - #### getLanguage

          public QueryLanguage getLanguage()

      Description copied from interface: `QueryRenderer`
      Return the language this QueryRenderer will render queries in.
      Specified by:
        `getLanguage` in interface `QueryRenderer`
      Returns:
        the query language

    - #### render

          public String render(ParsedQuery theQuery)
                        throws Exception

      Description copied from class: `BaseTupleExprRenderer`
      Render the ParsedQuery as a query string
      Specified by:
        `render` in interface `QueryRenderer`
      Overrides:
        `render` in class `BaseTupleExprRenderer`
      Parameters:
        `theQuery` - the parsed query to render
      Returns:
        the query object rendered in the serql syntax
      Throws:
        `Exception` - if there is an error while rendering

    - #### render

          public String render(ParsedOperation theOperation)
                        throws Exception

      Throws:
        `Exception`

    - #### render

          public String render(TupleExpr theExpr)
                        throws Exception

      Description copied from class: `BaseTupleExprRenderer`
      Render the TupleExpr as a query or query fragment depending on what kind of TupleExpr it is
      Specified by:
        `render` in class `BaseTupleExprRenderer`
      Parameters:
        `theExpr` - the expression to render
      Returns:
        the TupleExpr rendered in the serql syntax
      Throws:
        `Exception` - if there is an error while rendering

    - #### renderValueExpr

          public String renderValueExpr(ValueExpr theExpr)
                                 throws Exception

      Description copied from class: `BaseTupleExprRenderer`
      Render the given ValueExpr
      Specified by:
        `renderValueExpr` in class `BaseTupleExprRenderer`
      Parameters:
        `theExpr` - the expr to render
      Returns:
        the rendered expression
      Throws:
        `Exception` - if there is an error while rendering

Copyright © 2015-2021 Eclipse Foundation. All Rights Reserved.