Salome HOME
lots 3,8
[modules/hydro.git] / src / HYDROData / HYDROData_Entity.h
index ddd2ae8a831f04b080ebd8dcb1725dd5e6d3362b..f55fa33acf5ecbc56ec86ecb009dceea6cc8e6c2 100644 (file)
@@ -25,7 +25,7 @@
 #include <QMap>
 #include <QString>
 #include <Standard_Type.hxx>
-
+#include <MMgt_TShared.hxx>
 
 #ifdef NONLS
 #undef NONLS
@@ -76,7 +76,8 @@ const ObjectKind KIND_LAND_COVER_OBSOLETE = 27;
 const ObjectKind KIND_CHANNEL_ALTITUDE    = 28;
 const ObjectKind KIND_LAND_COVER_MAP      = 29;
 const ObjectKind KIND_DTM                 = 30;
-const ObjectKind KIND_LAST                = KIND_DTM;
+const ObjectKind KIND_BC_POLYGON          = 31;
+const ObjectKind KIND_LAST                = KIND_BC_POLYGON+1;
 
 class MapOfTreatedObjects : public QMap<QString,Handle(Standard_Transient)>
 {
@@ -130,6 +131,9 @@ public:
 public:
   DEFINE_STANDARD_RTTIEXT(HYDROData_Entity, MMgt_TShared);
 
+  HYDRODATA_EXPORT static QString Type( ObjectKind );
+  HYDRODATA_EXPORT virtual QString GetType() const;
+
   /**
    * Returns the kind of this object. Must be redefined in all objects of known type.
    */
@@ -292,6 +296,14 @@ public:
    * \param theDefColor default color to return if attribute has not been set before
    */
   HYDRODATA_EXPORT QColor GetColor( const QColor& theDefColor, const int theTag = 0 ) const;
+
+  /* Internal method that used to retreive the color attribute
+    * \param theTag tag of a label that keeps the attribute (for 0 this is myLab)
+   * \param theOutColor color to return if attribute has been set before
+   * \return true if attribute is present
+   */
+  HYDRODATA_EXPORT bool GetColor( QColor& theOutColor,
+                                  const int     theTag ) const;
  
 protected: