Class PrologHandler

java.lang.Object
org.apache.jena.arq.querybuilder.handlers.PrologHandler
All Implemented Interfaces:
Handler

public class PrologHandler extends Object implements Handler
The prolog handler
  • Constructor Details

    • PrologHandler

      public PrologHandler(Query query)
      Constructor.
      Parameters:
      query - The query to handle.
  • Method Details

    • setBase

      public void setBase(IRIx base)
      Set the base for the query. This is the IRI against which relative names will be resolved.
      Parameters:
      base - The base URI.
    • setBase

      public void setBase(String base)
      Set the base for the query. This is the IRI against which relative names will be resolved.
      Parameters:
      base - The string to set the base from.
    • addPrefix

      public void addPrefix(String pfx, String uri)
      Add a prefix to the prefix mapping.
      Parameters:
      pfx - The prefix to add.
      uri - The uri to resolve the prefix to.
    • clearPrefixes

      public void clearPrefixes()
      Clear the prefix mapping.
    • addPrefixes

      public void addPrefixes(Map<String,String> prefixes)
      Add the map of prefixes to the query prefixes.
      Parameters:
      prefixes - The map of prefixes to URIs.
    • getPrefixes

      public PrefixMapping getPrefixes()
    • getExprFactory

      public ExprFactory getExprFactory()
    • addPrefixes

      public void addPrefixes(PrefixMapping prefixes)
      Add prefixes from a prefix mapping.
      Parameters:
      prefixes - THe prefix mapping to add from.
    • addAll

      public void addAll(PrologHandler pfxHandler)
      Add the settings from the prolog handler argument.
      Parameters:
      pfxHandler - The PrologHandler to read from
    • setVars

      public void setVars(Map<Var,Node> values)
      Description copied from interface: Handler
      Set the values for variables managed by the handler implementation. This method is called by the builder to set values handled by this Handler implementation.
      Specified by:
      setVars in interface Handler
      Parameters:
      values - The map of variable to node value.
    • build

      public void build()
      Description copied from interface: Handler
      Called by the build process for this handler to perform any adjustments to the query before the build completes. The adjustments are made after setVars() has been called.
      Specified by:
      build in interface Handler