Part::SpherePy Class Reference

The python export class for GeomSphere. More...

#include <SpherePy.h>

Inheritance diagram for Part::SpherePy:
Part::GeometrySurfacePy Part::GeometryPy Base::PyObjectBase

List of all members.

Public Types

typedef GeomSpherePointerType

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.
PyObjectgetCustomAttributes (const char *attr) const
 getter method for special attributes (e.g. dynamic ones)
GeomSpheregetGeomSpherePtr (void) const
 getter for the object handled by this class
virtual PyParentObjectGetParents (void)
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)
 SpherePy (GeomSphere *pcObject, PyTypeObject *T=&Type)
 ~SpherePy ()

Static Public Member Functions

static PyObjectPyMake (struct _typeobject *, PyObject *, PyObject *)

Static Public Attributes

static PyGetSetDef GetterSetter []
 Attribute structure of SpherePy.
static PyMethodDef Methods []
 Methods structure of SpherePy.
static PyParentObject Parents [] = { PARENTSPartSpherePy }
static PyTypeObject Type
 Type structure of SpherePy.

callbacks and implementers for the python object attributes



Py::Float getArea (void) const
 getter for the Area attribute
Py::Object getAxis (void) const
 getter for the Axis attribute
Py::Object getCenter (void) const
 getter for the Center attribute
Py::Float getRadius (void) const
 getter for the Radius attribute
Py::Float getVolume (void) const
 getter for the Volume attribute
void setAxis (Py::Object arg)
 setter for the Axis attribute
void setCenter (Py::Object arg)
 setter for the Center attribute
void setRadius (Py::Float arg)
 setter for the Radius attribute
static PyObjectstaticCallback_getArea (PyObject *self, void *closure)
 getter callback for the Area attribute
static PyObjectstaticCallback_getAxis (PyObject *self, void *closure)
 getter callback for the Axis attribute
static PyObjectstaticCallback_getCenter (PyObject *self, void *closure)
 getter callback for the Center attribute
static PyObjectstaticCallback_getRadius (PyObject *self, void *closure)
 getter callback for the Radius attribute
static PyObjectstaticCallback_getVolume (PyObject *self, void *closure)
 getter callback for the Volume attribute
static int staticCallback_setArea (PyObject *self, PyObject *value, void *closure)
 setter callback for the Area attribute
static int staticCallback_setAxis (PyObject *self, PyObject *value, void *closure)
 setter callback for the Axis attribute
static int staticCallback_setCenter (PyObject *self, PyObject *value, void *closure)
 setter callback for the Center attribute
static int staticCallback_setRadius (PyObject *self, PyObject *value, void *closure)
 setter callback for the Radius attribute
static int staticCallback_setVolume (PyObject *self, PyObject *value, void *closure)
 setter callback for the Volume attribute

callbacks and implementers for the python object methods



PyObjectuIso (PyObject *args)
 implementer for the uIso() method
PyObjectvIso (PyObject *args)
 implementer for the vIso() method
static PyObjectstaticCallback_uIso (PyObject *self, PyObject *args)
 callback for the uIso() method
static PyObjectstaticCallback_vIso (PyObject *self, PyObject *args)
 callback for the vIso() method

Detailed Description

The python export class for GeomSphere.

Definition at line 20 of file SpherePy.h.


Member Typedef Documentation

Reimplemented from Part::GeometrySurfacePy.

Definition at line 36 of file SpherePy.h.


Constructor & Destructor Documentation

SpherePy::SpherePy ( GeomSphere pcObject,
PyTypeObject *  T = &Type 
)

Definition at line 483 of file SpherePy.cpp.

Referenced by PyMake().

SpherePy::~SpherePy (  ) 

Definition at line 492 of file SpherePy.cpp.


Member Function Documentation

PyObject * SpherePy::_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::GeometrySurfacePy.

Definition at line 507 of file SpherePy.cpp.

References Base::Console(), getCustomAttributes(), Methods, Base::Exception::ReportException(), and Base::Exception::what().

PyObject * SpherePy::_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::GeometrySurfacePy.

Definition at line 499 of file SpherePy.cpp.

References representation().

int SpherePy::_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::GeometrySurfacePy.

Definition at line 575 of file SpherePy.cpp.

References Base::Console(), Base::Exception::ReportException(), setCustomAttributes(), and Base::Exception::what().

Py::Float SpherePy::getArea ( void   )  const

getter for the Area attribute

Definition at line 96 of file SpherePyImp.cpp.

