Added setValue/getValue/canonicalPath/getPaths/verifyPath methods to various Property classes.
This commit is contained in:
+30
-1
@@ -34,13 +34,14 @@
|
||||
#include <Base/Reader.h>
|
||||
#include <Base/Stream.h>
|
||||
#include <Base/Rotation.h>
|
||||
#include <Base/Quantity.h>
|
||||
#include <Base/VectorPy.h>
|
||||
#include <Base/MatrixPy.h>
|
||||
#include <Base/PlacementPy.h>
|
||||
|
||||
#include "Placement.h"
|
||||
|
||||
#include "PropertyGeo.h"
|
||||
#include "ObjectIdentifier.h"
|
||||
|
||||
using namespace App;
|
||||
using namespace Base;
|
||||
@@ -538,6 +539,34 @@ const Base::Placement & PropertyPlacement::getValue(void)const
|
||||
return _cPos;
|
||||
}
|
||||
|
||||
void PropertyPlacement::getPaths(std::vector<ObjectIdentifier> &paths) const
|
||||
{
|
||||
paths.push_back(ObjectIdentifier(getContainer()) << ObjectIdentifier::Component::SimpleComponent(getName())
|
||||
<< ObjectIdentifier::Component::SimpleComponent(ObjectIdentifier::String("Base"))
|
||||
<< ObjectIdentifier::Component::SimpleComponent(ObjectIdentifier::String("x")));
|
||||
paths.push_back(ObjectIdentifier(getContainer()) << ObjectIdentifier::Component::SimpleComponent(getName())
|
||||
<< ObjectIdentifier::Component::SimpleComponent(ObjectIdentifier::String("Base"))
|
||||
<< ObjectIdentifier::Component::SimpleComponent(ObjectIdentifier::String("y")));
|
||||
paths.push_back(ObjectIdentifier(getContainer()) << ObjectIdentifier::Component::SimpleComponent(getName())
|
||||
<< ObjectIdentifier::Component::SimpleComponent(ObjectIdentifier::String("Base"))
|
||||
<< ObjectIdentifier::Component::SimpleComponent(ObjectIdentifier::String("z")));
|
||||
paths.push_back(ObjectIdentifier(getContainer()) << ObjectIdentifier::Component::SimpleComponent(getName())
|
||||
<< ObjectIdentifier::Component::SimpleComponent(ObjectIdentifier::String("Rotation"))
|
||||
<< ObjectIdentifier::Component::SimpleComponent(ObjectIdentifier::String("Angle")));
|
||||
paths.push_back(ObjectIdentifier(getContainer()) << ObjectIdentifier::Component::SimpleComponent(getName())
|
||||
<< ObjectIdentifier::Component::SimpleComponent(ObjectIdentifier::String("Rotation"))
|
||||
<< ObjectIdentifier::Component::SimpleComponent(ObjectIdentifier::String("Axis"))
|
||||
<< ObjectIdentifier::Component::SimpleComponent(ObjectIdentifier::String("x")));
|
||||
paths.push_back(ObjectIdentifier(getContainer()) << ObjectIdentifier::Component::SimpleComponent(getName())
|
||||
<< ObjectIdentifier::Component::SimpleComponent(ObjectIdentifier::String("Rotation"))
|
||||
<< ObjectIdentifier::Component::SimpleComponent(ObjectIdentifier::String("Axis"))
|
||||
<< ObjectIdentifier::Component::SimpleComponent(ObjectIdentifier::String("y")));
|
||||
paths.push_back(ObjectIdentifier(getContainer()) << ObjectIdentifier::Component::SimpleComponent(getName())
|
||||
<< ObjectIdentifier::Component::SimpleComponent(ObjectIdentifier::String("Rotation"))
|
||||
<< ObjectIdentifier::Component::SimpleComponent(ObjectIdentifier::String("Axis"))
|
||||
<< ObjectIdentifier::Component::SimpleComponent(ObjectIdentifier::String("z")));
|
||||
}
|
||||
|
||||
PyObject *PropertyPlacement::getPyObject(void)
|
||||
{
|
||||
return new Base::PlacementPy(new Base::Placement(_cPos));
|
||||
|
||||
Reference in New Issue
Block a user