GRASS Programmer's Manual
6.5.svn(2014)-r66266
|
#include <grass/datetime.h>
Go to the source code of this file.
Functions | |
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 'src' can be anything. The mode of the 'incr' must be RELATIVE, and the type (mode/from/to) for 'incr' must be a valid increment for 'src'. See datetime_is_valid_increment(), datetime_check_increment() Returns: 0: OK -1: 'incr' is invalid increment for 'src' For src.mode ABSOLUTE,. More... | |
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 'src' can be anything. The mode of the 'incr' must be RELATIVE, and the type (mode/from/to) for 'incr' must be a valid increment for 'src'. See datetime_is_valid_increment(), datetime_check_increment() Returns: 0: OK -1: 'incr' is invalid increment for 'src' For src.mode ABSOLUTE,.
The 'fracsec' in 'src' is preserved. The 'from/to' of the 'src' is preserved. A timezone in 'src' is allowed - it's presence is ignored. NOTE: There is no datetime_decrement() To decrement, set the 'incr' negative.
src | |
incr |
Definition at line 67 of file incr1.c.
References datetime_change_from_to(), datetime_copy(), datetime_error_code(), datetime_in_interval_day_second(), and datetime_is_valid_increment().
Referenced by datetime_change_from_to(), datetime_change_timezone(), and datetime_difference().