As Jerry said, you can't force the MOC to release a managed object. However, 
you CAN force it to turn managed objects into faults. Then in your override of 
-[NSManagedObject didTurnIntoFault], you can release the transient object. You 
will have to recreate the transient object on demand if the managed object is 
faulted back in.

On 2013-08-09, at 8:38 AM, Jerry Krinock <[email protected]> wrote:

> 
> 
> On 2013 Aug 09, at 00:59, Rick Mann <[email protected]> wrote:
> 
>> I've tried calling -refreshObject:mergeChanges: on it, but that only seems 
>> to reduce the retain count on my object by one.
> 
> I presume that Xcode's Product > Profile > Leaks is available in iOS 
> projects.  You could run it and make sure you don't have a memory leak.
> 
>> What I really want is for Core Data to just let my objects go when I'm no 
>> longer strongly referencing them.
> 
> I vaguely recall that maybe Core Data is not guaranteed to release managed 
> objects until their owning managed object context is deallocced.  You may 
> need to fetch objects you want released in a different, temporary moc.
> 
> Anyhow, maybe my wild guesses will inspire someone to jump in and correct me 
> :)
> _______________________________________________
> 
> Cocoa-dev mailing list ([email protected])
> 
> 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:
> https://lists.apple.com/mailman/options/cocoa-dev/dave.fernandes%40utoronto.ca
> 
> This email sent to [email protected]


_______________________________________________

Cocoa-dev mailing list ([email protected])

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:
https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to [email protected]

Reply via email to