dime  0.9.1
Portable DXF file library
Loading...
Searching...
No Matches
dimeSection Class Referenceabstract

The dimeSection class is the superclass for all section classes. More...

#include <dime/sections/Section.h>

Inheritance diagram for dimeSection:
dimeBase dimeBlocksSection dimeClassesSection dimeEntitiesSection dimeHeaderSection dimeObjectsSection dimeTablesSection dimeUnknownSection

Public Member Functions

 dimeSection (dimeMemHandler *const memhandler)
 
virtual ~dimeSection ()
 
virtual dimeSectioncopy (dimeModel *const model) const =0
 
virtual int countRecords () const =0
 
virtual const char * getSectionName () const =0
 
virtual bool isOfType (const int thetypeid) const
 
virtual bool read (dimeInput *const file)=0
 
virtual int typeId () const =0
 
virtual bool write (dimeOutput *const file)=0
 
- Public Member Functions inherited from dimeBase
 dimeBase (void)
 
virtual ~dimeBase ()
 
void operator delete (void *ptr)
 
void * operator new (size_t size, dimeMemHandler *memhandler=NULL, const int alignment=4)
 

Static Public Member Functions

static dimeSectioncreateSection (const char *const sectionname, dimeMemHandler *memhandler)
 

Protected Attributes

dimeMemHandlermemHandler
 

Additional Inherited Members

- Public Types inherited from dimeBase
enum  {
  dimeBaseType = 1 , dimeRecordType , dimeStringRecordType , dimeFloatRecordType ,
  dimeDoubleRecordType , dimeInt8RecordType , dimeInt16RecordType , dimeInt32RecordType ,
  dimeHexRecordType , dimeRecordHolderType , dimeClassType , dimeUnknownClassType ,
  dimeObjectType , dimeUnknownObjectType , dimeEntityType , dimeUnknownEntityType ,
  dimePolylineType , dimeVertexType , dimeFaceEntityType , dimeExtrusionEntityType ,
  dime3DFaceType , dimeSolidType , dimeTraceType , dimeLineType ,
  dimeTextType , dimePointType , dimeBlockType , dimeInsertType ,
  dimeCircleType , dimeArcType , dimeLWPolylineType , dimeEllipseType ,
  dimeSplineType , dimeSectionType , dimeUnknownSectionType , dimeEntitiesSectionType ,
  dimeBlocksSectionType , dimeTablesSectionType , dimeHeaderSectionType , dimeClassesSectionType ,
  dimeObjectsSectionType , dimeTableType , dimeTableEntryType , dimeUnknownTableType ,
  dimeUCSTableType , dimeLayerTableType , dimeLastTypeTag
}
 

Detailed Description

The dimeSection class is the superclass for all section classes.

Currently supported sections are:

  • Header (dimeHeaderSection)
  • Classes (dimeClassSection)
  • Tables (dimeTableSection)
  • Blocks (dimeBlockSection)
  • Entities (dimeEntititySection)
  • Objects (dimeObjectSection)

Constructor & Destructor Documentation

◆ dimeSection()

dimeSection::dimeSection ( dimeMemHandler *const memhandler)

Constructor

◆ ~dimeSection()

dimeSection::~dimeSection ( )
virtual

Empty virtual destructor.

Member Function Documentation

◆ countRecords()

int dimeSection::countRecords ( ) const
pure virtual

◆ createSection()

dimeSection * dimeSection::createSection ( const char *const sectionname,
dimeMemHandler * memhandler )
static

Static function used to create the correct section object from a text string.

◆ isOfType()

bool dimeSection::isOfType ( const int thetypeid) const
virtual

Returns true if the object is of type typeid or is inherited from it. Function in base class checks whether thetypeid equals the virtual dimeBase::typeId() value or equals dimeBaseType. Must be implemented by all subclasses that are superclasses of other classes, and should check if thetypeid equals its typeId, and then call its parent's isOfType function. Leaf-classes do not have to implement this method.

Reimplemented from dimeBase.

◆ read()

bool dimeSection::read ( dimeInput *const file)
pure virtual

Implemented in dimeBlocksSection, and dimeTablesSection.

◆ typeId()

int dimeSection::typeId ( ) const
pure virtual

Must be implemented by all subclasses, and should return an unique id for that class.

Implements dimeBase.

Implemented in dimeBlocksSection, dimeClassesSection, dimeEntitiesSection, dimeHeaderSection, dimeObjectsSection, dimeTablesSection, and dimeUnknownSection.

◆ write()

bool dimeSection::write ( dimeOutput *const file)
pure virtual

Implemented in dimeBlocksSection.


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