struct

Date

Inherits Comparable < Struct < Value < Object

Represents a year, month, and day with no time information.

Constructors

new(date : Tuple(Int32, Int32, Int32))

Creates a date from the return of Time#date.

Source

Instance methods

<=>(other : self)
Source
at_beginning_of_sunday_week

See Time#at_beginning_of_sunday_week.

Source
day_of_week

See Time#day_of_week.

Source
month
Source
shift(years : Int = 0, months : Int = 0, weeks : Int = 0, days : Int = 0) : self

See Time#shift.

Source
to_ical

Formats this date as an iCal DATE value.

Source
to_time

Converts this date to a Time at midnight in UTC.

Source
year
Source