Location:
SCHTIME.H
Link against: schsvr.lib
class TTsTime;
In Task Scheduler TTsTime is used to represent time as either UTC or Local Time
. It is used by many of the Task Scheduler API's and also used internally within Task Scheduler. This class is not expected
to be stored by Task Scheduler clients.
It provides EXPORTed APIs for constructing, setting and getting UTC and Local Time
.
Internally the object always holds time as UTC (using the data member iUTC) irrespective of whether the object is local time based or UTC based.
If the object is local time based iOffset will be set to the system TimeZone/DST offset. When UTC based iOffset will always be 0.
Therefore:
When representing UTC: iUTC contains the UTC time iOffSet is set to 0 iFlags, bit 0 is set to 1
When representing Local Time
: iUTC contains the home time minus the TimeZone/DST offset iOffSet contains the TimeZone/DST offset iFlags, bit 0 is set
to 0
If an instance of this class is created using the default constructor then: iUTC is set to 0 iOffSet is set to 0 iFlags, bit 0 is set to 1 (indicating UTC time)
Defined in TTsTime
:
GetLocalTime()
, GetLocalTime()
, GetUtcTime()
, GetUtcTime()
, IsUtc()
, SetLocalTime()
, SetUtcTime()
, TTsTime()
, TTsTime()
, TTsTime()
, operator=()
IMPORT_C TTsTime();
Default constructor for TTsTime. This constructor initialises its member data to zero. By default this sets it to be UTC based.
IMPORT_C TTsTime(const TTime &aTime, TBool aIsUtc);
Constructs a TTsTime with a TTime
. If the iIsUtc is ETrue, then TTsTime is UTC based time, if iIsUtc is EFalse then TTsTime is local time based. This constructor
will update all the member data as appropriate.
|
IMPORT_C TTsTime(const TTsTime &aTTsTime);
Copy constructor for TTsTime
|
IMPORT_C void SetLocalTime(const TTime &aLocalTime);
Sets this object to a local time based value updating its parameters as appropriate.
|
IMPORT_C const TTime GetLocalTime();
This function returns a home time value.
|
IMPORT_C TTime GetLocalTime() const;
This function returns a home time value.
|
IMPORT_C void SetUtcTime(const TTime &aUtcTime);
Sets this object to a UTC time based value updating its parameters as appropriate.
|
IMPORT_C const TTime &GetUtcTime();
This function returns a UTC value.
|
IMPORT_C const TTime &GetUtcTime() const;
This function returns a UTC value.
|
IMPORT_C TBool IsUtc() const;
|