users@jsr311.java.net

PathParam question in regards to Locators

From: Bill Burke <bburke_at_redhat.com>
Date: Thu, 07 Feb 2008 10:14:03 -0500

This is legal I assume? Two PathParams that are "id"

public class Base {
   @Path("/{id}")
   public Resource getResource(@PathParam("id") int id) {
       return new Resource();
   }
}

public class Resource {

    @GET @Path("/{id}")
    public String get(@PathParam("id") int id) {
      ...
    }
}

which leads me to my next question:

If we inject UriInfo into both Base and Resource,
getTemplateParameters() should return a different map, correct? Also,
does UriInfo for Resource have a different baseUri?

Thanks


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