org.mapdb / Atomic / Long / getAndSet

getAndSet

fun getAndSet(newValue: Long): Long

Atomically sets to the given value and returns the old value.

Parameters

newValue - the new value

Return
the previous value