Class: MindMeld::Tv

Inherits:
Device show all
Defined in:
lib/mind_meld/tv.rb

Instance Method Summary collapse

Methods inherited from Device

#add_statistics, #clear_state, #create_action, #device_details, #hive_queues, #id, #name, #poll, #register, #send_screenshot, #set_state

Methods inherited from MindMeld

#add_statistics, #devices, #flush_statistics

Constructor Details

#initialize(options) ⇒ Tv

Returns a new instance of Tv.



4
5
6
7
# File 'lib/mind_meld/tv.rb', line 4

def initialize options
  options[:device][:device_type] ||= 'Tv'
  super options
end

Instance Method Details

#set_application(application) ⇒ Object



9
10
11
12
13
14
15
16
17
# File 'lib/mind_meld/tv.rb', line 9

def set_application application
  request :put, 'plugin/tv/set_application',
    {
      device: {
          id: device_details['id'],
          application: application
      }
    }
end