[Seaside] Smalltalk question
Mart-Mari Breedt
breedt_m at aircom.co.za
Fri Aug 5 16:44:51 CEST 2005
Hi,
I believe this should work:
controller := ((Smalltalk at: (classname asSymbol)) new.
Best regards,
Mart-Mari
-----Original Message-----
From: Dmitry Dorofeev [mailto:dima-sender-3c337a at yasp.com]
Sent: 05 Augustus 2005 04:42 nm
To: The Squeak Enterprise Aubergines Server - general discussion.
Subject: [Seaside] Smalltalk question
Hi all.
I'd like to create an instance of class by knowing only a class name.
something like this:
classname := anObject class asString , 'Controller'.
"expect something like FSBlockListController in a classname"
controller := Smalltalk giveMeInstanceOf: classname.
"expect result of /FSBlockListController new/ in controller"
I know it should be possible in Squeak in one line of code,
but i am still a newbie...
Thank you very much.
-Dmitry.
_______________________________________________
Seaside mailing list
Seaside at lists.squeakfoundation.org
http://lists.squeakfoundation.org/listinfo/seaside
More information about the Seaside
mailing list