Salome HOME
Dump to Python script correction.
[modules/hydro.git] / src / HYDROData / HYDROData_Calculation.h
index 1f9a7716d1d0f3abbdaedb229cf05d0d8c3496e4..60acfb8d33286078d6735e5b3b1d54d77f42ab18 100644 (file)
@@ -1,23 +1,21 @@
 
-#ifndef HYDROData_HYDROData_Calculation
-#define HYDROData_HYDROData_Calculation
 
-#include <HYDROData_Object.h>
+#ifndef HYDROData_Calculation_HeaderFile
+#define HYDROData_Calculation_HeaderFile
 
-class gp_XY;
-class gp_XYZ;
-class QPointF;
-class QFile;
+#include <HYDROData_Entity.h>
 
-DEFINE_STANDARD_HANDLE(HYDROData_Calculation, HYDROData_Object)
+class Handle(HYDROData_Object);
+class Handle(HYDROData_Region);
+
+DEFINE_STANDARD_HANDLE(HYDROData_Calculation, HYDROData_Entity)
 
 
 /**\class HYDROData_Calculation
- * \brief Class that stores/retreives information about the Calculation case.
+ * \brief Calculation case is defined by selection of Geometry objects with or without \93Zone of water\94.
  *
- * Calculation case is defined by selection of Geometry objects with or without \93Zone of water\94
  */
-class HYDROData_Calculation : public HYDROData_Object
+class HYDROData_Calculation : public HYDROData_Entity
 {
 
 protected:
@@ -27,7 +25,18 @@ protected:
    */
   enum DataTag
   {
-    DataTag_First = HYDROData_Object::DataTag_First + 100, ///< first tag, to reserve
+    DataTag_First = HYDROData_Entity::DataTag_First + 100, ///< first tag, to reserve
+    DataTag_GeometryObject,   ///< reference geometry objects
+    DataTag_Region            ///< reference regions
+  };
+
+  /**
+   * Enumeration of tags corresponding to the child sub-objects of object.
+   */
+  enum ChildTag
+  {
+    ChildTag_First = HYDROData_Entity::ChildTag_First + 100, ///< first tag, to reserve
+    ChildTag_Region      ///< child regions
   };
 
 public:
@@ -48,6 +57,112 @@ public:
 public:      
   // Public methods to work with Calculation
 
+  /**
+   * Split reference geometry objects to non-intersected regions.
+   */
+  HYDRODATA_EXPORT virtual void SplitGeometryObjects();
+
+
+  /**
+   * Returns number of geometry objects for calculation case.
+   */
+  HYDRODATA_EXPORT virtual int NbGeometryObjects() const;
+
+  /**
+   * Add new one geometry object for calculation case.
+   */
+  HYDRODATA_EXPORT virtual void AddGeometryObject( const Handle(HYDROData_Object)& theObject );
+
+  /**
+   * Replace the geometry object for calculation case.
+   */
+  HYDRODATA_EXPORT virtual void SetGeometryObject( const int                       theIndex,
+                                                   const Handle(HYDROData_Object)& theObject );
+
+  /**
+   * Sets the geometry object for calculation case.
+   */
+  HYDRODATA_EXPORT virtual void SetGeometryObjects( const HYDROData_SequenceOfObjects& theObjects );
+
+  /**
+   * Returns geometry object of calculation case by index.
+   */
+  HYDRODATA_EXPORT virtual Handle(HYDROData_Object) GetGeometryObject( const int theIndex ) const;
+
+  /**
+   * Returns all geometry objects of calculation case.
+   */
+  HYDRODATA_EXPORT virtual HYDROData_SequenceOfObjects GetGeometryObjects() const;
+
+  /**
+   * Removes all geometry objects from calculation case.
+   */
+  HYDRODATA_EXPORT virtual void RemoveGeometryObjects();
+
+
+  /**
+   * Add new one region for calculation case.
+   * The new region is not added into the list of reference regions.
+   */
+  HYDRODATA_EXPORT virtual Handle(HYDROData_Region) AddNewRegion();
+
+  /**
+   * Removes all child regions from calculation case.
+   */
+  HYDRODATA_EXPORT virtual void RemoveChildRegions();
+
+
+  /**
+   * Returns number of reference regions of calculation case.
+   */
+  int NbRegions() const;
+
+  /**
+   * Add new one reference region for calculation case.
+   */
+  HYDRODATA_EXPORT virtual void AddRegion( const Handle(HYDROData_Region)& theRegion );
+
+  /**
+   * Replace the reference region for calculation case.
+   */
+  HYDRODATA_EXPORT virtual void SetRegion( const int                       theIndex,
+                                           const Handle(HYDROData_Region)& theRegion );
+
+  /**
+   * Inserts the reference region for calculation case before given index.
+   */
+  HYDRODATA_EXPORT virtual void InsertRegion( const int                       theBeforeIndex,
+                                              const Handle(HYDROData_Region)& theRegion );
+
+  /**
+   * Sets reference regions for calculation case.
+   */
+  HYDRODATA_EXPORT virtual void SetRegions( const HYDROData_SequenceOfObjects& theRegions );
+
+  /**
+   * Returns reference region of calculation case by index.
+   */
+  HYDRODATA_EXPORT virtual Handle(HYDROData_Region) GetRegion( const int theIndex ) const;
+
+  /**
+   * Returns all reference regions of calculation case.
+   */
+  HYDRODATA_EXPORT virtual HYDROData_SequenceOfObjects GetRegions() const;
+
+  /**
+   * Removes reference region from calculation case.
+   */
+  HYDRODATA_EXPORT virtual void RemoveRegion( const Handle(HYDROData_Region)& theRegion );
+
+  /**
+   * Removes reference region from calculation case by it index.
+   */
+  HYDRODATA_EXPORT virtual void RemoveRegion( const int theIndex );
+
+  /**
+   * Removes all reference regions from calculation case.
+   */
+  HYDRODATA_EXPORT virtual void RemoveRegions();
 
 protected: