module OptionsHash::MethodObject::InstanceMethods
Attributes
options[R]
Public Class Methods
new(options={})
click to toggle source
# File lib/options_hash/method_object.rb, line 37 def initialize options={} @options = self.class.options.parse(options) end
Public Instance Methods
given?(key)
click to toggle source
# File lib/options_hash/method_object.rb, line 47 def given? key options.given? key end
method_missing(method, *args, &block)
click to toggle source
# File lib/options_hash/method_object.rb, line 42 def method_missing method, *args, &block return options[method] if options.keys.include?(method) raise NoMethodError, "undefined method `#{method}'", caller(1) end