The python export class for TopoShape. More...
#include <TopoShapeWirePy.h>
Public Types | |
typedef TopoShape * | PointerType |
Public Member Functions | |
PyObject * | _getattr (char *attr) |
GetAttribute implementation This method implements the retriavel of object attributes. | |
virtual PyObject * | _repr (void) |
_repr method Overide this method to return a string object with some invormation about the object. | |
int | _setattr (char *attr, PyObject *value) |
SetAttribute implementation This method implements the seting of object attributes. | |
PyObject * | getCustomAttributes (const char *attr) const |
getter method for special attributes (e.g. dynamic ones) | |
virtual PyParentObject * | GetParents (void) |
TopoShape * | getTopoShapePtr (void) const |
getter for the object handled by this class | |
virtual PyTypeObject * | GetType (void) |
virtual int | PyInit (PyObject *args, PyObject *k) |
PyInit method Overide this method to initialize a newly created instance of the class (Constuctor). | |
std::string | representation (void) const |
int | setCustomAttributes (const char *attr, PyObject *obj) |
setter for special attributes (e.g. dynamic ones) | |
TopoShapeWirePy (TopoShape *pcObject, PyTypeObject *T=&Type) | |
~TopoShapeWirePy () | |
Static Public Member Functions | |
static PyObject * | PyMake (struct _typeobject *, PyObject *, PyObject *) |
Static Public Attributes | |
static PyGetSetDef | GetterSetter [] |
Attribute structure of TopoShapeWirePy. | |
static PyMethodDef | Methods [] |
Methods structure of TopoShapeWirePy. | |
static PyParentObject | Parents [] = { PARENTSPartTopoShapeWirePy } |
static PyTypeObject | Type |
Type structure of TopoShapeWirePy. | |
callbacks and implementers for the python object methods | |
| |
PyObject * | approximate (PyObject *args) |
implementer for the approximate() method | |
PyObject * | makeHomogenousWires (PyObject *args) |
implementer for the makeHomogenousWires() method | |
PyObject * | makeOffset (PyObject *args) |
implementer for the makeOffset() method | |
PyObject * | makePipe (PyObject *args) |
implementer for the makePipe() method | |
PyObject * | makePipeShell (PyObject *args) |
implementer for the makePipeShell() method | |
static PyObject * | staticCallback_approximate (PyObject *self, PyObject *args) |
callback for the approximate() method | |
static PyObject * | staticCallback_makeHomogenousWires (PyObject *self, PyObject *args) |
callback for the makeHomogenousWires() method | |
static PyObject * | staticCallback_makeOffset (PyObject *self, PyObject *args) |
callback for the makeOffset() method | |
static PyObject * | staticCallback_makePipe (PyObject *self, PyObject *args) |
callback for the makePipe() method | |
static PyObject * | staticCallback_makePipeShell (PyObject *self, PyObject *args) |
callback for the makePipeShell() method | |
callbacks and implementers for the python object attributes | |
| |
Py::Object | getCenterOfMass (void) const |
getter for the CenterOfMass attribute | |
static PyObject * | staticCallback_getCenterOfMass (PyObject *self, void *closure) |
getter callback for the CenterOfMass attribute | |
static int | staticCallback_setCenterOfMass (PyObject *self, PyObject *value, void *closure) |
setter callback for the CenterOfMass attribute |
The python export class for TopoShape.
Definition at line 20 of file TopoShapeWirePy.h.
Reimplemented from Part::TopoShapePy.
Definition at line 36 of file TopoShapeWirePy.h.
Definition at line 538 of file TopoShapeWirePy.cpp.
Referenced by makeHomogenousWires(), and PyMake().
TopoShapeWirePy::~TopoShapeWirePy | ( | ) |
Definition at line 547 of file TopoShapeWirePy.cpp.
PyObject * TopoShapeWirePy::_getattr | ( | char * | attr | ) | [virtual] |
GetAttribute implementation This method implements the retriavel of object attributes.
If you want to implement attributes in your class, reimplement this method. You have to call the method of the base class. Note: if you reimplement _gettattr() in a inheriting class you need to call the method of the base class! Otherwise even the methods of the object will disapiear!
Reimplemented from Part::TopoShapePy.
Definition at line 562 of file TopoShapeWirePy.cpp.
References Base::Console(), getCustomAttributes(), Methods, Base::Exception::ReportException(), and Base::Exception::what().
PyObject * TopoShapeWirePy::_repr | ( | void | ) | [virtual] |
_repr method Overide this method to return a string object with some invormation about the object.
PyObject *MeshFeaturePy::_repr(void) { std::stringstream a; a << "MeshFeature: [ "; a << "some realy important info about the object!"; a << "]" << std::endl; return Py_BuildValue("s", a.str().c_str()); }
Reimplemented from Part::TopoShapePy.
Definition at line 554 of file TopoShapeWirePy.cpp.
References representation().
int TopoShapeWirePy::_setattr | ( | char * | attr, | |
PyObject * | value | |||
) | [virtual] |
SetAttribute implementation This method implements the seting of object attributes.
If you want to implement attributes in your class, reimplement this method. You have to call the method of the base class.
Reimplemented from Part::TopoShapePy.
Definition at line 630 of file TopoShapeWirePy.cpp.
References Base::Console(), Base::Exception::ReportException(), setCustomAttributes(), and Base::Exception::what().
implementer for the approximate() method
Definition at line 225 of file TopoShapeWirePyImp.cpp.
References getTopoShapePtr().
Py::Object TopoShapeWirePy::getCenterOfMass | ( | void | ) | const |
getter for the CenterOfMass attribute
Definition at line 252 of file TopoShapeWirePyImp.cpp.
References getTopoShapePtr().
Referenced by staticCallback_getCenterOfMass().
PyObject * TopoShapeWirePy::getCustomAttributes | ( | const char * | attr | ) | const |
getter method for special attributes (e.g. dynamic ones)
Reimplemented from Part::TopoShapePy.
Definition at line 260 of file TopoShapeWirePyImp.cpp.
Referenced by _getattr().
virtual PyParentObject* Part::TopoShapeWirePy::GetParents | ( | void | ) | [inline, virtual] |
Reimplemented from Part::TopoShapePy.
Definition at line 28 of file TopoShapeWirePy.h.
TopoShape * TopoShapeWirePy::getTopoShapePtr | ( | void | ) | const |
getter for the object handled by this class
Reimplemented from Part::TopoShapePy.
Definition at line 689 of file TopoShapeWirePy.cpp.
References Base::PyObjectBase::_pcTwinPointer.
Referenced by approximate(), getCenterOfMass(), makeHomogenousWires(), makeOffset(), makePipe(), makePipeShell(), PyInit(), and representation().
virtual PyTypeObject* Part::TopoShapeWirePy::GetType | ( | void | ) | [inline, virtual] |
Reimplemented from Part::TopoShapePy.
Definition at line 27 of file TopoShapeWirePy.h.
implementer for the makeHomogenousWires() method
Definition at line 199 of file TopoShapeWirePyImp.cpp.
References Part::TopoShape::_Shape, getTopoShapePtr(), TopoShapeWirePy(), and Type.
implementer for the makeOffset() method
Definition at line 138 of file TopoShapeWirePyImp.cpp.
References draftlibs::fcvec::dist(), getTopoShapePtr(), Part::TopoShapePy::TopoShapePy(), and RobotExample::w.
implementer for the makePipe() method
Definition at line 151 of file TopoShapeWirePyImp.cpp.
References Part::TopoShape::_Shape, getTopoShapePtr(), Part::TopoShape::makePipe(), Part::TopoShapePy::TopoShapePy(), and Part::TopoShapePy::Type.
implementer for the makePipeShell() method
Definition at line 170 of file TopoShapeWirePyImp.cpp.
References Part::TopoShape::_Shape, Py::SeqBase< T >::begin(), Py::SeqBase< T >::end(), getTopoShapePtr(), Part::TopoShape::makePipeShell(), Part::TopoShapePy::TopoShapePy(), and Part::TopoShapePy::Type.
PyInit method Overide this method to initialize a newly created instance of the class (Constuctor).
Reimplemented from Part::TopoShapePy.
Definition at line 66 of file TopoShapeWirePyImp.cpp.
References Part::TopoShape::_Shape, Py::SeqBase< T >::begin(), Py::SeqBase< T >::end(), getTopoShapePtr(), and Part::TopoShapePy::Type.
Reimplemented from Part::TopoShapePy.
Definition at line 59 of file TopoShapeWirePyImp.cpp.
References TopoShapeWirePy().
std::string TopoShapeWirePy::representation | ( | void | ) | const |
Reimplemented from Part::TopoShapePy.
Definition at line 51 of file TopoShapeWirePyImp.cpp.
References getTopoShapePtr().
Referenced by _repr().
int TopoShapeWirePy::setCustomAttributes | ( | const char * | attr, | |
PyObject * | obj | |||
) |
setter for special attributes (e.g. dynamic ones)
Reimplemented from Part::TopoShapePy.
Definition at line 265 of file TopoShapeWirePyImp.cpp.
Referenced by _setattr().
PyObject * TopoShapeWirePy::staticCallback_approximate | ( | PyObject * | self, | |
PyObject * | args | |||
) | [static] |
callback for the approximate() method
Definition at line 423 of file TopoShapeWirePy.cpp.
References Base::Console(), Base::PyObjectBase::isConst(), Base::PyObjectBase::isValid(), Base::PyObjectBase::PyObjectBase(), Base::Exception::ReportException(), and Base::Exception::what().
PyObject * TopoShapeWirePy::staticCallback_getCenterOfMass | ( | PyObject * | self, | |
void * | closure | |||
) | [static] |
getter callback for the CenterOfMass attribute
Definition at line 499 of file TopoShapeWirePy.cpp.
References getCenterOfMass(), Base::PyObjectBase::isValid(), Py::new_reference_to(), and Base::PyObjectBase::PyObjectBase().
PyObject * TopoShapeWirePy::staticCallback_makeHomogenousWires | ( | PyObject * | self, | |
PyObject * | args | |||
) | [static] |
callback for the makeHomogenousWires() method
Definition at line 195 of file TopoShapeWirePy.cpp.
References Base::Console(), Base::PyObjectBase::isConst(), Base::PyObjectBase::isValid(), Base::PyObjectBase::PyObjectBase(), Base::Exception::ReportException(), and Base::Exception::what().
callback for the makeOffset() method
Definition at line 119 of file TopoShapeWirePy.cpp.
References Base::Console(), Base::PyObjectBase::isConst(), Base::PyObjectBase::isValid(), Base::PyObjectBase::PyObjectBase(), Base::Exception::ReportException(), and Base::Exception::what().
callback for the makePipe() method
Definition at line 271 of file TopoShapeWirePy.cpp.
References Base::Console(), Base::PyObjectBase::isConst(), Base::PyObjectBase::isValid(), Base::PyObjectBase::PyObjectBase(), Base::Exception::ReportException(), and Base::Exception::what().
PyObject * TopoShapeWirePy::staticCallback_makePipeShell | ( | PyObject * | self, | |
PyObject * | args | |||
) | [static] |
callback for the makePipeShell() method
Definition at line 347 of file TopoShapeWirePy.cpp.
References Base::Console(), Base::PyObjectBase::isConst(), Base::PyObjectBase::isValid(), Base::PyObjectBase::PyObjectBase(), Base::Exception::ReportException(), and Base::Exception::what().
int TopoShapeWirePy::staticCallback_setCenterOfMass | ( | PyObject * | self, | |
PyObject * | value, | |||
void * | closure | |||
) | [static] |
setter callback for the CenterOfMass attribute
Definition at line 517 of file TopoShapeWirePy.cpp.
References Base::PyObjectBase::isValid(), and Base::PyObjectBase::PyObjectBase().
PyGetSetDef TopoShapeWirePy::GetterSetter [static] |
{ {"CenterOfMass", (getter) staticCallback_getCenterOfMass, (setter) staticCallback_setCenterOfMass, "Returns the center of mass of the current system.\nIf the gravitational field is uniform, it is the center of gravity.\nThe coordinates returned for the center of mass are expressed in the\nabsolute Cartesian coordinate system.", NULL }, {NULL, NULL, NULL, NULL, NULL} }
Attribute structure of TopoShapeWirePy.
Reimplemented from Part::TopoShapePy.
Definition at line 25 of file TopoShapeWirePy.h.
PyMethodDef TopoShapeWirePy::Methods [static] |
{ {"makeOffset", (PyCFunction) staticCallback_makeOffset, METH_VARARGS, "Offset the shape by a given ammount" }, {"makeHomogenousWires", (PyCFunction) staticCallback_makeHomogenousWires, METH_VARARGS, "Make this and the given wire homogenous to have the same number of edges" }, {"makePipe", (PyCFunction) staticCallback_makePipe, METH_VARARGS, "Make a pipe by sweeping along a wire." }, {"makePipeShell", (PyCFunction) staticCallback_makePipeShell, METH_VARARGS, "Make a loft defined by profiles along a wire." }, {"approximate", (PyCFunction) staticCallback_approximate, METH_VARARGS, "Approximate B-Spline-curve from this wire" }, {NULL, NULL, 0, NULL} }
Methods structure of TopoShapeWirePy.
Reimplemented from Part::TopoShapePy.
Definition at line 24 of file TopoShapeWirePy.h.
Referenced by _getattr().
PyParentObject TopoShapeWirePy::Parents = { PARENTSPartTopoShapeWirePy } [static] |
Reimplemented from Part::TopoShapePy.
Definition at line 26 of file TopoShapeWirePy.h.
PyTypeObject TopoShapeWirePy::Type [static] |
Type structure of TopoShapeWirePy.
Reimplemented from Part::TopoShapePy.
Definition at line 23 of file TopoShapeWirePy.h.
Referenced by initPart(), and makeHomogenousWires().