Hi Jonas, I am a fan of Objectify: i abandonned JDO for Objectify.
But, I had the need for DTOs anyway: what you state about GWT & Ofy is true, but if your mixed (front-end + back-end) objects needs to inherit from a hierarchy in the back-end to have generic functions then you are in trouble because the GWT compiler will ask to "pull" this very specific back-end code in the front-end to compile it to JS and then the issues start. To be concrete: all my back-end ofy objects inherit from a root ofy object where I make use of methods annotated with @PrePersist hooks and doing staff with objects and methods of the JRE not supported by GWT compiler -> I had to implement DTOs in order to keep this possibility of inheritance in the back-end. But, again, moving from JDO to Objectify is definitely a good move (especially since the GAE google team pushes in that direction !) regards didier On Jan 26, 8:18 am, Jonas Gehring <[email protected]> wrote: > hi, > > take a look at the persistance framework > "Objectify"http://code.google.com/p/objectify-appengine/ > > Objectify entities can be used in GWT without the need for Data > Transfer Objects. > > On 25 Jan., 21:52, GeneralSlaine <[email protected]> wrote: > > > Hi all, > > I've been having some issues with getting my persistant object to GWT > > web front-end for example when implementing a web page to modify this > > object. Ideally I would like to be able to reuse the same class both > > for back-end as for front-end. > > So far, I have not managed. > > Instead I have a backbone class: Product and a front-end class > > FProduct. Communication between front-end and backbone is always via > > FProduct. So, when moving an object from backbone to web fornt, I have > > some sort of helper class to create an FProduct out of the real > > Product object. > > > Major disavantage is of course the back and forward copying and all > > the code associated with this. > > > Do you guys have better approaches? I'd love to hear your ideas/ best > > practises. > > > BR > > -- You received this message because you are subscribed to the Google Groups "Google App Engine for Java" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/google-appengine-java?hl=en.
