hopefully a simple hook (non-html version)
Can't believe I sent an HTML email, sorry about that. I was wondering if there was a simple hook into ObjecManager or something like this that lets me know when an item in the container has been altered. At present I have to actively mine the container for changes to bobobase modification times of the objects it contains. I have wrapped a small product around Folder.Folder to allow me to do this, but would like to find a hook that lets me know when the modification time of a contained object has changed. Matt
Matt wrote:
I was wondering if there was a simple hook into ObjecManager or something like this that lets me know when an item in the container has been altered. At present I have to actively mine the container for changes to bobobase modification times of the objects it contains. I have wrapped a small product around Folder.Folder to allow me to do this, but would like to find a hook that lets me know when the modification time of a contained object has changed.
No! But could just create a simple Python script in you root folder, that would traverse the next objectmanager in the aquisition path and get the "last modified date." Then you won't have to put the method in every Folder derived class you create. regards Max M
I was wondering if there was a simple hook into ObjectManager or something like this that lets me know when an item in the container has been altered. At present I have to actively mine the container for changes to bobobase modification times of the objects it contains. I have wrapped a small product around Folder.Folder to allow me to do this, but would like to find a hook that lets me know when the modification time of a contained object has changed.
This could probably be a useful solution: an AllSeeingObjectManager, derived from ObjectManager and in _setObject and _getObject it would notify its parent through a manage_afterSublevelCreate if the parent is also an AllSeeingObjectManager... Florent -- Florent Guillaume, Nuxeo (Paris, France) +33 1 40 33 79 10 http://nuxeo.com mailto:fg@nuxeo.com
Dunno if someone already suggested this, but what about cataloging the objects and querying the catalog for recent changes? Or you could hook simple item's (I think that's the right one) edit method to shoot a signal when it's called?
From: Florent Guillaume <fg@nuxeo.com> Organization: Nuxeo Newsgroups: local.lists.zope.zope Date: Tue, 29 Jan 2002 18:23:27 +0000 (UTC) To: zope@zope.org Subject: Re: [Zope] hopefully a simple hook (non-html version)
I was wondering if there was a simple hook into ObjectManager or something like this that lets me know when an item in the container has been altered. At present I have to actively mine the container for changes to bobobase modification times of the objects it contains. I have wrapped a small product around Folder.Folder to allow me to do this, but would like to find a hook that lets me know when the modification time of a contained object has changed.
This could probably be a useful solution: an AllSeeingObjectManager, derived from ObjectManager and in _setObject and _getObject it would notify its parent through a manage_afterSublevelCreate if the parent is also an AllSeeingObjectManager...
Florent -- Florent Guillaume, Nuxeo (Paris, France) +33 1 40 33 79 10 http://nuxeo.com mailto:fg@nuxeo.com
_______________________________________________ Zope maillist - Zope@zope.org http://lists.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope-dev )
participants (4)
-
Florent Guillaume -
marc lindahl -
Matt -
Max M