Salome HOME
NRI : Change lGeometryClient by lGEOMClient.
[modules/smesh.git] / src / SMDS / SMDS_MeshGroup.hxx
1 // File generated by CPPExt (Transient)
2 //
3 //                     Copyright (C) 1991,1995 by
4 //  
5 //                      MATRA DATAVISION, FRANCE
6 //  
7 // This software is furnished in accordance with the terms and conditions
8 // of the contract and with the inclusion of the above copyright notice.
9 // This software or any other copy thereof may not be provided or otherwise
10 // be made available to any other person. No title to an ownership of the
11 // software is hereby transferred.
12 //  
13 // At the termination of the contract, the software and all copies of this
14 // software must be deleted.
15 //
16 #ifndef _SMDS_MeshGroup_HeaderFile
17 #define _SMDS_MeshGroup_HeaderFile
18
19 #ifndef _Standard_HeaderFile
20 #include <Standard.hxx>
21 #endif
22 #ifndef _Handle_SMDS_MeshGroup_HeaderFile
23 #include "Handle_SMDS_MeshGroup.hxx"
24 #endif
25
26 #ifndef _Handle_SMDS_Mesh_HeaderFile
27 #include "Handle_SMDS_Mesh.hxx"
28 #endif
29 #ifndef _SMDSAbs_ElementType_HeaderFile
30 #include "SMDSAbs_ElementType.hxx"
31 #endif
32 #ifndef _SMDS_MapOfMeshElement_HeaderFile
33 #include "SMDS_MapOfMeshElement.hxx"
34 #endif
35 #ifndef _Handle_SMDS_MeshGroup_HeaderFile
36 #include "Handle_SMDS_MeshGroup.hxx"
37 #endif
38 #ifndef _SMDS_ListOfMeshGroup_HeaderFile
39 #include "SMDS_ListOfMeshGroup.hxx"
40 #endif
41 #ifndef _SMDS_MeshObject_HeaderFile
42 #include "SMDS_MeshObject.hxx"
43 #endif
44 #ifndef _Standard_Boolean_HeaderFile
45 #include <Standard_Boolean.hxx>
46 #endif
47 #ifndef _Handle_SMDS_MeshElement_HeaderFile
48 #include "Handle_SMDS_MeshElement.hxx"
49 #endif
50 #ifndef _Standard_Integer_HeaderFile
51 #include <Standard_Integer.hxx>
52 #endif
53 class SMDS_Mesh;
54 class Standard_NoSuchObject;
55 class Standard_TypeMismatch;
56 class SMDS_MeshElement;
57 class SMDS_MapOfMeshElement;
58
59
60 class SMDS_MeshGroup : public SMDS_MeshObject {
61
62 public:
63
64     inline void* operator new(size_t,void* anAddress) 
65       {
66         return anAddress;
67       }
68     inline void* operator new(size_t size) 
69       { 
70         return Standard::Allocate(size); 
71       }
72     inline void  operator delete(void *anAddress) 
73       { 
74         if (anAddress) Standard::Free((Standard_Address&)anAddress); 
75       }
76 //    inline void  operator delete(void *anAddress, size_t size) 
77 //      { 
78 //        if (anAddress) Standard::Free((Standard_Address&)anAddress,size); 
79 //      }
80  // Methods PUBLIC
81  // 
82 Standard_EXPORT SMDS_MeshGroup(const Handle(SMDS_Mesh)& aMesh);
83 Standard_EXPORT   Handle_SMDS_MeshGroup AddSubGroup() ;
84 Standard_EXPORT virtual  Standard_Boolean RemoveSubGroup(const Handle(SMDS_MeshGroup)& aGroup) ;
85 Standard_EXPORT virtual  Standard_Boolean RemoveFromParent() ;
86 Standard_EXPORT   void Clear() ;
87 Standard_EXPORT   void Add(const Handle(SMDS_MeshElement)& ME) ;
88 Standard_EXPORT   void Remove(const Handle(SMDS_MeshElement)& ME) ;
89 Standard_EXPORT   Standard_Boolean IsEmpty() const;
90 Standard_EXPORT   Standard_Integer Extent() const;
91 Standard_EXPORT   SMDSAbs_ElementType Type() const;
92 Standard_EXPORT   Standard_Boolean Contains(const Handle(SMDS_MeshElement)& ME) const;
93 Standard_EXPORT inline  const SMDS_MapOfMeshElement& Elements() const;
94 Standard_EXPORT ~SMDS_MeshGroup();
95
96
97
98
99  // Type management
100  //
101  Standard_EXPORT friend Handle_Standard_Type& SMDS_MeshGroup_Type_();
102  Standard_EXPORT const Handle(Standard_Type)& DynamicType() const;
103  Standard_EXPORT Standard_Boolean              IsKind(const Handle(Standard_Type)&) const;
104
105 protected:
106
107  // Methods PROTECTED
108  // 
109
110
111  // Fields PROTECTED
112  //
113
114
115 private: 
116
117  // Methods PRIVATE
118  // 
119 Standard_EXPORT SMDS_MeshGroup(const Handle(SMDS_MeshGroup)& parent);
120
121
122  // Fields PRIVATE
123  //
124 Handle_SMDS_Mesh myMesh;
125 SMDSAbs_ElementType myType;
126 SMDS_MapOfMeshElement myElements;
127 Handle_SMDS_MeshGroup myParent;
128 SMDS_ListOfMeshGroup myChildren;
129
130
131 };
132
133
134 #include "SMDS_MeshGroup.lxx"
135
136
137
138 // other inline functions and methods (like "C++: function call" methods)
139 //
140
141
142 #endif