summaryrefslogtreecommitdiff
path: root/inc/BOPTools_InterferencePool.hxx
blob: 4a75024ac4a5c121ca4d72740d3350c38293df6e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
// This file is generated by WOK (CPPExt).
// Please do not edit this file; modify original file instead.
// The copyright and license terms as defined for the original file apply to 
// this header file considered to be the "object code" form of the original source.

#ifndef _BOPTools_InterferencePool_HeaderFile
#define _BOPTools_InterferencePool_HeaderFile

#ifndef _Standard_HeaderFile
#include <Standard.hxx>
#endif
#ifndef _Standard_Macro_HeaderFile
#include <Standard_Macro.hxx>
#endif

#ifndef _BooleanOperations_PShapesDataStructure_HeaderFile
#include <BooleanOperations_PShapesDataStructure.hxx>
#endif
#ifndef _Standard_Integer_HeaderFile
#include <Standard_Integer.hxx>
#endif
#ifndef _BOPTools_CArray1OfInterferenceLine_HeaderFile
#include <BOPTools_CArray1OfInterferenceLine.hxx>
#endif
#ifndef _BOPTools_CArray1OfSSInterference_HeaderFile
#include <BOPTools_CArray1OfSSInterference.hxx>
#endif
#ifndef _BOPTools_CArray1OfESInterference_HeaderFile
#include <BOPTools_CArray1OfESInterference.hxx>
#endif
#ifndef _BOPTools_CArray1OfVSInterference_HeaderFile
#include <BOPTools_CArray1OfVSInterference.hxx>
#endif
#ifndef _BOPTools_CArray1OfEEInterference_HeaderFile
#include <BOPTools_CArray1OfEEInterference.hxx>
#endif
#ifndef _BOPTools_CArray1OfVEInterference_HeaderFile
#include <BOPTools_CArray1OfVEInterference.hxx>
#endif
#ifndef _BOPTools_CArray1OfVVInterference_HeaderFile
#include <BOPTools_CArray1OfVVInterference.hxx>
#endif
#ifndef _Standard_Boolean_HeaderFile
#include <Standard_Boolean.hxx>
#endif
#ifndef _BooleanOperations_KindOfInterference_HeaderFile
#include <BooleanOperations_KindOfInterference.hxx>
#endif
#ifndef _BOPTools_PShapeShapeInterference_HeaderFile
#include <BOPTools_PShapeShapeInterference.hxx>
#endif
class BooleanOperations_ShapesDataStructure;
class BOPTools_CArray1OfInterferenceLine;
class BOPTools_CArray1OfSSInterference;
class BOPTools_CArray1OfESInterference;
class BOPTools_CArray1OfVSInterference;
class BOPTools_CArray1OfEEInterference;
class BOPTools_CArray1OfVEInterference;
class BOPTools_CArray1OfVVInterference;



//!  Class for storing information about <br>
//! results of all interferences for all shapes <br>
class BOPTools_InterferencePool  {
public:

  void* operator new(size_t,void* anAddress) 
  {
    return anAddress;
  }
  void* operator new(size_t size) 
  {
    return Standard::Allocate(size); 
  }
  void  operator delete(void *anAddress) 
  {
    if (anAddress) Standard::Free((Standard_Address&)anAddress); 
  }

  
//! Empty constructor <br>
  Standard_EXPORT   BOPTools_InterferencePool();
  
//! Constructor <br>
  Standard_EXPORT   BOPTools_InterferencePool(const BooleanOperations_ShapesDataStructure& aDS);
  
//! Modifier <br>
  Standard_EXPORT     void SetDS(const BooleanOperations_ShapesDataStructure& aDS) ;
  
//! Selector <br>
  Standard_EXPORT     BooleanOperations_PShapesDataStructure DS() const;
  
//! Returns  TRUE if the shape with DS_index  <anInd> <br>
//! has at least one  interference with non-empty result <br>
  Standard_EXPORT     Standard_Boolean HasInterference(const Standard_Integer anInd) const;
  
//! Returns  TRUE if the interference between shapes <br>
//! <anInd1> and <anInd2> has already been computed. <br>
  Standard_EXPORT     Standard_Boolean IsComputed(const Standard_Integer anInd1,const Standard_Integer anInd2) const;
  
//! Sorts types of shapes <anInd1> and <anInd2> in increasing order <br>
  Standard_EXPORT     void SortTypes(Standard_Integer& anInd1,Standard_Integer& anInd2) const;
  
//! Gets the type of interference in accordance with the types of <br>
//! shapes  <anInd1> and <anInd2> <br>
  Standard_EXPORT     BooleanOperations_KindOfInterference InterferenceType(const Standard_Integer anInd1,const Standard_Integer anInd2) const;
  
//! Adds the info about interference in InterferenceLine-s for <br>
//! shapes  <anInd1> and <anInd2> <br>
  Standard_EXPORT     void AddInterference(const Standard_Integer anInd1,const Standard_Integer anInd2,const BooleanOperations_KindOfInterference aType,const Standard_Integer anIndex) ;
  
//! Returns the reference to complete array of interference line-s <br>
  Standard_EXPORT    const BOPTools_CArray1OfInterferenceLine& InterferenceTable() const;
  
//! Returns the reference to array Of F/F interferences <br>
  Standard_EXPORT     BOPTools_CArray1OfSSInterference& SSInterferences() ;
  
//! Returns the reference to array Of E/F interferences <br>
  Standard_EXPORT     BOPTools_CArray1OfESInterference& ESInterferences() ;
  
//! Returns the reference to array Of V/F interferences <br>
  Standard_EXPORT     BOPTools_CArray1OfVSInterference& VSInterferences() ;
  
//! Returns the reference to arrray Of E/E interferences <br>
  Standard_EXPORT     BOPTools_CArray1OfEEInterference& EEInterferences() ;
  
//! Returns the reference to arrray Of  V/E interferences <br>
  Standard_EXPORT     BOPTools_CArray1OfVEInterference& VEInterferences() ;
  
//! Returns the reference to arrray Of  V/V interferences <br>
  Standard_EXPORT     BOPTools_CArray1OfVVInterference& VVInterferences() ;
  
  Standard_EXPORT    const BOPTools_CArray1OfSSInterference& SSInterfs() const;
  
  Standard_EXPORT    const BOPTools_CArray1OfESInterference& ESInterfs() const;
  
  Standard_EXPORT    const BOPTools_CArray1OfVSInterference& VSInterfs() const;
  
  Standard_EXPORT    const BOPTools_CArray1OfEEInterference& EEInterfs() const;
  
  Standard_EXPORT    const BOPTools_CArray1OfVEInterference& VEInterfs() const;
  
  Standard_EXPORT    const BOPTools_CArray1OfVVInterference& VVInterfs() const;
  
  Standard_EXPORT     BOPTools_PShapeShapeInterference GetInterference(const Standard_Integer anIndex,const BooleanOperations_KindOfInterference aType) const;





protected:





private:



BooleanOperations_PShapesDataStructure myDS;
Standard_Integer myNbSourceShapes;
BOPTools_CArray1OfInterferenceLine myInterferenceTable;
BOPTools_CArray1OfSSInterference mySSInterferences;
BOPTools_CArray1OfESInterference myESInterferences;
BOPTools_CArray1OfVSInterference myVSInterferences;
BOPTools_CArray1OfEEInterference myEEInterferences;
BOPTools_CArray1OfVEInterference myVEInterferences;
BOPTools_CArray1OfVVInterference myVVInterferences;


};





// other Inline functions and methods (like "C++: function call" methods)


#endif