Package org.apache.jena.rdfconnection
Interface SparqlQueryConnection
- All Superinterfaces:
AutoCloseable,org.apache.jena.sparql.core.Transactional
- All Known Subinterfaces:
RDFConnection,RDFConnectionFuseki,RDFConnectionRemote
- All Known Implementing Classes:
RDFConnectionAdapter,RDFConnectionFuseki.RDFConnectionFusekiImpl,RDFConnectionLocal,RDFConnectionWrapper
public interface SparqlQueryConnection
extends org.apache.jena.sparql.core.Transactional, AutoCloseable
SPARQL Query Operations on a connection.
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.apache.jena.sparql.core.Transactional
org.apache.jena.sparql.core.Transactional.Promote -
Method Summary
Modifier and TypeMethodDescriptionvoidclose()Close this connection.org.apache.jena.query.QueryExecutionBuildernewQuery()Return an execution builder initialized with the RDFConnection setup.org.apache.jena.query.QueryExecutionSetup a SPARQL query execution.org.apache.jena.query.QueryExecutionquery(org.apache.jena.query.Query query) Setup a SPARQL query execution.booleanExecute a ASK query and return a booleanbooleanqueryAsk(org.apache.jena.query.Query query) Execute a ASK query and return a booleanorg.apache.jena.rdf.model.ModelqueryConstruct(String query) Execute a CONSTRUCT query and return as a Modelorg.apache.jena.rdf.model.ModelqueryConstruct(org.apache.jena.query.Query query) Execute a CONSTRUCT query and return as a Modelorg.apache.jena.rdf.model.ModelqueryDescribe(String query) Execute a DESCRIBE query and return as a Modelorg.apache.jena.rdf.model.ModelqueryDescribe(org.apache.jena.query.Query query) Execute a DESCRIBE query and return as a ModelvoidqueryResultSet(String query, Consumer<org.apache.jena.query.ResultSet> resultSetAction) Execute a SELECT query and process the ResultSet with the handler code.voidqueryResultSet(org.apache.jena.query.Query query, Consumer<org.apache.jena.query.ResultSet> resultSetAction) Execute a SELECT query and process the ResultSet with the handler code.voidquerySelect(String query, Consumer<org.apache.jena.query.QuerySolution> rowAction) Execute a SELECT query and process the rows of the results with the handler code.voidquerySelect(org.apache.jena.query.Query query, Consumer<org.apache.jena.query.QuerySolution> rowAction) Execute a SELECT query and process the rows of the results with the handler code.Methods inherited from interface org.apache.jena.sparql.core.Transactional
abort, begin, begin, begin, calc, calculate, calculateRead, calculateWrite, commit, end, exec, execute, executeRead, executeWrite, isInTransaction, promote, promote, transactionMode, transactionType
-
Method Details
-
queryResultSet
Execute a SELECT query and process the ResultSet with the handler code.- Parameters:
query-resultSetAction-
-
queryResultSet
void queryResultSet(org.apache.jena.query.Query query, Consumer<org.apache.jena.query.ResultSet> resultSetAction) Execute a SELECT query and process the ResultSet with the handler code.- Parameters:
query-resultSetAction-
-
querySelect
Execute a SELECT query and process the rows of the results with the handler code.- Parameters:
query-rowAction-
-
querySelect
void querySelect(org.apache.jena.query.Query query, Consumer<org.apache.jena.query.QuerySolution> rowAction) Execute a SELECT query and process the rows of the results with the handler code.- Parameters:
query-rowAction-
-
queryConstruct
Execute a CONSTRUCT query and return as a Model -
queryConstruct
org.apache.jena.rdf.model.Model queryConstruct(org.apache.jena.query.Query query) Execute a CONSTRUCT query and return as a Model -
queryDescribe
Execute a DESCRIBE query and return as a Model -
queryDescribe
org.apache.jena.rdf.model.Model queryDescribe(org.apache.jena.query.Query query) Execute a DESCRIBE query and return as a Model -
queryAsk
Execute a ASK query and return a boolean -
queryAsk
boolean queryAsk(org.apache.jena.query.Query query) Execute a ASK query and return a boolean -
query
org.apache.jena.query.QueryExecution query(org.apache.jena.query.Query query) Setup a SPARQL query execution. See alsoquerySelect(Query, Consumer),queryConstruct(Query),queryDescribe(Query),queryAsk(Query)for ways to execute queries for of a specific form.- Parameters:
query-- Returns:
- QueryExecution
-
query
Setup a SPARQL query execution. See alsoquerySelect(String, Consumer),queryConstruct(String),queryDescribe(String),queryAsk(String)for ways to execute queries for of a specific form.- Parameters:
queryString-- Returns:
- QueryExecution
-
newQuery
org.apache.jena.query.QueryExecutionBuilder newQuery()Return an execution builder initialized with the RDFConnection setup.- Returns:
- QueryExecutionBuilderCommon
-
close
void close()Close this connection. Use with try-resource.- Specified by:
closein interfaceAutoCloseable
-