OpenCog Framework
Branch: master, revision 6f0b7fc776b08468cf1b74aa9db028f387b4f0c0
|
#include <TruthValue.h>
Public Member Functions | |
virtual | ~TruthValue () |
virtual strength_t | getMean () const =0 |
virtual confidence_t | getConfidence () const =0 |
virtual count_t | getCount () const =0 |
virtual std::string | toString () const =0 |
virtual TruthValueType | getType () const =0 |
virtual TruthValuePtr | clone () const =0 |
virtual TruthValue * | rawclone () const =0 |
virtual bool | operator== (const TruthValue &rhs) const =0 |
bool | operator!= (const TruthValue &rhs) const |
virtual TruthValuePtr | merge (TruthValuePtr, TVMergeStyle ms=DEFAULT) const =0 |
virtual bool | isNullTv () const |
virtual bool | isDefaultTV () const |
Static Public Member Functions | |
static TruthValuePtr | NULL_TV () |
static TruthValuePtr | TRUE_TV () |
static TruthValuePtr | DEFAULT_TV () |
static TruthValuePtr | FALSE_TV () |
static TruthValuePtr | TRIVIAL_TV () |
Private Member Functions | |
TruthValue & | operator= (const TruthValue &rhs) |
Friends | |
class | SavingLoading |
class | Atom |
class | ::TruthValueUTest |
Definition at line 88 of file TruthValue.h.
|
inlinevirtual |
Definition at line 103 of file TruthValue.h.
|
pure virtual |
Implemented in opencog::IndefiniteTruthValue, opencog::FuzzyTruthValue, opencog::SimpleTruthValue, opencog::CountTruthValue, opencog::ProbabilisticTruthValue, and opencog::NullTruthValue.
|
static |
The shared reference to a special default (Simple) TruthValue object with MAX_TRUTH mean and 0 count. That is, its true, but with no confidence.
Definition at line 52 of file TruthValue.cc.
References MAX_TRUTH.
|
static |
The shared reference to a special FALSE (Simple) TruthValue object with 0 mean and MAX_TV_CONFIDENCE count. That is, its false with absolute confidence.
Definition at line 66 of file TruthValue.cc.
|
pure virtual |
Implemented in opencog::IndefiniteTruthValue, opencog::FuzzyTruthValue, opencog::SimpleTruthValue, opencog::CountTruthValue, opencog::ProbabilisticTruthValue, and opencog::NullTruthValue.
|
pure virtual |
Implemented in opencog::IndefiniteTruthValue, opencog::FuzzyTruthValue, opencog::SimpleTruthValue, opencog::CountTruthValue, opencog::ProbabilisticTruthValue, and opencog::NullTruthValue.
|
pure virtual |
Implemented in opencog::IndefiniteTruthValue, opencog::FuzzyTruthValue, opencog::SimpleTruthValue, opencog::CountTruthValue, opencog::ProbabilisticTruthValue, and opencog::NullTruthValue.
|
pure virtual |
Implemented in opencog::IndefiniteTruthValue, opencog::FuzzyTruthValue, opencog::SimpleTruthValue, opencog::CountTruthValue, opencog::ProbabilisticTruthValue, and opencog::NullTruthValue.
|
virtual |
Check if this TV is equal to the default TV. operator!= only compares pointers
Definition at line 85 of file TruthValue.cc.
References DEFAULT_TV(), getCount(), getMean(), and getType().
|
virtual |
Check if this TV is a null TV.
Reimplemented in opencog::NullTruthValue.
Definition at line 80 of file TruthValue.cc.
|
pure virtual |
Merge this TV object with the given TV object argument. It always returns a new TV object with the result of the merge, even if it is equal to one of the merged TV objects.
ms | the merge style as described in https://github.com/opencog/opencog/issues/1295 |
Implemented in opencog::IndefiniteTruthValue, opencog::FuzzyTruthValue, opencog::SimpleTruthValue, opencog::CountTruthValue, opencog::ProbabilisticTruthValue, and opencog::NullTruthValue.
|
static |
The shared reference to a special NullTruthValue object. This is supposed to be used only for book-keeping, and it must not be used as a normal TV object. Calling methods on it will throw exceptions.
Definition at line 46 of file TruthValue.cc.
|
inline |
Definition at line 156 of file TruthValue.h.
|
inlineprivate |
Definition at line 99 of file TruthValue.h.
|
pure virtual |
Equality. Used to determine if two truth values are the same, or not. Primarily useful see if a TV is equal to NULL_TV, TRUE_TV, FALSE_TV, etc.
Implemented in opencog::IndefiniteTruthValue, opencog::FuzzyTruthValue, opencog::SimpleTruthValue, opencog::CountTruthValue, opencog::ProbabilisticTruthValue, and opencog::NullTruthValue.
|
pure virtual |
|
pure virtual |
Implemented in opencog::IndefiniteTruthValue, opencog::FuzzyTruthValue, opencog::SimpleTruthValue, opencog::CountTruthValue, opencog::ProbabilisticTruthValue, and opencog::NullTruthValue.
|
static |
The shared reference to a special TRIVIAL (Simple) TruthValue object with 0 mean and 0 count. That is, its false, but with no confidence.
Definition at line 73 of file TruthValue.cc.
|
static |
The shared reference to a special TRUE (Simple) TruthValue object with MAX_TRUTH mean and MAX_TV_CONFIDENCE count. That is, its true with absolute confidence.
Definition at line 59 of file TruthValue.cc.
References MAX_TRUTH.
|
friend |
Definition at line 96 of file TruthValue.h.
|
friend |
Definition at line 92 of file TruthValue.h.
|
friend |
Definition at line 91 of file TruthValue.h.