[Pharo-project] NewInspector does not work well with delegated collections

Mariano Martinez Peck marianopeck at gmail.com
Tue Nov 30 10:18:05 CET 2010


On Mon, Nov 29, 2010 at 9:38 PM, jaayer <jaayer at zoho.com> wrote:

> Enclosed is a fileout of a sample collection named DelegatedSet that works
> by delegating to an instance of Set stored in an instance variable. It
> implements the basic protocol Collection requires, including #add:,
> #remove:ifAbsent: and #do: as well as some additional messages, all through
> delegation. Create an instance of it and then inspect that instance with
> NewInsepctor, and you will notice the "Elements" item does not work. Nothing
> happens when you click it. To inspect the elements, you need to click "set,"
> the instance variable containing the Set, and then inspect that object
> further. Apparently, unless you override one or more messages under the
> extension category *Newinspector, NewInspector will not know how to inspect
> your collection properly. Worse, as soon as you do implement those methods,
> unless you change their category, they will now be considered part of the
> *Newinspector package rather than the package your collection belongs to and
> will not be saved along with the collection.
>
> I think at a minimum, any collection understanding #do: and #size should be
> inspectable by NewInspector.


I agree. Maybe frederic can help.

Cheers

Mariano
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.gforge.inria.fr/pipermail/pharo-project/attachments/20101130/afad68ac/attachment.htm>


More information about the Pharo-project mailing list