A class for time handling. For general usage, see the description of chrono.Date in the Usage section, which works in much the same way as chrono.Time.
Valid values for time can be:
The class can also be instantiated using the keyword arguments hour, minute, and second:
Time(hour=16, minute=27, second=43)
If both time and keywords are specified, time takes precedence.
parser determines which parser to use for parsing times from strings. By default the value of chrono.DEFAULT_PARSER is used - normally chrono.parser.CommonParser, which supports the most common date and time formats. See chrono.parser for a list of available parsers.
Makes sure the object has a full time set, ie the attributes chrono.Time.hour, chrono.Time.minute, and chrono.Time.second are not None.
Raises chrono.error.NoDateTimeError on missing attributes.
Formats the time using template, replacing variables as supported by chrono.formatter.Formatter.
Raises chrono.error.NoDateTimeError on missing time data.
Returns the time as a tuple of hour, minute, and second.
Raises chrono.error.NoDateTimeError on missing time data.
Returns a datetime.time instance based on the time.
Raises chrono.error.NoDateTimeError on missing time data.
Returns a julian time for the set time, as a float between 0 and 1.
Raises chrono.error.NoDateTimeError on missing time data.
Returns a string represenation (hh:mm:ss) of the time.
Raises chrono.error.NoDateTimeError on missing time data.
Sets the time.
Raises chrono.error.HourError, chrono.error.MinuteError, or chrono.error.SecondError for invalid values.
Sets the time from a julian time, as a float between 0 and 1. If julian is greather than 1, only the decimal part will be used.
Raises chrono.error.TimeError on invalid julian time.
Sets the time from a string, parsed with the parser set in chrono.Date.parser - by default the parser set in chrono.DEFAULT_PARSER, normally chrono.parser.CommonParser.
Raises chrono.error.ParseError for invalid input format, TypeError for invalid input type, and chrono.error.HourError, chrono.error.MinuteError, or chrono.error.SecondError for invalid time values.