Foxit PDF SDK
|
Inherits SystemIDisposable.
Public Member Functions | |
DateTime (ushort year, ushort month, ushort day, ushort hour, ushort minute, ushort second, ushort milliseconds, short utc_hour_offset, ushort utc_minute_offset) | |
Constructor, with parameters. More... | |
DateTime () | |
Constructor. | |
DateTime (DateTime dt) | |
Constructor, with another date and time object. More... | |
bool | IsValid () |
Check whether current object is valid or not. More... | |
void | Set (ushort year, ushort month, ushort day, ushort hour, ushort minute, ushort second, ushort milliseconds, short utc_hour_offset, ushort utc_minute_offset) |
Set value. More... | |
DateTime | ToLocalTime () |
Convert current object to local time. More... | |
DateTime | ToUTCTime () |
Convert current object to UTC time. More... | |
Static Public Member Functions | |
static DateTime | GetLocalTime () |
Get local time. More... | |
static DateTime | GetUTCTime () |
Get UTC time. More... | |
Properties | |
ushort | day [get, set] |
Day of month. Valid range: from 1 to 31. | |
ushort | hour [get, set] |
Hour. Valid range: from 0 to 23. | |
ushort | milliseconds [get, set] |
Millisecond. Valid range: from 0 to 999. PDF standard does not support now, this can be omitted if it is not applicable. | |
ushort | minute [get, set] |
Minute. Valid range: from 0 to 59. | |
ushort | month [get, set] |
Month. Valid range: from 1 to 12. | |
ushort | second [get, set] |
Second. Valid range: from 0 to 60. 60 for leap second. | |
short | utc_hour_offset [get, set] |
Hour of time zone. Valid range: from -12 to 12. More... | |
ushort | utc_minute_offset [get, set] |
Minute of time zone. Valid range: from 0 to 59. | |
ushort | year [get, set] |
Year. It should be a four-digit number, such as 2014. | |
This class represents date, time and timezone.
|
inline |
Constructor, with parameters.
[in] | year | Year. It should be a four-digit number, such as 2014. |
[in] | month | Month. Valid range: from 1 to 12. |
[in] | day | Day of month. Valid range: from 1 to 31. |
[in] | hour | Hour. Valid range: from 0 to 23. |
[in] | minute | Minute. Valid range: from 0 to 59. |
[in] | second | Second. Valid range: from 0 to 60. 60 for leap second. |
[in] | milliseconds | Millisecond. Valid range: from 0 to 999. PDF standard does not support now, this can be omitted if it is not applicable. |
[in] | utc_hour_offset | Hour of time zone. Valid range: from -12 to 12. Positive value for the eastern time zone, and negative value for the western time zone. |
[in] | utc_minute_offset | Minute of time zone. Valid range: from 0 to 59. |
|
inline |
Constructor, with another date and time object.
[in] | dt | Another date and time object. |
|
inlinestatic |
Get local time.
|
inlinestatic |
Get UTC time.
|
inline |
Check whether current object is valid or not.
When the current object is not valid, that means current object is useless.
|
inline |
Set value.
[in] | year | Year. It should be a four-digit number, such as 2014. |
[in] | month | Month. Valid range: from 1 to 12. |
[in] | day | Day of month. Valid range: from 1 to 31. |
[in] | hour | Hour. Valid range: from 0 to 23. |
[in] | minute | Minute. Valid range: from 0 to 59. |
[in] | second | Second. Valid range: from 0 to 60. 60 for leap second. |
[in] | milliseconds | Millisecond. Valid range: from 0 to 999. PDF standard does not support now, this can be omitted if it is not applicable. |
[in] | utc_hour_offset | Hour of time zone. Valid range: from -12 to 12. Positive value for the eastern time zone, and negative value for the western time zone. |
[in] | utc_minute_offset | Minute of time zone. Valid range: from 0 to 59. |
|
inline |
Convert current object to local time.
|
inline |
Convert current object to UTC time.
|
getset |
Hour of time zone. Valid range: from -12 to 12.
Positive value for the eastern time zone, and negative value for the western time zone.