Package org.eclipse.rdf4j.federated
Class EndpointManager
- java.lang.Object
-
- org.eclipse.rdf4j.federated.EndpointManager
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description void
addEndpoint(Endpoint e)
Add the (initialized) endpoint to this endpoint manager to be used by theFederationManager
.Collection<Endpoint>
getAvailableEndpoints()
Endpoint
getEndpoint(String endpointID)
Endpoint
getEndpointByName(String endpointName)
Endpoint
getEndpointByUrl(String endpointUrl)
Return the Endpoint for the provided endpoint url, if it exists.List<Endpoint>
getEndpoints(Set<String> endpointIDs)
static EndpointManager
initialize(List<Endpoint> endpoints)
Initialize the singleton endpoint manager with the provided endpointsprotected void
removeEndpoint(Endpoint e)
Remove the provided endpoint from this endpoint manager to be used by theFederationManager
.
-
-
-
Method Detail
-
initialize
public static EndpointManager initialize(List<Endpoint> endpoints)
Initialize the singleton endpoint manager with the provided endpoints- Parameters:
endpoints
-
-
addEndpoint
public void addEndpoint(Endpoint e)
Add the (initialized) endpoint to this endpoint manager to be used by theFederationManager
.- Parameters:
e
- the endpoint
-
removeEndpoint
protected void removeEndpoint(Endpoint e) throws NoSuchElementException
Remove the provided endpoint from this endpoint manager to be used by theFederationManager
. In addition, this method unregisters theFederatedService
from RDF4J.- Parameters:
e
- the endpoint- Throws:
NoSuchElementException
- if there is no mapping for some endpoint id
-
getAvailableEndpoints
public Collection<Endpoint> getAvailableEndpoints()
- Returns:
- a collection of available endpoints in this endpoint manager
-
getEndpoint
public Endpoint getEndpoint(String endpointID)
- Parameters:
endpointID
-- Returns:
- the endpoint corresponding to the provided id or null
-
getEndpointByUrl
public Endpoint getEndpointByUrl(String endpointUrl)
Return the Endpoint for the provided endpoint url, if it exists. Otherwise return null.- Parameters:
endpointUrl
-- Returns:
- the endpoint by its URL
-
getEndpoints
public List<Endpoint> getEndpoints(Set<String> endpointIDs) throws NoSuchElementException
- Parameters:
endpointIDs
-- Returns:
- a list of endpoints corresponding to the provided ids
- Throws:
NoSuchElementException
- if there is no mapping for some endpoint id
-
-