Add TimeRange class and time_range function

TimeRange class added to handle adding a date to two times and adding
the correct date even when the time should roll over to a new day.