DVScheduler class

The schedule registry and the thing that fires it.

Constructors

DVScheduler({DateTime clock()?, DVScheduleLease? lease, void onFailure(DVScheduledFailure failure)?})
lease, when given, is claimed for each occurrence before it runs, so processes sharing its store run each occurrence once between them.

Properties

failures → List<DVScheduledFailure>
no setter
hashCode → int
The hash code for this object.
no setterinherited
lease → DVScheduleLease?
final
names → List<String>
no setter
onFailure → void Function(DVScheduledFailure failure)?
final
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited

Methods

clearFailures() → void
Forgets recorded failures.
nextRunOf(String name) → DateTime?
The next time name is due, or null if it can never run again.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
register(String name, String expression, Future<void> handler(), {bool catchUp = false, int maxCatchUp = 100}) → void
Adds a task.
registerAll(List<DVCronEntry> entries, {required Map<String, Future<void> Function()> handlers, bool catchUp = false}) → void
Registers every entry in entries against a handler of the same name.
tick() → Future<void>
Runs whatever is due.
toString() → String
A string representation of this object.
inherited
unregister(String name) → void

Operators

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