Objects for Results of FEM analysis

This commit is contained in:
jriegel
2013-11-27 20:13:57 +01:00
parent 680f4c82f7
commit feeb053e18
12 changed files with 407 additions and 4 deletions

View File

@@ -136,6 +136,8 @@ public:
void setValues (const std::vector<Base::Vector3d>& values);
void setValue (void){};
const std::vector<Base::Vector3d> &getValues(void) const {
return _lValueList;
}

View File

@@ -523,6 +523,8 @@ public:
/** Sets the property
*/
void setValue(double);
void setValue (void){};
/// index operator
double operator[] (const int idx) const {return _lValueList.operator[] (idx);}

View File

@@ -60,6 +60,14 @@ Base::Quantity PropertyQuantity::getQuantityValue(void) const
return Quantity( _dValue,_Unit);
}
void PropertyQuantity::setValue(const Base::Quantity &quant)
{
aboutToSetValue();
_dValue = quant.getValue();
_Unit = quant.getUnit();
hasSetValue();
}
const char* PropertyQuantity::getEditorName(void) const
{
@@ -90,14 +98,14 @@ void PropertyQuantity::setPyObject(PyObject *value)
Unit unit = quant.getUnit();
if(unit.isEmpty()){
setValue(quant.getValue());
PropertyFloat::setValue(quant.getValue());
return;
}
if (unit != _Unit)
throw Base::Exception("Not matching Unit!");
setValue(quant.getValue());
PropertyFloat::setValue(quant.getValue());
}
//**************************************************************************

View File

@@ -54,6 +54,8 @@ public:
PropertyQuantity(void){}
virtual ~PropertyQuantity(){}
void setValue(const Base::Quantity& quant);
Base::Quantity getQuantityValue(void) const;
virtual const char* getEditorName(void) const;