diff --git a/src/App/DocumentObject.cpp b/src/App/DocumentObject.cpp index 33398a10b..00f6411a5 100644 --- a/src/App/DocumentObject.cpp +++ b/src/App/DocumentObject.cpp @@ -272,7 +272,7 @@ void DocumentObject::setExpression(const ObjectIdentifier &path, boost::shared_p const PropertyExpressionEngine::ExpressionInfo DocumentObject::getExpression(const ObjectIdentifier &path) const { - boost::any value = ExpressionEngine.getValue(path); + boost::any value = ExpressionEngine.getPathValue(path); if (value.type() == typeid(PropertyExpressionEngine::ExpressionInfo)) return boost::any_cast(value); diff --git a/src/App/Expression.cpp b/src/App/Expression.cpp index 431e2d9ea..104a2de04 100644 --- a/src/App/Expression.cpp +++ b/src/App/Expression.cpp @@ -1007,7 +1007,7 @@ Expression * VariableExpression::eval() const if (!parent->isDerivedFrom(App::DocumentObject::getClassTypeId())) throw ExpressionError("Property must belong to a document object."); - boost::any value = prop->getValue(var); + boost::any value = prop->getPathValue(var); if (value.type() == typeid(Quantity)) { Quantity qvalue = boost::any_cast(value); diff --git a/src/App/Property.cpp b/src/App/Property.cpp index 3d5c6ff95..35590a20a 100644 --- a/src/App/Property.cpp +++ b/src/App/Property.cpp @@ -83,12 +83,12 @@ void Property::setContainer(PropertyContainer *Father) father = Father; } -void Property::setValue(const ObjectIdentifier &path, const boost::any &value) +void Property::setPathValue(const ObjectIdentifier &path, const boost::any &value) { path.setValue(value); } -const boost::any Property::getValue(const ObjectIdentifier &path) const +const boost::any Property::getPathValue(const ObjectIdentifier &path) const { return path.getValue(); } diff --git a/src/App/Property.h b/src/App/Property.h index 26236a803..cd3908357 100644 --- a/src/App/Property.h +++ b/src/App/Property.h @@ -88,10 +88,10 @@ public: PropertyContainer *getContainer(void) const {return father;} /// Set value of property - virtual void setValue(const App::ObjectIdentifier & path, const boost::any & value); + virtual void setPathValue(const App::ObjectIdentifier & path, const boost::any & value); /// Get value of property - virtual const boost::any getValue(const App::ObjectIdentifier & path) const; + virtual const boost::any getPathValue(const App::ObjectIdentifier & path) const; /// Convert p to a canonical representation of it virtual const App::ObjectIdentifier canonicalPath(const App::ObjectIdentifier & p) const; diff --git a/src/App/PropertyExpressionEngine.cpp b/src/App/PropertyExpressionEngine.cpp index 841fe32a8..634db77bc 100644 --- a/src/App/PropertyExpressionEngine.cpp +++ b/src/App/PropertyExpressionEngine.cpp @@ -284,7 +284,7 @@ void PropertyExpressionEngine::slotObjectRenamed(const DocumentObject &obj) * @return Expression for \a path, or empty boost::any if not found. */ -const boost::any PropertyExpressionEngine::getValue(const App::ObjectIdentifier & path) const +const boost::any PropertyExpressionEngine::getPathValue(const App::ObjectIdentifier & path) const { // Get a canonical path ObjectIdentifier usePath(canonicalPath(path)); @@ -310,7 +310,7 @@ void PropertyExpressionEngine::setValue(const ObjectIdentifier & path, boost::sh const Property * prop = usePath.getProperty(); // Try to access value; it should trigger an exception if it is not supported, or if the path is invalid - prop->getValue(usePath); + prop->getPathValue(usePath); if (expr) { std::string error = validateExpression(usePath, expr); @@ -486,7 +486,7 @@ DocumentObjectExecReturn *App::PropertyExpressionEngine::execute() #endif /* Set value of property */ - prop->setValue(*it, e->getValueAsAny()); + prop->setPathValue(*it, e->getValueAsAny()); ++it; } diff --git a/src/App/PropertyExpressionEngine.h b/src/App/PropertyExpressionEngine.h index 5b222bb41..61ec9834f 100644 --- a/src/App/PropertyExpressionEngine.h +++ b/src/App/PropertyExpressionEngine.h @@ -93,7 +93,7 @@ public: void setValue(const App::ObjectIdentifier &path, boost::shared_ptr expr, const char * comment = 0); - const boost::any getValue(const App::ObjectIdentifier & path) const; + const boost::any getPathValue(const App::ObjectIdentifier & path) const; DocumentObjectExecReturn * execute(); diff --git a/src/App/PropertyStandard.cpp b/src/App/PropertyStandard.cpp index 062a9f390..983e19263 100644 --- a/src/App/PropertyStandard.cpp +++ b/src/App/PropertyStandard.cpp @@ -133,7 +133,7 @@ void PropertyInteger::Paste(const Property &from) hasSetValue(); } -void PropertyInteger::setValue(const ObjectIdentifier &path, const boost::any &value) +void PropertyInteger::setPathValue(const ObjectIdentifier &path, const boost::any &value) { verifyPath(path); @@ -481,7 +481,7 @@ void PropertyEnumeration::Paste(const Property &from) hasSetValue(); } -void PropertyEnumeration::setValue(const ObjectIdentifier &path, const boost::any &value) +void PropertyEnumeration::setPathValue(const ObjectIdentifier &path, const boost::any &value) { verifyPath(path); @@ -959,7 +959,7 @@ void PropertyFloat::Paste(const Property &from) hasSetValue(); } -void PropertyFloat::setValue(const ObjectIdentifier &path, const boost::any &value) +void PropertyFloat::setPathValue(const ObjectIdentifier &path, const boost::any &value) { verifyPath(path); @@ -971,7 +971,7 @@ void PropertyFloat::setValue(const ObjectIdentifier &path, const boost::any &val throw bad_cast(); } -const boost::any PropertyFloat::getValue(const ObjectIdentifier &path) const +const boost::any PropertyFloat::getPathValue(const ObjectIdentifier &path) const { verifyPath(path); return _dValue; @@ -1347,12 +1347,12 @@ unsigned int PropertyString::getMemSize (void) const return static_cast(_cValue.size()); } -void PropertyString::setValue(const ObjectIdentifier &path, const boost::any &value) +void PropertyString::setPathValue(const ObjectIdentifier &path, const boost::any &value) { verifyPath(path); } -const boost::any PropertyString::getValue(const ObjectIdentifier &path) const +const boost::any PropertyString::getPathValue(const ObjectIdentifier &path) const { verifyPath(path); return _cValue; @@ -1906,7 +1906,7 @@ void PropertyBool::Paste(const Property &from) hasSetValue(); } -void PropertyBool::setValue(const ObjectIdentifier &path, const boost::any &value) +void PropertyBool::setPathValue(const ObjectIdentifier &path, const boost::any &value) { verifyPath(path); @@ -1922,7 +1922,7 @@ void PropertyBool::setValue(const ObjectIdentifier &path, const boost::any &valu throw bad_cast(); } -const boost::any PropertyBool::getValue(const ObjectIdentifier &path) const +const boost::any PropertyBool::getPathValue(const ObjectIdentifier &path) const { verifyPath(path); diff --git a/src/App/PropertyStandard.h b/src/App/PropertyStandard.h index 7e2d78342..b43ca928b 100644 --- a/src/App/PropertyStandard.h +++ b/src/App/PropertyStandard.h @@ -77,8 +77,8 @@ public: virtual unsigned int getMemSize (void) const{return sizeof(long);} - virtual void setValue(const App::ObjectIdentifier & path, const boost::any & value); - virtual const boost::any getValue(const App::ObjectIdentifier & path) const { return _lValue; } + virtual void setPathValue(const App::ObjectIdentifier & path, const boost::any & value); + virtual const boost::any getPathValue(const App::ObjectIdentifier & path) const { return _lValue; } protected: long _lValue; @@ -198,8 +198,8 @@ public: virtual Property * Copy(void) const; virtual void Paste(const Property &from); - virtual void setValue(const App::ObjectIdentifier & path, const boost::any & value); - virtual const boost::any getValue(const App::ObjectIdentifier & path) const { return _enum; } + virtual void setPathValue(const App::ObjectIdentifier & path, const boost::any & value); + virtual const boost::any getPathValue(const App::ObjectIdentifier & path) const { return _enum; } private: Enumeration _enum; @@ -459,8 +459,8 @@ public: virtual unsigned int getMemSize (void) const{return sizeof(double);} - void setValue(const App::ObjectIdentifier &path, const boost::any &value); - const boost::any getValue(const App::ObjectIdentifier &path) const; + void setPathValue(const App::ObjectIdentifier &path, const boost::any &value); + const boost::any getPathValue(const App::ObjectIdentifier &path) const; protected: double _dValue; @@ -614,8 +614,8 @@ public: virtual void Paste(const Property &from); virtual unsigned int getMemSize (void) const; - void setValue(const App::ObjectIdentifier &path, const boost::any &value); - const boost::any getValue(const App::ObjectIdentifier &path) const; + void setPathValue(const App::ObjectIdentifier &path, const boost::any &value); + const boost::any getPathValue(const App::ObjectIdentifier &path) const; private: std::string _cValue; @@ -768,8 +768,8 @@ public: virtual unsigned int getMemSize (void) const{return sizeof(bool);} - void setValue(const App::ObjectIdentifier &path, const boost::any &value); - const boost::any getValue(const App::ObjectIdentifier &path) const; + void setPathValue(const App::ObjectIdentifier &path, const boost::any &value); + const boost::any getPathValue(const App::ObjectIdentifier &path) const; private: bool _lValue; diff --git a/src/App/PropertyUnits.cpp b/src/App/PropertyUnits.cpp index 90865ff1f..72c9626ab 100644 --- a/src/App/PropertyUnits.cpp +++ b/src/App/PropertyUnits.cpp @@ -118,7 +118,7 @@ void PropertyQuantity::setPyObject(PyObject *value) PropertyFloat::setValue(quant.getValue()); } -void PropertyQuantity::setValue(const ObjectIdentifier &path, const boost::any &value) +void PropertyQuantity::setPathValue(const ObjectIdentifier &path, const boost::any &value) { if (value.type() == typeid(double)) setValue(boost::any_cast(value)); @@ -128,7 +128,7 @@ void PropertyQuantity::setValue(const ObjectIdentifier &path, const boost::any & throw bad_cast(); } -const boost::any PropertyQuantity::getValue(const ObjectIdentifier &path) const +const boost::any PropertyQuantity::getPathValue(const ObjectIdentifier &path) const { return Quantity(_dValue, _Unit); } diff --git a/src/App/PropertyUnits.h b/src/App/PropertyUnits.h index e2ee9f062..771cc175d 100644 --- a/src/App/PropertyUnits.h +++ b/src/App/PropertyUnits.h @@ -68,8 +68,8 @@ public: void setValue(double lValue) { PropertyFloat::setValue(lValue); } double getValue(void) const { return PropertyFloat::getValue(); } - virtual void setValue(const App::ObjectIdentifier &path, const boost::any &value); - virtual const boost::any getValue(const App::ObjectIdentifier &path) const; + virtual void setPathValue(const App::ObjectIdentifier &path, const boost::any &value); + virtual const boost::any getPathValue(const App::ObjectIdentifier &path) const; protected: Base::Quantity createQuantityFromPy(PyObject *value); diff --git a/src/Mod/Sketcher/App/PropertyConstraintList.cpp b/src/Mod/Sketcher/App/PropertyConstraintList.cpp index e0e5ddb85..039e52ab6 100644 --- a/src/Mod/Sketcher/App/PropertyConstraintList.cpp +++ b/src/Mod/Sketcher/App/PropertyConstraintList.cpp @@ -408,7 +408,7 @@ int PropertyConstraintList::getIndexFromConstraintName(const string &name) return std::atoi(name.substr(10,4000).c_str()) - 1; } -void PropertyConstraintList::setValue(const ObjectIdentifier &path, const boost::any &value) +void PropertyConstraintList::setPathValue(const ObjectIdentifier &path, const boost::any &value) { const ObjectIdentifier::Component & c0 = path.getPropertyComponent(0); double dvalue; @@ -464,7 +464,7 @@ const Constraint * PropertyConstraintList::getConstraint(const ObjectIdentifier throw Base::Exception("Invalid constraint"); } -const boost::any PropertyConstraintList::getValue(const ObjectIdentifier &path) const +const boost::any PropertyConstraintList::getPathValue(const ObjectIdentifier &path) const { return boost::any(getConstraint(path)->getValue()); } diff --git a/src/Mod/Sketcher/App/PropertyConstraintList.h b/src/Mod/Sketcher/App/PropertyConstraintList.h index 898aaf098..931a99d0e 100644 --- a/src/Mod/Sketcher/App/PropertyConstraintList.h +++ b/src/Mod/Sketcher/App/PropertyConstraintList.h @@ -103,8 +103,8 @@ public: const Constraint *getConstraint(const App::ObjectIdentifier &path) const; - virtual void setValue(const App::ObjectIdentifier & path, const boost::any & value); - virtual const boost::any getValue(const App::ObjectIdentifier & path) const; + virtual void setPathValue(const App::ObjectIdentifier & path, const boost::any & value); + virtual const boost::any getPathValue(const App::ObjectIdentifier & path) const; virtual const App::ObjectIdentifier canonicalPath(const App::ObjectIdentifier & p) const; virtual void getPaths(std::vector & paths) const;