a9cac89acb147641d6389773eaf76ef559a413c7
[controller.git] / opendaylight / config / yang-test / src / main / yang / types / test-groups.yang
1 module test-groups {
2     yang-version 1;
3     namespace "urn:opendaylight:params:xml:ns:yang:controller:config:test:groups";
4     prefix "tg";
5
6     import rpc-context { prefix rpcx; revision-date 2013-06-17; }
7
8     description
9         "Groupings generated for testing";
10
11     revision "2014-12-08";
12
13     grouping common-operational-rpc {
14         rpcx:rpc-context-instance common-rpc-ctx;
15         rpcx:rpc-context-instance common-rpc-ctx-two;
16     }
17
18     typedef version {
19         type enumeration {
20             enum version1 {
21                 value 1;
22               }
23             enum version2 {
24                 value 2;
25               }
26             enum version3 {
27                 value 3;
28               }
29             enum version4 {
30                 value 4;
31               }
32         }
33     }
34
35     grouping config-grouping {
36
37         container from-grouping {
38             leaf enum-in-grouping {
39                 type version;
40             }
41         }
42     }
43
44
45     identity common-rpc-ctx;
46     identity common-rpc-ctx-two;
47
48     rpc common-rpc {
49         input {
50             uses rpcx:rpc-context-ref {
51                 refine context-instance {
52                     rpcx:rpc-context-instance "common-rpc-ctx";
53                 }
54             }
55         }
56
57         output {
58             leaf output {
59                 type boolean;
60             }
61         }
62     }
63
64     rpc common-rpc-two {
65         input {
66             uses rpcx:rpc-context-ref {
67                 refine context-instance {
68                     rpcx:rpc-context-instance "common-rpc-ctx-two";
69                 }
70             }
71         }
72
73         output {
74             leaf output {
75                 type uint32;
76             }
77         }
78     }
79 }