Interface | osid.locale.TimeInfo | ||
---|---|---|---|
Description |
This interface defines methods to examine a time. Time is organized intro "hours," "minutes," and "seconds." A time system may offer a different designation for these divisions which may or may not vary in duration. | ||
Method | getTimeType | ||
Description |
Gets the time type. | ||
Return | osid.type.Type | the time type | |
Compliance | mandatory | This method must be implemented. | |
Method | getDisplayName | ||
Description |
Gets the display name for this time system. | ||
Return | osid.locale.DisplayText | the display name | |
Compliance | mandatory | This method must be implemented. | |
Method | getDisplayLabel | ||
Description |
Gets a short label for this time system. | ||
Return | osid.locale.DisplayText | the label | |
Compliance | mandatory | This method must be implemented. | |
Method | getDescription | ||
Description |
Gets a description of this time system. | ||
Return | osid.locale.DisplayText | the description | |
Compliance | mandatory | This method must be implemented. | |
Method | getHourName | ||
Description |
Gets the display name for "hours." | ||
Return | osid.locale.DisplayText | the name | |
Compliance | mandatory | This method must be implemented. | |
Method | getHourAbbrev | ||
Description |
Gets the abbreviation for "hours." | ||
Return | osid.locale.DisplayText | the abbreviation | |
Compliance | mandatory | This method must be implemented. | |
Method | getHourInitial | ||
Description |
Gets the initial for "hours." | ||
Return | osid.locale.DisplayText | the initial | |
Compliance | mandatory | This method must be implemented. | |
Method | hasVariableHours | ||
Description |
Tests if this time system has a variable number of hours in a day. | ||
Return | boolean | true if the number of hours per day varies, false
if the number of hours per day is constant | |
Compliance | mandatory | This method must be implemented. | |
Method | getNumHours | ||
Description |
Gets the number of hours in a day. For a variable hour time system, the number of hours defined is returned. If there are no "hours" in this time system then this value may be zero. | ||
Return | cardinal | the number of hours | |
Compliance | mandatory | This method must be implemented. | |
Method | getNumHoursForDay | ||
Description |
Gets the number of hours for a given day. | ||
Parameters | integer | year | a year |
cardinal | month | a DateTime month code | |
cardinal | day | a DateTime day code | |
Return | cardinal | the number of hours | |
Errors | ILLEGAL_STATE | year is greater than
CalendarInfo.getLastYearBeforeCommonEra() and less then
CalendarInfo.getFirstYearInCommonEra() , or month is
greater than or equal to CalendarInfo.getNumMonthsForYear(year)
, or day is greater than or equal to
CalendarInfo.getDaysInMonth(year, month) | |
OPERATION_FAILED | unable to complete request | ||
Compliance | mandatory | This method must be implemented. | |
Method | getMinuteName | ||
Description |
Gets the display name for "minutes." | ||
Return | osid.locale.DisplayText | the name | |
Compliance | mandatory | This method must be implemented. | |
Method | getMinuteAbbrev | ||
Description |
Gets the abbreviation for "minutes." | ||
Return | osid.locale.DisplayText | the abbreviation | |
Compliance | mandatory | This method must be implemented. | |
Method | getMinuteInitial | ||
Description |
Gets the initial for "minutes." | ||
Return | osid.locale.DisplayText | the initial | |
Compliance | mandatory | This method must be implemented. | |
Method | hasVariableMinutes | ||
Description |
Tests if this time system has a variable number of minutes in an hour. | ||
Return | boolean | true if the number of minutes per hour varies, false
if the number of minutes per hour is constant | |
Compliance | mandatory | This method must be implemented. | |
Method | getNumMinutes | ||
Description |
Gets the number of minutes in an hour. For a variable minute time system, the number of minutes defined is returned. If there are no "minutes" in this time system then this value may be zero. If there are no "hours" defined then the number of minutes is the number of minutes in a day. | ||
Return | cardinal | the number of minutes | |
Compliance | mandatory | This method must be implemented. | |
Method | getNumMinutesForHour | ||
Description |
Gets the minutes for a given hour. | ||
Parameters | integer | year | a year |
cardinal | month | a DateTime month code | |
cardinal | day | a DateTime day code | |
cardinal | hour | an hour | |
Return | cardinal | the number of minutes | |
Errors | ILLEGAL_STATE | year is greater than
CalendarInfo.getLastYearBeforeCommonEra() and less then
CalendarInfo.getFirstYearInCommonEra(), or month is
greater than or equal to CalendarInfo.getNumMonthsForYear(year)
, or day is greater than or equal to
CalendarInfo.getDaysInMonth(year, month) , or hour is
greater than or equal to getNumHoursInDay(year, month, day) | |
OPERATION_FAILED | unable to complete request | ||
Compliance | mandatory | This method must be implemented. | |
Method | getSecondName | ||
Description |
Gets the display name for "seconds." | ||
Return | osid.locale.DisplayText | the name | |
Compliance | mandatory | This method must be implemented. | |
Method | getSecondAbbrev | ||
Description |
Gets the abbreviation for "seconds." | ||
Return | osid.locale.DisplayText | the abbreviation | |
Compliance | mandatory | This method must be implemented. | |
Method | getSecondInitial | ||
Description |
Gets the initial for "seconds." | ||
Return | osid.locale.DisplayText | the initial | |
Compliance | mandatory | This method must be implemented. | |
Method | hasVariableSeconds | ||
Description |
Tests if this time system has a variable number of seconds in a minute. | ||
Return | boolean | true if the number of seconds per minute varies,
false if the number of seconds per minute is constant | |
Compliance | mandatory | This method must be implemented. | |
Method | getNumSeconds | ||
Description |
Gets the number of seconds in a minute. For a variable second time system, the number of seconds defined is returned. If there are no "seconds" in this time system then this value may be zero. If there are no "minutes" defined then the number of seconds is the number of seconds in an hour. | ||
Return | cardinal | the number of seconds | |
Compliance | mandatory | This method must be implemented. | |
Method | getNumSecondsForMinute | ||
Description |
Gets the seconds for a given minute. | ||
Parameters | integer | year | a year |
cardinal | month | a DateTime month code | |
cardinal | day | a DateTime day code | |
cardinal | hour | an hour | |
cardinal | minute | a minute | |
Return | cardinal | the number of seconds | |
Errors | ILLEGAL_STATE | year is greater than getLastYearBeforeCommonEra()
and less then getFirstYearInCommonEra() , or
month is greater than or equal to
CalendarInfo.getNumMonthsForYear(year) , or day is
greater than or equal to CalendarInfo.getDaysInMonth(year, month)
, or hour is greater than or equal to
getNumHoursInDay(year, month, day) , or minute is
greater than or equal to getNumMinutesInhour(year, month, day, hour)
| |
OPERATION_FAILED | unable to complete request | ||
Compliance | mandatory | This method must be implemented. |