Class PlanFactory


  • public class PlanFactory
    extends java.lang.Object
    A factory that creates a RootPlan from a query. Then the RootPlan may be used to execute the query.

    A SPARQLExtQuery may be created from a string as follows:

    
     String query;
     SPARQLExtQuery query;
    
     Syntax syntax = SPARQLExt.SYNTAX;
     query = (SPARQLExtQuery) QueryFactory.create(query, syntax);
     
    Author:
    Maxime Lefrançois
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static RootPlan create​(SPARQLExtQuery query)
      A factory that creates a RootPlan from a query.
      static RootPlan create​(java.lang.String queryStr)
      A factory that creates a RootPlan from a SPARQL-Generate or SPARQL-Template query.
      static RootPlan create​(java.lang.String queryStr, java.lang.String base)
      A factory that creates a RootPlan from a query.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Method Detail

      • create

        public static final RootPlan create​(SPARQLExtQuery query)
        A factory that creates a RootPlan from a query.

        A SPARQLExtQuery may be created from a string as follows:

        
         String query;
         SPARQLExtQuery query;
        
         Syntax syntax = SPARQLExt.syntaxSPARQLGenerate;
         query = (SPARQLExtQuery) QueryFactory.create(query, syntax);
         
        Parameters:
        query - the Query.
        Returns:
        the RootPlan that may be used to execute the query.
      • create

        public static final RootPlan create​(java.lang.String queryStr)
        A factory that creates a RootPlan from a SPARQL-Generate or SPARQL-Template query.
        Parameters:
        queryStr - the string representation of the SPARQL-Generate or SPARQL-Template Query.
        Returns:
        the RootPlan that may be used to execute the SPARQL-Generate or SPARQL-Template Query. query.
      • create

        public static final RootPlan create​(java.lang.String queryStr,
                                            java.lang.String base)
        A factory that creates a RootPlan from a query.
        Parameters:
        queryStr - the string representation of the SPARQL-Generate or SPARQL-Template Query.
        base - the base URI, if not set explicitly in the query string
        Returns:
        the RootPlan that may be used to execute the query.