module IceCube::Validations::DayOfYear
Public Instance Methods
day_of_year(*days)
click to toggle source
# File lib/ice_cube/validations/day_of_year.rb, line 5 def day_of_year(*days) days.flatten.each do |day| unless day.is_a?(Integer) raise ArgumentError, "expecting Integer value for day, got #{day.inspect}" end validations_for(:day_of_year) << Validation.new(day) end clobber_base_validations(:month, :day, :wday) self end