libstdc++
std::tr2::dynamic_bitset< _WordT, _Alloc >::reference Class Reference

Public Member Functions

 reference (dynamic_bitset &__b, size_type __pos) noexcept
 
referenceflip () noexcept
 
 operator bool () const noexcept
 
referenceoperator= (bool __x) noexcept
 
referenceoperator= (const reference &__j) noexcept
 
bool operator~ () const noexcept
 

Friends

class dynamic_bitset
 

Detailed Description

template<typename _WordT = unsigned long long, typename _Alloc = std::allocator<_WordT>>
class std::tr2::dynamic_bitset< _WordT, _Alloc >::reference

This encapsulates the concept of a single bit. An instance of this class is a proxy for an actual bit; this way the individual bit operations are done as faster word-size bitwise instructions.

Most users will never need to use this class directly; conversions to and from bool are automatic and should be transparent. Overloaded operators help to preserve the illusion.

(On a typical system, this "bit %reference" is 64 times the size of an actual bit. Ha.)

Definition at line 513 of file dynamic_bitset.

Constructor & Destructor Documentation

◆ reference()

template<typename _WordT = unsigned long long, typename _Alloc = std::allocator<_WordT>>
std::tr2::dynamic_bitset< _WordT, _Alloc >::reference::reference ( dynamic_bitset __b,
size_type  __pos 
)
inlinenoexcept

Definition at line 521 of file dynamic_bitset.

Member Function Documentation

◆ flip()

template<typename _WordT = unsigned long long, typename _Alloc = std::allocator<_WordT>>
reference & std::tr2::dynamic_bitset< _WordT, _Alloc >::reference::flip ( )
inlinenoexcept

Definition at line 560 of file dynamic_bitset.

◆ operator bool()

template<typename _WordT = unsigned long long, typename _Alloc = std::allocator<_WordT>>
std::tr2::dynamic_bitset< _WordT, _Alloc >::reference::operator bool ( ) const
inlinenoexcept

Definition at line 555 of file dynamic_bitset.

◆ operator=() [1/2]

template<typename _WordT = unsigned long long, typename _Alloc = std::allocator<_WordT>>
reference & std::tr2::dynamic_bitset< _WordT, _Alloc >::reference::operator= ( bool  __x)
inlinenoexcept

Definition at line 529 of file dynamic_bitset.

◆ operator=() [2/2]

template<typename _WordT = unsigned long long, typename _Alloc = std::allocator<_WordT>>
reference & std::tr2::dynamic_bitset< _WordT, _Alloc >::reference::operator= ( const reference __j)
inlinenoexcept

Definition at line 540 of file dynamic_bitset.

◆ operator~()

template<typename _WordT = unsigned long long, typename _Alloc = std::allocator<_WordT>>
bool std::tr2::dynamic_bitset< _WordT, _Alloc >::reference::operator~ ( ) const
inlinenoexcept

Definition at line 551 of file dynamic_bitset.

Friends And Related Symbol Documentation

◆ dynamic_bitset

template<typename _WordT = unsigned long long, typename _Alloc = std::allocator<_WordT>>
friend class dynamic_bitset
friend

Definition at line 515 of file dynamic_bitset.


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