class DAF::DynamicActionDaemon

This class represents the Dynamic Action Daemon it requires a set of commands to be passed in

Public Class Methods

new(commands) click to toggle source

Initializes DAD with a given command set

@param commands [Array] Array containing Command objects

# File lib/daf.rb, line 39
def initialize(commands)
  @commands = commands
end

Public Instance Methods

start() click to toggle source

Starts the daemon - this method will block for duration of execution of program

# File lib/daf.rb, line 45
def start
  @commands.each(&:execute)
  sleep
end