commons-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ohe...@apache.org
Subject svn commit: r1575762 - in /commons/proper/configuration/branches/immutableNodes/src/main/java/org/apache/commons/configuration/tree: NodeHandler.java TreeData.java
Date Sun, 09 Mar 2014 21:01:05 GMT
Author: oheger
Date: Sun Mar  9 21:01:04 2014
New Revision: 1575762

URL: http://svn.apache.org/r1575762
Log:
Added method getRootNode() to NodeHandler interface.

A node handler is always associated with a specific nodes structure. If the
handler and the root node are queried from different objects, there is a
potential race condition that the nodes structure has been updated in the mean
time.

Modified:
    commons/proper/configuration/branches/immutableNodes/src/main/java/org/apache/commons/configuration/tree/NodeHandler.java
    commons/proper/configuration/branches/immutableNodes/src/main/java/org/apache/commons/configuration/tree/TreeData.java

Modified: commons/proper/configuration/branches/immutableNodes/src/main/java/org/apache/commons/configuration/tree/NodeHandler.java
URL: http://svn.apache.org/viewvc/commons/proper/configuration/branches/immutableNodes/src/main/java/org/apache/commons/configuration/tree/NodeHandler.java?rev=1575762&r1=1575761&r2=1575762&view=diff
==============================================================================
--- commons/proper/configuration/branches/immutableNodes/src/main/java/org/apache/commons/configuration/tree/NodeHandler.java
(original)
+++ commons/proper/configuration/branches/immutableNodes/src/main/java/org/apache/commons/configuration/tree/NodeHandler.java
Sun Mar  9 21:01:04 2014
@@ -154,4 +154,11 @@ public interface NodeHandler<T>
      * @return a flag whether the passed in node is defined
      */
     boolean isDefined(T node);
+
+    /**
+     * Returns the root node of the underlying hierarchy.
+     *
+     * @return the current root node
+     */
+    T getRootNode();
 }

Modified: commons/proper/configuration/branches/immutableNodes/src/main/java/org/apache/commons/configuration/tree/TreeData.java
URL: http://svn.apache.org/viewvc/commons/proper/configuration/branches/immutableNodes/src/main/java/org/apache/commons/configuration/tree/TreeData.java?rev=1575762&r1=1575761&r2=1575762&view=diff
==============================================================================
--- commons/proper/configuration/branches/immutableNodes/src/main/java/org/apache/commons/configuration/tree/TreeData.java
(original)
+++ commons/proper/configuration/branches/immutableNodes/src/main/java/org/apache/commons/configuration/tree/TreeData.java
Sun Mar  9 21:01:04 2014
@@ -75,11 +75,6 @@ class TreeData implements NodeHandler<Im
         nodeTracker = tracker;
     }
 
-    /**
-     * Returns the root node.
-     *
-     * @return the current root node
-     */
     public ImmutableNode getRootNode()
     {
         return root;



Mime
View raw message