#include <time.h>


Go to the source code of this file.
| #define FREQ_DAILY 4 |
Definition at line 99 of file cpl_time.h.
Referenced by check_freq_interval(), check_min_unit(), get_min_interval(), and tr_parse_freq().
| #define FREQ_MONTHLY 2 |
Definition at line 97 of file cpl_time.h.
Referenced by check_byxxx(), check_freq_interval(), check_min_unit(), get_min_interval(), and tr_parse_freq().
| #define FREQ_NOFREQ 0 |
| #define FREQ_WEEKLY 3 |
Definition at line 98 of file cpl_time.h.
Referenced by check_freq_interval(), check_min_unit(), get_min_interval(), and tr_parse_freq().
| #define FREQ_YEARLY 1 |
Definition at line 96 of file cpl_time.h.
Referenced by check_byxxx(), check_freq_interval(), check_min_unit(), get_min_interval(), and tr_parse_freq().
| #define is_leap_year | ( | yyyy | ) | ((((yyyy)%400))?(((yyyy)%100)?(((yyyy)%4)?0:1):0):1) |
| #define TSW_RSET 2 |
| #define TSW_TSET 1 |
Definition at line 110 of file cpl_time.h.
| #define WDAY_FR 5 |
| #define WDAY_MO 1 |
| #define WDAY_NU 7 |
Definition at line 108 of file cpl_time.h.
| #define WDAY_SA 6 |
| #define WDAY_SU 0 |
| #define WDAY_TH 4 |
| #define WDAY_TU 2 |
| #define WDAY_WE 3 |
| typedef struct _ac_maxval * ac_maxval_p |
| typedef struct _ac_maxval ac_maxval_t |
| typedef struct _tr_byxxx * tr_byxxx_p |
| typedef struct _tr_byxxx tr_byxxx_t |
| ac_maxval_p ac_get_maxval | ( | ac_tm_p | ) |
Definition at line 213 of file cpl_time.c.
References ac_get_yweek(), is_leap_year, _ac_maxval::mday, _ac_tm::mv, _ac_maxval::mwday, _ac_maxval::mweek, NULL, pkg_malloc, _ac_tm::t, _ac_maxval::yday, _ac_maxval::ywday, and _ac_maxval::yweek.
Referenced by check_byxxx().
| int ac_get_mweek | ( | struct tm * | ) |
| int ac_get_wkst | ( | void | ) |
Definition at line 186 of file cpl_time.c.
| int ac_get_yweek | ( | struct tm * | ) |
Definition at line 158 of file cpl_time.c.
References MON_WEEK.
Referenced by ac_get_maxval(), and ac_tm_fill().
| int ac_print | ( | ac_tm_p | ) |
Definition at line 275 of file cpl_time.c.
References _ac_maxval::mday, _ac_tm::mv, _ac_maxval::mwday, _ac_tm::mwday, _ac_maxval::mweek, _ac_tm::mweek, _ac_tm::t, _ac_tm::time, _ac_maxval::yday, _ac_maxval::ywday, _ac_tm::ywday, _ac_maxval::yweek, and _ac_tm::yweek.
| int ac_tm_free | ( | ac_tm_p | ) |
Definition at line 203 of file cpl_time.c.
References _ac_tm::mv, and pkg_free.
Referenced by run_time_switch().
| ac_tm_p ac_tm_new | ( | void | ) |
| int ac_tm_reset | ( | ac_tm_p | ) |
Definition at line 195 of file cpl_time.c.
| int ac_tm_set_time | ( | ac_tm_p | , | |
| time_t | ||||
| ) |
Definition at line 139 of file cpl_time.c.
References ac_tm_fill(), and _ac_tm::time.
Referenced by run_time_switch().
return 0/REC_MATCH - the time falls in -1/REC_ERR - error 1/REC_NOMATCH - the time falls out
Definition at line 946 of file cpl_time.c.
References _IS_SET, check_byxxx(), check_freq_interval(), check_min_unit(), _tmrec::dtend, _tmrec::dtstart, _tmrec::duration, _tr_res::flag, REC_ERR, REC_MATCH, REC_NOMATCH, _tr_res::rest, _ac_tm::time, TSW_RSET, and _tmrec::until.
Referenced by run_time_switch().
| tr_byxxx_p ic_parse_byday | ( | char * | ) |
Definition at line 658 of file cpl_time.c.
References NULL, _tr_byxxx::req, tr_byxxx_free(), tr_byxxx_init(), tr_byxxx_new(), WDAY_FR, WDAY_MO, WDAY_SA, WDAY_SU, WDAY_TH, WDAY_TU, WDAY_WE, and _tr_byxxx::xxx.
Referenced by tr_parse_byday().
| tr_byxxx_p ic_parse_byxxx | ( | char * | ) |
Definition at line 791 of file cpl_time.c.
References NULL, _tr_byxxx::req, tr_byxxx_free(), tr_byxxx_init(), tr_byxxx_new(), and _tr_byxxx::xxx.
Referenced by tr_parse_bymday(), tr_parse_bymonth(), tr_parse_byweekno(), and tr_parse_byyday().
| time_t ic_parse_datetime | ( | char * | , | |
| struct tm * | ||||
| ) |
Definition at line 559 of file cpl_time.c.
References _D.
Referenced by tr_parse_dtend(), tr_parse_dtstart(), and tr_parse_until().
| time_t ic_parse_duration | ( | char * | ) |
| int ic_parse_wkst | ( | char * | ) |
Definition at line 860 of file cpl_time.c.
References WDAY_FR, WDAY_MO, WDAY_SA, WDAY_SU, WDAY_TH, WDAY_TU, and WDAY_WE.
Referenced by tr_parse_wkst().
| int tmrec_free | ( | tmrec_p | ) |
Definition at line 364 of file cpl_time.c.
References _tmrec::byday, _tmrec::bymday, _tmrec::bymonth, _tmrec::byweekno, _tmrec::byyday, and tr_byxxx_free().
Referenced by run_time_switch().
| tmrec_p tmrec_new | ( | void | ) |
Definition at line 353 of file cpl_time.c.
References _tmrec::dtstart, NULL, pkg_malloc, and _tmrec::ts.
| int tr_byxxx_free | ( | tr_byxxx_p | ) |
Definition at line 341 of file cpl_time.c.
References pkg_free, _tr_byxxx::req, and _tr_byxxx::xxx.
Referenced by ic_parse_byday(), ic_parse_byxxx(), and tmrec_free().
| int tr_byxxx_init | ( | tr_byxxx_p | , | |
| int | ||||
| ) |
Definition at line 319 of file cpl_time.c.
References _tr_byxxx::nr, pkg_free, pkg_malloc, _tr_byxxx::req, and _tr_byxxx::xxx.
Referenced by ic_parse_byday(), and ic_parse_byxxx().
| tr_byxxx_p tr_byxxx_new | ( | void | ) |
Definition at line 309 of file cpl_time.c.
References NULL, and pkg_malloc.
Referenced by ic_parse_byday(), and ic_parse_byxxx().
| int tr_parse_byday | ( | tmrec_p | , | |
| char * | ||||
| ) |
Definition at line 450 of file cpl_time.c.
References _tmrec::byday, and ic_parse_byday().
Referenced by run_time_switch().
| int tr_parse_bymday | ( | tmrec_p | , | |
| char * | ||||
| ) |
Definition at line 458 of file cpl_time.c.
References _tmrec::bymday, and ic_parse_byxxx().
Referenced by run_time_switch().
| int tr_parse_bymonth | ( | tmrec_p | , | |
| char * | ||||
| ) |
Definition at line 474 of file cpl_time.c.
References _tmrec::bymonth, and ic_parse_byxxx().
Referenced by run_time_switch().
| int tr_parse_byweekno | ( | tmrec_p | , | |
| char * | ||||
| ) |
Definition at line 482 of file cpl_time.c.
References _tmrec::byweekno, and ic_parse_byxxx().
Referenced by run_time_switch().
| int tr_parse_byyday | ( | tmrec_p | , | |
| char * | ||||
| ) |
Definition at line 466 of file cpl_time.c.
References _tmrec::byyday, and ic_parse_byxxx().
Referenced by run_time_switch().
| int tr_parse_dtend | ( | tmrec_p | , | |
| char * | ||||
| ) |
Definition at line 387 of file cpl_time.c.
References _tmrec::dtend, and ic_parse_datetime().
Referenced by run_time_switch().
| int tr_parse_dtstart | ( | tmrec_p | , | |
| char * | ||||
| ) |
Definition at line 379 of file cpl_time.c.
References _tmrec::dtstart, ic_parse_datetime(), and _tmrec::ts.
Referenced by run_time_switch().
| int tr_parse_duration | ( | tmrec_p | , | |
| char * | ||||
| ) |
Definition at line 396 of file cpl_time.c.
References _tmrec::duration, and ic_parse_duration().
Referenced by run_time_switch().
| int tr_parse_freq | ( | tmrec_p | , | |
| char * | ||||
| ) |
Definition at line 413 of file cpl_time.c.
References _tmrec::freq, FREQ_DAILY, FREQ_MONTHLY, FREQ_NOFREQ, FREQ_WEEKLY, and FREQ_YEARLY.
Referenced by run_time_switch().
| int tr_parse_interval | ( | tmrec_p | , | |
| char * | ||||
| ) |
Definition at line 442 of file cpl_time.c.
References _tmrec::interval, and strz2int().
Referenced by run_time_switch().
| int tr_parse_until | ( | tmrec_p | , | |
| char * | ||||
| ) |
Definition at line 404 of file cpl_time.c.
References ic_parse_datetime(), and _tmrec::until.
Referenced by run_time_switch().
| int tr_parse_wkst | ( | tmrec_p | , | |
| char * | ||||
| ) |
Definition at line 490 of file cpl_time.c.
References ic_parse_wkst(), and _tmrec::wkst.
Referenced by run_time_switch().
| int tr_print | ( | tmrec_p | ) |
Definition at line 498 of file cpl_time.c.
References _tmrec::byday, _tmrec::bymday, _tmrec::bymonth, _tmrec::byweekno, _tmrec::byyday, _tmrec::dtend, _tmrec::dtstart, _tmrec::duration, _tmrec::freq, _tmrec::interval, _tr_byxxx::nr, _tr_byxxx::req, _tmrec::ts, _tmrec::until, _tmrec::wkst, and _tr_byxxx::xxx.
1.5.6