Sept. 11, 2012
8:32 p.m.
read Smalltalk by Example book of alec sharp Stef On Sep 11, 2012, at 8:36 PM, sergio_101 wrote:
yes, i know this sounds simple.. but is it possible to instantiate an object with some parameters?
say i have a dictionary:
params := Dictionary new. params at: 'sound' put: 'bark'
dog := Dog new.
^^ at this point, i would like to just create a dog and send it 'params' all at once..
can i do this? what would the syntax look like?
thanks!
-- ---- peace, sergio photographer, journalist, visionary
http://www.ThoseOptimizeGuys.com http://www.CodingForHire.com http://www.coffee-black.com http://www.painlessfrugality.com http://www.twitter.com/sergio_101 http://www.facebook.com/sergio101