Class: Goraku::Client
- Inherits:
-
Object
- Object
- Goraku::Client
- Includes:
- Authentication, Log, Program, Recorded, Recording, Reserves, Rules, Schedule, Scheduler, Status, Storage, Configurable
- Defined in:
- lib/goraku/client.rb,
lib/goraku/client/log.rb,
lib/goraku/client/rules.rb,
lib/goraku/client/status.rb,
lib/goraku/client/program.rb,
lib/goraku/client/storage.rb,
lib/goraku/client/recorded.rb,
lib/goraku/client/reserves.rb,
lib/goraku/client/schedule.rb,
lib/goraku/client/recording.rb,
lib/goraku/client/scheduler.rb
Defined Under Namespace
Modules: Log, Program, Recorded, Recording, Reserves, Rules, Schedule, Scheduler, Status, Storage
Instance Attribute Summary
Attributes included from Configurable
#api_endpoint, #connection_options, #login, #middleware, #password, #proxy
Instance Method Summary collapse
- #delete(path, options = {}) ⇒ Object
- #get(path, options = {}) ⇒ Object
-
#initialize(options = {}) ⇒ Client
constructor
A new instance of Client.
- #inspect ⇒ Object
- #put(path, options = {}) ⇒ Object
- #root ⇒ Object
Methods included from Storage
Methods included from Status
Methods included from Scheduler
#exec_scheduler, #force_scheduler, #scheduler
Methods included from Schedule
#schedule, #schedule_broadcasting, #schedule_channel, #schedule_channel_broadcasting, #schedule_channel_programs, #schedule_programs
Methods included from Rules
#add_rule, #delete_rule, #rule, #rule_disable, #rule_enable, #rules, #update_rule
Methods included from Reserves
#delete_reserved_program, #reserves, #reserves_program, #skip_reserved_program, #unskip_reserved_program
Methods included from Recording
#recording, #recording_program, #recording_program_preview, #stop_recording_program, #watch_recording_program
Methods included from Recorded
#delete_recorded_program, #recorded, #recorded_program, #recorded_program_file, #recorded_program_preview, #watch_recorded_program
Methods included from Program
Methods included from Log
#operator_log, #scheduler_log, #wui_log
Methods included from Authentication
Methods included from Configurable
Constructor Details
#initialize(options = {}) ⇒ Client
Returns a new instance of Client.
34 35 36 37 38 |
# File 'lib/goraku/client.rb', line 34 def initialize( = {}) Configurable.keys.each do |key| instance_variable_set(:"@#{key}", [key] || Goraku.instance_variable_get(:"@#{key}")) end end |
Instance Method Details
#delete(path, options = {}) ⇒ Object
48 49 50 |
# File 'lib/goraku/client.rb', line 48 def delete(path, = {}) request :delete, path, end |
#get(path, options = {}) ⇒ Object
40 41 42 |
# File 'lib/goraku/client.rb', line 40 def get(path, = {}) request :get, path, end |
#inspect ⇒ Object
56 57 58 59 |
# File 'lib/goraku/client.rb', line 56 def inspect inspected = super inspected.gsub! @password, "*****" if @password end |
#put(path, options = {}) ⇒ Object
44 45 46 |
# File 'lib/goraku/client.rb', line 44 def put(path, = {}) request :put, path, end |
#root ⇒ Object
52 53 54 |
# File 'lib/goraku/client.rb', line 52 def root get '/' end |