Module: Metaractor::Delegation
- Defined in:
- lib/metaractor/delegation.rb
Instance Method Summary
collapse
Dynamic Method Handling
This class handles dynamic methods through the method_missing method
#method_missing(name) ⇒ Object
8
9
10
11
12
13
14
|
# File 'lib/metaractor/delegation.rb', line 8
def method_missing(name, ...)
if context.has_key?(name)
context.public_send(name, ...)
else
super
end
end
|
Instance Method Details
#respond_to_missing?(name, include_private = false) ⇒ Boolean
3
4
5
6
|
# File 'lib/metaractor/delegation.rb', line 3
def respond_to_missing?(name, include_private = false)
return false if name == :marshal_dump || name == :_dump
context.has_key?(name) || super
end
|