For all issues regarding the Forums use, please, refer to the Forum Rules.

Our Solutions

Need professional assistance?
Consider our:

Support Offerings

 

Need to speed up your development?
Have a look at our:

Samples & Tools

 

Need some functionality extending standard OCCT capabilities?
Check out our:

Adv. Components

Related pages

Templates and Containers ??

Omar Msaaf's picture
Forums: 

Hello, I was just wondering why Cas.Cade doesn't offer Template Classes and Containers such as Lists, Maps, etc.. I know that with some little work we can take the data structure of Top_Tools and we can manage to make our own data structure. But this is not true all the time. For example i tried creating a TopTools_Array of a Class that inherits from MFC CObject. It didn't work.

There is no complaint just a question to know how Cas.Cade's architecture was thought. This could help people use it better this way i think Best regards Omar Msaaf

Arnaud Magnier's picture

Open CASCADE delivers template classes in the TCollection package. As an exemple, you will find the templates of :

- Arrays (1 and 2 dimension),

- Stack, Queue,

- List, Sequence, Set,

- Map, DataMap, DoubleMap, IndexedMap, IndexedDataMap.

Moreover, some packages contains classes instanciating these templates, such as :

- TColStd for basic types (real, integer, boolean, etc.),

- TColgp for basic geometries defined in the gp package,

- TColGeom for 3D geometries defined in the Geom package,

- TColGeom2d for 2D geometries defined in the Geom2d package,

- TopTools for topologies defined in the TopoDS package,

- etc.

Regards,

Arnaud.

Contact us

Attention: DO NOT use this form for all kind of request for the removal of your personal data. Please follow this link for such cases.