public interface HttpTransport
| Modifier and Type | Interface and Description |
|---|---|
static interface |
HttpTransport.Response
An HTTP operation response.
|
| Modifier and Type | Method and Description |
|---|---|
static HttpTransport |
create()
Create the most suitable
HttpTransport based on the
system environment. |
static HttpTransport |
create(DockerHost dockerHost)
Create the most suitable
HttpTransport based on the
system environment. |
static HttpTransport |
create(Environment environment)
Create the most suitable
HttpTransport based on the given
Environment. |
static HttpTransport |
create(Environment environment,
DockerHost dockerHost)
|
HttpTransport.Response |
delete(URI uri)
Perform a HTTP DELETE operation.
|
HttpTransport.Response |
get(URI uri)
Perform a HTTP GET operation.
|
HttpTransport.Response |
post(URI uri)
Perform a HTTP POST operation.
|
HttpTransport.Response |
post(URI uri,
String registryAuth)
Perform a HTTP POST operation.
|
HttpTransport.Response |
post(URI uri,
String contentType,
IOConsumer<OutputStream> writer)
Perform a HTTP POST operation.
|
HttpTransport.Response |
put(URI uri,
String contentType,
IOConsumer<OutputStream> writer)
Perform a HTTP PUT operation.
|
HttpTransport.Response get(URI uri) throws IOException
uri - the destination URI (excluding any host/port)IOException - on IO errorHttpTransport.Response post(URI uri) throws IOException
uri - the destination URI (excluding any host/port)IOException - on IO errorHttpTransport.Response post(URI uri, String registryAuth) throws IOException
uri - the destination URI (excluding any host/port)registryAuth - registry authentication credentialsIOException - on IO errorHttpTransport.Response post(URI uri, String contentType, IOConsumer<OutputStream> writer) throws IOException
uri - the destination URI (excluding any host/port)contentType - the content type to writewriter - a content writerIOException - on IO errorHttpTransport.Response put(URI uri, String contentType, IOConsumer<OutputStream> writer) throws IOException
uri - the destination URI (excluding any host/port)contentType - the content type to writewriter - a content writerIOException - on IO errorHttpTransport.Response delete(URI uri) throws IOException
uri - the destination URI (excluding any host/port)IOException - on IO errorstatic HttpTransport create()
HttpTransport based on the
system environment.HttpTransport instancestatic HttpTransport create(DockerHost dockerHost)
HttpTransport based on the
system environment.dockerHost - the Docker engine host configurationHttpTransport instancestatic HttpTransport create(Environment environment)
HttpTransport based on the given
Environment.environment - the source environmentHttpTransport instancestatic HttpTransport create(Environment environment, DockerHost dockerHost)
environment - the source environmentdockerHost - the Docker engine host configurationHttpTransport instance