It's not really recommended to use getMemento() and setMemento() in your own
code - they are meant for internal use.  I created my own version of
getMemento() that is safe to consume, and I also have a populate() method
that could be used as a replacement for setMemento().  You can find
references to both on my blog.

Cheers,
Bob

On Thu, Oct 29, 2009 at 1:21 PM, John Watson <[email protected]> wrote:

> Someone who knows a little more detail about how the caching works may say
> what I suggest is a bad a idea, but here's a method I've used with no issues
> yet.
>
> Inside the decorator I've used the TO.setTransferObject(otherTO) method.
> Though both the setting object and the TO object are both the same (IE:
> content/content).
>
> Another idea may be to use setMemento(mementoStruct)
>
> John
>
>
> On Thu, Oct 29, 2009 at 09:10, Jim Rising <[email protected]> wrote:
>
>> I'm needing to copy one TO to another TO, and wondered if anyone had any
>> ideas on the best way to do that? Basically I have one TO that needs to
>> serve as a 'template' of another.
>>
>> Example:
>>
>> I have a TO called 'contentTemplate' and another called 'content'.
>> I want to be able to create a 'content' object from the 'contentTemplate'
>> object.
>>
>> I'm thinking I will need to just get / set everything between each of
>> them, but was hoping I would have another option available.
>>
>> Thanks!
>> --
>> Jim Rising
>> Serial Entrepreneur
>> Software Engineer
>> Web Developer
>>
>> "Knowledge work requires both autonomy and accountability."
>>
>>
>>
>
> >
>


-- 
Bob Silverberg
www.silverwareconsulting.com

--~--~---------~--~----~------------~-------~--~----~
Before posting questions to the group please read:
http://groups.google.com/group/transfer-dev/web/how-to-ask-support-questions-on-transfer

You received this message because you are subscribed to the Google Groups 
"transfer-dev" 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/transfer-dev?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to