Class: Line::Bot::Event::Things

Inherits:
Base
  • Object
show all
Defined in:
lib/line/bot/event/things.rb

Instance Method Summary collapse

Methods inherited from Base

#[], #initialize

Constructor Details

This class inherits a constructor from Line::Bot::Event::Base

Instance Method Details

#device_idObject



32
33
34
# File 'lib/line/bot/event/things.rb', line 32

def device_id
  @src['things']['deviceId']
end

#typeObject



26
27
28
29
30
# File 'lib/line/bot/event/things.rb', line 26

def type
  Line::Bot::Event::ThingsType.const_get(Line::Bot::Util.camelize(@src['things']['type']))
rescue NameError
  Line::Bot::Event::ThingsType::Unsupport
end