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
9 package org.opendaylight.mdsal.dom.store.inmemory;
11 import static java.util.Objects.requireNonNull;
13 import org.opendaylight.mdsal.dom.spi.shard.AbstractDataModificationCursor;
14 import org.opendaylight.mdsal.dom.spi.shard.WriteCursorStrategy;
16 class InMemoryShardDataModificationCursor extends AbstractDataModificationCursor<ShardDataModification> {
18 private InmemoryDOMDataTreeShardWriteTransaction parent;
20 InMemoryShardDataModificationCursor(final ShardDataModification root,
21 final InmemoryDOMDataTreeShardWriteTransaction parent) {
23 this.parent = requireNonNull(parent);
27 protected WriteCursorStrategy getRootOperation(final ShardDataModification root) {
28 return root.createOperation(null);
33 parent.cursorClosed();