S
shaw.cttk
Hi, I'm super new in Ruby World, and got in trouble with that:
how do I call the 'new' method of a class I don't know the name? The name of the class is stored in a string.
something like:
arg1 = "RADIUS"
codec = arg1.new
I would like to create an instance of whatever class name is stored in arg1 string.
Thanks in advance.
-- sfim
how do I call the 'new' method of a class I don't know the name? The name of the class is stored in a string.
something like:
arg1 = "RADIUS"
codec = arg1.new
I would like to create an instance of whatever class name is stored in arg1 string.
Thanks in advance.
-- sfim