From: "Søren Andersen" Date: 2007-10-25T01:17:14+09:00 Subject: Re: Passing methods as parameters - the nice way? ------=_Part_6475_28980010.1193242635084 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Content-Disposition: inline Doh, ofc. I should have figured that out myself. Thank you! Regards, S=F8ren On 10/24/07, Vasyl Smirnov wrote: > > > > On Oct 24, 6:31 pm, "S=F8ren Andersen" wrote: > > interface.set_action(:foo) > > interface.call_action =3D> foo called > > > > but, how do I handle it if the method is an instance method on some > object? > > program =3D Program.new > > interface.set_action(:program.foo)? > > No variant of this works for me. > > > You should pass the target object to the interface as well, and then > do "my_obj.send(an_instance_method_foo)" > > > ------=_Part_6475_28980010.1193242635084--