Bump topology model versions
[mdsal.git] / model / ietf / ietf-topology-isis / src / main / yang / isis-topology@2013-10-21.yang
1 module isis-topology {
2     yang-version 1;
3     namespace "urn:TBD:params:xml:ns:yang:network:isis-topology";
4     // replace with IANA namespace when assigned
5     prefix "isis";
6     import network-topology {
7         prefix nt;
8     }
9     import l3-unicast-igp-topology {
10         prefix igp;
11     }
12     import ted {
13         prefix ted;
14     }
15
16     organization "TBD";
17     contact "TBD";
18     description "ISIS Topology model";
19
20     revision "2013-10-21" {
21         description "Initial version";
22     }
23     typedef iso-system-id {
24         description "ISO System ID. RFC 1237";
25         type string {
26             pattern '[0-9a-fA-F]{4}(\.[0-9a-fA-F]{4}){2}';
27         }
28     }
29
30     typedef iso-pseudonode-id {
31         description "ISO pseudonode id for broadcast network";
32         type string {
33             pattern '[0-9a-fA-F]{2}';
34         }
35     }
36     typedef iso-net-id {
37         description "ISO NET ID. RFC 1237";
38         type string {
39             pattern '[0-9a-fA-F]{2}((\.[0-9a-fA-F]{4}){6})';
40         }
41     }
42
43     grouping isis-topology-type {
44         container isis {
45             presence "Indicates ISIS Topology";
46         }
47     }
48
49     augment "/nt:network-topology/nt:topology/nt:topology-types/igp:l3-unicast-igp-topology" {
50         uses isis-topology-type;
51     }
52
53     augment "/nt:network-topology/nt:topology/igp:igp-topology-attributes" {
54         when "../nt:topology-types/l3t:l3-unicast-igp-topology/isis";
55         container isis-topology-attributes {
56             leaf net {
57                 type iso-net-id;
58             }
59         }
60     }
61
62     augment "/nt:network-topology/nt:topology/nt:node/igp:igp-node-attributes" {
63         when "../../nt:topology-types/l3t:l3-unicast-igp-topology/isis";
64         uses isis-node-attributes;
65     }
66
67     augment "/nt:network-topology/nt:topology/nt:link/igp:igp-link-attributes" {
68
69         when "../../nt:topology-types/l3t:l3-unicast-igp-topology/isis";
70         uses isis-link-attributes;
71     }
72
73     grouping isis-node-attributes {
74         container isis-node-attributes {
75             container iso {
76                 leaf iso-system-id {
77                     type iso-system-id;
78                 }
79                 leaf iso-pseudonode-id {
80                     default "0";
81                     type iso-pseudonode-id;
82                 }
83             }
84             leaf-list net {
85                 max-elements 3;
86                 type iso-net-id;
87             }
88             leaf-list multi-topology-id {
89                 description "List of Multi Topology Identifier upto 128 (0-127). RFC 4915";
90                 max-elements "128";
91                 type uint8 {
92                     range "0..127";
93                 }
94             }
95             choice router-type {
96                 case level-2 {
97                     leaf level-2 {
98                         type empty;
99                     }
100                 }
101                 case level-1 {
102                     leaf level-1 {
103                         type empty;
104                     }
105                 }
106                 case level-1-2 {
107                     leaf level-1-2 {
108                         type empty;
109                     }
110                 }
111             }
112             container ted {
113                 uses ted:ted-node-attributes;
114             }
115         }
116     }
117
118     grouping isis-link-attributes {
119         container isis-link-attributes {
120             leaf multi-topology-id {
121                 type uint8 {
122                     range "0..127";
123                 }
124             }
125             container ted {
126                 uses ted:ted-link-attributes;
127             }
128         }
129     }
130
131     augment "/igp:igp-node-event" {
132         uses isis-topology-type;
133         uses isis-node-attributes;
134     }
135
136     augment "/igp:igp-link-event" {
137         uses isis-topology-type;
138         uses isis-link-attributes;
139     }
140 } // Module isis-topology