2 #ifndef HYDROData_Region_HeaderFile
3 #define HYDROData_Region_HeaderFile
5 #include "HYDROData_Entity.h"
8 DEFINE_STANDARD_HANDLE(HYDROData_Region, HYDROData_Entity)
10 class Handle(HYDROData_Zone);
12 /**\class HYDROData_Region
13 * \brief Regions are groups (lists) of zones, they can include one or several zones.
15 class HYDROData_Region : public HYDROData_Entity
21 * Enumeration of tags corresponding to the persistent object parameters.
25 DataTag_First = HYDROData_Entity::DataTag_First + 100, ///< first tag, to reserve
26 DataTag_Zone, ///< reference zones
30 * Enumeration of tags corresponding to the child sub-objects of object.
34 ChildTag_First = HYDROData_Entity::ChildTag_First + 100, ///< first tag, to reserve
35 ChildTag_Zone ///< child zones
39 DEFINE_STANDARD_RTTI(HYDROData_Region);
42 * Returns the kind of this object. Must be redefined in all objects of known type.
44 HYDRODATA_EXPORT virtual const ObjectKind GetKind() const { return KIND_REGION; }
47 * Dump object to Python script representation.
49 HYDRODATA_EXPORT virtual QStringList DumpToPython( MapOfTreatedObjects& theTreatedObjects ) const;
53 * Add new one reference zone for region.
54 * The label of theZone is changed in case if old parent is not this region.
56 HYDRODATA_EXPORT virtual bool AddZone( const Handle(HYDROData_Zone)& theZone );
59 * Returns all reference zone of region.
61 HYDRODATA_EXPORT virtual HYDROData_SequenceOfObjects GetZones() const;
64 * Removes reference zone from region.
66 HYDRODATA_EXPORT virtual void RemoveZone( const Handle(HYDROData_Zone)& theZone );
69 * Removes all reference zones from region.
71 HYDRODATA_EXPORT virtual void RemoveZones();
77 * Create new one reference zone for region on child label.
78 * The new zone is added into the list of reference zones.
80 HYDRODATA_EXPORT virtual Handle(HYDROData_Zone) addNewZone();
84 friend class HYDROData_Calculation;
85 friend class HYDROData_Iterator;
88 * Creates new object in the internal data structure. Use higher level objects
89 * to create objects with real content.
94 * Destructs properties of the object and object itself, removes it from the document.