/** * Returns the SPARQL endpoint URL for the given namespace or the default SPARQL * endpoint in case namespace is null. * * @param namespace * @return the namespace */ private String getSparqlEndpointUrlForNamespaceOrDefault(final String namespace) { return namespace==null ? baseServiceURL + "/sparql" : getRepositoryBaseURLForNamespace(namespace) + "/sparql"; } /**
/** * Obtain a flyweight {@link RemoteRepository} for a data set managed by the * remote service. * * @param namespace * The name of the data set (its bigdata namespace). * * @return An interface which may be used to talk to that data set. */ public RemoteRepository getRepositoryForNamespace(final String namespace) { return getRepositoryForURL(getRepositoryBaseURLForNamespace(namespace) + "/sparql"); }
/** * Destroy a KB instance. * * @param namespace * The namespace of the KB instance. * @param uuid * The {@link UUID} to be assigned to the request.a * * @throws Exception */ public void deleteRepository(final String namespace, final UUID uuid) throws Exception { final ConnectOptions opts = newConnectOptions(getRepositoryBaseURLForNamespace(namespace), uuid, null/* txId */); opts.method = "DELETE"; JettyResponseListener response = null; try { checkResponseCode(response = doConnect(opts)); } finally { if (response != null) response.abort(); } }
public Properties getRepositoryProperties(final String namespace, final UUID uuid) throws Exception { final String sparqlEndpointURL = getRepositoryBaseURLForNamespace(namespace);