Class: MessageQuickly::Messaging::Event

Inherits:
Base
  • Object
show all
Defined in:
lib/message_quickly/messaging/event.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(params = {}) ⇒ Event

Returns a new instance of Event.



7
8
9
10
11
12
# File 'lib/message_quickly/messaging/event.rb', line 7

def initialize(params = {})
  params.deep_symbolize_keys!
  @sender = Sender.new(params.delete(:sender)) if params.include?(:sender)
  @recipient = Recipient.new(params.delete(:recipient)) if params.include?(:recipient)
  super
end

Instance Attribute Details

#entryObject (readonly)

Returns the value of attribute entry.



5
6
7
# File 'lib/message_quickly/messaging/event.rb', line 5

def entry
  @entry
end

#recipientObject (readonly)

Returns the value of attribute recipient.



5
6
7
# File 'lib/message_quickly/messaging/event.rb', line 5

def recipient
  @recipient
end

#senderObject (readonly)

Returns the value of attribute sender.



5
6
7
# File 'lib/message_quickly/messaging/event.rb', line 5

def sender
  @sender
end

#timestampObject (readonly)

Returns the value of attribute timestamp.



5
6
7
# File 'lib/message_quickly/messaging/event.rb', line 5

def timestamp
  @timestamp
end