From: Adrian Klingel Date: 2009-02-22T03:28:29+09:00 Subject: Re: How to call a module method dynamically Tom Link wrote: >> I can just pass the job name (i.e. the name of the module method) > > Couldn't you also pass a block? > > do_something {Foo::Bar.mymethod} > > You can get the method object via instance_method but then you have an > unbound method. Or you could turn that method into a module_function > which you could invoke via MyModule.send(:mymethod). But IMHO that's > weird. Even weirder is monkey-patching Object with my module so I can just use "send", which is what I did. -- Posted via http://www.ruby-forum.com/.