Class: ECMBlockchain::CustomAttribute
- Inherits:
-
Object
- Object
- ECMBlockchain::CustomAttribute
- Includes:
- ActiveModel::Validations
- Defined in:
- lib/ecm-blockchain-api/models/custom_attribute.rb
Instance Attribute Summary collapse
-
#name ⇒ Object
Returns the value of attribute name.
-
#value ⇒ Object
Returns the value of attribute value.
Instance Method Summary collapse
-
#initialize(data = {}) ⇒ CustomAttribute
constructor
A new instance of CustomAttribute.
Constructor Details
#initialize(data = {}) ⇒ CustomAttribute
Returns a new instance of CustomAttribute.
12 13 14 15 |
# File 'lib/ecm-blockchain-api/models/custom_attribute.rb', line 12 def initialize(data = {}) @name = data.fetch(:name) @value = data.fetch(:value) end |
Instance Attribute Details
#name ⇒ Object
Returns the value of attribute name.
7 8 9 |
# File 'lib/ecm-blockchain-api/models/custom_attribute.rb', line 7 def name @name end |
#value ⇒ Object
Returns the value of attribute value.
7 8 9 |
# File 'lib/ecm-blockchain-api/models/custom_attribute.rb', line 7 def value @value end |