Open CASCADE Technology Reference Manual 8.0.0
Loading...
Searching...
No Matches
Public Member Functions | Protected Member Functions
STEPConstruct_ExternRefs Class Reference

Provides a tool for analyzing (reading) and creating (writing) references to external files in STEP. More...

#include <STEPConstruct_ExternRefs.hxx>

Inheritance diagram for STEPConstruct_ExternRefs:
Inheritance graph
[legend]

Public Member Functions

 STEPConstruct_ExternRefs ()
 Creates an empty tool.
 
 STEPConstruct_ExternRefs (const occ::handle< XSControl_WorkSession > &WS)
 Creates a tool and initializes it.
 
bool Init (const occ::handle< XSControl_WorkSession > &WS)
 Initializes tool; returns True if succeeded.
 
void Clear ()
 Clears internal fields (list of defined extern refs)
 
bool LoadExternRefs ()
 Searches current STEP model for external references and loads them to the internal data structures NOTE: does not clear data structures before loading.
 
int NbExternRefs () const
 Returns number of defined extern references.
 
const charFileName (const int num) const
 Returns filename for numth extern reference Returns Null if FileName is not defined or bad.
 
occ::handle< StepBasic_ProductDefinitionProdDef (const int num) const
 Returns ProductDefinition to which numth extern reference is associated. Returns Null if cannot be detected or if extern reference is not associated to SDR in a proper way.
 
occ::handle< StepBasic_DocumentFileDocFile (const int num) const
 Returns DocumentFile to which numth extern reference is associated. Returns Null if cannot be detected.
 
occ::handle< TCollection_HAsciiStringFormat (const int num) const
 Returns format identification string for the extern document Returns Null handle if format is not defined.
 
int AddExternRef (const char *const filename, const occ::handle< StepBasic_ProductDefinition > &PD, const char *const format)
 Create a new external reference with specified attributes attached to a given SDR <format> can be Null string, in that case this information is not written. Else, it can be "STEP AP214" or "STEP AP203" Returns index of a new extern ref.
 
void checkAP214Shared ()
 Check (create if it is null) all shared entities for the model.
 
int WriteExternRefs (const int num) const
 Adds all the currently defined external refs to the model Returns number of written extern refs.
 
void SetAP214APD (const occ::handle< StepBasic_ApplicationProtocolDefinition > &APD)
 Set the ApplicationProtocolDefinition of the PDM schema.
 
occ::handle< StepBasic_ApplicationProtocolDefinitionGetAP214APD ()
 Returns the ApplicationProtocolDefinition of the PDM schema NOTE: if not defined then create new APD with new Application Context.
 
- Public Member Functions inherited from STEPConstruct_Tool
 STEPConstruct_Tool ()
 Creates an empty tool.
 
 STEPConstruct_Tool (const occ::handle< XSControl_WorkSession > &WS)
 Creates a tool and loads it with worksession.
 
const occ::handle< XSControl_WorkSession > & WS () const
 Returns currently loaded WorkSession.
 
occ::handle< Interface_InterfaceModelModel () const
 Returns current model (Null if not loaded)
 
const Interface_GraphGraph (const bool recompute=false) const
 Returns current graph (recomputing if necessary)
 
const occ::handle< Transfer_TransientProcess > & TransientProcess () const
 Returns TransientProcess (reading; Null if not loaded)
 
const occ::handle< Transfer_FinderProcess > & FinderProcess () const
 Returns FinderProcess (writing; Null if not loaded)
 

Protected Member Functions

bool addAP214ExterRef (const occ::handle< StepAP214_AppliedDocumentReference > &ADR, const occ::handle< StepBasic_ProductDefinition > &PD, const occ::handle< StepBasic_DocumentFile > &DF, const char *const filename)
 Create a new additional structure entities and add necessary references Note: do not refer from ADR to DF directly in AP214 (TRJ11).
 
- Protected Member Functions inherited from STEPConstruct_Tool
bool SetWS (const occ::handle< XSControl_WorkSession > &WS)
 Load worksession; returns True if succeeded Returns False if either FinderProcess of TransientProcess cannot be obtained or are Null.
 

