Sha256: e6bcbbbd33170e4947afce3732029156b34ae59c10e409412a65c5cf9483ac81

Contents?: true

Size: 288 Bytes

Versions: 2

Compression:

Stored size: 288 Bytes

Contents

module Scheduling
class RegularSchedule < Struct.new(:regularity, :date_range)
  def occurances date_range
    occurances = []
    overlap = self.date_range & date_range
    unless overlap.nil?
      occurances = regularity.occurances(overlap)
    end
    return occurances
  end
end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
scheduling-0.1.2 lib/scheduling/schedule/regular_schedule.rb
scheduling-0.1.1 lib/scheduling/schedule/regular_schedule.rb