Class JdkRDF4JHttpClient
java.lang.Object
org.eclipse.rdf4j.http.client.jdk.JdkRDF4JHttpClient
- All Implemented Interfaces:
AutoCloseable, RDF4JHttpClient
RDF4JHttpClient implementation backed by java.net.http.HttpClient.-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidclose()Closes this client and releases any resources held (e.g., connection pools, threads).execute(HttpRequest request) Executes the given HTTP request and returns the response.
-
Constructor Details
-
JdkRDF4JHttpClient
-
-
Method Details
-
execute
Description copied from interface:RDF4JHttpClientExecutes the given HTTP request and returns the response.The caller must close the returned
HttpResponseafter use to release connection resources.- Specified by:
executein interfaceRDF4JHttpClient- Parameters:
request- the request to execute.- Returns:
- the HTTP response.
- Throws:
IOException- if a network or I/O error occurs.
-
close
public void close()Description copied from interface:RDF4JHttpClientCloses this client and releases any resources held (e.g., connection pools, threads).- Specified by:
closein interfaceAutoCloseable- Specified by:
closein interfaceRDF4JHttpClient
-