vertx / io.vertx.reactivex.core.shareddata / Counter / rxCompareAndSet

rxCompareAndSet

open fun rxCompareAndSet(expected: Long, value: Long): Single<Boolean>

Set the counter to the specified value only if the current value is the expectec value. This happens atomically.

Parameters

expected - the expected value

value - the new value

Return