References getGeomSpherePtr(), and StartPage::StartPage::handle().

Referenced by staticCallback_getArea().

Py::Object SpherePy::getAxis ( void   )  const

getter for the Axis attribute

Definition at line 140 of file SpherePyImp.cpp.

References Part::GeometryPy::getGeometryPtr(), and StartPage::StartPage::handle().

Referenced by staticCallback_getAxis().

Py::Object SpherePy::getCenter ( void   )  const

getter for the Center attribute

Definition at line 110 of file SpherePyImp.cpp.

References getGeomSpherePtr(), and StartPage::StartPage::handle().

Referenced by staticCallback_getCenter().

PyObject * SpherePy::getCustomAttributes ( const char *  attr  )  const

getter method for special attributes (e.g. dynamic ones)

Reimplemented from Part::GeometrySurfacePy.

Definition at line 221 of file SpherePyImp.cpp.

Referenced by _getattr().

GeomSphere * SpherePy::getGeomSpherePtr ( void   )  const

getter for the object handled by this class

Definition at line 634 of file SpherePy.cpp.

References Base::PyObjectBase::_pcTwinPointer.

Referenced by getArea(), getCenter(), getRadius(), getVolume(), PyInit(), representation(), setCenter(), setRadius(), uIso(), and vIso().

virtual PyParentObject* Part::SpherePy::GetParents ( void   )  [inline, virtual]

Reimplemented from Part::GeometrySurfacePy.

Definition at line 28 of file SpherePy.h.

Py::Float SpherePy::getRadius ( void   )  const

getter for the Radius attribute

Definition at line 82 of file SpherePyImp.cpp.

References getGeomSpherePtr(), and StartPage::StartPage::handle().

Referenced by staticCallback_getRadius().

virtual PyTypeObject* Part::SpherePy::GetType ( void   )  [inline, virtual]

Reimplemented from Part::GeometrySurfacePy.

Definition at line 27 of file SpherePy.h.

Py::Float SpherePy::getVolume ( void   )  const

getter for the Volume attribute

Definition at line 103 of file SpherePyImp.cpp.

References getGeomSpherePtr(), and StartPage::StartPage::handle().

Referenced by staticCallback_getVolume().

int SpherePy::PyInit ( PyObject ,
PyObject  
) [virtual]

PyInit method Overide this method to initialize a newly created instance of the class (Constuctor).

Reimplemented from Part::GeometrySurfacePy.

Definition at line 70 of file SpherePyImp.cpp.

References getGeomSpherePtr(), and StartPage::StartPage::handle().

PyObject * SpherePy::PyMake ( struct _typeobject *  ,
PyObject ,
PyObject  
) [static]

Reimplemented from Part::GeometrySurfacePy.

Definition at line 63 of file SpherePyImp.cpp.

References SpherePy().

std::string SpherePy::representation ( void   )  const

Reimplemented from Part::GeometrySurfacePy.

Definition at line 44 of file SpherePyImp.cpp.

References getGeomSpherePtr(), and StartPage::StartPage::handle().

Referenced by _repr().

void SpherePy::setAxis ( Py::Object  arg  ) 
void SpherePy::setCenter ( Py::Object  arg  ) 
int SpherePy::setCustomAttributes ( const char *  attr,
PyObject obj 
)

setter for special attributes (e.g. dynamic ones)

Reimplemented from Part::GeometrySurfacePy.

Definition at line 226 of file SpherePyImp.cpp.

Referenced by _setattr().

void SpherePy::setRadius ( Py::Float  arg  ) 

setter for the Radius attribute

Definition at line 89 of file SpherePyImp.cpp.

References getGeomSpherePtr(), and StartPage::StartPage::handle().

PyObject * SpherePy::staticCallback_getArea ( PyObject self,
void *  closure 
) [static]

getter callback for the Area attribute

Definition at line 324 of file SpherePy.cpp.

References getArea(), Base::PyObjectBase::isValid(), Py::new_reference_to(), and Base::PyObjectBase::PyObjectBase().

PyObject * SpherePy::staticCallback_getAxis ( PyObject self,
void *  closure 
) [static]

getter callback for the Axis attribute

Definition at line 432 of file SpherePy.cpp.

References getAxis(), Base::PyObjectBase::isValid(), Py::new_reference_to(), and Base::PyObjectBase::PyObjectBase().

PyObject * SpherePy::staticCallback_getCenter ( PyObject self,
void *  closure 
) [static]

getter callback for the Center attribute

Definition at line 388 of file SpherePy.cpp.

