On Apr 13, 2010, at 3:55 AM, Isak Jonsson wrote:
> Another thing. The creation of subresources through the use of AbstractSubResourceLocators appears a bit hidden for me, as a developer?
>
I don't understand your question - perhaps if you ask it in a different way.
> Assume I have root resources A and B, both with methods returning subresource C (let's call them fromAtoC() and fromBtoC()). My goal is to achieve:
>
> <resource path="A">
> <resource path="C">
> <doc>This resource was obtained through A.fromAtoC()</doc>
> ...
> </resource>
> </resource>
> <resource path="B">
> <resource path="C">
> <doc>This resource was obtained through B.fromAtoC()</doc>
> ...
> </resource>
> </resource>
>
> Any hints on how to get that information? Or is C the same Resource in both cases?
>
The WADL is generated from the Class so essentially C is the same in both cases. What are you planning to use the WADL for ? From a client perspective I don't see a use for the documentation you show above, all clients need to know is that there are resources at A/C and B/C, what those resources represent and what methods those resources support. Perhaps you are trying to use WADL as technical documentation about the JAX-RS application ?
Marc.
>
>
>> -----Original Message-----
>> From: Marc Hadley [mailto:marc.hadley_at_oracle.com]
>> Sent: den 8 april 2010 14:33
>> To: dev_at_jersey.dev.java.net
>> Subject: Re: [Jersey] Jersey, annotations, and WADL
>>
>> Could you add an issue so we can keep track of this. I'm looking into
>> the WADL generation aspect at the moment and will look into this issue.
>>
>> Marc.
>>
>> On Apr 8, 2010, at 5:13 AM, Isak Jonsson wrote:
>>
>>> Hello, small suggestion to IntrospectorModeller.java.
>>>
>>> Let's assume I have a resource
>>>
>>> @Path("somepath")
>>> public class MyResource {
>>> @GET
>>> public String myMethod(@MyAnnotation String parameter) { ... } }
>>> }
>>>
>>> Here, @MyAnnotation messes up the Parameter generated by
>> IntrospectorModeller, so that the resulting WADL is "broken", or
>> rather, less usable. Maybe there should be a way to have
>> IntrospectorModeller to ignore this annotation?
>>>
>>> Cheers,
>>>
>>> /Isak
>