BUG-45 : migrated Subsequent Address Family Identifier to generated source code.
[bgpcep.git] / bgp / concepts / src / main / yang / bgp-types.yang
1 module bgp-types {
2         yang-version 1;
3         namespace "urn:opendaylight:params:xml:ns:yang:bgp-types";
4         prefix "bgp-t";
5
6         import ietf-inet-types {
7                 prefix inet;
8                 revision-date 2010-09-24;
9         }
10
11         organization "Cisco Systems, Inc.";
12         contact "Dana Kutenicsova <dkutenic@cisco.com>";
13
14         description
15                 "This module contains the base concepts contained in RFC4271 and RFC4760.
16
17                 Copyright (c)2013 Cisco Systems, Inc. All rights reserved.
18
19                 This program and the accompanying materials are made available
20                 under the terms of the Eclipse Public License v1.0 which
21                 accompanies this distribution, and is available at
22                 http://www.eclipse.org/legal/epl-v10.html";
23
24         revision "2013-09-19" {
25                 description
26                         "Initial revision.";
27                 reference "RFC4271, RFC4760";
28         }
29
30         typedef bgp-origin {
31                 reference "http://tools.ietf.org/html/rfc4271#section-5";
32                 description "Values of BGP Origin Path Attribute.";
33                 type enumeration {
34                         enum igp {
35                                 value 0;
36                         }
37                         enum egp {
38                                 value 1;
39                         }
40                         enum incomplete {
41                                 value 2;
42                         }
43                 }
44         }
45         
46         typedef bgp-subsequent-address-family {
47                 reference "http://tools.ietf.org/html/rfc4760#section-6";
48                 type enumeration {
49                         enum unicast {
50                                 value 1;
51                         }
52                         enum mpls-labeled-vpn {
53                                 value 128;
54                         }
55                         enum linkstate {
56                                 reference "http://tools.ietf.org/html/draft-ietf-idr-ls-distribution-03#section-3.2";
57                                 value 71;
58                         }
59                 }
60         }
61
62         grouping bgp-aggregator {
63                 reference "http://tools.ietf.org/html/rfc4271#section-5.1.7";
64                 description "BGP Path Attribute AGGREGATOR.";
65                 leaf as-number {
66                         type inet:as-number;
67                 }
68                 leaf network-address {
69                         type inet:ipv4-address;
70                 }
71         }
72 }