Parameters for annotated resources with interface?

2012-07-25 Thread Norm Deane
Is it possible to do something like this... public interface AccountResource { @Get public Account get(int id); } public class AccountServerResource implements AccountResource { public Account get(int id) { return doSomethingToGetAccount(id); } } If there is I'm missing it. I

RE: OAuth2: How to resolve "Unable to get the template authorize.html."

2012-07-25 Thread Richard Berger
Thank you for the response. I was able to use setTemplateLoader to get my own code to point at a particular directory - but I didn't see how to change what AuthPageServerResource was doing (without of course changing that code and having my own version of it - which I didn't want to do). Did y

Re: Unable to retrieve URI query and path from link

2012-07-25 Thread Tim Peierls
I've used the following code successfully to proxy images. Overriding getTargetRef involves more code, but it also gives you direct control over the redirection. (This code works, but I'd love to hear from experts whether there is a better way. Also, I'm not sure, but I think it interacts badly wit

Unable to retrieve URI query and path from link

2012-07-25 Thread Laurens Rietveld
I'm currently dealing with the following scenario: I want to forward users to a different site using the Redirector class. The site to forward the user to is included in the url: e.g. http://localhost/restlet/http://www.google.com?q=just-a-query. I'm not using TYPE_URI_ALL because I want to proce

RE: OAuth2: How to resolve "Unable to get the template authorize.html."

2012-07-25 Thread Thierry LAU
Hi Richard Please try the solution described here : http://stackoverflow.com/questions/9651019/cant-get-resource-files-in-my-template-files-using-restlet-and-freemarker It consiste to add the following lines in your codes : Configuration configuration = new Configuration(); configuration.setTem

RE: Enable only selected cipher suites

2012-07-25 Thread Jerome Louvel
Hi all, I'm happy to report that this SSL cipher configuration issue has been fixed in both 2.1 and 2.2 branches, with the help from Jim Zuber and his team at QualityLogic. The fix, which has some similarities with the changes made by Andreas, will be available in the upcoming snapshot builds. Be

RE: Oauth Client example

2012-07-25 Thread Thierry LAU
Hi Luko Please replace with the following lines. It works for me : OAuthUser u = (OAuthUser) getRequest().getClientInfo().getUser(); String token = u.getAccessToken(); Best regards Thierry -- http://restlet.tigris.org/ds/viewMessage.do?dsForu