X-Git-Url: https://git.opendaylight.org/gerrit/gitweb?a=blobdiff_plain;f=opendaylight%2Fmd-sal%2Fsal-distributed-datastore%2Fsrc%2Fmain%2Fjava%2Forg%2Fopendaylight%2Fcontroller%2Fcluster%2Fdatastore%2FLocalTransactionChain.java;h=c995e1150df974d7dfdd1b1c7d9dcaa589be0d14;hb=546cd1fd100dbaa36908b22c2f422320dbd8c4b2;hp=791c3ef69b135f8387e3b0afb764bc7abaf70fc3;hpb=127042ea7e148d9dc0282acc3780b4754ca69e12;p=controller.git diff --git a/opendaylight/md-sal/sal-distributed-datastore/src/main/java/org/opendaylight/controller/cluster/datastore/LocalTransactionChain.java b/opendaylight/md-sal/sal-distributed-datastore/src/main/java/org/opendaylight/controller/cluster/datastore/LocalTransactionChain.java index 791c3ef69b..c995e1150d 100644 --- a/opendaylight/md-sal/sal-distributed-datastore/src/main/java/org/opendaylight/controller/cluster/datastore/LocalTransactionChain.java +++ b/opendaylight/md-sal/sal-distributed-datastore/src/main/java/org/opendaylight/controller/cluster/datastore/LocalTransactionChain.java @@ -18,9 +18,9 @@ import org.opendaylight.mdsal.dom.spi.store.DOMStoreReadWriteTransaction; import org.opendaylight.mdsal.dom.spi.store.DOMStoreThreePhaseCommitCohort; import org.opendaylight.mdsal.dom.spi.store.DOMStoreWriteTransaction; import org.opendaylight.mdsal.dom.spi.store.SnapshotBackedWriteTransaction; -import org.opendaylight.yangtools.yang.data.api.schema.tree.DataTree; import org.opendaylight.yangtools.yang.data.api.schema.tree.DataTreeModification; import org.opendaylight.yangtools.yang.data.api.schema.tree.DataTreeSnapshot; +import org.opendaylight.yangtools.yang.data.api.schema.tree.ReadOnlyDataTree; /** * Transaction chain instantiated on top of a locally-available DataTree. It does not instantiate @@ -31,15 +31,16 @@ final class LocalTransactionChain extends AbstractSnapshotBackedTransactionChain private static final Throwable ABORTED = new Throwable("Transaction aborted"); private final TransactionChainProxy parent; private final ActorSelection leader; - private final DataTree tree; + private final ReadOnlyDataTree tree; - LocalTransactionChain(final TransactionChainProxy parent, final ActorSelection leader, final DataTree tree) { + LocalTransactionChain(final TransactionChainProxy parent, final ActorSelection leader, + final ReadOnlyDataTree tree) { this.parent = requireNonNull(parent); this.leader = requireNonNull(leader); this.tree = requireNonNull(tree); } - DataTree getDataTree() { + ReadOnlyDataTree getDataTree() { return tree; }