Lock

interface Lock

A read/write lock.

Functions

Link copied to clipboard
abstract fun <T> read(action: () -> T): T

Executes the given action under a read lock.

Link copied to clipboard
abstract fun <T> write(action: () -> T): T

Executes the given action under a write lock.