Bit64

A counter that utilizes 64-bit numbers, providing a maximum count of 2^128.

See also

Constructors

Link copied to clipboard
constructor(lo: Long, hi: Long, incrementBy: Long)

Creates a new Bit64 counter initialized to lo and hi

constructor(incrementBy: Long)

Creates a new Bit64 counter initialized to 0L:0L

Types

Link copied to clipboard
object Companion
Link copied to clipboard

Holder of the count produced by Bit64.final

Properties

Link copied to clipboard
@get:JvmName(name = "hi")
var hi: Long

The most significant bits of the number

Link copied to clipboard
@JvmField
val incrementBy: Long

The value to increment things by

Link copied to clipboard
@get:JvmName(name = "lo")
var lo: Long

The least significant bits of the number

Functions

Link copied to clipboard
open override fun copy(): Counter.Bit64

Copies the instance and its state to a new Counter

Link copied to clipboard
open override fun final(additional: Int): Counter.Bit64.Final

Produces a final count, including any additional value needed to be added (such as the size of buffered input).

Link copied to clipboard
open override fun increment()

Increments the count

Link copied to clipboard
open override fun reset()

Resets the count to 0:0