Class: ConfigOMat::LoadedProfile
- Inherits:
-
ConfigItem
- Object
- ConfigItem
- ConfigOMat::LoadedProfile
- Extended by:
- Forwardable
- Defined in:
- lib/config_o_mat/shared/types.rb
Instance Attribute Summary collapse
-
#loaded_profile_data ⇒ Object
readonly
Returns the value of attribute loaded_profile_data.
-
#secrets ⇒ Object
readonly
Returns the value of attribute secrets.
Attributes inherited from ConfigItem
Instance Method Summary collapse
- #eql?(other) ⇒ Boolean
- #hash ⇒ Object
-
#initialize(loaded_profile_data, secrets) ⇒ LoadedProfile
constructor
A new instance of LoadedProfile.
- #to_h ⇒ Object
- #validate ⇒ Object
Methods inherited from ConfigItem
#==, #error, #errors?, #validate!
Constructor Details
#initialize(loaded_profile_data, secrets) ⇒ LoadedProfile
Returns a new instance of LoadedProfile.
467 468 469 470 471 472 |
# File 'lib/config_o_mat/shared/types.rb', line 467 def initialize(loaded_profile_data, secrets) @loaded_profile_data = loaded_profile_data @secrets = secrets || {} @errors = @loaded_profile_data.errors if @loaded_profile_data.errors? end |
Instance Attribute Details
#loaded_profile_data ⇒ Object (readonly)
Returns the value of attribute loaded_profile_data.
463 464 465 |
# File 'lib/config_o_mat/shared/types.rb', line 463 def loaded_profile_data @loaded_profile_data end |
#secrets ⇒ Object (readonly)
Returns the value of attribute secrets.
463 464 465 |
# File 'lib/config_o_mat/shared/types.rb', line 463 def secrets @secrets end |
Instance Method Details
#eql?(other) ⇒ Boolean
485 486 487 488 489 |
# File 'lib/config_o_mat/shared/types.rb', line 485 def eql?(other) return false if !super(other) return false if other.loaded_profile_data != @loaded_profile_data || other.secrets != @secrets true end |
#hash ⇒ Object
477 478 479 |
# File 'lib/config_o_mat/shared/types.rb', line 477 def hash @loaded_profile_data.hash ^ @secrets.hash end |
#to_h ⇒ Object
481 482 483 |
# File 'lib/config_o_mat/shared/types.rb', line 481 def to_h contents end |
#validate ⇒ Object
474 475 |
# File 'lib/config_o_mat/shared/types.rb', line 474 def validate end |