value property

AnswerValue? get value

The value, or null when empty.

Implementation

AnswerValue? get value => _value;
set value (AnswerValue? value)

Sets the value without notifying listeners. Only leaves can hold a value.

Implementation

set value(AnswerValue? value) {
  if (!isLeaf) {
    throw StateError("Can't set data value for node that has children!");
  }
  _value = value;
}