From: Robert Dober Date: 2007-06-16T05:05:59+09:00 Subject: Re: Using extend for initialization settings? On 6/15/07, Gregory Brown wrote: > On 6/15/07, Trans wrote: > > > > f = Foo.new(Container) > > > > f.report > > class Foo; end > > f = Foo.new > f.extend(Container) > > > I don't get what this is getting me over plain ruby? Hmm control maybe, you are not forcing anybody to call f.extend(Container) in your approach. Tom's approach would allow you to exercise some control about instantiation e.g. def initialize(settings) check about settings. I however miss the point of #to_module ? What is that good for.... would you mind to explain please. Cheers Robert > > -- You see things; and you say Why? But I dream things that never were; and I say Why not? -- George Bernard Shaw