My doubt is how create objects by reflection, when they need more than
one argument. Given that I need to create them based on array.


def build(instance,clazz,args)
 if args == nil
  @instances[instance] = Object.const_get(clazz).new
 else
  @instances[instance] = Object.const_get(clazz).new(args[0])
 end
end

And how about to

build "int0","Person",["name",]

Since the Person is:

class Person
 attr_accessor :name, :surname
 def initialize(name,surname)
  @name = name
  @surname = surname
 end
end

--
leandro moreira - leandromoreira.com.br

-- 
Posted via http://www.ruby-forum.com/.