The system time is set through the System Static Functions API
User
class.
System locale settings, which affect date and time formatting, are
set through TLocale
in the Locale Settings API.
The point in time is a 64-bit integer that represents time as the number of microseconds since midnight on 1st January 0 AD, using a nominal Gregorian calendar. It can be set to the current system time, can have arithmetic and comparison operations performed on it, and can be converted into a string formatted according to the locale and other options.
The main point in time interface is provided by
TTime
. A support class TDateTime
is
provided that allows time values to be get and set in an easy-to-use format,
such as year, month, day, rather than as an integer.
The time utilities provides miscellaneous time functions, for such things as checking for leap years.
The time utilities interface is provided by
Time
.
The time interval represents a period between two points in time. Time intervals can be added or subtracted, either to or from each other or to or from points in time.
The time interval interface is provided by a base class
TTimeIntervalBase
and by a family of derived classes for
second, minute, hour, etc. intervals. A class outside this hierarchy,
TTimeIntervalMicroSeconds
, is provided for efficiency
reasons (it alone stores its value as a 64-bit number).