#include <Bit.h>
Inheritance diagram for zypp::bit::BitField< _IntT >:
Public Member Functions | |
BitField () | |
Default ctor: zero. | |
BitField (const _IntT &value_r) | |
Ctor taking an _IntT. | |
template<class _Range> | |
_IntT | value () const |
Return the value. | |
_IntT | value () const |
template<class _Range> | |
std::string | asString () const |
Value as bit string. | |
std::string | asString () const |
template<class _Range> | |
BitField & | assign (_IntT rhs) |
Assign Range in rhs to this . | |
BitField & | assign (_IntT rhs) |
template<class _Range> | |
bool | isEqual (_IntT rhs) const |
Test for equal value within a Range. | |
bool | isEqual (_IntT rhs) const |
BitField & | operator= (const BitField &rhs) |
BitField & | operator &= (const BitField &rhs) |
BitField & | operator|= (const BitField &rhs) |
BitField & | operator^= (const BitField &rhs) |
BitField & | operator<<= (unsigned num) |
BitField & | operator>>= (unsigned num) |
BitField | operator~ () const |
Private Types | |
typedef base::SafeBool< BitField< _IntT > >::bool_type | bool_type |
Private Member Functions | |
friend | base::SafeBool () const |
bool | boolTest () const |
SafeBool test. | |
Private Attributes | |
_IntT | _value |
Related Functions | |
(Note that these are not member functions.) | |
std::ostream & | operator<< (std::ostream &str, const BitField< _IntT > &obj) |
bool | operator== (const BitField< _IntT > &lhs, const BitField< _IntT > &rhs) |
bool | operator!= (const BitField< _IntT > &lhs, const BitField< _IntT > &rhs) |
BitField< _IntT > | operator & (const BitField< _IntT > &lhs, const BitField< _IntT > &rhs) |
BitField< _IntT > | operator| (const BitField< _IntT > &lhs, const BitField< _IntT > &rhs) |
BitField< _IntT > | operator^ (const BitField< _IntT > &lhs, const BitField< _IntT > &rhs) |
BitField< _IntT > | operator<< (const BitField< _IntT > &lhs, unsigned num) |
BitField< _IntT > | operator>> (const BitField< _IntT > &lhs, unsigned num) |
Most methods exist as templated and nontemplated version. The nontemplated operates on the complete BitField, while the tamplated ones are restricted to the given Range.
BitField<char> bf; // 00000000 typedef Range<char,2,3> SubField; // bits 2,3,4 in a char field bf<SubField>.assign( -1 ); // assign SubField in -1 // to SubField in bf. // 00011100 bf.assign( -1 ); // assign -1 to bf // 11111111 bf<SubField>.assign( 0 ); // 11100011
Definition at line 161 of file Bit.h.
|
Reimplemented from zypp::base::SafeBool< BitField< _IntT > >. |
|
Default ctor: zero.
|
|
Ctor taking an _IntT.
|
|
Return the value.
Definition at line 183 of file Bit.h. Referenced by zypp::Arch::CompatEntry::compatibleWith(), zypp::ResStatus::getTransactByValue(), zypp::ResStatus::getTransactValue(), zypp::ResStatus::isGreaterThan(), zypp::ResStatus::isLessThan(), zypp::bit::BitField< _IntT >::operator==(), and zypp::ResStatus::setStatus(). |
|
|
|
Value as bit string.
Definition at line 194 of file Bit.h. References zypp::bit::asString(). |
|
Definition at line 198 of file Bit.h. References zypp::bit::asString(). |
|
Assign Range in rhs to
Definition at line 205 of file Bit.h. Referenced by zypp::ResStatus::fieldValueAssign(). |
|
|
|
Test for equal value within a Range.
Definition at line 219 of file Bit.h. Referenced by zypp::ResStatus::fieldValueIs(). |
|
|
|
Definition at line 230 of file Bit.h. References zypp::bit::BitField< _IntT >::_value. |
|
Definition at line 233 of file Bit.h. References zypp::bit::BitField< _IntT >::_value. |
|
Definition at line 236 of file Bit.h. References zypp::bit::BitField< _IntT >::_value. |
|
Definition at line 239 of file Bit.h. References zypp::bit::BitField< _IntT >::_value. |
|
|
|
|
|
|
|
|
|
SafeBool test.
|
|
Stream output |
|
Definition at line 272 of file Bit.h. References zypp::bit::BitField< _IntT >::value(). |
|
|
|
|
|
|
|
|
|
|
|
|
|
Definition at line 258 of file Bit.h. Referenced by zypp::bit::BitField< _IntT >::operator &=(), zypp::bit::BitField< _IntT >::operator=(), zypp::bit::BitField< _IntT >::operator^=(), and zypp::bit::BitField< _IntT >::operator|=(). |