Class: AtlasEngine::CountryProfileSubsetBase
- Inherits:
-
Object
- Object
- AtlasEngine::CountryProfileSubsetBase
- Extended by:
- T::Sig
- Defined in:
- app/models/atlas_engine/country_profile_subset_base.rb
Direct Known Subclasses
CountryProfileIngestionSubset, CountryProfileValidationSubset
Instance Attribute Summary collapse
-
#attributes ⇒ Object
readonly
Returns the value of attribute attributes.
Instance Method Summary collapse
-
#initialize(hash:) ⇒ CountryProfileSubsetBase
constructor
A new instance of CountryProfileSubsetBase.
Constructor Details
#initialize(hash:) ⇒ CountryProfileSubsetBase
Returns a new instance of CountryProfileSubsetBase.
12 13 14 15 16 17 18 19 20 |
# File 'app/models/atlas_engine/country_profile_subset_base.rb', line 12 def initialize(hash:) @attributes = hash attributes.keys.each do |key| define_singleton_method(key.to_s) do @attributes[key] end unless respond_to?(key.to_s) end end |
Instance Attribute Details
#attributes ⇒ Object (readonly)
Returns the value of attribute attributes.
9 10 11 |
# File 'app/models/atlas_engine/country_profile_subset_base.rb', line 9 def attributes @attributes end |