Go to repository

Interface Changeable<A>

A Changeable is a data structure used to register changes over a certain value of a given type.

The initial value is supposed to be given on creation, and then subsequent changes can be registered using addChange. At any moment the current value (that corresponding to the last active change) can be accessed using currentValue.

interface Changeable<A> {
    addChange(e: A): void;
    currentValue(): A;
}

Type Parameters

  • A

Implemented by

API

Add a change to the history in the current transaction, as the last version of the value.

Parameters

Returns void

Describes the current value in the history.

Returns A