References getCenter(), Base::PyObjectBase::isValid(), Py::new_reference_to(), and Base::PyObjectBase::PyObjectBase().

PyObject * SpherePy::staticCallback_getRadius ( PyObject self,
void *  closure 
) [static]

getter callback for the Radius attribute

Definition at line 280 of file SpherePy.cpp.

References getRadius(), Base::PyObjectBase::isValid(), Py::new_reference_to(), and Base::PyObjectBase::PyObjectBase().

PyObject * SpherePy::staticCallback_getVolume ( PyObject self,
void *  closure 
) [static]

getter callback for the Volume attribute

Definition at line 356 of file SpherePy.cpp.

References getVolume(), Base::PyObjectBase::isValid(), Py::new_reference_to(), and Base::PyObjectBase::PyObjectBase().

int SpherePy::staticCallback_setArea ( PyObject self,
PyObject value,
void *  closure 
) [static]

setter callback for the Area attribute

Definition at line 342 of file SpherePy.cpp.

References Base::PyObjectBase::isValid(), and Base::PyObjectBase::PyObjectBase().

int SpherePy::staticCallback_setAxis ( PyObject self,
PyObject value,
void *  closure 
) [static]

setter callback for the Axis attribute

Definition at line 450 of file SpherePy.cpp.

References Base::PyObjectBase::isConst(), Base::PyObjectBase::isValid(), and Base::PyObjectBase::PyObjectBase().

int SpherePy::staticCallback_setCenter ( PyObject self,
PyObject value,
void *  closure 
) [static]

setter callback for the Center attribute

Definition at line 406 of file SpherePy.cpp.

References Base::PyObjectBase::isConst(), Base::PyObjectBase::isValid(), and Base::PyObjectBase::PyObjectBase().

int SpherePy::staticCallback_setRadius ( PyObject self,
PyObject value,
void *  closure 
) [static]

setter callback for the Radius attribute

Definition at line 298 of file SpherePy.cpp.

References Base::PyObjectBase::isConst(), Base::PyObjectBase::isValid(), and Base::PyObjectBase::PyObjectBase().

int SpherePy::staticCallback_setVolume ( PyObject self,
PyObject value,
void *  closure 
) [static]

setter callback for the Volume attribute

Definition at line 374 of file SpherePy.cpp.

References Base::PyObjectBase::isValid(), and Base::PyObjectBase::PyObjectBase().

PyObject * SpherePy::staticCallback_uIso ( PyObject self,
PyObject args 
) [static]
PyObject * SpherePy::staticCallback_vIso ( PyObject self,
PyObject args 
) [static]
PyObject * SpherePy::uIso ( PyObject args  ) 

implementer for the uIso() method

Definition at line 183 of file SpherePyImp.cpp.

References getGeomSpherePtr(), and StartPage::StartPage::handle().

PyObject * SpherePy::vIso ( PyObject args  ) 

implementer for the vIso() method

Definition at line 202 of file SpherePyImp.cpp.

References getGeomSpherePtr(), and StartPage::StartPage::handle().


Member Data Documentation

PyGetSetDef SpherePy::GetterSetter [static]

Attribute structure of SpherePy.

Reimplemented from Part::GeometrySurfacePy.

Definition at line 25 of file SpherePy.h.

PyMethodDef SpherePy::Methods [static]
Initial value:
 {
    {"uIso",
        (PyCFunction) staticCallback_uIso,
        METH_VARARGS,
        "\n                                     Builds the U isoparametric circle of this sphere\n                              "
    },
    {"vIso",
        (PyCFunction) staticCallback_vIso,
        METH_VARARGS,
        "Builds the V isoparametric circle of this sphere \nwhere V must be in the range [-Pi/2,Pi/2]"
    },
    {NULL, NULL, 0, NULL}               
}

Methods structure of SpherePy.

Reimplemented from Part::GeometrySurfacePy.

Definition at line 24 of file SpherePy.h.

Referenced by _getattr().

PyParentObject SpherePy::Parents = { PARENTSPartSpherePy } [static]

Reimplemented from Part::GeometrySurfacePy.

Definition at line 26 of file SpherePy.h.

PyTypeObject SpherePy::Type [static]

Type structure of SpherePy.

Reimplemented from Part::GeometrySurfacePy.

Definition at line 23 of file SpherePy.h.

Referenced by initPart().


The documentation for this class was generated from the following files:

Generated on Wed Nov 23 19:02:36 2011 for FreeCAD by  doxygen 1.6.1