users@jersey.java.net

[Jersey] Re: AbstractSubResourceMethod vs AbstractResourceMethod

From: Marek Potociar <marek.potociar_at_oracle.com>
Date: Tue, 20 Dec 2011 10:31:12 +0100

Can you share more content?

In general:
- a resource method is a method annotated with a HTTP method annotation (e.g. @GET, @POST ...)
- a sub-resource method is a method annotated with a HTTP method annotation *and* @Path annotation
- a sub-resource locator is a method annotated with @Path annotation that returns an instance of a (sub)resource class.

To learn more about resources and subresources, http methods and sub resource locators please read the following section
of Jersey user guide: http://jersey.java.net/nonav/documentation/latest/user-guide.html#jax-rs

You may also want to check the JAX-RS 1.1 specification and javadoc. Links are available at the JAX-RS project page:
http://jax-rs-spec.java.net/

HTH,
Marek

On 12/20/2011 10:07 AM, Jordan Blay wrote:
> Hi!
>
> What is the difference between AbstractSubResourceMethod and
> AbstractResourceMethod?
>
> I saw that my @GET method is AbstractResourceMethod and my @POST was
> AbstractSubResourceMethod .
>
> Where does the difference come from?
>
> Thanks
>
> --
> View this message in context: http://jersey.576304.n2.nabble.com/AbstractSubResourceMethod-vs-AbstractResourceMethod-tp7111166p7111166.html
> Sent from the Jersey mailing list archive at Nabble.com.