TimeRange constructor

TimeRange({
  1. required int startTimestamp,
  2. required int endTimestamp,
})

Implementation

TimeRange({
  required this.startTimestamp,
  required this.endTimestamp,
}) {
  if (endTimestamp <= startTimestamp) {
    throw InvalidValueException('Invalid TimeRange: endTimestamp '
        '$endTimestamp is not after startTimestamp $startTimestamp');
  }
}