Speaking the Lingo

First, A Workflow Model

class Queue
  def initialize(name) ... end
  def to_sql ... end
end
class Alternative
  def initialize(code, next_step) ... end
  def to_sql ... end
end
class Step
  def initialize(queue) ... end
  def add(alternative) ... end
  def to_sql ... end
end
class Route
  def initialize(name) ... end
  def add(step) ... end
  def to_sql ... end
end