Detailed Description

Provides a tool for analyzing (reading) and creating (writing) references to external files in STEP.

It maintains a data structure in the form of sequences of relevant STEP entities (roots), allowing either to create them by convenient API, or load from existing model and investigate

Constructor & Destructor Documentation

◆ STEPConstruct_ExternRefs() [1/2]

STEPConstruct_ExternRefs::STEPConstruct_ExternRefs ( )

Creates an empty tool.

◆ STEPConstruct_ExternRefs() [2/2]

STEPConstruct_ExternRefs::STEPConstruct_ExternRefs ( const occ::handle< XSControl_WorkSession > & WS)

Creates a tool and initializes it.

Member Function Documentation

◆ addAP214ExterRef()

bool STEPConstruct_ExternRefs::addAP214ExterRef ( const occ::handle< StepAP214_AppliedDocumentReference > & ADR,
const occ::handle< StepBasic_ProductDefinition > & PD,
const occ::handle< StepBasic_DocumentFile > & DF,
const char *const filename )
protected

Create a new additional structure entities and add necessary references Note: do not refer from ADR to DF directly in AP214 (TRJ11).

◆ AddExternRef()

int STEPConstruct_ExternRefs::AddExternRef ( const char *const filename,
const occ::handle< StepBasic_ProductDefinition > & PD,
const char *const format )

Create a new external reference with specified attributes attached to a given SDR <format> can be Null string, in that case this information is not written. Else, it can be "STEP AP214" or "STEP AP203" Returns index of a new extern ref.

◆ checkAP214Shared()

void STEPConstruct_ExternRefs::checkAP214Shared ( )

Check (create if it is null) all shared entities for the model.

◆ Clear()

void STEPConstruct_ExternRefs::Clear ( )

Clears internal fields (list of defined extern refs)

◆ DocFile()

occ::handle< StepBasic_DocumentFile > STEPConstruct_ExternRefs::DocFile ( const int num) const

Returns DocumentFile to which numth extern reference is associated. Returns Null if cannot be detected.

◆ FileName()

const char * STEPConstruct_ExternRefs::FileName ( const int num) const

Returns filename for numth extern reference Returns Null if FileName is not defined or bad.

◆ Format()

occ::handle< TCollection_HAsciiString > STEPConstruct_ExternRefs::Format ( const int num) const

Returns format identification string for the extern document Returns Null handle if format is not defined.

◆ GetAP214APD()

occ::handle< StepBasic_ApplicationProtocolDefinition > STEPConstruct_ExternRefs::GetAP214APD ( )

Returns the ApplicationProtocolDefinition of the PDM schema NOTE: if not defined then create new APD with new Application Context.

◆ Init()

bool STEPConstruct_ExternRefs::Init ( const occ::handle< XSControl_WorkSession > & WS)

Initializes tool; returns True if succeeded.

◆ LoadExternRefs()

bool STEPConstruct_ExternRefs::LoadExternRefs ( )

Searches current STEP model for external references and loads them to the internal data structures NOTE: does not clear data structures before loading.

◆ NbExternRefs()

int STEPConstruct_ExternRefs::NbExternRefs ( ) const

Returns number of defined extern references.

◆ ProdDef()

occ::handle< StepBasic_ProductDefinition > STEPConstruct_ExternRefs::ProdDef ( const int num) const

Returns ProductDefinition to which numth extern reference is associated. Returns Null if cannot be detected or if extern reference is not associated to SDR in a proper way.

◆ SetAP214APD()

void STEPConstruct_ExternRefs::SetAP214APD ( const occ::handle< StepBasic_ApplicationProtocolDefinition > & APD)

Set the ApplicationProtocolDefinition of the PDM schema.

◆ WriteExternRefs()

int STEPConstruct_ExternRefs::WriteExternRefs ( const int num) const

Adds all the currently defined external refs to the model Returns number of written extern refs.


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