Class: RRule::Monthly

Inherits:
Frequency show all
Defined in:
lib/rrule/frequencies/monthly.rb

Instance Attribute Summary

Attributes inherited from Frequency

#current_date

Instance Method Summary collapse

Methods inherited from Frequency

#advance, #initialize

Constructor Details

This class inherits a constructor from RRule::Frequency

Instance Method Details

#possible_daysObject



3
4
5
6
# File 'lib/rrule/frequencies/monthly.rb', line 3

def possible_days
  # yday is 1-indexed, need results 0-indexed
  (current_date.beginning_of_month.yday - 1..current_date.end_of_month.yday - 1).to_a
end