DVContractDecision class final

Whether a contract may run.

One decision behind two codes: DV-RELEASE-005 from DVContractStepGate and DV-SCHEMA-005 from Schema Evolution's tracker. Each caller supplies what it knows -- the gate reads the window from the protocol lock, the tracker is given the versions seen calling -- and neither keeps its own copy of the rule.

Constructors

DVContractDecision.evaluate({required Iterable<int>? windowed, required bool readsOldShape(int protocol), required DVContractReplacing? replacing})
Decides.
factory

Properties

allowed → bool
no setter
hashCode → int
The hash code for this object.
no setterinherited
readers → List<int>
The windowed versions that still read what the contract drops.
final
replacing → DVContractReplacing?
final
replacingReadsOldShape → bool
The release being replaced still reads the old shape.
no setter
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
windowed → List<int>?
The protocol versions inside the window, sorted; null when not known.
final
windowKnown → bool
no setter

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() → String
A string representation of this object.
inherited

Operators

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

Static Methods

builtToReadOldShape(DVReleaseMigrationPhase? phase) → bool
Whether a release built for phase still reads the old shape: anything before the read switch, and a release that names no phase at all.