Class: TTK::Services::MonitorClient

Inherits:
DRbService show all
Defined in:
lib/ttk/services/MonitorClient.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from DRbService

#stop_service, #update

Constructor Details

#initialize(config = {}) ⇒ MonitorClient

Returns a new instance of MonitorClient.



13
14
15
16
# File 'lib/ttk/services/MonitorClient.rb', line 13

def initialize(config={})
  @client = nil
  super(config)
end

Instance Attribute Details

#clientObject (readonly)

Returns the value of attribute client.



18
19
20
# File 'lib/ttk/services/MonitorClient.rb', line 18

def client
  @client
end

Instance Method Details

#start_service(uri, monitor_uri) ⇒ Object



20
21
22
23
24
# File 'lib/ttk/services/MonitorClient.rb', line 20

def start_service(uri, monitor_uri)
  super(uri)
  monitor = DRbObject.new_with_uri(monitor_uri.to_s)
  @client = Monitors::Client.new(self, monitor)
end