[Cuis-dev] What happened to the changed/update cycle?

stephen at heaveneverywhere.com stephen at heaveneverywhere.com
Sun May 1 11:57:02 PDT 2022


Hi folks,

In the original MVC as described in the BlueBook, the changed/update cycle that is the core of MVC (and any other observer pattern implementation in Smalltalk) was the message sequence:

Any object (a model) sends
	self changed 

which calls, by default
	self changed: aToken

which calls, by default
	self changed: aToken with: anArgument

which calls, by default
	self changed: aToken with: anArgument from: aSender

which was implemented as:
	self dependents do:
		[ :dep |
		dep update: aToken with: anArgument from: aSender]

The dependents then implement update:with:from: or its simpler variants.


In Squeak and descendants (I believe) this is rewritten using triggerEvent: which is less flexible and not compatible.

Does anyone else notice this or have apps that use the old Observer pattern code?

Stephen Pope


--

                    Stephen Travis Pope   Ojai, California, USA    
          http://HeavenEverywhere.com <http://heaveneverywhere.com/>        http://FASTLabInc.com <http://fastlabinc.com/>
                       https://vimeo.com/user19434036/videos <https://vimeo.com/user19434036/videos>      http://heaveneverywhere.com/Reflections

--




-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.cuis.st/mailman/archives/cuis-dev/attachments/20220501/679c9171/attachment-0001.htm>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: pastedGraphic.tiff
Type: image/tiff
Size: 2442 bytes
Desc: not available
URL: <http://lists.cuis.st/mailman/archives/cuis-dev/attachments/20220501/679c9171/attachment-0001.tiff>


More information about the Cuis-dev mailing list