class PunchTime::Configuration
Constants
- Raw
Attributes
breaks[RW]
night[RW]
offset[RW]
raw[RW]
shift_in_time[RW]
shift_out_time[RW]
Public Class Methods
new() { |raw| ... }
click to toggle source
# File lib/punch_time/configuration.rb, line 23 def initialize self.raw = Raw.new yield raw if block_given? self.shift_in_time ||= raw.shift_in_time self.shift_out_time ||= raw.shift_out_time self.night ||= raw.night self.breaks ||= raw.breaks self.offset ||= raw.offset raise ArgumentError, errors.messages unless valid? raw.freeze end