Files
kotlin-fork/libraries/stdlib/api/js-v1/kotlin.properties.kt
T
Anton Bannykh cbabb4f76a JS stdlib api test: various changes
- Setting -Doverwrite.output=true updates gold data
- Big packages don't get split into chunks
- Unique lines in the API are marked with /*∆*/ and diff test is removed
- Annotations on separate lines and other dump format tweaks
- Test data moved to libraries/stdlib/api/
- Minor visibility fix to Enum members
2020-06-15 11:49:15 +03:00

34 lines
1.8 KiB
Kotlin

public object Delegates {
public final fun <T : kotlin.Any> notNull(): kotlin.properties.ReadWriteProperty<kotlin.Any?, T>
public final inline fun <T> observable(initialValue: T, crossinline onChange: (property: kotlin.reflect.KProperty<*>, oldValue: T, newValue: T) -> kotlin.Unit): kotlin.properties.ReadWriteProperty<kotlin.Any?, T>
public final inline fun <T> vetoable(initialValue: T, crossinline onChange: (property: kotlin.reflect.KProperty<*>, oldValue: T, newValue: T) -> kotlin.Boolean): kotlin.properties.ReadWriteProperty<kotlin.Any?, T>
}
public abstract class ObservableProperty<V> : kotlin.properties.ReadWriteProperty<kotlin.Any?, V> {
public constructor ObservableProperty<V>(initialValue: V)
protected open fun afterChange(property: kotlin.reflect.KProperty<*>, oldValue: V, newValue: V): kotlin.Unit
protected open fun beforeChange(property: kotlin.reflect.KProperty<*>, oldValue: V, newValue: V): kotlin.Boolean
public open override operator fun getValue(thisRef: kotlin.Any?, property: kotlin.reflect.KProperty<*>): V
public open override operator fun setValue(thisRef: kotlin.Any?, property: kotlin.reflect.KProperty<*>, value: V): kotlin.Unit
}
@kotlin.SinceKotlin(version = "1.4")
public interface PropertyDelegateProvider<in T, out D> {
public abstract operator fun provideDelegate(thisRef: T, property: kotlin.reflect.KProperty<*>): D
}
public interface ReadOnlyProperty<in T, out V> {
public abstract operator fun getValue(thisRef: T, property: kotlin.reflect.KProperty<*>): V
}
public interface ReadWriteProperty<in T, V> : kotlin.properties.ReadOnlyProperty<T, V> {
public abstract override operator fun getValue(thisRef: T, property: kotlin.reflect.KProperty<*>): V
public abstract operator fun setValue(thisRef: T, property: kotlin.reflect.KProperty<*>, value: V): kotlin.Unit
}