isBeforeTime method
Returns true if this occurs fully before time
.
See DateTime.isAfter
for reference.
Implementation
@override
bool isBeforeTime(DateTime time) =>
// interval's end timestamp is not included in the interval
endTime != null &&
(endTime!.isBefore(time) || endTime!.isAtSameMomentAs(time));