Module: Vident::Typed::Component
- Extended by:
- ActiveSupport::Concern
- Defined in:
- lib/vident/typed/component.rb
Instance Method Summary collapse
Instance Method Details
#initialize(attrs = {}) ⇒ Object
29 30 31 32 33 34 35 36 37 38 |
# File 'lib/vident/typed/component.rb', line 29 def initialize(attrs = {}) before_initialise(attrs) prepare_attributes(attrs) # The attributes need to also be set as ivars attributes.each do |attr_name, attr_value| instance_variable_set(self.class.attribute_ivar_names[attr_name], attr_value) end after_initialise super() end |