MeshLib JavaScript Docs
Loading...
Searching...
No Matches
Inheritance diagram for BitSet:

Public Member Functions

 BitSet ()
number size ()
number count ()
 computes the number of set bits in the whole set
boolean empty ()
boolean test (number n)
void set (number n, boolean val)
void resize (number numBits, boolean fillValue)
number find_first ()
 return the smallest index i such that bit i is set, or npos if *this has no on bits.
number find_last ()
 return the highest index i such that bit i is set, or npos if *this has no on bits.
Uint32Array toIndices ()

Static Public Member Functions

static BitSet fromIndices (readonly number indices)

Detailed Description

std::vector<bool> like container (random-access, size_t - index type, bool - value type) with all bits after size() considered off during testing

Constructor & Destructor Documentation

◆ BitSet()

BitSet::BitSet ( )

Member Function Documentation

◆ count()

number BitSet::count ( )

computes the number of set bits in the whole set

◆ empty()

boolean BitSet::empty ( )

◆ find_first()

number BitSet::find_first ( )

return the smallest index i such that bit i is set, or npos if *this has no on bits.

◆ find_last()

number BitSet::find_last ( )

return the highest index i such that bit i is set, or npos if *this has no on bits.

◆ fromIndices()

BitSet BitSet::fromIndices ( readonly number indices)
static

◆ resize()

void BitSet::resize ( number numBits,
boolean fillValue )

◆ set()

void BitSet::set ( number n,
boolean val )

◆ size()

number BitSet::size ( )

◆ test()

boolean BitSet::test ( number n)

◆ toIndices()

Uint32Array BitSet::toIndices ( )

The documentation for this class was generated from the following file: