Cyclic atomic integer variable.

Constructor

new (max:Int)

Methods

inline get ():Int

Returns the variable value.

Returns:

Variable value.

inline increase (?val:Int):Int

Increases the variable value. If the new value is >= maximum value, it is set to 0.

Parameters:

val

Value to add.

Returns:

New variable value.

inline set (val:Int):Void

Sets the variable value.

Parameters:

val

New value.