Re: The life of a DataObject

From: André Luiz do Nascimento Sousa (andresous..aixaseguros.com.br)
Date: Wed Feb 16 2005 - 15:28:05 EST

  • Next message: Cris Daniluk: "RE: The life of a DataObject"

    Hi, All,


           I few weeks ago, I started a thread here about the needed of Cayenne POJO Objects. Maybe I'm totally wrong, but I think when Cayenne could deal with the attach/dettach POJO's objects in the DataContext automatically, we will could has less doubts like that.

            I wait paciently for this feature :-)

           Thanks and Sorry for my intrusion.

    André Luiz do N. Sousa
         


    Cris Daniluk wrote:

    For what its worth, I think it's a lot easier to just make a duplicate
    version of the DataObject that isn't inherited from CayenneDataObject. Then
    you can just use BeanUtils to load the properties in the Cayenne DataObject.
    This is a little repetitive, but you can make a script to generate your
    initial set automatically and then modify them to suit your needs. We do
    this because it makes form validation, etc a little more convenient and is
    more conducive to distributing the application down the road, where the web
    app and the business logic might not necessarily be on the same server. Try
    using a DataObject then :)
    
    
      
    -----Original Message-----
    From: Fredrik Liden [mailto:fliden@translate.com] 
    Sent: Wednesday, February 16, 2005 1:27 PM
    To: cayenne-user@objectstyle.org
    Subject: RE: The life of a DataObject
    
    Thanks for your feedback Mike, that makes sense!
    
    How about using another DataObject that hasn't been 
    registered with the context to collect the data and then copy 
    that data over to a live DataObject. All in one fetch, 
    update, commit cycle like you suggested.
    
    For new objects I guess I don't need a separate object. When 
    it's filled out I'll only need to register it with the 
    context and submit it.
    
        
    
    
      



    This archive was generated by hypermail 2.0.0 : Wed Feb 16 2005 - 14:26:13 EST