Hi,
I have been using restlet with spring. I have a resource (ContactResource).
And I want to use @Get(or others, @Put,..) annotation for different methods
at same resource.
Now i am using this way,
public class ContactResource() {
@Get
public Representation seperator() {
String opretion = getRequestAttributes().get("operation");
if("getcontact".equals(operation)) {
return getContact();
} else if("getcontactbyx".equals(operation)) {
return getContactByX();
}
}
public Representation getContact() {
//Some Code
}
public Representation getContactByX() {
//Some Code
}
}
But I dont want to use "if else" pairs for seperating every other methods.
So , does restlet have any solution for this issue.
And restlet cofiguration part (at application-config.xml(Spring
configuration file))
Thanks
Musa
--
View this message in context:
http://restlet-discuss.1400322.n2.nabble.com/Using-Get-or-Put-annotation-for-different-methods-at-the-same-resource-tp6161197p6161197.html
Sent from the Restlet Discuss mailing list archive at Nabble.com.
------------------------------------------------------
http://restlet.tigris.org/ds/viewMessage.do?dsForumId=4447&dsMessageId=2710907