Class: Marver::KeyDate
- Inherits:
-
Object
- Object
- Marver::KeyDate
- Defined in:
- lib/marver/entities/key_date.rb
Instance Attribute Summary collapse
-
#date ⇒ Object
readonly
Returns the value of attribute date.
-
#type ⇒ Object
readonly
Returns the value of attribute type.
Instance Method Summary collapse
-
#initialize(json) ⇒ KeyDate
constructor
A new instance of KeyDate.
Constructor Details
#initialize(json) ⇒ KeyDate
Returns a new instance of KeyDate.
5 6 7 8 |
# File 'lib/marver/entities/key_date.rb', line 5 def initialize(json) @type = json['type'] @date = Date.parse(json['date']) end |
Instance Attribute Details
#date ⇒ Object (readonly)
Returns the value of attribute date.
3 4 5 |
# File 'lib/marver/entities/key_date.rb', line 3 def date @date end |
#type ⇒ Object (readonly)
Returns the value of attribute type.
3 4 5 |
# File 'lib/marver/entities/key_date.rb', line 3 def type @type end |