MRS  1.0
A C++ Class Library for Statistical Set Processing
subpavings::BooleanMappedValue Class Reference

List of all members.

Public Member Functions

 BooleanMappedValue ()
 No-arguments constructor.
 BooleanMappedValue (bool b)
 Constructor.
bool getValue () const
 Get the boolean value represented by this.
void swap (BooleanMappedValue &bv)
 Swap contents of this and another BooleanMappedValue.
Arithmetic operations.
BooleanMappedValueoperator+= (bool b)
const BooleanMappedValue operator+ (bool b) const
BooleanMappedValueoperator+= (const BooleanMappedValue &bv)
const BooleanMappedValue operator+ (const BooleanMappedValue &bv) const
BooleanMappedValueoperator-= (bool b)
const BooleanMappedValue operator- (bool b) const
BooleanMappedValueoperator-= (const BooleanMappedValue &bv)
const BooleanMappedValue operator- (const BooleanMappedValue &bv) const
BooleanMappedValueoperator*= (bool b)
const BooleanMappedValue operator* (bool b) const
BooleanMappedValueoperator*= (const BooleanMappedValue &bv)
const BooleanMappedValue operator* (const BooleanMappedValue &bv) const
BooleanMappedValueoperator/= (bool b)
const BooleanMappedValue operator/ (bool b) const
BooleanMappedValueoperator/= (const BooleanMappedValue &bv)
const BooleanMappedValue operator/ (const BooleanMappedValue &bv) const
Equality and inequality operations.
bool operator== (bool b) const
bool operator== (const BooleanMappedValue &bv) const
bool operator!= (bool b) const
bool operator!= (const BooleanMappedValue &bv) const

Constructor & Destructor Documentation

Constructor.

Parameters:
bthe boolean value to represent with this.
    : value(b) {}

Member Function Documentation

Swap contents of this and another BooleanMappedValue.

Parameters:
bvthe BooleanMappedValue to swap contents with.
{
  if (value && !bv.value) {
    value = false;
    bv.value = true;
  }
  if (!value && bv.value) {
    value = true;
    bv.value = false;
  }
}

The documentation for this class was generated from the following files:
 All Classes Namespaces Functions Variables Typedefs Enumerations Friends