Fixed RESTConf support for identity-ref build-in datatype
[controller.git] / opendaylight / md-sal / sal-rest-connector / src / test / resources / cnsn-to-json / choice / choice.yang
1 module choice-case-test {
2         namespace "choice:case:test";  
3         
4         prefix "chcatst";
5         revision 2013-11-27 {    
6         }
7         
8         container cont {
9                 leaf lf1 {
10                         type string;
11                 }               
12                 
13                 choice choi1 {            
14                         case a1 {
15                                 leaf lf1a {
16                                         type uint16;    
17                                 }
18                                 choice choi1a {
19                                         case aa1 {
20                                                 leaf lf1aa {
21                                                         type string;
22                                                 }
23                                                 choice choi1aa {
24                                                         case aaa1 {
25                                                                 leaf lf1aaa {
26                                                                         type string;
27                                                                 }
28                                                         }
29                                                         case aab1 {
30                                                                 leaf lf1aab {
31                                                                         type string;
32                                                                 }
33                                                         }
34                                                 }
35                                         }
36                                         case ab1 {
37                                                 leaf lf1ab {
38                                                         type string;
39                                                 }
40                                         }
41                                 }
42                         }                       
43                         case b1 {
44                                 list lst1b {
45                                         leaf lf11b {
46                                                 type string;
47                                         }
48                                 }
49                         }
50                         case c1 {
51                                 container cont1c {
52                                         leaf lf11c {
53                                                 type string;
54                                         }
55                                 }
56                         }
57                         case d1 {
58                                 leaf-list lflst1d {
59                                         type string;
60                                 }
61                         }
62             leaf e1 {
63                 type uint32;
64             }
65                 }
66                 
67                 choice choi2 {
68                         case a2 {
69                                 leaf lf2a {
70                                         type string;
71                                 }
72                         }
73                         case b2 {
74                                 leaf lf2b {
75                                         type string;
76                                 }
77                         }
78                 }
79         
80         choice choi4 {
81             case a4 {
82                 list lst4a {
83                     choice choi4aa {
84                         case aa1 {
85                             leaf lf4aa {
86                                 type string;
87                             }
88                         }
89                         case ab2 {
90                             leaf lf4ab {
91                                 type int16;
92                             }
93                         }
94                     }
95                 }
96             }
97             case b4 {
98                 leaf-list lflst4b {
99                     type uint32;
100                 }
101             }
102             
103         }
104                 
105 /*               equal identifiers in various cases are illegal 7.9.2 rfc6020 */
106 /*              
107                 choice choi3 {
108                         case 3a {
109                                 leaf lf3a {
110                                         type string;
111                                 }
112                         }
113                         case 3b {
114                                 leaf lf3b {
115                                         type string;
116                                 }
117                         }
118                 }
119 */
120                                 
121         }
122   
123         
124
125 }