In general you want to use faultForGlobalID for this sort of thing. objectForGlobalID will return null if the enterprise object in question hasn't yet been registered in that particular editing context. faultForGlobalID will properly register the eo in the editing context.

On Dec 16, 2008, at 9:50 AM, Gennady Kushnir wrote:

Hello list.
I can not understand if it is a bug or I am doing something wrong.
I am caching EOGlobalID's for a reference table in a static NSMutableDictionary
However I noticed that this cache is not working:
EOEditingContext.objectForGlobalID returns null
but when getting that EO by other means, its GID is just the same as
requested one (not simply "equals" but "==")
In fact, sometimes it returns fine. But I can not get the difference...

Any ideas?

--
The Ent visualization project:
http://wirehose.com/research/entvisualization



_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list      (Webobjects-dev@lists.apple.com)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Reply via email to