Class: Evntaly::Event
- Inherits:
-
Object
- Object
- Evntaly::Event
- Defined in:
- lib/evntaly/event.rb
Instance Attribute Summary collapse
-
#apply_rule_only ⇒ Object
Returns the value of attribute apply_rule_only.
-
#data ⇒ Object
Returns the value of attribute data.
-
#description ⇒ Object
Returns the value of attribute description.
-
#feature ⇒ Object
Returns the value of attribute feature.
-
#icon ⇒ Object
Returns the value of attribute icon.
-
#message ⇒ Object
Returns the value of attribute message.
-
#notify ⇒ Object
Returns the value of attribute notify.
-
#session_id ⇒ Object
Returns the value of attribute session_id.
-
#tags ⇒ Object
Returns the value of attribute tags.
-
#title ⇒ Object
Returns the value of attribute title.
-
#topic ⇒ Object
Returns the value of attribute topic.
-
#type ⇒ Object
Returns the value of attribute type.
-
#user ⇒ Object
Returns the value of attribute user.
Instance Method Summary collapse
-
#initialize(title:, description:, message:, data:, tags:, notify:, icon:, apply_rule_only:, user:, type:, session_id:, feature:, topic:) ⇒ Event
constructor
A new instance of Event.
- #to_json(*_args) ⇒ Object
Constructor Details
#initialize(title:, description:, message:, data:, tags:, notify:, icon:, apply_rule_only:, user:, type:, session_id:, feature:, topic:) ⇒ Event
Returns a new instance of Event.
6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 |
# File 'lib/evntaly/event.rb', line 6 def initialize(title:, description:, message:, data:, tags:, notify:, icon:, apply_rule_only:, user:, type:, session_id:, feature:, topic:) @title = title @description = description = @data = data = @notify = notify @icon = icon @apply_rule_only = apply_rule_only @user = user @type = type @session_id = session_id @feature = feature @topic = topic end |
Instance Attribute Details
#apply_rule_only ⇒ Object
Returns the value of attribute apply_rule_only.
3 4 5 |
# File 'lib/evntaly/event.rb', line 3 def apply_rule_only @apply_rule_only end |
#data ⇒ Object
Returns the value of attribute data.
3 4 5 |
# File 'lib/evntaly/event.rb', line 3 def data @data end |
#description ⇒ Object
Returns the value of attribute description.
3 4 5 |
# File 'lib/evntaly/event.rb', line 3 def description @description end |
#feature ⇒ Object
Returns the value of attribute feature.
3 4 5 |
# File 'lib/evntaly/event.rb', line 3 def feature @feature end |
#icon ⇒ Object
Returns the value of attribute icon.
3 4 5 |
# File 'lib/evntaly/event.rb', line 3 def icon @icon end |
#message ⇒ Object
Returns the value of attribute message.
3 4 5 |
# File 'lib/evntaly/event.rb', line 3 def end |
#notify ⇒ Object
Returns the value of attribute notify.
3 4 5 |
# File 'lib/evntaly/event.rb', line 3 def notify @notify end |
#session_id ⇒ Object
Returns the value of attribute session_id.
3 4 5 |
# File 'lib/evntaly/event.rb', line 3 def session_id @session_id end |
#tags ⇒ Object
Returns the value of attribute tags.
3 4 5 |
# File 'lib/evntaly/event.rb', line 3 def end |
#title ⇒ Object
Returns the value of attribute title.
3 4 5 |
# File 'lib/evntaly/event.rb', line 3 def title @title end |
#topic ⇒ Object
Returns the value of attribute topic.
3 4 5 |
# File 'lib/evntaly/event.rb', line 3 def topic @topic end |
#type ⇒ Object
Returns the value of attribute type.
3 4 5 |
# File 'lib/evntaly/event.rb', line 3 def type @type end |
#user ⇒ Object
Returns the value of attribute user.
3 4 5 |
# File 'lib/evntaly/event.rb', line 3 def user @user end |
Instance Method Details
#to_json(*_args) ⇒ Object
22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 |
# File 'lib/evntaly/event.rb', line 22 def to_json(*_args) { title: @title, description: @description, message: , data: @data, tags: , notify: @notify, icon: @icon, apply_rule_only: @apply_rule_only, user: @user, type: @type, session_id: @session_id, feature: @feature, topic: @topic }.to_json end |