On Fri, 2013-11-22 at 14:27 +0200, Petteri Hentilä wrote:
> A couple of comments.
> 
> 1. I cannot pass the HttpContext to FutureCallback as a construction
> parameter, because that class has only one parameterless constructor. I
> also cannot put the HttpContext as the generic type for FutureCallback
> because it gives me a compile error.
> 

FutureCallback is an _interface_. One can have any constructor
parameters for a class that implements this interface.

> 2. I derived my own class from BasicAsyncResponseConsumer to have more
> control over the response processing, but that class does not have the
> correct methods that I would need. It has a method
> responseReceived(HttpResponse) but it does not get HttpContext as a
> parameter. It also has a method failed(Exception) but it does not get
> HttpContext as a parameter either.
> 

Same deal as with FutureCallback. You can pass any additional contextual
parameters at the construction time.

Oleg



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to