new

Date.new([year=-4712[, month=1[, mday=1[, start=Date::ITALY]]]]) â date Class Public methods Creates a date object denoting the given calendar date. In this class, BCE years are counted astronomically. Thus, the year before the year 1 is the year zero, and the year preceding the year zero is the year -1. The month and the day of month should be a negative or a positive number (as a relative month/day from the end of year/month when negative). They should not be zero. The las

leap?

Date.leap?(year) â bool Class Public methods Returns true if the given year is a leap year of the proleptic Gregorian calendar. Date.gregorian_leap?(1900) #=> false Date.gregorian_leap?(2000) #=> true

julian_leap?

Date.julian_leap?(year) â bool Class Public methods Returns true if the given year is a leap year of the proleptic Julian calendar. Date.julian_leap?(1900) #=> true Date.julian_leap?(1901) #=> false

json_create

json_create(object) Class Public methods Deserializes JSON string by converting Julian year y, month m, day d and Day of Calendar Reform sg to Date.

jisx0301

Date.jisx0301(string='-4712-01-01'[, start=ITALY]) â date Class Public methods Creates a new Date object by parsing from a string according to some typical JIS X 0301 formats. Date.jisx0301('H13.02.03') #=> #<Date: 2001-02-03 ...>

jd

Date.jd([jd=0[, start=Date::ITALY]]) â date Class Public methods Creates a date object denoting the given chronological Julian day number. Date.jd(2451944) #=> #<Date: 2001-02-03 ...> Date.jd(2451945) #=> #<Date: 2001-02-04 ...> Date.jd(0) #=> #<Date: -4712-01-01 ...> See also new.

iso8601

Date.iso8601(string='-4712-01-01'[, start=ITALY]) â date Class Public methods Creates a new Date object by parsing from a string according to some typical ISO 8601 formats. Date.iso8601('2001-02-03') #=> #<Date: 2001-02-03 ...> Date.iso8601('20010203') #=> #<Date: 2001-02-03 ...> Date.iso8601('2001-W05-6') #=> #<Date: 2001-02-03 ...>

httpdate

Date.httpdate(string='Mon, 01 Jan -4712 00:00:00 GMT'[, start=ITALY]) â date Class Public methods Creates a new Date object by parsing from a string according to some RFC 2616 format. Date.httpdate('Sat, 03 Feb 2001 00:00:00 GMT') #=> #<Date: 2001-02-03 ...>

gregorian_leap?

Date.gregorian_leap?(year) â bool Class Public methods Returns true if the given year is a leap year of the proleptic Gregorian calendar. Date.gregorian_leap?(1900) #=> false Date.gregorian_leap?(2000) #=> true

commercial

Date.commercial([cwyear=-4712[, cweek=1[, cwday=1[, start=Date::ITALY]]]]) â date Class Public methods Creates a date object denoting the given week date. The week and the day of week should be a negative or a positive number (as a relative week/day from the end of year/week when negative). They should not be zero. Date.commercial(2001) #=> #<Date: 2001-01-01 ...> Date.commercial(2002) #=> #<Date: 2001-12-31 ...> Date.commercial(2001,5,6) #=> #<D