1 // File: XGUI_ViewerPrs.h
2 // Created: 20 Apr 2014
3 // Author: Natalia ERMOLAEVA
5 #ifndef XGUI_ViewerPrs_H
6 #define XGUI_ViewerPrs_H
10 #include <boost/shared_ptr.hpp>
11 #include <TopoDS_Shape.hxx>
12 #include <SelectMgr_EntityOwner.hxx>
14 class ModelAPI_Feature;
16 /**\class XGUI_ViewerPrs
18 * \brief Presentation. Provides container to have feature, shape and/or selection owner.
20 class XGUI_EXPORT XGUI_ViewerPrs
26 /// \param theFeature a model feature
27 /// \param theShape a viewer shape
28 /// \param theOwner a selection owner
29 XGUI_ViewerPrs(boost::shared_ptr<ModelAPI_Feature> theFeature,
30 const TopoDS_Shape& theShape,
31 Handle_SelectMgr_EntityOwner theOwner);
33 virtual ~XGUI_ViewerPrs();
36 /// \param theFeature a feature instance
37 void setFeature(boost::shared_ptr<ModelAPI_Feature> theFeature);
39 /// Returns the feature.
40 /// \return a feature instance
41 boost::shared_ptr<ModelAPI_Feature> feature() const;
43 /// Returns the presentation owner
45 void setOwner(Handle_SelectMgr_EntityOwner theOwner);
47 /// Returns the presentation owner
49 Handle_SelectMgr_EntityOwner owner() const;
52 /// \param theShape a shape instance
53 void setShape(const TopoDS_Shape& theShape);
56 /// \return a shape instance
57 const TopoDS_Shape& shape() const;
60 boost::shared_ptr<ModelAPI_Feature> myFeature; /// the feature
61 Handle(SelectMgr_EntityOwner) myOwner; /// the selection owner
62 TopoDS_Shape myShape; /// the shape