0024428: Implementation of LGPL license
[occt.git] / src / IntPatch / IntPatch_WLine.cdl
1 -- Created on: 1991-05-27
2 -- Created by: Isabelle GRIGNON
3 -- Copyright (c) 1991-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
9 -- under the terms of the GNU Lesser General Public 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 class WLine from IntPatch
18
19 inherits Line from IntPatch 
20
21         ---Purpose: Definition of set of points as a result of the intersection
22         --          between 2 parametrised patches.
23
24 uses
25      HCurve2d        from Adaptor2d,
26      Point           from IntPatch,
27      SequenceOfPoint from IntPatch,
28      PntOn2S         from IntSurf,
29      LineOn2S        from IntSurf,
30      TypeTrans       from IntSurf,
31      Situation       from IntSurf,
32      Box2d           from Bnd,
33      Box             from Bnd,
34      Pnt2d           from gp,
35      Pnt             from gp
36
37 raises OutOfRange  from Standard,
38        DomainError from Standard
39 is
40     Create(Line: LineOn2S from IntSurf; Tang: Boolean from Standard;
41            Trans1, Trans2: TypeTrans from IntSurf)
42     
43         ---Purpose: Creates a WLine as an intersection when the 
44         --          transitions are In or Out.
45     
46         returns mutable WLine from IntPatch;
47
48
49     Create(Line: LineOn2S from IntSurf; Tang: Boolean from Standard;
50            Situ1,Situ2: Situation from IntSurf)
51     
52         ---Purpose: Creates a WLine as an intersection when the 
53         --          transitions are Touch.
54     
55         returns mutable WLine from IntPatch;
56
57
58     Create(Line: LineOn2S from IntSurf; Tang: Boolean from Standard)
59     
60         ---Purpose: Creates a WLine as an intersection when the 
61         --          transitions are Undecided.
62     
63         returns mutable WLine from IntPatch;
64
65
66     AddVertex(me: mutable; Pnt: Point from IntPatch)
67     
68         ---Purpose: Adds a vertex in the list.
69
70         ---C++: inline
71
72         is static;
73
74     
75     SetPoint(me:mutable; Index: Integer from Standard; Pnt: Point from IntPatch)
76     
77         ---Purpose: Set the Point of index <Index> in the LineOn2S
78     
79         is static;
80     
81     
82     Replace(me: mutable; Index: Integer from Standard; Pnt: Point from IntPatch)
83     
84         ---Purpose: Replaces the element of range Index in the list
85         --          of points.
86         --          The exception OutOfRange is raised when
87         --          Index <= 0 or Index > NbVertex.
88
89         ---C++: inline
90
91         raises OutOfRange from Standard
92         
93         is static;
94
95
96     SetFirstPoint(me: mutable; IndFirst: Integer from Standard) is static;
97
98         ---C++: inline
99
100
101     SetLastPoint(me: mutable; IndLast: Integer from Standard) is static;
102
103         ---C++: inline
104
105
106     NbPnts(me)
107     
108         ---Purpose: Returns the number of intersection points.
109
110         returns Integer from Standard
111         ---C++: inline
112         
113         is static;
114
115
116     Point(me; Index: Integer from Standard)
117     
118         ---Purpose: Returns the intersection point of range Index.
119
120         returns PntOn2S from IntSurf
121         ---C++: inline
122         ---C++: return const&
123         
124         raises OutOfRange from Standard
125         --- The exception OutOfRange is raised if Index <= 0 or Index > NbPnts.
126         
127         is static;
128
129
130     HasFirstPoint(me)
131     
132         ---Purpose: Returns True if the line has a known First point.
133         --          This point is given by the method FirstPoint().
134     
135         returns Boolean from Standard
136         ---C++: inline
137         
138         is static;
139
140
141     HasLastPoint(me)
142     
143         ---Purpose: Returns True if the line has a known Last point.
144         --          This point is given by the method LastPoint().
145     
146         returns Boolean from Standard
147         ---C++: inline
148         
149         is static;
150
151
152     FirstPoint(me)
153     
154         ---Purpose: Returns the Point corresponding to the FirstPoint.
155     
156         returns Point from IntPatch
157         ---C++: inline
158         ---C++: return const&
159         
160         raises DomainError from Standard
161         --- The exception DomainError is raised when HasFirstPoint
162         --  returns False.
163         
164         is static;
165
166
167     LastPoint(me)
168     
169         ---Purpose: Returns the Point corresponding to the LastPoint.
170     
171         returns Point from IntPatch
172         ---C++: inline
173         ---C++: return const&
174         
175         raises DomainError from Standard
176         --- The exception DomainError is raised when HasFirstPoint
177         --  returns False.
178         
179         is static;
180
181
182     FirstPoint(me; Indfirst: out Integer from Standard)
183     
184         ---Purpose: Returns the Point corresponding to the FirstPoint.
185         --          Indfirst is the index of the first in the list
186         --          of vertices.
187     
188         returns Point from IntPatch
189         ---C++: inline
190         ---C++: return const&
191         
192         raises DomainError from Standard
193         --- The exception DomainError is raised when HasFirstPoint
194         --  returns False.
195         
196         is static;
197
198
199     LastPoint(me; Indlast: out Integer from Standard)
200     
201         ---Purpose: Returns the Point corresponding to the LastPoint.
202         --          Indlast is the index of the last in the list
203         --          of vertices.
204     
205         returns Point from IntPatch
206         ---C++: inline
207         ---C++: return const&
208         
209         raises DomainError from Standard
210         --- The exception DomainError is raised when HasFirstPoint
211         --  returns False.
212         
213         is static;
214
215
216     NbVertex(me)
217     
218         returns Integer from Standard
219         ---C++: inline
220         
221         is static;
222
223
224     Vertex(me; Index: Integer from Standard)
225     
226         ---Purpose: Returns the vertex of range Index on the line.
227     
228         returns Point from IntPatch
229         ---C++: inline
230         ---C++: return const&
231         
232         raises OutOfRange from Standard 
233         --- The exception OutOfRange is raised if Index <= 0 or
234         --  Index > NbVertex.
235
236         is static;
237
238
239     ComputeVertexParameters(me: mutable; Tol: Real from Standard)
240     
241         ---Purpose: Set the parameters of all the vertex on the line.
242         --          if a vertex is already in the line, 
243         --             its parameter is modified
244         --          else a new point in the line is inserted.
245         is static; 
246
247     Curve(me) 
248     
249        returns LineOn2S from IntSurf
250        is static;
251        
252
253     IsOutSurf1Box(me: mutable; P1: Pnt2d from gp )
254         returns Boolean from Standard
255         is static;
256
257     IsOutSurf2Box(me: mutable; P1: Pnt2d from gp )
258         returns Boolean from Standard
259         is static;
260         
261     IsOutBox(me: mutable; P: Pnt from gp)
262         returns Boolean from Standard
263         is static;
264
265
266     SetPeriod(me: mutable; pu1,pv1,pu2,pv2: Real from Standard)
267         is static;
268         
269
270     U1Period(me) 
271         returns Real from Standard
272         is static;
273
274     V1Period(me) 
275         returns Real from Standard
276         is static;
277
278     U2Period(me) 
279         returns Real from Standard
280         is static;
281
282     V2Period(me) 
283         returns Real from Standard
284         is static;
285         
286
287
288     SetArcOnS1(me: mutable ; A : HCurve2d from Adaptor2d)
289         is static;
290         
291     HasArcOnS1(me)
292         returns Boolean from Standard
293         is static;
294     
295     GetArcOnS1(me) 
296         ---C++: return const&
297         returns HCurve2d from Adaptor2d;
298
299     SetArcOnS2(me: mutable ; A : HCurve2d from Adaptor2d)
300         is static;
301         
302     HasArcOnS2(me)
303         returns Boolean from Standard
304         is static;
305     
306     GetArcOnS2(me) 
307         ---C++: return const&
308         returns HCurve2d from Adaptor2d;
309
310     Dump(me)
311     
312         is static;
313
314  
315 fields
316
317     curv : LineOn2S        from IntSurf;
318     fipt : Boolean         from Standard;
319     lapt : Boolean         from Standard;
320     indf : Integer         from Standard;
321     indl : Integer         from Standard;
322     svtx : SequenceOfPoint from IntPatch;
323     
324     Buv1 : Box2d        from Bnd;
325     Buv2 : Box2d        from Bnd;
326     Bxyz : Box          from Bnd;
327
328     u1period : Real from Standard;
329     v1period : Real from Standard;
330     u2period : Real from Standard;
331     v2period : Real from Standard;
332     
333     hasArcOnS1   : Boolean from Standard;
334     theArcOnS1   : HCurve2d from Adaptor2d;
335     hasArcOnS2   : Boolean from Standard;
336     theArcOnS2   : HCurve2d from Adaptor2d;
337     
338 end WLine;