Overview
The following functions help to create and manage STEP external identification data, which is used to create assemblies that reference external files for their individual piece parts. These functions are defined by the stix_extdef.h header file.
Call stix_extdef_tag() before using these functions. This scans the STEP data and adds extra information for efficient access.
stix_extdef_get()
stp_document * stix_extdef_get ( stp_product_definition * pdef ); stp_document * stix_extdef_get ( stp_representation * rep );
The stix_extdef_get() function returns the document object that identifies the external definition of a product, or the shape representation of a product.
stix_extdef_get_filename()
const char * stix_extdef_get_filename ( stp_document * doc ); const char * stix_extdef_get_filename ( stp_product_definition * pdef ); const char * stix_extdef_get_filename ( stp_representation * rep );
The stix_extdef_get_filename() function looks through the attributes of a document instance and returns the string containing the external filename. This will correctly handle any external identification assignment according to the recommended practices, if one is applied to the document. If a product definition or representation is passed in, the function first calls stix_extdef_get() to find the document.
stix_extdef_tag / untag / retag()
// add external reference links void stix_extdef_tag( RoseDesign * d ); // remove external reference links void stix_extdef_untag( RoseDesign * d ); // untag+tag to refresh external reference links void stix_extdef_retag( RoseDesign * d );
The stix_extdef_tag() function looks at all of the document objects, and their assignments to products and shape representations in the file, recognizes external definition declarations, and annotates them for quick retrieval.
You must call the stix_extdef_tag() before using the
functions described on this page. The tag
function
checks if the external definition index is present and builds it if
not present. Subsequent calls are ignored. The untag
function removes the external definition index data.
If the underlying STEP data has changed, you can force a refresh by
calling the retag
function which simply removes the index
with untag
followed by building it again
with tag
.