Abstract base class for quality measures. More...
#include <quality.h>
Public Member Functions | |
virtual double | evaluate ()=0 |
virtual double | evaluate3D ()=0 |
virtual QString | getName () |
virtual const char * | getType () const =0 |
QualityMeasure (Grasp *g, QString n) | |
QualityMeasure (qmDlgDataT *data) | |
virtual | ~QualityMeasure () |
Static Public Member Functions | |
static void | buildParamArea (qmDlgDataT *qmData) |
static QualityMeasure * | createInstance (qmDlgDataT *qmData) |
Static Public Attributes | |
static const char * | TYPE_LIST [] = {"Epsilon","Volume",NULL} |
A list of the possible qm types expressed as strings. | |
Protected Attributes | |
Grasp * | grasp |
A pointer to the grasp this qm is associated with. | |
double | val |
The current value of the qm. | |
Private Attributes | |
QString | name |
The user chosen name of this qm instance. |
Abstract base class for quality measures.
A quality measure is associated with a particular grasp. Each individual type of quality measure must be able to build a parameters area for the quality measure dialog box. It also must be able to produce a scalar real value that evaluates its grasp in someway.
Definition at line 79 of file quality.h.
QualityMeasure::QualityMeasure | ( | qmDlgDataT * | qmData | ) |
Sets the name of this QM to the text contained within the name widget. Sets the grasp pointer for this qm to the grasp in qmData.
Definition at line 61 of file quality.cpp.
QualityMeasure::QualityMeasure | ( | Grasp * | g, | |
QString | n | |||
) |
Definition at line 67 of file quality.cpp.
QualityMeasure::~QualityMeasure | ( | ) | [virtual] |
Stub Destructor
Definition at line 76 of file quality.cpp.
void QualityMeasure::buildParamArea | ( | qmDlgDataT * | qmData | ) | [static] |
Calls the appropriate buildParameterArea method from the specific subclass of the quality measure contained within qmData. The type of the qm is determined by examining the string qmData->qmType.
Reimplemented in QualEpsilon, and QualVolume.
Definition at line 90 of file quality.cpp.
QualityMeasure * QualityMeasure::createInstance | ( | qmDlgDataT * | qmData | ) | [static] |
Creates an instance of the specific subclass that is named in the string pointed to by qmData->qmType.
Definition at line 104 of file quality.cpp.
virtual double QualityMeasure::evaluate | ( | ) | [pure virtual] |
Returns the quality of the grasp associated with this qm
Implemented in QualEpsilon, and QualVolume.
virtual double QualityMeasure::evaluate3D | ( | ) | [pure virtual] |
Implemented in QualEpsilon, and QualVolume.
virtual QString QualityMeasure::getName | ( | ) | [inline, virtual] |
virtual const char* QualityMeasure::getType | ( | ) | const [pure virtual] |
Returns the type of this quality measure expressed as a string
Implemented in QualEpsilon, and QualVolume.
Grasp* QualityMeasure::grasp [protected] |
QString QualityMeasure::name [private] |
const char * QualityMeasure::TYPE_LIST = {"Epsilon","Volume",NULL} [static] |
double QualityMeasure::val [protected] |