A threeway extension of the boolean type.
More...
#include <utilities/nbooleans.h>
A threeway extension of the boolean type.
Threeway booleans can be true, false or unknown.
 Deprecated:
 NTriBool has now been replaced with native (twoway) bool throughout Regina, and will be removed in some future release.
regina::NTriBool::NTriBool 
( 
 ) 


inline 
Creates a new threeway boolean initialised to the unknown value.
regina::NTriBool::NTriBool 
( 
const NTriBool & 
cloneMe  ) 


inline 
Creates a copy of the given threeway boolean.
 Parameters

cloneMe  the threeway boolean to clone. 
regina::NTriBool::NTriBool 
( 
bool 
value  ) 


inline 
Creates a new threeway boolean whose initial value is the given standard boolean.
 Parameters

value  the value (true or false) to assign to the new threeway boolean. 
bool regina::NTriBool::isFalse 
( 
 ) 
const 

inline 
Is the value of this threeway boolean equal to false?
 Returns
 whether or not this object has the value of false.
bool regina::NTriBool::isKnown 
( 
 ) 
const 

inline 
Does this threeway boolean take one of the explicit values true or false?
Note that this routine is the negation of isUnknown().
 Returns
 whether or not this object has an explicit true or false value.
bool regina::NTriBool::isTrue 
( 
 ) 
const 

inline 
Is the value of this threeway boolean equal to true?
 Returns
 whether or not this object has the value of true.
bool regina::NTriBool::isUnknown 
( 
 ) 
const 

inline 
Is the value of this threeway boolean equal to unknown?
 Returns
 whether or not this object has the value of unknown.
bool regina::NTriBool::operator!= 
( 
const NTriBool & 
other  ) 
const 

inline 
Determines whether this and the given threeway boolean are different.
This routine makes a straightforward comparison of states. That is, true is equal to true, false is equal to false and unknown is equal to unknown.
 Parameters

other  the threeway boolean to compare with this. 
 Returns
true
if and only if this and the given value are different.
bool regina::NTriBool::operator!= 
( 
bool 
other  ) 
const 

inline 
Determines whether this and the given standard boolean are different.
This routine makes a straightforward comparison of states. That is, true is equal to true and false is equal to false. Unknown is equal to neither true nor false.
 Python:
 Not present, to avoid accidental integer conversions in Python.
 Parameters

other  the standard boolean to compare with this. 
 Returns
true
if and only if this and the given value are different.
Returns the conjunction of this and the given value.
Unknown is handled in the intuitive way. For instance, (unknown and true) is unknown, and (unknown and false) is false.
 Parameters

other  the value to combine with this value. 
 Returns
 the conjunction of this and the given value.
NTriBool regina::NTriBool::operator& 
( 
bool 
other  ) 
const 

inline 
Returns the conjunction of this and the given value.
Unknown is handled in the intuitive way. For instance, (unknown and true) is unknown, and (unknown and false) is false.
 Python:
 Not present, to avoid accidental integer conversions in Python.
 Parameters

other  the value to combine with this value. 
 Returns
 the conjunction of this and the given value.
Sets this to be the conjunction of this and the given value.
Unknown is handled in the intuitive way. For instance, (unknown and true) is unknown, and (unknown and false) is false.
 Parameters

other  the value to combine with this value. 
 Returns
 a reference to this object.
NTriBool & regina::NTriBool::operator&= 
( 
bool 
other  ) 


inline 
Sets this to be the conjunction of this and the given value.
Unknown is handled in the intuitive way. For instance, (unknown and true) is unknown, and (unknown and false) is false.
 Python:
 Not present, to avoid accidental integer conversions in Python.
 Parameters

other  the value to combine with this value. 
 Returns
 a reference to this object.
Sets this threeway boolean to be identical to the given threeway boolean.
 Parameters

cloneMe  the value to assign to this object. 
 Returns
 a reference to this object.
NTriBool & regina::NTriBool::operator= 
( 
bool 
cloneMe  ) 


inline 
Sets this threeway boolean to be identical to the given standard boolean.
 Python:
 Not present, to avoid accidental integer conversions in Python.
 Parameters

cloneMe  the value to assign to this object. 
 Returns
 a reference to this object.
bool regina::NTriBool::operator== 
( 
const NTriBool & 
other  ) 
const 

inline 
Determines whether this and the given threeway boolean are equal.
This routine makes a straightforward comparison of states. That is, true is equal to true, false is equal to false and unknown is equal to unknown.
 Parameters

other  the threeway boolean to compare with this. 
 Returns
true
if and only if this and the given value are equal.
bool regina::NTriBool::operator== 
( 
bool 
other  ) 
const 

inline 
Determines whether this and the given standard boolean are equal.
This routine makes a straightforward comparison of states. That is, true is equal to true and false is equal to false. Unknown is equal to neither true nor false.
 Python:
 Not present, to avoid accidental integer conversions in Python.
 Parameters

other  the standard boolean to compare with this. 
 Returns
true
if and only if this and the given value are equal.
Returns the disjunction of this and the given value.
Unknown is handled in the intuitive way. For instance, (unknown or true) is true, and (unknown or false) is unknown.
 Parameters

other  the value to combine with this value. 
 Returns
 the disjunction of this and the given value.
NTriBool regina::NTriBool::operator 
( 
bool 
other  ) 
const 

inline 
Returns the disjunction of this and the given value.
Unknown is handled in the intuitive way. For instance, (unknown or true) is true, and (unknown or false) is unknown.
 Python:
 Not present, to avoid accidental integer conversions in Python.
 Parameters

other  the value to combine with this value. 
 Returns
 the disjunction of this and the given value.
Sets this to be the disjunction of this and the given value.
Unknown is handled in the intuitive way. For instance, (unknown or true) is true, and (unknown or false) is unknown.
 Parameters

other  the value to combine with this value. 
 Returns
 a reference to this object.
NTriBool & regina::NTriBool::operator= 
( 
bool 
other  ) 


inline 
Sets this to be the disjunction of this and the given value.
Unknown is handled in the intuitive way. For instance, (unknown or true) is true, and (unknown or false) is unknown.
 Python:
 Not present, to avoid accidental integer conversions in Python.
 Parameters

other  the value to combine with this value. 
 Returns
 a reference to this object.
NTriBool regina::NTriBool::operator~ 
( 
 ) 
const 

inline 
Returns the negation of this value.
The negation of unknown is unknown.
 Returns
 the negation of this value.
void regina::NTriBool::setFalse 
( 
 ) 


inline 
Sets this threeway boolean to false.
void regina::NTriBool::setTrue 
( 
 ) 


inline 
Sets this threeway boolean to true.
void regina::NTriBool::setUnknown 
( 
 ) 


inline 
Sets this threeway boolean to unknown.
A global instance of the false value.
A global instance of the true value.
const NTriBool regina::NTriBool::Unknown 

static 
A global instance of the unknown value.
The documentation for this class was generated from the following file: