com.hp.hpl.jena.sparql.util
Class QueryExecUtils

java.lang.Object
  extended by com.hp.hpl.jena.sparql.util.QueryExecUtils

public class QueryExecUtils
extends Object

Some utilities for query processing.


Constructor Summary
QueryExecUtils()
           
 
Method Summary
static void executeAlgebra(Op op, DatasetGraph dsg, ResultsFormat outputFormat)
           
static void executeQuery(Query query, QueryExecution queryExecution)
           
static void executeQuery(Query query, QueryExecution queryExecution, ResultsFormat outputFormat)
           
static com.hp.hpl.jena.rdf.model.RDFNode getExactlyOne(QueryExecution qExec, String varname)
          Execute, expecting the result to be one row, one column.
static com.hp.hpl.jena.rdf.model.RDFNode getExactlyOne(String qs, Dataset ds)
          Execute a query, expecting the result to be one row, one column.
static com.hp.hpl.jena.rdf.model.RDFNode getExactlyOne(String qs, com.hp.hpl.jena.rdf.model.Model model)
          Execute a query, expecting the result to be one row, one column.
static com.hp.hpl.jena.rdf.model.RDFNode getOne(QueryExecution qExec, String varname)
          Execute, expecting the result to be one row, one column.
static void outputResultSet(ResultSet results, Prologue prologue, ResultsFormat outputFormat)
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

QueryExecUtils

public QueryExecUtils()
Method Detail

executeQuery

public static void executeQuery(Query query,
                                QueryExecution queryExecution)

executeQuery

public static void executeQuery(Query query,
                                QueryExecution queryExecution,
                                ResultsFormat outputFormat)

executeAlgebra

public static void executeAlgebra(Op op,
                                  DatasetGraph dsg,
                                  ResultsFormat outputFormat)

outputResultSet

public static void outputResultSet(ResultSet results,
                                   Prologue prologue,
                                   ResultsFormat outputFormat)

getExactlyOne

public static com.hp.hpl.jena.rdf.model.RDFNode getExactlyOne(String qs,
                                                              com.hp.hpl.jena.rdf.model.Model model)
Execute a query, expecting the result to be one row, one column. Return that one RDFNode


getExactlyOne

public static com.hp.hpl.jena.rdf.model.RDFNode getExactlyOne(String qs,
                                                              Dataset ds)
Execute a query, expecting the result to be one row, one column. Return that one RDFNode


getExactlyOne

public static com.hp.hpl.jena.rdf.model.RDFNode getExactlyOne(QueryExecution qExec,
                                                              String varname)
Execute, expecting the result to be one row, one column. Return that one RDFNode or throw an exception


getOne

public static com.hp.hpl.jena.rdf.model.RDFNode getOne(QueryExecution qExec,
                                                       String varname)
Execute, expecting the result to be one row, one column. Return that one RDFNode or null Throw excpetion if more than one.



Copyright ? 2004, 2005, 2006, 2007, 2008, 2009 Hewlett-Packard Development Company, LP Copyright ? 2010 Talis Systems Ltd. Copyright ? 2010 Epimorphics Ltd.