Sequence of unsigned integer values with specified number bits.
More...
#include <eagine/biteset.hpp>
|
|
constexpr | biteset () noexcept=default |
| | Default constructor.
|
| |
|
template<typename... P, typename = std::enable_if_t< (sizeof...(P) == N) && std::conjunction_v<std::true_type, std::is_convertible<P, T>...>>> |
| constexpr | biteset (P... p) noexcept |
| | Construction from a pack of integer values.
|
| |
| constexpr auto | size () const noexcept -> size_type |
| | Returns the number of elements in this biteset. More...
|
| |
| constexpr auto | get (size_type i) const noexcept |
| | Returns the i-th element in this biteset. More...
|
| |
| void | set (size_type i, T value) noexcept |
| | Sets the i-th element in this biteset. More...
|
| |
|
auto | begin () const noexcept -> const_iterator |
| | Returns an iterator to the start of the sequence.
|
| |
|
auto | end () const noexcept -> const_iterator |
| | Returns an iterator past the end of the sequence.
|
| |
|
auto | begin () noexcept -> iterator |
| | Returns a const iterator to the start of the sequence.
|
| |
|
auto | end () noexcept -> iterator |
| | Returns a const iterator past the end of the sequence.
|
| |
|
constexpr auto | operator[] (size_type i) const noexcept -> biteset_value_proxy< const biteset > |
| | Subscript operator.
|
| |
|
constexpr auto | operator[] (size_type i) noexcept -> biteset_value_proxy< biteset > |
| | Subscript operator.
|
| |
|
constexpr auto | bytes () const noexcept -> const byteset< store_size > & |
| | Converts this biteset into a byteset.
|
| |
|
|
template<typename UIntT > |
| static constexpr auto | from_value (UIntT init) noexcept |
| | Constructs a biteset from the specified values splitting bit groups of size=B.
|
| |
template<std::size_t N, std::size_t B, typename T>
class eagine::biteset< N, B, T >
Sequence of unsigned integer values with specified number bits.
- Template Parameters
-
| N | the size - count of elements - in the sequence. |
| B | the number of bits in each element. |
| T | the type representing a single element outside of the biteset. |
- See also
- byteset
◆ get()
template<std::size_t N, std::size_t B, typename T >
Returns the i-th element in this biteset.
- Precondition
- i < size()
◆ set()
template<std::size_t N, std::size_t B, typename T >
Sets the i-th element in this biteset.
- Precondition
- i < size()
◆ size()
template<std::size_t N, std::size_t B, typename T >
Returns the number of elements in this biteset.
- See also
- get
The documentation for this class was generated from the following file: