Method: Chef::Resource#method_missing
- Defined in:
- lib/chef/resource.rb
permalink #method_missing(method_symbol, *args, &block) ⇒ Object
If an unknown method is invoked, determine whether the enclosing Provider’s lexical scope can fulfill the request. E.g. This happens when the Resource’s block invokes new_resource.
1341 1342 1343 1344 1345 1346 1347 |
# File 'lib/chef/resource.rb', line 1341 def method_missing(method_symbol, *args, &block) if enclosing_provider && enclosing_provider.respond_to?(method_symbol) enclosing_provider.send(method_symbol, *args, &block) else raise NoMethodError, "undefined method `#{method_symbol}' for #{self.class}" end end |