[prev in list] [next in list] [prev in thread] [next in thread] 

List:       zope3-dev
Subject:    [Zope3-dev] Re: emit ObjectModifiedEvent when object changed and
From:       Philipp von Weitershausen <philipp () weitershausen ! de>
Date:       2006-09-26 20:39:19
Message-ID: 45198FF7.3020301 () weitershausen ! de
[Download RAW message or body]

Chris Withers wrote:
> Hi All,
> 
> Just been wondering about the need to retrofit:
> 
> notify(ObjectModifiedEvent(self))
> 
> ...into lots of code. Can we do anything less intrusive?
> 
> I mean, if a non-Zope object has changed, why should it have to think 
> about emitting events?

Objects don't send events about themselves. It's the code that does 
things to objects that has the responsibility of sending the right 
event. E.g. if your code (e.g. a view) modifies an object, it has to 
send the event. Zope's form machineries do this already, btw.

Philipp
_______________________________________________
Zope3-dev mailing list
Zope3-dev@zope.org
Unsub: http://mail.zope.org/mailman/options/zope3-dev/zope3-dev%40progressive-comp.com

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic