• 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: Copying Managed Objects from App to Doc MOContext
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Copying Managed Objects from App to Doc MOContext


  • Subject: Re: Copying Managed Objects from App to Doc MOContext
  • From: Jerry Krinock <email@hidden>
  • Date: Sat, 20 Dec 2008 18:29:10 -0800


On 2008 Dec, 20, at 17:55, Kyle Sluder wrote:

This doesn't make sense... you don't store arrays in managed object
contexts.

Whoops. Indeed, that does not make sense. I should have said that there are potatoes inserted into the app's central managed object context. They're not in an array and not related to any other entity; they just hang loose in there, fetched when needed, which is not very often.


So, there's a separate app-wide persistent store, or just a separate MOC?

Both. The app-wide MOC has its PSC set to the app-wide PSC, which in turn has a persistent store in the Application Support folder.


Looks OK to me, but having never seen anything like this, I was wondering if
I'm seeing OK today.

It depends on the semantics you're trying to achieve. If what you really want is to store a reference to the central Potato, then store its UUID. If you want to store a copy of the potato, keep doing what you're doing.

By UUID, I believe you mean [[[self objectID] URIRepresentation] absoluteString].


I'd considered that, but since it's possible that the source potato in the central store might go away, indeed I want a copy. I was thinking that, for portability and robustness, in most cases one would not want a document to reference an object in an app's Application Support.

Thank you, Kyle -- I'm starting to see a clearer picture what I'm doing now.

_______________________________________________

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: Copying Managed Objects from App to Doc MOContext
      • From: "Kyle Sluder" <email@hidden>
    • Re: Copying Managed Objects from App to Doc MOContext
      • From: Dave Fernandes <email@hidden>
References: 
 >Copying Managed Objects from App to Doc MOContext (From: Jerry Krinock <email@hidden>)
 >Re: Copying Managed Objects from App to Doc MOContext (From: "Kyle Sluder" <email@hidden>)

  • Prev by Date: Re: Newbie Question: implementing a stack
  • Next by Date: Re: NSTimer help
  • Previous by thread: Re: Copying Managed Objects from App to Doc MOContext
  • Next by thread: Re: Copying Managed Objects from App to Doc MOContext
  • Index(es):
    • Date
    • Thread