2009/11/1 Lukas Renggli <[email protected]>:
>> Oh, wait.. you mean that if i want, say 35 out of 50 announcement
>> kinds to be logged, then
>> i need to do something like:
>>
>> logblock := [:announcement | ... ].
>> announcer on: AnnouncementKind1 do: logblock.
>> announcer on: AnnouncementKind2 do: logblock.
>> ....
>> announcer on: AnnouncementKind35 do: logblock.
>>
>> ?
>> Do you agree that this is far from being short and elegant? Moreover
>> it imposes dependency from various kinds of events, instead of just
>> one (LoggedAnnouncement),
>> and, if i going to change them somehow, i would need to revisit this
>> code again.. and again.
>
>    announcer
>        on: AnnouncementKind1 , AnnouncementKind2 , ... AnnouncementKind35
>        do: logblock
>
good catch.
Still dependency on 35 classes .. while my intent is to subscribe to
all announcements which can be logged.
If i load new package, it could provide more announcements which can be logged.
But i will not be able to see them if i'm going to enumerate them in
such way :(



> --
> Lukas Renggli
> http://www.lukas-renggli.ch
>
> _______________________________________________
> Pharo-project mailing list
> [email protected]
> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
>



-- 
Best regards,
Igor Stasenko AKA sig.

_______________________________________________
Pharo-project mailing list
[email protected]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project

Reply via email to