[squeak-dev] How to use pool dictionaries in a workspace?

Bob Arning arning315 at comcast.net
Tue Mar 5 20:01:38 UTC 2013


On 3/5/13 2:51 PM, Louis LaBrunda wrote:
> Hi Bob,
>
>> Have you tried
>> Workspace addLookupPool: MyPool?
> Thanks, that works great although the #removeLookupPool: doesn't seem to
> turn it off but I'm not sure I care.
What did you write to add the pool to the workspace lookups?
>
>> Although I wonder why one would go to the trouble. Why not just put the
>> code in a method that can reference the pool normally?
> One could say that about anything you might want to play with in a
> workspace.
I'm not opposed to workspaces, but when you are spending energy to make 
a workspace do what a class & method will already provide, seems like 
re-inventing the wheel.
> As I said, I often work up code in a workspace and then copy it
> to a method when I'm happy with it.  If I can't use pool references in the
> workspace, I then have to change things when I want to make a real method.
I don't understand this part. If you put it in a method from the start, 
then when it works, you're done.

Oh, any any guesses what Thunderbird thinks your name really is? ;-)

>
> Thanks again for the help.
>
> Lou
>
>> On 3/5/13 1:56 PM, Louis LaBrunda wrote:
>>> Hi,
>>>
>>> When I want to use values defined in a pool dictionary in VA Smalltalk, I
>>> put the following lines at the top of the workspace (I often save
>>> workspaces for repeat use):
>>>
>>> "
>>> EtWindow defaultEvaluationPools: (EtWindow defaultEvaluationPools asSet
>>> addAll: #(#PoolDictionaryName)) asArray.
>>> EtWindow defaultEvaluationPools: nil.
>>> "
>>>
>>> If I execute the first line (not counting the comment " line and not
>>> wrapped) The named pool dictionary is available to the workspace.  I can
>>> test code as if the pool dictionary were specified for the class and I was
>>> writing a method.  This way when I'm happy with the code, I can just copy
>>> it to a method and use it as is.  The second line puts things back the way
>>> it was.
>>>
>>> I would love to be able to do this with Squeak.  Does anyone have any idea
>>> how to do this with Squeak?  Or point me in the right direction?
>>>
>>> Lou
>>> -----------------------------------------------------------
>>> Louis LaBrunda
>>> Keystone Software Corp.
>>> SkypeMe callto://PhotonDemon
>>> mailto:Lou at Keystone-Software.com http://www.Keystone-Software.com
>>>
>>>
>>>
> -----------------------------------------------------------
> Louis LaBrunda
> Keystone Software Corp.
> SkypeMe callto://PhotonDemon
> mailto:Lou at Keystone-Software.com http://www.Keystone-Software.com
>
>
>



More information about the Squeak-dev mailing list