Xcos MVC: implement clone / delete on the Model side
[scilab.git] / scilab / modules / scicos / src / cpp / view_scilab / DiagramAdapter.hxx
index 6c5529e..028eea8 100644 (file)
@@ -6,7 +6,7 @@
  *  This source file is licensed as described in the file COPYING, which
  *  you should have received as part of this distribution.  The terms
  *  are also available at
- *  http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
+ *  http://www.cecill.info/licences/Licence_CeCILL_V2.1-en.txt
  *
  */
 
 #define DIAGRAMADAPTER_HXX_
 
 #include <string>
-#include <sstream>
 
+#include "utilities.hxx"
 #include "BaseAdapter.hxx"
-
 #include "model/Diagram.hxx"
 
 namespace org_scilab_modules_scicos
@@ -28,21 +27,25 @@ namespace view_scilab
 class DiagramAdapter : public BaseAdapter<DiagramAdapter, org_scilab_modules_scicos::model::Diagram>
 {
 public:
-    DiagramAdapter(const DiagramAdapter& o);
-    DiagramAdapter(org_scilab_modules_scicos::model::Diagram* o);
+    DiagramAdapter(bool ownAdaptee, org_scilab_modules_scicos::model::Diagram* adaptee);
     ~DiagramAdapter();
 
     static const std::wstring getSharedTypeStr()
     {
-        return L"Diagram";
+        return L"diagram";
     }
 
-    bool toString(std::wostringstream& ostr);
     std::wstring getTypeStr();
     std::wstring getShortTypeStr();
+
+    types::InternalType* getContribContent() const;
+    void setContribContent(types::InternalType* v);
+
+private:
+    types::InternalType* contrib_content;
 };
 
-} /* view_scilab */
+} /* namespace view_scilab */
 } /* namespace org_scilab_modules_scicos */
 
 #endif /* MODELADAPTER_HXX_ */