On 08/25/2011 02:16 PM, Bill Burke wrote:
>
>
> On 8/24/11 10:23 PM, Bill Burke wrote:
>> 6) Once Invocation extends HttpRequest you start to see that all the
>> Builder interfaces just don't make sense at all.
>
> yet another reason why the whole Builder class hierarchy doesn't make sense is that there's a chance you'll want to stop
> in the middle of request building and hand off the request to another application method to be finished off. Passing
> around RequestHeader.Builder<Invocation.Builder> references doesn't look very friendly.
>
>
You have multiple other options:
1. pass Target
2. pass Invocation.TargetedBuilder
3. pass RequestHeader.Builder<?>
4. my personal favorite: turn the application method into a Filter and register it within the invocation chain.
Marek