Methods
Public Class
Public Instance
Attributes
message | [R] | |
message_type | [R] | |
sent | [R] |
Public Class methods
new
(params)
[show source]
# File lib/gnip_api/gnip/system_message.rb, line 5 def initialize params @raw = params @message_type = params.keys.first @message = params['message'] @sent = params['sent'] end
Public Instance methods
log!
()
[show source]
# File lib/gnip_api/gnip/system_message.rb, line 31 def log! GnipApi.logger.warn "System Message Received: #{message_type} -- #{message} at #{sent}" end
log_method
()
[show source]
# File lib/gnip_api/gnip/system_message.rb, line 19 def log_method @message_type.to_sym end
original_attributes
()
[show source]
# File lib/gnip_api/gnip/system_message.rb, line 12 def original_attributes { @message_type => @message, :sent => @sent } end
to_json
()
[show source]
# File lib/gnip_api/gnip/system_message.rb, line 27 def to_json @raw.to_json end