public final class HttpMessenger extends Object implements Messenger<AbstractWebRequest,AbstractWebResponse>
Constructor and Description |
---|
HttpMessenger(Function<org.asynchttpclient.Response,AbstractWebResponse> responseFactory,
HttpOptions options)
Constructor for HttpMessenger.
|
Modifier and Type | Method and Description |
---|---|
void |
close() |
io.netty.channel.EventLoopGroup |
getExecutor()
The
Executor utilized by this messenger |
HttpOptions |
getOptions()
getOptions.
|
AsyncHttpTransport |
getTransport()
The underlying
Transport used by this instance |
CompletableFuture<AbstractWebResponse> |
send(InetSocketAddress address,
AbstractWebRequest request)
Send request to the underlying
Transport |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
get, get, getOrDefault, getOrDefault, lock, set, unlock
public HttpMessenger(Function<org.asynchttpclient.Response,AbstractWebResponse> responseFactory, HttpOptions options)
Constructor for HttpMessenger.
public HttpOptions getOptions()
getOptions.
getOptions
in interface ConfigurationSupport
Options
objectpublic void close() throws IOException
close
in interface Closeable
close
in interface AutoCloseable
IOException
public CompletableFuture<AbstractWebResponse> send(InetSocketAddress address, AbstractWebRequest request)
Send request to the underlying Transport
send
in interface Messenger<AbstractWebRequest,AbstractWebResponse>
address
- a InetSocketAddress
objectrequest
- a R objectCompletableFuture
objectpublic AsyncHttpTransport getTransport()
The underlying Transport
used by this instance
getTransport
in interface Messenger<AbstractWebRequest,AbstractWebResponse>
Transport
objectpublic io.netty.channel.EventLoopGroup getExecutor()
The Executor
utilized by this messenger
getExecutor
in interface Messenger<AbstractWebRequest,AbstractWebResponse>
Executor
objectCopyright © 2016–2024. All rights reserved.