length property

int length

Gets the length of this date interval in days. This will always be at least 1.

Implementation

int get length =>
  // Period.DaysBetween will give us the exclusive result, so we need to add 1
  // to include the end date.
  IPeriod.daysBetween(start, end) + 1;