Class DefaultAsyncPushConsumerFactory
- java.lang.Object
-
- org.apache.hc.core5.http2.nio.support.DefaultAsyncPushConsumerFactory
-
- All Implemented Interfaces:
HandlerFactory<AsyncPushConsumer>
public final class DefaultAsyncPushConsumerFactory extends java.lang.Object implements HandlerFactory<AsyncPushConsumer>
Factory forAsyncPushConsumer
instances that make use ofHttpRequestMapper
to dispatch the request to a particularAsyncPushConsumer
for processing.- Since:
- 5.0
-
-
Field Summary
Fields Modifier and Type Field Description private HttpRequestMapper<Supplier<AsyncPushConsumer>>
mapper
-
Constructor Summary
Constructors Constructor Description DefaultAsyncPushConsumerFactory(HttpRequestMapper<Supplier<AsyncPushConsumer>> mapper)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description AsyncPushConsumer
create(HttpRequest request, HttpContext context)
Creates a new handler instance based on properties of an incoming request message..
-
-
-
Field Detail
-
mapper
private final HttpRequestMapper<Supplier<AsyncPushConsumer>> mapper
-
-
Constructor Detail
-
DefaultAsyncPushConsumerFactory
public DefaultAsyncPushConsumerFactory(HttpRequestMapper<Supplier<AsyncPushConsumer>> mapper)
-
-
Method Detail
-
create
public AsyncPushConsumer create(HttpRequest request, HttpContext context) throws HttpException
Description copied from interface:HandlerFactory
Creates a new handler instance based on properties of an incoming request message..- Specified by:
create
in interfaceHandlerFactory<AsyncPushConsumer>
- Parameters:
request
- the incoming request head.context
- the actual execution context.- Returns:
- handler
- Throws:
HttpException
-
-