addTokens

fun addTokens(tokensToAdd: Long)(source)

Adds the specified number of tokensToAdd to the bucket, not exceeding the capacity of the bucket. Delegates directly to the underlying LockFreeBucket's addTokens implementation.

Parameters

tokensToAdd

The number of tokens to add to the bucket.