build method
Returns an LDValue of type LDValueType.array containing the builder's current elements.
Subsequent changes to the builder will not affect the returned value (it uses copy-on-write logic, so the previous values will only be copied to a new list if you continue to add elements after calling build).
Implementation
LDValue build() {
_copyOnWrite = true;
return LDValue._const(_LDValueArray(UnmodifiableListView(_builder)));
}