Get the farthest date from the instance.
(self, dt1: date, dt2: date)
| 120 | return dt2 |
| 121 | |
| 122 | def farthest(self, dt1: date, dt2: date) -> Self: |
| 123 | """ |
| 124 | Get the farthest date from the instance. |
| 125 | """ |
| 126 | dt1 = self.__class__(dt1.year, dt1.month, dt1.day) |
| 127 | dt2 = self.__class__(dt2.year, dt2.month, dt2.day) |
| 128 | |
| 129 | if self.diff(dt1).in_seconds() > self.diff(dt2).in_seconds(): |
| 130 | return dt1 |
| 131 | |
| 132 | return dt2 |
| 133 | |
| 134 | def is_future(self) -> bool: |
| 135 | """ |