Slide 45
Slide 45 text
ObservableProperty
class LogOnWrite(initialValue: T) : ObservableProperty(initialValue) {
override fun afterChange(property: KProperty<*>, oldValue: T, newValue: T) {
println("Changed from $oldValue to $newValue")
}
override fun beforeChange(property: KProperty<*>, oldValue: T, newValue: T)
= true // Accept change
// = false // Reject change
}