Squeak programming question

kpgrant at mindspring.com kpgrant at mindspring.com
Mon Mar 22 12:49:22 UTC 1999


Quick programming question from a Squeak/Smalltalk newbie:
 
Is there any elegant method for handling occasions when you
wish a method to return multiple objects?  I'm writing a
method that will return a set and a dictionary to the
caller.  I can't reasonably break up the method into two
methods (one for each kind of data), and the contents of
the set and dictionary are unrelated enough that it seems
silly to make a whole new class of object containing nothing
but pointers to each.  The only thing that occurs to me is
something like:
 
^((OrderedCollection new) add: myDictionary add: mySet)

and then disassemble the thing on the receiving side.  I'm
not really crazy about this though.

Re the discussion about turning this mailing list into a
newsgroup.  At the very least it would be nice if the
mailing list were split up into sub-lists based on topic.
There is a lot of traffic on the list that people like me,
who aren't far enough along to even think about making
improvements to the current environment, can't begin to
follow.  At the same time it seems kind of silly to post
a "how do I do this in Squeak" kind of question to the
whole list.  A sub-list dedicated to programming questions
would be nice.

Thanks,
Kevin





More information about the Squeak-dev mailing list