2 * Copyright (c) 2013 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.yangtools.yang.model.api;
10 import java.util.Collection;
12 import org.opendaylight.yangtools.yang.common.QName;
15 * Node which can contains other nodes.
17 public interface DataNodeContainer {
20 * Returns set of all newly defined types within this DataNodeContainer.
22 * @return typedef statements in lexicographical order
24 Set<TypeDefinition<?>> getTypeDefinitions();
27 * Returns set of all child nodes defined within this DataNodeContainer.
28 * Although the return type is a collection, each node is guaranteed to
29 * be present at most once.
31 * @return child nodes in lexicographical order
33 Collection<DataSchemaNode> getChildNodes();
36 * Returns set of all groupings defined within this DataNodeContainer.
38 * @return grouping statements in lexicographical order
40 Set<GroupingDefinition> getGroupings();
43 * Returns the child node corresponding to the specified name.
47 * @return child node of this DataNodeContainer if child with given name is
48 * present, null otherwise
50 DataSchemaNode getDataChildByName(QName name);
53 * Returns grouping nodes used ny this container.
55 * @return Set of all uses nodes defined within this DataNodeContainer
57 Set<UsesNode> getUses();