1 // Created on: 1996-12-16
2 // Created by: Remi Lequette
3 // Copyright (c) 1996-1999 Matra Datavision
4 // Copyright (c) 1999-2014 OPEN CASCADE SAS
6 // This file is part of Open CASCADE Technology software library.
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.
14 // Alternatively, this file may be used under the terms of Open CASCADE
15 // commercial license or contractual agreement.
17 #ifndef _TNaming_Builder_HeaderFile
18 #define _TNaming_Builder_HeaderFile
20 #include <Standard.hxx>
21 #include <Standard_DefineAlloc.hxx>
22 #include <Standard_Handle.hxx>
24 class TNaming_UsedShapes;
25 class TNaming_NamedShape;
26 class Standard_ConstructionError;
31 //! A tool to create and maintain topological attributes.
32 //! Constructor creates an empty
33 //! TNaming_NamedShape attribute at the given
34 //! label. It allows adding "old shape" and "new
35 //! shape" pairs with the specified evolution to this
36 //! named shape. One evolution type per one
37 //! builder must be used.
45 //! Create an Builder.
46 //! Warning: Before Addition copies the current Value, and clear
47 Standard_EXPORT TNaming_Builder(const TDF_Label& aLabel);
49 //! Records the shape newShape which was
50 //! generated during a topological construction.
51 //! As an example, consider the case of a face
52 //! generated in construction of a box.
53 Standard_EXPORT void Generated (const TopoDS_Shape& newShape);
55 //! Records the shape newShape which was
56 //! generated from the shape oldShape during a topological construction.
57 //! As an example, consider the case of a face
58 //! generated from an edge in construction of a prism.
59 Standard_EXPORT void Generated (const TopoDS_Shape& oldShape, const TopoDS_Shape& newShape);
61 //! Records the shape oldShape which was deleted from the current label.
62 //! As an example, consider the case of a face removed by a Boolean operation.
63 Standard_EXPORT void Delete (const TopoDS_Shape& oldShape);
65 //! Records the shape newShape which is a
66 //! modification of the shape oldShape.
67 //! As an example, consider the case of a face split
68 //! or merged in a Boolean operation.
69 Standard_EXPORT void Modify (const TopoDS_Shape& oldShape, const TopoDS_Shape& newShape);
71 //! Add a Shape to the current label , This Shape is
72 //! unmodified. Used for example to define a set
73 //! of shapes under a label.
74 Standard_EXPORT void Select (const TopoDS_Shape& aShape, const TopoDS_Shape& inShape);
76 //! Returns the NamedShape which has been built or is under construction.
77 Standard_EXPORT Handle(TNaming_NamedShape) NamedShape() const;
92 Handle(TNaming_UsedShapes) myShapes;
93 Handle(TNaming_NamedShape) myAtt;
104 #endif // _TNaming_Builder_HeaderFile