Hi Harald,

I just reached your email :) Thanks for the enthusiasm! If I understand
correctly, Piriti is a JAXB equivalent for GWT, leveraging GWT's deferred
binding mechanism? 

Our approach in Restlet 2.0 was to leverage the object serialization format
from the GWT-RPC mechanism to serialize the objects exchanged between a
Restlet server and a Restlet/GWT client. See the complete tutorial here:
http://wiki.restlet.org/docs_2.0/13-restlet/181-restlet/303-restlet.html

The advantage is that the serialization is fully transparent and we can
still get JSON and XML from the server using content negotiation.

What is nice with your solution is that if you *don't* control the server
and have to deal with a given XML output, then you can still facilitate the
parsing work with annotations.

If we could combine that feature with our support for Restlet annotated
interfaces in GWT, then we could have a nice combination! We just need to
open up Restlet deferred binding logic to support extensions: GWT-RPC or
Piriti-XML or *-JSON maybe?

I've just entered a RFE to keep track of this:

"Add Piriti extension for GWT XML serialization"
http://restlet.tigris.org/issues/show_bug.cgi?id=1041

This would be a nice enhancement for Restlet 2.1!

Best regards,
Jerome Louvel
--
Restlet ~ Founder and Technical Lead ~ http://www.restlet.org
Noelios Technologies ~ http://www.noelios.com




-----Message d'origine-----
De : Harald Pehl [mailto:[email protected]] 
Envoyé : vendredi 15 janvier 2010 11:26
À : [email protected]
Objet : XML mapper for GWT

I'm a big fan of the Restlet framework. When using REST resources with XML
representations in combination with GWT you have to parse the XML and map it
to the model used in the GWT client. The code therefore is tedious and
error-prone. So I decided to start a little framework called "piriti" (Maori
for bridge). The basic idea behind piriti is to use annotations on your
model and generate the parsing / mapping code with the help of deferred
binding. 

Feel free to take a look at it under http://code.google.com/p/piriti/ and
let me know if this is somewhat useful! 

Cheers Harald

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

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

Reply via email to