endOfDay property

DateTime get endOfDay

Get a new DateTime with the same year, month and day, but the time is set to the last microsecond before a new day starts.

Implementation

DateTime get endOfDay => copyWith(
      hour: 23,
      minute: 59,
      second: 59,
      millisecond: 999,
      microsecond: 999,
    );