Introduce top-level pom file.
[mdsal.git] / code-generator / binding-generator-impl / src / test / resources / bit_and_union_in_leaf.yang
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 module bit-and-union-in-leaf {
9     
10     namespace "urn:bit:union:in:leaf";
11     prefix "sbd";
12
13     organization "OPEN DAYLIGHT";
14     contact "http://www.opendaylight.org/";
15
16     revision 2013-06-26 {
17         
18     }
19     
20     typedef union-typedef {
21         type union {
22             type string {
23                 pattern "[a-g]";
24             }
25             type int16;
26         }
27     }
28     
29     typedef union-typedef2 {
30         type union {
31             type string; 
32             type int16;
33         }
34     }    
35     
36     container parent-container {
37         leaf bit-leaf {
38             type bits {
39                 bit first-bit;
40                 bit second-bit;
41                 bit third-bit;
42             }
43         }
44         
45         leaf union-leaf {
46             type union {
47                 type int32;
48                 type string {
49                     pattern "[a-z]";
50                 }
51                 type string {
52                     pattern "[0-9]*";
53                 }
54                 type string {
55                     pattern "[a-d]*";
56                     pattern "[0-5]*";
57                 }
58                 type uint8;
59             }
60         }
61     }
62 }