2 * Copyright (c) 2016 Cisco Systems, Inc. and others. All rights reserved.
4 * This program and the accompanying materials are made available under the
5 * terms of the Eclipse Public License v1.0 which accompanies this distribution,
6 * and is available at http://www.eclipse.org/legal/epl-v10.html
8 package org.opendaylight.controller.cluster.databroker;
10 import static java.util.Objects.requireNonNull;
12 import org.opendaylight.controller.cluster.databroker.actors.dds.ClientTransaction;
13 import org.opendaylight.mdsal.dom.spi.store.DOMStoreTransaction;
16 * Abstract base class for concrete {@link DOMStoreTransaction} implementations. It holds a reference to the associated
17 * {@link ClientTransaction}. This abstraction layer is needed to isolate end users, who interact with
18 * {@link DOMStoreTransaction} from the internal implementation.
20 * @author Robert Varga
22 abstract class AbstractShardedTransaction implements DOMStoreTransaction {
23 private final ClientTransaction tx;
25 AbstractShardedTransaction(final ClientTransaction tx) {
26 this.tx = requireNonNull(tx);
30 public final Object getIdentifier() {
31 return tx.getIdentifier();
34 final ClientTransaction transaction() {