1 // Copyright (C) 2014-20xx CEA/DEN, EDF R&D
3 // File: GeomAlgoAPI_MakeShape.h
4 // Created: 17 Oct 2014
5 // Author: Sergey ZARITCHNY
6 #ifndef GeomAlgoAPI_MakeShape_H_
7 #define GeomAlgoAPI_MakeShape_H_
9 #include <GeomAPI_Shape.h>
10 #include <GeomAlgoAPI.h>
15 /**\class GeomAlgoAPI_MakeShape
17 * \brief Interface to the root class of all topological shapes constructions
19 class GeomAlgoAPI_MakeShape : public GeomAPI_Interface
30 /// Constructor by the already stored builder in the interface
31 GEOMALGOAPI_EXPORT GeomAlgoAPI_MakeShape(void* theBuilder, const AlgoType theAlgoType = MakeShape);
33 /// Constructor by the builder and wire. Used for pipe builder.
34 GEOMALGOAPI_EXPORT GeomAlgoAPI_MakeShape(void* theBuilder,
35 const std::shared_ptr<GeomAPI_Shape> theWire,
36 const std::shared_ptr<GeomAPI_Shape> theBaseShape);
38 /// Returns a shape built by the shape construction algorithm
39 GEOMALGOAPI_EXPORT virtual const std::shared_ptr<GeomAPI_Shape> shape() const;
41 /// Returns the list of shapes generated from the shape \a theShape
42 GEOMALGOAPI_EXPORT virtual void generated(
43 const std::shared_ptr<GeomAPI_Shape> theShape, ListOfShape& theHistory);
45 /// Returns the list of shapes modified from the shape \a theShape
46 GEOMALGOAPI_EXPORT virtual void modified(
47 const std::shared_ptr<GeomAPI_Shape> theShape, ListOfShape& theHistory);
49 /// Returns whether the shape is deleted
50 GEOMALGOAPI_EXPORT virtual bool isDeleted(const std::shared_ptr<GeomAPI_Shape> theShape);
53 GEOMALGOAPI_EXPORT GeomAlgoAPI_MakeShape(){};
56 GeomAlgoAPI_MakeShape::AlgoType myAlgoType; ///< Type of make shape algo.
57 std::shared_ptr<GeomAPI_Shape> myShape; ///< Resulting shape.
58 std::shared_ptr<GeomAPI_Shape> myWire; ///< Wire for pipe algo.
59 std::shared_ptr<GeomAPI_Shape> myBaseShape; ///< Base shape of algo.
62 typedef std::list<std::shared_ptr<GeomAlgoAPI_MakeShape> > ListOfMakeShape;