libsurf
Programmer's Documentation

Public Types | Public Member Functions | Static Public Member Functions | Public Attributes | Private Member Functions | Private Attributes | List of all members
StepFile Class Reference

Detailed Description

STEP File.

This class represents a file containing data in the STEP (ISO-10303-21) format. Currently, only a small subset of the entities in AP-203 is read from plain text (P21) format files, which are the only commonly encountered manifestation.

Due to the horrific complexity of the standard, the C++ code to read and write all of the STEP entities is automatically generated by a python script which dumps the step_ap203 interfaces. In this way, all of STEP AP203 is supported in the sense that the file contents are read into an in-memory C++ representation. However, not all entities which exist in AP203 have a correponding representation in libsurf.

Apart from the entities defined by AP203, the standard also permits to create new, compound entities. These are not parsed by the current implementation.

Todo:
How to handle compound entities?
See Also
IgesFile, StepEntity

#include <stepfile.h>

Collaboration diagram for StepFile:
[legend]

Public Types

typedef StepEntitySet::iterator iterator
 
typedef
StepEntitySet::const_iterator 
const_iterator
 

Public Member Functions

 StepFile ()
 create empty file
 
uint size () const
 number of entities in file
 
iterator begin ()
 allow iteration over entities
 
iterator end ()
 allow iteration over entities
 
const_iterator begin () const
 allow iteration over entities
 
const_iterator end () const
 allow iteration over entities
 
StepEntityPtr operator[] (StepID eid) const
 access entity by entity id
 
template<class Entity >
bool as (StepID eid, const Entity **p) const
 access as a certain entity type
 
void read (const std::string &fname)
 read file from disk
 
void write (std::ostream &os) const
 write file to stream
 

Static Public Member Functions

static bool isStepFile (const std::string &fname)
 determine whether a file could be a step file by looking at the header
 

Public Attributes

std::string hdDescription
 header: description, filename, author
 
std::string hdFileName
 
std::string hdAuthor
 
std::string hdOrg
 header: organisation, version, originating system, authorization
 
std::string hdPpVersion
 
std::string hdOrigSystem
 
std::string hdAuth
 

Private Member Functions

void processLine (const std::string &line)
 reading : process data section line
 

Private Attributes

StepEntitySet entities
 geometry and topology entities
 

The documentation for this class was generated from the following files:
Generated on Mon Jan 24 2022 03:03:19 for libsurf by   doxygen 1.8.5