42cf5bc1 |
1 | // Created on: 1994-10-07 |
2 | // Created by: Yves FRICAUD |
3 | // Copyright (c) 1994-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 _BRepMAT2d_LinkTopoBilo_HeaderFile |
18 | #define _BRepMAT2d_LinkTopoBilo_HeaderFile |
19 | |
20 | #include <Standard.hxx> |
21 | #include <Standard_DefineAlloc.hxx> |
22 | #include <Standard_Handle.hxx> |
23 | |
24 | #include <BRepMAT2d_DataMapOfShapeSequenceOfBasicElt.hxx> |
25 | #include <BRepMAT2d_DataMapOfBasicEltShape.hxx> |
26 | #include <TopoDS_Shape.hxx> |
27 | #include <Standard_Integer.hxx> |
28 | #include <Standard_Boolean.hxx> |
42cf5bc1 |
29 | class BRepMAT2d_Explorer; |
30 | class BRepMAT2d_BisectingLocus; |
42cf5bc1 |
31 | class MAT_BasicElt; |
32 | class TopoDS_Wire; |
33 | |
34 | |
4551e1be |
35 | //! Constructs links between the Wire or the Face of the explorer and |
42cf5bc1 |
36 | //! the BasicElts contained in the bisecting locus. |
37 | class BRepMAT2d_LinkTopoBilo |
38 | { |
39 | public: |
40 | |
41 | DEFINE_STANDARD_ALLOC |
42 | |
43 | |
44 | Standard_EXPORT BRepMAT2d_LinkTopoBilo(); |
45 | |
46 | //! Constructs the links Between S and BiLo. |
47 | //! |
48 | //! raises if <S> is not a face. |
49 | Standard_EXPORT BRepMAT2d_LinkTopoBilo(const BRepMAT2d_Explorer& Explo, const BRepMAT2d_BisectingLocus& BiLo); |
50 | |
51 | //! Constructs the links Between S and BiLo. |
52 | //! |
53 | //! raises if <S> is not a face or a wire. |
54 | Standard_EXPORT void Perform (const BRepMAT2d_Explorer& Explo, const BRepMAT2d_BisectingLocus& BiLo); |
55 | |
56 | //! Initialise the Iterator on <S> |
57 | //! <S> is an edge or a vertex of the initial |
58 | //! wire or face. |
59 | //! raises if <S> is not an edge or a vertex. |
60 | Standard_EXPORT void Init (const TopoDS_Shape& S); |
61 | |
62 | //! Returns True if there is a current BasicElt. |
63 | Standard_EXPORT Standard_Boolean More(); |
64 | |
65 | //! Proceed to the next BasicElt. |
66 | Standard_EXPORT void Next(); |
67 | |
68 | //! Returns the current BasicElt. |
69 | Standard_EXPORT Handle(MAT_BasicElt) Value() const; |
70 | |
71 | //! Returns the Shape linked to <aBE>. |
72 | Standard_EXPORT TopoDS_Shape GeneratingShape (const Handle(MAT_BasicElt)& aBE) const; |
73 | |
74 | |
75 | |
76 | |
77 | protected: |
78 | |
79 | |
80 | |
81 | |
82 | |
83 | private: |
84 | |
85 | |
86 | Standard_EXPORT void LinkToWire (const TopoDS_Wire& W, const BRepMAT2d_Explorer& Explo, const Standard_Integer IndexContour, const BRepMAT2d_BisectingLocus& BiLo); |
87 | |
88 | |
89 | BRepMAT2d_DataMapOfShapeSequenceOfBasicElt myMap; |
90 | BRepMAT2d_DataMapOfBasicEltShape myBEShape; |
91 | TopoDS_Shape myKey; |
92 | Standard_Integer current; |
93 | Standard_Boolean isEmpty; |
94 | |
95 | |
96 | }; |
97 | |
98 | |
99 | |
100 | |
101 | |
102 | |
103 | |
104 | #endif // _BRepMAT2d_LinkTopoBilo_HeaderFile |