Class: Hackle::EventType
- Inherits:
-
Object
- Object
- Hackle::EventType
- Defined in:
- lib/hackle/models/event_type.rb
Instance Attribute Summary collapse
-
#id ⇒ Object
readonly
Returns the value of attribute id.
-
#key ⇒ Object
readonly
Returns the value of attribute key.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(id:, key:) ⇒ EventType
constructor
A new instance of EventType.
Constructor Details
#initialize(id:, key:) ⇒ EventType
Returns a new instance of EventType.
5 6 7 8 |
# File 'lib/hackle/models/event_type.rb', line 5 def initialize(id:, key:) @id = id @key = key end |
Instance Attribute Details
#id ⇒ Object (readonly)
Returns the value of attribute id.
3 4 5 |
# File 'lib/hackle/models/event_type.rb', line 3 def id @id end |
#key ⇒ Object (readonly)
Returns the value of attribute key.
3 4 5 |
# File 'lib/hackle/models/event_type.rb', line 3 def key @key end |
Class Method Details
.undefined(key:) ⇒ Object
10 11 12 |
# File 'lib/hackle/models/event_type.rb', line 10 def self.undefined(key:) EventType.new(id: 0, key: key) end |