]> SALOME platform Git repositories - modules/shaper.git/blob - src/ModelAPI/ModelAPI_ResultConstruction.h
Salome HOME
1092c4a9c1f20124ae9a2471dd40bf72e2bb0a65
[modules/shaper.git] / src / ModelAPI / ModelAPI_ResultConstruction.h
1 // Copyright (C) 2014-20xx CEA/DEN, EDF R&D
2
3 // File:        ModelAPI_ResultConstruction.h
4 // Created:     07 Jul 2014
5 // Author:      Mikhail PONIKAROV
6
7 #ifndef ModelAPI_ResultConstruction_H_
8 #define ModelAPI_ResultConstruction_H_
9
10 #include "ModelAPI_Result.h"
11 #include <GeomAPI_Shape.h>
12
13 #include <string>
14
15 /**\class ModelAPI_ResultConstruction
16  * \ingroup DataModel
17  * \brief The construction element result of a feature.
18  *
19  * Provides a shape that may be displayed in the viewer.
20  * Intermediate, light result that in many cases produces a result on the fly.
21  */
22 class ModelAPI_ResultConstruction : public ModelAPI_Result
23 {
24  public:
25   /// Returns the group identifier of this result
26   virtual std::string groupName()
27   {
28     return group();
29   }
30
31   /// Returns the group identifier of this result
32   static std::string group()
33   {
34     static std::string MY_GROUP = "Construction";
35     return MY_GROUP;
36   }
37
38   /// Sets the result
39   virtual void setShape(std::shared_ptr<GeomAPI_Shape> theShape) = 0;
40
41   /// Sets the flag that it must be displayed in history (default is true)
42   virtual void setIsInHistory(const bool isInHistory) = 0;
43 };
44
45 //! Pointer on feature object
46 typedef std::shared_ptr<ModelAPI_ResultConstruction> ResultConstructionPtr;
47
48 #endif