Class FedXRepository
java.lang.Object
org.eclipse.rdf4j.repository.base.AbstractRepository
org.eclipse.rdf4j.repository.sail.SailRepository
org.eclipse.rdf4j.federated.repository.FedXRepository
- All Implemented Interfaces:
HttpClientDependent,SessionManagerDependent,FederatedServiceResolverClient,Repository,RepositoryResolverClient
A special
SailRepository which performs the actions as defined in FedXRepositoryConnection.- Author:
- as
-
Field Summary
Fields inherited from class org.eclipse.rdf4j.repository.base.AbstractRepository
logger -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionOpens a connection to this repository that can be used for querying and updating the contents of the repository.return the number of triples in the federation as string.protected voidvoidSets theFederatedServiceResolverto use for this client.protected voidMethods inherited from class org.eclipse.rdf4j.repository.sail.SailRepository
getDataDir, getFederatedServiceResolver, getHttpClient, getHttpClientSessionManager, getSail, getValueFactory, isWritable, setDataDir, setHttpClient, setHttpClientSessionManager, setRepositoryResolver, toStringMethods inherited from class org.eclipse.rdf4j.repository.base.AbstractRepository
init, isInitialized, shutDown
-
Constructor Details
-
FedXRepository
-
-
Method Details
-
getConnection
Description copied from interface:RepositoryOpens a connection to this repository that can be used for querying and updating the contents of the repository. Created connections need to be closed to make sure that any resources they keep hold of are released. The best way to do this is to use a try-with-resources block, as follows:try (RepositoryConnection conn = repository.getConnection()) { // perform operations on the connection }Note that
RepositoryConnectionis not guaranteed to be thread-safe! The recommended pattern for repository access in a multi-threaded application is to share the Repository object between threads, but have each thread create and use its ownRepositoryConnections.- Specified by:
getConnectionin interfaceRepository- Overrides:
getConnectionin classSailRepository- Returns:
- A connection that allows operations on this repository.
- Throws:
RepositoryException- If something went wrong during the creation of the Connection.
-
initializeInternal
- Overrides:
initializeInternalin classSailRepository- Throws:
RepositoryException
-
shutDownInternal
- Overrides:
shutDownInternalin classSailRepository- Throws:
RepositoryException
-
setFederatedServiceResolver
Description copied from interface:FederatedServiceResolverClientSets theFederatedServiceResolverto use for this client.- Specified by:
setFederatedServiceResolverin interfaceFederatedServiceResolverClient- Overrides:
setFederatedServiceResolverin classSailRepository- Parameters:
resolver- The resolver to use.
-
getFederationSize
return the number of triples in the federation as string. Retrieving the size is only supportedEndpointType.NativeStoreandEndpointType.RemoteRepository. If the federation contains other types of endpoints, the size is indicated as a lower bound, i.e. the string starts with a larger sign.- Returns:
- the number of triples in the federation
-
getFederationContext
- Returns:
- the
FederationContext
-
getQueryManager
- Returns:
- the
QueryManagerfrom theFederationContext
-