Part::GeomSurfaceOfExtrusion Class Reference

#include <Geometry.h>

Inheritance diagram for Part::GeomSurfaceOfExtrusion:
Part::GeomSurface Part::Geometry Base::Persistence Base::BaseClass

List of all members.

Public Member Functions

virtual Geometryclone (void) const
 returns a cloned object
 GeomSurfaceOfExtrusion (const Handle_Geom_SurfaceOfLinearExtrusion &)
 GeomSurfaceOfExtrusion (const Handle_Geom_Curve &, const gp_Dir &)
 GeomSurfaceOfExtrusion ()
virtual unsigned int getMemSize (void) const
 This method is used to get the size of objects It is not meant to have the exact size, it is more or less an estimation which runs fast! Is it two bytes or a GB?
virtual PyObjectgetPyObject (void)
 This method returns the Python wrapper for a C++ object.
virtual Base::Type getTypeId (void) const
const Handle_Geom_Geometry & handle () const
virtual void Restore (Base::XMLReader &)
 This method is used to restore properties from an XML document.
virtual void Save (Base::Writer &) const
 This method is used to save properties to an XML document.
void setHandle (const Handle_Geom_SurfaceOfLinearExtrusion &c)
virtual ~GeomSurfaceOfExtrusion ()

Static Public Member Functions

static void * create (void)
static Base::Type getClassTypeId (void)
static void init (void)

Detailed Description

Definition at line 633 of file Geometry.h.


Constructor & Destructor Documentation

GeomSurfaceOfExtrusion::GeomSurfaceOfExtrusion (  ) 

Definition at line 1712 of file Geometry.cpp.

Referenced by clone().

GeomSurfaceOfExtrusion::GeomSurfaceOfExtrusion ( const Handle_Geom_Curve &  c,
const gp_Dir &  d 
)

Definition at line 1716 of file Geometry.cpp.

GeomSurfaceOfExtrusion::GeomSurfaceOfExtrusion ( const Handle_Geom_SurfaceOfLinearExtrusion &  s  ) 

Definition at line 1721 of file Geometry.cpp.

GeomSurfaceOfExtrusion::~GeomSurfaceOfExtrusion (  )  [virtual]

Definition at line 1726 of file Geometry.cpp.


Member Function Documentation

Geometry * GeomSurfaceOfExtrusion::clone ( void   )  const [virtual]

returns a cloned object

Implements Part::Geometry.

Definition at line 1740 of file Geometry.cpp.

References Part::Geometry::Construction, and GeomSurfaceOfExtrusion().

Referenced by getPyObject().

void * Part::GeomSurfaceOfExtrusion::create ( void   )  [static]

Reimplemented from Part::GeomSurface.

Definition at line 1710 of file Geometry.cpp.

Base::Type Part::GeomSurfaceOfExtrusion::getClassTypeId ( void   )  [static]

Reimplemented from Part::GeomSurface.

Definition at line 1710 of file Geometry.cpp.

unsigned int GeomSurfaceOfExtrusion::getMemSize ( void   )  const [virtual]

This method is used to get the size of objects It is not meant to have the exact size, it is more or less an estimation which runs fast! Is it two bytes or a GB?

Reimplemented from Part::Geometry.

Definition at line 1748 of file Geometry.cpp.

PyObject * GeomSurfaceOfExtrusion::getPyObject ( void   )  [virtual]

This method returns the Python wrapper for a C++ object.

It's in the responsibility of the programmer to do the correct reference counting. Basically there are two ways how to implement that: Either always return a new Python object then reference counting is not a matter or return always the same Python object then the reference counter must be incremented by one. However, it's absolutely forbidden to return always the same Python object without incrementing the reference counter.

The default implementation returns 'None'.

Reimplemented from Base::BaseClass.

Definition at line 1752 of file Geometry.cpp.

References clone().

Base::Type Part::GeomSurfaceOfExtrusion::getTypeId ( void   )  const [virtual]

Reimplemented from Part::GeomSurface.

Definition at line 1710 of file Geometry.cpp.

const Handle_Geom_Geometry & GeomSurfaceOfExtrusion::handle (  )  const [virtual]

Implements Part::Geometry.

Definition at line 1735 of file Geometry.cpp.

void Part::GeomSurfaceOfExtrusion::init ( void   )  [static]

Reimplemented from Part::GeomSurface.

Definition at line 1710 of file Geometry.cpp.

Referenced by initPart().

void GeomSurfaceOfExtrusion::Restore ( Base::XMLReader  )  [virtual]

This method is used to restore properties from an XML document.

It uses the XMLReader class, which bases on SAX, to read the in Save() written information. Again the Vector as an example:

 void PropertyVector::Restore(Base::XMLReader &reader)
 {
   // read my Element
   reader.readElement("PropertyVector");
   // get the value of my Attribute
   _cVec.x = (float)reader.getAttributeAsFloat("valueX");
   _cVec.y = (float)reader.getAttributeAsFloat("valueY");
   _cVec.z = (float)reader.getAttributeAsFloat("valueZ");
 }

Reimplemented from Part::Geometry.

Definition at line 1750 of file Geometry.cpp.

void GeomSurfaceOfExtrusion::Save ( Base::Writer  )  const [virtual]

This method is used to save properties to an XML document.

A good example you'll find in PropertyStandard.cpp, e.g. the vector:

  void PropertyVector::Save (Writer &writer) const
  {
     writer << writer.ind() << "<PropertyVector valueX=\"" <<  _cVec.x <<
                                            "\" valueY=\"" <<  _cVec.y <<
                                            "\" valueZ=\"" <<  _cVec.z <<"\"/>" << endl;
  }

The writer.ind() expression writes the indention, just for pretty printing of the XML. As you see, the writing of the XML document is not done with a DOM implementation because of performance reasons. Therefore the programmer has to take care that a valid XML document is written. This means closing tags and writing UTF-8.

See also:
Base::Writer

Reimplemented from Part::Geometry.

Definition at line 1749 of file Geometry.cpp.

void GeomSurfaceOfExtrusion::setHandle ( const Handle_Geom_SurfaceOfLinearExtrusion &  c  ) 

Definition at line 1730 of file Geometry.cpp.

Referenced by Part::SurfaceOfExtrusionPy::PyInit().


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

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