incubator-oodt-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ke...@apache.org
Subject svn commit: r964913 - /incubator/oodt/trunk/metadata/src/main/java/org/apache/oodt/cas/metadata/Metadata.java
Date Fri, 16 Jul 2010 19:23:07 GMT
Author: kelly
Date: Fri Jul 16 19:23:07 2010
New Revision: 964913

URL: http://svn.apache.org/viewvc?rev=964913&view=rev
Log:
PGE wants a "replaceMetadata" method that takes a Metadata instance; provide that function

Modified:
    incubator/oodt/trunk/metadata/src/main/java/org/apache/oodt/cas/metadata/Metadata.java

Modified: incubator/oodt/trunk/metadata/src/main/java/org/apache/oodt/cas/metadata/Metadata.java
URL: http://svn.apache.org/viewvc/incubator/oodt/trunk/metadata/src/main/java/org/apache/oodt/cas/metadata/Metadata.java?rev=964913&r1=964912&r2=964913&view=diff
==============================================================================
--- incubator/oodt/trunk/metadata/src/main/java/org/apache/oodt/cas/metadata/Metadata.java
(original)
+++ incubator/oodt/trunk/metadata/src/main/java/org/apache/oodt/cas/metadata/Metadata.java
Fri Jul 16 19:23:07 2010
@@ -158,6 +158,17 @@ public class Metadata {
     }
 
     /**
+     * Replace our metadata with all metadata in the given metadata.
+     * Keys in our metadata will be overwritten by the given's.  New
+     * keys that don't yet exist in ours will get added.
+     *
+     * @param metadata Metadata from which to replace our own.
+     */
+    public void replaceMetadata(Metadata metadata) {
+        this.replaceMetadata(new Hashtable(metadata.elementMap));
+    }
+
+    /**
      * <p>
      * Replaces the internal hashtable of metadata with the specified
      * {@link Hashtable}.



Mime
View raw message