[Swift-commit] r7322 - trunk/src/org/griphyn/vdl/mapping

hategan at ci.uchicago.edu hategan at ci.uchicago.edu
Mon Nov 25 02:00:06 CST 2013


Author: hategan
Date: 2013-11-25 02:00:06 -0600 (Mon, 25 Nov 2013)
New Revision: 7322

Modified:
   trunk/src/org/griphyn/vdl/mapping/ExternalDataNode.java
Log:
don't complain about double-closing an external and allow getValue() to be called on it without a warning; from some point on, values on mapped types started to be used to better track status of things

Modified: trunk/src/org/griphyn/vdl/mapping/ExternalDataNode.java
===================================================================
--- trunk/src/org/griphyn/vdl/mapping/ExternalDataNode.java	2013-11-25 07:58:16 UTC (rev 7321)
+++ trunk/src/org/griphyn/vdl/mapping/ExternalDataNode.java	2013-11-25 08:00:06 UTC (rev 7322)
@@ -111,11 +111,6 @@
 		throw new UnsupportedOperationException(this.getDisplayableName() + " is an external dataset and cannot be set");
 	}
 
-	public Object getValue() {
-	    logger.warn("getValue called on an external dataset");
-	    return null;
-	}
-
 	public Map<Comparable<?>, DSHandle> getArrayValue() {
 	    throw new UnsupportedOperationException("cannot get value of external dataset");
 	}
@@ -155,12 +150,14 @@
     }
 
     @Override
-    public void closeDeep() {
-        /*
-         * Need to override this and set a value since 
-         * this is skipped by the normal stageout mechanism which
-         * does that
-         */
-        this.setValue(FILE_VALUE);
+    public synchronized void closeDeep() {
+        if (!this.isClosed()) {
+            /*
+             * Need to override this and set a value since 
+             * this is skipped by the normal stageout mechanism which
+             * does that
+             */
+            this.setValue(FILE_VALUE);
+        }
     }
 }




More information about the Swift-commit mailing list