I've gone through the firstResource bit of the Restlet 1.1 tutorial and put together a web service that handles GET, POST, DELETE, PUT by subclassing the Resource
class and overriding the appropriate methods and using a Router
to attach the subclassed Resource
classes.
So I'm left thinking - what's the point of a Restlet
?
I can attach a
Resource
or aRestlet
to anApplication
Router
A
Resource
has methods to handle HTTP GET POST etc.A
Restlet
has ahandle
method - do I somehow forward that on to aResource
class?
What's the difference? When do I use one or the other? What would I put in a Restlet
handle
method?
Thanks.