Salome HOME
[EDF27816] Management of double foreach and management of proxyfile lifecycle
[modules/yacs.git] / src / engine / InputPort.hxx
index 80c565f2236f9ce5bf39af1f1d33071dead3cea7..3440801c6f0c85a9ee898a5cb212dd96f4a5eb0f 100644 (file)
@@ -1,4 +1,4 @@
-// Copyright (C) 2006-2015  CEA/DEN, EDF R&D
+// Copyright (C) 2006-2023  CEA, EDF
 //
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
@@ -66,7 +66,7 @@ namespace YACS
       void edInit(Any *value);
       void edInit(const std::string& impl,const void* value);
       virtual void edRemoveManInit();
-      virtual void checkBasicConsistency() const throw(Exception);
+      virtual void checkBasicConsistency() const ;
       virtual void exInit(bool start);
       virtual void exSaveInit() = 0;
       virtual void exRestoreInit() = 0;
@@ -74,14 +74,17 @@ namespace YACS
       virtual bool isEmpty();
 
       virtual void *get() const = 0;
-      virtual void put(const void *data) throw(ConversionException) = 0;
+      virtual void releaseData() = 0;
+      virtual void put(const void *data) = 0;
       virtual std::string dump();
+      virtual std::string getHumanRepr();
       virtual void setStringRef(std::string strRef);
       virtual std::string typeName() {return "YACS__ENGINE__InputPort";}
       bool canBeNull() const;
     protected:
       InputPort(const InputPort& other, Node *newHelder);
       InputPort(const std::string& name, Node *node, TypeCode* type, bool canBeNull = false);
+      void releaseDataUnsafe();
     protected:
       Any *_initValue;
       std::string _stringRef;
@@ -99,9 +102,9 @@ namespace YACS
       ProxyPort(InputPort* p);
       ~ProxyPort();
       
-      void edRemoveAllLinksLinkedWithMe() throw(Exception);
+      void edRemoveAllLinksLinkedWithMe() ;
       InputPort *clone(Node *newHelder) const;
-      void edNotifyReferencedBy(OutPort *fromPort);
+      void edNotifyReferencedBy(OutPort *fromPort, bool isLoopProof = true) override;
       void edNotifyDereferencedBy(OutPort *fromPort);
       std::set<OutPort *> edSetOutPort() const;
 #ifdef NOCOVARIANT
@@ -110,7 +113,8 @@ namespace YACS
       InputPort *getPublicRepresentant();
 #endif
       void *get() const;
-      virtual void put(const void *data) throw(ConversionException) ;
+      virtual void put(const void *data) ;
+      void releaseData() override;
       int edGetNumberOfLinks() const;
       bool isIntermediate() const { return true; }
       void exRestoreInit();