• 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: Strange localInstanceOfObject behaviour...
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Strange localInstanceOfObject behaviour...


  • Subject: Re: Strange localInstanceOfObject behaviour...
  • From: Mark Ritchie <email@hidden>
  • Date: Wed, 31 May 2006 18:01:02 -0400

On Wednesday, May 31, 2006, at 05:37PM, Mike Schrag <email@hidden> wrote:
>You can't localInstanceOfObject a new object (one that has not been committed yet).  There's no snapshot yet, so it would have odd side-effects if they allowed you to do so (it would mean that when you save both editing contexts, it would commit twice, i would assume).  Not sure if old versions of EOF let you, but it's been this way for a while.

Um, sure you can... As long as the temporary object is registered in a parent editingContext and your referencing it in a child editingContext.  It just works.  This is the beauty of using a child editingContext to play in, as your 'sandbox' if you like. You can try out new object connections, configurations and settings before deciding weather to commit the changes to the parent editingContext.  and then if your happy, you can commit the parent editingContext to save the whole thing or ditch the parent if you decide that it's not working out.  You'd loose a lot of EOF's abilities if this wasn't the case.

And just for fun, you can have multiple peer editingContexts which all reference the temporary EO so long as the temporary object is registered in an editingContext which is common to both peers. :-)

And yes, IIRC, this has worked back to EOF v2.  I've tried to forget EOF v1 and DBKit! ;-)

Regards,
Mark
__
Mark Ritchie
Diamond Lake Consulting Inc., Toronto Ontario Canada.

 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Follow-Ups:
    • Re: Strange localInstanceOfObject behaviour...
      • From: Mike Schrag <email@hidden>
    • Re: Strange localInstanceOfObject behaviour...
      • From: "Pierce T. Wetter III" <email@hidden>
    • Re: Strange localInstanceOfObject behaviour...
      • From: Kieran Kelleher <email@hidden>
  • Prev by Date: Re: Strange localInstanceOfObject behaviour...
  • Next by Date: Re: Strange localInstanceOfObject behaviour...
  • Previous by thread: Re: Strange localInstanceOfObject behaviour...
  • Next by thread: Re: Strange localInstanceOfObject behaviour...
  • Index(es):
    • Date
    • Thread