20 #ifndef ModelAPI_BodyBuilder_H_
21 #define ModelAPI_BodyBuilder_H_
24 #include <GeomAPI_Shape.h>
25 #include <GeomAlgoAPI_MakeShape.h>
26 #include <GeomAPI_DataMapOfShapeShape.h>
44 virtual void store(
const GeomShapePtr& theShape,
45 const bool theIsStoreSameShapes =
true) = 0;
49 const GeomShapePtr& theToShape,
50 const bool theIsCleanStored =
true) = 0;
54 const GeomShapePtr& theToShape,
const std::shared_ptr<GeomAlgoAPI_MakeShape> theMakeShape) = 0;
58 const GeomShapePtr& theNewShape,
59 const bool theIsCleanStored =
true) = 0;
63 const GeomShapePtr& theNewShape,
const std::shared_ptr<GeomAlgoAPI_MakeShape> theMakeShape)=0;
66 virtual GeomShapePtr
shape() = 0;
71 virtual bool generated(
const GeomShapePtr& theNewShape,
72 const std::string& theName,
const bool theCheckIsInResult =
true) = 0;
77 virtual void generated(
const GeomShapePtr& theOldShape,
78 const GeomShapePtr& theNewShape,
79 const std::string& theName =
"") = 0;
83 virtual void modified(
const GeomShapePtr& theOldShape,
84 const GeomShapePtr& theNewShape,
85 const std::string& theName =
"") = 0;
89 const GeomShapePtr& theOldShape,
91 const GeomShapePtr& theShapesToAvoid = GeomShapePtr()) = 0;
95 const GeomShapePtr& theOldShape,
97 const std::string& theName =
"") = 0;
101 const GeomShapePtr& theOldShape,
103 const std::string& theName =
"",
104 const bool theSaveOldIfNotInTree =
false) = 0;
108 const std::string& theName) = 0;
115 MODELAPI_EXPORT
virtual std::shared_ptr<ModelAPI_Data>
data()
const;
118 MODELAPI_EXPORT
virtual std::shared_ptr<ModelAPI_Document>
document()
const;
128 typedef std::shared_ptr<ModelAPI_BodyBuilder> BodyBuilderPtr;
ShapeType
Shape type enum.
Definition: GeomAPI_Shape.h:46
Extra API for the ResultBody that allows to work with naming.
Definition: ModelAPI_BodyBuilder.h:39
virtual void loadFirstLevel(GeomShapePtr theShape, const std::string &theName)=0
load shapes of the first level (to be used during shape import)
virtual bool generated(const GeomShapePtr &theNewShape, const std::string &theName, const bool theCheckIsInResult=true)=0
Records the subshape newShape which was generated during a topological construction.
virtual GeomShapePtr shape()=0
Returns the shape-result produced by this feature.
virtual void storeGenerated(const GeomShapePtr &theFromShape, const GeomShapePtr &theToShape, const bool theIsCleanStored=true)=0
Stores the generated shape (called by the execution method).
virtual void loadDeletedShapes(const GeomMakeShapePtr &theAlgo, const GeomShapePtr &theOldShape, const GeomAPI_Shape::ShapeType theShapeTypeToExplore, const GeomShapePtr &theShapesToAvoid=GeomShapePtr())=0
load deleted shapes
ModelAPI_Object * myOwner
the owner object this builder belongs to
Definition: ModelAPI_BodyBuilder.h:124
virtual void storeGenerated(const std::list< GeomShapePtr > &theFromShapes, const GeomShapePtr &theToShape, const std::shared_ptr< GeomAlgoAPI_MakeShape > theMakeShape)=0
Stores the root generated shapes (called by the execution method).
virtual MODELAPI_EXPORT std::shared_ptr< ModelAPI_Data > data() const
Returns the data manager of this object: attributes.
Definition: ModelAPI_BodyBuilder.cpp:28
virtual void loadModifiedShapes(const GeomMakeShapePtr &theAlgo, const GeomShapePtr &theOldShape, const GeomAPI_Shape::ShapeType theShapeTypeToExplore, const std::string &theName="")=0
load and orient modified shapes
virtual void modified(const GeomShapePtr &theOldShape, const GeomShapePtr &theNewShape, const std::string &theName="")=0
Records the shape newShape which is a modification of the shape oldShape.
virtual void storeModified(const std::list< GeomShapePtr > &theOldShapes, const GeomShapePtr &theNewShape, const std::shared_ptr< GeomAlgoAPI_MakeShape > theMakeShape)=0
Stores the root modified shapes (called by the execution method).
virtual void store(const GeomShapePtr &theShape, const bool theIsStoreSameShapes=true)=0
Stores the shape (called by the execution method).
virtual MODELAPI_EXPORT void cleanCash()=0
Cleans cash related to the already stored elements.
virtual MODELAPI_EXPORT std::shared_ptr< ModelAPI_Document > document() const
Returns document this feature belongs to.
Definition: ModelAPI_BodyBuilder.cpp:33
virtual void storeModified(const GeomShapePtr &theOldShape, const GeomShapePtr &theNewShape, const bool theIsCleanStored=true)=0
Stores the modified shape (called by the execution method).
MODELAPI_EXPORT ModelAPI_BodyBuilder(ModelAPI_Object *theOwner)
Default constructor accessible only from Model_Object.
Definition: ModelAPI_BodyBuilder.cpp:23
virtual void loadGeneratedShapes(const GeomMakeShapePtr &theAlgo, const GeomShapePtr &theOldShape, const GeomAPI_Shape::ShapeType theShapeTypeToExplore, const std::string &theName="", const bool theSaveOldIfNotInTree=false)=0
load and orient generated shapes
virtual void generated(const GeomShapePtr &theOldShape, const GeomShapePtr &theNewShape, const std::string &theName="")=0
Records the shape newShape which was generated from the shape oldShape during a topological construct...
General object of the application that allows to get/set attributes from the document and compute res...
Definition: ModelAPI_Data.h:72
Document for internal data structure of any object storage.
Definition: ModelAPI_Document.h:52
Represents any object in the data model and in the object browser.
Definition: ModelAPI_Object.h:45