10 # Create a new instance that is ready for use by a configuration file
11 def initialize(options = {})
13 self.server = Server.new(self, options[:host], options[:port])
16 # Instantiate a new, empty Watch object and pass it to the mandatory
17 # block. The attributes of the watch will be set by the configuration
23 # ensure the new watch has a unique name
24 unless @watches.select { |x| x.name == w.name }.empty?
25 abort "Duplicate Watch with name '#{w.name}'"
28 # add to list of watches
32 # Schedule all poll conditions and register all condition events
34 @watches.each { |w| w.monitor }