2 * Copyright (c) 2017 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.binding.javav2.spec.base;
11 import com.google.common.annotations.Beta;
12 import org.opendaylight.mdsal.binding.javav2.spec.structural.Augmentation;
13 import org.opendaylight.mdsal.binding.javav2.spec.structural.TreeChildNode;
14 import org.opendaylight.yangtools.concepts.Builder;
17 public interface InstanceIdentifierBuilder<T extends TreeNode> extends Builder<InstanceIdentifier<T>> {
19 * Append the specified container as a child of the current InstanceIdentifier referenced by the
22 * This method should be used when you want to build an instance identifier by appending
28 * InstanceIdentifier.builder().child(Nodes.class).build();
32 * NOTE :- The above example is only for illustration purposes InstanceIdentifier.builder() has
33 * been deprecated and should not be used. Use InstanceIdentifier.builder(Nodes.class) instead
39 // FIXME: Why TreeNode needs to be explicitly mentioned, whern ChildTreeNode is derived from
41 <N extends TreeNode & TreeChildNode<? super T, Item<N>>> InstanceIdentifierBuilder<N> child(Class<N> container);
44 * Append the specified listItem as a child of the current InstanceIdentifier referenced by the
47 * This method should be used when you want to build an instance identifier by appending a
48 * specific list element to the identifier
56 <N extends TreeChildNode<? super T, ?>, K> InstanceIdentifierBuilder<N> child(Class<N> listItem, K listKey);
59 * Build an identifier which refers to a specific augmentation of the current InstanceIdentifier
60 * referenced by the builder
66 <N extends TreeNode & Augmentation<? super T>> InstanceIdentifierBuilder<N> augmentation(Class<N> container);
69 * Build the instance identifier.
74 InstanceIdentifier<T> build();
77 * @deprecated use #build()
80 InstanceIdentifier<T> toInstance();