at some place you use Smalltalk globals to access the class.
Now it would be better to have an environment instance variable that is initialized by default to point to Smalltalk globals. Like that I can use your code if I want to store a list of message with another environment that Smalltalk globals I can pass another instance of systemDictionary with what I want inside
Stef
Ok, i've added a environment variable in MessageList which is initialized trought the environment method ;)
good! For the record these are not annoucement but events. Announcement pass objects as send: parameters.
Stef
Ok, i'll resume trying to understand how Announcement works ...
have a look at the code, the point is that as a class you do not want to let the user decide how to interpret you. You can say there are three ways to change me 1, 2, 3 but not how you decided internally to represent them. I just made asDictionaryByDateAscendingSelector = a choice like 1 the client does not have to know that this is #asDictionaryByDateAscending. It could be anything else.
Setf
Ok, now i see :) Thank you again Ben