Merge "Rename applySubtreeChange()"
authorTony Tkacik <ttkacik@cisco.com>
Wed, 25 Mar 2015 09:41:07 +0000 (09:41 +0000)
committerGerrit Code Review <gerrit@opendaylight.org>
Wed, 25 Mar 2015 09:41:08 +0000 (09:41 +0000)
yang/yang-data-impl/src/main/java/org/opendaylight/yangtools/yang/data/impl/schema/tree/AbstractNodeContainerModificationStrategy.java
yang/yang-data-impl/src/main/java/org/opendaylight/yangtools/yang/data/impl/schema/tree/AbstractValueNodeModificationStrategy.java
yang/yang-data-impl/src/main/java/org/opendaylight/yangtools/yang/data/impl/schema/tree/SchemaAwareApplyOperation.java
yang/yang-data-impl/src/main/java/org/opendaylight/yangtools/yang/data/impl/schema/tree/UnkeyedListModificationStrategy.java

index 9349ed504683aa6bfd65c2539ba8bdaf5d79191b..c0ddf6c4aa5f332d4c6c4cff3be79d2c97b34324 100644 (file)
@@ -129,11 +129,11 @@ abstract class AbstractNodeContainerModificationStrategy extends SchemaAwareAppl
     protected TreeNode applyMerge(final ModifiedNode modification, final TreeNode currentMeta,
             final Version version) {
         // For Node Containers - merge is same as subtree change - we only replace children.
-        return applySubtreeChange(modification, currentMeta, version);
+        return applyTouch(modification, currentMeta, version);
     }
 
     @Override
-    public TreeNode applySubtreeChange(final ModifiedNode modification,
+    public TreeNode applyTouch(final ModifiedNode modification,
             final TreeNode currentMeta, final Version version) {
         final MutableTreeNode newMeta = currentMeta.mutable();
         newMeta.setSubtreeVersion(version);
index e2d5cdec1a9d2a4cec35f86ebce1c4795255dc0d..6f4e8497ac387879dcce3c2b11ad9d4916896a6a 100644 (file)
@@ -46,7 +46,7 @@ abstract class AbstractValueNodeModificationStrategy<T extends DataSchemaNode> e
     }
 
     @Override
-    protected final TreeNode applySubtreeChange(final ModifiedNode modification,
+    protected final TreeNode applyTouch(final ModifiedNode modification,
             final TreeNode currentMeta, final Version version) {
         throw new UnsupportedOperationException("Node " + schema.getPath()
                 + "is leaf type node. Subtree change is not allowed.");
index b691f9f20a2146769ea6f1fbd84e39aa4aa5c0b2..80ef74cf9a3a8b9bcc44e0fdbec3b514237882db 100644 (file)
@@ -191,7 +191,7 @@ abstract class SchemaAwareApplyOperation extends ModificationApplyOperation {
         case TOUCH:
             Preconditions.checkArgument(currentMeta.isPresent(), "Metadata not available for modification",
                     modification);
-            return modification.setSnapshot(Optional.of(applySubtreeChange(modification, currentMeta.get(),
+            return modification.setSnapshot(Optional.of(applyTouch(modification, currentMeta.get(),
                     version)));
         case MERGE:
             final TreeNode result;
@@ -240,7 +240,7 @@ abstract class SchemaAwareApplyOperation extends ModificationApplyOperation {
      * @param version New subtree version of parent node
      * @return A sealed TreeNode representing applied operation.
      */
-    protected abstract TreeNode applySubtreeChange(ModifiedNode modification, TreeNode currentMeta, Version version);
+    protected abstract TreeNode applyTouch(ModifiedNode modification, TreeNode currentMeta, Version version);
 
     /**
      *
index 8231dac24508fb59f8e575000a233458c01ef618..d786cc67b5fe61c21ba19df0e6ecd04c1baaca89 100644 (file)
@@ -44,7 +44,7 @@ final class UnkeyedListModificationStrategy extends SchemaAwareApplyOperation {
     }
 
     @Override
-    protected TreeNode applySubtreeChange(final ModifiedNode modification,
+    protected TreeNode applyTouch(final ModifiedNode modification,
             final TreeNode currentMeta, final Version version) {
         throw new UnsupportedOperationException("UnkeyedList does not support subtree change.");
     }