SynchronizedObject
SynchronizedObject from kotlinx.atomicfu.locks
SynchronizedObject is designed for inheritance. You write class MyClass : SynchronizedObject()
and then use synchronized(instance) { ... }
extension function similarly to the synchronized function from the standard library that is available for JVM. The SynchronizedObject superclass gets erased (transformed to Any) on JVM and JS, with synchronized
leaving no trace in the code on JS and getting replaced with built-in monitors for locking on JVM.
SynchronizedObject from kotlinx.atomicfu.locks
SynchronizedObject is designed for inheritance. You write class MyClass : SynchronizedObject()
and then use synchronized(instance) { ... }
extension function similarly to the synchronized function from the standard library that is available for JVM. The SynchronizedObject superclass gets erased (transformed to Any) on JVM and JS, with synchronized
leaving no trace in the code on JS and getting replaced with built-in monitors for locking on JVM.
SynchronizedObject from kotlinx.atomicfu.locks
SynchronizedObject is designed for inheritance. You write class MyClass : SynchronizedObject()
and then use synchronized(instance) { ... }
extension function similarly to the synchronized function from the standard library that is available for JVM. The SynchronizedObject superclass gets erased (transformed to Any) on JVM and JS, with synchronized
leaving no trace in the code on JS and getting replaced with built-in monitors for locking on JVM.
SynchronizedObject from kotlinx.atomicfu.locks
SynchronizedObject is designed for inheritance. You write class MyClass : SynchronizedObject()
and then use synchronized(instance) { ... }
extension function similarly to the synchronized function from the standard library that is available for JVM. The SynchronizedObject superclass gets erased (transformed to Any) on JVM and JS, with synchronized
leaving no trace in the code on JS and getting replaced with built-in monitors for locking on JVM.