Salome HOME
Synchronize adm files
[modules/geom.git] / src / GEOMAlgo / GEOMAlgo_ShapeInfo.hxx
1 // Copyright (C) 2007-2014  CEA/DEN, EDF R&D, OPEN CASCADE
2 //
3 // This library is free software; you can redistribute it and/or
4 // modify it under the terms of the GNU Lesser General Public
5 // License as published by the Free Software Foundation; either
6 // version 2.1 of the License, or (at your option) any later version.
7 //
8 // This library is distributed in the hope that it will be useful,
9 // but WITHOUT ANY WARRANTY; without even the implied warranty of
10 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
11 // Lesser General Public License for more details.
12 //
13 // You should have received a copy of the GNU Lesser General Public
14 // License along with this library; if not, write to the Free Software
15 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
16 //
17 // See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
18 //
19
20
21 #ifndef _GEOMAlgo_ShapeInfo_HeaderFile
22 #define _GEOMAlgo_ShapeInfo_HeaderFile
23
24 #include <Standard.hxx>
25 #include <Standard_Macro.hxx>
26 #include <TopAbs_ShapeEnum.hxx>
27 #include <Standard_Integer.hxx>
28
29
30 #include <gp_Pnt.hxx>
31 #include <gp_Dir.hxx>
32 #include <gp_Ax3.hxx>
33 #include <Standard_Real.hxx>
34 #include <gp_Ax2.hxx>
35
36 #include <GEOMAlgo_KindOfShape.hxx>
37 #include <GEOMAlgo_KindOfName.hxx>
38 #include <GEOMAlgo_KindOfBounds.hxx>
39 #include <GEOMAlgo_KindOfClosed.hxx>
40
41
42 //=======================================================================
43 //class : GEOMAlgo_ShapeInfo
44 //purpose  :
45 //=======================================================================
46 class GEOMAlgo_ShapeInfo
47 {
48  public:
49   Standard_EXPORT
50     GEOMAlgo_ShapeInfo();
51
52   Standard_EXPORT
53     virtual ~GEOMAlgo_ShapeInfo();
54
55   Standard_EXPORT
56     void Reset() ;
57
58   Standard_EXPORT
59     void SetType(const TopAbs_ShapeEnum aType) ;
60
61   Standard_EXPORT
62     TopAbs_ShapeEnum Type() const;
63
64   Standard_EXPORT
65     void SetNbSubShapes(const TopAbs_ShapeEnum aType,const Standard_Integer aNb) ;
66
67   Standard_EXPORT
68     Standard_Integer NbSubShapes(const TopAbs_ShapeEnum aType) const;
69
70   Standard_EXPORT
71     void SetKindOfShape(const GEOMAlgo_KindOfShape aT) ;
72
73   Standard_EXPORT
74     GEOMAlgo_KindOfShape KindOfShape() const;
75
76   Standard_EXPORT
77     void SetKindOfName(const GEOMAlgo_KindOfName aT) ;
78
79   Standard_EXPORT
80     GEOMAlgo_KindOfName KindOfName() const;
81
82   Standard_EXPORT
83     void SetKindOfBounds(const GEOMAlgo_KindOfBounds aT) ;
84
85   Standard_EXPORT
86     GEOMAlgo_KindOfBounds KindOfBounds() const;
87
88   Standard_EXPORT
89     void SetKindOfClosed(const GEOMAlgo_KindOfClosed aT) ;
90
91   Standard_EXPORT
92     GEOMAlgo_KindOfClosed KindOfClosed() const;
93
94   Standard_EXPORT
95     void SetLocation(const gp_Pnt& aP) ;
96
97   Standard_EXPORT
98     const gp_Pnt& Location() const;
99
100   Standard_EXPORT
101     void SetDirection(const gp_Dir& aD) ;
102
103   Standard_EXPORT
104     const gp_Dir& Direction() const;
105
106   Standard_EXPORT
107     void SetPosition(const gp_Ax2& aAx2) ;
108
109   Standard_EXPORT
110     void SetPosition(const gp_Ax3& aAx3) ;
111
112   Standard_EXPORT
113     const gp_Ax3& Position() const;
114
115   Standard_EXPORT
116     void SetPnt1(const gp_Pnt& aP) ;
117
118   Standard_EXPORT
119     const gp_Pnt& Pnt1() const;
120
121   Standard_EXPORT
122     void SetPnt2(const gp_Pnt& aP) ;
123
124   Standard_EXPORT
125     const gp_Pnt& Pnt2() const;
126
127   Standard_EXPORT
128     void SetRadius1(const Standard_Real aR) ;
129
130   Standard_EXPORT
131     Standard_Real Radius1() const;
132
133   Standard_EXPORT
134     void SetRadius2(const Standard_Real aR) ;
135
136   Standard_EXPORT
137     Standard_Real Radius2() const;
138
139   Standard_EXPORT
140     void SetLength(const Standard_Real aL) ;
141
142   Standard_EXPORT
143     Standard_Real Length() const;
144
145   Standard_EXPORT
146     void SetWidth(const Standard_Real aW) ;
147
148   Standard_EXPORT
149     Standard_Real Width() const;
150
151   Standard_EXPORT
152     void SetHeight(const Standard_Real aH) ;
153
154   Standard_EXPORT
155     Standard_Real Height() const;
156
157   Standard_EXPORT
158     void Dump() const;
159
160  protected:
161   Standard_EXPORT
162     void DumpVertex() const;
163
164   Standard_EXPORT
165     void DumpEdge() const;
166
167   Standard_EXPORT
168     void DumpWire() const;
169
170   Standard_EXPORT
171     void DumpFace() const;
172
173   Standard_EXPORT
174     void DumpShell() const;
175
176   Standard_EXPORT
177     void DumpSolid() const;
178
179   Standard_EXPORT
180     void DumpCompSolid() const;
181
182   Standard_EXPORT
183     void DumpCompound() const;
184
185
186   TopAbs_ShapeEnum myType;
187   Standard_Integer myNbSubShapes[9];
188   GEOMAlgo_KindOfShape myKindOfShape;
189   GEOMAlgo_KindOfName myKindOfName;
190   GEOMAlgo_KindOfBounds myKindOfBounds;
191   GEOMAlgo_KindOfClosed myKindOfClosed;
192   gp_Pnt myLocation;
193   gp_Dir myDirection;
194   gp_Ax3 myPosition;
195   Standard_Real myRadius1;
196   Standard_Real myRadius2;
197   Standard_Real myLength;
198   Standard_Real myWidth;
199   Standard_Real myHeight;
200   gp_Pnt myPnt1;
201   gp_Pnt myPnt2;
202   Standard_Integer myNbTypes;
203 };
204 #endif