BUG-865: deprecate pre-Beryllium parser elements
[yangtools.git] / yang / yang-parser-impl / src / main / java / org / opendaylight / yangtools / yang / parser / builder / api / GroupingBuilder.java
1 /*
2  * Copyright (c) 2013 Cisco Systems, Inc. and others.  All rights reserved.
3  *
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
7  */
8 package org.opendaylight.yangtools.yang.parser.builder.api;
9
10 import java.util.List;
11 import java.util.Set;
12 import org.opendaylight.yangtools.yang.model.api.GroupingDefinition;
13
14 /**
15  * Interface for builders of 'grouping' statement.
16  *
17  * @deprecated Pre-Beryllium implementation, scheduled for removal.
18  */
19 @Deprecated
20 public interface GroupingBuilder extends DataNodeContainerBuilder, SchemaNodeBuilder, GroupingMember {
21
22     /**
23      * Build GroupingDefinition object from this builder.
24      *
25      * @return Instance of {@link GroupingDefinition} described by this builder.
26      */
27     @Override
28     GroupingDefinition build();
29
30     /**
31      *
32      * Returns instantiation of grouping child nodes under supplied builder.
33      *
34      * Supplied newParent is not modified.
35      *
36      * For each {@link #getChildNodeBuilders()} new builder is created,
37      * which has supplied new parent set as their {@link Builder#getParent()}
38      * and QNames have updated namespace and revision per supplied parent
39      * node.
40      *
41      * @param newParent Parent node, under which this grouping should be instantiated.
42      * @return List of new builders representing instantiation of this grouping.
43      */
44     List<DataSchemaNodeBuilder> instantiateChildNodes(Builder newParent);
45
46
47    /**
48     *
49     * Returns instantiation of grouping type definitions under supplied builder.
50     *
51     * Supplied newParent is not modified.
52     *
53     * For each {@link #getTypeDefinitionBuilders()} new builder is created,
54     * which has supplied new parent set as their {@link Builder#getParent()}
55     * and QNames have updated namespace and revision per supplied parent
56     * node.
57     *
58     * @param newParent Parent node, under which this grouping should be instantiated.
59     * @return Set of new builders representing instantiation of this grouping.
60     */
61     Set<TypeDefinitionBuilder> instantiateTypedefs(Builder newParent);
62
63    /**
64     *
65     * Returns instantiation of grouping definitions under supplied builder.
66     *
67     * Supplied newParent is not modified.
68     *
69     * For each {@link #getGroupingBuilders()} new builder is created,
70     * which has supplied new parent set as their {@link Builder#getParent()}
71     * and QNames have updated namespace and revision per supplied parent
72     * node.
73     *
74     * @param newParent Parent node, under which this grouping should be instantiated.
75     * @return Set of new builders representing instantiation of this grouping.
76     */
77     Set<GroupingBuilder> instantiateGroupings(Builder newParent);
78
79     /**
80     *
81     * Returns instantiation of unknown nodes under supplied builder.
82     *
83     * Supplied newParent is not modified.
84     *
85     * For each {@link #getUnknownNodes()} new builder is created,
86     * which has supplied new parent set as their {@link Builder#getParent()}
87     * and QNames have updated namespace and revision per supplied parent
88     * node.
89     *
90     * @param newParent Parent node, under which this grouping should be instantiated.
91     * @return Set of new builders representing instantiation of this grouping.
92     */
93     Set<UnknownSchemaNodeBuilder> instantiateUnknownNodes(Builder newParent);
94
95 }