• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: ARC Extending Lifetime of Objects
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: ARC Extending Lifetime of Objects


  • Subject: Re: ARC Extending Lifetime of Objects
  • From: Graham Cox <email@hidden>
  • Date: Mon, 23 Jul 2012 23:22:01 +1000

On 23/07/2012, at 11:12 PM, Andreas Grosam wrote:

> Due to the lack of attributes attachable to properties in Objective-C language and a momento method (I already warned that I'll possibly digressing ;)  ) I just use a deep copy for creating the momento.


Another solution is to use archiving to turn your object graph into a block of data. While this may sound not very high performance, it may be adequate - after all, if the purpose is to Undo or Cancel, the actual need to Undo or Cancel doesn't arise very often, so it's not like you have to perform thousands of these per second, and archiving is pretty fast if your object graph isn't ultra-complex.

--Graham




_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Follow-Ups:
    • Re: ARC Extending Lifetime of Objects
      • From: Andreas Grosam <email@hidden>
References: 
 >ARC Extending Lifetime of Objects (From: Andreas Grosam <email@hidden>)
 >Re: ARC Extending Lifetime of Objects (From: Mike Abdullah <email@hidden>)
 >Re: ARC Extending Lifetime of Objects (From: Andreas Grosam <email@hidden>)
 >Re: ARC Extending Lifetime of Objects (From: Mike Abdullah <email@hidden>)
 >Re: ARC Extending Lifetime of Objects (From: Andreas Grosam <email@hidden>)
 >Re: ARC Extending Lifetime of Objects (From: Mike Abdullah <email@hidden>)
 >Re: ARC Extending Lifetime of Objects (From: Andreas Grosam <email@hidden>)

  • Prev by Date: Re: ARC Extending Lifetime of Objects
  • Next by Date: Re: ARC Extending Lifetime of Objects
  • Previous by thread: Re: ARC Extending Lifetime of Objects
  • Next by thread: Re: ARC Extending Lifetime of Objects
  • Index(es):
    • Date
    • Thread