b311480e |
1 | // Created on: 1993-03-23 |
2 | // Created by: Jean Yves LEBEY |
3 | // Copyright (c) 1993-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 | |
42cf5bc1 |
17 | |
42cf5bc1 |
18 | #include <TopOpeBRepBuild_LoopSet.hxx> |
7fd59977 |
19 | |
20 | //======================================================================= |
21 | //function : TopOpeBRepBuild_LoopSet |
22 | //purpose : |
23 | //======================================================================= |
7fd59977 |
24 | TopOpeBRepBuild_LoopSet::TopOpeBRepBuild_LoopSet() : |
25 | myLoopIndex(1), myNbLoop(0) |
26 | { |
27 | } |
28 | |
e6f550da |
29 | TopOpeBRepBuild_LoopSet::~TopOpeBRepBuild_LoopSet() |
7fd59977 |
30 | {} |
31 | |
32 | //======================================================================= |
33 | //function : InitLoop |
34 | //purpose : |
35 | //======================================================================= |
36 | |
37 | void TopOpeBRepBuild_LoopSet::InitLoop() |
38 | { |
39 | myLoopIterator.Initialize(myListOfLoop); |
40 | myLoopIndex = 1; myNbLoop = myListOfLoop.Extent(); |
41 | } |
42 | |
43 | //======================================================================= |
44 | //function : MoreLoop |
45 | //purpose : |
46 | //======================================================================= |
47 | |
48 | Standard_Boolean TopOpeBRepBuild_LoopSet::MoreLoop() const |
49 | { |
50 | Standard_Boolean b = myLoopIterator.More(); |
51 | return b; |
52 | } |
53 | |
54 | //======================================================================= |
55 | //function : NextLoop |
56 | //purpose : |
57 | //======================================================================= |
58 | |
59 | void TopOpeBRepBuild_LoopSet::NextLoop() |
60 | { |
61 | myLoopIndex++; |
62 | myLoopIterator.Next(); |
63 | } |
64 | |
65 | //======================================================================= |
66 | //function : Loop |
67 | //purpose : |
68 | //======================================================================= |
69 | |
4796758e |
70 | Handle(TopOpeBRepBuild_Loop) TopOpeBRepBuild_LoopSet::Loop() const |
7fd59977 |
71 | { |
72 | const Handle(TopOpeBRepBuild_Loop)& L = myLoopIterator.Value(); |
73 | return L; |
74 | } |
75 | |
76 | |
77 | //======================================================================= |
78 | //function : ChangeListOfLoop |
79 | //purpose : |
80 | //======================================================================= |
81 | |
82 | TopOpeBRepBuild_ListOfLoop& TopOpeBRepBuild_LoopSet::ChangeListOfLoop() |
83 | { |
84 | return myListOfLoop; |
85 | } |