Class HttpAsyncServer
java.lang.Object
org.apache.hc.core5.http.impl.bootstrap.AbstractConnectionInitiatorBase
org.apache.hc.core5.http.impl.bootstrap.AsyncServer
org.apache.hc.core5.http.impl.bootstrap.HttpAsyncServer
- All Implemented Interfaces:
Closeable
,AutoCloseable
,ModalCloseable
,ConnectionAcceptor
,ConnectionInitiator
,IOReactor
,IOReactorService
HTTP/1.1 server side message exchange handler.
- Since:
- 5.0
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionHttpAsyncServer
(IOEventHandlerFactory eventHandlerFactory, IOReactorConfig ioReactorConfig, Decorator<IOSession> ioSessionDecorator, Callback<Exception> exceptionCallback, IOSessionListener sessionListener) UseAsyncServerBootstrap
to create instances of this class.HttpAsyncServer
(IOEventHandlerFactory eventHandlerFactory, IOReactorConfig ioReactorConfig, Decorator<IOSession> ioSessionDecorator, Callback<Exception> exceptionCallback, IOSessionListener sessionListener, String canonicalName) UseAsyncServerBootstrap
to create instances of this class. -
Method Summary
Modifier and TypeMethodDescriptionlisten
(SocketAddress address) Deprecated.listen
(SocketAddress address, FutureCallback<ListenerEndpoint> callback) Deprecated.listen
(SocketAddress address, URIScheme scheme) listen
(SocketAddress address, URIScheme scheme, Object attachment, FutureCallback<ListenerEndpoint> callback) listen
(SocketAddress address, URIScheme scheme, FutureCallback<ListenerEndpoint> callback) Methods inherited from class org.apache.hc.core5.http.impl.bootstrap.AsyncServer
awaitShutdown, close, close, getEndpoints, getIOReactor, getStatus, initiateShutdown, listen, pause, resume, start
Methods inherited from class org.apache.hc.core5.http.impl.bootstrap.AbstractConnectionInitiatorBase
connect
-
Field Details
-
canonicalName
-
-
Constructor Details
-
HttpAsyncServer
@Internal public HttpAsyncServer(IOEventHandlerFactory eventHandlerFactory, IOReactorConfig ioReactorConfig, Decorator<IOSession> ioSessionDecorator, Callback<Exception> exceptionCallback, IOSessionListener sessionListener, String canonicalName) UseAsyncServerBootstrap
to create instances of this class.- Since:
- 5.1
-
HttpAsyncServer
@Internal public HttpAsyncServer(IOEventHandlerFactory eventHandlerFactory, IOReactorConfig ioReactorConfig, Decorator<IOSession> ioSessionDecorator, Callback<Exception> exceptionCallback, IOSessionListener sessionListener) UseAsyncServerBootstrap
to create instances of this class.
-
-
Method Details
-
listen
public Future<ListenerEndpoint> listen(SocketAddress address, URIScheme scheme, Object attachment, FutureCallback<ListenerEndpoint> callback) - Since:
- 5.1
-
listen
public Future<ListenerEndpoint> listen(SocketAddress address, URIScheme scheme, FutureCallback<ListenerEndpoint> callback) - Since:
- 5.1
-
listen
- Since:
- 5.1
-
listen
@Deprecated public Future<ListenerEndpoint> listen(SocketAddress address, FutureCallback<ListenerEndpoint> callback) Deprecated.Description copied from interface:ConnectionAcceptor
Opens a new listener endpoint with the given socket address. Once the endpoint is fully initialized it starts accepting incoming connections and propagates I/O activity notifications to the I/O event dispatcher.- Specified by:
listen
in interfaceConnectionAcceptor
- Overrides:
listen
in classAsyncServer
- Parameters:
address
- the socket address to listen on.callback
- the result callback.- Returns:
- listener endpoint.
-
listen
Deprecated.- Overrides:
listen
in classAsyncServer
-
listen(SocketAddress, URIScheme)