java.lang.Object
org.apache.jena.http.HttpRDF
A collection of convenience operations for HTTP level operations
for RDF related tasks. This does not include GSP naming
which is in
GSP
.
See also AsyncHttpRDF
.-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic void
httpDeleteGraph
(String url) static void
httpDeleteGraph
(HttpClient httpClient, String url) static org.apache.jena.graph.Graph
httpGetGraph
(String url) GET a graph from a URLstatic org.apache.jena.graph.Graph
httpGetGraph
(String url, String acceptHeader) GET a graph from a URL using the provided "Accept" header.static org.apache.jena.graph.Graph
httpGetGraph
(HttpClient httpClient, String url) GET a graph from a URL using theHttpClient
provided.static org.apache.jena.graph.Graph
httpGetGraph
(HttpClient httpClient, String url, String acceptHeader) GET a graph from a URL using theHttpClient
provided and the "Accept" header.static void
httpGetToStream
(String url, String acceptHeader, StreamRDF dest) Send the RDF data from the resource at the URL to the StreamRDF.static void
httpGetToStream
(HttpClient client, String url, String acceptHeader, StreamRDF dest) Read the RDF data from the resource at the URL and send to the StreamRDF.static void
httpGetToStream
(HttpClient client, String url, Map<String, String> headers, StreamRDF dest) Read the RDF data from the resource at the URL and send to the StreamRDF.static void
httpPostDataset
(HttpClient httpClient, String url, DatasetGraph dataset, RDFFormat format) static void
httpPostDataset
(HttpClient httpClient, String url, DatasetGraph dataset, RDFFormat format, Map<String, String> httpHeaders) static void
httpPostGraph
(String url, org.apache.jena.graph.Graph graph) static void
httpPostGraph
(HttpClient httpClient, String url, org.apache.jena.graph.Graph graph, RDFFormat format) static void
httpPostGraph
(HttpClient httpClient, String url, org.apache.jena.graph.Graph graph, RDFFormat format, Map<String, String> httpHeaders) static org.apache.jena.graph.Graph
httpPostGraphRtn
(String url, org.apache.jena.graph.Graph graph) Post a graph and expect an RDF graph back as the result.static org.apache.jena.graph.Graph
httpPostGraphRtn
(HttpClient httpClient, String url, org.apache.jena.graph.Graph graph, RDFFormat format, Map<String, String> httpHeaders) Post a graph and expect an RDF graph back as the result.static void
httpPutDataset
(HttpClient httpClient, String url, DatasetGraph dataset, RDFFormat format) static void
httpPutDataset
(HttpClient httpClient, String url, DatasetGraph dataset, RDFFormat format, Map<String, String> httpHeaders) static void
httpPutGraph
(String url, org.apache.jena.graph.Graph graph) static void
httpPutGraph
(HttpClient httpClient, String url, org.apache.jena.graph.Graph graph, RDFFormat fmt) static void
httpPutGraph
(HttpClient httpClient, String url, org.apache.jena.graph.Graph graph, RDFFormat format, Map<String, String> httpHeaders)
-
Constructor Details
-
HttpRDF
public HttpRDF()
-
-
Method Details
-
httpGetGraph
GET a graph from a URL- Throws:
HttpException
-
httpGetGraph
GET a graph from a URL using the provided "Accept" header.- Throws:
HttpException
-
httpGetGraph
GET a graph from a URL using theHttpClient
provided.- Throws:
HttpException
-
httpGetGraph
public static org.apache.jena.graph.Graph httpGetGraph(HttpClient httpClient, String url, String acceptHeader) GET a graph from a URL using theHttpClient
provided and the "Accept" header.- Throws:
HttpException
-
httpGetToStream
Send the RDF data from the resource at the URL to the StreamRDF. Beware of parse errors!- Throws:
HttpException
-
httpGetToStream
public static void httpGetToStream(HttpClient client, String url, String acceptHeader, StreamRDF dest) Read the RDF data from the resource at the URL and send to the StreamRDF.Beware of parse errors!
- Throws:
HttpException
RiotException
-
httpGetToStream
public static void httpGetToStream(HttpClient client, String url, Map<String, String> headers, StreamRDF dest) Read the RDF data from the resource at the URL and send to the StreamRDF.Beware of parse errors!
- Throws:
HttpException
RiotException
-
httpPostGraph
-
httpPostGraph
public static void httpPostGraph(HttpClient httpClient, String url, org.apache.jena.graph.Graph graph, RDFFormat format) -
httpPostGraph
-
httpPostGraphRtn
public static org.apache.jena.graph.Graph httpPostGraphRtn(String url, org.apache.jena.graph.Graph graph) Post a graph and expect an RDF graph back as the result. -
httpPostGraphRtn
public static org.apache.jena.graph.Graph httpPostGraphRtn(HttpClient httpClient, String url, org.apache.jena.graph.Graph graph, RDFFormat format, Map<String, String> httpHeaders) Post a graph and expect an RDF graph back as the result. -
httpPostDataset
public static void httpPostDataset(HttpClient httpClient, String url, DatasetGraph dataset, RDFFormat format) -
httpPostDataset
public static void httpPostDataset(HttpClient httpClient, String url, DatasetGraph dataset, RDFFormat format, Map<String, String> httpHeaders) -
httpPutGraph
-
httpPutGraph
public static void httpPutGraph(HttpClient httpClient, String url, org.apache.jena.graph.Graph graph, RDFFormat fmt) -
httpPutGraph
-
httpPutDataset
public static void httpPutDataset(HttpClient httpClient, String url, DatasetGraph dataset, RDFFormat format) -
httpPutDataset
public static void httpPutDataset(HttpClient httpClient, String url, DatasetGraph dataset, RDFFormat format, Map<String, String> httpHeaders) -
httpDeleteGraph
-
httpDeleteGraph
-