summaryrefslogtreecommitdiffhomepage
path: root/config/bgp_configs.go
blob: 2178344b5bc4d02ce99563d233234ab97e73cced (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
// Copyright (C) 2014,2015 Nippon Telegraph and Telephone Corporation.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
//    http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
// implied.
// See the License for the specific language governing permissions and
// limitations under the License.

package config

import "net"

// typedef for typedef bgp:remove-private-as-option
type RemovePrivateAsOption int

const (
	REMOVE_PRIVATE_AS_OPTION_ALL = iota
	REMOVE_PRIVATE_AS_OPTION_REPLACE
)

// typedef for typedef bgp:community-type
type CommunityType int

const (
	COMMUNITY_TYPE_STANDARD = iota
	COMMUNITY_TYPE_EXTENDED
	COMMUNITY_TYPE_BOTH
	COMMUNITY_TYPE_NONE
)

// typedef for typedef bgp:rr-cluster-id-type
type RrClusterIdType string

// typedef for typedef bgp:peer-type
type PeerTypeDef int

const (
	PEER_TYPE_INTERNAL = iota
	PEER_TYPE_EXTERNAL
)

// typedef for typedef bgp:percentage
type Percentage uint8

// typedef for typedef bgp:bgp-origin-attr-type
type BgpOriginAttrType int

const (
	BGP_ORIGIN_ATTR_TYPE_IGP        = 0
	BGP_ORIGIN_ATTR_TYPE_EGP        = 1
	BGP_ORIGIN_ATTR_TYPE_INCOMPLETE = 2
)

// typedef for typedef ptypes:igp-tag-type
type IgpTagType string

// typedef for typedef ptypes:match-set-options-type
type MatchSetOptionsType int

const (
	MATCH_SET_OPTIONS_TYPE_ANY = iota
	MATCH_SET_OPTIONS_TYPE_ALL
	MATCH_SET_OPTIONS_TYPE_INVERT
)

// typedef for typedef rpol:install-protocol-type
type InstallProtocolType int

const (
	INSTALL_PROTOCOL_TYPE_ISIS = iota
	INSTALL_PROTOCOL_TYPE_OSPF
	INSTALL_PROTOCOL_TYPE_OSPF3
	INSTALL_PROTOCOL_TYPE_STATIC
	INSTALL_PROTOCOL_TYPE_DIRECTLY_CONNECTED
)

// typedef for typedef rpol:default-policy-type
type DefaultPolicyType int

const (
	DEFAULT_POLICY_TYPE_ACCEPT_ROUTE = iota
	DEFAULT_POLICY_TYPE_REJECT_ROUTE
)

//struct for container rpol:igp-actions
type IgpActions struct {
	// original -> rpol:set-tag
	SetTag IgpTagType
}

//struct for container rpol:actions
type Actions struct {
	// original -> rpol:accept-route
	//rpol:accept-route's original type is empty
	AcceptRoute bool
	// original -> rpol:reject-route
	//rpol:reject-route's original type is empty
	RejectRoute bool
	// original -> rpol:igp-actions
	IgpActions IgpActions
}

//struct for container rpol:igp-conditions
type IgpConditions struct {
	// original -> rpol:tag-eq
	TagEq IgpTagType
}

//struct for container rpol:conditions
type Conditions struct {
	// original -> rpol:call-policy
	CallPolicy string
	// original -> rpol:match-prefix-set
	MatchPrefixSet string
	// original -> rpol:match-neighbor-set
	MatchNeighborSet string
	// original -> rpol:match-set-options
	MatchSetOptions MatchSetOptionsType
	// original -> rpol:install-protocol-eq
	InstallProtocolEq InstallProtocolType
	// original -> rpol:igp-conditions
	IgpConditions IgpConditions
}

//struct for container rpol:statement
type Statement struct {
	// original -> rpol:name
	Name string
	// original -> rpol:conditions
	Conditions Conditions
	// original -> rpol:actions
	Actions Actions
}

//struct for container rpol:policy-definition
type PolicyDefinition struct {
	// original -> rpol:name
	Name string
	// original -> rpol:statement
	StatementList []Statement
}

//struct for container rpol:neighbor-info
type NeighborInfo struct {
	// original -> rpol:address
	//rpol:address's original type is inet:ip-address
	Address net.IP
}

//struct for container rpol:neighbor-set
type NeighborSet struct {
	// original -> rpol:neighbor-set-name
	NeighborSetName string
	// original -> rpol:neighbor-info
	NeighborInfoList []NeighborInfo
}

//struct for container rpol:prefix
type Prefix struct {
	// original -> rpol:address
	//rpol:address's original type is inet:ip-address
	Address net.IP
	// original -> rpol:masklength
	Masklength uint8
	// original -> rpol:masklength-range
	MasklengthRange string
}

//struct for container rpol:prefix-set
type PrefixSet struct {
	// original -> rpol:prefix-set-name
	PrefixSetName string
	// original -> rpol:prefix
	PrefixList []Prefix
}

//struct for container rpol:defined-sets
type DefinedSets struct {
	// original -> rpol:prefix-set
	PrefixSetList []PrefixSet
	// original -> rpol:neighbor-set
	NeighborSetList []NeighborSet
}

//struct for container rpol:routing-policy
type RoutingPolicy struct {
	// original -> rpol:defined-sets
	DefinedSets DefinedSets
	// original -> rpol:policy-definition
	PolicyDefinitionList []PolicyDefinition
}

//struct for container rpol:apply-policy
type ApplyPolicy struct {
	// original -> rpol:import-policies
	ImportPolicies []string
	// original -> rpol:default-import-policy
	DefaultImportPolicy DefaultPolicyType
	// original -> rpol:export-policies
	ExportPolicies []string
	// original -> rpol:default-export-policy
	DefaultExportPolicy DefaultPolicyType
}

//struct for container bgp-op:bgp-neighbor-common-state
type BgpNeighborCommonState struct {
	// original -> bgp-op:state
	State uint32
	// original -> bgp-op:uptime
	Uptime int64
	// original -> bgp-op:downtime
	Downtime int64
	// original -> bgp-op:open-in
	OpenIn uint32
	// original -> bgp-op:open-out
	OpenOut uint32
	// original -> bgp-op:update-in
	UpdateIn uint32
	// original -> bgp-op:update-out
	UpdateOut uint32
	// original -> bgp-op:update-recv-time
	UpdateRecvTime int64
	// original -> bgp-op:keepalive-in
	KeepaliveIn uint32
	// original -> bgp-op:keepalive-out
	KeepaliveOut uint32
	// original -> bgp-op:notify-in
	NotifyIn uint32
	// original -> bgp-op:notify-out
	NotifyOut uint32
	// original -> bgp-op:refresh-in
	RefreshIn uint32
	// original -> bgp-op:refresh-out
	RefreshOut uint32
	// original -> bgp-op:dynamic-cap-in
	DynamicCapIn uint32
	// original -> bgp-op:dynamic-cap-out
	DynamicCapOut uint32
	// original -> bgp-op:discarded-in
	DiscardedIn uint32
	// original -> bgp-op:discarded-out
	DiscardedOut uint32
	// original -> bgp-op:total-in
	TotalIn uint32
	// original -> bgp-op:total-out
	TotalOut uint32
	// original -> bgp-op:established-count
	EstablishedCount uint32
	// original -> bgp-op:flops
	Flops uint32
}

//struct for container bgp:add-paths
type AddPaths struct {
	// original -> bgp:receive
	//bgp:receive's original type is empty
	Receive bool
	// original -> bgp:send-max
	SendMax uint8
}

//struct for container bgp:as-path-options
type AsPathOptions struct {
	// original -> bgp:allow-own-as
	//bgp:allow-own-as's original type is boolean
	AllowOwnAs bool
	// original -> bgp:replace-peer-as
	//bgp:replace-peer-as's original type is boolean
	ReplacePeerAs bool
}

//struct for container bgp:error-handling
type ErrorHandling struct {
	// original -> bgp:treat-as-withdraw
	//bgp:treat-as-withdraw's original type is boolean
	TreatAsWithdraw bool
}

//struct for container bgp:transport-options
type TransportOptions struct {
	// original -> bgp:tcp-mss
	TcpMss uint16
	// original -> bgp:mtu-discovery
	//bgp:mtu-discovery's original type is boolean
	MtuDiscovery bool
	// original -> bgp:passive-mode
	//bgp:passive-mode's original type is boolean
	PassiveMode bool
}

//struct for container bgp:bgp-logging-options
type BgpLoggingOptions struct {
	// original -> bgp:log-neighbor-state-changes
	//bgp:log-neighbor-state-changes's original type is boolean
	LogNeighborStateChanges bool
}

//struct for container bgp:route-server
type RouteServer struct {
	// original -> bgp:route-server-client
	//bgp:route-server-client's original type is boolean
	RouteServerClient bool
}

//struct for container bgp:route-reflector
type RouteReflector struct {
	// original -> bgp:route-reflector-cluster-id
	RouteReflectorClusterId RrClusterIdType
	// original -> bgp:route-reflector-client
	//bgp:route-reflector-client's original type is boolean
	RouteReflectorClient bool
}

//struct for container bgp:ebgp-multihop
type EbgpMultihop struct {
	// original -> bgp:multihop-ttl
	MultihopTtl uint8
}

//struct for container bgp:timers
type Timers struct {
	// original -> bgp:connect-retry
	//bgp:connect-retry's original type is decimal64
	ConnectRetry float64
	// original -> bgp:hold-time
	//bgp:hold-time's original type is decimal64
	HoldTime float64
	// original -> bgp:idle-hold-time-after-reset
	//bgp:idle-hold-time-after-reset's original type is decimal64
	IdleHoldTimeAfterReset float64
	// original -> bgp:keepalive-interval
	//bgp:keepalive-interval's original type is decimal64
	KeepaliveInterval float64
	// original -> bgp:minimum-advertisement-interval
	//bgp:minimum-advertisement-interval's original type is decimal64
	MinimumAdvertisementInterval float64
	// original -> bgp:send-update-delay
	//bgp:send-update-delay's original type is decimal64
	SendUpdateDelay float64
}

//struct for container bgp-mp:prefix-limit
type PrefixLimit struct {
	// original -> bgp-mp:max-prefixes
	MaxPrefixes uint32
	// original -> bgp-mp:shutdown-threshold-pct
	ShutdownThresholdPct Percentage
	// original -> bgp-mp:restart-timer
	//bgp-mp:restart-timer's original type is decimal64
	RestartTimer float64
}

//struct for container bgp-mp:l2vpn-evpn
type L2vpnEvpn struct {
	// original -> rpol:apply-policy
	ApplyPolicy ApplyPolicy
	// original -> bgp-mp:prefix-limit
	PrefixLimit PrefixLimit
}

//struct for container bgp-mp:l2vpn-vpls
type L2vpnVpls struct {
	// original -> bgp-mp:enabled
	//bgp-mp:enabled's original type is boolean
	Enabled bool
	// original -> rpol:apply-policy
	ApplyPolicy ApplyPolicy
	// original -> bgp-mp:prefix-limit
	PrefixLimit PrefixLimit
}

//struct for container bgp-mp:l3vpn-ipv6-multicast
type L3vpnIpv6Multicast struct {
	// original -> bgp-mp:enabled
	//bgp-mp:enabled's original type is boolean
	Enabled bool
	// original -> rpol:apply-policy
	ApplyPolicy ApplyPolicy
	// original -> bgp-mp:prefix-limit
	PrefixLimit PrefixLimit
}

//struct for container bgp-mp:l3vpn-ipv4-multicast
type L3vpnIpv4Multicast struct {
	// original -> bgp-mp:enabled
	//bgp-mp:enabled's original type is boolean
	Enabled bool
	// original -> rpol:apply-policy
	ApplyPolicy ApplyPolicy
	// original -> bgp-mp:prefix-limit
	PrefixLimit PrefixLimit
}

//struct for container bgp-mp:l3vpn-ipv6-unicast
type L3vpnIpv6Unicast struct {
	// original -> bgp-mp:enabled
	//bgp-mp:enabled's original type is boolean
	Enabled bool
	// original -> rpol:apply-policy
	ApplyPolicy ApplyPolicy
	// original -> bgp-mp:prefix-limit
	PrefixLimit PrefixLimit
}

//struct for container bgp-mp:l3vpn-ipv4-unicast
type L3vpnIpv4Unicast struct {
	// original -> bgp-mp:enabled
	//bgp-mp:enabled's original type is boolean
	Enabled bool
	// original -> rpol:apply-policy
	ApplyPolicy ApplyPolicy
	// original -> bgp-mp:prefix-limit
	PrefixLimit PrefixLimit
}

//struct for container bgp-mp:ipv6-labelled-unicast
type Ipv6LabelledUnicast struct {
	// original -> bgp-mp:enabled
	//bgp-mp:enabled's original type is boolean
	Enabled bool
	// original -> rpol:apply-policy
	ApplyPolicy ApplyPolicy
	// original -> bgp-mp:prefix-limit
	PrefixLimit PrefixLimit
}

//struct for container bgp-mp:ipv4-labelled-unicast
type Ipv4LabelledUnicast struct {
	// original -> bgp-mp:enabled
	//bgp-mp:enabled's original type is boolean
	Enabled bool
	// original -> rpol:apply-policy
	ApplyPolicy ApplyPolicy
	// original -> bgp-mp:prefix-limit
	PrefixLimit PrefixLimit
}

//struct for container bgp-mp:ipv6-multicast
type Ipv6Multicast struct {
	// original -> bgp-mp:enabled
	//bgp-mp:enabled's original type is boolean
	Enabled bool
	// original -> rpol:apply-policy
	ApplyPolicy ApplyPolicy
	// original -> bgp-mp:prefix-limit
	PrefixLimit PrefixLimit
}

//struct for container bgp-mp:ipv4-multicast
type Ipv4Multicast struct {
	// original -> bgp-mp:enabled
	//bgp-mp:enabled's original type is boolean
	Enabled bool
	// original -> rpol:apply-policy
	ApplyPolicy ApplyPolicy
	// original -> bgp-mp:prefix-limit
	PrefixLimit PrefixLimit
}

//struct for container bgp-mp:ipv6-unicast
type Ipv6Unicast struct {
	// original -> bgp-mp:enabled
	//bgp-mp:enabled's original type is boolean
	Enabled bool
	// original -> rpol:apply-policy
	ApplyPolicy ApplyPolicy
	// original -> bgp-mp:prefix-limit
	PrefixLimit PrefixLimit
	// original -> bgp-mp:send-default-route
	//bgp-mp:send-default-route's original type is boolean
	SendDefaultRoute bool
}

//struct for container bgp-mp:ipv4-unicast
type Ipv4Unicast struct {
	// original -> bgp-mp:enabled
	//bgp-mp:enabled's original type is boolean
	Enabled bool
	// original -> rpol:apply-policy
	ApplyPolicy ApplyPolicy
	// original -> bgp-mp:prefix-limit
	PrefixLimit PrefixLimit
	// original -> bgp-mp:send-default-route
	//bgp-mp:send-default-route's original type is boolean
	SendDefaultRoute bool
}

//struct for container bgp-mp:ibgp
type Ibgp struct {
	// original -> bgp-mp:maximum-paths
	MaximumPaths uint32
}

//struct for container bgp-mp:ebgp
type Ebgp struct {
	// original -> bgp-mp:allow-multiple-as
	//bgp-mp:allow-multiple-as's original type is boolean
	AllowMultipleAs bool
	// original -> bgp-mp:maximum-paths
	MaximumPaths uint32
}

//struct for container bgp-mp:use-multiple-paths
type UseMultiplePaths struct {
	// original -> bgp-mp:ebgp
	Ebgp Ebgp
	// original -> bgp-mp:ibgp
	Ibgp Ibgp
}

//struct for container bgp-mp:route-selection-options
type RouteSelectionOptions struct {
	// original -> bgp-mp:always-compare-med
	//bgp-mp:always-compare-med's original type is boolean
	AlwaysCompareMed bool
	// original -> bgp-mp:ignore-as-path-length
	//bgp-mp:ignore-as-path-length's original type is boolean
	IgnoreAsPathLength bool
	// original -> bgp-mp:external-compare-router-id
	//bgp-mp:external-compare-router-id's original type is boolean
	ExternalCompareRouterId bool
	// original -> bgp-mp:advertise-inactive-routes
	//bgp-mp:advertise-inactive-routes's original type is boolean
	AdvertiseInactiveRoutes bool
	// original -> bgp-mp:enable-aigp
	//bgp-mp:enable-aigp's original type is empty
	EnableAigp bool
	// original -> bgp-mp:ignore-next-hop-igp-metric
	//bgp-mp:ignore-next-hop-igp-metric's original type is boolean
	IgnoreNextHopIgpMetric bool
}

//struct for container bgp-mp:afi-safi
type AfiSafi struct {
	// original -> bgp-mp:afi-safi-name
	AfiSafiName string
	// original -> bgp-mp:route-selection-options
	RouteSelectionOptions RouteSelectionOptions
	// original -> bgp-mp:use-multiple-paths
	UseMultiplePaths UseMultiplePaths
	// original -> bgp-mp:ipv4-unicast
	Ipv4Unicast Ipv4Unicast
	// original -> bgp-mp:ipv6-unicast
	Ipv6Unicast Ipv6Unicast
	// original -> bgp-mp:ipv4-multicast
	Ipv4Multicast Ipv4Multicast
	// original -> bgp-mp:ipv6-multicast
	Ipv6Multicast Ipv6Multicast
	// original -> bgp-mp:ipv4-labelled-unicast
	Ipv4LabelledUnicast Ipv4LabelledUnicast
	// original -> bgp-mp:ipv6-labelled-unicast
	Ipv6LabelledUnicast Ipv6LabelledUnicast
	// original -> bgp-mp:l3vpn-ipv4-unicast
	L3vpnIpv4Unicast L3vpnIpv4Unicast
	// original -> bgp-mp:l3vpn-ipv6-unicast
	L3vpnIpv6Unicast L3vpnIpv6Unicast
	// original -> bgp-mp:l3vpn-ipv4-multicast
	L3vpnIpv4Multicast L3vpnIpv4Multicast
	// original -> bgp-mp:l3vpn-ipv6-multicast
	L3vpnIpv6Multicast L3vpnIpv6Multicast
	// original -> bgp-mp:l2vpn-vpls
	L2vpnVpls L2vpnVpls
	// original -> bgp-mp:l2vpn-evpn
	L2vpnEvpn L2vpnEvpn
}

//struct for container bgp:graceful-restart
type GracefulRestart struct {
	// original -> bgp:restart-time
	RestartTime uint16
	// original -> bgp:stale-routes-time
	//bgp:stale-routes-time's original type is decimal64
	StaleRoutesTime float64
}

//struct for container bgp:neighbor
type Neighbor struct {
	// original -> bgp:neighbor-address
	//bgp:neighbor-address's original type is inet:ip-address
	NeighborAddress net.IP
	// original -> bgp:peer-as
	//bgp:peer-as's original type is inet:as-number
	PeerAs uint32
	// original -> bgp:description
	Description string
	// original -> bgp:graceful-restart
	GracefulRestart GracefulRestart
	// original -> rpol:apply-policy
	ApplyPolicy ApplyPolicy
	// original -> bgp-mp:use-multiple-paths
	UseMultiplePaths UseMultiplePaths
	// original -> bgp-mp:afi-safi
	AfiSafiList []AfiSafi
	// original -> bgp:auth-password
	AuthPassword string
	// original -> bgp:peer-type
	PeerType PeerTypeDef
	// original -> bgp:timers
	Timers Timers
	// original -> bgp:ebgp-multihop
	EbgpMultihop EbgpMultihop
	// original -> bgp:route-reflector
	RouteReflector RouteReflector
	// original -> bgp:route-server
	RouteServer RouteServer
	// original -> bgp:remove-private-as
	RemovePrivateAs RemovePrivateAsOption
	// original -> bgp:bgp-logging-options
	BgpLoggingOptions BgpLoggingOptions
	// original -> bgp:transport-options
	TransportOptions TransportOptions
	// original -> bgp:local-address
	//bgp:local-address's original type is inet:ip-address
	LocalAddress net.IP
	// original -> bgp:route-flap-damping
	//bgp:route-flap-damping's original type is boolean
	RouteFlapDamping bool
	// original -> bgp:send-community
	SendCommunity CommunityType
	// original -> bgp:error-handling
	ErrorHandling ErrorHandling
	// original -> bgp:as-path-options
	AsPathOptions AsPathOptions
	// original -> bgp:add-paths
	AddPaths AddPaths
	// original -> bgp-op:bgp-neighbor-common-state
	BgpNeighborCommonState BgpNeighborCommonState
}

//struct for container bgp-op:bgp-group-common-state
type BgpGroupCommonState struct {
}

//struct for container bgp:peer-group
type PeerGroup struct {
	// original -> bgp:group-name
	GroupName string
	// original -> bgp-op:bgp-group-common-state
	BgpGroupCommonState BgpGroupCommonState
	// original -> bgp:description
	Description string
	// original -> bgp:graceful-restart
	GracefulRestart GracefulRestart
	// original -> rpol:apply-policy
	ApplyPolicy ApplyPolicy
	// original -> bgp-mp:use-multiple-paths
	UseMultiplePaths UseMultiplePaths
	// original -> bgp-mp:afi-safi
	AfiSafiList []AfiSafi
	// original -> bgp:auth-password
	AuthPassword string
	// original -> bgp:peer-type
	PeerType PeerTypeDef
	// original -> bgp:timers
	Timers Timers
	// original -> bgp:ebgp-multihop
	EbgpMultihop EbgpMultihop
	// original -> bgp:route-reflector
	RouteReflector RouteReflector
	// original -> bgp:route-server
	RouteServer RouteServer
	// original -> bgp:remove-private-as
	RemovePrivateAs RemovePrivateAsOption
	// original -> bgp:bgp-logging-options
	BgpLoggingOptions BgpLoggingOptions
	// original -> bgp:transport-options
	TransportOptions TransportOptions
	// original -> bgp:local-address
	//bgp:local-address's original type is inet:ip-address
	LocalAddress net.IP
	// original -> bgp:route-flap-damping
	//bgp:route-flap-damping's original type is boolean
	RouteFlapDamping bool
	// original -> bgp:send-community
	SendCommunity CommunityType
	// original -> bgp:error-handling
	ErrorHandling ErrorHandling
	// original -> bgp:as-path-options
	AsPathOptions AsPathOptions
	// original -> bgp:add-paths
	AddPaths AddPaths
	// original -> bgp:neighbor
	NeighborList []Neighbor
}

//struct for container bgp-op:bgp-global-state
type BgpGlobalState struct {
}

//struct for container bgp:confederation
type Confederation struct {
	// original -> bgp:identifier
	//bgp:identifier's original type is inet:as-number
	Identifier uint32
	// original -> bgp:member-as
	//original type is list of inet:as-number
	MemberAs []uint32
}

//struct for container bgp:default-route-distance
type DefaultRouteDistance struct {
	// original -> bgp:external-route-distance
	ExternalRouteDistance uint8
	// original -> bgp:internal-route-distance
	InternalRouteDistance uint8
}

//struct for container bgp:global
type Global struct {
	// original -> bgp:as
	//bgp:as's original type is inet:as-number
	As uint32
	// original -> bgp:router-id
	//bgp:router-id's original type is inet:ipv4-address
	RouterId net.IP
	// original -> bgp:default-route-distance
	DefaultRouteDistance DefaultRouteDistance
	// original -> bgp:confederation
	Confederation Confederation
	// original -> bgp-mp:use-multiple-paths
	UseMultiplePaths UseMultiplePaths
	// original -> bgp-mp:afi-safi
	AfiSafiList []AfiSafi
	// original -> bgp-op:bgp-global-state
	BgpGlobalState BgpGlobalState
}

//struct for container bgp:bgp
type Bgp struct {
	// original -> bgp:global
	Global Global
	// original -> bgp:peer-group
	PeerGroupList []PeerGroup
	// original -> bgp:neighbor
	NeighborList []Neighbor
	// original -> rpol:apply-policy
	ApplyPolicy ApplyPolicy
}