|
|
constexpr size_type * | data () |
| |
|
constexpr const size_type * | data () const |
| |
|
GAIA_NODISCARD constexpr uint32_t | items () const |
| | Returns the number of words used by the bitset internally.
|
| |
|
constexpr iter | begin () const |
| |
|
constexpr iter | end () const |
| |
|
constexpr iter_rev | rbegin () const |
| |
|
constexpr iter_rev | rend () const |
| |
|
constexpr iter_inv | ibegin () const |
| |
|
constexpr iter_inv | iend () const |
| |
|
constexpr iter_rev_inv | ribegin () const |
| |
|
constexpr iter_rev_inv | riend () const |
| |
|
GAIA_NODISCARD constexpr bool | operator[] (uint32_t pos) const |
| |
|
GAIA_NODISCARD constexpr bool | operator== (const bitset &other) const |
| |
|
GAIA_NODISCARD constexpr bool | operator!= (const bitset &other) const |
| |
|
constexpr void | set () |
| | Sets all bits.
|
| |
| constexpr void | set (uint32_t pos, bool value=true) |
| | Sets the bit at the given position.
|
| |
|
constexpr bitset & | flip () |
| | Flips all bits.
|
| |
| constexpr void | flip (uint32_t pos) |
| | Flips the bit at the postion.
|
| |
| constexpr bitset & | flip (uint32_t bitFrom, uint32_t bitTo) |
| | Flips all bits from.
|
| |
|
constexpr void | reset () |
| | Unsets all bits.
|
| |
| constexpr void | reset (uint32_t pos) |
| | Unsets the bit at the postion.
|
| |
| GAIA_NODISCARD constexpr bool | test (uint32_t pos) const |
| | Returns the value of the bit at the position.
|
| |
|
GAIA_NODISCARD constexpr bool | all () const |
| | Checks if all bits are set.
|
| |
|
GAIA_NODISCARD constexpr bool | any () const |
| | Checks if any bit is set.
|
| |
|
GAIA_NODISCARD constexpr bool | none () const |
| | Checks if all bits are reset.
|
| |
|
GAIA_NODISCARD uint32_t | count () const |
| | Returns the number of set bits.
|
| |
|
GAIA_NODISCARD constexpr uint32_t | size () const |
| | Returns the number of bits the bitset can hold.
|
| |
|
|
friend | iter |
| |
|
friend | iter_inv |
| |
|
friend | iter_rev |
| |
|
friend | iter_rev_inv |
| |
|
|
static constexpr uint32_t | BitCount = NBits |
| |
|
static constexpr uint32_t | BitsPerItem = (NBits / 64) > 0 ? 64 : 32 |
| |
|
static constexpr uint32_t | Items = (NBits + BitsPerItem - 1) / BitsPerItem |
| |
◆ flip() [1/2]
Flips all bits from.
- Parameters
-
| bitFrom | to |
| bitTo | (including) |
◆ flip() [2/2]
Flips the bit at the postion.
- Parameters
-
◆ reset()
Unsets the bit at the postion.
- Parameters
-
◆ set()
Sets the bit at the given position.
- Parameters
-
| pos | Bit position to set (0-based, must be < NBits) |
| value | Value to set the bit to. Defaults to true. |
◆ test()
Returns the value of the bit at the position.
- Parameters
-
The documentation for this class was generated from the following file:
- /home/runner/work/gaia-ecs/gaia-ecs/include/gaia/cnt/bitset.h