• 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: CoreData headaches
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: CoreData headaches


  • Subject: Re: CoreData headaches
  • From: Steve Mills <email@hidden>
  • Date: Sun, 30 Oct 2016 22:22:02 -0500

On Oct 30, 2016, at 14:11:01, Chris Hanson <email@hidden> wrote:
>
> On Oct 27, 2016, at 9:02 PM, Steve Mills <email@hidden> wrote:
>>
>> Yes, the Asset is an NSManagedObject. In this call chain, there is no NSManagedObjectContext in sight.
>
> There is always an NSManagedObjectContext involved; an NSManagedObject doesn’t exist outside one. Fortunately, you don’t need to pass one along with an NSManagedObject, you can just ask the NSManagedObject for the context it’s a part of.

That was my misunderstanding because of the confusion of the docs, or maybe the lack of generous explanation in the docs. The explanation they give sounds like they mean the context created specifically to do an operation, like the way that a temporary private context is created, say, to do a bulk add, then is merged with the parent main context when complete. That's why I said there wasn't a context in that call chain, meaning I didn't create a private context to do this work.

It's a bit more clear now, thanks to all of you that have chimed in here.

--
Steve Mills
Drummer, Mac geek


_______________________________________________

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: CoreData headaches
      • From: Samuel Williams <email@hidden>
References: 
 >CoreData headaches (From: Steve Mills <email@hidden>)
 >Re: CoreData headaches (From: Dave Fernandes <email@hidden>)
 >Re: CoreData headaches (From: Steve Mills <email@hidden>)
 >Re: CoreData headaches (From: Dave Fernandes <email@hidden>)
 >Re: CoreData headaches (From: Steve Mills <email@hidden>)
 >Re: CoreData headaches (From: Chris Hanson <email@hidden>)

  • Prev by Date: Re: CoreData headaches
  • Next by Date: Re: CoreData headaches
  • Previous by thread: Re: CoreData headaches
  • Next by thread: Re: CoreData headaches
  • Index(es):
    • Date
    • Thread