summaryrefslogtreecommitdiff
path: root/inc/IntPatch_RLine.hxx
blob: d0d4d60942ffe850414051501d76c377bf990ff8 (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
// 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 _IntPatch_RLine_HeaderFile
#define _IntPatch_RLine_HeaderFile

#ifndef _Standard_HeaderFile
#include <Standard.hxx>
#endif
#ifndef _Standard_DefineHandle_HeaderFile
#include <Standard_DefineHandle.hxx>
#endif
#ifndef _Handle_IntPatch_RLine_HeaderFile
#include <Handle_IntPatch_RLine.hxx>
#endif

#ifndef _Handle_Adaptor2d_HCurve2d_HeaderFile
#include <Handle_Adaptor2d_HCurve2d.hxx>
#endif
#ifndef _Standard_Boolean_HeaderFile
#include <Standard_Boolean.hxx>
#endif
#ifndef _Standard_Real_HeaderFile
#include <Standard_Real.hxx>
#endif
#ifndef _Handle_IntSurf_LineOn2S_HeaderFile
#include <Handle_IntSurf_LineOn2S.hxx>
#endif
#ifndef _Standard_Integer_HeaderFile
#include <Standard_Integer.hxx>
#endif
#ifndef _IntPatch_SequenceOfPoint_HeaderFile
#include <IntPatch_SequenceOfPoint.hxx>
#endif
#ifndef _IntPatch_Line_HeaderFile
#include <IntPatch_Line.hxx>
#endif
#ifndef _IntSurf_TypeTrans_HeaderFile
#include <IntSurf_TypeTrans.hxx>
#endif
#ifndef _IntSurf_Situation_HeaderFile
#include <IntSurf_Situation.hxx>
#endif
class Adaptor2d_HCurve2d;
class IntSurf_LineOn2S;
class Standard_DomainError;
class Standard_OutOfRange;
class IntPatch_Point;
class IntSurf_PntOn2S;


//! Implementation of an intersection line described by a <br>
//!          restriction line on one of the surfaces. <br>
class IntPatch_RLine : public IntPatch_Line {

public:

  //! Creates a restriction as an intersection line <br>
//!          when the transitions are In or Out. <br>
  Standard_EXPORT   IntPatch_RLine(const Standard_Boolean Tang,const IntSurf_TypeTrans Trans1,const IntSurf_TypeTrans Trans2);
  //! Creates a restriction as an intersection line <br>
//!          when the transitions are Touch. <br>
  Standard_EXPORT   IntPatch_RLine(const Standard_Boolean Tang,const IntSurf_Situation Situ1,const IntSurf_Situation Situ2);
  //! Creates a restriction as an intersection line <br>
//!          when the transitions are Undecided. <br>
  Standard_EXPORT   IntPatch_RLine(const Standard_Boolean Tang);
  //! To add a vertex in the list. <br>
        void AddVertex(const IntPatch_Point& Pnt) ;
  //! Replaces the element of range Index in the list <br>
//!          of points. <br>
        void Replace(const Standard_Integer Index,const IntPatch_Point& Pnt) ;
  
        void SetFirstPoint(const Standard_Integer IndFirst) ;
  
        void SetLastPoint(const Standard_Integer IndLast) ;
  
        void Add(const Handle(IntSurf_LineOn2S)& L) ;
  //! Returns True if the intersection is on the domain of the <br>
//!          first patch. <br>
//!          Returns False if the intersection is on the domain of <br>
//!          the second patch. <br>
        Standard_Boolean IsArcOnS1() const;
  //! Returns True if the intersection is on the domain of the <br>
//!          first patch. <br>
//!          Returns False if the intersection is on the domain of <br>
//!          the second patch. <br>
        Standard_Boolean IsArcOnS2() const;
  
  Standard_EXPORT     void SetArcOnS1(const Handle(Adaptor2d_HCurve2d)& A) ;
  
  Standard_EXPORT     void SetArcOnS2(const Handle(Adaptor2d_HCurve2d)& A) ;
  
  Standard_EXPORT     void SetParamOnS1(const Standard_Real p1,const Standard_Real p2) ;
  
  Standard_EXPORT     void SetParamOnS2(Standard_Real& p1,Standard_Real& p2) ;
  //! Returns the concerned arc. <br>
       const Handle_Adaptor2d_HCurve2d& ArcOnS1() const;
  //! Returns the concerned arc. <br>
       const Handle_Adaptor2d_HCurve2d& ArcOnS2() const;
  
  Standard_EXPORT     void ParamOnS1(Standard_Real& p1,Standard_Real& p2) const;
  
  Standard_EXPORT     void ParamOnS2(Standard_Real& p1,Standard_Real& p2) const;
  //! Returns True if the line has a known First point. <br>
//!          This point is given by the method FirstPoint(). <br>
        Standard_Boolean HasFirstPoint() const;
  //! Returns True if the line has a known Last point. <br>
//!          This point is given by the method LastPoint(). <br>
        Standard_Boolean HasLastPoint() const;
  //! Returns the IntPoint corresponding to the FirstPoint. <br>
//!          An exception is raised when HasFirstPoint returns False. <br>
       const IntPatch_Point& FirstPoint() const;
  //! Returns the IntPoint corresponding to the LastPoint. <br>
//!          An exception is raised when HasLastPoint returns False. <br>
       const IntPatch_Point& LastPoint() const;
  
        Standard_Integer NbVertex() const;
  //! Returns the vertex of range Index on the line. <br>
       const IntPatch_Point& Vertex(const Standard_Integer Index) const;
  
        Standard_Boolean HasPolygon() const;
  //! Returns the number of intersection points. <br>
        Standard_Integer NbPnts() const;
  //! Returns the intersection point of range Index. <br>
       const IntSurf_PntOn2S& Point(const Standard_Integer Index) const;
  //! Set the Point of index <Index> in the LineOn2S <br>
  Standard_EXPORT     void SetPoint(const Standard_Integer Index,const IntPatch_Point& Pnt) ;
  //! Set the parameters of all the vertex on the line. <br>
//!          if a vertex is already in the line, <br>
//!             its parameter is modified <br>
//!          else a new point in the line is inserted. <br>
  Standard_EXPORT     void ComputeVertexParameters(const Standard_Real Tol) ;




  DEFINE_STANDARD_RTTI(IntPatch_RLine)

protected:




private: 


Handle_Adaptor2d_HCurve2d theArcOnS1;
Handle_Adaptor2d_HCurve2d theArcOnS2;
Standard_Boolean onS1;
Standard_Boolean onS2;
Standard_Real ParamInf1;
Standard_Real ParamSup1;
Standard_Real ParamInf2;
Standard_Real ParamSup2;
Handle_IntSurf_LineOn2S curv;
Standard_Boolean fipt;
Standard_Boolean lapt;
Standard_Integer indf;
Standard_Integer indl;
IntPatch_SequenceOfPoint svtx;


};


#include <IntPatch_RLine.lxx>



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


#endif