Switch CompositeModification to bypass thread-local streams
[controller.git] / opendaylight / md-sal / sal-distributed-datastore / src / main / java / org / opendaylight / controller / cluster / datastore / modification / AbstractModification.java
index 77f0858d7b1ef9119fb5b2bff9039de0d30e4536..33bd4d45e191419d605153463eafd2e00987830e 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2014 Cisco Systems, Inc. and others.  All rights reserved.
+ * Copyright (c) 2014, 2017 Cisco Systems, Inc. and others.  All rights reserved.
  *
  * This program and the accompanying materials are made available under the
  * terms of the Eclipse Public License v1.0 which accompanies this distribution,
@@ -8,26 +8,30 @@
 
 package org.opendaylight.controller.cluster.datastore.modification;
 
-
 import org.opendaylight.yangtools.yang.data.api.YangInstanceIdentifier;
 
 /**
- * Base class to be used for all simple modifications that can be applied to a DOMStoreTransaction
+ * Base class to be used for all simple modifications that can be applied to a DOMStoreTransaction.
  */
 public abstract class AbstractModification implements Modification {
 
     private YangInstanceIdentifier path;
     private short version;
 
-    protected AbstractModification(short version) {
+    protected AbstractModification(final short version) {
+        this.version = version;
+    }
+
+    protected AbstractModification(final short version, final YangInstanceIdentifier path) {
+        this.path = path;
         this.version = version;
     }
 
-    protected AbstractModification(YangInstanceIdentifier path) {
+    protected AbstractModification(final YangInstanceIdentifier path) {
         this.path = path;
     }
 
-    protected void setPath(YangInstanceIdentifier path) {
+    protected void setPath(final YangInstanceIdentifier path) {
         this.path = path;
     }