Salome HOME
Prepare version 1.2.1: quick fix for iteration 2 release
[modules/shaper.git] / src / Model / Model_Data.h
index 10464cabdba9c7b620c0197f3c91a4186d1773cf..38733fb7209708d3b9a2147d3c00dd46821df3ac 100644 (file)
@@ -56,8 +56,6 @@ class Model_Data : public ModelAPI_Data
   /// flag that may block the "attribute updated" sending
   bool mySendAttributeUpdated;
 
-  Model_Data();
-
   /// Returns label of this feature
   TDF_Label label()
   {
@@ -73,6 +71,8 @@ class Model_Data : public ModelAPI_Data
   friend class Model_AttributeSelection;
 
  public:
+  /// The simplest constructor. "setLabel" must be called just after to initialize correctly.
+  Model_Data();
   /// Returns the name of the feature visible by the user in the object browser
   MODEL_EXPORT virtual std::string name();
   /// Defines the name of the feature visible by the user in the object browser
@@ -186,6 +186,12 @@ class Model_Data : public ModelAPI_Data
   /// Copies all atributes content into theTarget data
   MODEL_EXPORT virtual void copyTo(std::shared_ptr<ModelAPI_Data> theTarget);
 
+  /// Returns the invalid data pointer (to avoid working with NULL shared ptrs in swig)
+  MODEL_EXPORT virtual std::shared_ptr<ModelAPI_Data> invalidPtr();
+
+  /// Returns the invalid data pointer: static method
+  static std::shared_ptr<ModelAPI_Data> invalidData();
+
 protected:
   /// Returns true if "is in history" custom behaviors is defined for the feature
   MODEL_EXPORT virtual bool isInHistory();