SizeBound

case class SizeBound(lowerBound: Long, upperBound: Option[Long])

Bounds the size, in bits, of the binary encoding of a codec -- i.e., it provides a lower bound and an upper bound on the size of bit vectors returned as a result of encoding.

Bounds the size, in bits, of the binary encoding of a codec -- i.e., it provides a lower bound and an upper bound on the size of bit vectors returned as a result of encoding.

Value Params
lowerBound

Minimum number of bits

upperBound

Maximum number of bits

Companion
object
trait Serializable
trait Product
trait Equals
class Object
trait Matchable
class Any

Value members

Concrete methods

def *(n: Long): SizeBound

Multiplies this size bound by the specified scalar.

Multiplies this size bound by the specified scalar.

def +(that: SizeBound): SizeBound

Adds the specified size bound to this size bound.

Adds the specified size bound to this size bound.

Returns a new bound with the upper bound removed.

Returns a new bound with the upper bound removed.

Returns a new bound with the lower bound reset to 0.

Returns a new bound with the lower bound reset to 0.

def exact: Option[Long]

Returns the exact size of the encoded bits. Defined when the lower bound is equal to the upper bound.

Returns the exact size of the encoded bits. Defined when the lower bound is equal to the upper bound.

override def toString: String
Definition Classes
Any
def |(that: SizeBound): SizeBound

ORs the specified size bound with this size bound, resulting in a new bound which has the minimum lower bound and maximum upper bound.

ORs the specified size bound with this size bound, resulting in a new bound which has the minimum lower bound and maximum upper bound.

Inherited methods

def productElementNames: Iterator[String]
Inherited from
Product
def productIterator: Iterator[Any]
Inherited from
Product