Salome HOME
Image composing.
[modules/hydro.git] / src / HYDROGUI / HYDROGUI_DataObject.h
index 4e92dfffa3fad5688fb8211c7c65061314c7584b..cad33c21f52db026d1538411557e3b06322a3c23 100644 (file)
@@ -23,8 +23,6 @@
 #ifndef HYDROGUI_DATAOBJECT_H
 #define HYDROGUI_DATAOBJECT_H
 
-#include "HYDROGUI.h"
-
 #include <HYDROData_Object.h>
 
 #include <LightApp_DataObject.h>
@@ -74,15 +72,17 @@ public:
   void setObject( Handle(HYDROData_Object) theObject ) { myData = theObject; }
 
   /**
-   * Returns \a HYDROGUI_DataObject by the entry string of this object.
-   * \returns NULL if this is not HYDRO entry, or cannot cast to HYDROGUI_DataObject
+   * Returns the entry prefix for all HYDRO data objects.
+   */
+  static QString entryPrefix() { return QString( "HYDRO_" ); }
+
+  /**
+   * Returns the full entry for the specified data object.
    */
-  static HYDROGUI_DataObject* objectByEntry( const QString& theEntry );
+  static QString dataObjectEntry( const Handle(HYDROData_Object)& theObject );
 
 protected:
   Handle(HYDROData_Object) myData; ///< object from data model
-  QString myEntry; ///< optimization: store generated entry to return it quickly
-  int myStudyId; ///< the study identifier: check an object validity in the corresponded document
 };
 
 /**
@@ -115,13 +115,6 @@ public:
    */
   virtual QString name() const;
 
-  /**
-   * Returns name of the named object that is identified by this entry.
-   * \param theEntry entry of the object (used for selection identification).
-   * \returns name of the object, or empty string if it is not HYDRO named object
-   */
-  static QString nameByEntry( const QString& theEntry );
-
 private:
   QString myName; ///< name in the OB
 };