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.mdsal.dom.spi.shard;
10 import com.google.common.annotations.Beta;
11 import com.google.common.collect.ImmutableMap;
13 import org.opendaylight.yangtools.yang.data.api.YangInstanceIdentifier.PathArgument;
16 public abstract class WriteableNodeWithSubshard extends WriteableModificationNode {
18 private final Map<PathArgument, WriteableModificationNode> children;
20 protected WriteableNodeWithSubshard(final Map<PathArgument, WriteableModificationNode> children) {
21 this.children = ImmutableMap.copyOf(children);
25 public Map<PathArgument, WriteableModificationNode> getChildrenWithSubshards() {
30 public WriteableModificationNode getChild(final PathArgument node) {
31 return children.get(node);
35 public void markDeleted() {
36 for (WriteableModificationNode child : children.values()) {