Class: RussianWorkdays::Year

Inherits:
CollectionPreset show all
Defined in:
lib/russian_workdays/year.rb

Instance Method Summary collapse

Constructor Details

#initialize(year = Date.today.year) ⇒ Year

Returns a new instance of Year.



7
8
9
# File 'lib/russian_workdays/year.rb', line 7

def initialize(year = Date.today.year)
  @dates = Collection.new(Date.new(year, 1, 1)..Date.new(year, 12, -1))
end