What I described is the only way to do it at the moment. The behavior you
are looking for is not there. You could add an RFE issue, if there isn't
one already.

On the client side, build the URI from the same template:

    final Template ACCOUNT_TEMPLATE = new Template("/account/{id}");
    ...
    ClientResource rootResource = new ClientResource(baseUri);
    ...
    int id = ..;
    String path = ACCOUNT_TEMPLATE.format(ImmutableMap.of("id", id));
    AccountResource accountResource = rootResource.getChild(path,
AccountResource.class);
    Account account = accountResource.get();

Restlet offers the convincing illusion -- too convincing! -- that you can
call any Java method on the client side and have it remotely call the same
method on the server. At its heart, though, it's just providing different
names for the four or five methods of the uniform interface.

--tim

On Thu, Jul 26, 2012 at 4:20 PM, Norm Deane <norm.de...@vanderbilt.edu>wrote:

> That's not quite what I'm looking for Tim. I want the signature of the GET
> annotated method to have an int parameter and to have the restlet framework
> parse the value from the URI and pass it to my method.
>
> It seems that this behavior should be there but I can't find it.
>
> Also, on the client side if the client is using the interface defined for
> this resource and a proxy created by ClientResource.wrap how do they
> specify the int parameter to the get if they aren't defined on the GET
> annotated method.
>
> Norm
>
> ------------------------------------------------------
>
> http://restlet.tigris.org/ds/viewMessage.do?dsForumId=4447&dsMessageId=2993258
>

------------------------------------------------------
http://restlet.tigris.org/ds/viewMessage.do?dsForumId=4447&dsMessageId=2993269

Reply via email to