This class describes a leave.
This Hash defines the supported leave types. It maps the symbol to its index. The index sequence is important when multiple leaves are defined for the same time slot. A subsequent definition with a type with a larger index will override the old leave type.
Create a new Leave object. interval should be an Interval describing the leave period. type must be one of the supported leave types (:holiday, :annual, :special, :unpaid, :sick and :project ). The reason is an optional String that describes the leave reason.
# File lib/taskjuggler/LeaveList.rb, line 36 def initialize(type, interval, reason = nil) unless Types[type] raise ArgumentError, "Unsupported leave type #{type}" end @type = type @interval = interval @reason = reason end
Generated with the Darkfish Rdoc Generator 2.