Class SparqlView

java.lang.Object
org.aksw.jena_sparql_api.views.SparqlView
All Implemented Interfaces:
IViewDef

public class SparqlView extends Object implements IViewDef
An SparqlView definition. Essentially a SPARQL construct query with constraints
Author:
raven
  • Constructor Details

    • SparqlView

      public SparqlView(String name, org.apache.jena.sparql.core.QuadPattern template, org.apache.jena.sparql.expr.ExprList constraints, VarDefinition varDefinition, org.apache.jena.sparql.algebra.Op op)
  • Method Details

    • getRestrictions

      public RestrictionManagerImpl getRestrictions()
    • setRestrictions

      public void setRestrictions(RestrictionManagerImpl restrictions)
    • getVarsMentioned

      public Set<org.apache.jena.sparql.core.Var> getVarsMentioned()
      Specified by:
      getVarsMentioned in interface IViewDef
    • getName

      public String getName()
      Specified by:
      getName in interface IViewDef
    • create

      public static SparqlView create(String name, String viewDefStr)
      Constructs a view definition syntax: [From graph] { ?s ?p ?o . Filter(?o = ...) . } with ?s = expr; ?p = ; select ...; Currently this is just some string hack
      Parameters:
      pattern -
    • create

      public static SparqlView create(String name, org.apache.jena.sparql.core.QuadPattern quadPattern, org.apache.jena.sparql.syntax.Element element)
    • create

      public static SparqlView create(String name, org.apache.jena.sparql.core.QuadPattern quadPattern, org.apache.jena.sparql.algebra.Op op)
    • create

      public static SparqlView create(String name, org.apache.jena.query.Query query)
    • create

      public static SparqlView create(String name, org.apache.jena.sparql.core.QuadPattern template, org.apache.jena.sparql.expr.ExprList filters, List<org.apache.jena.sparql.expr.Expr> bindings, List<Constraint> rawConstraints, org.apache.jena.sparql.algebra.Op op)
      Meh.... Didn't notice that template does not have support for graphs. Therefore need to change that...
      Parameters:
      template -
      filters -
      bindings -
      relation -
      Returns:
    • getQuadPattern

      @Deprecated public org.apache.jena.sparql.core.QuadPattern getQuadPattern()
      Deprecated.
    • getBinding

      @Deprecated public Map<org.apache.jena.graph.Node,org.apache.jena.sparql.expr.Expr> getBinding()
      Deprecated.
    • getOp

      public org.apache.jena.sparql.algebra.Op getOp()
    • getConstraints

      public org.apache.jena.sparql.expr.ExprList getConstraints()
    • toString

      public String toString()
      Overrides:
      toString in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • equals

      public boolean equals(Object obj)
      Overrides:
      equals in class Object
    • getTemplate

      public org.apache.jena.sparql.core.QuadPattern getTemplate()
      Specified by:
      getTemplate in interface IViewDef
    • getVarRestrictions

      public RestrictionManagerImpl getVarRestrictions()
      Specified by:
      getVarRestrictions in interface IViewDef
    • getVarDefinition

      public VarDefinition getVarDefinition()
      Specified by:
      getVarDefinition in interface IViewDef
    • copySubstitute

      @Deprecated public SparqlView copySubstitute(Map<org.apache.jena.graph.Node,org.apache.jena.graph.Node> renamer)
      Deprecated.
    • copyRenameVars

      public SparqlView copyRenameVars(Map<org.apache.jena.sparql.core.Var,org.apache.jena.sparql.core.Var> oldToNew)
      Specified by:
      copyRenameVars in interface IViewDef