gloomex v0.2.0 Gloomex.BitArray
This module implements a bit array using Erlang's :array
module.
Link to this section Summary
Functions
Amount of bits used by the atomic array
Returns true
if the bitarray has the i
th bit set,
otherwise returns false
.
Returns a new bitarray of size n
.
Updates a bitarray
Link to this section Types
Specs
t() :: :array.array(term())
Link to this section Functions
Link to this function
bit_size(a)
Amount of bits used by the atomic array
Link to this function
get(a, i)
Specs
get(t(), non_neg_integer()) :: boolean()
Returns true
if the bitarray has the i
th bit set,
otherwise returns false
.
Link to this function
new(n)
Specs
new(pos_integer()) :: t()
Returns a new bitarray of size n
.
Link to this function
set(a, i)
Specs
set(t(), non_neg_integer()) :: t()
Updates a bitarray