public class AsyncServerBootstrap extends Object
HttpAsyncServer
bootstrap.public static AsyncServerBootstrap bootstrap()
public final AsyncServerBootstrap setCanonicalHostName(String canonicalHostName)
public final AsyncServerBootstrap setIOReactorConfig(IOReactorConfig ioReactorConfig)
public final AsyncServerBootstrap setHttp1Config(Http1Config http1Config)
public final AsyncServerBootstrap setCharCodingConfig(CharCodingConfig charCodingConfig)
public final AsyncServerBootstrap setHttpProcessor(HttpProcessor httpProcessor)
HttpProcessor
instance.public final AsyncServerBootstrap setConnectionReuseStrategy(ConnectionReuseStrategy connStrategy)
ConnectionReuseStrategy
instance.public final AsyncServerBootstrap setTlsStrategy(TlsStrategy tlsStrategy)
TlsStrategy
instance.public final AsyncServerBootstrap setTlsHandshakeTimeout(Timeout handshakeTimeout)
Timeout
.public final AsyncServerBootstrap setIOSessionDecorator(Decorator<IOSession> ioSessionDecorator)
public final AsyncServerBootstrap setExceptionCallback(Callback<Exception> exceptionCallback)
public final AsyncServerBootstrap setIOSessionListener(IOSessionListener sessionListener)
IOSessionListener
instance.public final AsyncServerBootstrap setLookupRegistry(LookupRegistry<Supplier<AsyncServerExchangeHandler>> lookupRegistry)
LookupRegistry
instance.public final AsyncServerBootstrap setStreamListener(Http1StreamListener streamListener)
Http1StreamListener
instance.public final AsyncServerBootstrap register(String uriPattern, Supplier<AsyncServerExchangeHandler> supplier)
AsyncServerExchangeHandler
Supplier
as a default handler for URIs
matching the given pattern.uriPattern
- the pattern to register the handler for.supplier
- the handler supplier.public final AsyncServerBootstrap registerVirtual(String hostname, String uriPattern, Supplier<AsyncServerExchangeHandler> supplier)
AsyncServerExchangeHandler
Supplier
as a handler for URIs
matching the given host and the pattern.hostname
- the host nameuriPattern
- the pattern to register the handler for.supplier
- the handler supplier.public final <T> AsyncServerBootstrap register(String uriPattern, AsyncServerRequestHandler<T> requestHandler)
AsyncServerRequestHandler
as a default handler for URIs
matching the given pattern.uriPattern
- the pattern to register the handler for.requestHandler
- the handler.public final <T> AsyncServerBootstrap registerVirtual(String hostname, String uriPattern, AsyncServerRequestHandler<T> requestHandler)
AsyncServerRequestHandler
as a handler for URIs
matching the given host and the pattern.hostname
- the host nameuriPattern
- the pattern to register the handler for.requestHandler
- the handler.public final AsyncServerBootstrap addFilterBefore(String existing, String name, AsyncFilterHandler filterHandler)
public final AsyncServerBootstrap addFilterAfter(String existing, String name, AsyncFilterHandler filterHandler)
public final AsyncServerBootstrap replaceFilter(String existing, AsyncFilterHandler filterHandler)
public final AsyncServerBootstrap addFilterFirst(String name, AsyncFilterHandler filterHandler)
public final AsyncServerBootstrap addFilterLast(String name, AsyncFilterHandler filterHandler)
public HttpAsyncServer create()
Copyright © 2005–2022 The Apache Software Foundation. All rights reserved.