Hello.
I've been trying to make a small test application
using restlets. First of all I'd like to say good work
on bringing a framework for developing REST
applications to Java, that was sorely needed!
Anyway. I've looked at the sample code, and there the
domain classes are subclasses of Resource.
Looking at the Handler code in eg handleDelete, the
Resource is found, and the delete() method is called
on the resource.
If we use the domain class as a subclass of Resource,
this would mean that the object will have to delete
itself... Isn't that a bit strange? Is it better to
make the Resource classes refer to the real domain
objects, and thereby deleting the referred domain
object?
How have others separated the domain objects and the
Resources?
I'm desperatly seeking some documentation that goes a
bit beyond setting up a server and plain Javadoc, as
well as a more complete example with all CRUD methods
implemented.
Regards,
Kyrre
------------------------------------------------------------
Kyrre Kristiansen
___________________________________________________________
To help you stay safe and secure online, we've developed the all new Yahoo!
Security Centre. http://uk.security.yahoo.com