From: Ian Macdonald Date: 2002-04-10T16:26:37+09:00 Subject: why do the methods from my mixed-in module disappear? Have a look at this piece of code: module Foo require 'soap/driver' class Search include SOAP attr_reader :key def initialize(k) Endpoint = 'http://www.foo.com/foobar/' Ns = 'urn:fooService' @key = k a = SOAP::Driver.new(nil, nil, Ns, Endpoint) puts a.methods end end end In the above Foo module, I'm mixing SOAP into my Search class. The call to puts is there to verify that all the expected methods associated with the SOAP object are available to me. The SOAP object is then returned to the caller. The calling code looks like this: require 'foo' key = 'abc123' f = Foo::Search.new(key) puts f.methods Here, however, the call to puts does _not_ display the same list of methods as the call to puts in the constructor. My question is: why are the SOAP object's methods not passed back when returning from the constructor method? I would expect the mix-in of SOAP to make these methods available in the caller. Clearly, I'm misunderstanding something. Ian -- Ian Macdonald | Chicago law prohibits eating in a place ian@caliban.org | that is on fire. | | |