Module: Relax::Delegator::ClassMethods
- Defined in:
- lib/relax/delegator.rb
Instance Method Summary
collapse
Dynamic Method Handling
This class handles dynamic methods through the method_missing method
#method_missing(method, *args, &block) ⇒ Object
16
17
18
19
20
21
22
|
# File 'lib/relax/delegator.rb', line 16
def method_missing(method, *args, &block)
if client_instance.respond_to?(method)
client_instance.send(method, *args, &block)
else
super
end
end
|
Instance Method Details
#respond_to?(method, include_private = false) ⇒ Boolean
12
13
14
|
# File 'lib/relax/delegator.rb', line 12
def respond_to?(method, include_private=false)
super || client_instance.respond_to?(method, include_private)
end
|