Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
New stable version with the add of the Maheve algorithm.
[mapping.git] / src / and / Mapping / Association.java
index 7d24134..ab8ebdc 100644 (file)
@@ -94,10 +94,18 @@ public class Association implements Serializable
        /**
         * Replace the GNode of the association.
         * @param _g The replacing GNode
+        * @return The state of the replacement
         */
-       public void setGNode( GNode _g )
+       public boolean setGNode( GNode _g )
        {
-               g = _g ;
+               if( _g != null )
+               {
+                       g = _g ;
+                       return true ;
+               } else {
+                       System.err.println( "(Association) The new GNode is null!" ) ;
+                       return false ;
+               }
        }