Module: Temple::Mixins::Options
Instance Attribute Summary collapse
- #options ⇒ Object readonly
Class Method Summary collapse
Instance Method Summary collapse
Instance Attribute Details
#options ⇒ Object (readonly)
79 80 81 |
# File 'lib/temple/mixins/options.rb', line 79 def @options end |
Class Method Details
.included(base) ⇒ Object
72 73 74 75 76 77 |
# File 'lib/temple/mixins/options.rb', line 72 def self.included(base) base.class_eval do extend ClassOptions extend ThreadOptions end end |
Instance Method Details
#initialize(opts = {}) ⇒ Object
81 82 83 84 85 |
# File 'lib/temple/mixins/options.rb', line 81 def initialize(opts = {}) self.class..validate_map!(opts) self.class..validate_map!(self.class.) if self.class. @options = ImmutableMap.new({}.update(self.class.).update(self.class. || {}).update(opts)) end |