1 -- Created on: 1992-04-06
2 -- Created by: Jacques GOUSSARD
3 -- Copyright (c) 1992-1999 Matra Datavision
4 -- Copyright (c) 1999-2014 OPEN CASCADE SAS
6 -- This file is part of Open CASCADE Technology software library.
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.
14 -- Alternatively, this file may be used under the terms of Open CASCADE
15 -- commercial license or contractual agreement.
17 class RLine from IntPatch
20 inherits Line from IntPatch
22 ---Purpose: Implementation of an intersection line described by a
23 -- restriction line on one of the surfaces.
27 HCurve2d from Adaptor2d,
29 SequenceOfPoint from IntPatch,
30 TypeTrans from IntSurf,
31 Situation from IntSurf,
35 raises DomainError from Standard,
36 OutOfRange from Standard
40 Create(Tang: Boolean from Standard;
41 Trans1,Trans2: TypeTrans from IntSurf)
43 ---Purpose: Creates a restriction as an intersection line
44 -- when the transitions are In or Out.
46 returns RLine from IntPatch;
49 Create(Tang: Boolean from Standard;
50 Situ1,Situ2: Situation from IntSurf)
52 ---Purpose: Creates a restriction as an intersection line
53 -- when the transitions are Touch.
55 returns RLine from IntPatch;
58 Create(Tang: Boolean from Standard)
60 ---Purpose: Creates a restriction as an intersection line
61 -- when the transitions are Undecided.
63 returns RLine from IntPatch;
66 AddVertex(me: mutable; Pnt: Point from IntPatch)
68 ---Purpose: To add a vertex in the list.
75 Replace(me: mutable; Index: Integer from Standard; Pnt: Point from IntPatch)
77 ---Purpose: Replaces the element of range Index in the list
82 raises OutOfRange from Standard
83 --- The exception OutOfRange is raised when Index <= 0
84 -- or Index > NbVertex.
89 SetFirstPoint(me: mutable; IndFirst: Integer from Standard) is static;
94 SetLastPoint(me: mutable; IndLast: Integer from Standard) is static;
99 Add(me: mutable; L: LineOn2S from IntSurf)
108 ---Purpose: Returns True if the intersection is on the domain of the
110 -- Returns False if the intersection is on the domain of
113 returns Boolean from Standard
120 ---Purpose: Returns True if the intersection is on the domain of the
122 -- Returns False if the intersection is on the domain of
125 returns Boolean from Standard
130 SetArcOnS1(me: mutable; A: HCurve2d from Adaptor2d)
134 SetArcOnS2(me: mutable; A: HCurve2d from Adaptor2d)
138 SetParamOnS1(me: mutable; p1,p2: Real from Standard)
139 --- first and last parameters on the restriction of the first
143 SetParamOnS2(me: mutable; p1,p2: out Real from Standard)
144 --- first and last parameters on the restriction of the first
150 ---Purpose: Returns the concerned arc.
152 returns HCurve2d from Adaptor2d
154 ---C++: return const&
156 raises DomainError from Standard
162 ---Purpose: Returns the concerned arc.
164 returns HCurve2d from Adaptor2d
166 ---C++: return const&
168 raises DomainError from Standard
172 ParamOnS1(me; p1,p2: out Real from Standard)
173 --- first and last parameters on the restriction of the first
177 ParamOnS2(me; p1,p2: out Real from Standard)
178 --- first and last parameters on the restriction of the first
184 ---Purpose: Returns True if the line has a known First point.
185 -- This point is given by the method FirstPoint().
187 returns Boolean from Standard
195 ---Purpose: Returns True if the line has a known Last point.
196 -- This point is given by the method LastPoint().
198 returns Boolean from Standard
206 ---Purpose: Returns the IntPoint corresponding to the FirstPoint.
207 -- An exception is raised when HasFirstPoint returns False.
209 returns Point from IntPatch
211 ---C++: return const&
213 raises DomainError from Standard
220 ---Purpose: Returns the IntPoint corresponding to the LastPoint.
221 -- An exception is raised when HasLastPoint returns False.
223 returns Point from IntPatch
225 ---C++: return const&
227 raises DomainError from Standard
234 returns Integer from Standard
240 Vertex(me; Index: Integer from Standard)
242 ---Purpose: Returns the vertex of range Index on the line.
244 returns Point from IntPatch
246 ---C++: return const&
248 raises OutOfRange from Standard
249 --- The exception OutOfRange is raised if Index <= 0 or
257 returns Boolean from Standard
265 ---Purpose: Returns the number of intersection points.
267 returns Integer from Standard
270 raises DomainError from Standard
271 --- The exception DomainError is raised if HasPolygon returns False.
276 Point(me; Index: Integer from Standard)
278 ---Purpose: Returns the intersection point of range Index.
280 returns PntOn2S from IntSurf
282 ---C++: return const&
284 raises OutOfRange from Standard,
285 DomainError from Standard
286 --- The exception DomainError is raised if HasPolygon returns False.
287 --- The exception OutOfRange is raised if Index <= 0 or Index > NbPnts.
292 SetPoint(me:mutable; Index: Integer from Standard; Pnt: Point from IntPatch)
294 ---Purpose: Set the Point of index <Index> in the LineOn2S
298 ComputeVertexParameters(me: mutable; Tol:Real from Standard)
300 ---Purpose: Set the parameters of all the vertex on the line.
301 -- if a vertex is already in the line,
302 -- its parameter is modified
303 -- else a new point in the line is inserted.
309 theArcOnS1 : HCurve2d from Adaptor2d;
310 theArcOnS2 : HCurve2d from Adaptor2d;
311 onS1 : Boolean from Standard;
312 onS2 : Boolean from Standard;
314 ParamInf1 : Real from Standard;
315 ParamSup1 : Real from Standard;
316 ParamInf2 : Real from Standard;
317 ParamSup2 : Real from Standard;
319 curv : LineOn2S from IntSurf;
320 fipt : Boolean from Standard;
321 lapt : Boolean from Standard;
322 indf : Integer from Standard;
323 indl : Integer from Standard;
324 svtx : SequenceOfPoint from IntPatch;