aboutsummaryrefslogtreecommitdiffstats
path: root/calendar/timeutil.h
diff options
context:
space:
mode:
Diffstat (limited to 'calendar/timeutil.h')
-rw-r--r--calendar/timeutil.h13
1 files changed, 11 insertions, 2 deletions
diff --git a/calendar/timeutil.h b/calendar/timeutil.h
index ac006012ac..2c2ddfcbac 100644
--- a/calendar/timeutil.h
+++ b/calendar/timeutil.h
@@ -43,10 +43,12 @@ int time_days_in_month (int year, int month);
*/
time_t time_from_day (int year, int month, int day);
-time_t time_start_of_day (time_t t);
-time_t time_end_of_day (time_t t);
time_t time_day_hour (time_t t, int hour);
+/* For the functions below, time ranges are considered to contain the start time, but not the end
+ * time.
+ */
+
/* These two functions take a time value and return the beginning or end of the corresponding year,
* respectively.
*/
@@ -65,6 +67,13 @@ time_t time_month_end (time_t t);
time_t time_week_begin (time_t t);
time_t time_week_end (time_t t);
+/* These two functions take a time value and return the beginning or end of the corresponding day,
+ * respectively.
+ */
+time_t time_day_begin (time_t t);
+time_t time_day_end (time_t t);
+
+
time_t parse_date (char *str);
void print_time_t (time_t t);