0031642: Visualization - crash in Graphic3d_Structure::SetVisual() on redisplaying...
[occt.git] / src / BRepBuilderAPI / BRepBuilderAPI_MakeShape.cxx
1 // Created on: 1993-07-23
2 // Created by: Remi LEQUETTE
3 // Copyright (c) 1993-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
18 #include <BRepBuilderAPI_MakeShape.hxx>
19 #include <StdFail_NotDone.hxx>
20 #include <TopoDS.hxx>
21 #include <TopoDS_Edge.hxx>
22 #include <TopoDS_Face.hxx>
23 #include <TopoDS_Shape.hxx>
24 #include <TopoDS_Vertex.hxx>
25
26 //=======================================================================
27 //function : BRepBuilderAPI_MakeShape
28 //purpose  : 
29 //=======================================================================
30 BRepBuilderAPI_MakeShape::BRepBuilderAPI_MakeShape()
31 {
32 }
33
34 //=======================================================================
35 //function : Build
36 //purpose  : 
37 //=======================================================================
38
39 void BRepBuilderAPI_MakeShape::Build()
40 {
41 }
42
43 //=======================================================================
44 //function : Shape
45 //purpose  : 
46 //=======================================================================
47
48 const TopoDS_Shape&  BRepBuilderAPI_MakeShape::Shape()
49 {
50   if (!IsDone()) {
51     // the following is const cast away
52     ((BRepBuilderAPI_MakeShape*) (void*) this)->Build();
53     Check();
54   }
55   return myShape;
56 }
57
58
59 //=======================================================================
60 //function : operator
61 //purpose  : 
62 //=======================================================================
63
64 BRepBuilderAPI_MakeShape::operator TopoDS_Shape()
65 {
66   return Shape();
67 }
68
69
70 //=======================================================================
71 //function : Generated
72 //purpose  : 
73 //=======================================================================
74
75 const TopTools_ListOfShape& BRepBuilderAPI_MakeShape::Generated (const TopoDS_Shape&) 
76
77 {
78   myGenerated.Clear();
79   return myGenerated;
80 }
81
82
83 //=======================================================================
84 //function : Modified
85 //purpose  : 
86 //=======================================================================
87
88 const TopTools_ListOfShape& BRepBuilderAPI_MakeShape::Modified (const TopoDS_Shape&) 
89
90 {
91   myGenerated.Clear();
92   return myGenerated;
93 }
94
95
96 //=======================================================================
97 //function : IsDeleted
98 //purpose  : 
99 //=======================================================================
100
101 Standard_Boolean BRepBuilderAPI_MakeShape::IsDeleted (const TopoDS_Shape&) 
102
103 {
104   return Standard_False;
105 }
106
107
108
109