SettlementScope

sealed interface SettlementScope<in V>

What a settlement says the widget was left holding. See the MirrorState.settle a block runs in.

A settlement is closed exactly one of two ways. answered records a value this pass read back, which is what a widget that resolved the write its own way has to be measured against afterwards. unchanged says the write left this mirror's property alone, so there is nothing to read back and nothing to record - the mirror already holds what the widget holds. Saying neither is a defect rather than a third case: it leaves the widget standing where the write left it with no later pass due to correct it.

Functions

Link copied to clipboard
abstract fun answered(value: V)

Records value - what this settlement read the widget back as - as the answer to what it wrote.

Link copied to clipboard
abstract fun unchanged()

Closes the settlement without recording, for a write that left this mirror's property untouched.