Salome HOME
Merge branch 'BR_PYTHON_PLUGIN' of newgeom:newgeom.git into Dev_0.6.1
[modules/shaper.git] / src / ModelAPI / ModelAPI_Result.h
1 // Copyright (C) 2014-20xx CEA/DEN, EDF R&D
2
3 // File:        ModelAPI_Result.hxx
4 // Created:     07 Jul 2014
5 // Author:      Mikhail PONIKAROV
6
7 #ifndef ModelAPI_Result_H_
8 #define ModelAPI_Result_H_
9
10 #include "ModelAPI_Object.h"
11 #include <GeomAPI_Shape.h>
12
13 class ModelAPI_Feature;
14
15 /**\class ModelAPI_Result
16  * \ingroup DataModel
17  * \brief The result of a feature.
18  *
19  * A generic class that .
20  */
21 class ModelAPI_Result : public ModelAPI_Object
22 {
23   bool myIsConcealed; ///< the result is concealed from the data tree (referenced by other objects)
24  public:
25    /// Returns true if the result is concealed from the data tree (referenced by other objects)
26   inline bool isConcealed() {return myIsConcealed;}
27
28   /// Returns true if the result is concealed from the data tree (referenced by other objects)
29   inline void setIsConcealed(const bool theValue) {myIsConcealed = theValue;}
30
31   /// To virtually destroy the fields of successors
32   virtual ~ModelAPI_Result()
33   {
34   }
35
36   /// Returns the shape-result produced by this feature (or null if no shapes)
37   virtual std::shared_ptr<GeomAPI_Shape> shape() {return std::shared_ptr<GeomAPI_Shape>();}
38 };
39
40 //! Pointer on feature object
41 typedef std::shared_ptr<ModelAPI_Result> ResultPtr;
42
43 #endif