9 static void make_incr();
85 for (pos = dtfrom; pos < from; pos++) {
116 for (carry = 0, pos = dt->
to; carry == 0 && pos > to; pos--) {
142 make_incr(&incr, to, to, dt);
162 for (pos = dt->
to; pos > to; pos--) {
163 make_incr(&incr, pos, pos, dt);
167 incr.
day = dt->
day + ndays / 2;
180 for (pos = from; pos < dtfrom; pos++)
202 for (pos = to; pos > dt->
to; pos--)
int datetime_is_relative(const DateTime *dt)
Returns: 1 if dt.mode is relative 0 if not (even if dt.mode is not defined)
void datetime_set_negative(DateTime *dt)
Makes the DateTime negative. (B.C. for ABSOLUTE DateTimes)
#define DATETIME_RELATIVE
int datetime_change_from_to(DateTime *dt, int from, int to, int round)
Changes the from/to of the type for dt. The 'from/to' must be legal values for the mode of dt; (if th...
int datetime_is_valid_type(const DateTime *dt)
Returns: 1 if datetime_check_type() returns 0 0 if not.
int datetime_days_in_year(int year, int ad)
returns the number of days in 'year'
int datetime_is_negative(const DateTime *dt)
Returns: 1 if the DateTime is negative 0 otherwise.
int datetime_set_type(DateTime *dt, int mode, int from, int to, int fracsec)
int datetime_is_absolute(const DateTime *dt)
Returns: 1 if dt.mode is absolute 0 if not (even if dt.mode is not defined)
int datetime_increment(DateTime *src, DateTime *incr)
This function changes the 'src' date/time data based on the 'incr' The type (mode/from/to) of the 'sr...