417051e95e31c41121ed763153613cdcf6a025c5
[occt.git] / src / MAT / MAT_ListOfBisector.hxx
1 // Created on: 1992-09-22
2 // Created by: Gilles DEBARBOUILLE
3 // Copyright (c) 1992-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 _MAT_ListOfBisector_HeaderFile
18 #define _MAT_ListOfBisector_HeaderFile
19
20 #include <Standard.hxx>
21 #include <Standard_Type.hxx>
22
23 #include <Standard_Integer.hxx>
24 #include <Standard_Transient.hxx>
25 #include <Standard_Boolean.hxx>
26 class MAT_TListNodeOfListOfBisector;
27 class MAT_Bisector;
28
29
30 class MAT_ListOfBisector;
31 DEFINE_STANDARD_HANDLE(MAT_ListOfBisector, Standard_Transient)
32
33
34 class MAT_ListOfBisector : public Standard_Transient
35 {
36
37 public:
38
39   
40   Standard_EXPORT MAT_ListOfBisector();
41   
42   Standard_EXPORT void First();
43   
44   Standard_EXPORT void Last();
45   
46   Standard_EXPORT void Init (const Handle(MAT_Bisector)& aniten);
47   
48   Standard_EXPORT void Next();
49   
50   Standard_EXPORT void Previous();
51   
52   Standard_EXPORT Standard_Boolean More() const;
53   
54   Standard_EXPORT Handle(MAT_Bisector) Current() const;
55   
56   Standard_EXPORT void Current (const Handle(MAT_Bisector)& anitem) const;
57   
58   Standard_EXPORT Handle(MAT_Bisector) FirstItem() const;
59   
60   Standard_EXPORT Handle(MAT_Bisector) LastItem() const;
61   
62   Standard_EXPORT Handle(MAT_Bisector) PreviousItem() const;
63   
64   Standard_EXPORT Handle(MAT_Bisector) NextItem() const;
65   
66     Standard_Integer Number() const;
67   
68     Standard_Integer Index() const;
69   
70   Standard_EXPORT Handle(MAT_Bisector) Brackets (const Standard_Integer anindex);
71 Handle(MAT_Bisector) operator() (const Standard_Integer anindex)
72 {
73   return Brackets(anindex);
74 }
75   
76   Standard_EXPORT void Unlink();
77   
78   Standard_EXPORT void LinkBefore (const Handle(MAT_Bisector)& anitem);
79   
80   Standard_EXPORT void LinkAfter (const Handle(MAT_Bisector)& anitem);
81   
82   Standard_EXPORT void FrontAdd (const Handle(MAT_Bisector)& anitem);
83   
84   Standard_EXPORT void BackAdd (const Handle(MAT_Bisector)& anitem);
85   
86   Standard_EXPORT void Permute();
87   
88   Standard_EXPORT void Loop() const;
89   
90   Standard_EXPORT Standard_Boolean IsEmpty() const;
91   
92   Standard_EXPORT void Dump (const Standard_Integer ashift, const Standard_Integer alevel);
93
94
95
96
97   DEFINE_STANDARD_RTTI_INLINE(MAT_ListOfBisector,Standard_Transient)
98
99 protected:
100
101
102
103
104 private:
105
106
107   Handle(MAT_TListNodeOfListOfBisector) thefirstnode;
108   Handle(MAT_TListNodeOfListOfBisector) thelastnode;
109   Handle(MAT_TListNodeOfListOfBisector) thecurrentnode;
110   Standard_Integer thecurrentindex;
111   Standard_Integer thenumberofitems;
112
113
114 };
115
116 #define Item Handle(MAT_Bisector)
117 #define Item_hxx <MAT_Bisector.hxx>
118 #define MAT_TListNode MAT_TListNodeOfListOfBisector
119 #define MAT_TListNode_hxx <MAT_TListNodeOfListOfBisector.hxx>
120 #define Handle_MAT_TListNode Handle(MAT_TListNodeOfListOfBisector)
121 #define MAT_TList MAT_ListOfBisector
122 #define MAT_TList_hxx <MAT_ListOfBisector.hxx>
123 #define Handle_MAT_TList Handle(MAT_ListOfBisector)
124
125 #include <MAT_TList.lxx>
126
127 #undef Item
128 #undef Item_hxx
129 #undef MAT_TListNode
130 #undef MAT_TListNode_hxx
131 #undef Handle_MAT_TListNode
132 #undef MAT_TList
133 #undef MAT_TList_hxx
134 #undef Handle_MAT_TList
135
136
137
138
139 #endif // _MAT_ListOfBisector_HeaderFile