Salome HOME
Bug #487: dump/load script - problem with obstacle.
[modules/hydro.git] / src / HYDROData / HYDROData_VisualState.h
1
2 #ifndef HYDROData_VisualState_HeaderFile
3 #define HYDROData_VisualState_HeaderFile
4
5 #include <HYDROData_Entity.h>
6
7 DEFINE_STANDARD_HANDLE(HYDROData_VisualState, HYDROData_Entity)
8
9 /**\class HYDROData_VisualState
10  * \brief Class that stores/retreives information about the visual state.
11  *
12  * Keeps the visual state as encoded text string.
13  */
14 class HYDROData_VisualState : public HYDROData_Entity
15 {
16 protected:
17   /**
18    * Enumeration of tags corresponding to the persistent object parameters.
19    */
20   enum DataTag
21   {
22     DataTag_First = HYDROData_Entity::DataTag_First + 100, ///< first tag, to reserve
23     DataTag_State ///< encoded visual state
24   };
25
26 public:
27   DEFINE_STANDARD_RTTI(HYDROData_VisualState);
28
29   /**
30    * Returns the kind of this object. Must be redefined in all objects of known type.
31    */
32   HYDRODATA_EXPORT virtual const ObjectKind GetKind() const { return KIND_VISUAL_STATE; }
33
34   /**
35    * Stores the encoded visual state
36    * \param theState new state
37    */
38   HYDRODATA_EXPORT void SetState( const std::string& theState );
39
40   /**
41    * Returns the encoded visual state
42    */
43   HYDRODATA_EXPORT std::string GetState() const;
44
45 protected:
46
47   friend class HYDROData_Iterator;
48
49   /**
50    * Creates new object in the internal data structure. Use higher level objects 
51    * to create objects with real content.
52    */
53   HYDROData_VisualState();
54
55   /**
56    * Destructs properties of the object and object itself, removes it from the document.
57    */
58   ~HYDROData_VisualState();
59
60 };
61
62 #endif