DATAKIT API  V2025.4
sw::sww::Instance Class Reference

This class provides Instance about a Solidworks File.
It can be used with sw::sww::OpenAssembly functions to Add Instance. More...

Public Member Functions

void AddMetadata (const Dtk_tab< Dtk_MetaDataPtr > &inArrayMetadata)
 
const Dtk_Int32GetBlankedStatus ()
 
const Dtk_RGBGetColor ()
 
const Dtk_stringGetConfigurationName ()
 
const Dtk_stringGetInstanceName ()
 
const Dtk_transfoGetMatrix ()
 
const Dtk_tab< Dtk_MetaDataPtr > & GetMetadata ()
 
const Dtk_stringGetName ()
 
 Instance ()
 Default constructor. More...
 
 Instance (const Dtk_string &inSolidfileName, const Dtk_string &inInstanceName, const Dtk_transfo &inTransfo, const Dtk_RGB &inColorInstance=Dtk_RGB(-1, -1, -1, -1), const Dtk_Int32 &inBlankedStatus=DTK_FALSE, const Dtk_string &inConfigurationName=Dtk_string())
 Default constructor. More...
 
 ~Instance ()
 Destructor. More...
 

Protected Attributes

Dtk_Int32 _BlankedStatus
 
Dtk_RGB _Color
 
Dtk_string _ConfigurationName
 
Dtk_string _InstanceName
 
Dtk_transfo _Matrix
 
Dtk_string _Name
 
Dtk_tab< Dtk_MetaDataPtrm_ArrayMetadata
 

Detailed Description

This class provides Instance about a Solidworks File.
It can be used with sw::sww::OpenAssembly functions to Add Instance.

//...
soldiworksw::Instance instance;
Dtk_ErrorStatus dtkerror;
dtkerror = sw::sww::AddInstance( instance);
//...

Constructor & Destructor Documentation

◆ Instance() [1/2]

sw::sww::Instance::Instance ( )

Default constructor.

◆ ~Instance()

sw::sww::Instance::~Instance ( )

Destructor.

◆ Instance() [2/2]

sw::sww::Instance::Instance ( const Dtk_string inSolidfileName,
const Dtk_string inInstanceName,
const Dtk_transfo inTransfo,
const Dtk_RGB inColorInstance = Dtk_RGB( -1, -1, -1, -1 ),
const Dtk_Int32 inBlankedStatus = DTK_FALSE,
const Dtk_string inConfigurationName = Dtk_string() 
)

Default constructor.

Member Function Documentation

◆ AddMetadata()

void sw::sww::Instance::AddMetadata ( const Dtk_tab< Dtk_MetaDataPtr > &  inArrayMetadata)

◆ GetBlankedStatus()

const Dtk_Int32& sw::sww::Instance::GetBlankedStatus ( )

◆ GetColor()

const Dtk_RGB& sw::sww::Instance::GetColor ( )

◆ GetConfigurationName()

const Dtk_string& sw::sww::Instance::GetConfigurationName ( )

◆ GetInstanceName()

const Dtk_string& sw::sww::Instance::GetInstanceName ( )

◆ GetMatrix()

const Dtk_transfo& sw::sww::Instance::GetMatrix ( )

◆ GetMetadata()

const Dtk_tab<Dtk_MetaDataPtr>& sw::sww::Instance::GetMetadata ( )

◆ GetName()

const Dtk_string& sw::sww::Instance::GetName ( )

Field Documentation

◆ _BlankedStatus

Dtk_Int32 sw::sww::Instance::_BlankedStatus
protected

◆ _Color

Dtk_RGB sw::sww::Instance::_Color
protected

◆ _ConfigurationName

Dtk_string sw::sww::Instance::_ConfigurationName
protected

◆ _InstanceName

Dtk_string sw::sww::Instance::_InstanceName
protected

◆ _Matrix

Dtk_transfo sw::sww::Instance::_Matrix
protected

◆ _Name

Dtk_string sw::sww::Instance::_Name
protected

◆ m_ArrayMetadata

Dtk_tab<Dtk_MetaDataPtr> sw::sww::Instance::m_ArrayMetadata
protected
catiav5w::AddInstance
Dtk_ErrorStatus AddInstance(const Dtk_ID &inDocId, const Dtk_string &inInstanceName, const Dtk_transfo &inTransfo, Dtk_ID &outInstanceId)
Add an instance to a DocID into the Current (Sub/Root) CATProduct.
Dtk_ErrorStatus
Dtk_ErrorStatus
Definition: error_dtk.hpp:6