jsr339-experts@jax-rs-spec.java.net

[jsr339-experts] Re: Request/Response.getEntity(...) and Request/ResponseBuilder.entity(...) should take annotations array argument

From: Bill Burke <bburke_at_redhat.com>
Date: Fri, 06 Jan 2012 08:19:51 -0500

On 1/6/12 3:26 AM, Sergey Beryozkin wrote:
> On 06/01/12 00:21, Bill Burke wrote:
>>
>>
>> On 1/5/12 3:04 PM, Sergey Beryozkin wrote:
>>> On 05/01/12 16:46, Bill Burke wrote:
>>>>
>>>>
>>>> On 1/5/12 3:51 AM, Sergey Beryozkin wrote:
>>>>> On 03/01/12 12:35, Marek Potociar wrote:
>>>>>> FYI: http://java.net/jira/browse/JAX_RS_SPEC-160
>>>>>>
>>>>>> The proposal is to add new method overloads to fix the issue.
>>>>>
>>>>> Looks reasonable, however, I'm wondering, how do you expect the
>>>>> calling
>>>>> code to obtain these annotations ?
>>>>
>>>> How? Reflection. I have a similar issue with generic type information
>>>> where currently it is impossible to pass it in manually.
>>>>
>>> Sure, what I meant was that the reflection info is not quite available
>>> on the client side (where I'd say use Response.getEntity(...)), may be I
>>> am missing something
>>>
>>
>> You may be building a request based on reflection info.
>>
> Indeed, as I said I could see how this can be of use for Request and
> possibly for RequestBuilder but not sure so far about Response &
> ResponseBuilder
>

Well, there will be cases where server code may be dealing with response
generically.

-- 
Bill Burke
JBoss, a division of Red Hat
http://bill.burkecentral.com