On Jan 20, 2006, at 6:51 PM, [EMAIL PROTECTED] wrote:

Assuming no undo stack and that any references to EOEnterpriseObject subclasses are broken, how does the interplay between an EC and maintenance of snapshots at the EODatabase level then work after a save changes has occured?

Snapshots are reference-counted (see <http://developer.apple.com/ documentation/LegacyTechnologies/WebObjects/WebObjects_4.5/System/ Documentation/Developer/WebObjects/DeltaDoc/EOF.html#CBGDABII>). So as long as a reference to a snapshot from any editing context exists, the snapshot will remain. But when the last reference is broken (e.g., when an editing context is freed), the snapshot will be freed.

So if you have a situation in which some objects need to persist, they can be in one editing context that is kept for the life of the process. But if other objects are transient, they can be in a different temporary editing context. When these objects are no longer needed, the editing context can be freed which will free all snapshots whose only reference was in the freed editing context.

Aloha,
Art

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

This email sent to [email protected]

Reply via email to