#include <qofdate.h>
Based on struct tm but using signed integers. The year value uses a signed 64bit value to prevent overflows. (A glong is insufficient by two orders of magnitude.) To retain precision, a QofDate includes a nanoseconds value that can be used with a QofTime and a 64bit value for seconds.
Definition at line 138 of file qofdate.h.
Data Fields | |
glong | qd_nanosecs |
gint64 | qd_sec |
glong | qd_min |
Signed replacement of struct tm.tm_min. | |
glong | qd_hour |
Signed replacement of struct tm.tm_hour. | |
glong | qd_mday |
Signed replacement of struct tm.tm_mday. | |
glong | qd_mon |
Signed replacement of struct tm.tm_mon. | |
gint64 | qd_year |
Extended version to cope with full range of dates. | |
gshort | qd_wday |
gshort | qd_yday |
gshort | qd_is_dst |
glong | qd_gmt_off |
Calculated value based on struct tm.tm_gmtoff. | |
const gchar * | qd_zone |
Calculated value based on struct tm.tm_zone. | |
gboolean | qd_valid |
If the QofDate is valid or merely initialised. |
glong QofDate_s::qd_nanosecs |
gint64 QofDate_s::qd_sec |
glong QofDate_s::qd_min |
glong QofDate_s::qd_hour |
glong QofDate_s::qd_mday |
glong QofDate_s::qd_mon |
gint64 QofDate_s::qd_year |
Extended version to cope with full range of dates.
gshort QofDate_s::qd_wday |
gshort QofDate_s::qd_yday |
gshort QofDate_s::qd_is_dst |
glong QofDate_s::qd_gmt_off |
Calculated value based on struct tm.tm_gmtoff.
const gchar* QofDate_s::qd_zone |
gboolean QofDate_s::qd_valid |
If the QofDate is valid or merely initialised.
Some QofDate values are invalid when initialised to zero (e.g. qm_mday). Avoid setting this value manually (just because it can be done, does not mean doing it is a good idea). Use qof_date_valid to ensure that values like qd_wday, qd_yday, qd_gmt_off and qd_is_dst are set correctly.