DVMaintenanceWindow class

A span of the day, as HH:MM-HH:MM.

A maintenance window normally runs past midnight, which is why this is a span of the clock rather than of time: 23:00-01:00 is two hours, not a negative twenty-two.

Constructors

DVMaintenanceWindow({required int startMinute, required int endMinute})
const

Properties

endMinute → int
Minutes past midnight at which it closes. Less than startMinute when the window runs into the next day.
final
hashCode → int
The hash code for this object.
no setterinherited
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
startMinute → int
Minutes past midnight at which the window opens.
final
wrapsMidnight → bool
Whether the window runs past midnight.
no setter

Methods

contains(DateTime when) → bool
Whether when falls inside the window.
nextOpening(DateTime when) → DateTime
When the window next opens, at or after when.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() → String
A string representation of this object.
override

Operators

operator ==(Object other) → bool
The equality operator.
inherited

Static Methods

parse(Object? raw) → DVMaintenanceWindow?
Reads 02:00-04:00. Null when it cannot be read, so a caller can say so rather than fall back to a window it invented.