ReadOnlyPropertyDefaultObservable
constructor(defaultValue: R, readOnlyProperty: ReadOnlyProperty<Any?, T>, observation: ObservationDefault<R, T?> = ObservationDefault(
defaultValue,
ObservableOptional.Value(
run {
val v by readOnlyProperty
v
},
),
))
Parameters
T
the type of value to expect.
R
the type of result to expect. Must be a subclass of T
defaultValue
The default R to return if the value of the ReadOnlyProperty is null
.
readOnlyProperty
The ReadOnlyProperty to track.
observation
The ObservationInitialized to handle observation.