value property
T
get
value
override
Returns the value of the signal.
Implementation
T get value {
if (_shouldGetValueNotify) {
_shouldGetValueNotify = false;
Reactter.emit(Signal, SignalEvent.onGetValue, this);
_shouldGetValueNotify = true;
}
return super.value;
}
set
value
(T val)
override
Updates the value of the signal and notifies the observers when changes occur.
Implementation
set value(T val) {
if (super.value == val) return;
update((_) {
super.value = val;
if (!_shouldSetValueNotify) return;
_shouldSetValueNotify = false;
Reactter.emit(Signal, SignalEvent.onSetValue, this);
_shouldSetValueNotify = true;
});
}