"Phillip J. Eby" wrote:
> It could cause a problem if the object is added after any other sort of
> change from the point of view of the Agent.  The Agent would view it as
> having been added, when in fact it is actually merely changed.  I have not,
> however, been able to think of any scenario where this condition could
> occur unless the DataManager containing the Agent was itself being
> reconfigured during the same transaction as the other events, which is an
> "all bets are off, hold onto your butts" type proposition anyhow.
> My guess is that your patch will probably work fine.  I've checked it in
> locally and will incorporate it into a release soon.

The other approach would be to hold a list of the events that have
happened during a transaction, and have a simple set of rules (regular
grammar, implemented as a state machine, or regular expression) for
condensing a list of events into the overall description of the event.

I just made this regular grammar up without thinking particularly hard
about them. The letters D, C, A stand for Delete, Change and Add
respectively. "C*" means zero or more repeated "C".

C*    : C
CA    : A
DA    : C
AC    : A
C*D   : D
AD    : D

Then again, if you can't think of any but the most unlikely exceptions
to the current simple algorithm, I'll go with that :-)

Steve Alexander
Software Engineer
Cat-Box limited

Zope-Dev maillist  -  [EMAIL PROTECTED]
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope )

Reply via email to