operator + method

DateTime operator +(
  1. Duration duration
)

Ads this duration of time to this date and returns the result.

Example: "2023-08-24".toDate + 7.day -> 2023-08-31.

Implementation

DateTime operator +(Duration duration) => add(duration);