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;
13 import org.opendaylight.yangtools.yang.common.QName;
16 * Node which can contains other nodes.
18 public interface DataNodeContainer {
21 * Returns set of all newly defined types within this DataNodeContainer.
23 * @return typedef statements in lexicographical order
25 Set<TypeDefinition<?>> getTypeDefinitions();
28 * Returns set of all child nodes defined within this DataNodeContainer.
29 * Although the return type is a collection, each node is guaranteed to
30 * be present at most once.
32 * @return child nodes in lexicographical order
34 Collection<DataSchemaNode> getChildNodes();
37 * Returns set of all groupings defined within this DataNodeContainer.
39 * @return grouping statements in lexicographical order
41 Set<GroupingDefinition> getGroupings();
45 * QName of seeked child
46 * @return child node of this DataNodeContainer if child with given name is
47 * present, null otherwise
49 DataSchemaNode getDataChildByName(QName name);
53 * name of seeked child as String
54 * @return child node of this DataNodeContainer if child with given name is
55 * present, null otherwise
57 DataSchemaNode getDataChildByName(String name);
60 * @return Set of all uses nodes defined within this DataNodeContainer
62 Set<UsesNode> getUses();