b311480e |
1 | -- Created on: 1992-09-22 |
2 | -- Created by: Gilles DEBARBOUILLE |
3 | -- Copyright (c) 1992-1999 Matra Datavision |
973c2be1 |
4 | -- Copyright (c) 1999-2014 OPEN CASCADE SAS |
b311480e |
5 | -- |
973c2be1 |
6 | -- This file is part of Open CASCADE Technology software library. |
b311480e |
7 | -- |
d5f74e42 |
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 |
973c2be1 |
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. |
b311480e |
13 | -- |
973c2be1 |
14 | -- Alternatively, this file may be used under the terms of Open CASCADE |
15 | -- commercial license or contractual agreement. |
7fd59977 |
16 | |
47cbf134 |
17 | class Mat2d from MAT2d |
7fd59977 |
18 | |
19 | ---Purpose: this class contains the generic algoritm of |
20 | -- computation of the bisecting locus. |
21 | |
22 | uses |
23 | Side from MAT, |
24 | Bisector from MAT, |
47cbf134 |
25 | ListOfEdge from MAT, |
26 | ListOfBisector from MAT, |
7fd59977 |
27 | DataMapOfIntegerBisector from MAT, |
47cbf134 |
28 | DataMapOfIntegerInteger from TColStd, |
29 | Tool2d from MAT2d |
7fd59977 |
30 | |
31 | is |
32 | |
0e0f7a7c |
33 | Create(IsOpenResult : Boolean from Standard = Standard_False) |
7fd59977 |
34 | ---Purpose: Empty construtor. |
47cbf134 |
35 | returns Mat2d from MAT2d; |
7fd59977 |
36 | |
37 | --- Category : Computation. |
38 | |
47cbf134 |
39 | CreateMat(me : in out ; aTool : in out Tool2d from MAT2d) |
7fd59977 |
40 | ---Purpose: Algoritm of computation of the bisecting locus. |
41 | is static; |
42 | |
0e0f7a7c |
43 | CreateMatOpen(me : in out ; aTool : in out Tool2d from MAT2d) |
44 | ---Purpose: Algoritm of computation of the bisecting locus for |
45 | -- open wire. |
46 | is static; |
47 | |
7fd59977 |
48 | IsDone(me) returns Boolean from Standard |
49 | ---Purpose: Returns <TRUE> if CreateMat has succeeded. |
50 | is static; |
51 | |
52 | LoadBisectorsToRemove(me : in out ; |
53 | noofbisectorstoremove : in out Integer; |
54 | distance1 : Real; |
55 | distance2 : Real; |
56 | bisector1 : Bisector from MAT; |
57 | bisector2 : Bisector from MAT; |
58 | bisector3 : Bisector from MAT; |
59 | bisector4 : Bisector from MAT) |
60 | is static private; |
61 | |
62 | |
63 | Intersect( me : in out ; |
47cbf134 |
64 | atool : in out Tool2d from MAT2d; |
7fd59977 |
65 | aside : Integer ; |
66 | noofbisectorstoremove: in out Integer ; |
6e33d3ce |
67 | bisector1 : Bisector from MAT; |
68 | bisector2 : Bisector from MAT) |
7fd59977 |
69 | is static private; |
70 | |
71 | |
72 | --- Category : Querying. |
73 | |
74 | Init(me : in out) |
75 | --- Purpose : Initialize an iterator on the set of the roots |
76 | -- of the trees of bisectors. |
77 | is static; |
78 | |
79 | More(me) returns Boolean |
80 | --- Purpose : Return False if there is no more roots. |
81 | is static; |
82 | |
83 | Next(me : in out) |
84 | --- Purpose : Move to the next root. |
85 | is static; |
86 | |
87 | Bisector(me) returns any Bisector from MAT |
88 | --- Purpose : Returns the current root. |
89 | is static; |
90 | |
91 | SemiInfinite(me) returns Boolean from Standard |
92 | --- Purpose : Returns True if there are semi_infinite bisectors. |
93 | -- So there is a tree for each semi_infinte bisector. |
94 | is static; |
95 | |
96 | NumberOfBisectors(me) returns Integer from Standard |
97 | --- Purpose : Returns the total number of bisectors. |
98 | is static; |
99 | |
100 | fields |
101 | |
0e0f7a7c |
102 | myIsOpenResult : Boolean; |
7fd59977 |
103 | thenumberofbisectors : Integer; |
104 | thenumberofedges : Integer; |
105 | semiInfinite : Boolean; |
106 | theedgelist : ListOfEdge from MAT; |
107 | typeofbisectortoremove: DataMapOfIntegerInteger from TColStd; |
108 | bisectoronetoremove : DataMapOfIntegerBisector from MAT; |
109 | bisectortwotoremove : DataMapOfIntegerBisector from MAT; |
110 | bisectormap : DataMapOfIntegerBisector from MAT; |
111 | roots : ListOfBisector from MAT; |
7fd59977 |
112 | isDone : Boolean; |
113 | |
47cbf134 |
114 | end Mat2d; |