17 #ifndef HH_SENF_Packets_BitsetParser_ 18 #define HH_SENF_Packets_BitsetParser_ 1 23 #include <boost/integer/static_min_max.hpp> 32 static std::size_t
bytePosition(std::size_t totalBytes, std::size_t bitPos);
33 static std::size_t
bit(std::size_t bitPos);
38 static std::size_t
bytePosition(std::size_t totalBytes, std::size_t bitPos);
39 static std::size_t
bit(std::size_t bitPos);
43 template <std::
size_t N,
typename Endianness>
51 static size_type const fixed_bytes = N/8 + boost::static_unsigned_min<1u, N % 8>::value;
59 bool operator~()
const;
60 operator bool()
const;
70 void set(std::size_t pos,
bool v =
true);
73 void reset(std::size_t pos);
76 void flip(std::size_t pos);
82 bool test(std::size_t pos)
const;
84 bool operator[](std::size_t pos)
const;
87 std::size_t size()
const;
88 std::size_t
count()
const;
90 void value(value_type
const & bset);
91 value_type value()
const;
PacketParser public header.
unspecified_keyword_type parser
static std::size_t bit(std::size_t bitPos)
BitsetParser(data_iterator i, state_type s)
Packet data STL-sequence view.
detail::packet::size_type size_type
Unsigned integral type.
static std::size_t bytePosition(std::size_t totalBytes, std::size_t bitPos)
std::bitset< N > value_type
detail::packet::iterator data_iterator
Raw data iterator type.