commercial(y=-4712, w=1, d=1, sg=ITALY)public
Monday is day-of-week 1; Sunday is day-of-week 7.
w and d can be negative, in which case they count backwards from the end of the year and the end of the week respectively. No wraparound is performed, however, and invalid values cause an ArgumentError to be raised.
y defaults to -4712, w to 1, and d to 1; this is Julian Day Number day 0.
sg specifies the Day of Calendar Reform.
# File lib/date.rb, line 830 def self.commercial(y=-4712, w=1, d=1, sg=ITALY) unless jd = _valid_commercial?(y, w, d, sg) raise ArgumentError, 'invalid date' end new!(jd_to_ajd(jd, 0, 0), 0, sg) end