DATAKIT SDK  V2026.2
dtk_maindoc.hpp
Go to the documentation of this file.
1 #ifndef __UTIL_DTK_DOCUMENT_HPP__
2 #define __UTIL_DTK_DOCUMENT_HPP__
3 
4 #include "def/define.h"
11 #include "util/dtk_maindoc_ptr.hpp"
13 #include "util/error_dtk.hpp"
15 #include "util/util_ent_dtk.hpp"
16 #include "util/util_ptr_dtk.hpp"
17 #include "util/util_stl_dtk.hpp"
19 
20 class Dtk_mesh;
22 class Dtk_feat;
24 class Dtk_Kinematic;
26 
27 
29 {
30  V5ReaderModule = 0, // CatiaV5
31  VdaReaderModule = 1, // VdaFS
32  InvReaderModule = 2, // Inventor
33  V4ReaderModule = 3, // CatiaV4
34  UgReaderModule = 4, // Unigraphics NX
35  XmtReaderModule = 5, // Parasolid using parasolid kernel
36  SwReaderModule = 6, // Solidworks
37  SeReaderModule = 7, // Solidedge
38  IgesReaderModule = 8, // Iges
39  StepReaderModule = 9, // Step
40  PsReaderModule = 10, // Parasolid via datakit
41  ProeReaderModule = 11, // Pro/Engineer - Creo Parametric
42  SatReaderModule = 12, // Internal Use Only
43  JtReaderModule = 13, // Jt
44  CgrReaderModule = 14, // Cgr
45  CaddsReaderModule = 15, // Cadds
46  AcisReaderModule = 16, // Acis
47  ProCeraReaderModule = 17,// ProCera dental format
48  CerconReaderModule = 18, // Cercon dental format
49  CerecReaderModule = 19, // Cerec Sirona dental format
50  DcmReaderModule = 20, // Dcm 3Shape dental format
51  _3dXmlReaderModule = 21, // Internal Use Only
52  XmlReaderModule = 22, // Internal Use Only
53  V6ReaderModule = 23, // 3DEXPERIENCE CatiaV6
54  DxfReaderModule = 24, // Dxf
55  PlmXmlReaderModule = 25, // PlmXml
56  Lava3mReaderModule = 26, // Lava 3M dental format
57  U3dReaderModule = 27, // Internal Use Only
58  PdfReaderModule = 28, // Internal Use Only
59  RnXmlReaderModule = 29, // Internal Use Only
60  _3dmReaderModule = 30, // Rhino
61  DwgReaderModule = 31, // Dwg
62  ObjReaderModule = 32, // Obj
63  IfcReaderModule = 33, // Ifc
64  BRepOccReaderModule = 34,// Brep Open Cascade
65  RevitReaderModule = 35, // Revit
66  CreoviewReaderModule = 36,// Creo View
67  StlReaderModule = 37, // Stl
68  FbxReaderModule = 38, // Fbx
69  CgmReaderModule = 39, // Computer Graphics Metafile
70  SdnfReaderModule = 40, // Computer Graphics Metafile
71  ArtReaderModule = 41, // Art
72  SmgReaderModule = 42, // Smg
73  PrcReaderModule = 43, // Prc
74  F3dReaderModule = 44, // F3d
75  DstvReaderModule = 45, // DSTV
76  GltfReaderModule = 46, // Gltf
77  NavisReaderModule = 47, // Navis
78  QifReaderModule = 48, // QIF
79  DwgDtkReaderModule = 49, // Dwg via datakit
80  Zw3dReaderModule = 50, // Zw3d
81  UsdReaderModule = 51, // USD
82 
85 };
86 
89 
90 
91 class Dtk_MainDoc;
92 
93 
94 /////////////////////////////////////////////////////////////////////////////
95 //! \ingroup DtkAPIGroup
96 //! \class Dtk_DocElement
97 //! \brief This is the Main Doc Element Class
98 //! The Dtk_DocElement object is common parent class of the Dtk_Node and the Dtk_Component classes
99 //! It typically used as geometry into a Part.
100 //! \SmartPtr{Dtk_DocElementPtr}
102 {
103 protected:
104 
106  struct Dtk_Handle; // Not defined here
107  Dtk_Handle *_Private; // Handle
108 protected:
109  void _Init();
110  void _Reset();
111  void _Copy(const Dtk_Node&s);
112 
113  //! \internal
114  Dtk_DocElement(const Dtk_ID& inID, Dtk_string inName);
115 
116  //! \BaseDestructor
117  virtual ~Dtk_DocElement();
118 
119 
120  //! \brief Adds a child Dtk_DocElement to main Element.
121  //! \param inChild The Dtk_DocElement to be added as a child.
122  void _AddChild(const Dtk_DocElementPtr& inChild);
123 
124  //! \brief Retrieves the ith Dtk_DocElement - read only -
125  //! \param inPos Child element index.
126  //! \return the inPos'th Dtk_DocElement
127  const Dtk_DocElementPtr _GetChild(const Dtk_Size_t& inPos) const;
128 
129  //! \brief Replaces a child by another one. Also update father lists.
130  //! \param inPos Old Child element index.
131  //! \param inNewChild The Dtk_DocElement replacing the old one
132  //! \DtkInternal
133  //! \return the DtkNoerrror if success.
134  //! \return the dtkErrorOutOfRange if bad inPos parameter.
135  //! \return the dtkErrorNullPointer if inNewChild is NULL.
136  Dtk_ErrorStatus _ReplaceChild(const Dtk_Size_t& inPos, const Dtk_DocElementPtr& inNewChild);
137 
138  friend class Dtk_SmartPtr<Dtk_DocElement>;
139  friend class Dtk_MainDoc;
140 
141 public:
142  //! \DtkDynamicType
143  Dtk_Int32 DtkDynamicType(const int& inId);
144 
145  //! \DtkDynamicCast
147 
148  //! \brief Retrieves the number of the Dtk_DocElement children - read only -
149  //! \return The Children number.
151 
152  //! \brief Retrieves the Dtk_DocElement Name - read only -
153  //! \return The Element Name.
154  const Dtk_string& Name() const;
156 
157  //! \brief Retrieves the Dtk_DocElement ID - read only -
158  //! \return The element ID.
159  Dtk_ID GetID() const;
160 
161  //! \brief Retrieves Dtk_DocElement ith FatherID - read only -
162  //! \return The ith FatherID.
164 
165  //! \brief GetNumFather
166  //! \return Number of fathers
168 
169  void GetReadID(Dtk_ID& outReadID) const;
170  void SetReadID(const Dtk_ID & inNewID);
171 
172 
173  //! \brief Retrieves the Dtk_DocElement Dtk_InfoPtr - read only -
174  //! \return The element Dtk_InfoPtr.
176  void SetInfos(const Dtk_InfoPtr& inInfos);
177 
178  //! \brief Retrieves the Dtk_DocElement Dtk_MaterialPtr - read only -
179  //! \return The element Dtk_MaterialPtrif if exists .
181  void SetMaterial(Dtk_MaterialPtr inMaterial);
182 
183 
184  //! \brief Retrieves the Dtk_DocElement Dtk_PreviewPtr - read only -
185  //! \return The element Dtk_PreviewPtr if exists.
187  void SetPreview(Dtk_PreviewPtr inPreview);
189 
190 
191  //! \brief Adds a Dtk_MetaDataPtr to the Dtk_DocElement.
192  //! \param inMetaData The Dtk_MetaDataPtr to be added.
193  void AddMetaData(const Dtk_MetaDataPtr& inMetaData);
194 
195  //! \brief Adds a Dtk_MetaDataGroupPtr to the Dtk_DocElement.
196  //! \param inMetaDataGroup The Dtk_MetaDataGroupPtr to be added.
197  //! \param inAddMetadata If we also add the metadata of the group to the Dtk_DocElement
198  void AddMetaDataGroup(const Dtk_MetaDataGroupPtr& inMetaDataGroup, Dtk_bool inAddMetadata = DTK_FALSE);
199 
200  //! \brief Adds a Dtk_PropertiesPtr to the Dtk_DocElement.
201  //! \param inProperty The Dtk_PropertiesPtr to be added.
202  void AddProperty(const Dtk_PropertiesPtr & inProperty);
203 
204  //! \brief Retrieves the ith Dtk_MetaDataPtr - read only -
205  //! \param inPos Metadata index.
206  //! \return the inPos'th Dtk_MetaDataPtr
208 
209  //! \brief Retrieves the ith Dtk_MetaDataGrouplPtr - read only -
210  //! \param inPos Group index.
211  //! \return the inPos'th Dtk_MetaDataGrouplPtr
213 
214  //! \brief Retrieves the number of the Dtk_MetaDataPtr - read only -
215  //! \return The Metadata number.
217 
218  //! \brief Retrieves the number of the Dtk_MetaDataGroupPtr - read only -
219  //! \return The Group number.
221 };
222 
223 /////////////////////////////////////////////////////////////////////////////
224 //! \ingroup DtkAPIGroup
225 //! \class Dtk_Node
226 //! \brief This is the Node Class
227 //! \brief The Dtk_Node is used to retrieve information from a Dtk_Component.
228 //! \details It is typically used as geometry into a Part.
229 //! \SmartPtr{Dtk_NodePtr}
230 class Dtk_Node : public Dtk_DocElement
231 {
232 public:
233 
235  {
237  HasPoints = 1,
238  HasCurves = 2,
240  HasSolids = 8,
241  HasAxis = 16,
242  HasMesh = 32,
243  HasMeshSurfaces = 64
244  };
245 
247  {
248  NullType = 0,
249  BodyType, // for 3D
250  MeshType, // for 3D Tesselated
251  AnnotationSetType, // for FdtAnnotationSet -- Obsolete
252  FdtType, // for Fdt
253  DrawingType, // for 2D
254  KinematicsType, // Kinematics
255  AxisSystemType, // AxisPlacement
256  LayerInfosSetType, // LayerInfosSet
257  ColorInfosSetType, // ColorInfosSet
258  MetaDataType, // MetaData
259  ModelDisplayType, // Model Display
260  CameraType, // Camera
261  VirtualType, // just for containing children
262  ConstraintType, // ConstraintType
264  };
265  //! \ingroup DtkAPIGroup
266  //! \class Dtk_Node::FullType
267  //! \brief This is the Node FullType Class
268  //! The Dtk_Node::FullType object is used to retrieve the full informations about Dtk_Node Type - Primary and SubType -
269  class FullType
270  {
271  public:
272  friend class Dtk_Node;
273  private:
274  //! \brief Primary Node Type
275  NodeDataTypeEnum _PrimaryType;
276  //! \brief SubType - if relevant -
277  type_detk _SubType;
278  public:
279  FullType( const NodeDataTypeEnum inPrimaryType, const type_detk inSubType ) : _PrimaryType(inPrimaryType), _SubType(inSubType) {}
281  FullType() : _PrimaryType(NullType), _SubType(DTK_TYPE_UNKNOWN) {}
282  inline NodeDataTypeEnum PrimaryType() const {return _PrimaryType;}
283  inline type_detk SubType() const {return _SubType;}
284  };
285 
286 
288  {
289  switch( inEnum )
290  {
291  case NullType: return L"NullType";
292  case BodyType: return L"BodyType";
293  case MeshType: return L"MeshType";
294  case AnnotationSetType: return L"AnnotationSetType";
295  case FdtType: return L"FdtType";
296  case DrawingType: return L"DrawingType";
297  case KinematicsType: return L"KinematicsType";
298  case AxisSystemType: return L"AxisSystemType";
299  case LayerInfosSetType: return L"LayerInfosSetType";
300  case ColorInfosSetType: return L"ColorInfosSetType";
301  case MetaDataType: return L"MetaDataType";
302  case VirtualType: return L"VirtualType";
303  case ModelDisplayType : return L"ModelDisplayType";
304  case CameraType : return L"CameraType";
305  case ConstraintType: return L"Constraint";
306  default: return L"Unknown";
307  }
308  }
309 
310  static inline Dtk_Int32 NodeDataStringToEnumType( const Dtk_string &type )
311  {
312  if( type == L"NullType" )
313  return NullType;
314  else if( type == L"BodyType" )
315  return BodyType;
316  else if( type == L"MeshType" )
317  return MeshType;
318  else if( type == L"AnnotationSetType" )
319  return AnnotationSetType;
320  else if( type == L"FdtType" )
321  return FdtType;
322  else if( type == L"DrawingType" )
323  return DrawingType;
324  else if( type == L"KinematicsType" )
325  return KinematicsType;
326  else if( type == L"AxisSystemType" )
327  return AxisSystemType;
328  else if (type == L"LayerInfosSetType")
329  return LayerInfosSetType;
330  else if (type == L"ColorInfosSetType")
331  return ColorInfosSetType;
332  else if( type == L"MetaDataType" )
333  return MetaDataType;
334  else if( type == L"VirtualType" )
335  return VirtualType;
336  else if (type == L"ModelDisplayType")
337  return ModelDisplayType;
338  else if (type == L"CameraType")
339  return CameraType;
340  else if (type == L"ConstraintType")
341  return ConstraintType;
342  else return -1;
343  }
344 
345 protected:
346 
347  enum { _typeID = DTK_TYPE_NODE };
348  struct Dtk_Handle; // Not defined here
349  Dtk_Handle *_Private; // Handle
350  friend class Dtk_Component;
351 private:
352  void _Init();
353  void _Reset();
354  void _Copy(const Dtk_Node&s);
355 
356  //! \sa Dtk_Component::CreateVirtualNode( const Dtk_string& )
357  //! \sa Dtk_Component::CreateMeshNode(const Dtk_string&, const Dtk_ID&);
358  //! \sa Dtk_Component::CreateBodyNode(const Dtk_string&, const Dtk_ID&);
359  //! \sa Dtk_Component::CreateKinematicsNode(const Dtk_string&, const Dtk_KinematicsPtr&);
360  //! \sa Dtk_Component::CreateDrawingNode(const Dtk_string&, const Dtk_DrawingPtr&);
361  Dtk_Node(const Dtk_NodeID& inID,
362  const Dtk_ComponentID inOwningComponentId,
363  Dtk_string inName, const NodeDataTypeEnum& inDataNodeType, const Dtk_ID inEntityID, const Dtk_Int32 inBodyFlag = UnknownType, const type_detk inSubType = DTK_TYPE_NO_SUBTYPE);
364 
365  //! \BaseDestructor
367 
368  friend class Dtk_SmartPtr<Dtk_Node>;
369 
370 public:
371  //! \DtkDynamicType
372  Dtk_Int32 DtkDynamicType(const int& inId);
373 
374  //! \DtkDynamicCast
376 
377  //! \brief Adds a child Dtk_Node to main Node.
378  //! \param inChild The Dtk_Node to be added as a child.
379  inline void AddChild(const Dtk_NodePtr& inChild)
381 
382  //! \brief Retrieves the ith Dtk_Node - read only -
383  //! \param inPos Child node index.
384  //! \return the inPos'th Dtk_Node
385  inline const Dtk_NodePtr GetChild(const Dtk_Size_t& inPos) const
386  { return Dtk_NodePtr::DtkDynamicCast( _GetChild(inPos) ); }
387 
388  //! \brief Replaces a child Dtk_NodePtr by another one. Also updates father lists.
389  //! \param inPos Old Child Dtk_NodePtr element index.
390  //! \param inNewChild The Dtk_NodePtr replacing the old one
391  //! \DtkInternal
392  //! \return the DtkNoerrror if success.
393  //! \return the dtkErrorOutOfRange if bad inPos parameter.
394  //! \return the dtkErrorNullPointer if inNewChild is NULL.
395  inline Dtk_ErrorStatus ReplaceChildNode(const Dtk_Size_t& inPos, const Dtk_NodePtr& inNewChild)
396  { return _ReplaceChild( inPos, Dtk_DocElementPtr::DtkDynamicCast(inNewChild) ); }
397 
398  //! \brief Retrieves the Dtk_Node Node Type - read only -
399  //! \return The Node Type.
400  //! \deprecated
401  //! \sa Dtk_Node::GetNodeFullType()
402  //SetAsDeprecated("Undefined", "Use GetNodeFullType")
404 
405  //! \brief Retrieves the Node SubType - if relevant - - read only -
406  //! \return The Node SubType.
407  //! \deprecated
408  //! \sa Dtk_Node::GetNodeFullType()
409  //SetAsDeprecated("Undefined", "Use GetNodeFullType")
411 
412  //! \brief Retrieves the Node FullType - Primary ans Sub Type - - read only -
413  //! \return The Node FullType.
415 
416  //! \brief Return DTK_TRUE if Dtk_Node Type Body or Mesh contains points entity
418  //! \brief Return DTK_TRUE if Dtk_Node Type Body or Mesh contains curves entity
420  //! \brief Return DTK_TRUE if Dtk_Node Type Body contains solid entity
422  //! \brief Return DTK_TRUE if Dtk_Node Type Body contains surfacic entity
424  //! \brief Return DTK_TRUE if Dtk_Node Type Body contains mesh surface entity
426  //! \brief Return DTK_TRUE if Dtk_Node Type Body contains axis entity
428  //! \brief Return DTK_TRUE if Dtk_Node Type Body or Mesh contains mesh entity
430 
431 
432  //! \brief Retrieves the Dtk_Node as a Dtk_BodyPtr - if exists -
433  //! \return The Dtk_Node as a Dtk_BodyPtr if exists. Null Dtk_BodyPtr else.
434  //! \remark This method is used to retrieve the body
435  //! informations - if GetNodeType() method returns BodyType -.
437 
438  //! \brief Retrieves the Dtk_Node as a Dtk_meshPtr - if exists -
439  //! \return The Dtk_Node as a Dtk_meshPtr if exists. Null Dtk_meshPtr else.
440  //! \remark This method is used to retrieve the mesh
441  //! informations - if GetNodeType() method returns MeshType -.
443 
444  //! \brief Retrieves the Dtk_Node as a Dtk_FeaturePtr - if exists -
445  //! \return The Dtk_Node as a Dtk_FeaturePtr if exists. Null Dtk_FeaturePtr else.
446  //! \remark This method is used to retrieve the feature
447  //! informations - if GetNodeType() method returns Virtual Type or Body Type-.
449  //! \brief Retrieves the Dtk_Node as a Dtk_AdvancedFeaturePtr - if exists - Internal Use !!!
450  //! \return The Dtk_Node as a Dtk_FeaturePtr if exists. Null Dtk_FeaturePtr else.
451  //! \remark
453 
454 
455  //! \brief Retrieves the Dtk_Node as a Dtk_FdtPtr - if exists -
456  //! \return The Dtk_Node as a Dtk_FdtPtr if exists. Null Dtk_FdtPtr else.
457  //! \remark This method is used to retrieve the FDT
458  //! informations - if GetNodeType() method returns FdtType -.
460 
461 
462  //! \brief Retrieves the Dtk_Node as a Dtk_KinematicPtr - if exists -
463  //! \return The Dtk_Node as a Dtk_KinematicsPtr if exists. Null Dtk_KinematicPtr else.
464  //! \remark This method is used to retrieve the Kinematics
465  //! informations - if GetNodeType() method returns KinematicsType -.
467 
468  //! \brief Retrieves the Dtk_Node as a Dtk_MetaDataPtr - if exists -
469  //! \return The Dtk_Node as a MetaDataPtr if exists. Null MetaDataPtr else.
470  //! \remark This method is used to retrieve the MetaData
471  //! informations - if GetNodeType() method returns MetaDataType -.
473 
474  //! \brief Retrieves the Dtk_Node as a Dtk_DrawingPtr - if exists -
475  //! \return The Dtk_Node as a Dtk_DrawingPtr if exists. Null Dtk_DrawingPtr else.
476  //! \remark This method is used to retrieve the drawing
477  //! informations - if GetNodeType() method returns DrawingType -.
479 
480  //! \brief Retrieves the Dtk_Node as a Dtk_AxisSystemPtr - if exists -
481  //! \return The Dtk_Node as a Dtk_AxisSystemPtr if exists. Null Dtk_AxisSystemPtr else.
482  //! \remark This method is used to retrieve the axis placement
483  //! informations - if GetNodeType() method returns AxisSystemType -.
485 
486  //! \brief Retrieves the Dtk_Node as a Dtk_LayerInfosSetPtr - if exists -
487  //! \return The Dtk_Node as a Dtk_LayerInfosSetPtr if exists. Null Dtk_LayerInfosSetPtr else.
488  //! \remark This method is used to retrieve the layer infos set
489  //! informations - if GetNodeType() method returns LayerInfosSetType -.
491 
492  //! \brief Retrieves the Dtk_Node as a Dtk_ColorInfosSetPtr - if exists -
493  //! \return The Dtk_Node as a Dtk_ColorInfosSetPtr if exists. Null Dtk_ColorInfosSetPtr else.
494  //! \remark This method is used to retrieve the color infos set
495  //! informations - if GetNodeType() method returns ColorInfosSetType -.
497 
498  //! \brief Retrieves the Dtk_Node as a Dtk_ModelDisplayPtr - if exists -
499  //! \return The Dtk_Node as a Dtk_ModelDisplayPtr if exists. Null Dtk_ModelDisplayPtr else.
500  //! \remark This method is used to retrieve the display model entity (camera capture)
501  //! informations - if GetNodeType() method returns ModelDisplayType -.
503 
504  //! \brief Retrieves the Dtk_Node as a Dtk_CameraPtr - if exists -
505  //! \return The Dtk_Node as a Dtk_CameraPtr if exists. Null Dtk_CameraPtr else.
506  //! \remark This method is used to retrieve the camera entity
507  //! informations - if GetNodeType() method returns CameraType -.
509 
510  //! \brief Retrieves the Dtk_Node as a Dtk_ConstraintPtr - if exists -
511  //! \return The Dtk_Node as a Dtk_ConstraintPtr if exists. Null Dtk_ConstraintPtr else.
512  //! \remark This method is used to retrieve the Constraint entity
513  //! informations - if GetNodeType() method returns ConstraintType -.
515 
516  //! \brief Retrieves the Dtk_Node as a Dtk_KinematicsPtr - if exists -
517  //! \return The Dtk_Node as a Dtk_Kinematic if exists. Null Dtk_Kinematics else.
518  //! \remark This method is used to retrieve the kinematic info
519  //! informations - if GetNodeType() method returns KinematicFilterType -.
520  //Dtk_KinematicsPtr GetDtk_KinematicPtr();
521 
522  //! \brief Adds associated entity - Dtk_NodeConnectorPtr - to the Dtk_Node.
523  //! \return DtkNoError if success.
524  //! \param inAssociatedEntity AssociatedEntity to be added.
525  void AddAssociatedEntity ( const Dtk_NodeConnectorPtr& inAssociatedEntity );
526 
527  //! \brief Adds associated entities - Dtk_NodeConnectorPtr - to the Dtk_Node.
528  //! \return DtkNoError if success.
529  //! \param inAssociatedEntities AssociatedEntities to be added.
530  void AddAssociatedEntities ( const Dtk_tab< Dtk_NodeConnectorPtr >& inAssociatedEntities );
531 
532  //! \brief Retrieves the entities associated to the Dtk_Node. They are retrieved via Dtk_NodeConnectorPtr.
533  //! \return DtkNoError if success.
534  //! \param outAssociatedEntities The associatedEntities to be retrieved.
536 
537  //Internal Use
539  void SetStoredInfos(const Dtk_StoredInfoPtr& inInfos);
540 
541  //! \brief Retrieves the Dtk_Node EntityID - read only -
542  //! \return The Entity ID of Node.
544 };
545 /////////////////////////////////////////////////////////////////////////////
546 
547 /////////////////////////////////////////////////////////////////////////////
548 //! \ingroup DtkAPIGroup
549 //! \class Dtk_Component
550 //! \brief This is the Component Class.\n
551 //! The Dtk_ComponentPtr object is used as element into an assembly tree.\n
552 //! Is typically used as a Part into an Assembly Tree.\n
553 //! \SmartPtr{Dtk_ComponentPtr}
555 {
556 public:
558  {
566  };
568  {
573 
574  };
575 
577  {
578  switch( inEnum )
579  {
580  case ComponentMissing: return L"ComponentMissing";
581  case ComponentFound: return L"ComponentFound";
582  case ComponentInternal: return L"ComponentInternal";
583  case ComponentPhantom: return L"ComponentPhantom";
584  case ComponentAdditionnalReference: return L"ComponentAdditionnalReference";
585  case ComponentAssemblyGeometry: return L"ComponentAssemblyGeometry";
586  case ComponentWithUnavailableReader: return L"ComponentWithUnavailableReader";
587 
588  default: return L"Unknown";
589  }
590  }
591 
593  {
594  switch( inEnum )
595  {
596  case CatalogComponentType: return L"CatalogComponentType";
597  case VirtualComponentType: return L"VirtualComponentType";
598  case InstanceComponentType: return L"InstanceComponentType";
599  case PrototypeComponentType: return L"PrototypeComponentType";
600 
601  default: return L"Unknown";
602  }
603  }
604 
605  static inline Dtk_Int32 ComponentTypeStringToInt( const Dtk_string &name )
606  {
607  Dtk_Int32 result = -1;
608 
609  if( name.len() > 0 )
610  {
611  if( name == L"CatalogComponentType" )
612  result = CatalogComponentType;
613  else if( name == L"VirtualComponentType" )
614  result = VirtualComponentType;
615  else if( name == L"InstanceComponentType" )
616  result = InstanceComponentType;
617  else if( name == L"PrototypeComponentType" )
618  result = PrototypeComponentType;
619  }
620 
621  return result;
622  }
623 
624 protected:
626  struct Dtk_Handle; // Not defined here
627  Dtk_Handle *_Private; // Handle
628  friend class Dtk_MainDoc;
629  friend class Dtk_API;
632 private:
633  void _Init();
634  void _Reset();
635  void _Copy(const Dtk_Component&s);
636 
637  //! \sa Dtk_MainDoc::CreatePhysicalDtk_Component()
638  //! \sa Dtk_MainDoc::CreateVirtualDtk_Component()
639  Dtk_Component( const Dtk_ComponentID& inID,
640  const ComponentTypeEnum& inComponentType,
641  const ComponentAvailabilityEnum& inComponentAvailability,
642  const Dtk_Int32& inAdditionnalReferenceFlag,
643  Dtk_string inComponentName,
644  Dtk_string inComponentFullPath,
645  Dtk_string inComponentInstanceName,
646  const Dtk_transfo& inTransformationMatrix,
647  const DtkReaderType& inAssociatedModule,
648  Dtk_string inComponentOriginalName);
649 
650  //! \BaseDestructor
652  friend class Dtk_SmartPtr<Dtk_Component>;
653 
654  void _CheckGlobalDataSet();
655  void _CheckFdtDataSet();
656 public:
657 
658  //! \DtkDynamicType
659  Dtk_Int32 DtkDynamicType(const int& inId);
660 
661  //! \DtkDynamicCast
663 
664  //InternalUse
666 
667 
668  //! \brief Adds a child Dtk_Component to main Component.
669  //! \param inChild The Dtk_Component to be added as a child.
670  inline void AddChild(const Dtk_ComponentPtr& inChild)
672 
673  //! \brief Retrieves the ith Dtk_ComponentPtr - read only -
674  //! \param inPos Child component index.
675  //! \return the inPos'th Dtk_ComponentPtr
676  inline const Dtk_ComponentPtr GetChild(const Dtk_Size_t& inPos) const
677  { return Dtk_ComponentPtr::DtkDynamicCast( _GetChild(inPos) ); }
678 
679  //! \brief Replaces a child Dtk_ComponentPtr by another one. Also updates father lists.
680  //! \param inPos Old Child Dtk_ComponentPtr element index.
681  //! \param inNewChild The Dtk_ComponentPtr replacing the old one
682  //! \DtkInternal
683  //! \return the DtkNoerrror if success.
684  //! \return the dtkErrorOutOfRange if bad inPos parameter.
685  //! \return the dtkErrorNullPointer if inNewChild is NULL.
686  inline Dtk_ErrorStatus ReplaceChildComponent(const Dtk_Size_t& inPos, const Dtk_ComponentPtr& inNewChild)
687  { return _ReplaceChild( inPos, Dtk_DocElementPtr::DtkDynamicCast(inNewChild) ); }
688 
689  //! \brief Retrieves the Dtk_Component Type - read only -
690  //! \return The component Type.
692 
693  //! \brief Gives Dtk_Component availability - read only -
694  //! \return The component availability.
696 
697  //! \brief Retrieves the Dtk_Component FullPathName - read only -
698  //! \return The component FullPathName.
699  const Dtk_string& FullPathName() const;
700 
701  //! \brief Retrieves the Dtk_Component OriginalPathName (read in file) - read only -
702  //! \return The component OriginalPathName.
703  const Dtk_string& OriginalPathName() const;
704 
705  //! \brief Retrieves the Dtk_Component TransformationMatrix - read only -
706  //! \return The component TransformationMatrix.
708 
709  //! \brief Retrieves the Dtk_Component InstanceName - read only -
710  //! \return The component InstanceName.
711  const Dtk_string& InstanceName() const;
712 
713  //! \brief Retrieves the Dtk_Component AssociatedModuleType - read only -
714  //! \return The component AssociatedModuleType.
716 
717  //! \brief Returns DTK_TRUE if Dtk_Component is an assembly.
719 
720  //! \brief Returns DTK_TRUE if Dtk_Component is Additionnal Reference.
722 
723  //! \brief Returns Default Child Index or -1 if Component isn't a catalog
725 
726  //! \brief Returns Activated Children Index or empty array if Component isn't a catalog
728 
729  //! \brief Creates a Virtual Dtk_NodePtr
730  //! \param inName Node name.
731  //! \return the constructed Dtk_NodePtr.
733 
734  //! \brief Creates a Body Dtk_NodePtr from a body ID.
735  //! \param inName Node name.
736  //! \param inBodyID Body Id.
737  //! \param inBodyFlag Body Info : Wire,Solid, MeshSurface and/or Surface.
738  //! \return the constructed Dtk_NodePtr.
739  Dtk_NodePtr CreateBodyNode( Dtk_string inName, const Dtk_ID& inBodyID, const Dtk_Int32 inBodyFlag , const type_detk inSubType = DTK_TYPE_BODY);
740 
741  //! \brief Creates a Mesh Dtk_NodePtr from a Mesh ID.
742  //! \param inName Node name.
743  //! \param inMeshID Mesh Id.
744  //! \return the constructed Dtk_NodePtr.
746  Dtk_string inName,
747  const Dtk_ID& inMeshID,
748  const Dtk_Int32 inMeshFlag,
749  const type_detk inSubType = DTK_TYPE_MESH );
750 
751  //! \brief Creates a Fdt Dtk_NodePtr from a Dtk_FdtPtr ID.
752  //! \param inName Node name.
753  //! \param inFdtID Dtk_FdtPtr ID.
754  //! \return the constructed Dtk_NodePtr.
756  Dtk_string inName,
757  const Dtk_ID& inFdtID, const type_detk inSubType = DTK_TYPE_FDT);
758 
759  //! \brief Creates a Kinematic Dtk_NodePtr from a Dtk_KinematicPtr.
760  //! \param inName Node name.
761  //! \param inKinematicData Dtk_KinematicPtr data.
762  //! \return the constructed Dtk_NodePtr.
764  Dtk_string inName,
765  const Dtk_ID& inKinematicID);
766 
767  //! \brief Creates a Drawing Dtk_NodePtr from a Dtk_DrawingPtr.
768  //! \param inName Node name.
769  //! \param inDrawingID Dtk_DrawingPtr ID.
770  //! \return the constructed Dtk_NodePtr.
771  Dtk_NodePtr CreateDrawingNode( Dtk_string inName, const Dtk_ID& inDrawingID);
772 
773  //! \brief Creates a MetaData Dtk_NodePtr from a Dtk_MetaDataPtr.
774  //! \param inName Node name.
775  //! \param inMetaDataID Dtk_MetaDataPtr ID.
776  //! \return the constructed Dtk_NodePtr.
777  Dtk_NodePtr CreateMetaDataNode( Dtk_string inName, const Dtk_ID& inMetaDataID, const type_detk inSubType = DTK_TYPE_METADATA);
778 
779  //! \brief Creates a Constraint Dtk_NodePtr from a Dtk_ConstraintPtr.
780  //! \param inName Node name.
781  //! \param inConstraintID Dtk_ConstraintPtr ID.
782  //! \return the constructed Dtk_NodePtr.
783  Dtk_NodePtr CreateConstraintNode( Dtk_string inName, const Dtk_ID& inConstraintID, const type_detk inSubType = DTK_TYPE_CONSTRAINT);
784 
785  //! \brief Creates a AxisSystem Dtk_NodePtr from a AxisSystemPtr.
786  //! \param inName Node name.
787  //! \param inAxisSystemID AxisPlacementPtr ID.
788  //! \return the constructed Dtk_NodePtr.
789  Dtk_NodePtr CreateAxisSystemNode( Dtk_string inName, const Dtk_ID& inAxisSystemID, const type_detk inSubType = DTK_TYPE_AXIS_SYSTEM);
790 
791  //! \brief Creates a LayerInfosSet Dtk_NodePtr from a LayerInfosSetPtr.
792  //! \param inName Node name.
793  //! \param inLayerInfosSetID LayerInfosSetPtr ID.
794  //! \return the constructed Dtk_NodePtr.
795  Dtk_NodePtr CreateLayerInfosSetNode( Dtk_string inName, const Dtk_ID& inLayerInfosSetID);
796 
797  //! \brief Creates a ColorInfosSet Dtk_NodePtr from a ColorInfosSetPtr.
798  //! \param inName Node name.
799  //! \param inColorInfosSetID ColorInfosSetPtr ID.
800  //! \return the constructed Dtk_NodePtr.
801  Dtk_NodePtr CreateColorInfosSetNode( Dtk_string inName, const Dtk_ID& inColorInfosSetID);
802 
803  //! \brief Creates a ModelDisplay Dtk_NodePtr from a DisplayModel.
804  //! \param inName Node name.
805  //! \param inModelDisplayID DisplayModel ID.
806  //! \return the constructed Dtk_NodePtr.
807  Dtk_NodePtr CreateModelDisplayNode( Dtk_string inName, const Dtk_ID& inDisplayModelID, const type_detk inSubType = DTK_TYPE_NO_SUBTYPE );
808 
809  //! \brief Creates a Camera Dtk_NodePtr from a Camera.
810  //! \param inName Node name.
811  //! \param inCameraID Camera ID.
812  //! \return the constructed Dtk_NodePtr.
813  Dtk_NodePtr CreateCameraNode( Dtk_string inName, const Dtk_ID& inCameraID);
814 
815  //! \brief Retrieves a Dtk_NodePtr from the Dtk_Component NodesPool giving his Id.
816  //! \param inNodeID Wanted Dtk_NodePtr Id.
817  //! \return The wanted Dtk_NodePtr.
818  Dtk_NodePtr GetNodeByID( const Dtk_NodeID& inNodeID ) const;
819 
820  //! \brief Retrieves the father Dtk_NodePtr of the given Dtk_NodePtr.
821  //! \param inNode The Dtk_NodePtr from which we want the father.
822  //! \return The wanted Dtk_NodePtr.
823  Dtk_NodePtr GetFatherNode(const Dtk_NodePtr& inNode) const;
824 
825  //! \brief Get the Original Units for documents - geometrical data are given in MM (Scale to MM)
826  ////! \param [out] outUnitScale : Unit Scale (1.0 for MM)
827  ////! \return DtkNoError if unit is read
829  //! \brief Gets the Original Units for documents
830  //! \deprecated Use Dtk_Component::GetConceptionUnitScale(Dtk_Double64 &outUnitScale) method instead.
831  SetAsDeprecated("2022.1", "Use Dtk_Component::GetConceptionUnitScale(Dtk_Double64 &outUnitScale) method instead.")
834 
835  //! \brief Gets File Version
836  const Dtk_string & GetFileVersion()const;
837  void SetFileVersion(const Dtk_string & inFileVersion);
838 
839  //! \brief Current layer for Component
840  SetAsDeprecated( "v2026.2", "Use Dtk_LayerInfoSet::GetCurrentLayer instead")
841  Dtk_Int32 GetCurrentLayer() const;
842  SetAsDeprecated( "v2026.2", "Use Dtk_LayerInfoSet::SetCurrentLayer instead")
843  void SetCurrentLayer(Dtk_Int32 inCurrentLayer);
844 
845  //! \brief Visible layer for Component
846  SetAsDeprecated( "v2026.2", "Use GetLayerInfosSet() then Dtk_LayerInfosSet::GetLayersFlaggedAs( Dtk_LayerInfosSet::Layer::Status::Visible ) instead")
847  void GetVisibleLayers(Dtk_tab<Dtk_Int32> &outVisibleLayers)const;
848  SetAsDeprecated( "v2026.2", "Use Dtk_LayerInfosSet::AddLayer instead" )
849  void SetVisibleLayers(const Dtk_tab<Dtk_Int32> & inVisibleLayers);
850 
851  //! \brief Selectable layer for Component
852  SetAsDeprecated( "v2026.2", "Use GetLayerInfosSet() then Dtk_LayerInfosSet::GetLayersFlaggedAs( Dtk_LayerInfosSet::Layer::Status::Selectable ) instead")
853  void GetSelectableLayers(Dtk_tab<Dtk_Int32> &outSelectableLayers)const;
854  SetAsDeprecated( "v2026.2", "Use Dtk_LayerInfosSet::AddLayer instead" )
855  void SetSelectableLayers(const Dtk_tab<Dtk_Int32> & inSelectableLayers);
856 
857  //! \brief Retrieves the Dtk_LayerInfosSet of this component
858  //! \remark Dtk_API::ReadComponent has to be called for the layer set to be available.
859  //! \return The Dtk_LayerInfosSet of this component.
861 
862  //! \brief SiblingName for Component
863  DtkErrorStatus GetSiblingName(Dtk_string &outSiblingName)const;
864  DtkErrorStatus SetSiblingName(const Dtk_string & inSiblingName);
865 
866 
867  //! \brief Gives number of Nodes in the Component (useful if you want to handle progress bar).
868  //! \return number of Nodes.
870 
871  //! \brief Attaches SelectionDataSet infos to the Dtk_Component - through the Dtk_GlobalDataSetPtr -.
872  void SetSelectionDataSet( const Dtk_SelectionDataSetPtr& inSelectionDataSet);
873 
874  //! \brief Retrieves the Dtk_GlobalDataSetPtr attached to the Dtk_Component - get only -.
875  //! \return The attached Dtk_GlobalDataSetPtr - can be null -
877 
878 
879  //! \brief Retrieves the connectors pointing on this component.
880  //! \return The pointing connectors.
882 
883  //! \brief Devalidates Component into MainDoc.
884  //! \param inNodeID The NodeID to devalidate.
885  //! \return DtkNoError if success.
886  //! \remark Internal Use only.
888 
889  //! \brief Gets BoundingBox on Prototype Component if it can be read in original file
890  //! \param [out] outMin Resulting minimum coordinates
891  //! \param [out] outMax Resulting maximum coordinates
892  //! \return DtkNoError if success.
894 
895  //! \brief Adds Override set to a prototype component
896  //! \return dtkNoError if ok.
898 
899  //! \brief Gives number of Override sets in a prototype component
900  //! \return Override sets.
902 
903  //! \brief Gives array of Override sets in a prototype component
904  //! \return dtkNoError if ok.
906 
907  //! \brief Sets array of Override sets in a prototype component
908  //! \return dtkNoError if ok.
910 };
911 /////////////////////////////////////////////////////////////////////////////
912 
913 /////////////////////////////////////////////////////////////////////////////
914 //! \ingroup DtkAPIGroup
915 //! \class Dtk_MainDoc
916 //! \brief This is the Document Class.\n
917 //! The Dtk_MainDocPtr object is used as root element produced by a translation.\n
918 //! It contains the root Dtk_ComponentPtr.
919 //! \SmartPtr{Dtk_MainDocPtr}
920 class Dtk_MainDoc : public Dtk_Object
921 {
922  friend class Dtk_MainDocWrapper;
923 public:
924  struct Dtk_Handle; // Not defined here
925 protected:
927  Dtk_Handle *_Private; // Handle
928  friend class Dtk_API;
931 private:
932  void _Init();
933  void _Reset();
934  void _Copy(const Dtk_MainDoc&s);
935 
936  //! \sa Create
937  Dtk_MainDoc();
938  //! \BaseDestructor
939  ~Dtk_MainDoc();
940 
941  void _AddComponentIntoPool(Dtk_ComponentPtr& outElt);
942 
943  friend class Dtk_SmartPtr<Dtk_MainDoc>;
944 public:
945 
946  //! \CreateBase
948 
949  //! \DtkDynamicType
950  Dtk_Int32 DtkDynamicType(const int& inId);
951 
952  //! \DtkDynamicCast
954 
955  //! \brief Set the root Dtk_ComponentPtr.
956  //! \param inRootComponent The root Ccomponent
957  void SetRootComponent(const Dtk_ComponentPtr& inRootComponent);
958 
959  //! \brief Retrieves the root Dtk_ComponentPtr of the Dtk_MainDoc.
960  //! \return The root Dtk_ComponentPtr.
962 
963  //! \brief Creates a physical Dtk_ComponentPtr.
964  //! \param inComponentType Component type - Part or Assembly -.
965  //! \param inComponentFullPath Component full path.
966  //! \param inComponentName Component name.
967  //! \param inInstanceName Instance name.
968  //! \param inTransformationMatrix Transformation matrix.
969  //! \param inAssociatedModule Associated module - Unknown by default -.
970  //! \return the constructed Dtk_ComponentPtr.
971 
972  //! \brief Creates an Instance Dtk_ComponentPtr.
973  //! \param inPrototype The Prototype Dtk_ComponentPtr used to create instance.
974  //! \param inInstanceName Instance name.
975  //! \param inTransformationMatrix Transformation matrix.
976  //! \return the constructed InstanceDtk_ComponentPtr.
977  //! \remark The Prototype is automatically linked to the instance.
979  const Dtk_ComponentPtr& inPrototype,
981  const Dtk_transfo& inTransformationMatrix);
982 
983  //! \brief Creates a Prototype Dtk_ComponentPtr.
984  //! This type handles Assemblies and part components.
985  //! \param inComponentFullPath Component full path.
986  //! \param inComponentName Component name.
987  //! \param inAssociatedModule Associated module - Unknown by default -.
988  //! \param inAvailability : Is component found/missing or internal
989  //! \param inAdditionnalReferenceFlag : Is component an additionnal reference ( not part of assembly) or not
990  //! \return the constructed Prototype Dtk_ComponentPtr.
992  Dtk_string inComponentFullPath,
993  Dtk_string inComponentName,
994  const DtkReaderType& inAssociatedModule,
995  const Dtk_Component::ComponentAvailabilityEnum& inAvailability,
996  const int inAdditionnalReferenceFlag = 0,
997  Dtk_string inOriginalName=Dtk_string());
998 
999  //! \brief Creates a virtual Dtk_ComponentPtr.
1000  //! \param inComponentName Component name.
1001  //! \param inAssociatedModule Associated module - Unknown by default -.
1002  //! \return the constructed Dtk_ComponentPtr.
1003  //! \remark A virtual Dtk_ComponentPtr hasn't any full path.
1005  Dtk_string inComponentName,
1006  const DtkReaderType& inAssociatedModule,
1007  Dtk_string inComponentFullPath,
1008  const Dtk_Component::ComponentAvailabilityEnum& inAvailability);
1009 
1010  //! \brief Creates a Catalog Dtk_ComponentPtr.
1011  //! \param inComponentFullPath Component full path.
1012  //! \param inComponentName Component name.
1013  //! \param inInstanceName Instance name.
1014  //! \param inTransformationMatrix Transformation matrix.
1015  //! \param inAssociatedModule Associated module - Unknown by default -.
1016  //! \return the constructed Dtk_ComponentPtr.
1018  Dtk_string inComponentFullPath,
1019  Dtk_string inComponentName,
1021  const Dtk_transfo& inTransformationMatrix,
1022  const DtkReaderType& inAssociatedModule = UnknownModule,
1024  Dtk_string inOriginalName = Dtk_string());
1025 
1026 
1027 
1028  //! \brief Retrieves a Dtk_ComponentPtr giving its ID.
1029  //! \param inComponentID The component ID
1030  //! \return The wanted Dtk_ComponentPtr.
1031  Dtk_ComponentPtr GetComponentByID( const Dtk_ComponentID& inComponentID ) const;
1032 
1033  //! \brief Retrieves the inIndexth father of the giving Dtk_ComponentPtr.
1034  //! \param inComponent The component from which we want the father.
1035  //! \param inIndex index of father wanted.
1036  //! \return The wanted Dtk_ComponentPtr.
1038 
1039  //! \brief Retrieves the inIndexth father of the giving Dtk_ComponentPtr.
1040  //! \param inComponent The component from which we want the number of fathers.
1041  //! \return The number of father.
1043 
1044  //! \brief Give number of Components in the Dtk_MainDoc (useful if you want to handle progress bar).
1045  //! \return number of Components.
1047 
1048  //! \brief Give number of InstanceComponents in the Dtk_MainDoc
1049  //! \return number of Instance Components.
1051 
1052  //! \brief Indicate that document contains several independant models
1053  //! \return DTK_TRUE if the MainDoc represent a multi model document.
1055 
1056  //! \brief Set flag to indicate that document contains several independant models
1057  void SetMultiModelFlag(Dtk_bool inMultiModelFlag);
1058 
1059  //! \brief Devalidates Component into MainDoc.
1060  //! \param inComponentID The ComponentID to devalidate.
1061  //! \return DtkNoError if success.
1062  //! \remark Internal Use only.
1064 
1065  //! \brief return list of missing files into MainDoc.
1066  //! \param outFileList : list of missing files
1067  //! \return DtkNoError if success.
1069 
1070  //! \brief return list of additional reference files into MainDoc.
1071  //! \param outFileList : list of additionnal reference files
1072  //! \return DtkNoError if success.
1074 
1075 };
1076 
1077 /////////////////////////////////////////////////////////////////////////////
1078 //! \ingroup DtkAPIGroup
1079 //! \class Dtk_NodeConnector
1080 //! \brief This is the Dtk_NodeConnector Class.\n
1081 //! \SmartPtr{Dtk_NodeConnectorPtr}
1083 {
1084 public:
1085  //! \brief Reason - Type of the Dtk_NodeConnector -. It's used to filter connectors to same elements.
1087  {
1088  Unknown = 0,
1089  //Placement Reasons
1090  VerticallyAligned, //the pointing entity is bound to the the position of pointed one, so that they stay vertically aligned
1091  HorizontallyAligned, //the pointing entity is bound to the the position of pointed one, so that they stay horizontally aligned
1092  StackedLeft, //the pointing entity is bound to the the position of pointed one, so that it is kept to the left
1093  StackedRight, //the pointing entity is bound to the the position of pointed one, so that it is kept to the right
1094  StackedAbove, //the pointing entity is bound to the the position of pointed one, so that it is kept above
1095  StackedBelow, //the pointing entity is bound to the the position of pointed one, so that it is kept below
1096  PositionallyFixed, //the pointing entity positon is constrained by the pointed one
1097  OrientationallyFixed, //the pointing entity direction is constrained by the pointed one
1098  ForceHidden, //the pointed entity is forced to be hidden
1099  ForceVisible, //the pointed entity is forced to be visible
1100  ForceColor, //the pointed entity is forced to change color
1101  ForceRender, //the pointed entity is forced to change render info
1102  ForceClipped, //the pointed entity is forced to be clipped by light section view
1103  KeepOnlyFdt, //keep only pmi
1104 
1105  //Category used to qualify links from the 1st Dtk_ReferenceBlockPtr - [PT] / [SL] / [PL] -
1106  //These links can apply to a reference into Dtk_ReferenceBlockPtr - 3 1st references handled - or to the common datum - the whole Dtk_ReferenceBlockPtr
1111 
1112  //Category used to qualify links from the 2nd Dtk_ReferenceBlockPtr - [PT] / [SL] / [PL] -
1113  //These links can apply to a reference into Dtk_ReferenceBlockPtr - 3 1st references handled - or to the common datum - the whole Dtk_ReferenceBlockPtr
1118 
1119  //Category used to qualify links from the 3rd Dtk_ReferenceBlockPtr - [PT] / [SL] / [PL] -
1120  //These links can apply to a reference into Dtk_ReferenceBlockPtr - 3 1st references handled - or to the common datum - the whole Dtk_ReferenceBlockPtr
1125 
1126  //General Associations
1138 
1140 
1141  };
1142  static inline Dtk_string ReasonLinkEnumToString(const ReasonLinkEnum& inEnum)
1143  {
1144  switch( inEnum )
1145  {
1146  case VerticallyAligned: return L"VerticallyAligned";
1147  case HorizontallyAligned: return L"HorizontallyAligned";
1148  case StackedLeft: return L"StackedLeft";
1149  case StackedRight: return L"StackedRight";
1150  case StackedAbove: return L"StackedAbove";
1151  case StackedBelow: return L"StackedBelow";
1152  case PositionallyFixed: return L"PositionallyFixed";
1153  case OrientationallyFixed: return L"OrientationallyFixed";
1154  case ForceHidden: return L"ForceHidden";
1155  case ForceVisible: return L"ForceVisible";
1156  case ForceClipped: return L"ForceClipped";
1157  case KeepOnlyFdt: return L"KeepOnlyFdt";
1158  case ForceColor: return L"ForceColor";
1159  case ForceRender: return L"ForceRender";
1160 
1161  case AssociatedGeometry: return L"AssociatedGeometry";
1162  case AssociatedFeature: return L"AssociatedFeature";
1163  case SubPMI: return L"SubPMI";
1164  case DefaultAnnotationLink: return L"DefaultAnnotationLink";
1165  case HighlightedGeometry: return L"HighlightedGeometry";
1166  case Support: return L"Support";
1167  case AssociatedAxisSystem: return L"AssociatedAxisSystem";
1168  case AssociatedXDirection: return L"AssociatedXDirection";
1169  case AssociatedYDirection: return L"AssociatedYDirection";
1170  case AssociatedZDirection: return L"AssociatedZDirection";
1171  case AssociatedCenterPoint: return L"AssociatedCenterPoint";
1172 
1173  case Context: return L"Context";
1174 
1175  case FirstRefBlockSituation_Common: return L"FirstRefBlockSituation_Common";
1176  case FirstRefBlockSituation_1: return L"FirstRefBlockSituation_1";
1177  case FirstRefBlockSituation_2: return L"FirstRefBlockSituation_2";
1178  case FirstRefBlockSituation_3: return L"FirstRefBlockSituation_3";
1179 
1180  case SecondRefBlockSituation_Common: return L"SecondRefBlockSituation_Common";
1181  case SecondRefBlockSituation_1: return L"SecondRefBlockSituation_1";
1182  case SecondRefBlockSituation_2: return L"SecondRefBlockSituation_2";
1183  case SecondRefBlockSituation_3: return L"SecondRefBlockSituation_3";
1184 
1185  case ThirdRefBlockSituation_Common: return L"ThirdRefBlockSituation_Common";
1186  case ThirdRefBlockSituation_1: return L"ThirdRefBlockSituation_1";
1187  case ThirdRefBlockSituation_2: return L"ThirdRefBlockSituation_2";
1188  case ThirdRefBlockSituation_3: return L"ThirdRefBlockSituation_3";
1189 
1190  default: return L"Unknown";
1191  }
1192  }
1193 
1194  //! \brief Reason Category. Global Category of the NodeConnector uesed to gather Reason into families.
1196  {
1197  UnknownCategory = 0,
1198  PlacementCategory, //General Placement Category gathering all Placement Reasons
1202 
1206  };
1208  {
1209  switch( inEnum )
1210  {
1211  case PlacementCategory: return L"PlacementCategory";
1212  case GeneralAssociationCategory: return L"GeneralAssociationCategory";
1213  case VisibilityCategory: return L"VisibilityCategory";
1214  case AppearanceCategory: return L"AppearanceCategory";
1215  case FirstRefBlockSituationCategory: return L"FirstRefBlockSituationCategory";
1216  case SecondRefBlockSituationCategory: return L"SecondRefBlockSituationCategory";
1217  case ThirdRefBlockSituationCategory: return L"ThirdRefBlockSituationCategory";
1218  default: return L"UnknownCategory";
1219  }
1220  }
1221 
1223  {
1224  private:
1225  Dtk_ID _SubEntityID; // optional: Set of IDs (in case the connector links to a geometric entity (construction)
1226  type_detk _SubEntityType; // optional: The list of entities types
1227  public:
1228  inline SubEntity( ) : _SubEntityID(0), _SubEntityType(DTK_TYPE_UNKNOWN){}
1229  inline SubEntity( const Dtk_ID inSubEntityID, const type_detk inSubEntityType ) : _SubEntityID(inSubEntityID), _SubEntityType(inSubEntityType){}
1230  inline SubEntity( const SubEntity& inTobeCopied ) : _SubEntityID(inTobeCopied._SubEntityID), _SubEntityType(inTobeCopied._SubEntityType){}
1231  inline ~SubEntity() {}
1232 
1233  inline Dtk_ID GetSubEntityId() const {return _SubEntityID;}
1234  inline type_detk GetSubEntityType() const {return _SubEntityType;}
1235  friend Dtk_bool operator==(const SubEntity&, const SubEntity&);
1236 
1237  };
1238 
1239 protected:
1240  struct Dtk_Handle; // Not defined here
1241  Dtk_Handle *_Private; // Handle
1242 
1243  enum
1244  {
1246  };
1247 
1248  //! \BaseConstructor
1250 
1251  //! \CopyConstructor{in}
1253 
1254  //! \BaseDestructor
1256 
1257  inline virtual Dtk_Object* Clone() { return new Dtk_NodeConnector(*this); }
1258 
1259 protected:
1260  void _Init();
1261  void _Reset();
1262  void _Copy(const Dtk_NodeConnector &s);
1263  friend class Dtk_SmartPtr<Dtk_NodeConnector>;
1264 public:
1265  friend class Dtk_Node;
1266  //! \DtkDynamicType
1268 
1269  //! \DtkDynamicCast
1271 
1272  //! \CreateBase
1274 
1275  //! \CreateCopy{in}
1277 
1278  //! \return The type of the entity type - DTK_TYPE_FDT -
1280 
1281  //! \brief Returns the Component ID referenced by the connector
1283  //! \brief Sets the component ID
1284  void SetAssociatedComponentID (const Dtk_ID &inComponentID);
1285 
1286  //! \brief Returns the Path Component ID referenced by the connector from Root to Target
1288  void GetAssociatedPathComponentID(Dtk_tab<Dtk_ID>& outAssociatedPathComponentID) const ;
1289  //! \brief Sets the Path Component ID from Root to Target
1290  void SetAssociatedPathComponentID (const Dtk_tab<Dtk_ID> &inPathComponentID);
1291  //! \brief Checks if the Path Component ID exist into Dtk_MainDocPtr
1292  //! \brief Returns true if path connector exists else returns false
1294 
1295  //! \brief Returns the Node id referenced by the connector
1296  Dtk_ID GetNodeId() const ;
1297  //! \brief Sets the Node id
1298  void SetNodeId(const Dtk_ID &inNodeId);
1299 
1300 
1301  //! \brief Returns the number of the geometric entities
1303 
1304  //! \brief Retrieves The connected SubEntities - IDs and types -
1305  //! \param outEntitiesIDs SubEntities Ids
1306  //! \param outEntitiesTypes SubEntities types
1307  //! \remark Sizes of the 2 arrays are equal
1308  //! \return DtkNoError if no error.
1309  Dtk_ErrorStatus GetSubEntities(Dtk_tab <Dtk_ID>& outEntitiesIDs, Dtk_tab <type_detk> & outEntitiesTypes) const;
1310 
1311  //! \brief Returns the set of Additional Entities defined by their IDs and Types
1312  //! \param inEntitiesIDs SubEntities Ids
1313  //! \param inEntitiesTypes SubEntities types
1314  //! \remark The size of the 2 arrays must be equal
1315  //! \return DtkNoError if no error.
1316  Dtk_ErrorStatus SetSubEntities(const Dtk_tab <Dtk_ID> &inEntitiesIDs, const Dtk_tab <type_detk> & inEntitiesTypes);
1317 
1318  //! \brief Sets of SubEntities - defined by their IDs and Types -
1319  //! \param inSubEntities SubEntities array
1320  //! \return DtkNoError if no error.
1322 
1323  //! \brief Add a set of SubEntities - defined by their IDs and Types - to the SubEntities list
1324  //! \param inSubEntities SubEntities array
1325  //! \return DtkNoError if no error.
1327 
1328  //! \brief Add a SubEntity - defined by their IDs and Types - to the SubEntities list
1329  //! \param inSubEntity SubEntity
1330  //! \return DtkNoError if no error.
1332 
1333  //! \brief Retrieves the SubEntities array - defined by their IDs and Types -
1334  //! \param outSubEntities The resulting SubEntities array
1335  //! \return DtkNoError if no error.
1337 
1338  //! \brief Retrieves the pointing entity FullType. Should be the FullType of the Dtk_Node containing the Dtk_NodeConnector
1339  //! \return The pointing entity FullType.
1341 
1342  //! \brief Sets the pointing entity Type.
1343  //! \param inPointingEntityType The pointing entity Type.
1344  void SetPointingEntityType( const Dtk_Node::FullType inPointingEntityType );
1345 
1346  //! \brief Sets the pointed entity Type.
1347  //! \param inPointedEntityType The pointed entity Type.
1348  void SetPointedEntityType( const type_detk inPointedEntityType);
1349 
1350  //! \brief Retrieves the pointed entity Type.
1351  //! \return The pointed entity Type.
1353 
1354  //! \brief Sets the Reason Link of the Dtk_NodeConnector to specify the reason of the connection.
1355  //! \param inReasonLink The Reason Link
1356  void SetReasonLink( const ReasonLinkEnum inReasonLink );
1357 
1358  //! \brief Gets the Reason Link of the Dtk_NodeConnector to specify the reason of the connection.
1359  //! \param outReasonCategory The Reason Category - processed from the ReasonLink -
1360  //! \return The Reason Link.
1362 
1363  //! \brief Set the Color Id for ForceColor connectors
1364  //! \param inColorId The Color Id
1365  void SetColorId( Dtk_ID inColorId) ;
1366 
1367  //! \brief Retrieves the Color Id for ForceColor connectors
1368  //! \return The Color Id ( > 0 if exists, 0 otherwise).
1370 
1371  //! \brief Set the Render Id for ForceRender connectors
1372  //! \param inRenderId The Render Id
1373  void SetRenderId( Dtk_ID inRenderId );
1374 
1375  //! \brief Retrieves the Render Id for ForceRender connectors
1376  //! \return The Render Id ( > 0 if exists, 0 otherwise).
1378 };
1379 
1380 
1381 /////////////////////////////////////////////////////////////////////////////
1382 
1383 
1384 #endif
Dtk_NodeConnector::SetNodeId
void SetNodeId(const Dtk_ID &inNodeId)
Sets the Node id.
Dtk_Node::FullType::FullType
FullType(const NodeDataTypeEnum inPrimaryType, const type_detk inSubType)
Definition: dtk_maindoc.hpp:279
Dtk_Node::AnnotationSetType
@ AnnotationSetType
Definition: dtk_maindoc.hpp:251
Dtk_feat
Generic Feature All metric data in feature classes are given in MM All angular data are given in degr...
Definition: str_feat_dtk.hpp:6859
Dtk_NodeConnector::ReasonLinkEnum
ReasonLinkEnum
Reason - Type of the Dtk_NodeConnector -. It's used to filter connectors to same elements.
Definition: dtk_maindoc.hpp:1087
Dtk_Component::CreateCameraNode
Dtk_NodePtr CreateCameraNode(Dtk_string inName, const Dtk_ID &inCameraID)
Creates a Camera Dtk_NodePtr from a Camera.
Dtk_NodeConnector::SetPointingEntityType
void SetPointingEntityType(const Dtk_Node::FullType inPointingEntityType)
Sets the pointing entity Type.
Dtk_NodeConnector::KeepOnlyFdt
@ KeepOnlyFdt
Definition: dtk_maindoc.hpp:1103
dtk_global_data_set_ptr.hpp
CaddsReaderModule
@ CaddsReaderModule
Definition: dtk_maindoc.hpp:45
Dtk_MainDoc::GetComponentByID
Dtk_ComponentPtr GetComponentByID(const Dtk_ComponentID &inComponentID) const
Retrieves a Dtk_ComponentPtr giving its ID.
RnXmlReaderModule
@ RnXmlReaderModule
Definition: dtk_maindoc.hpp:59
Dtk_Component::DtkDynamicType
Dtk_Int32 DtkDynamicType(const int &inId)
Retrieves the dynamic entity type.
UsdReaderModule
@ UsdReaderModule
Definition: dtk_maindoc.hpp:81
Dtk_NodeConnector::_Reset
void _Reset()
Dtk_ID
uint32_t Dtk_ID
Definition: define.h:681
Dtk_transfo
This is the Transformation dedicated class.
Definition: dtk_transfo.hpp:19
Dtk_Node::HasMeshSurfaces
@ HasMeshSurfaces
Definition: dtk_maindoc.hpp:243
CerconReaderModule
@ CerconReaderModule
Definition: dtk_maindoc.hpp:48
Dtk_NodeConnector::SetPointedEntityType
void SetPointedEntityType(const type_detk inPointedEntityType)
Sets the pointed entity Type.
Dtk_NodeConnector
This is the Dtk_NodeConnector Class. .
Definition: dtk_maindoc.hpp:1083
Dtk_DocElement::GetFatherID
Dtk_ID GetFatherID(Dtk_Size_t inIndex) const
Retrieves Dtk_DocElement ith FatherID - read only -.
PlmXmlReaderModule
@ PlmXmlReaderModule
Definition: dtk_maindoc.hpp:55
NavisReaderModule
@ NavisReaderModule
Definition: dtk_maindoc.hpp:77
DTK_TYPE_UNKNOWN
@ DTK_TYPE_UNKNOWN
Definition: define.h:26
Dtk_Component::CreateMeshNode
Dtk_NodePtr CreateMeshNode(Dtk_string inName, const Dtk_ID &inMeshID, const Dtk_Int32 inMeshFlag, const type_detk inSubType=DTK_TYPE_MESH)
Creates a Mesh Dtk_NodePtr from a Mesh ID.
Dtk_Component::GetChild
const Dtk_ComponentPtr GetChild(const Dtk_Size_t &inPos) const
Retrieves the ith Dtk_ComponentPtr - read only -.
Definition: dtk_maindoc.hpp:676
Dtk_Node::GetDtk_ModelDisplayPtr
Dtk_ModelDisplayPtr GetDtk_ModelDisplayPtr()
Retrieves the Dtk_Node as a Dtk_ModelDisplayPtr - if exists -.
Dtk_NodeConnector::Support
@ Support
Definition: dtk_maindoc.hpp:1132
Dtk_DocElement::~Dtk_DocElement
virtual ~Dtk_DocElement()
Destructor.
Dtk_Node::FdtType
@ FdtType
Definition: dtk_maindoc.hpp:252
Dtk_Node::FullType::~FullType
~FullType()
Definition: dtk_maindoc.hpp:280
Dtk_NodeConnector::SubEntity::SubEntity
SubEntity(const SubEntity &inTobeCopied)
Definition: dtk_maindoc.hpp:1230
DTK_TYPE_MESH
@ DTK_TYPE_MESH
Definition: define.h:468
Dtk_Component::CatalogComponentType
@ CatalogComponentType
Definition: dtk_maindoc.hpp:571
_3dmReaderModule
@ _3dmReaderModule
Definition: dtk_maindoc.hpp:60
Dtk_Node::GetDtk_KinematicPtr
Dtk_KinematicPtr GetDtk_KinematicPtr()
Retrieves the Dtk_Node as a Dtk_KinematicPtr - if exists -.
Dtk_Node::BodyNodeDataTypeEnum
BodyNodeDataTypeEnum
Definition: dtk_maindoc.hpp:235
Dtk_Node::HasAxis
@ HasAxis
Definition: dtk_maindoc.hpp:241
Dtk_NodeConnector::GetSubEntities
Dtk_ErrorStatus GetSubEntities(Dtk_tab< Dtk_ID > &outEntitiesIDs, Dtk_tab< type_detk > &outEntitiesTypes) const
Retrieves The connected SubEntities - IDs and types -.
Dtk_Component::AddChild
void AddChild(const Dtk_ComponentPtr &inChild)
Adds a child Dtk_Component to main Component.
Definition: dtk_maindoc.hpp:670
DTK_TYPE_NODE_CONNECTOR
@ DTK_TYPE_NODE_CONNECTOR
Definition: define.h:474
Dtk_MainDoc::GetFatherComponent
Dtk_ComponentPtr GetFatherComponent(const Dtk_ComponentPtr &inComponent, Dtk_Size_t inIndex) const
Retrieves the inIndexth father of the giving Dtk_ComponentPtr.
Dtk_NodeConnector::Create
static Dtk_NodeConnectorPtr Create(const Dtk_NodeConnector &in)
Calls copy constructor to allocate a new object.
Dtk_DocElement::Dtk_DocElement
Dtk_DocElement(const Dtk_ID &inID, Dtk_string inName)
Dtk_Component::CreateLayerInfosSetNode
Dtk_NodePtr CreateLayerInfosSetNode(Dtk_string inName, const Dtk_ID &inLayerInfosSetID)
Creates a LayerInfosSet Dtk_NodePtr from a LayerInfosSetPtr.
Dtk_DocElement::_Reset
void _Reset()
Dtk_NodeConnector::VerticallyAligned
@ VerticallyAligned
Definition: dtk_maindoc.hpp:1090
Dtk_NodeConnector::ThirdRefBlockSituation_1
@ ThirdRefBlockSituation_1
Definition: dtk_maindoc.hpp:1122
DTK_TYPE_DOC_ELEMENT
@ DTK_TYPE_DOC_ELEMENT
Definition: define.h:501
Dtk_Node::HasSurfaces
@ HasSurfaces
Definition: dtk_maindoc.hpp:239
Dtk_DocElement::GetNumFathers
Dtk_Size_t GetNumFathers() const
GetNumFather.
Dtk_Component::CreateConstraintNode
Dtk_NodePtr CreateConstraintNode(Dtk_string inName, const Dtk_ID &inConstraintID, const type_detk inSubType=DTK_TYPE_CONSTRAINT)
Creates a Constraint Dtk_NodePtr from a Dtk_ConstraintPtr.
Dtk_Component::_typeID
@ _typeID
Definition: dtk_maindoc.hpp:625
PsReaderModule
@ PsReaderModule
Definition: dtk_maindoc.hpp:40
Dtk_Component::SetOverrideSets
DtkErrorStatus SetOverrideSets(const Dtk_tab< Dtk_OverrideSetPtr > &inOverrideSets)
Sets array of Override sets in a prototype component.
Dtk_NodeConnector::GetColorId
Dtk_Int32 GetColorId() const
Retrieves the Color Id for ForceColor connectors.
Dtk_Node::FullType::PrimaryType
NodeDataTypeEnum PrimaryType() const
Definition: dtk_maindoc.hpp:282
Dtk_NodeConnector::ForceColor
@ ForceColor
Definition: dtk_maindoc.hpp:1100
Dtk_Component::CreateAxisSystemNode
Dtk_NodePtr CreateAxisSystemNode(Dtk_string inName, const Dtk_ID &inAxisSystemID, const type_detk inSubType=DTK_TYPE_AXIS_SYSTEM)
Creates a AxisSystem Dtk_NodePtr from a AxisSystemPtr.
Dtk_NodeConnector::StackedBelow
@ StackedBelow
Definition: dtk_maindoc.hpp:1095
Dtk_NodeConnector::ForceHidden
@ ForceHidden
Definition: dtk_maindoc.hpp:1098
Dtk_Node::NodeHasSolids
Dtk_bool NodeHasSolids() const
Return DTK_TRUE if Dtk_Node Type Body contains solid entity.
Dtk_Node::NodeHasPoints
Dtk_bool NodeHasPoints() const
Return DTK_TRUE if Dtk_Node Type Body or Mesh contains points entity.
Dtk_DocElement::_Private
Dtk_Handle * _Private
Definition: dtk_maindoc.hpp:106
Dtk_NodeConnector::ThirdRefBlockSituation_Common
@ ThirdRefBlockSituation_Common
Definition: dtk_maindoc.hpp:1121
Dtk_Node::HasSolids
@ HasSolids
Definition: dtk_maindoc.hpp:240
Dtk_Component::GetActivatedChildrenInCatalog
Dtk_tab< Dtk_Int32 > GetActivatedChildrenInCatalog() const
Returns Activated Children Index or empty array if Component isn't a catalog.
Dtk_NodeConnector::AssociatedYDirection
@ AssociatedYDirection
Definition: dtk_maindoc.hpp:1135
Dtk_Component::CreateModelDisplayNode
Dtk_NodePtr CreateModelDisplayNode(Dtk_string inName, const Dtk_ID &inDisplayModelID, const type_detk inSubType=DTK_TYPE_NO_SUBTYPE)
Creates a ModelDisplay Dtk_NodePtr from a DisplayModel.
Dtk_DocElement::GetMetaData
Dtk_MetaDataPtr GetMetaData(const Dtk_Size_t &inPos) const
Retrieves the ith Dtk_MetaDataPtr - read only -.
CerecReaderModule
@ CerecReaderModule
Definition: dtk_maindoc.hpp:49
Dtk_NodeConnector::Dtk_NodeConnector
Dtk_NodeConnector(const Dtk_NodeConnector &in)
Copy constructor.
Dtk_NodeConnector::SetRenderId
void SetRenderId(Dtk_ID inRenderId)
Set the Render Id for ForceRender connectors.
Dtk_MainDoc::_Private
Dtk_Handle * _Private
Definition: dtk_maindoc.hpp:927
Dtk_NodeConnector::FirstRefBlockSituation_3
@ FirstRefBlockSituation_3
Definition: dtk_maindoc.hpp:1110
Dtk_Node::NodeDataTypeEnum
NodeDataTypeEnum
Definition: dtk_maindoc.hpp:247
PrcReaderModule
@ PrcReaderModule
Definition: dtk_maindoc.hpp:73
V5ReaderModule
@ V5ReaderModule
Definition: dtk_maindoc.hpp:30
Dtk_DocElement::_typeID
@ _typeID
Definition: dtk_maindoc.hpp:105
Dtk_API::Dtk_Component
friend class Dtk_Component
Definition: dtk_api.hpp:137
Dtk_Component::CreateKinematicsNode
Dtk_NodePtr CreateKinematicsNode(Dtk_string inName, const Dtk_ID &inKinematicID)
Creates a Kinematic Dtk_NodePtr from a Dtk_KinematicPtr.
Dtk_Node::ModelDisplayType
@ ModelDisplayType
Definition: dtk_maindoc.hpp:259
Dtk_KinematicPtr
Dtk_SmartPtr< Dtk_Kinematic > Dtk_KinematicPtr
Definition: dtk_maindoc.hpp:24
SatReaderModule
@ SatReaderModule
Definition: dtk_maindoc.hpp:42
Dtk_DocElement::_Copy
void _Copy(const Dtk_Node &s)
Dtk_NodeConnector::_Private
Dtk_Handle * _Private
Definition: dtk_maindoc.hpp:1240
Dtk_NodeConnector::AssociatedAxisSystem
@ AssociatedAxisSystem
Definition: dtk_maindoc.hpp:1133
Zw3dReaderModule
@ Zw3dReaderModule
Definition: dtk_maindoc.hpp:80
Dtk_Node::_Private
Dtk_Handle * _Private
Definition: dtk_maindoc.hpp:348
Dtk_string
This is a high level string class.
Definition: dtk_string.hpp:53
Dtk_NodeConnector::StackedAbove
@ StackedAbove
Definition: dtk_maindoc.hpp:1094
Dtk_Node::NodeHasMeshSurfaces
Dtk_bool NodeHasMeshSurfaces() const
Return DTK_TRUE if Dtk_Node Type Body contains mesh surface entity.
Dtk_Size_t
size_t Dtk_Size_t
Definition: define.h:704
Dtk_NodeConnector::SubEntity
Definition: dtk_maindoc.hpp:1223
Dtk_MainDoc::SetMultiModelFlag
void SetMultiModelFlag(Dtk_bool inMultiModelFlag)
Set flag to indicate that document contains several independant models.
Dtk_MainDoc::_ReleaseComponents
void _ReleaseComponents()
Dtk_Component::IsAdditionnalReference
Dtk_bool IsAdditionnalReference() const
Returns DTK_TRUE if Dtk_Component is Additionnal Reference.
Dtk_Node::KinematicsType
@ KinematicsType
Definition: dtk_maindoc.hpp:254
Dtk_Component::SetSiblingName
DtkErrorStatus SetSiblingName(const Dtk_string &inSiblingName)
XmlReaderModule
@ XmlReaderModule
Definition: dtk_maindoc.hpp:52
DTK_TYPE_AXIS_SYSTEM
@ DTK_TYPE_AXIS_SYSTEM
Definition: define.h:34
Dtk_Node::FullType::SubType
type_detk SubType() const
Definition: dtk_maindoc.hpp:283
Dtk_Node::FullType::FullType
FullType()
Definition: dtk_maindoc.hpp:281
Dtk_DocElement::DtkDynamicCast
static Dtk_DocElement * DtkDynamicCast(Dtk_Object *s)
Performs a dynamic cast - doesn't need RTTI -.
Dtk_Component::CreateColorInfosSetNode
Dtk_NodePtr CreateColorInfosSetNode(Dtk_string inName, const Dtk_ID &inColorInfosSetID)
Creates a ColorInfosSet Dtk_NodePtr from a ColorInfosSetPtr.
Dtk_DocElement::AddProperty
void AddProperty(const Dtk_PropertiesPtr &inProperty)
Adds a Dtk_PropertiesPtr to the Dtk_DocElement.
Dtk_DocElement::AddMetaDataGroup
void AddMetaDataGroup(const Dtk_MetaDataGroupPtr &inMetaDataGroup, Dtk_bool inAddMetadata=DTK_FALSE)
Adds a Dtk_MetaDataGroupPtr to the Dtk_DocElement.
Dtk_Node::NodeHasAxis
Dtk_bool NodeHasAxis() const
Return DTK_TRUE if Dtk_Node Type Body contains axis entity.
Dtk_NodeConnector::PlacementCategory
@ PlacementCategory
Definition: dtk_maindoc.hpp:1198
Dtk_NodeConnector::SecondRefBlockSituationCategory
@ SecondRefBlockSituationCategory
Definition: dtk_maindoc.hpp:1204
Dtk_NodeConnector::SecondRefBlockSituation_2
@ SecondRefBlockSituation_2
Definition: dtk_maindoc.hpp:1116
dtk_metadata.hpp
Dtk_Component::CreateDrawingNode
Dtk_NodePtr CreateDrawingNode(Dtk_string inName, const Dtk_ID &inDrawingID)
Creates a Drawing Dtk_NodePtr from a Dtk_DrawingPtr.
Dtk_DocElement::ReleasePreview
void ReleasePreview()
Dtk_NodeID
Dtk_ID Dtk_NodeID
Definition: dtk_maindoc.hpp:88
UnknownModule
@ UnknownModule
Definition: dtk_maindoc.hpp:83
Dtk_Node::HasCurves
@ HasCurves
Definition: dtk_maindoc.hpp:238
Dtk_Node::BodyType
@ BodyType
Definition: dtk_maindoc.hpp:249
Dtk_NodeConnector::AppearanceCategory
@ AppearanceCategory
Definition: dtk_maindoc.hpp:1201
Dtk_DocElement::_GetChild
const Dtk_DocElementPtr _GetChild(const Dtk_Size_t &inPos) const
Retrieves the ith Dtk_DocElement - read only -.
Dtk_NodeConnector::GetPointingEntityType
Dtk_Node::FullType GetPointingEntityType() const
Retrieves the pointing entity FullType. Should be the FullType of the Dtk_Node containing the Dtk_Nod...
Dtk_Node::CameraType
@ CameraType
Definition: dtk_maindoc.hpp:260
F3dReaderModule
@ F3dReaderModule
Definition: dtk_maindoc.hpp:74
DTK_FALSE
#define DTK_FALSE
Definition: define.h:720
StlReaderModule
@ StlReaderModule
Definition: dtk_maindoc.hpp:67
Dtk_Node::GetDtk_CameraPtr
Dtk_CameraPtr GetDtk_CameraPtr()
Retrieves the Dtk_Node as a Dtk_CameraPtr - if exists -.
Dtk_bool
char Dtk_bool
Definition: define.h:717
ProCeraReaderModule
@ ProCeraReaderModule
Definition: dtk_maindoc.hpp:47
Dtk_DocElement::_ReplaceChild
Dtk_ErrorStatus _ReplaceChild(const Dtk_Size_t &inPos, const Dtk_DocElementPtr &inNewChild)
Replaces a child by another one. Also update father lists.
Dtk_NodeConnector::Clone
virtual Dtk_Object * Clone()
Definition: dtk_maindoc.hpp:1257
AcisReaderModule
@ AcisReaderModule
Definition: dtk_maindoc.hpp:46
Dtk_API::_Init
void _Init()
Dtk_Component::ComponentAvailability
const ComponentAvailabilityEnum ComponentAvailability() const
Gives Dtk_Component availability - read only -.
Dtk_MainDoc::DevalidateComponent
Dtk_ErrorStatus DevalidateComponent(const Dtk_ComponentID &inComponentID)
Devalidates Component into MainDoc.
Dtk_Component::ReplaceChildComponent
Dtk_ErrorStatus ReplaceChildComponent(const Dtk_Size_t &inPos, const Dtk_ComponentPtr &inNewChild)
Replaces a child Dtk_ComponentPtr by another one. Also updates father lists.
Definition: dtk_maindoc.hpp:686
DtkReaderType
DtkReaderType
Definition: dtk_maindoc.hpp:29
Dtk_NodeConnector::SetColorId
void SetColorId(Dtk_ID inColorId)
Set the Color Id for ForceColor connectors.
Dtk_Node::GetDtk_AxisSystemPtr
Dtk_AxisSystemPtr GetDtk_AxisSystemPtr()
Retrieves the Dtk_Node as a Dtk_AxisSystemPtr - if exists -.
Dtk_MainDoc
This is the Document Class. The Dtk_MainDocPtr object is used as root element produced by a translati...
Definition: dtk_maindoc.hpp:921
Dtk_Component::ComponentAvailabilityEnum
ComponentAvailabilityEnum
Definition: dtk_maindoc.hpp:558
Dtk_NodeConnector::ThirdRefBlockSituation_3
@ ThirdRefBlockSituation_3
Definition: dtk_maindoc.hpp:1124
SwReaderModule
@ SwReaderModule
Definition: dtk_maindoc.hpp:36
Dtk_Component::VirtualComponentType
@ VirtualComponentType
Definition: dtk_maindoc.hpp:572
Dtk_Node::GetChild
const Dtk_NodePtr GetChild(const Dtk_Size_t &inPos) const
Retrieves the ith Dtk_Node - read only -.
Definition: dtk_maindoc.hpp:385
Dtk_Double64
double Dtk_Double64
Definition: define.h:691
Dtk_MainDoc::CreatePrototypeDtk_Component
Dtk_ComponentPtr CreatePrototypeDtk_Component(Dtk_string inComponentFullPath, Dtk_string inComponentName, const DtkReaderType &inAssociatedModule, const Dtk_Component::ComponentAvailabilityEnum &inAvailability, const int inAdditionnalReferenceFlag=0, Dtk_string inOriginalName=Dtk_string())
Creates a Prototype Dtk_ComponentPtr. This type handles Assemblies and part components.
Dtk_Node::UnknownType
@ UnknownType
Definition: dtk_maindoc.hpp:236
Dtk_MainDoc::IsMultiModel
Dtk_bool IsMultiModel() const
Indicate that document contains several independant models.
Dtk_Component::GetOverrideSets
DtkErrorStatus GetOverrideSets(Dtk_tab< Dtk_OverrideSetPtr > &outOverrideSet) const
Gives array of Override sets in a prototype component
Dtk_Node::GetDtk_LayerInfosSetPtr
Dtk_LayerInfosSetPtr GetDtk_LayerInfosSetPtr()
Retrieves the Dtk_Node as a Dtk_LayerInfosSetPtr - if exists -.
Dtk_mesh
This is a high level mesh class.
Definition: util_mesh_dtk.hpp:485
Dtk_Component::SetSelectionDataSet
void SetSelectionDataSet(const Dtk_SelectionDataSetPtr &inSelectionDataSet)
Attaches SelectionDataSet infos to the Dtk_Component - through the Dtk_GlobalDataSetPtr -.
Dtk_Component::InstanceComponentType
@ InstanceComponentType
Definition: dtk_maindoc.hpp:569
Dtk_Component::GetDefaultChildInCatalog
Dtk_Int32 GetDefaultChildInCatalog() const
Returns Default Child Index or -1 if Component isn't a catalog.
Dtk_Node::GetAssociatedEntities
Dtk_ErrorStatus GetAssociatedEntities(Dtk_tab< Dtk_NodeConnectorPtr > &outAssociatedEntities)
Retrieves the entities associated to the Dtk_Node. They are retrieved via Dtk_NodeConnectorPtr.
Dtk_Kinematic
Dtk_Kinematic represents a kinematic.
Definition: util_kinematics_dtk.hpp:1828
util_draw_ptr_dtk.hpp
DTK_TYPE_NODE
@ DTK_TYPE_NODE
Definition: define.h:502
CgrReaderModule
@ CgrReaderModule
Definition: dtk_maindoc.hpp:44
Dtk_Component::CreateVirtualNode
Dtk_NodePtr CreateVirtualNode(Dtk_string inName, const type_detk inSubType=DTK_TYPE_NO_SUBTYPE)
Creates a Virtual Dtk_NodePtr.
Dtk_NodeConnector::_Init
void _Init()
ObjReaderModule
@ ObjReaderModule
Definition: dtk_maindoc.hpp:62
QifReaderModule
@ QifReaderModule
Definition: dtk_maindoc.hpp:78
Dtk_NodeConnector::CheckAssociatedPathComponentID
Dtk_Int32 CheckAssociatedPathComponentID(const Dtk_MainDocPtr &inMainDocPtr)
Checks if the Path Component ID exist into Dtk_MainDocPtr.
Dtk_DocElement::SetInfos
void SetInfos(const Dtk_InfoPtr &inInfos)
Dtk_Node::GetNodeType
NodeDataTypeEnum GetNodeType() const
Retrieves the Dtk_Node Node Type - read only -.
Dtk_Node::GetDtk_DrawingPtr
Dtk_DrawingPtr GetDtk_DrawingPtr()
Retrieves the Dtk_Node as a Dtk_DrawingPtr - if exists -.
Dtk_Component::ComponentType
const ComponentTypeEnum & ComponentType() const
Retrieves the Dtk_Component Type - read only -.
Dtk_NodeConnector::AssociatedGeometry
@ AssociatedGeometry
Definition: dtk_maindoc.hpp:1127
Dtk_Node::GetNodeFullType
const Dtk_Node::FullType GetNodeFullType() const
Retrieves the Node FullType - Primary ans Sub Type - - read only -.
dtk_pnt.hpp
Dtk_LayerInfosSet
This class represents a set of layer information, such as their name and identifier,...
Definition: util_ent_dtk.hpp:515
util_topology_ptr_dtk.hpp
Dtk_Node::AddAssociatedEntities
void AddAssociatedEntities(const Dtk_tab< Dtk_NodeConnectorPtr > &inAssociatedEntities)
Adds associated entities - Dtk_NodeConnectorPtr - to the Dtk_Node.
Dtk_NodeConnector::GetSubEntitiesNb
Dtk_Size_t GetSubEntitiesNb() const
Returns the number of the geometric entities.
Dtk_Component::ComponentFound
@ ComponentFound
Definition: dtk_maindoc.hpp:560
Dtk_DocElement::DtkDynamicType
Dtk_Int32 DtkDynamicType(const int &inId)
Retrieves the dynamic entity type.
DxfReaderModule
@ DxfReaderModule
Definition: dtk_maindoc.hpp:54
Dtk_Component::ComponentAssemblyGeometry
@ ComponentAssemblyGeometry
Definition: dtk_maindoc.hpp:564
Dtk_Component::GetConceptionUnitScale
Dtk_ErrorStatus GetConceptionUnitScale(Dtk_Double64 &outUnitScale) const
Get the Original Units for documents - geometrical data are given in MM (Scale to MM) /!
Dtk_NodeConnector::~Dtk_NodeConnector
~Dtk_NodeConnector()
Destructor.
U3dReaderModule
@ U3dReaderModule
Definition: dtk_maindoc.hpp:57
Dtk_DocElement::Name
const Dtk_string & Name() const
Retrieves the Dtk_DocElement Name - read only -.
Dtk_NodeConnector::DtkDynamicType
Dtk_Int32 DtkDynamicType(const Dtk_Int32 &inId)
Retrieves the dynamic entity type.
Dtk_Component::GetFileVersion
const Dtk_string & GetFileVersion() const
Gets File Version.
Dtk_NodeConnector::Create
static Dtk_NodeConnectorPtr Create()
Calls default constructor to allocate a new object.
Dtk_Component::IsAssembly
Dtk_bool IsAssembly() const
Returns DTK_TRUE if Dtk_Component is an assembly.
IgesReaderModule
@ IgesReaderModule
Definition: dtk_maindoc.hpp:38
Dtk_NodeConnector::ReasonCategoryEnum
ReasonCategoryEnum
Reason Category. Global Category of the NodeConnector uesed to gather Reason into families.
Definition: dtk_maindoc.hpp:1196
Dtk_Component::GetLayerInfosSet
Dtk_LayerInfosSetPtr GetLayerInfosSet() const
Retrieves the Dtk_LayerInfosSet of this component.
Dtk_MainDoc::CreateCatalogDtk_Component
Dtk_ComponentPtr CreateCatalogDtk_Component(Dtk_string inComponentFullPath, Dtk_string inComponentName, Dtk_string inInstanceName, const Dtk_transfo &inTransformationMatrix, const DtkReaderType &inAssociatedModule=UnknownModule, const Dtk_Component::ComponentAvailabilityEnum &inAvailability=Dtk_Component::ComponentInternal, Dtk_string inOriginalName=Dtk_string())
Creates a Catalog Dtk_ComponentPtr.
Dtk_NodeConnector::AssociatedCenterPoint
@ AssociatedCenterPoint
Definition: dtk_maindoc.hpp:1137
Dtk_NodeConnector::AddSubEntity
Dtk_ErrorStatus AddSubEntity(const SubEntity &inSubEntity)
Add a SubEntity - defined by their IDs and Types - to the SubEntities list.
dtk_override_ptr.hpp
_3dXmlReaderModule
@ _3dXmlReaderModule
Definition: dtk_maindoc.hpp:51
Dtk_Node::MaxNodeDataType
@ MaxNodeDataType
Definition: dtk_maindoc.hpp:263
Dtk_Node::HasPoints
@ HasPoints
Definition: dtk_maindoc.hpp:237
Dtk_Component::ComponentAdditionnalReference
@ ComponentAdditionnalReference
Definition: dtk_maindoc.hpp:563
Dtk_NodeConnector::StackedRight
@ StackedRight
Definition: dtk_maindoc.hpp:1093
DTK_TYPE_METADATA
@ DTK_TYPE_METADATA
Definition: define.h:507
V6ReaderModule
@ V6ReaderModule
Definition: dtk_maindoc.hpp:53
Dtk_NodeConnector::SetSubEntities
Dtk_ErrorStatus SetSubEntities(const Dtk_tab< Dtk_ID > &inEntitiesIDs, const Dtk_tab< type_detk > &inEntitiesTypes)
Returns the set of Additional Entities defined by their IDs and Types.
Dtk_Component::DevalidateNode
Dtk_ErrorStatus DevalidateNode(const Dtk_NodeID &inNodeID)
Devalidates Component into MainDoc.
SeReaderModule
@ SeReaderModule
Definition: dtk_maindoc.hpp:37
Dtk_Component::AddOverrideSet
DtkErrorStatus AddOverrideSet(const Dtk_OverrideSetPtr &inOverrideSet)
Adds Override set to a prototype component
Dtk_FeaturePtr
Dtk_SmartPtr< Dtk_feat > Dtk_FeaturePtr
Definition: dtk_maindoc.hpp:22
Dtk_Component::TransformationMatrix
const Dtk_transfo & TransformationMatrix() const
Retrieves the Dtk_Component TransformationMatrix - read only -.
Dtk_API::_Reset
void _Reset()
Dtk_MeshPtr
Dtk_SmartPtr< Dtk_mesh > Dtk_MeshPtr
Definition: dtk_maindoc.hpp:20
Dtk_Component::ComponentWithUnavailableReader
@ ComponentWithUnavailableReader
Definition: dtk_maindoc.hpp:565
DcmReaderModule
@ DcmReaderModule
Definition: dtk_maindoc.hpp:50
MaxReaderModules
@ MaxReaderModules
Definition: dtk_maindoc.hpp:84
Dtk_Component::SetFileVersion
void SetFileVersion(const Dtk_string &inFileVersion)
util_ent_dtk.hpp
Dtk_Node
This is the Node Class.
Definition: dtk_maindoc.hpp:231
Dtk_Node::GetStoredInfos
Dtk_StoredInfoPtr GetStoredInfos() const
Dtk_DocElement::AddMetaData
void AddMetaData(const Dtk_MetaDataPtr &inMetaData)
Adds a Dtk_MetaDataPtr to the Dtk_DocElement.
Dtk_NodeConnector::ThirdRefBlockSituation_2
@ ThirdRefBlockSituation_2
Definition: dtk_maindoc.hpp:1123
DTK_TYPE_BODY
@ DTK_TYPE_BODY
Definition: define.h:481
RevitReaderModule
@ RevitReaderModule
Definition: dtk_maindoc.hpp:65
Dtk_NodeConnector::ReasonLinkEnumToString
static Dtk_string ReasonLinkEnumToString(const ReasonLinkEnum &inEnum)
Definition: dtk_maindoc.hpp:1142
Dtk_Int32
int32_t Dtk_Int32
Definition: define.h:679
Dtk_Node::FullType
This is the Node FullType Class The Dtk_Node::FullType object is used to retrieve the full informatio...
Definition: dtk_maindoc.hpp:270
ArtReaderModule
@ ArtReaderModule
Definition: dtk_maindoc.hpp:71
Dtk_Component::ComponentAvailabilityEnumToString
static Dtk_string ComponentAvailabilityEnumToString(const ComponentAvailabilityEnum &inEnum)
Definition: dtk_maindoc.hpp:576
Dtk_Node::MetaDataType
@ MetaDataType
Definition: dtk_maindoc.hpp:258
dtk_maindoc_ptr.hpp
Dtk_Node::NullType
@ NullType
Definition: dtk_maindoc.hpp:248
Dtk_NodeConnector::ForceRender
@ ForceRender
Definition: dtk_maindoc.hpp:1101
Dtk_NodeConnector::Context
@ Context
Definition: dtk_maindoc.hpp:1139
Dtk_Node::GetDtk_ConstraintPtr
Dtk_ConstraintPtr GetDtk_ConstraintPtr()
Retrieves the Dtk_Node as a Dtk_ConstraintPtr - if exists -.
V4ReaderModule
@ V4ReaderModule
Definition: dtk_maindoc.hpp:33
Dtk_Component::ComponentTypeEnum
ComponentTypeEnum
Definition: dtk_maindoc.hpp:568
Dtk_Component::GetSiblingName
DtkErrorStatus GetSiblingName(Dtk_string &outSiblingName) const
SiblingName for Component.
Dtk_MainDoc::CreateInstanceDtk_Component
Dtk_ComponentPtr CreateInstanceDtk_Component(const Dtk_ComponentPtr &inPrototype, Dtk_string inInstanceName, const Dtk_transfo &inTransformationMatrix)
Creates a physical Dtk_ComponentPtr.
Dtk_Component::ComponentTypeEnumToString
static Dtk_string ComponentTypeEnumToString(const ComponentTypeEnum &inEnum)
Definition: dtk_maindoc.hpp:592
Dtk_Node::ConstraintType
@ ConstraintType
Definition: dtk_maindoc.hpp:262
Dtk_DocElement::GetInfos
Dtk_InfoPtr GetInfos() const
Retrieves the Dtk_DocElement Dtk_InfoPtr - read only -.
Dtk_Component::CreateFdtNode
Dtk_NodePtr CreateFdtNode(Dtk_string inName, const Dtk_ID &inFdtID, const type_detk inSubType=DTK_TYPE_FDT)
Creates a Fdt Dtk_NodePtr from a Dtk_FdtPtr ID.
Dtk_NodeConnector::ForceClipped
@ ForceClipped
Definition: dtk_maindoc.hpp:1102
StepReaderModule
@ StepReaderModule
Definition: dtk_maindoc.hpp:39
Dtk_DocElement::SetMaterial
void SetMaterial(Dtk_MaterialPtr inMaterial)
DstvReaderModule
@ DstvReaderModule
Definition: dtk_maindoc.hpp:75
Dtk_SmartPtr::DtkDynamicCast
static Dtk_SmartPtr< T > DtkDynamicCast(const Dtk_SmartPtr< T2 > &p)
Definition: util_ptr_dtk.hpp:101
Dtk_Node::DtkDynamicCast
static Dtk_Node * DtkDynamicCast(Dtk_Object *s)
Performs a dynamic cast - doesn't need RTTI -.
Dtk_NodeConnector::GetAssociatedComponentID
Dtk_ID GetAssociatedComponentID() const
Returns the Component ID referenced by the connector.
error_dtk.hpp
Dtk_NodeConnector::HorizontallyAligned
@ HorizontallyAligned
Definition: dtk_maindoc.hpp:1091
Dtk_Node::AddChild
void AddChild(const Dtk_NodePtr &inChild)
Adds a child Dtk_Node to main Node.
Definition: dtk_maindoc.hpp:379
Dtk_ErrorStatus
Dtk_ErrorStatus
Definition: error_dtk.hpp:6
Dtk_DocElement::GetNumChildren
Dtk_Size_t GetNumChildren() const
Retrieves the number of the Dtk_DocElement children - read only -.
Dtk_Node::SetStoredInfos
void SetStoredInfos(const Dtk_StoredInfoPtr &inInfos)
SdnfReaderModule
@ SdnfReaderModule
Definition: dtk_maindoc.hpp:70
Dtk_NodeConnector::FirstRefBlockSituationCategory
@ FirstRefBlockSituationCategory
Definition: dtk_maindoc.hpp:1203
Dtk_NodeConnector::GetPointedEntityType
type_detk GetPointedEntityType() const
Retrieves the pointed entity Type.
Dtk_NodeConnector::GetAssociatedPathComponentID
void GetAssociatedPathComponentID(Dtk_tab< Dtk_ID > &outAssociatedPathComponentID) const
DTK_TYPE_FDT
@ DTK_TYPE_FDT
Definition: define.h:424
Dtk_NodeConnector::ThirdRefBlockSituationCategory
@ ThirdRefBlockSituationCategory
Definition: dtk_maindoc.hpp:1205
Dtk_Node::LayerInfosSetType
@ LayerInfosSetType
Definition: dtk_maindoc.hpp:256
Dtk_SmartPtr
Definition: util_ptr_dtk.hpp:37
Dtk_Node::AddAssociatedEntity
void AddAssociatedEntity(const Dtk_NodeConnectorPtr &inAssociatedEntity)
Retrieves the Dtk_Node as a Dtk_KinematicsPtr - if exists -.
Dtk_Component::GetAssociatedModuleType
const DtkReaderType & GetAssociatedModuleType() const
Retrieves the Dtk_Component AssociatedModuleType - read only -.
Dtk_NodeConnector::SetReasonLink
void SetReasonLink(const ReasonLinkEnum inReasonLink)
Sets the Reason Link of the Dtk_NodeConnector to specify the reason of the connection.
Dtk_Component::ComponentInternal
@ ComponentInternal
Definition: dtk_maindoc.hpp:561
Dtk_NodeConnector::ReasonCategoryEnumToString
static Dtk_string ReasonCategoryEnumToString(const ReasonCategoryEnum &inEnum)
Definition: dtk_maindoc.hpp:1207
VdaReaderModule
@ VdaReaderModule
Definition: dtk_maindoc.hpp:31
Dtk_Component::CreateMetaDataNode
Dtk_NodePtr CreateMetaDataNode(Dtk_string inName, const Dtk_ID &inMetaDataID, const type_detk inSubType=DTK_TYPE_METADATA)
Creates a MetaData Dtk_NodePtr from a Dtk_MetaDataPtr.
Dtk_Node::NodeHasCurves
Dtk_bool NodeHasCurves() const
Return DTK_TRUE if Dtk_Node Type Body or Mesh contains curves entity.
Dtk_Component::CreateBodyNode
Dtk_NodePtr CreateBodyNode(Dtk_string inName, const Dtk_ID &inBodyID, const Dtk_Int32 inBodyFlag, const type_detk inSubType=DTK_TYPE_BODY)
Creates a Body Dtk_NodePtr from a body ID.
Dtk_DocElement::GetID
Dtk_ID GetID() const
Retrieves the Dtk_DocElement ID - read only -.
Dtk_Node::GetDtk_MetaDataPtr
Dtk_MetaDataPtr GetDtk_MetaDataPtr()
Retrieves the Dtk_Node as a Dtk_MetaDataPtr - if exists -.
DTK_TYPE_DOCUMENT
@ DTK_TYPE_DOCUMENT
Definition: define.h:500
Dtk_DocElement::SetPreview
void SetPreview(Dtk_PreviewPtr inPreview)
Dtk_NodeConnector::Dtk_NodeConnector
Dtk_NodeConnector()
Default constructor.
Dtk_MainDoc::SetRootComponent
void SetRootComponent(const Dtk_ComponentPtr &inRootComponent)
Set the root Dtk_ComponentPtr.
Dtk_NodeConnector::SetAssociatedComponentID
void SetAssociatedComponentID(const Dtk_ID &inComponentID)
Sets the component ID.
dtk_transfo.hpp
Dtk_pnt
This is a mathematical point class.
Definition: dtk_pnt.hpp:20
Dtk_Component::InstanceName
const Dtk_string & InstanceName() const
Retrieves the Dtk_Component InstanceName - read only -.
type_detk
type_detk
Definition: define.h:21
Dtk_Component::ComponentPhantom
@ ComponentPhantom
Definition: dtk_maindoc.hpp:562
Dtk_DocElement::GetMetaDataGroup
Dtk_MetaDataGroupPtr GetMetaDataGroup(const Dtk_Size_t &inPos) const
Retrieves the ith Dtk_MetaDataGrouplPtr - read only -.
Dtk_NodeConnector::ForceVisible
@ ForceVisible
Definition: dtk_maindoc.hpp:1099
Dtk_MainDoc::GetNumComponents
Dtk_Size_t GetNumComponents() const
Give number of Components in the Dtk_MainDoc (useful if you want to handle progress bar).
Dtk_Component::SetConceptionUnitScale
void SetConceptionUnitScale(Dtk_Double64 inUnitScale)
Dtk_DocElement::GetMaterial
Dtk_MaterialPtr GetMaterial() const
Retrieves the Dtk_DocElement Dtk_MaterialPtr - read only -.
Dtk_Component::GetNumOverrideSets
Dtk_Size_t GetNumOverrideSets() const
Gives number of Override sets in a prototype component
Dtk_Component::FullPathName
const Dtk_string & FullPathName() const
Retrieves the Dtk_Component FullPathName - read only -.
Dtk_NodeConnector::PositionallyFixed
@ PositionallyFixed
Definition: dtk_maindoc.hpp:1096
Dtk_Component::GetFatherNode
Dtk_NodePtr GetFatherNode(const Dtk_NodePtr &inNode) const
Retrieves the father Dtk_NodePtr of the given Dtk_NodePtr.
Dtk_NodeConnector::get_type_detk
type_detk get_type_detk() const
Definition: dtk_maindoc.hpp:1279
util_stl_dtk.hpp
Dtk_NodeConnector::HighlightedGeometry
@ HighlightedGeometry
Definition: dtk_maindoc.hpp:1131
Dtk_DocElement::SetReadID
void SetReadID(const Dtk_ID &inNewID)
Dtk_Node::ReplaceChildNode
Dtk_ErrorStatus ReplaceChildNode(const Dtk_Size_t &inPos, const Dtk_NodePtr &inNewChild)
Replaces a child Dtk_NodePtr by another one. Also updates father lists.
Definition: dtk_maindoc.hpp:395
Dtk_Node::_typeID
@ _typeID
Definition: dtk_maindoc.hpp:347
Dtk_NodeConnector::SubEntity::SubEntity
SubEntity(const Dtk_ID inSubEntityID, const type_detk inSubEntityType)
Definition: dtk_maindoc.hpp:1229
Dtk_NodeConnector::SetSubEntities
Dtk_ErrorStatus SetSubEntities(const Dtk_tab< SubEntity > &inSubEntities)
Sets of SubEntities - defined by their IDs and Types -.
Dtk_Node::NodeDataTypeEnumToString
static Dtk_string NodeDataTypeEnumToString(const NodeDataTypeEnum &inEnum)
Definition: dtk_maindoc.hpp:287
Dtk_Node::GetDtk_MeshPtr
Dtk_MeshPtr GetDtk_MeshPtr()
Retrieves the Dtk_Node as a Dtk_meshPtr - if exists -.
util_ptr_dtk.hpp
Dtk_Component::SetAsDeprecated
SetAsDeprecated("2022.1", "Use Dtk_Component::GetConceptionUnitScale(Dtk_Double64 &outUnitScale) method instead.") Dtk_Double64 GetConceptionUnitScale() const
Gets the Original Units for documents.
define.h
Dtk_MainDoc::_ReleaseNodeConnectors
void _ReleaseNodeConnectors()
Dtk_Component::DtkDynamicCast
static Dtk_Component * DtkDynamicCast(Dtk_Object *s)
Performs a dynamic cast - doesn't need RTTI -.
DTK_TYPE_COMPONENT
@ DTK_TYPE_COMPONENT
Definition: define.h:503
Dtk_NodeConnector::GetRenderId
Dtk_ID GetRenderId() const
Retrieves the Render Id for ForceRender connectors.
Dtk_Component::SetComponentAvailability
Dtk_ErrorStatus SetComponentAvailability(const ComponentAvailabilityEnum &inComponentAvailability)
Dtk_NodeConnector::SubEntity::SubEntity
SubEntity()
Definition: dtk_maindoc.hpp:1228
Dtk_NodeConnector::VisibilityCategory
@ VisibilityCategory
Definition: dtk_maindoc.hpp:1200
Dtk_MainDoc::DtkDynamicType
Dtk_Int32 DtkDynamicType(const int &inId)
Retrieves the dynamic entity type.
Dtk_Node::NodeDataStringToEnumType
static Dtk_Int32 NodeDataStringToEnumType(const Dtk_string &type)
Definition: dtk_maindoc.hpp:310
Dtk_tab< Dtk_NodeConnectorPtr >
Dtk_Component::GetNodeByID
Dtk_NodePtr GetNodeByID(const Dtk_NodeID &inNodeID) const
Retrieves a Dtk_NodePtr from the Dtk_Component NodesPool giving his Id.
DwgDtkReaderModule
@ DwgDtkReaderModule
Definition: dtk_maindoc.hpp:79
Dtk_Node::GetDtk_AdvancedFeaturePtr
Dtk_ObjectPtr GetDtk_AdvancedFeaturePtr()
Retrieves the Dtk_Node as a Dtk_AdvancedFeaturePtr - if exists - Internal Use !!!
Dtk_Node::GetDtk_FdtPtr
Dtk_FdtPtr GetDtk_FdtPtr()
Retrieves the Dtk_Node as a Dtk_FdtPtr - if exists -.
Dtk_DocElement::GetNumMetaData
Dtk_Size_t GetNumMetaData() const
Retrieves the number of the Dtk_MetaDataPtr - read only -.
DTK_TYPE_CONSTRAINT
@ DTK_TYPE_CONSTRAINT
Definition: define.h:599
Dtk_DocElement::GetReadID
void GetReadID(Dtk_ID &outReadID) const
Dtk_NodeConnector::DefaultAnnotationLink
@ DefaultAnnotationLink
Definition: dtk_maindoc.hpp:1130
Dtk_Component::GetGlobalDataSet
const Dtk_GlobalDataSetPtr GetGlobalDataSet() const
Retrieves the Dtk_GlobalDataSetPtr attached to the Dtk_Component - get only -.
CgmReaderModule
@ CgmReaderModule
Definition: dtk_maindoc.hpp:69
Dtk_NodeConnector::GetReasonLink
Dtk_NodeConnector::ReasonLinkEnum GetReasonLink(ReasonCategoryEnum &outReasonCategory) const
Gets the Reason Link of the Dtk_NodeConnector to specify the reason of the connection.
FbxReaderModule
@ FbxReaderModule
Definition: dtk_maindoc.hpp:68
Dtk_NodeConnector::GetNodeId
Dtk_ID GetNodeId() const
Returns the Node id referenced by the connector.
Dtk_MainDoc::DtkDynamicCast
static Dtk_MainDoc * DtkDynamicCast(Dtk_Object *s)
Performs a dynamic cast - doesn't need RTTI -.
Dtk_NodeConnector::SecondRefBlockSituation_Common
@ SecondRefBlockSituation_Common
Definition: dtk_maindoc.hpp:1114
SmgReaderModule
@ SmgReaderModule
Definition: dtk_maindoc.hpp:72
Dtk_NodeConnector::SecondRefBlockSituation_3
@ SecondRefBlockSituation_3
Definition: dtk_maindoc.hpp:1117
IfcReaderModule
@ IfcReaderModule
Definition: dtk_maindoc.hpp:63
DTK_TYPE_NO_SUBTYPE
@ DTK_TYPE_NO_SUBTYPE
Definition: define.h:532
Dtk_Component::GetBoundingBox
Dtk_ErrorStatus GetBoundingBox(Dtk_pnt &outMin, Dtk_pnt &outMax)
Gets BoundingBox on Prototype Component if it can be read in original file.
Dtk_NodeConnector::GeneralAssociationCategory
@ GeneralAssociationCategory
Definition: dtk_maindoc.hpp:1199
Dtk_Node::GetDtk_ColorInfosSetPtr
Dtk_ColorInfosSetPtr GetDtk_ColorInfosSetPtr()
Retrieves the Dtk_Node as a Dtk_ColorInfosSetPtr - if exists -.
Dtk_Component::PrototypeComponentType
@ PrototypeComponentType
Definition: dtk_maindoc.hpp:570
Dtk_Node::GetDtk_FeaturePtr
Dtk_FeaturePtr GetDtk_FeaturePtr()
Retrieves the Dtk_Node as a Dtk_FeaturePtr - if exists -.
Dtk_NodeConnector::FirstRefBlockSituation_Common
@ FirstRefBlockSituation_Common
Definition: dtk_maindoc.hpp:1107
Dtk_DocElement
This is the Main Doc Element Class The Dtk_DocElement object is common parent class of the Dtk_Node a...
Definition: dtk_maindoc.hpp:102
Dtk_Node::ColorInfosSetType
@ ColorInfosSetType
Definition: dtk_maindoc.hpp:257
XmtReaderModule
@ XmtReaderModule
Definition: dtk_maindoc.hpp:35
Dtk_DocElement::GetNumMetaDataGroup
Dtk_Size_t GetNumMetaDataGroup() const
Retrieves the number of the Dtk_MetaDataGroupPtr - read only -.
Dtk_Component::ComponentMissing
@ ComponentMissing
Definition: dtk_maindoc.hpp:559
Dtk_string::len
int len() const
Retrieve the length of the Dtk_string.
Dtk_NodeConnector::FirstRefBlockSituation_1
@ FirstRefBlockSituation_1
Definition: dtk_maindoc.hpp:1108
Dtk_Object
Definition: dtk_object.hpp:8
Dtk_Component
This is the Component Class. The Dtk_ComponentPtr object is used as element into an assembly tree....
Definition: dtk_maindoc.hpp:555
Dtk_NodeConnector::SetAssociatedPathComponentID
void SetAssociatedPathComponentID(const Dtk_tab< Dtk_ID > &inPathComponentID)
Sets the Path Component ID from Root to Target.
Dtk_DocElement::_AddChild
void _AddChild(const Dtk_DocElementPtr &inChild)
Adds a child Dtk_DocElement to main Element.
dtk_string.hpp
InvReaderModule
@ InvReaderModule
Definition: dtk_maindoc.hpp:32
Dtk_Component::GetNumNodes
Dtk_Size_t GetNumNodes() const
Gives number of Nodes in the Component (useful if you want to handle progress bar).
Dtk_NodeConnector::SubEntity::operator==
friend Dtk_bool operator==(const SubEntity &, const SubEntity &)
Dtk_MainDoc::Create
static Dtk_MainDocPtr Create()
Calls default constructor to allocate a new object.
Dtk_ComponentID
Dtk_ID Dtk_ComponentID
Definition: dtk_maindoc.hpp:87
Dtk_NodeConnector::SubEntity::GetSubEntityType
type_detk GetSubEntityType() const
Definition: dtk_maindoc.hpp:1234
Dtk_MainDoc::GetNumFatherComponent
Dtk_Size_t GetNumFatherComponent(const Dtk_ComponentPtr &inComponent)
Retrieves the inIndexth father of the giving Dtk_ComponentPtr.
JtReaderModule
@ JtReaderModule
Definition: dtk_maindoc.hpp:43
Dtk_NodeConnector::AssociatedZDirection
@ AssociatedZDirection
Definition: dtk_maindoc.hpp:1136
Dtk_NodeConnector::StackedLeft
@ StackedLeft
Definition: dtk_maindoc.hpp:1092
Dtk_Component::OriginalPathName
const Dtk_string & OriginalPathName() const
Retrieves the Dtk_Component OriginalPathName (read in file) - read only -.
Dtk_MainDoc::CreateVirtualDtk_Component
Dtk_ComponentPtr CreateVirtualDtk_Component(Dtk_string inComponentName, const DtkReaderType &inAssociatedModule, Dtk_string inComponentFullPath, const Dtk_Component::ComponentAvailabilityEnum &inAvailability)
Creates a virtual Dtk_ComponentPtr.
Dtk_Node::HasMesh
@ HasMesh
Definition: dtk_maindoc.hpp:242
catiav5w::inInstanceName
const Dtk_string & inInstanceName
Definition: catiav5w.hpp:621
CreoviewReaderModule
@ CreoviewReaderModule
Definition: dtk_maindoc.hpp:66
Dtk_Component::_ReleaseVolatileData
void _ReleaseVolatileData()
Dtk_Node::VirtualType
@ VirtualType
Definition: dtk_maindoc.hpp:261
PdfReaderModule
@ PdfReaderModule
Definition: dtk_maindoc.hpp:58
Dtk_NodeConnector::AssociatedXDirection
@ AssociatedXDirection
Definition: dtk_maindoc.hpp:1134
Dtk_DocElement::_Init
void _Init()
Dtk_NodeConnector::GetSubEntities
Dtk_ErrorStatus GetSubEntities(Dtk_tab< SubEntity > &outSubEntities) const
Retrieves the SubEntities array - defined by their IDs and Types -.
Dtk_Node::DrawingType
@ DrawingType
Definition: dtk_maindoc.hpp:253
Dtk_Node::GetEntityID
Dtk_NodeID GetEntityID() const
Retrieves the Dtk_Node EntityID - read only -.
Dtk_Node::NodeHasSurfaces
Dtk_bool NodeHasSurfaces() const
Return DTK_TRUE if Dtk_Node Type Body contains surfacic entity.
GltfReaderModule
@ GltfReaderModule
Definition: dtk_maindoc.hpp:76
Dtk_Node::NodeHasMesh
Dtk_bool NodeHasMesh() const
Return DTK_TRUE if Dtk_Node Type Body or Mesh contains mesh entity.
Dtk_NodeConnector::OrientationallyFixed
@ OrientationallyFixed
Definition: dtk_maindoc.hpp:1097
Dtk_DocElement::Name
Dtk_string & Name()
Dtk_NodeConnector::SecondRefBlockSituation_1
@ SecondRefBlockSituation_1
Definition: dtk_maindoc.hpp:1115
Dtk_Component::GetConnectorsPointingToThisComponent
Dtk_ErrorStatus GetConnectorsPointingToThisComponent(Dtk_tab< Dtk_NodeConnectorPtr > &outConnectedEntities)
Retrieves the connectors pointing on this component.
Dtk_Component::Dtk_MainDoc
friend class Dtk_MainDoc
Definition: dtk_maindoc.hpp:628
Dtk_Node::AxisSystemType
@ AxisSystemType
Definition: dtk_maindoc.hpp:255
Dtk_Node::DtkDynamicType
Dtk_Int32 DtkDynamicType(const int &inId)
Retrieves the dynamic entity type.
Dtk_NodeConnector::FirstRefBlockSituation_2
@ FirstRefBlockSituation_2
Definition: dtk_maindoc.hpp:1109
Dtk_NodeConnector::SubEntity::~SubEntity
~SubEntity()
Definition: dtk_maindoc.hpp:1231
Dtk_NodeConnector::AddSubEntities
Dtk_ErrorStatus AddSubEntities(const Dtk_tab< SubEntity > &inSubEntities)
Add a set of SubEntities - defined by their IDs and Types - to the SubEntities list.
Dtk_Node::GetNodeSubType
type_detk GetNodeSubType() const
Retrieves the Node SubType - if relevant - - read only -.
Dtk_NodeConnector::SubPMI
@ SubPMI
Definition: dtk_maindoc.hpp:1129
Dtk_NodeConnector::DtkDynamicCast
static Dtk_NodeConnector * DtkDynamicCast(Dtk_Object *s)
Performs a dynamic cast - doesn't need RTTI -.
Dtk_NodeConnector::AssociatedFeature
@ AssociatedFeature
Definition: dtk_maindoc.hpp:1128
Dtk_MainDoc::GetNumInstances
Dtk_Int32 GetNumInstances() const
Give number of InstanceComponents in the Dtk_MainDoc.
Dtk_DocElement::GetPreview
Dtk_PreviewPtr GetPreview() const
Retrieves the Dtk_DocElement Dtk_PreviewPtr - read only -.
Dtk_Component::ComponentTypeStringToInt
static Dtk_Int32 ComponentTypeStringToInt(const Dtk_string &name)
Definition: dtk_maindoc.hpp:605
BRepOccReaderModule
@ BRepOccReaderModule
Definition: dtk_maindoc.hpp:64
Dtk_Node::MeshType
@ MeshType
Definition: dtk_maindoc.hpp:250
Dtk_Node::GetDtk_BodyPtr
Dtk_BodyPtr GetDtk_BodyPtr()
Retrieves the Dtk_Node as a Dtk_BodyPtr - if exists -.
dtk_object.hpp
Dtk_MainDoc::GetAdditionalReferenceList
Dtk_ErrorStatus GetAdditionalReferenceList(Dtk_tab< Dtk_string > &outFileList) const
return list of additional reference files into MainDoc.
Dtk_API
Definition: dtk_api.hpp:75
Dtk_MainDoc::GetMissingComponentList
Dtk_ErrorStatus GetMissingComponentList(Dtk_tab< Dtk_string > &outFileList) const
return list of missing files into MainDoc.
ProeReaderModule
@ ProeReaderModule
Definition: dtk_maindoc.hpp:41
Dtk_Component::_Private
Dtk_Handle * _Private
Definition: dtk_maindoc.hpp:626
UgReaderModule
@ UgReaderModule
Definition: dtk_maindoc.hpp:34
Lava3mReaderModule
@ Lava3mReaderModule
Definition: dtk_maindoc.hpp:56
DwgReaderModule
@ DwgReaderModule
Definition: dtk_maindoc.hpp:61
Dtk_NodeConnector::GetAssociatedPathComponentID
const Dtk_tab< Dtk_ID > & GetAssociatedPathComponentID() const
Returns the Path Component ID referenced by the connector from Root to Target.
Dtk_Component::_ReleaseNodes
void _ReleaseNodes()
Dtk_NodeConnector::SubEntity::GetSubEntityId
Dtk_ID GetSubEntityId() const
Definition: dtk_maindoc.hpp:1233
Dtk_MainDoc::RootComponent
const Dtk_ComponentPtr & RootComponent() const
Retrieves the root Dtk_ComponentPtr of the Dtk_MainDoc.