Salome HOME
Issue #1865 : initial implementation of fields results and high level API
[modules/shaper.git] / src / Model / Model_ResultField.h
1 // Copyright (C) 2014-20xx CEA/DEN, EDF R&D
2
3 // File:        Model_ResultField.h
4 // Created:     16 Nov 2016
5 // Author:      Mikhail PONIKAROV
6
7 #ifndef Model_ResultField_H_
8 #define Model_ResultField_H_
9
10 #include "Model.h"
11 #include <ModelAPI_ResultField.h>
12
13 /**\class Model_ResultField
14  * \ingroup DataModel
15  * \brief The fields result.
16  *
17  * Provides a compound of selected elements, without storage, one the fly.
18  */
19 class Model_ResultField : public ModelAPI_ResultField
20 {
21   std::shared_ptr<ModelAPI_Data> myOwnerData;  ///< data of owner of this result
22 public:
23
24   /// Retuns the parameters of color definition in the resources config manager
25   MODEL_EXPORT virtual void colorConfigInfo(std::string& theSection, std::string& theName,
26                                             std::string& theDefault);
27
28   /// Returns the compound of selected entities
29   MODEL_EXPORT virtual std::shared_ptr<GeomAPI_Shape> shape();
30
31   /// Removes the stored builders
32   MODEL_EXPORT virtual ~Model_ResultField() {}
33
34 protected:
35   /// Makes a body on the given feature data
36   Model_ResultField(std::shared_ptr<ModelAPI_Data> theOwnerData);
37
38   friend class Model_Objects;
39 };
40
41 #endif