Class: CDP::Timeline::Event
- Inherits:
-
Object
- Object
- CDP::Timeline::Event
- Defined in:
- lib/cdp/timeline/event.rb
Instance Attribute Summary collapse
-
#event_canceled_at ⇒ Object
Returns the value of attribute event_canceled_at.
-
#event_identifier ⇒ Object
Returns the value of attribute event_identifier.
-
#event_timestamp ⇒ Object
Returns the value of attribute event_timestamp.
-
#event_type ⇒ Object
Returns the value of attribute event_type.
-
#event_uuid ⇒ Object
Returns the value of attribute event_uuid.
-
#payload ⇒ Object
Returns the value of attribute payload.
Instance Method Summary collapse
- #==(o) ⇒ Object
- #eql?(o) ⇒ Boolean
-
#initialize(event_uuid: nil, event_identifier: nil, event_type: nil, event_timestamp: nil, event_canceled_at: nil, payload: nil) ⇒ Event
constructor
A new instance of Event.
- #to_hash ⇒ Object
Constructor Details
#initialize(event_uuid: nil, event_identifier: nil, event_type: nil, event_timestamp: nil, event_canceled_at: nil, payload: nil) ⇒ Event
Returns a new instance of Event.
11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 |
# File 'lib/cdp/timeline/event.rb', line 11 def initialize( event_uuid: nil, event_identifier: nil, event_type: nil, event_timestamp: nil, event_canceled_at: nil, payload: nil ) @event_uuid = event_uuid @event_identifier = event_identifier @event_type = event_type @event_timestamp = @event_canceled_at = event_canceled_at @payload = payload end |
Instance Attribute Details
#event_canceled_at ⇒ Object
Returns the value of attribute event_canceled_at.
8 9 10 |
# File 'lib/cdp/timeline/event.rb', line 8 def event_canceled_at @event_canceled_at end |
#event_identifier ⇒ Object
Returns the value of attribute event_identifier.
5 6 7 |
# File 'lib/cdp/timeline/event.rb', line 5 def event_identifier @event_identifier end |
#event_timestamp ⇒ Object
Returns the value of attribute event_timestamp.
7 8 9 |
# File 'lib/cdp/timeline/event.rb', line 7 def @event_timestamp end |
#event_type ⇒ Object
Returns the value of attribute event_type.
6 7 8 |
# File 'lib/cdp/timeline/event.rb', line 6 def event_type @event_type end |
#event_uuid ⇒ Object
Returns the value of attribute event_uuid.
4 5 6 |
# File 'lib/cdp/timeline/event.rb', line 4 def event_uuid @event_uuid end |
#payload ⇒ Object
Returns the value of attribute payload.
9 10 11 |
# File 'lib/cdp/timeline/event.rb', line 9 def payload @payload end |
Instance Method Details
#==(o) ⇒ Object
27 28 29 30 31 32 33 34 35 36 |
# File 'lib/cdp/timeline/event.rb', line 27 def ==(o) return true if self.equal?(o) self.class == o.class && event_uuid == o.event_uuid && event_identifier == o.event_identifier && == o. && event_canceled_at == o.event_canceled_at && event_type == o.event_type && payload == o.payload end |
#eql?(o) ⇒ Boolean
40 41 42 |
# File 'lib/cdp/timeline/event.rb', line 40 def eql?(o) self == o end |
#to_hash ⇒ Object
44 45 46 47 48 49 50 51 52 53 |
# File 'lib/cdp/timeline/event.rb', line 44 def to_hash { event_uuid: event_uuid, event_identifier: event_identifier, event_type: event_type, event_timestamp: , event_canceled_at: event_canceled_at, payload: payload, } end |