3.4.0
tigl::CTiglCADExporter Class Referenceabstract

Abstract base class for CAD exports. More...

#include <CTiglCADExporter.h>

+ Inheritance diagram for tigl::CTiglCADExporter:

Public Member Functions

TIGL_EXPORT bool AddConfiguration (CCPACSConfiguration &config, const ShapeExportOptions &options=DefaultShapeExportOptions())
 Adds the whole non-fused configuration to the exporter. If one of the components fail to export, funtion returns fals. More...
 
TIGL_EXPORT void AddFusedConfiguration (CCPACSConfiguration &config, const ShapeExportOptions &options=DefaultShapeExportOptions())
 Adds the geometry (as described in loaded file) to exporter as one fused shape. More...
 
TIGL_EXPORT void AddShape (PNamedShape shape, const ShapeExportOptions &options=DefaultShapeExportOptions())
 Adds a shape to the exporter. More...
 
TIGL_EXPORT void AddShape (PNamedShape shape, const CCPACSConfiguration *config, const ShapeExportOptions &options=DefaultShapeExportOptions())
 Adds a shape and configuration to exporter. More...
 
TIGL_EXPORT CTiglCADExporter (const ExporterOptions &options=DefaultExporterOption())
 Constructor. More...
 
virtual ExporterOptions GetDefaultOptions () const =0
 
virtual ShapeExportOptions GetDefaultShapeOptions () const =0
 
TIGL_EXPORT const ShapeExportOptionsGetOptions (size_t iShape) const
 
TIGL_EXPORT PNamedShape GetShape (size_t iShape) const
 Returns shape added to the exporter by position in list, in order it was added to exporter, note that adding the whole configuration adds shapes seperatly if not fused. More...
 
TIGL_EXPORT const ExporterOptionsGlobalExportOptions () const
 
TIGL_EXPORT size_t NShapes () const
 Returns the number of shapes added to exporter. More...
 
TIGL_EXPORT std::string SupportedFileType () const
 
TIGL_EXPORT bool Write (const std::string &filename) const
 Writes the export file to working directory. More...
 
virtual TIGL_EXPORT ~CTiglCADExporter ()
 Destructor. More...
 

Protected Member Functions

const CCPACSConfigurationGetConfiguration (size_t iShape) const
 Can also be NULL! More...
 

Private Member Functions

virtual std::string SupportedFileTypeImpl () const =0
 must be overridden. If multiple types supported, separate with a ";" More...
 
virtual bool WriteImpl (const std::string &filename) const =0
 must be overridden by the concrete implementation More...
 

Private Attributes

std::vector< const CCPACSConfiguration * > _configs
 
ExporterOptions _globalOptions
 
std::vector< ShapeExportOptions_shapeOptions
 
ListPNamedShape _shapes
 

Detailed Description

Abstract base class for CAD exports.

Constructor & Destructor Documentation

◆ CTiglCADExporter()

TIGL_EXPORT tigl::CTiglCADExporter::CTiglCADExporter ( const ExporterOptions options = DefaultExporterOption())

Constructor.

Parameters
optionsSets options for exporter

◆ ~CTiglCADExporter()

virtual TIGL_EXPORT tigl::CTiglCADExporter::~CTiglCADExporter ( )
inlinevirtual

Destructor.

Member Function Documentation

◆ AddConfiguration()

TIGL_EXPORT bool tigl::CTiglCADExporter::AddConfiguration ( CCPACSConfiguration config,
const ShapeExportOptions options = DefaultShapeExportOptions() 
)

Adds the whole non-fused configuration to the exporter. If one of the components fail to export, funtion returns fals.

Parameters
config
options
Returns
TIGL_EXPORT If one of the components fail to export, the function returns false

◆ AddFusedConfiguration()

TIGL_EXPORT void tigl::CTiglCADExporter::AddFusedConfiguration ( CCPACSConfiguration config,
const ShapeExportOptions options = DefaultShapeExportOptions() 
)

Adds the geometry (as described in loaded file) to exporter as one fused shape.

Parameters
config
options

◆ AddShape() [1/2]

TIGL_EXPORT void tigl::CTiglCADExporter::AddShape ( PNamedShape  shape,
const ShapeExportOptions options = DefaultShapeExportOptions() 
)

Adds a shape to the exporter.

Parameters
shape
options

◆ AddShape() [2/2]

TIGL_EXPORT void tigl::CTiglCADExporter::AddShape ( PNamedShape  shape,
const CCPACSConfiguration config,
const ShapeExportOptions options = DefaultShapeExportOptions() 
)

Adds a shape and configuration to exporter.

Parameters
shape
config
options

◆ GetConfiguration()

const CCPACSConfiguration* tigl::CTiglCADExporter::GetConfiguration ( size_t  iShape) const
protected

Can also be NULL!

◆ GetDefaultOptions()

virtual ExporterOptions tigl::CTiglCADExporter::GetDefaultOptions ( ) const
pure virtual

◆ GetDefaultShapeOptions()

virtual ShapeExportOptions tigl::CTiglCADExporter::GetDefaultShapeOptions ( ) const
pure virtual

◆ GetOptions()

TIGL_EXPORT const ShapeExportOptions& tigl::CTiglCADExporter::GetOptions ( size_t  iShape) const

◆ GetShape()

TIGL_EXPORT PNamedShape tigl::CTiglCADExporter::GetShape ( size_t  iShape) const

Returns shape added to the exporter by position in list, in order it was added to exporter, note that adding the whole configuration adds shapes seperatly if not fused.

Parameters
iShapeIndex refering to position of shape that was added to exporter. Index starts at '0'

◆ GlobalExportOptions()

TIGL_EXPORT const ExporterOptions& tigl::CTiglCADExporter::GlobalExportOptions ( ) const

◆ NShapes()

TIGL_EXPORT size_t tigl::CTiglCADExporter::NShapes ( ) const

Returns the number of shapes added to exporter.

◆ SupportedFileType()

TIGL_EXPORT std::string tigl::CTiglCADExporter::SupportedFileType ( ) const

◆ SupportedFileTypeImpl()

virtual std::string tigl::CTiglCADExporter::SupportedFileTypeImpl ( ) const
privatepure virtual

must be overridden. If multiple types supported, separate with a ";"

Implemented in tigl::CTiglExportIges, tigl::CTiglExportVtk, tigl::CTiglExportStep, tigl::CTiglExportBrep, tigl::CTiglExportStl, and tigl::CTiglExportCollada.

◆ Write()

TIGL_EXPORT bool tigl::CTiglCADExporter::Write ( const std::string &  filename) const

Writes the export file to working directory.

Parameters
filename

◆ WriteImpl()

virtual bool tigl::CTiglCADExporter::WriteImpl ( const std::string &  filename) const
privatepure virtual

Field Documentation

◆ _configs

std::vector<const CCPACSConfiguration*> tigl::CTiglCADExporter::_configs
private

TIGL configurations

◆ _globalOptions

ExporterOptions tigl::CTiglCADExporter::_globalOptions
mutableprivate

◆ _shapeOptions

std::vector<ShapeExportOptions> tigl::CTiglCADExporter::_shapeOptions
private

◆ _shapes

ListPNamedShape tigl::CTiglCADExporter::_shapes
private

stores all shapes for export


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