Package com.inrupt.client
Class Request
java.lang.Object
com.inrupt.client.Request
An HTTP Request.
This interface provides a generic API for building and interacting with HTTP requests.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic interfaceAn API for serializing an HTTP Request.static final classBuilt-inRequest.BodyPublisherimplementations.static final classARequestbuilder. -
Method Summary
Modifier and TypeMethodDescriptionTheRequest.BodyPublisherset on this request.headers()The HTTP headers for this request.method()The HTTP method.static Request.BuilderCreates aRequestbuilder.static Request.BuildernewBuilder(URI uri) Creates aRequestbuilder with the given URI.timeout()The timeout for this request.uri()The HTTP URI.
-
Method Details
-
method
The HTTP method.- Returns:
- the HTTP method
-
uri
The HTTP URI.- Returns:
- the HTTP URI
-
bodyPublisher
TheRequest.BodyPublisherset on this request.- Returns:
- the body publisher, if present
-
headers
The HTTP headers for this request.- Returns:
- the HTTP headers
-
timeout
The timeout for this request.- Returns:
- the timeout for this request, if present
-
newBuilder
Creates aRequestbuilder.- Returns:
- the builder
-
newBuilder
Creates aRequestbuilder with the given URI.- Parameters:
uri- the request URI- Returns:
- the builder
-