Known child units
|
Exceptions
Date_Error |
|
Any calendar operation may raise this exception if a date is not valid
for a particular calendar. Possible reasons for Date_Error being
raised include: passing a date before 15-OCT-1582 to a Gregorian
calendar, or passing a non-existing date to a Universal calendar, such
as a date in the range 05-OCT-1582 to 14-OCT-1582, if the switch date
of the Universal calendar is not changed.
|
|
Type Summary
|
Other Items:
|
type Calendar is abstract tagged null record;
|
Abstract root type for all calendars. Note: any other operations are
added by derived types. For instance, operations on days and months
are added in child package
Util.Calendars.Western.
They're not added here because other calendar systems may not have
a concept of months in the sense of the western calendars.
|
|
subtype Year_Number is Integer;
|
|
But any calendar has a concept of a year! (Even if the counting systems
may differ wildly, as may the length of a year.)
|
|
function Year
(Base : in Calendar;
Date : in Util.Times.Time)
return Year_Number
is abstract;
|
|
Return the year of the Date. May raise Date_Error if the Date is
not a valid date for the given calendar Base.
|
|
function Image
(Base : in Calendar;
Date : in Util.Times.Time)
return String
is abstract;
|
|
Returns a string representation of the given Date. May raise
Date_Error if the Date is not a valid date for the given calendar
Base.
|
|