|
sparrow 2.2.1
C++20 idiomatic APIs for the Apache Arrow Columnar Format
|
A proxy reference class that provides mutable access to individual bits in a bitset. More...
#include <bitset_reference.hpp>
Public Types | |
| using | self_type = bitset_reference<B> |
| This class type for convenience. | |
Public Member Functions | |
| constexpr | bitset_reference (const bitset_reference &) noexcept=default |
| constexpr | bitset_reference (bitset_reference &&) noexcept=default |
| constexpr self_type & | operator= (const self_type &rhs) noexcept |
| Copy assignment from another bitset_reference. | |
| constexpr self_type & | operator= (self_type &&rhs) noexcept |
| Move assignment from another bitset_reference. | |
| constexpr self_type & | operator= (bool value) noexcept |
| Assignment from a boolean value. | |
| constexpr | operator bool () const noexcept |
| Implicit conversion to bool. | |
| constexpr bool | operator~ () const noexcept |
| Bitwise NOT operator. | |
| constexpr self_type & | operator&= (bool rhs) noexcept |
| Bitwise AND assignment. | |
| constexpr self_type & | operator|= (bool rhs) noexcept |
| Bitwise OR assignment. | |
| constexpr self_type & | operator^= (bool rhs) noexcept |
| Bitwise XOR assignment. | |
Friends | |
| class | bitset_iterator< B, false > |
| Mutable iterator needs access to create references. | |
| template<typename RAR, null_count_policy NCP> | |
| class | dynamic_bitset_base |
| Bitset base class needs access to create references. | |
A proxy reference class that provides mutable access to individual bits in a bitset.
This class acts as a smart reference that allows individual bits in a bitset to be treated as if they were regular boolean references, despite being stored as packed bits within integer blocks. It provides a complete set of boolean operations and assignment operators to make bit manipulation transparent to the user.
The reference maintains a pointer to the owning bitset and the index of the bit it represents. All operations are forwarded to the appropriate bitset methods, ensuring that null count tracking and other internal state remain consistent.
| B | The bitset type that contains the referenced bit. Must be a type that provides test() and set() methods with appropriate signatures. |
Example usage:
Definition at line 58 of file bitset_reference.hpp.
| using sparrow::bitset_reference< B >::self_type = bitset_reference<B> |
This class type for convenience.
Definition at line 62 of file bitset_reference.hpp.
|
constexprdefaultnoexcept |
|
constexprdefaultnoexcept |
|
constexprnoexcept |
Implicit conversion to bool.
Definition at line 229 of file bitset_reference.hpp.
|
constexprnoexcept |
Bitwise AND assignment.
| rhs | The boolean value to AND with the referenced bit |
Definition at line 241 of file bitset_reference.hpp.
|
constexprnoexcept |
Assignment from a boolean value.
| value | The boolean value to assign to the referenced bit |
Definition at line 222 of file bitset_reference.hpp.
|
constexprnoexcept |
Copy assignment from another bitset_reference.
| rhs | The reference to copy the value from |
Definition at line 208 of file bitset_reference.hpp.
|
constexprnoexcept |
Move assignment from another bitset_reference.
| rhs | The reference to move the value from |
Definition at line 215 of file bitset_reference.hpp.
|
constexprnoexcept |
Bitwise XOR assignment.
| rhs | The boolean value to XOR with the referenced bit |
Definition at line 261 of file bitset_reference.hpp.
|
constexprnoexcept |
Bitwise OR assignment.
| rhs | The boolean value to OR with the referenced bit |
Definition at line 251 of file bitset_reference.hpp.
|
constexprnoexcept |
Bitwise NOT operator.
Definition at line 235 of file bitset_reference.hpp.
|
friend |
Mutable iterator needs access to create references.
Definition at line 176 of file bitset_reference.hpp.
|
friend |
Bitset base class needs access to create references.
Definition at line 181 of file bitset_reference.hpp.