0028832: MMgt_TShared can be replaced by Standard_Transient
[occt.git] / src / ChFiDS / ChFiDS_SurfData.hxx
CommitLineData
42cf5bc1 1// Created on: 1993-11-26
2// Created by: Isabelle GRIGNON
3// Copyright (c) 1993-1999 Matra Datavision
4// Copyright (c) 1999-2014 OPEN CASCADE SAS
5//
6// This file is part of Open CASCADE Technology software library.
7//
8// This library is free software; you can redistribute it and/or modify it under
9// the terms of the GNU Lesser General Public License version 2.1 as published
10// by the Free Software Foundation, with special exception defined in the file
11// OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT
12// distribution for complete text of the license and disclaimer of any warranty.
13//
14// Alternatively, this file may be used under the terms of Open CASCADE
15// commercial license or contractual agreement.
16
17#ifndef _ChFiDS_SurfData_HeaderFile
18#define _ChFiDS_SurfData_HeaderFile
19
20#include <Standard.hxx>
21#include <Standard_Type.hxx>
22
23#include <ChFiDS_CommonPoint.hxx>
24#include <ChFiDS_FaceInterference.hxx>
25#include <gp_Pnt2d.hxx>
26#include <Standard_Real.hxx>
27#include <Standard_Integer.hxx>
28#include <Standard_Boolean.hxx>
29#include <TopAbs_Orientation.hxx>
25e59720 30#include <Standard_Transient.hxx>
31
42cf5bc1 32class ChFiDS_FaceInterference;
33class ChFiDS_CommonPoint;
34class gp_Pnt2d;
35
36
37class ChFiDS_SurfData;
25e59720 38DEFINE_STANDARD_HANDLE(ChFiDS_SurfData, Standard_Transient)
42cf5bc1 39
40//! data structure for all information related to the
41//! fillet and to 2 faces vis a vis
25e59720 42class ChFiDS_SurfData : public Standard_Transient
42cf5bc1 43{
44
45public:
46
47
48 Standard_EXPORT ChFiDS_SurfData();
49
50 Standard_EXPORT void Copy (const Handle(ChFiDS_SurfData)& Other);
51
52 Standard_Integer IndexOfS1() const;
53
54 Standard_Integer IndexOfS2() const;
55
56 Standard_Boolean IsOnCurve1() const;
57
58 Standard_Boolean IsOnCurve2() const;
59
60 Standard_Integer IndexOfC1() const;
61
62 Standard_Integer IndexOfC2() const;
63
64 Standard_Integer Surf() const;
65
66 TopAbs_Orientation Orientation() const;
67
68 const ChFiDS_FaceInterference& InterferenceOnS1() const;
69
70 const ChFiDS_FaceInterference& InterferenceOnS2() const;
71
72 const ChFiDS_CommonPoint& VertexFirstOnS1() const;
73
74 const ChFiDS_CommonPoint& VertexFirstOnS2() const;
75
76 const ChFiDS_CommonPoint& VertexLastOnS1() const;
77
78 const ChFiDS_CommonPoint& VertexLastOnS2() const;
79
80 void ChangeIndexOfS1 (const Standard_Integer Index);
81
82 void ChangeIndexOfS2 (const Standard_Integer Index);
83
84 void ChangeSurf (const Standard_Integer Index);
85
86 void SetIndexOfC1 (const Standard_Integer Index);
87
88 void SetIndexOfC2 (const Standard_Integer Index);
89
90 TopAbs_Orientation& ChangeOrientation();
91
92 ChFiDS_FaceInterference& ChangeInterferenceOnS1();
93
94 ChFiDS_FaceInterference& ChangeInterferenceOnS2();
95
96 ChFiDS_CommonPoint& ChangeVertexFirstOnS1();
97
98 ChFiDS_CommonPoint& ChangeVertexFirstOnS2();
99
100 ChFiDS_CommonPoint& ChangeVertexLastOnS1();
101
102 ChFiDS_CommonPoint& ChangeVertexLastOnS2();
103
104 Standard_EXPORT const ChFiDS_FaceInterference& Interference (const Standard_Integer OnS) const;
105
106 Standard_EXPORT ChFiDS_FaceInterference& ChangeInterference (const Standard_Integer OnS);
107
108 Standard_EXPORT Standard_Integer Index (const Standard_Integer OfS) const;
109
110 //! returns one of the four vertices wether First is true
111 //! or wrong and OnS equals 1 or 2.
112 Standard_EXPORT const ChFiDS_CommonPoint& Vertex (const Standard_Boolean First, const Standard_Integer OnS) const;
113
114 //! returns one of the four vertices wether First is true
115 //! or wrong and OnS equals 1 or 2.
116 Standard_EXPORT ChFiDS_CommonPoint& ChangeVertex (const Standard_Boolean First, const Standard_Integer OnS);
117
118 Standard_Boolean IsOnCurve (const Standard_Integer OnS) const;
119
120 Standard_Integer IndexOfC (const Standard_Integer OnS) const;
121
122 Standard_EXPORT Standard_Real FirstSpineParam() const;
123
124 Standard_EXPORT Standard_Real LastSpineParam() const;
125
126 Standard_EXPORT void FirstSpineParam (const Standard_Real Par);
127
128 Standard_EXPORT void LastSpineParam (const Standard_Real Par);
129
130 Standard_EXPORT Standard_Real FirstExtensionValue() const;
131
132 Standard_EXPORT Standard_Real LastExtensionValue() const;
133
134 Standard_EXPORT void FirstExtensionValue (const Standard_Real Extend);
135
136 Standard_EXPORT void LastExtensionValue (const Standard_Real Extend);
137
25e59720 138 Standard_EXPORT Handle(Standard_Transient) Simul() const;
42cf5bc1 139
25e59720 140 Standard_EXPORT void SetSimul (const Handle(Standard_Transient)& S);
42cf5bc1 141
142 Standard_EXPORT void ResetSimul();
143
144 Standard_EXPORT gp_Pnt2d Get2dPoints (const Standard_Boolean First, const Standard_Integer OnS) const;
145
146 Standard_EXPORT void Get2dPoints (gp_Pnt2d& P2df1, gp_Pnt2d& P2dl1, gp_Pnt2d& P2df2, gp_Pnt2d& P2dl2) const;
147
148 Standard_EXPORT void Set2dPoints (const gp_Pnt2d& P2df1, const gp_Pnt2d& P2dl1, const gp_Pnt2d& P2df2, const gp_Pnt2d& P2dl2);
149
150 Standard_Boolean TwistOnS1() const;
151
152 Standard_Boolean TwistOnS2() const;
153
154 void TwistOnS1 (const Standard_Boolean T);
155
156 void TwistOnS2 (const Standard_Boolean T);
157
158
159
160
25e59720 161 DEFINE_STANDARD_RTTIEXT(ChFiDS_SurfData,Standard_Transient)
42cf5bc1 162
163protected:
164
165
166
167
168private:
169
170
171 ChFiDS_CommonPoint pfirstOnS1;
172 ChFiDS_CommonPoint plastOnS1;
173 ChFiDS_CommonPoint pfirstOnS2;
174 ChFiDS_CommonPoint plastOnS2;
175 ChFiDS_FaceInterference intf1;
176 ChFiDS_FaceInterference intf2;
177 gp_Pnt2d p2df1;
178 gp_Pnt2d p2dl1;
179 gp_Pnt2d p2df2;
180 gp_Pnt2d p2dl2;
181 Standard_Real ufspine;
182 Standard_Real ulspine;
183 Standard_Real myfirstextend;
184 Standard_Real mylastextend;
25e59720 185 Handle(Standard_Transient) simul;
42cf5bc1 186 Standard_Integer indexOfS1;
187 Standard_Integer indexOfC1;
188 Standard_Integer indexOfS2;
189 Standard_Integer indexOfC2;
190 Standard_Integer indexOfConge;
191 Standard_Boolean isoncurv1;
192 Standard_Boolean isoncurv2;
193 Standard_Boolean twistons1;
194 Standard_Boolean twistons2;
195 TopAbs_Orientation orientation;
196
197
198};
199
200
201#include <ChFiDS_SurfData.lxx>
202
203
204
205
206
207#endif // _ChFiDS_SurfData_HeaderFile