public class RepositoryFederatedService extends Object implements FederatedService
Repository to communicate with a SPARQL endpoint.| Modifier and Type | Field and Description |
|---|---|
protected org.eclipse.rdf4j.repository.RepositoryConnection |
conn |
protected org.eclipse.rdf4j.repository.Repository |
rep |
protected boolean |
shutDown |
| Constructor and Description |
|---|
RepositoryFederatedService(org.eclipse.rdf4j.repository.Repository repo) |
RepositoryFederatedService(org.eclipse.rdf4j.repository.Repository repo,
boolean shutDown) |
protected final org.eclipse.rdf4j.repository.Repository rep
protected boolean shutDown
protected org.eclipse.rdf4j.repository.RepositoryConnection conn
public RepositoryFederatedService(org.eclipse.rdf4j.repository.Repository repo)
repo - the repository to be usedpublic RepositoryFederatedService(org.eclipse.rdf4j.repository.Repository repo, boolean shutDown)
repo - the repository to be usedshutDown - a flag indicating whether the repository shall be closed in shutdown()public CloseableIteration<BindingSet,QueryEvaluationException> select(Service service, Set<String> projectionVars, BindingSet bindings, String baseUri) throws QueryEvaluationException
Repository of this
FederatedService. Insert bindings into SELECT query and evaluateselect in interface FederatedServiceQueryEvaluationExceptionpublic boolean ask(Service service, BindingSet bindings, String baseUri) throws QueryEvaluationException
Repository of this
FederatedService. Insert bindings, send ask query and return final resultask in interface FederatedServiceQueryEvaluationExceptionpublic CloseableIteration<BindingSet,QueryEvaluationException> evaluate(Service service, CloseableIteration<BindingSet,QueryEvaluationException> bindings, String baseUri) throws QueryEvaluationException
evaluate in interface FederatedServiceQueryEvaluationExceptionprotected CloseableIteration<BindingSet,QueryEvaluationException> evaluateInternal(Service service, CloseableIteration<BindingSet,QueryEvaluationException> bindings, String baseUri) throws QueryEvaluationException
Repository of this FederatedService. Use specified bindings as constraints to the
query. Try to evaluate using BINDINGS clause, if this yields an exception fall back to the naive
implementation. This method deals with SILENT SERVICEs.QueryEvaluationExceptionpublic void initialize()
throws QueryEvaluationException
initialize in interface FederatedServiceQueryEvaluationExceptionpublic boolean isInitialized()
isInitialized in interface FederatedServicepublic void shutdown()
throws QueryEvaluationException
shutdown in interface FederatedServiceQueryEvaluationExceptionprotected org.eclipse.rdf4j.repository.RepositoryConnection getConnection() throws org.eclipse.rdf4j.repository.RepositoryException
Copyright © 2015-2017 Eclipse Foundation. All Rights Reserved.