AtomicLongExtras

scribe.handler.AtomicLongExtras
final class AtomicLongExtras(val value: AtomicLong) extends AnyVal

Attributes

Graph
Supertypes
class AnyVal
trait Matchable
class Any

Members list

Value members

Concrete methods

def ++: Long

Increments and returns the new value

Increments and returns the new value

Attributes

def +=(value: Long): Long

Adds the value and returns the new value

Adds the value and returns the new value

Attributes

def --: Long

Decrements and returns the new value

Decrements and returns the new value

Attributes

def -=(value: Long): Long

Subtracts the value and returns the new value

Subtracts the value and returns the new value

Attributes

def decrementIfGreaterThan(min: Long): Boolean

Decrements the value if the current value is greater than the max value supplied.

Decrements the value if the current value is greater than the max value supplied.

This method is thread-safe without locking.

Attributes

def incrementIfLessThan(max: Int): Boolean

Increments the value if the current value is less than the max value supplied.

Increments the value if the current value is less than the max value supplied.

This method is thread-safe without locking.

Attributes

final def modify(f: Long => Option[Long]): Boolean

Modifies the value atomicly without locking if the resulting value of the function is Some.

Modifies the value atomicly without locking if the resulting value of the function is Some.

Attributes

def setIfCondition(condition: Long => Boolean, value: Long): Boolean

Concrete fields

val value: AtomicLong