From: Gary Gregory <[email protected]>
Date: Wed, Jan 10, 2018 at 2:03 PM
Subject:
To: HttpComponents Project <[email protected]>


Hi All, today we have:

public class DefaultHttpClientIODispatch
                    extends AbstractIODispatch<DefaultNHttpClientConnection>

I would like to use generics in order to type the handler like this:

public class DefaultHttpClientIODispatch<H extends NHttpClientEventHandler>
                    extends AbstractIODispatch<DefaultNHttpClientConnection>

This allows call sites to call getHandler() and get the exact type that was
passed in on construction instead of getting back the interface and going a
type-cast (if you need access to the actual class like I do.)

Same for DefaultHttpServerIODispatch.

I am currently working around not having this feature easily. This is a
"nice-to-have" but not essential.

Thoughts?

Gary

Reply via email to