Do not use entrySet() where values() or keySet() suffices
[mdsal.git] / dom / mdsal-dom-inmemory-datastore / src / main / java / org / opendaylight / mdsal / dom / store / inmemory / WriteableNodeWithSubshard.java
index 326ab2330681b835d36cb57ba6e646ca92b0e60c..58cb6d9852b0486917928c155b4eb0de6b350d2d 100644 (file)
@@ -10,14 +10,13 @@ package org.opendaylight.mdsal.dom.store.inmemory;
 
 import com.google.common.collect.ImmutableMap;
 import java.util.Map;
-import java.util.Map.Entry;
 import org.opendaylight.yangtools.yang.data.api.YangInstanceIdentifier.PathArgument;
 
 abstract class WriteableNodeWithSubshard extends WriteableModificationNode {
 
     private final Map<PathArgument, WriteableModificationNode> children;
 
-    WriteableNodeWithSubshard(Map<PathArgument, WriteableModificationNode> children) {
+    WriteableNodeWithSubshard(final Map<PathArgument, WriteableModificationNode> children) {
         this.children = ImmutableMap.copyOf(children);
     }
 
@@ -27,14 +26,14 @@ abstract class WriteableNodeWithSubshard extends WriteableModificationNode {
     }
 
     @Override
-    WriteableModificationNode getChild(PathArgument node) {
+    WriteableModificationNode getChild(final PathArgument node) {
         return children.get(node);
     }
 
     @Override
     void markDeleted() {
-        for (Entry<PathArgument, WriteableModificationNode> child : children.entrySet()) {
-            child.getValue().markDeleted();
+        for (WriteableModificationNode child : children.values()) {
+            child.markDeleted();
         }
     }
 }
\ No newline at end of file