Newer
Older
/*
Package tapi is a generated package which contains definitions
of structs which represent a YANG schema. The generated schema can be
compressed by a series of transformations (compression was false
in this case).
This package was generated by /Users/mk/go/pkg/mod/github.com/openconfig/ygot@v0.10.0/genutil/names.go
- ../../models/tapi/tapi-topology@2019-03-31.yang
- ../../models/tapi/tapi-connectivity@2019-03-31.yang
- ../../models/tapi/tapi-common@2019-03-31.yang
- ../../models/tapi/tapi-photonic-media@2019-03-31.yang
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
Imported modules were sourced from:
- ../../yang/...
*/
package tapi
import (
"encoding/json"
"fmt"
"reflect"
"github.com/openconfig/ygot/ygot"
"github.com/openconfig/goyang/pkg/yang"
"github.com/openconfig/ygot/ytypes"
)
// Binary is a type that is used for fields that have a YANG type of
// binary. It is used such that binary fields can be distinguished from
// leaf-lists of uint8s (which are mapped to []uint8, equivalent to
// []byte in reflection).
type Binary []byte
// YANGEmpty is a type that is used for fields that have a YANG type of
// empty. It is used such that empty fields can be distinguished from boolean fields
// in the generated code.
type YANGEmpty bool
var (
SchemaTree map[string]*yang.Entry
)
func init() {
var err error
if SchemaTree, err = UnzipSchema(); err != nil {
panic("schema error: " + err.Error())
}
}
// Schema returns the details of the generated schema.
func Schema() (*ytypes.Schema, error) {
uzp, err := UnzipSchema()
if err != nil {
return nil, fmt.Errorf("cannot unzip schema, %v", err)
}
return &ytypes.Schema{
Root: &Device{},
SchemaTree: uzp,
Unmarshal: Unmarshal,
}, nil
}
// UnzipSchema unzips the zipped schema and returns a map of yang.Entry nodes,
// keyed by the name of the struct that the yang.Entry describes the schema for.
func UnzipSchema() (map[string]*yang.Entry, error) {
var schemaTree map[string]*yang.Entry
var err error
if schemaTree, err = ygot.GzipToSchema(ySchema); err != nil {
return nil, fmt.Errorf("could not unzip the schema; %v", err)
}
return schemaTree, nil
}
// Unmarshal unmarshals data, which must be RFC7951 JSON format, into
// destStruct, which must be non-nil and the correct GoStruct type. It returns
// an error if the destStruct is not found in the schema or the data cannot be
// unmarshaled. The supplied options (opts) are used to control the behaviour
// of the unmarshal function - for example, determining whether errors are
// thrown for unknown fields in the input JSON.
func Unmarshal(data []byte, destStruct ygot.GoStruct, opts ...ytypes.UnmarshalOpt) error {
tn := reflect.TypeOf(destStruct).Elem().Name()
schema, ok := SchemaTree[tn]
if !ok {
return fmt.Errorf("could not find schema for type %s", tn )
}
var jsonTree interface{}
if err := json.Unmarshal([]byte(data), &jsonTree); err != nil {
return err
}
return ytypes.Unmarshal(schema, destStruct, jsonTree, opts...)
}
// Device represents the /device YANG schema element.
type Device struct {
Context *TapiCommon_Context `path:"context" module:"tapi-common"`
}
// IsYANGGoStruct ensures that Device implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*Device) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *Device) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["Device"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *Device) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context represents the /tapi-common/context YANG schema element.
type TapiCommon_Context struct {
ConnectivityContext *TapiCommon_Context_ConnectivityContext `path:"connectivity-context" module:"tapi-connectivity"`
Name map[string]*TapiCommon_Context_Name `path:"name" module:"tapi-common"`
PathComputationContext *TapiCommon_Context_PathComputationContext `path:"path-computation-context" module:"tapi-path-computation"`
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
ServiceInterfacePoint map[string]*TapiCommon_Context_ServiceInterfacePoint `path:"service-interface-point" module:"tapi-common"`
TopologyContext *TapiCommon_Context_TopologyContext `path:"topology-context" module:"tapi-topology"`
Uuid *string `path:"uuid" module:"tapi-common"`
}
// IsYANGGoStruct ensures that TapiCommon_Context implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context) IsYANGGoStruct() {}
// NewName creates a new entry in the Name list of the
// TapiCommon_Context struct. The keys of the list are populated from the input
// arguments.
func (t *TapiCommon_Context) NewName(ValueName string) (*TapiCommon_Context_Name, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.Name == nil {
t.Name = make(map[string]*TapiCommon_Context_Name)
}
key := ValueName
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.Name[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list Name", key)
}
t.Name[key] = &TapiCommon_Context_Name{
ValueName: &ValueName,
}
return t.Name[key], nil
}
// NewServiceInterfacePoint creates a new entry in the ServiceInterfacePoint list of the
// TapiCommon_Context struct. The keys of the list are populated from the input
// arguments.
func (t *TapiCommon_Context) NewServiceInterfacePoint(Uuid string) (*TapiCommon_Context_ServiceInterfacePoint, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.ServiceInterfacePoint == nil {
t.ServiceInterfacePoint = make(map[string]*TapiCommon_Context_ServiceInterfacePoint)
}
key := Uuid
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.ServiceInterfacePoint[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list ServiceInterfacePoint", key)
}
t.ServiceInterfacePoint[key] = &TapiCommon_Context_ServiceInterfacePoint{
Uuid: &Uuid,
}
return t.ServiceInterfacePoint[key], nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext represents the /tapi-common/context/connectivity-context YANG schema element.
type TapiCommon_Context_ConnectivityContext struct {
Connection map[string]*TapiCommon_Context_ConnectivityContext_Connection `path:"connection" module:"tapi-connectivity"`
ConnectivityService map[string]*TapiCommon_Context_ConnectivityContext_ConnectivityService `path:"connectivity-service" module:"tapi-connectivity"`
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext) IsYANGGoStruct() {}
// NewConnection creates a new entry in the Connection list of the
// TapiCommon_Context_ConnectivityContext struct. The keys of the list are populated from the input
// arguments.
func (t *TapiCommon_Context_ConnectivityContext) NewConnection(Uuid string) (*TapiCommon_Context_ConnectivityContext_Connection, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.Connection == nil {
t.Connection = make(map[string]*TapiCommon_Context_ConnectivityContext_Connection)
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
key := Uuid
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.Connection[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list Connection", key)
}
t.Connection[key] = &TapiCommon_Context_ConnectivityContext_Connection{
Uuid: &Uuid,
}
return t.Connection[key], nil
}
// NewConnectivityService creates a new entry in the ConnectivityService list of the
// TapiCommon_Context_ConnectivityContext struct. The keys of the list are populated from the input
// arguments.
func (t *TapiCommon_Context_ConnectivityContext) NewConnectivityService(Uuid string) (*TapiCommon_Context_ConnectivityContext_ConnectivityService, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.ConnectivityService == nil {
t.ConnectivityService = make(map[string]*TapiCommon_Context_ConnectivityContext_ConnectivityService)
}
key := Uuid
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.ConnectivityService[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list ConnectivityService", key)
}
t.ConnectivityService[key] = &TapiCommon_Context_ConnectivityContext_ConnectivityService{
Uuid: &Uuid,
}
return t.ConnectivityService[key], nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_Connection represents the /tapi-common/context/connectivity-context/connection YANG schema element.
type TapiCommon_Context_ConnectivityContext_Connection struct {
BoundingNode *TapiCommon_Context_ConnectivityContext_Connection_BoundingNode `path:"bounding-node" module:"tapi-connectivity"`
ConnectionEndPoint map[TapiCommon_Context_ConnectivityContext_Connection_ConnectionEndPoint_Key]*TapiCommon_Context_ConnectivityContext_Connection_ConnectionEndPoint `path:"connection-end-point" module:"tapi-connectivity"`
Direction E_TapiConnectivity_ForwardingDirection `path:"direction" module:"tapi-connectivity"`
LayerProtocolName E_TapiConnectivity_LayerProtocolName `path:"layer-protocol-name" module:"tapi-connectivity"`
LifecycleState E_TapiCommon_LifecycleState `path:"lifecycle-state" module:"tapi-connectivity"`
LowerConnection map[string]*TapiCommon_Context_ConnectivityContext_Connection_LowerConnection `path:"lower-connection" module:"tapi-connectivity"`
Name map[string]*TapiCommon_Context_ConnectivityContext_Connection_Name `path:"name" module:"tapi-connectivity"`
OperationalState E_TapiCommon_OperationalState `path:"operational-state" module:"tapi-connectivity"`
Route map[string]*TapiCommon_Context_ConnectivityContext_Connection_Route `path:"route" module:"tapi-connectivity"`
SupportedClientLink map[TapiCommon_Context_ConnectivityContext_Connection_SupportedClientLink_Key]*TapiCommon_Context_ConnectivityContext_Connection_SupportedClientLink `path:"supported-client-link" module:"tapi-connectivity"`
SwitchControl map[string]*TapiCommon_Context_ConnectivityContext_Connection_SwitchControl `path:"switch-control" module:"tapi-connectivity"`
Uuid *string `path:"uuid" module:"tapi-connectivity"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_Connection implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_Connection) IsYANGGoStruct() {}
// TapiCommon_Context_ConnectivityContext_Connection_ConnectionEndPoint_Key represents the key for list ConnectionEndPoint of element /tapi-common/context/connectivity-context/connection.
type TapiCommon_Context_ConnectivityContext_Connection_ConnectionEndPoint_Key struct {
TopologyUuid string `path:"topology-uuid"`
NodeUuid string `path:"node-uuid"`
NodeEdgePointUuid string `path:"node-edge-point-uuid"`
ConnectionEndPointUuid string `path:"connection-end-point-uuid"`
}
// TapiCommon_Context_ConnectivityContext_Connection_SupportedClientLink_Key represents the key for list SupportedClientLink of element /tapi-common/context/connectivity-context/connection.
type TapiCommon_Context_ConnectivityContext_Connection_SupportedClientLink_Key struct {
TopologyUuid string `path:"topology-uuid"`
LinkUuid string `path:"link-uuid"`
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
// NewConnectionEndPoint creates a new entry in the ConnectionEndPoint list of the
// TapiCommon_Context_ConnectivityContext_Connection struct. The keys of the list are populated from the input
// arguments.
func (t *TapiCommon_Context_ConnectivityContext_Connection) NewConnectionEndPoint(TopologyUuid string, NodeUuid string, NodeEdgePointUuid string, ConnectionEndPointUuid string) (*TapiCommon_Context_ConnectivityContext_Connection_ConnectionEndPoint, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.ConnectionEndPoint == nil {
t.ConnectionEndPoint = make(map[TapiCommon_Context_ConnectivityContext_Connection_ConnectionEndPoint_Key]*TapiCommon_Context_ConnectivityContext_Connection_ConnectionEndPoint)
}
key := TapiCommon_Context_ConnectivityContext_Connection_ConnectionEndPoint_Key{
TopologyUuid: TopologyUuid,
NodeUuid: NodeUuid,
NodeEdgePointUuid: NodeEdgePointUuid,
ConnectionEndPointUuid: ConnectionEndPointUuid,
}
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.ConnectionEndPoint[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list ConnectionEndPoint", key)
}
t.ConnectionEndPoint[key] = &TapiCommon_Context_ConnectivityContext_Connection_ConnectionEndPoint{
TopologyUuid: &TopologyUuid,
NodeUuid: &NodeUuid,
NodeEdgePointUuid: &NodeEdgePointUuid,
ConnectionEndPointUuid: &ConnectionEndPointUuid,
}
return t.ConnectionEndPoint[key], nil
}
// NewLowerConnection creates a new entry in the LowerConnection list of the
// TapiCommon_Context_ConnectivityContext_Connection struct. The keys of the list are populated from the input
// arguments.
func (t *TapiCommon_Context_ConnectivityContext_Connection) NewLowerConnection(ConnectionUuid string) (*TapiCommon_Context_ConnectivityContext_Connection_LowerConnection, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.LowerConnection == nil {
t.LowerConnection = make(map[string]*TapiCommon_Context_ConnectivityContext_Connection_LowerConnection)
}
key := ConnectionUuid
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.LowerConnection[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list LowerConnection", key)
}
t.LowerConnection[key] = &TapiCommon_Context_ConnectivityContext_Connection_LowerConnection{
ConnectionUuid: &ConnectionUuid,
}
return t.LowerConnection[key], nil
}
// TapiCommon_Context_ConnectivityContext_Connection struct. The keys of the list are populated from the input
func (t *TapiCommon_Context_ConnectivityContext_Connection) NewName(ValueName string) (*TapiCommon_Context_ConnectivityContext_Connection_Name, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.Name == nil {
t.Name = make(map[string]*TapiCommon_Context_ConnectivityContext_Connection_Name)
}
key := ValueName
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.Name[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list Name", key)
}
t.Name[key] = &TapiCommon_Context_ConnectivityContext_Connection_Name{
ValueName: &ValueName,
}
return t.Name[key], nil
}
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
// NewRoute creates a new entry in the Route list of the
// TapiCommon_Context_ConnectivityContext_Connection struct. The keys of the list are populated from the input
// arguments.
func (t *TapiCommon_Context_ConnectivityContext_Connection) NewRoute(LocalId string) (*TapiCommon_Context_ConnectivityContext_Connection_Route, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.Route == nil {
t.Route = make(map[string]*TapiCommon_Context_ConnectivityContext_Connection_Route)
}
key := LocalId
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.Route[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list Route", key)
}
t.Route[key] = &TapiCommon_Context_ConnectivityContext_Connection_Route{
LocalId: &LocalId,
}
return t.Route[key], nil
}
// NewSupportedClientLink creates a new entry in the SupportedClientLink list of the
// TapiCommon_Context_ConnectivityContext_Connection struct. The keys of the list are populated from the input
// arguments.
func (t *TapiCommon_Context_ConnectivityContext_Connection) NewSupportedClientLink(TopologyUuid string, LinkUuid string) (*TapiCommon_Context_ConnectivityContext_Connection_SupportedClientLink, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.SupportedClientLink == nil {
t.SupportedClientLink = make(map[TapiCommon_Context_ConnectivityContext_Connection_SupportedClientLink_Key]*TapiCommon_Context_ConnectivityContext_Connection_SupportedClientLink)
}
key := TapiCommon_Context_ConnectivityContext_Connection_SupportedClientLink_Key{
TopologyUuid: TopologyUuid,
LinkUuid: LinkUuid,
}
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.SupportedClientLink[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list SupportedClientLink", key)
}
t.SupportedClientLink[key] = &TapiCommon_Context_ConnectivityContext_Connection_SupportedClientLink{
TopologyUuid: &TopologyUuid,
LinkUuid: &LinkUuid,
}
return t.SupportedClientLink[key], nil
}
// NewSwitchControl creates a new entry in the SwitchControl list of the
// TapiCommon_Context_ConnectivityContext_Connection struct. The keys of the list are populated from the input
// arguments.
func (t *TapiCommon_Context_ConnectivityContext_Connection) NewSwitchControl(Uuid string) (*TapiCommon_Context_ConnectivityContext_Connection_SwitchControl, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.SwitchControl == nil {
t.SwitchControl = make(map[string]*TapiCommon_Context_ConnectivityContext_Connection_SwitchControl)
}
key := Uuid
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.SwitchControl[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list SwitchControl", key)
}
t.SwitchControl[key] = &TapiCommon_Context_ConnectivityContext_Connection_SwitchControl{
Uuid: &Uuid,
}
return t.SwitchControl[key], nil
}
// ΛListKeyMap returns the keys of the TapiCommon_Context_ConnectivityContext_Connection struct, which is a YANG list entry.
func (t *TapiCommon_Context_ConnectivityContext_Connection) ΛListKeyMap() (map[string]interface{}, error) {
if t.Uuid == nil {
return nil, fmt.Errorf("nil value for key Uuid")
}
return map[string]interface{}{
"uuid": *t.Uuid,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_Connection) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_Connection"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_Connection) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_Connection_BoundingNode represents the /tapi-common/context/connectivity-context/connection/bounding-node YANG schema element.
type TapiCommon_Context_ConnectivityContext_Connection_BoundingNode struct {
NodeUuid *string `path:"node-uuid" module:"tapi-connectivity"`
TopologyUuid *string `path:"topology-uuid" module:"tapi-connectivity"`
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_Connection_BoundingNode implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_Connection_BoundingNode) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_Connection_BoundingNode) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_Connection_BoundingNode"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_Connection_BoundingNode) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_Connection_ConnectionEndPoint represents the /tapi-common/context/connectivity-context/connection/connection-end-point YANG schema element.
type TapiCommon_Context_ConnectivityContext_Connection_ConnectionEndPoint struct {
ConnectionEndPointUuid *string `path:"connection-end-point-uuid" module:"tapi-connectivity"`
NodeEdgePointUuid *string `path:"node-edge-point-uuid" module:"tapi-connectivity"`
NodeUuid *string `path:"node-uuid" module:"tapi-connectivity"`
TopologyUuid *string `path:"topology-uuid" module:"tapi-connectivity"`
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_Connection_ConnectionEndPoint implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
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
func (*TapiCommon_Context_ConnectivityContext_Connection_ConnectionEndPoint) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_ConnectivityContext_Connection_ConnectionEndPoint struct, which is a YANG list entry.
func (t *TapiCommon_Context_ConnectivityContext_Connection_ConnectionEndPoint) ΛListKeyMap() (map[string]interface{}, error) {
if t.ConnectionEndPointUuid == nil {
return nil, fmt.Errorf("nil value for key ConnectionEndPointUuid")
}
if t.NodeEdgePointUuid == nil {
return nil, fmt.Errorf("nil value for key NodeEdgePointUuid")
}
if t.NodeUuid == nil {
return nil, fmt.Errorf("nil value for key NodeUuid")
}
if t.TopologyUuid == nil {
return nil, fmt.Errorf("nil value for key TopologyUuid")
}
return map[string]interface{}{
"connection-end-point-uuid": *t.ConnectionEndPointUuid,
"node-edge-point-uuid": *t.NodeEdgePointUuid,
"node-uuid": *t.NodeUuid,
"topology-uuid": *t.TopologyUuid,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_Connection_ConnectionEndPoint) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_Connection_ConnectionEndPoint"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_Connection_ConnectionEndPoint) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_Connection_LowerConnection represents the /tapi-common/context/connectivity-context/connection/lower-connection YANG schema element.
type TapiCommon_Context_ConnectivityContext_Connection_LowerConnection struct {
ConnectionUuid *string `path:"connection-uuid" module:"tapi-connectivity"`
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_Connection_LowerConnection implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_Connection_LowerConnection) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_ConnectivityContext_Connection_LowerConnection struct, which is a YANG list entry.
func (t *TapiCommon_Context_ConnectivityContext_Connection_LowerConnection) ΛListKeyMap() (map[string]interface{}, error) {
if t.ConnectionUuid == nil {
return nil, fmt.Errorf("nil value for key ConnectionUuid")
"connection-uuid": *t.ConnectionUuid,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_Connection_LowerConnection) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_Connection_LowerConnection"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_Connection_LowerConnection) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_Connection_Name represents the /tapi-common/context/connectivity-context/connection/name YANG schema element.
type TapiCommon_Context_ConnectivityContext_Connection_Name struct {
Value *string `path:"value" module:"tapi-connectivity"`
ValueName *string `path:"value-name" module:"tapi-connectivity"`
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_Connection_Name implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_Connection_Name) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_ConnectivityContext_Connection_Name struct, which is a YANG list entry.
func (t *TapiCommon_Context_ConnectivityContext_Connection_Name) ΛListKeyMap() (map[string]interface{}, error) {
if t.ValueName == nil {
return nil, fmt.Errorf("nil value for key ValueName")
}
return map[string]interface{}{
"value-name": *t.ValueName,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_Connection_Name) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_Connection_Name"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_Connection_Name) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_Connection_Route represents the /tapi-common/context/connectivity-context/connection/route YANG schema element.
type TapiCommon_Context_ConnectivityContext_Connection_Route struct {
ConnectionEndPoint map[TapiCommon_Context_ConnectivityContext_Connection_Route_ConnectionEndPoint_Key]*TapiCommon_Context_ConnectivityContext_Connection_Route_ConnectionEndPoint `path:"connection-end-point" module:"tapi-connectivity"`
LocalId *string `path:"local-id" module:"tapi-connectivity"`
Name map[string]*TapiCommon_Context_ConnectivityContext_Connection_Route_Name `path:"name" module:"tapi-connectivity"`
ResilienceRoute *TapiCommon_Context_ConnectivityContext_Connection_Route_ResilienceRoute `path:"resilience-route" module:"tapi-connectivity"`
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_Connection_Route implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_Connection_Route) IsYANGGoStruct() {}
// TapiCommon_Context_ConnectivityContext_Connection_Route_ConnectionEndPoint_Key represents the key for list ConnectionEndPoint of element /tapi-common/context/connectivity-context/connection/route.
type TapiCommon_Context_ConnectivityContext_Connection_Route_ConnectionEndPoint_Key struct {
TopologyUuid string `path:"topology-uuid"`
NodeUuid string `path:"node-uuid"`
NodeEdgePointUuid string `path:"node-edge-point-uuid"`
ConnectionEndPointUuid string `path:"connection-end-point-uuid"`
// NewConnectionEndPoint creates a new entry in the ConnectionEndPoint list of the
// TapiCommon_Context_ConnectivityContext_Connection_Route struct. The keys of the list are populated from the input
func (t *TapiCommon_Context_ConnectivityContext_Connection_Route) NewConnectionEndPoint(TopologyUuid string, NodeUuid string, NodeEdgePointUuid string, ConnectionEndPointUuid string) (*TapiCommon_Context_ConnectivityContext_Connection_Route_ConnectionEndPoint, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.ConnectionEndPoint == nil {
t.ConnectionEndPoint = make(map[TapiCommon_Context_ConnectivityContext_Connection_Route_ConnectionEndPoint_Key]*TapiCommon_Context_ConnectivityContext_Connection_Route_ConnectionEndPoint)
key := TapiCommon_Context_ConnectivityContext_Connection_Route_ConnectionEndPoint_Key{
TopologyUuid: TopologyUuid,
NodeUuid: NodeUuid,
NodeEdgePointUuid: NodeEdgePointUuid,
ConnectionEndPointUuid: ConnectionEndPointUuid,
}
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.ConnectionEndPoint[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list ConnectionEndPoint", key)
t.ConnectionEndPoint[key] = &TapiCommon_Context_ConnectivityContext_Connection_Route_ConnectionEndPoint{
TopologyUuid: &TopologyUuid,
NodeUuid: &NodeUuid,
NodeEdgePointUuid: &NodeEdgePointUuid,
ConnectionEndPointUuid: &ConnectionEndPointUuid,
return t.ConnectionEndPoint[key], nil
}
// NewName creates a new entry in the Name list of the
// TapiCommon_Context_ConnectivityContext_Connection_Route struct. The keys of the list are populated from the input
func (t *TapiCommon_Context_ConnectivityContext_Connection_Route) NewName(ValueName string) (*TapiCommon_Context_ConnectivityContext_Connection_Route_Name, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.Name == nil {
t.Name = make(map[string]*TapiCommon_Context_ConnectivityContext_Connection_Route_Name)
}
key := ValueName
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.Name[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list Name", key)
}
t.Name[key] = &TapiCommon_Context_ConnectivityContext_Connection_Route_Name{
ValueName: &ValueName,
}
return t.Name[key], nil
}
// ΛListKeyMap returns the keys of the TapiCommon_Context_ConnectivityContext_Connection_Route struct, which is a YANG list entry.
func (t *TapiCommon_Context_ConnectivityContext_Connection_Route) ΛListKeyMap() (map[string]interface{}, error) {
if t.LocalId == nil {
return nil, fmt.Errorf("nil value for key LocalId")
}
return map[string]interface{}{
"local-id": *t.LocalId,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_Connection_Route) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_Connection_Route"], t, opts...); err != nil {
return err
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_Connection_Route) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_Connection_Route_ConnectionEndPoint represents the /tapi-common/context/connectivity-context/connection/route/connection-end-point YANG schema element.
type TapiCommon_Context_ConnectivityContext_Connection_Route_ConnectionEndPoint struct {
ConnectionEndPointUuid *string `path:"connection-end-point-uuid" module:"tapi-connectivity"`
NodeEdgePointUuid *string `path:"node-edge-point-uuid" module:"tapi-connectivity"`
NodeUuid *string `path:"node-uuid" module:"tapi-connectivity"`
TopologyUuid *string `path:"topology-uuid" module:"tapi-connectivity"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_Connection_Route_ConnectionEndPoint implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_Connection_Route_ConnectionEndPoint) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_ConnectivityContext_Connection_Route_ConnectionEndPoint struct, which is a YANG list entry.
func (t *TapiCommon_Context_ConnectivityContext_Connection_Route_ConnectionEndPoint) ΛListKeyMap() (map[string]interface{}, error) {
if t.ConnectionEndPointUuid == nil {
return nil, fmt.Errorf("nil value for key ConnectionEndPointUuid")
if t.NodeEdgePointUuid == nil {
return nil, fmt.Errorf("nil value for key NodeEdgePointUuid")
if t.NodeUuid == nil {
return nil, fmt.Errorf("nil value for key NodeUuid")
}
if t.TopologyUuid == nil {
return nil, fmt.Errorf("nil value for key TopologyUuid")
}
return map[string]interface{}{
"connection-end-point-uuid": *t.ConnectionEndPointUuid,
"node-edge-point-uuid": *t.NodeEdgePointUuid,
"node-uuid": *t.NodeUuid,
"topology-uuid": *t.TopologyUuid,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_Connection_Route_ConnectionEndPoint) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_Connection_Route_ConnectionEndPoint"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_Connection_Route_ConnectionEndPoint) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_Connection_Route_Name represents the /tapi-common/context/connectivity-context/connection/route/name YANG schema element.
type TapiCommon_Context_ConnectivityContext_Connection_Route_Name struct {
Value *string `path:"value" module:"tapi-connectivity"`
ValueName *string `path:"value-name" module:"tapi-connectivity"`
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_Connection_Route_Name implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_Connection_Route_Name) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_ConnectivityContext_Connection_Route_Name struct, which is a YANG list entry.
func (t *TapiCommon_Context_ConnectivityContext_Connection_Route_Name) ΛListKeyMap() (map[string]interface{}, error) {
if t.ValueName == nil {
return nil, fmt.Errorf("nil value for key ValueName")
}
return map[string]interface{}{
"value-name": *t.ValueName,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_Connection_Route_Name) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_Connection_Route_Name"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_Connection_Route_Name) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_Connection_Route_ResilienceRoute represents the /tapi-common/context/connectivity-context/connection/route/resilience-route YANG schema element.
type TapiCommon_Context_ConnectivityContext_Connection_Route_ResilienceRoute struct {
Priority *uint64 `path:"priority" module:"tapi-connectivity"`
RouteState E_TapiConnectivity_RouteState `path:"route-state" module:"tapi-connectivity"`
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_Connection_Route_ResilienceRoute implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
func (*TapiCommon_Context_ConnectivityContext_Connection_Route_ResilienceRoute) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_Connection_Route_ResilienceRoute) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_Connection_Route_ResilienceRoute"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_Connection_Route_ResilienceRoute) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_Connection_SupportedClientLink represents the /tapi-common/context/connectivity-context/connection/supported-client-link YANG schema element.
type TapiCommon_Context_ConnectivityContext_Connection_SupportedClientLink struct {
LinkUuid *string `path:"link-uuid" module:"tapi-connectivity"`
TopologyUuid *string `path:"topology-uuid" module:"tapi-connectivity"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_Connection_SupportedClientLink implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_Connection_SupportedClientLink) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_ConnectivityContext_Connection_SupportedClientLink struct, which is a YANG list entry.
func (t *TapiCommon_Context_ConnectivityContext_Connection_SupportedClientLink) ΛListKeyMap() (map[string]interface{}, error) {
if t.LinkUuid == nil {
return nil, fmt.Errorf("nil value for key LinkUuid")
}
if t.TopologyUuid == nil {
return nil, fmt.Errorf("nil value for key TopologyUuid")
}
return map[string]interface{}{
"topology-uuid": *t.TopologyUuid,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_Connection_SupportedClientLink) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_Connection_SupportedClientLink"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
func (t *TapiCommon_Context_ConnectivityContext_Connection_SupportedClientLink) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_Connection_SwitchControl represents the /tapi-common/context/connectivity-context/connection/switch-control YANG schema element.
type TapiCommon_Context_ConnectivityContext_Connection_SwitchControl struct {
FaultConditionDetermination E_TapiConnectivity_FaultConditionDetermination `path:"fault-condition-determination" module:"tapi-connectivity"`
HoldOffTime *uint64 `path:"hold-off-time" module:"tapi-connectivity"`
IsCoordinatedSwitchingBothEnds *bool `path:"is-coordinated-switching-both-ends" module:"tapi-connectivity"`
IsFrozen *bool `path:"is-frozen" module:"tapi-connectivity"`
IsLockOut *bool `path:"is-lock-out" module:"tapi-connectivity"`
MaxSwitchTimes *uint64 `path:"max-switch-times" module:"tapi-connectivity"`
Name map[string]*TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Name `path:"name" module:"tapi-connectivity"`
PreferredRestorationLayer []E_TapiConnectivity_LayerProtocolName `path:"preferred-restoration-layer" module:"tapi-connectivity"`
ResilienceType *TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResilienceType `path:"resilience-type" module:"tapi-connectivity"`
ResiliencyRouteConstraint map[string]*TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint `path:"resiliency-route-constraint" module:"tapi-connectivity"`
RestorationCoordinateType E_TapiConnectivity_CoordinateType `path:"restoration-coordinate-type" module:"tapi-connectivity"`
RestorePriority *uint64 `path:"restore-priority" module:"tapi-connectivity"`
ReversionMode E_TapiConnectivity_ReversionMode `path:"reversion-mode" module:"tapi-connectivity"`
SelectionControl E_TapiConnectivity_SelectionControl `path:"selection-control" module:"tapi-connectivity"`
SubSwitchControl map[TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_SubSwitchControl_Key]*TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_SubSwitchControl `path:"sub-switch-control" module:"tapi-connectivity"`
Switch map[string]*TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Switch `path:"switch" module:"tapi-connectivity"`
Uuid *string `path:"uuid" module:"tapi-connectivity"`
WaitToRevertTime *uint64 `path:"wait-to-revert-time" module:"tapi-connectivity"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_Connection_SwitchControl implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_Connection_SwitchControl) IsYANGGoStruct() {}
// TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_SubSwitchControl_Key represents the key for list SubSwitchControl of element /tapi-common/context/connectivity-context/connection/switch-control.
type TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_SubSwitchControl_Key struct {
ConnectionUuid string `path:"connection-uuid"`
SwitchControlUuid string `path:"switch-control-uuid"`
// NewName creates a new entry in the Name list of the
// TapiCommon_Context_ConnectivityContext_Connection_SwitchControl struct. The keys of the list are populated from the input
func (t *TapiCommon_Context_ConnectivityContext_Connection_SwitchControl) NewName(ValueName string) (*TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Name, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.Name == nil {
t.Name = make(map[string]*TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Name)
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.Name[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list Name", key)
t.Name[key] = &TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Name{
ValueName: &ValueName,
// NewResiliencyRouteConstraint creates a new entry in the ResiliencyRouteConstraint list of the
// TapiCommon_Context_ConnectivityContext_Connection_SwitchControl struct. The keys of the list are populated from the input
func (t *TapiCommon_Context_ConnectivityContext_Connection_SwitchControl) NewResiliencyRouteConstraint(LocalId string) (*TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.ResiliencyRouteConstraint == nil {
t.ResiliencyRouteConstraint = make(map[string]*TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint)
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.ResiliencyRouteConstraint[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list ResiliencyRouteConstraint", key)
t.ResiliencyRouteConstraint[key] = &TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint{
LocalId: &LocalId,
return t.ResiliencyRouteConstraint[key], nil
// NewSubSwitchControl creates a new entry in the SubSwitchControl list of the
// TapiCommon_Context_ConnectivityContext_Connection_SwitchControl struct. The keys of the list are populated from the input
func (t *TapiCommon_Context_ConnectivityContext_Connection_SwitchControl) NewSubSwitchControl(ConnectionUuid string, SwitchControlUuid string) (*TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_SubSwitchControl, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.SubSwitchControl == nil {
t.SubSwitchControl = make(map[TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_SubSwitchControl_Key]*TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_SubSwitchControl)
key := TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_SubSwitchControl_Key{
ConnectionUuid: ConnectionUuid,
SwitchControlUuid: SwitchControlUuid,
}
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.SubSwitchControl[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list SubSwitchControl", key)
t.SubSwitchControl[key] = &TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_SubSwitchControl{
ConnectionUuid: &ConnectionUuid,
SwitchControlUuid: &SwitchControlUuid,
// NewSwitch creates a new entry in the Switch list of the
// TapiCommon_Context_ConnectivityContext_Connection_SwitchControl struct. The keys of the list are populated from the input
func (t *TapiCommon_Context_ConnectivityContext_Connection_SwitchControl) NewSwitch(LocalId string) (*TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Switch, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.Switch == nil {
t.Switch = make(map[string]*TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Switch)
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.Switch[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list Switch", key)
t.Switch[key] = &TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Switch{
LocalId: &LocalId,
// ΛListKeyMap returns the keys of the TapiCommon_Context_ConnectivityContext_Connection_SwitchControl struct, which is a YANG list entry.
func (t *TapiCommon_Context_ConnectivityContext_Connection_SwitchControl) ΛListKeyMap() (map[string]interface{}, error) {
if t.Uuid == nil {
return nil, fmt.Errorf("nil value for key Uuid")
}
return map[string]interface{}{
"uuid": *t.Uuid,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_Connection_SwitchControl) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_Connection_SwitchControl"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_Connection_SwitchControl) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Name represents the /tapi-common/context/connectivity-context/connection/switch-control/name YANG schema element.
type TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Name struct {
Value *string `path:"value" module:"tapi-connectivity"`
ValueName *string `path:"value-name" module:"tapi-connectivity"`
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Name implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Name) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Name struct, which is a YANG list entry.
func (t *TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Name) ΛListKeyMap() (map[string]interface{}, error) {
if t.ValueName == nil {
return nil, fmt.Errorf("nil value for key ValueName")
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Name) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Name"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Name) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResilienceType represents the /tapi-common/context/connectivity-context/connection/switch-control/resilience-type YANG schema element.
type TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResilienceType struct {
ProtectionType E_TapiTopology_ProtectionType `path:"protection-type" module:"tapi-connectivity"`
RestorationPolicy E_TapiTopology_RestorationPolicy `path:"restoration-policy" module:"tapi-connectivity"`
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResilienceType implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResilienceType) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResilienceType) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResilienceType"], t, opts...); err != nil {
return err
}
return nil
1136
1137
1138
1139
1140
1141
1142
1143
1144
1145
1146
1147
1148
1149
1150
1151
1152
1153
1154
1155
1156
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResilienceType) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint represents the /tapi-common/context/connectivity-context/connection/switch-control/resiliency-route-constraint YANG schema element.
type TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint struct {
LocalId *string `path:"local-id" module:"tapi-connectivity"`
Name map[string]*TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_Name `path:"name" module:"tapi-connectivity"`
Priority *uint64 `path:"priority" module:"tapi-connectivity"`
RoutingConstraint *TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint `path:"routing-constraint" module:"tapi-connectivity"`
TopologyConstraint *TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_TopologyConstraint `path:"topology-constraint" module:"tapi-connectivity"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint) IsYANGGoStruct() {}
// NewName creates a new entry in the Name list of the
// TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint struct. The keys of the list are populated from the input
func (t *TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint) NewName(ValueName string) (*TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_Name, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.Name == nil {
t.Name = make(map[string]*TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_Name)
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.Name[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list Name", key)
t.Name[key] = &TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_Name{
ValueName: &ValueName,
// ΛListKeyMap returns the keys of the TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint struct, which is a YANG list entry.
func (t *TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint) ΛListKeyMap() (map[string]interface{}, error) {
if t.LocalId == nil {
return nil, fmt.Errorf("nil value for key LocalId")
}
return map[string]interface{}{
"local-id": *t.LocalId,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint"], t, opts...); err != nil {
return err
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_Name represents the /tapi-common/context/connectivity-context/connection/switch-control/resiliency-route-constraint/name YANG schema element.
type TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_Name struct {
Value *string `path:"value" module:"tapi-connectivity"`
ValueName *string `path:"value-name" module:"tapi-connectivity"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_Name implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_Name) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_Name struct, which is a YANG list entry.
func (t *TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_Name) ΛListKeyMap() (map[string]interface{}, error) {
if t.ValueName == nil {
return nil, fmt.Errorf("nil value for key ValueName")
return map[string]interface{}{
"value-name": *t.ValueName,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_Name) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_Name"], t, opts...); err != nil {
return err
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_Name) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint represents the /tapi-common/context/connectivity-context/connection/switch-control/resiliency-route-constraint/routing-constraint YANG schema element.
type TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint struct {
CostCharacteristic map[string]*TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint_CostCharacteristic `path:"cost-characteristic" module:"tapi-connectivity"`
DiversityPolicy E_TapiPathComputation_DiversityPolicy `path:"diversity-policy" module:"tapi-connectivity"`
IsExclusive *bool `path:"is-exclusive" module:"tapi-connectivity"`
LatencyCharacteristic map[string]*TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint_LatencyCharacteristic `path:"latency-characteristic" module:"tapi-connectivity"`
MaxAllowedCost *TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint_MaxAllowedCost `path:"max-allowed-cost" module:"tapi-connectivity"`
MaxAllowedDelay *TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint_MaxAllowedDelay `path:"max-allowed-delay" module:"tapi-connectivity"`
MaxAllowedHops *TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint_MaxAllowedHops `path:"max-allowed-hops" module:"tapi-connectivity"`
RiskDiversityCharacteristic map[string]*TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint_RiskDiversityCharacteristic `path:"risk-diversity-characteristic" module:"tapi-connectivity"`
RouteObjectiveFunction E_TapiPathComputation_RouteObjectiveFunction `path:"route-objective-function" module:"tapi-connectivity"`
TolerableImpact E_TapiPathComputation_GradesOfImpact `path:"tolerable-impact" module:"tapi-connectivity"`
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint) IsYANGGoStruct() {}
// NewCostCharacteristic creates a new entry in the CostCharacteristic list of the
// TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint struct. The keys of the list are populated from the input
func (t *TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint) NewCostCharacteristic(CostName string) (*TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint_CostCharacteristic, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.CostCharacteristic == nil {
t.CostCharacteristic = make(map[string]*TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint_CostCharacteristic)
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.CostCharacteristic[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list CostCharacteristic", key)
t.CostCharacteristic[key] = &TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint_CostCharacteristic{
CostName: &CostName,
return t.CostCharacteristic[key], nil
// NewLatencyCharacteristic creates a new entry in the LatencyCharacteristic list of the
// TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint struct. The keys of the list are populated from the input
func (t *TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint) NewLatencyCharacteristic(TrafficPropertyName string) (*TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint_LatencyCharacteristic, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.LatencyCharacteristic == nil {
t.LatencyCharacteristic = make(map[string]*TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint_LatencyCharacteristic)
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.LatencyCharacteristic[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list LatencyCharacteristic", key)
t.LatencyCharacteristic[key] = &TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint_LatencyCharacteristic{
TrafficPropertyName: &TrafficPropertyName,
return t.LatencyCharacteristic[key], nil
// NewRiskDiversityCharacteristic creates a new entry in the RiskDiversityCharacteristic list of the
// TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint struct. The keys of the list are populated from the input
func (t *TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint) NewRiskDiversityCharacteristic(RiskCharacteristicName string) (*TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint_RiskDiversityCharacteristic, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.RiskDiversityCharacteristic == nil {
t.RiskDiversityCharacteristic = make(map[string]*TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint_RiskDiversityCharacteristic)
}
key := RiskCharacteristicName
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.RiskDiversityCharacteristic[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list RiskDiversityCharacteristic", key)
t.RiskDiversityCharacteristic[key] = &TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint_RiskDiversityCharacteristic{
return t.RiskDiversityCharacteristic[key], nil
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint"], t, opts...); err != nil {
return err
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint_CostCharacteristic represents the /tapi-common/context/connectivity-context/connection/switch-control/resiliency-route-constraint/routing-constraint/cost-characteristic YANG schema element.
type TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint_CostCharacteristic struct {
CostAlgorithm *string `path:"cost-algorithm" module:"tapi-connectivity"`
CostName *string `path:"cost-name" module:"tapi-connectivity"`
CostValue *string `path:"cost-value" module:"tapi-connectivity"`
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint_CostCharacteristic implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint_CostCharacteristic) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint_CostCharacteristic struct, which is a YANG list entry.
func (t *TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint_CostCharacteristic) ΛListKeyMap() (map[string]interface{}, error) {
if t.CostName == nil {
return nil, fmt.Errorf("nil value for key CostName")
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint_CostCharacteristic) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint_CostCharacteristic"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint_CostCharacteristic) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint_LatencyCharacteristic represents the /tapi-common/context/connectivity-context/connection/switch-control/resiliency-route-constraint/routing-constraint/latency-characteristic YANG schema element.
type TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint_LatencyCharacteristic struct {
FixedLatencyCharacteristic *string `path:"fixed-latency-characteristic" module:"tapi-connectivity"`
JitterCharacteristic *string `path:"jitter-characteristic" module:"tapi-connectivity"`
QueingLatencyCharacteristic *string `path:"queing-latency-characteristic" module:"tapi-connectivity"`
TrafficPropertyName *string `path:"traffic-property-name" module:"tapi-connectivity"`
WanderCharacteristic *string `path:"wander-characteristic" module:"tapi-connectivity"`
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint_LatencyCharacteristic implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint_LatencyCharacteristic) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint_LatencyCharacteristic struct, which is a YANG list entry.
func (t *TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint_LatencyCharacteristic) ΛListKeyMap() (map[string]interface{}, error) {
if t.TrafficPropertyName == nil {
return nil, fmt.Errorf("nil value for key TrafficPropertyName")
}
return map[string]interface{}{
"traffic-property-name": *t.TrafficPropertyName,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint_LatencyCharacteristic) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint_LatencyCharacteristic"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint_LatencyCharacteristic) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint_MaxAllowedCost represents the /tapi-common/context/connectivity-context/connection/switch-control/resiliency-route-constraint/routing-constraint/max-allowed-cost YANG schema element.
type TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint_MaxAllowedCost struct {
Priority *uint64 `path:"priority" module:"tapi-connectivity"`
Value *uint64 `path:"value" module:"tapi-connectivity"`
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint_MaxAllowedCost implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint_MaxAllowedCost) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint_MaxAllowedCost) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint_MaxAllowedCost"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint_MaxAllowedCost) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint_MaxAllowedDelay represents the /tapi-common/context/connectivity-context/connection/switch-control/resiliency-route-constraint/routing-constraint/max-allowed-delay YANG schema element.
type TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint_MaxAllowedDelay struct {
Priority *uint64 `path:"priority" module:"tapi-connectivity"`
Value *uint64 `path:"value" module:"tapi-connectivity"`
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint_MaxAllowedDelay implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint_MaxAllowedDelay) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint_MaxAllowedDelay) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint_MaxAllowedDelay"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint_MaxAllowedDelay) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint_MaxAllowedHops represents the /tapi-common/context/connectivity-context/connection/switch-control/resiliency-route-constraint/routing-constraint/max-allowed-hops YANG schema element.
type TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint_MaxAllowedHops struct {
Priority *uint64 `path:"priority" module:"tapi-connectivity"`
Value *uint64 `path:"value" module:"tapi-connectivity"`
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint_MaxAllowedHops implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint_MaxAllowedHops) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint_MaxAllowedHops) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint_MaxAllowedHops"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint_MaxAllowedHops) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint_RiskDiversityCharacteristic represents the /tapi-common/context/connectivity-context/connection/switch-control/resiliency-route-constraint/routing-constraint/risk-diversity-characteristic YANG schema element.
type TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint_RiskDiversityCharacteristic struct {
RiskCharacteristicName *string `path:"risk-characteristic-name" module:"tapi-connectivity"`
RiskIdentifierList []string `path:"risk-identifier-list" module:"tapi-connectivity"`
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint_RiskDiversityCharacteristic implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint_RiskDiversityCharacteristic) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint_RiskDiversityCharacteristic struct, which is a YANG list entry.
func (t *TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint_RiskDiversityCharacteristic) ΛListKeyMap() (map[string]interface{}, error) {
if t.RiskCharacteristicName == nil {
return nil, fmt.Errorf("nil value for key RiskCharacteristicName")
"risk-characteristic-name": *t.RiskCharacteristicName,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint_RiskDiversityCharacteristic) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint_RiskDiversityCharacteristic"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
1532
1533
1534
1535
1536
1537
1538
1539
1540
1541
1542
1543
1544
1545
1546
1547
1548
1549
1550
1551
1552
1553
func (t *TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_RoutingConstraint_RiskDiversityCharacteristic) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_TopologyConstraint represents the /tapi-common/context/connectivity-context/connection/switch-control/resiliency-route-constraint/topology-constraint YANG schema element.
type TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_TopologyConstraint struct {
AvoidTopology *string `path:"avoid-topology" module:"tapi-connectivity"`
ConstraintWeight *uint64 `path:"constraint-weight" module:"tapi-connectivity"`
ExcludeLink *string `path:"exclude-link" module:"tapi-connectivity"`
ExcludeNode *string `path:"exclude-node" module:"tapi-connectivity"`
ExcludeNodeEdgePoint *string `path:"exclude-node-edge-point" module:"tapi-connectivity"`
ExcludePath *string `path:"exclude-path" module:"tapi-connectivity"`
IncludeLink *string `path:"include-link" module:"tapi-connectivity"`
IncludeNode *string `path:"include-node" module:"tapi-connectivity"`
IncludeNodeEdgePoint *string `path:"include-node-edge-point" module:"tapi-connectivity"`
IncludePath *string `path:"include-path" module:"tapi-connectivity"`
IncludeTopology *string `path:"include-topology" module:"tapi-connectivity"`
LocalId *string `path:"local-id" module:"tapi-connectivity"`
Name map[string]*TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_TopologyConstraint_Name `path:"name" module:"tapi-connectivity"`
PreferredTransportLayer E_TapiPathComputation_LayerProtocolName `path:"preferred-transport-layer" module:"tapi-connectivity"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_TopologyConstraint implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_TopologyConstraint) IsYANGGoStruct() {}
// NewName creates a new entry in the Name list of the
// TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_TopologyConstraint struct. The keys of the list are populated from the input
// arguments.
func (t *TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_TopologyConstraint) NewName(ValueName string) (*TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_TopologyConstraint_Name, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.Name == nil {
t.Name = make(map[string]*TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_TopologyConstraint_Name)
key := ValueName
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.Name[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list Name", key)
t.Name[key] = &TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_TopologyConstraint_Name{
ValueName: &ValueName,
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_TopologyConstraint) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_TopologyConstraint"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_TopologyConstraint) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_TopologyConstraint_Name represents the /tapi-common/context/connectivity-context/connection/switch-control/resiliency-route-constraint/topology-constraint/name YANG schema element.
type TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_TopologyConstraint_Name struct {
Value *string `path:"value" module:"tapi-connectivity"`
ValueName *string `path:"value-name" module:"tapi-connectivity"`
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_TopologyConstraint_Name implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_TopologyConstraint_Name) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_TopologyConstraint_Name struct, which is a YANG list entry.
func (t *TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_TopologyConstraint_Name) ΛListKeyMap() (map[string]interface{}, error) {
if t.ValueName == nil {
return nil, fmt.Errorf("nil value for key ValueName")
}
return map[string]interface{}{
"value-name": *t.ValueName,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_TopologyConstraint_Name) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_TopologyConstraint_Name"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_ResiliencyRouteConstraint_TopologyConstraint_Name) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_SubSwitchControl represents the /tapi-common/context/connectivity-context/connection/switch-control/sub-switch-control YANG schema element.
type TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_SubSwitchControl struct {
ConnectionUuid *string `path:"connection-uuid" module:"tapi-connectivity"`
SwitchControlUuid *string `path:"switch-control-uuid" module:"tapi-connectivity"`
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_SubSwitchControl implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_SubSwitchControl) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_SubSwitchControl struct, which is a YANG list entry.
func (t *TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_SubSwitchControl) ΛListKeyMap() (map[string]interface{}, error) {
if t.ConnectionUuid == nil {
return nil, fmt.Errorf("nil value for key ConnectionUuid")
}
if t.SwitchControlUuid == nil {
return nil, fmt.Errorf("nil value for key SwitchControlUuid")
"connection-uuid": *t.ConnectionUuid,
"switch-control-uuid": *t.SwitchControlUuid,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_SubSwitchControl) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_SubSwitchControl"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_SubSwitchControl) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Switch represents the /tapi-common/context/connectivity-context/connection/switch-control/switch YANG schema element.
type TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Switch struct {
LocalId *string `path:"local-id" module:"tapi-connectivity"`
Name map[string]*TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Switch_Name `path:"name" module:"tapi-connectivity"`
SelectedConnectionEndPoint map[TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Switch_SelectedConnectionEndPoint_Key]*TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Switch_SelectedConnectionEndPoint `path:"selected-connection-end-point" module:"tapi-connectivity"`
SelectedRoute map[TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Switch_SelectedRoute_Key]*TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Switch_SelectedRoute `path:"selected-route" module:"tapi-connectivity"`
SelectionReason E_TapiConnectivity_SelectionReason `path:"selection-reason" module:"tapi-connectivity"`
SwitchDirection E_TapiConnectivity_PortDirection `path:"switch-direction" module:"tapi-connectivity"`
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Switch implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Switch) IsYANGGoStruct() {}
// TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Switch_SelectedConnectionEndPoint_Key represents the key for list SelectedConnectionEndPoint of element /tapi-common/context/connectivity-context/connection/switch-control/switch.
type TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Switch_SelectedConnectionEndPoint_Key struct {
TopologyUuid string `path:"topology-uuid"`
NodeUuid string `path:"node-uuid"`
NodeEdgePointUuid string `path:"node-edge-point-uuid"`
ConnectionEndPointUuid string `path:"connection-end-point-uuid"`
// TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Switch_SelectedRoute_Key represents the key for list SelectedRoute of element /tapi-common/context/connectivity-context/connection/switch-control/switch.
type TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Switch_SelectedRoute_Key struct {
ConnectionUuid string `path:"connection-uuid"`
RouteLocalId string `path:"route-local-id"`
}
// NewName creates a new entry in the Name list of the
// TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Switch struct. The keys of the list are populated from the input
// arguments.
func (t *TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Switch) NewName(ValueName string) (*TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Switch_Name, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.Name == nil {
t.Name = make(map[string]*TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Switch_Name)
}
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.Name[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list Name", key)
t.Name[key] = &TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Switch_Name{
ValueName: &ValueName,
}
return t.Name[key], nil
// NewSelectedConnectionEndPoint creates a new entry in the SelectedConnectionEndPoint list of the
// TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Switch struct. The keys of the list are populated from the input
// arguments.
func (t *TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Switch) NewSelectedConnectionEndPoint(TopologyUuid string, NodeUuid string, NodeEdgePointUuid string, ConnectionEndPointUuid string) (*TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Switch_SelectedConnectionEndPoint, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.SelectedConnectionEndPoint == nil {
t.SelectedConnectionEndPoint = make(map[TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Switch_SelectedConnectionEndPoint_Key]*TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Switch_SelectedConnectionEndPoint)
}
1740
1741
1742
1743
1744
1745
1746
1747
1748
1749
1750
1751
1752
1753
1754
1755
1756
1757
1758
1759
1760
1761
key := TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Switch_SelectedConnectionEndPoint_Key{
TopologyUuid: TopologyUuid,
NodeUuid: NodeUuid,
NodeEdgePointUuid: NodeEdgePointUuid,
ConnectionEndPointUuid: ConnectionEndPointUuid,
}
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.SelectedConnectionEndPoint[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list SelectedConnectionEndPoint", key)
}
t.SelectedConnectionEndPoint[key] = &TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Switch_SelectedConnectionEndPoint{
TopologyUuid: &TopologyUuid,
NodeUuid: &NodeUuid,
NodeEdgePointUuid: &NodeEdgePointUuid,
ConnectionEndPointUuid: &ConnectionEndPointUuid,
}
return t.SelectedConnectionEndPoint[key], nil
// NewSelectedRoute creates a new entry in the SelectedRoute list of the
// TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Switch struct. The keys of the list are populated from the input
// arguments.
func (t *TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Switch) NewSelectedRoute(ConnectionUuid string, RouteLocalId string) (*TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Switch_SelectedRoute, error){
1769
1770
1771
1772
1773
1774
1775
1776
1777
1778
1779
1780
1781
1782
1783
1784
1785
1786
1787
1788
1789
1790
1791
1792
1793
1794
1795
1796
1797
1798
// Initialise the list within the receiver struct if it has not already been
// created.
if t.SelectedRoute == nil {
t.SelectedRoute = make(map[TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Switch_SelectedRoute_Key]*TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Switch_SelectedRoute)
}
key := TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Switch_SelectedRoute_Key{
ConnectionUuid: ConnectionUuid,
RouteLocalId: RouteLocalId,
}
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.SelectedRoute[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list SelectedRoute", key)
}
t.SelectedRoute[key] = &TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Switch_SelectedRoute{
ConnectionUuid: &ConnectionUuid,
RouteLocalId: &RouteLocalId,
}
return t.SelectedRoute[key], nil
}
// ΛListKeyMap returns the keys of the TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Switch struct, which is a YANG list entry.
func (t *TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Switch) ΛListKeyMap() (map[string]interface{}, error) {
if t.LocalId == nil {
return nil, fmt.Errorf("nil value for key LocalId")
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Switch) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Switch"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Switch) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Switch_Name represents the /tapi-common/context/connectivity-context/connection/switch-control/switch/name YANG schema element.
type TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Switch_Name struct {
Value *string `path:"value" module:"tapi-connectivity"`
ValueName *string `path:"value-name" module:"tapi-connectivity"`
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Switch_Name implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Switch_Name) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Switch_Name struct, which is a YANG list entry.
func (t *TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Switch_Name) ΛListKeyMap() (map[string]interface{}, error) {
if t.ValueName == nil {
return nil, fmt.Errorf("nil value for key ValueName")
}
return map[string]interface{}{
"value-name": *t.ValueName,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Switch_Name) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Switch_Name"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Switch_Name) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Switch_SelectedConnectionEndPoint represents the /tapi-common/context/connectivity-context/connection/switch-control/switch/selected-connection-end-point YANG schema element.
type TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Switch_SelectedConnectionEndPoint struct {
ConnectionEndPointUuid *string `path:"connection-end-point-uuid" module:"tapi-connectivity"`
NodeEdgePointUuid *string `path:"node-edge-point-uuid" module:"tapi-connectivity"`
NodeUuid *string `path:"node-uuid" module:"tapi-connectivity"`
TopologyUuid *string `path:"topology-uuid" module:"tapi-connectivity"`
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Switch_SelectedConnectionEndPoint implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Switch_SelectedConnectionEndPoint) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Switch_SelectedConnectionEndPoint struct, which is a YANG list entry.
func (t *TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Switch_SelectedConnectionEndPoint) ΛListKeyMap() (map[string]interface{}, error) {
if t.ConnectionEndPointUuid == nil {
return nil, fmt.Errorf("nil value for key ConnectionEndPointUuid")
}
if t.NodeEdgePointUuid == nil {
return nil, fmt.Errorf("nil value for key NodeEdgePointUuid")
}
if t.NodeUuid == nil {
return nil, fmt.Errorf("nil value for key NodeUuid")
if t.TopologyUuid == nil {
return nil, fmt.Errorf("nil value for key TopologyUuid")
return map[string]interface{}{
"connection-end-point-uuid": *t.ConnectionEndPointUuid,
"node-edge-point-uuid": *t.NodeEdgePointUuid,
"node-uuid": *t.NodeUuid,
"topology-uuid": *t.TopologyUuid,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Switch_SelectedConnectionEndPoint) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Switch_SelectedConnectionEndPoint"], t, opts...); err != nil {
return err
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Switch_SelectedConnectionEndPoint) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Switch_SelectedRoute represents the /tapi-common/context/connectivity-context/connection/switch-control/switch/selected-route YANG schema element.
type TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Switch_SelectedRoute struct {
ConnectionUuid *string `path:"connection-uuid" module:"tapi-connectivity"`
RouteLocalId *string `path:"route-local-id" module:"tapi-connectivity"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Switch_SelectedRoute implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Switch_SelectedRoute) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Switch_SelectedRoute struct, which is a YANG list entry.
func (t *TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Switch_SelectedRoute) ΛListKeyMap() (map[string]interface{}, error) {
if t.ConnectionUuid == nil {
return nil, fmt.Errorf("nil value for key ConnectionUuid")
if t.RouteLocalId == nil {
return nil, fmt.Errorf("nil value for key RouteLocalId")
}
return map[string]interface{}{
"connection-uuid": *t.ConnectionUuid,
"route-local-id": *t.RouteLocalId,
}, nil
1933
1934
1935
1936
1937
1938
1939
1940
1941
1942
1943
1944
1945
1946
1947
1948
1949
1950
1951
1952
1953
1954
1955
1956
1957
1958
1959
1960
1961
1962
1963
1964
1965
1966
1967
1968
1969
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Switch_SelectedRoute) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Switch_SelectedRoute"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_Connection_SwitchControl_Switch_SelectedRoute) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_ConnectivityService represents the /tapi-common/context/connectivity-context/connectivity-service YANG schema element.
type TapiCommon_Context_ConnectivityContext_ConnectivityService struct {
AdministrativeState E_TapiCommon_AdministrativeState `path:"administrative-state" module:"tapi-connectivity"`
Connection map[string]*TapiCommon_Context_ConnectivityContext_ConnectivityService_Connection `path:"connection" module:"tapi-connectivity"`
ConnectivityConstraint *TapiCommon_Context_ConnectivityContext_ConnectivityService_ConnectivityConstraint `path:"connectivity-constraint" module:"tapi-connectivity"`
ConnectivityService map[string]*TapiCommon_Context_ConnectivityContext_ConnectivityService_ConnectivityService `path:"connectivity-service" module:"tapi-connectivity"`
Direction E_TapiConnectivity_ForwardingDirection `path:"direction" module:"tapi-connectivity"`
EndPoint map[string]*TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint `path:"end-point" module:"tapi-connectivity"`
LifecycleState E_TapiCommon_LifecycleState `path:"lifecycle-state" module:"tapi-connectivity"`
Name map[string]*TapiCommon_Context_ConnectivityContext_ConnectivityService_Name `path:"name" module:"tapi-connectivity"`
OperationalState E_TapiCommon_OperationalState `path:"operational-state" module:"tapi-connectivity"`
ResilienceConstraint *TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint `path:"resilience-constraint" module:"tapi-connectivity"`
RoutingConstraint *TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint `path:"routing-constraint" module:"tapi-connectivity"`
TopologyConstraint map[string]*TapiCommon_Context_ConnectivityContext_ConnectivityService_TopologyConstraint `path:"topology-constraint" module:"tapi-connectivity"`
Uuid *string `path:"uuid" module:"tapi-connectivity"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_ConnectivityService implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_ConnectivityService) IsYANGGoStruct() {}
// NewConnection creates a new entry in the Connection list of the
// TapiCommon_Context_ConnectivityContext_ConnectivityService struct. The keys of the list are populated from the input
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService) NewConnection(ConnectionUuid string) (*TapiCommon_Context_ConnectivityContext_ConnectivityService_Connection, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.Connection == nil {
t.Connection = make(map[string]*TapiCommon_Context_ConnectivityContext_ConnectivityService_Connection)
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.Connection[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list Connection", key)
t.Connection[key] = &TapiCommon_Context_ConnectivityContext_ConnectivityService_Connection{
ConnectionUuid: &ConnectionUuid,
// NewConnectivityService creates a new entry in the ConnectivityService list of the
// TapiCommon_Context_ConnectivityContext_ConnectivityService struct. The keys of the list are populated from the input
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService) NewConnectivityService(ConnectivityServiceUuid string) (*TapiCommon_Context_ConnectivityContext_ConnectivityService_ConnectivityService, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.ConnectivityService == nil {
t.ConnectivityService = make(map[string]*TapiCommon_Context_ConnectivityContext_ConnectivityService_ConnectivityService)
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.ConnectivityService[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list ConnectivityService", key)
t.ConnectivityService[key] = &TapiCommon_Context_ConnectivityContext_ConnectivityService_ConnectivityService{
ConnectivityServiceUuid: &ConnectivityServiceUuid,
return t.ConnectivityService[key], nil
// NewEndPoint creates a new entry in the EndPoint list of the
// TapiCommon_Context_ConnectivityContext_ConnectivityService struct. The keys of the list are populated from the input
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService) NewEndPoint(LocalId string) (*TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.EndPoint == nil {
t.EndPoint = make(map[string]*TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint)
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.EndPoint[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list EndPoint", key)
t.EndPoint[key] = &TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint{
LocalId: &LocalId,
// NewName creates a new entry in the Name list of the
// TapiCommon_Context_ConnectivityContext_ConnectivityService struct. The keys of the list are populated from the input
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService) NewName(ValueName string) (*TapiCommon_Context_ConnectivityContext_ConnectivityService_Name, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.Name == nil {
t.Name = make(map[string]*TapiCommon_Context_ConnectivityContext_ConnectivityService_Name)
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.Name[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list Name", key)
t.Name[key] = &TapiCommon_Context_ConnectivityContext_ConnectivityService_Name{
ValueName: &ValueName,
// NewTopologyConstraint creates a new entry in the TopologyConstraint list of the
// TapiCommon_Context_ConnectivityContext_ConnectivityService struct. The keys of the list are populated from the input
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService) NewTopologyConstraint(LocalId string) (*TapiCommon_Context_ConnectivityContext_ConnectivityService_TopologyConstraint, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.TopologyConstraint == nil {
t.TopologyConstraint = make(map[string]*TapiCommon_Context_ConnectivityContext_ConnectivityService_TopologyConstraint)
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.TopologyConstraint[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list TopologyConstraint", key)
t.TopologyConstraint[key] = &TapiCommon_Context_ConnectivityContext_ConnectivityService_TopologyConstraint{
LocalId: &LocalId,
return t.TopologyConstraint[key], nil
// ΛListKeyMap returns the keys of the TapiCommon_Context_ConnectivityContext_ConnectivityService struct, which is a YANG list entry.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService) ΛListKeyMap() (map[string]interface{}, error) {
if t.Uuid == nil {
return nil, fmt.Errorf("nil value for key Uuid")
}
return map[string]interface{}{
"uuid": *t.Uuid,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_ConnectivityService"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_ConnectivityService_Connection represents the /tapi-common/context/connectivity-context/connectivity-service/connection YANG schema element.
type TapiCommon_Context_ConnectivityContext_ConnectivityService_Connection struct {
ConnectionUuid *string `path:"connection-uuid" module:"tapi-connectivity"`
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_ConnectivityService_Connection implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_ConnectivityService_Connection) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_ConnectivityContext_ConnectivityService_Connection struct, which is a YANG list entry.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_Connection) ΛListKeyMap() (map[string]interface{}, error) {
if t.ConnectionUuid == nil {
return nil, fmt.Errorf("nil value for key ConnectionUuid")
"connection-uuid": *t.ConnectionUuid,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_Connection) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_ConnectivityService_Connection"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_Connection) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_ConnectivityService_ConnectivityConstraint represents the /tapi-common/context/connectivity-context/connectivity-service/connectivity-constraint YANG schema element.
type TapiCommon_Context_ConnectivityContext_ConnectivityService_ConnectivityConstraint struct {
ConnectionExclusion []string `path:"connection-exclusion" module:"tapi-connectivity"`
ConnectionInclusion []string `path:"connection-inclusion" module:"tapi-connectivity"`
CorouteInclusion *TapiCommon_Context_ConnectivityContext_ConnectivityService_ConnectivityConstraint_CorouteInclusion `path:"coroute-inclusion" module:"tapi-connectivity"`
DiversityExclusion map[string]*TapiCommon_Context_ConnectivityContext_ConnectivityService_ConnectivityConstraint_DiversityExclusion `path:"diversity-exclusion" module:"tapi-connectivity"`
RequestedCapacity *TapiCommon_Context_ConnectivityContext_ConnectivityService_ConnectivityConstraint_RequestedCapacity `path:"requested-capacity" module:"tapi-connectivity"`
Schedule *TapiCommon_Context_ConnectivityContext_ConnectivityService_ConnectivityConstraint_Schedule `path:"schedule" module:"tapi-connectivity"`
ServiceLevel *string `path:"service-level" module:"tapi-connectivity"`
ServiceType E_TapiConnectivity_ServiceType `path:"service-type" module:"tapi-connectivity"`
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_ConnectivityService_ConnectivityConstraint implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
2176
2177
2178
2179
2180
2181
2182
2183
2184
2185
2186
2187
2188
2189
2190
2191
2192
2193
2194
2195
2196
2197
2198
2199
2200
func (*TapiCommon_Context_ConnectivityContext_ConnectivityService_ConnectivityConstraint) IsYANGGoStruct() {}
// NewDiversityExclusion creates a new entry in the DiversityExclusion list of the
// TapiCommon_Context_ConnectivityContext_ConnectivityService_ConnectivityConstraint struct. The keys of the list are populated from the input
// arguments.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_ConnectivityConstraint) NewDiversityExclusion(ConnectivityServiceUuid string) (*TapiCommon_Context_ConnectivityContext_ConnectivityService_ConnectivityConstraint_DiversityExclusion, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.DiversityExclusion == nil {
t.DiversityExclusion = make(map[string]*TapiCommon_Context_ConnectivityContext_ConnectivityService_ConnectivityConstraint_DiversityExclusion)
}
key := ConnectivityServiceUuid
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.DiversityExclusion[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list DiversityExclusion", key)
}
t.DiversityExclusion[key] = &TapiCommon_Context_ConnectivityContext_ConnectivityService_ConnectivityConstraint_DiversityExclusion{
ConnectivityServiceUuid: &ConnectivityServiceUuid,
}
return t.DiversityExclusion[key], nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_ConnectivityConstraint) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_ConnectivityService_ConnectivityConstraint"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_ConnectivityConstraint) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_ConnectivityService_ConnectivityConstraint_CorouteInclusion represents the /tapi-common/context/connectivity-context/connectivity-service/connectivity-constraint/coroute-inclusion YANG schema element.
type TapiCommon_Context_ConnectivityContext_ConnectivityService_ConnectivityConstraint_CorouteInclusion struct {
ConnectivityServiceUuid *string `path:"connectivity-service-uuid" module:"tapi-connectivity"`
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_ConnectivityService_ConnectivityConstraint_CorouteInclusion implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_ConnectivityService_ConnectivityConstraint_CorouteInclusion) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_ConnectivityConstraint_CorouteInclusion) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_ConnectivityService_ConnectivityConstraint_CorouteInclusion"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_ConnectivityConstraint_CorouteInclusion) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_ConnectivityService_ConnectivityConstraint_DiversityExclusion represents the /tapi-common/context/connectivity-context/connectivity-service/connectivity-constraint/diversity-exclusion YANG schema element.
type TapiCommon_Context_ConnectivityContext_ConnectivityService_ConnectivityConstraint_DiversityExclusion struct {
ConnectivityServiceUuid *string `path:"connectivity-service-uuid" module:"tapi-connectivity"`
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_ConnectivityService_ConnectivityConstraint_DiversityExclusion implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_ConnectivityService_ConnectivityConstraint_DiversityExclusion) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_ConnectivityContext_ConnectivityService_ConnectivityConstraint_DiversityExclusion struct, which is a YANG list entry.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_ConnectivityConstraint_DiversityExclusion) ΛListKeyMap() (map[string]interface{}, error) {
if t.ConnectivityServiceUuid == nil {
return nil, fmt.Errorf("nil value for key ConnectivityServiceUuid")
"connectivity-service-uuid": *t.ConnectivityServiceUuid,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_ConnectivityConstraint_DiversityExclusion) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_ConnectivityService_ConnectivityConstraint_DiversityExclusion"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_ConnectivityConstraint_DiversityExclusion) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_ConnectivityService_ConnectivityConstraint_RequestedCapacity represents the /tapi-common/context/connectivity-context/connectivity-service/connectivity-constraint/requested-capacity YANG schema element.
type TapiCommon_Context_ConnectivityContext_ConnectivityService_ConnectivityConstraint_RequestedCapacity struct {
TotalSize *TapiCommon_Context_ConnectivityContext_ConnectivityService_ConnectivityConstraint_RequestedCapacity_TotalSize `path:"total-size" module:"tapi-connectivity"`
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_ConnectivityService_ConnectivityConstraint_RequestedCapacity implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_ConnectivityService_ConnectivityConstraint_RequestedCapacity) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_ConnectivityConstraint_RequestedCapacity) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_ConnectivityService_ConnectivityConstraint_RequestedCapacity"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_ConnectivityConstraint_RequestedCapacity) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_ConnectivityService_ConnectivityConstraint_RequestedCapacity_TotalSize represents the /tapi-common/context/connectivity-context/connectivity-service/connectivity-constraint/requested-capacity/total-size YANG schema element.
type TapiCommon_Context_ConnectivityContext_ConnectivityService_ConnectivityConstraint_RequestedCapacity_TotalSize struct {
Unit E_TapiCommon_CapacityUnit `path:"unit" module:"tapi-connectivity"`
Value *uint64 `path:"value" module:"tapi-connectivity"`
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_ConnectivityService_ConnectivityConstraint_RequestedCapacity_TotalSize implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_ConnectivityService_ConnectivityConstraint_RequestedCapacity_TotalSize) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_ConnectivityConstraint_RequestedCapacity_TotalSize) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_ConnectivityService_ConnectivityConstraint_RequestedCapacity_TotalSize"], t, opts...); err != nil {
return err
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_ConnectivityConstraint_RequestedCapacity_TotalSize) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_ConnectivityService_ConnectivityConstraint_Schedule represents the /tapi-common/context/connectivity-context/connectivity-service/connectivity-constraint/schedule YANG schema element.
type TapiCommon_Context_ConnectivityContext_ConnectivityService_ConnectivityConstraint_Schedule struct {
EndTime *string `path:"end-time" module:"tapi-connectivity"`
StartTime *string `path:"start-time" module:"tapi-connectivity"`
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_ConnectivityService_ConnectivityConstraint_Schedule implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_ConnectivityService_ConnectivityConstraint_Schedule) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_ConnectivityConstraint_Schedule) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_ConnectivityService_ConnectivityConstraint_Schedule"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_ConnectivityConstraint_Schedule) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_ConnectivityService_ConnectivityService represents the /tapi-common/context/connectivity-context/connectivity-service/connectivity-service YANG schema element.
type TapiCommon_Context_ConnectivityContext_ConnectivityService_ConnectivityService struct {
ConnectivityServiceUuid *string `path:"connectivity-service-uuid" module:"tapi-connectivity"`
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_ConnectivityService_ConnectivityService implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_ConnectivityService_ConnectivityService) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_ConnectivityContext_ConnectivityService_ConnectivityService struct, which is a YANG list entry.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_ConnectivityService) ΛListKeyMap() (map[string]interface{}, error) {
if t.ConnectivityServiceUuid == nil {
return nil, fmt.Errorf("nil value for key ConnectivityServiceUuid")
"connectivity-service-uuid": *t.ConnectivityServiceUuid,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_ConnectivityService) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_ConnectivityService_ConnectivityService"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_ConnectivityService) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint represents the /tapi-common/context/connectivity-context/connectivity-service/end-point YANG schema element.
type TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint struct {
AdministrativeState E_TapiCommon_AdministrativeState `path:"administrative-state" module:"tapi-connectivity"`
Capacity *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_Capacity `path:"capacity" module:"tapi-connectivity"`
ConnectionEndPoint map[TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_ConnectionEndPoint_Key]*TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_ConnectionEndPoint `path:"connection-end-point" module:"tapi-connectivity"`
Direction E_TapiConnectivity_PortDirection `path:"direction" module:"tapi-connectivity"`
LayerProtocolName E_TapiConnectivity_LayerProtocolName `path:"layer-protocol-name" module:"tapi-connectivity"`
LayerProtocolQualifier E_TapiConnectivity_LayerProtocolQualifier `path:"layer-protocol-qualifier" module:"tapi-connectivity"`
LifecycleState E_TapiCommon_LifecycleState `path:"lifecycle-state" module:"tapi-connectivity"`
LocalId *string `path:"local-id" module:"tapi-connectivity"`
MediaChannelConnectivityServiceEndPointSpec *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec `path:"media-channel-connectivity-service-end-point-spec" module:"tapi-photonic-media"`
Name map[string]*TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_Name `path:"name" module:"tapi-connectivity"`
OperationalState E_TapiCommon_OperationalState `path:"operational-state" module:"tapi-connectivity"`
OtsiConnectivityServiceEndPointSpec *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_OtsiConnectivityServiceEndPointSpec `path:"otsi-connectivity-service-end-point-spec" module:"tapi-photonic-media"`
PeerFwdConnectivityServiceEndPoint *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_PeerFwdConnectivityServiceEndPoint `path:"peer-fwd-connectivity-service-end-point" module:"tapi-connectivity"`
ProtectingConnectivityServiceEndPoint *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_ProtectingConnectivityServiceEndPoint `path:"protecting-connectivity-service-end-point" module:"tapi-connectivity"`
ProtectionRole E_TapiConnectivity_ProtectionRole `path:"protection-role" module:"tapi-connectivity"`
Role E_TapiConnectivity_PortRole `path:"role" module:"tapi-connectivity"`
ServerConnectivityServiceEndPoint *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_ServerConnectivityServiceEndPoint `path:"server-connectivity-service-end-point" module:"tapi-connectivity"`
ServiceInterfacePoint *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_ServiceInterfacePoint `path:"service-interface-point" module:"tapi-connectivity"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint) IsYANGGoStruct() {}
// TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_ConnectionEndPoint_Key represents the key for list ConnectionEndPoint of element /tapi-common/context/connectivity-context/connectivity-service/end-point.
type TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_ConnectionEndPoint_Key struct {
TopologyUuid string `path:"topology-uuid"`
NodeUuid string `path:"node-uuid"`
NodeEdgePointUuid string `path:"node-edge-point-uuid"`
ConnectionEndPointUuid string `path:"connection-end-point-uuid"`
// NewConnectionEndPoint creates a new entry in the ConnectionEndPoint list of the
// TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint struct. The keys of the list are populated from the input
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint) NewConnectionEndPoint(TopologyUuid string, NodeUuid string, NodeEdgePointUuid string, ConnectionEndPointUuid string) (*TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_ConnectionEndPoint, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.ConnectionEndPoint == nil {
t.ConnectionEndPoint = make(map[TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_ConnectionEndPoint_Key]*TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_ConnectionEndPoint)
key := TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_ConnectionEndPoint_Key{
NodeEdgePointUuid: NodeEdgePointUuid,
ConnectionEndPointUuid: ConnectionEndPointUuid,
}
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.ConnectionEndPoint[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list ConnectionEndPoint", key)
t.ConnectionEndPoint[key] = &TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_ConnectionEndPoint{
NodeEdgePointUuid: &NodeEdgePointUuid,
ConnectionEndPointUuid: &ConnectionEndPointUuid,
return t.ConnectionEndPoint[key], nil
// NewName creates a new entry in the Name list of the
// TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint struct. The keys of the list are populated from the input
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint) NewName(ValueName string) (*TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_Name, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.Name == nil {
t.Name = make(map[string]*TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_Name)
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.Name[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list Name", key)
t.Name[key] = &TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_Name{
ValueName: &ValueName,
// ΛListKeyMap returns the keys of the TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint struct, which is a YANG list entry.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint) ΛListKeyMap() (map[string]interface{}, error) {
if t.LocalId == nil {
return nil, fmt.Errorf("nil value for key LocalId")
return map[string]interface{}{
"local-id": *t.LocalId,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint"], t, opts...); err != nil {
return err
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_Capacity represents the /tapi-common/context/connectivity-context/connectivity-service/end-point/capacity YANG schema element.
type TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_Capacity struct {
TotalSize *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_Capacity_TotalSize `path:"total-size" module:"tapi-connectivity"`
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_Capacity implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_Capacity) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_Capacity) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_Capacity"], t, opts...); err != nil {
return err
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_Capacity) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_Capacity_TotalSize represents the /tapi-common/context/connectivity-context/connectivity-service/end-point/capacity/total-size YANG schema element.
type TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_Capacity_TotalSize struct {
Unit E_TapiCommon_CapacityUnit `path:"unit" module:"tapi-connectivity"`
Value *uint64 `path:"value" module:"tapi-connectivity"`
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_Capacity_TotalSize implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_Capacity_TotalSize) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_Capacity_TotalSize) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_Capacity_TotalSize"], t, opts...); err != nil {
return err
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_Capacity_TotalSize) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_ConnectionEndPoint represents the /tapi-common/context/connectivity-context/connectivity-service/end-point/connection-end-point YANG schema element.
type TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_ConnectionEndPoint struct {
ConnectionEndPointUuid *string `path:"connection-end-point-uuid" module:"tapi-connectivity"`
NodeEdgePointUuid *string `path:"node-edge-point-uuid" module:"tapi-connectivity"`
NodeUuid *string `path:"node-uuid" module:"tapi-connectivity"`
TopologyUuid *string `path:"topology-uuid" module:"tapi-connectivity"`
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_ConnectionEndPoint implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_ConnectionEndPoint) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_ConnectionEndPoint struct, which is a YANG list entry.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_ConnectionEndPoint) ΛListKeyMap() (map[string]interface{}, error) {
if t.ConnectionEndPointUuid == nil {
return nil, fmt.Errorf("nil value for key ConnectionEndPointUuid")
if t.NodeEdgePointUuid == nil {
return nil, fmt.Errorf("nil value for key NodeEdgePointUuid")
if t.NodeUuid == nil {
return nil, fmt.Errorf("nil value for key NodeUuid")
if t.TopologyUuid == nil {
return nil, fmt.Errorf("nil value for key TopologyUuid")
return map[string]interface{}{
"connection-end-point-uuid": *t.ConnectionEndPointUuid,
"node-edge-point-uuid": *t.NodeEdgePointUuid,
"node-uuid": *t.NodeUuid,
"topology-uuid": *t.TopologyUuid,
}, nil
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_ConnectionEndPoint) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_ConnectionEndPoint"], t, opts...); err != nil {
return err
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_ConnectionEndPoint) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
2600
2601
2602
2603
2604
2605
2606
2607
2608
2609
2610
2611
2612
2613
2614
2615
2616
2617
2618
2619
2620
2621
2622
2623
2624
2625
2626
2627
2628
2629
2630
2631
2632
2633
2634
2635
2636
2637
2638
2639
2640
2641
2642
2643
2644
2645
2646
2647
2648
2649
2650
2651
2652
2653
2654
2655
2656
2657
2658
2659
2660
2661
2662
2663
2664
2665
2666
2667
2668
2669
2670
2671
2672
2673
2674
2675
2676
2677
2678
2679
2680
2681
2682
2683
2684
2685
2686
2687
2688
2689
2690
2691
2692
2693
2694
2695
2696
2697
2698
2699
2700
2701
2702
2703
2704
2705
2706
2707
2708
2709
2710
2711
2712
2713
2714
2715
2716
2717
2718
2719
2720
2721
2722
2723
2724
2725
2726
2727
2728
2729
2730
2731
2732
2733
2734
2735
2736
2737
2738
2739
2740
2741
2742
2743
2744
2745
2746
2747
2748
2749
2750
2751
2752
2753
2754
2755
2756
2757
2758
2759
2760
2761
2762
2763
2764
2765
2766
2767
2768
2769
2770
2771
2772
2773
2774
2775
2776
2777
2778
2779
2780
2781
2782
2783
2784
2785
2786
2787
2788
2789
2790
2791
2792
2793
2794
2795
2796
2797
2798
2799
2800
2801
2802
2803
2804
2805
2806
2807
2808
2809
2810
2811
2812
2813
2814
2815
2816
2817
// TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec represents the /tapi-common/context/connectivity-context/connectivity-service/end-point/media-channel-connectivity-service-end-point-spec YANG schema element.
type TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec struct {
McConfig *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec_McConfig `path:"mc-config" module:"tapi-photonic-media"`
PowerManagementConfig *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec_PowerManagementConfig `path:"power-management-config" module:"tapi-photonic-media"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec_McConfig represents the /tapi-common/context/connectivity-context/connectivity-service/end-point/media-channel-connectivity-service-end-point-spec/mc-config YANG schema element.
type TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec_McConfig struct {
Spectrum *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec_McConfig_Spectrum `path:"spectrum" module:"tapi-photonic-media"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec_McConfig implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec_McConfig) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec_McConfig) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec_McConfig"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec_McConfig) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec_McConfig_Spectrum represents the /tapi-common/context/connectivity-context/connectivity-service/end-point/media-channel-connectivity-service-end-point-spec/mc-config/spectrum YANG schema element.
type TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec_McConfig_Spectrum struct {
FrequencyConstraint *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec_McConfig_Spectrum_FrequencyConstraint `path:"frequency-constraint" module:"tapi-photonic-media"`
LowerFrequency *uint64 `path:"lower-frequency" module:"tapi-photonic-media"`
UpperFrequency *uint64 `path:"upper-frequency" module:"tapi-photonic-media"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec_McConfig_Spectrum implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec_McConfig_Spectrum) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec_McConfig_Spectrum) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec_McConfig_Spectrum"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec_McConfig_Spectrum) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec_McConfig_Spectrum_FrequencyConstraint represents the /tapi-common/context/connectivity-context/connectivity-service/end-point/media-channel-connectivity-service-end-point-spec/mc-config/spectrum/frequency-constraint YANG schema element.
type TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec_McConfig_Spectrum_FrequencyConstraint struct {
AdjustmentGranularity E_TapiPhotonicMedia_AdjustmentGranularity `path:"adjustment-granularity" module:"tapi-photonic-media"`
GridType E_TapiPhotonicMedia_GridType `path:"grid-type" module:"tapi-photonic-media"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec_McConfig_Spectrum_FrequencyConstraint implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec_McConfig_Spectrum_FrequencyConstraint) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec_McConfig_Spectrum_FrequencyConstraint) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec_McConfig_Spectrum_FrequencyConstraint"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec_McConfig_Spectrum_FrequencyConstraint) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec_PowerManagementConfig represents the /tapi-common/context/connectivity-context/connectivity-service/end-point/media-channel-connectivity-service-end-point-spec/power-management-config YANG schema element.
type TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec_PowerManagementConfig struct {
ExpectedMaximumInputPower *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec_PowerManagementConfig_ExpectedMaximumInputPower `path:"expected-maximum-input-power" module:"tapi-photonic-media"`
ExpectedMinimumInputPower *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec_PowerManagementConfig_ExpectedMinimumInputPower `path:"expected-minimum-input-power" module:"tapi-photonic-media"`
IntendedMaximumOutputPower *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec_PowerManagementConfig_IntendedMaximumOutputPower `path:"intended-maximum-output-power" module:"tapi-photonic-media"`
IntendedMinimumOutputPower *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec_PowerManagementConfig_IntendedMinimumOutputPower `path:"intended-minimum-output-power" module:"tapi-photonic-media"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec_PowerManagementConfig implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec_PowerManagementConfig) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec_PowerManagementConfig) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec_PowerManagementConfig"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec_PowerManagementConfig) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec_PowerManagementConfig_ExpectedMaximumInputPower represents the /tapi-common/context/connectivity-context/connectivity-service/end-point/media-channel-connectivity-service-end-point-spec/power-management-config/expected-maximum-input-power YANG schema element.
type TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec_PowerManagementConfig_ExpectedMaximumInputPower struct {
PowerSpectralDensity *float64 `path:"power-spectral-density" module:"tapi-photonic-media"`
TotalPower *float64 `path:"total-power" module:"tapi-photonic-media"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec_PowerManagementConfig_ExpectedMaximumInputPower implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec_PowerManagementConfig_ExpectedMaximumInputPower) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec_PowerManagementConfig_ExpectedMaximumInputPower) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec_PowerManagementConfig_ExpectedMaximumInputPower"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec_PowerManagementConfig_ExpectedMaximumInputPower) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec_PowerManagementConfig_ExpectedMinimumInputPower represents the /tapi-common/context/connectivity-context/connectivity-service/end-point/media-channel-connectivity-service-end-point-spec/power-management-config/expected-minimum-input-power YANG schema element.
type TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec_PowerManagementConfig_ExpectedMinimumInputPower struct {
PowerSpectralDensity *float64 `path:"power-spectral-density" module:"tapi-photonic-media"`
TotalPower *float64 `path:"total-power" module:"tapi-photonic-media"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec_PowerManagementConfig_ExpectedMinimumInputPower implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec_PowerManagementConfig_ExpectedMinimumInputPower) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec_PowerManagementConfig_ExpectedMinimumInputPower) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec_PowerManagementConfig_ExpectedMinimumInputPower"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec_PowerManagementConfig_ExpectedMinimumInputPower) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec_PowerManagementConfig_IntendedMaximumOutputPower represents the /tapi-common/context/connectivity-context/connectivity-service/end-point/media-channel-connectivity-service-end-point-spec/power-management-config/intended-maximum-output-power YANG schema element.
type TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec_PowerManagementConfig_IntendedMaximumOutputPower struct {
PowerSpectralDensity *float64 `path:"power-spectral-density" module:"tapi-photonic-media"`
TotalPower *float64 `path:"total-power" module:"tapi-photonic-media"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec_PowerManagementConfig_IntendedMaximumOutputPower implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec_PowerManagementConfig_IntendedMaximumOutputPower) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec_PowerManagementConfig_IntendedMaximumOutputPower) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec_PowerManagementConfig_IntendedMaximumOutputPower"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec_PowerManagementConfig_IntendedMaximumOutputPower) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec_PowerManagementConfig_IntendedMinimumOutputPower represents the /tapi-common/context/connectivity-context/connectivity-service/end-point/media-channel-connectivity-service-end-point-spec/power-management-config/intended-minimum-output-power YANG schema element.
type TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec_PowerManagementConfig_IntendedMinimumOutputPower struct {
PowerSpectralDensity *float64 `path:"power-spectral-density" module:"tapi-photonic-media"`
TotalPower *float64 `path:"total-power" module:"tapi-photonic-media"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec_PowerManagementConfig_IntendedMinimumOutputPower implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec_PowerManagementConfig_IntendedMinimumOutputPower) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec_PowerManagementConfig_IntendedMinimumOutputPower) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec_PowerManagementConfig_IntendedMinimumOutputPower"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_MediaChannelConnectivityServiceEndPointSpec_PowerManagementConfig_IntendedMinimumOutputPower) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_Name represents the /tapi-common/context/connectivity-context/connectivity-service/end-point/name YANG schema element.
type TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_Name struct {
Value *string `path:"value" module:"tapi-connectivity"`
ValueName *string `path:"value-name" module:"tapi-connectivity"`
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_Name implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_Name) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_Name struct, which is a YANG list entry.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_Name) ΛListKeyMap() (map[string]interface{}, error) {
if t.ValueName == nil {
return nil, fmt.Errorf("nil value for key ValueName")
return map[string]interface{}{
"value-name": *t.ValueName,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_Name) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_Name"], t, opts...); err != nil {
return err
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_Name) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
2853
2854
2855
2856
2857
2858
2859
2860
2861
2862
2863
2864
2865
2866
2867
2868
2869
2870
2871
2872
2873
2874
2875
2876
2877
2878
2879
2880
2881
2882
2883
2884
2885
2886
2887
2888
2889
2890
2891
2892
2893
2894
2895
2896
2897
2898
2899
2900
2901
2902
2903
2904
2905
2906
2907
2908
2909
2910
2911
2912
2913
2914
2915
2916
2917
2918
2919
2920
2921
2922
2923
2924
2925
2926
2927
2928
2929
2930
2931
2932
2933
2934
2935
2936
2937
2938
2939
2940
2941
2942
2943
2944
2945
2946
2947
2948
2949
2950
2951
2952
2953
2954
2955
2956
2957
2958
2959
2960
2961
2962
2963
2964
2965
2966
2967
2968
2969
2970
2971
2972
2973
2974
2975
2976
2977
2978
2979
2980
2981
2982
2983
2984
2985
2986
2987
2988
2989
2990
2991
2992
2993
2994
2995
2996
2997
2998
2999
3000
3001
3002
3003
3004
3005
3006
3007
3008
3009
3010
3011
3012
3013
3014
3015
3016
3017
3018
3019
3020
3021
3022
3023
3024
3025
3026
3027
3028
3029
3030
3031
3032
3033
3034
3035
3036
3037
3038
3039
3040
3041
3042
3043
3044
3045
3046
3047
3048
3049
3050
// TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_OtsiConnectivityServiceEndPointSpec represents the /tapi-common/context/connectivity-context/connectivity-service/end-point/otsi-connectivity-service-end-point-spec YANG schema element.
type TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_OtsiConnectivityServiceEndPointSpec struct {
OtsiConfig *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_OtsiConnectivityServiceEndPointSpec_OtsiConfig `path:"otsi-config" module:"tapi-photonic-media"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_OtsiConnectivityServiceEndPointSpec implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_OtsiConnectivityServiceEndPointSpec) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_OtsiConnectivityServiceEndPointSpec) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_OtsiConnectivityServiceEndPointSpec"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_OtsiConnectivityServiceEndPointSpec) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_OtsiConnectivityServiceEndPointSpec_OtsiConfig represents the /tapi-common/context/connectivity-context/connectivity-service/end-point/otsi-connectivity-service-end-point-spec/otsi-config YANG schema element.
type TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_OtsiConnectivityServiceEndPointSpec_OtsiConfig struct {
ApplicationIdentifier *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_OtsiConnectivityServiceEndPointSpec_OtsiConfig_ApplicationIdentifier `path:"application-identifier" module:"tapi-photonic-media"`
CentralFrequency *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_OtsiConnectivityServiceEndPointSpec_OtsiConfig_CentralFrequency `path:"central-frequency" module:"tapi-photonic-media"`
LaserControl E_TapiPhotonicMedia_LaserControlType `path:"laser-control" module:"tapi-photonic-media"`
Modulation E_TapiPhotonicMedia_ModulationTechnique `path:"modulation" module:"tapi-photonic-media"`
Spectrum *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_OtsiConnectivityServiceEndPointSpec_OtsiConfig_Spectrum `path:"spectrum" module:"tapi-photonic-media"`
TotalPowerWarnThresholdLower *float64 `path:"total-power-warn-threshold-lower" module:"tapi-photonic-media"`
TotalPowerWarnThresholdUpper *float64 `path:"total-power-warn-threshold-upper" module:"tapi-photonic-media"`
TransmitPower *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_OtsiConnectivityServiceEndPointSpec_OtsiConfig_TransmitPower `path:"transmit-power" module:"tapi-photonic-media"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_OtsiConnectivityServiceEndPointSpec_OtsiConfig implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_OtsiConnectivityServiceEndPointSpec_OtsiConfig) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_OtsiConnectivityServiceEndPointSpec_OtsiConfig) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_OtsiConnectivityServiceEndPointSpec_OtsiConfig"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_OtsiConnectivityServiceEndPointSpec_OtsiConfig) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_OtsiConnectivityServiceEndPointSpec_OtsiConfig_ApplicationIdentifier represents the /tapi-common/context/connectivity-context/connectivity-service/end-point/otsi-connectivity-service-end-point-spec/otsi-config/application-identifier YANG schema element.
type TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_OtsiConnectivityServiceEndPointSpec_OtsiConfig_ApplicationIdentifier struct {
ApplicationCode *string `path:"application-code" module:"tapi-photonic-media"`
ApplicationIdentifierType E_TapiPhotonicMedia_ApplicationIdentifierType `path:"application-identifier-type" module:"tapi-photonic-media"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_OtsiConnectivityServiceEndPointSpec_OtsiConfig_ApplicationIdentifier implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_OtsiConnectivityServiceEndPointSpec_OtsiConfig_ApplicationIdentifier) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_OtsiConnectivityServiceEndPointSpec_OtsiConfig_ApplicationIdentifier) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_OtsiConnectivityServiceEndPointSpec_OtsiConfig_ApplicationIdentifier"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_OtsiConnectivityServiceEndPointSpec_OtsiConfig_ApplicationIdentifier) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_OtsiConnectivityServiceEndPointSpec_OtsiConfig_CentralFrequency represents the /tapi-common/context/connectivity-context/connectivity-service/end-point/otsi-connectivity-service-end-point-spec/otsi-config/central-frequency YANG schema element.
type TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_OtsiConnectivityServiceEndPointSpec_OtsiConfig_CentralFrequency struct {
CentralFrequency *uint64 `path:"central-frequency" module:"tapi-photonic-media"`
FrequencyConstraint *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_OtsiConnectivityServiceEndPointSpec_OtsiConfig_CentralFrequency_FrequencyConstraint `path:"frequency-constraint" module:"tapi-photonic-media"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_OtsiConnectivityServiceEndPointSpec_OtsiConfig_CentralFrequency implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_OtsiConnectivityServiceEndPointSpec_OtsiConfig_CentralFrequency) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_OtsiConnectivityServiceEndPointSpec_OtsiConfig_CentralFrequency) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_OtsiConnectivityServiceEndPointSpec_OtsiConfig_CentralFrequency"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_OtsiConnectivityServiceEndPointSpec_OtsiConfig_CentralFrequency) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_OtsiConnectivityServiceEndPointSpec_OtsiConfig_CentralFrequency_FrequencyConstraint represents the /tapi-common/context/connectivity-context/connectivity-service/end-point/otsi-connectivity-service-end-point-spec/otsi-config/central-frequency/frequency-constraint YANG schema element.
type TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_OtsiConnectivityServiceEndPointSpec_OtsiConfig_CentralFrequency_FrequencyConstraint struct {
AdjustmentGranularity E_TapiPhotonicMedia_AdjustmentGranularity `path:"adjustment-granularity" module:"tapi-photonic-media"`
GridType E_TapiPhotonicMedia_GridType `path:"grid-type" module:"tapi-photonic-media"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_OtsiConnectivityServiceEndPointSpec_OtsiConfig_CentralFrequency_FrequencyConstraint implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_OtsiConnectivityServiceEndPointSpec_OtsiConfig_CentralFrequency_FrequencyConstraint) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_OtsiConnectivityServiceEndPointSpec_OtsiConfig_CentralFrequency_FrequencyConstraint) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_OtsiConnectivityServiceEndPointSpec_OtsiConfig_CentralFrequency_FrequencyConstraint"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_OtsiConnectivityServiceEndPointSpec_OtsiConfig_CentralFrequency_FrequencyConstraint) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_OtsiConnectivityServiceEndPointSpec_OtsiConfig_Spectrum represents the /tapi-common/context/connectivity-context/connectivity-service/end-point/otsi-connectivity-service-end-point-spec/otsi-config/spectrum YANG schema element.
type TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_OtsiConnectivityServiceEndPointSpec_OtsiConfig_Spectrum struct {
FrequencyConstraint *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_OtsiConnectivityServiceEndPointSpec_OtsiConfig_Spectrum_FrequencyConstraint `path:"frequency-constraint" module:"tapi-photonic-media"`
LowerFrequency *uint64 `path:"lower-frequency" module:"tapi-photonic-media"`
UpperFrequency *uint64 `path:"upper-frequency" module:"tapi-photonic-media"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_OtsiConnectivityServiceEndPointSpec_OtsiConfig_Spectrum implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_OtsiConnectivityServiceEndPointSpec_OtsiConfig_Spectrum) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_OtsiConnectivityServiceEndPointSpec_OtsiConfig_Spectrum) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_OtsiConnectivityServiceEndPointSpec_OtsiConfig_Spectrum"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_OtsiConnectivityServiceEndPointSpec_OtsiConfig_Spectrum) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_OtsiConnectivityServiceEndPointSpec_OtsiConfig_Spectrum_FrequencyConstraint represents the /tapi-common/context/connectivity-context/connectivity-service/end-point/otsi-connectivity-service-end-point-spec/otsi-config/spectrum/frequency-constraint YANG schema element.
type TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_OtsiConnectivityServiceEndPointSpec_OtsiConfig_Spectrum_FrequencyConstraint struct {
AdjustmentGranularity E_TapiPhotonicMedia_AdjustmentGranularity `path:"adjustment-granularity" module:"tapi-photonic-media"`
GridType E_TapiPhotonicMedia_GridType `path:"grid-type" module:"tapi-photonic-media"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_OtsiConnectivityServiceEndPointSpec_OtsiConfig_Spectrum_FrequencyConstraint implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_OtsiConnectivityServiceEndPointSpec_OtsiConfig_Spectrum_FrequencyConstraint) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_OtsiConnectivityServiceEndPointSpec_OtsiConfig_Spectrum_FrequencyConstraint) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_OtsiConnectivityServiceEndPointSpec_OtsiConfig_Spectrum_FrequencyConstraint"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_OtsiConnectivityServiceEndPointSpec_OtsiConfig_Spectrum_FrequencyConstraint) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_OtsiConnectivityServiceEndPointSpec_OtsiConfig_TransmitPower represents the /tapi-common/context/connectivity-context/connectivity-service/end-point/otsi-connectivity-service-end-point-spec/otsi-config/transmit-power YANG schema element.
type TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_OtsiConnectivityServiceEndPointSpec_OtsiConfig_TransmitPower struct {
PowerSpectralDensity *float64 `path:"power-spectral-density" module:"tapi-photonic-media"`
TotalPower *float64 `path:"total-power" module:"tapi-photonic-media"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_OtsiConnectivityServiceEndPointSpec_OtsiConfig_TransmitPower implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_OtsiConnectivityServiceEndPointSpec_OtsiConfig_TransmitPower) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_OtsiConnectivityServiceEndPointSpec_OtsiConfig_TransmitPower) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_OtsiConnectivityServiceEndPointSpec_OtsiConfig_TransmitPower"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_OtsiConnectivityServiceEndPointSpec_OtsiConfig_TransmitPower) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_PeerFwdConnectivityServiceEndPoint represents the /tapi-common/context/connectivity-context/connectivity-service/end-point/peer-fwd-connectivity-service-end-point YANG schema element.
type TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_PeerFwdConnectivityServiceEndPoint struct {
ConnectivityServiceEndPointLocalId *string `path:"connectivity-service-end-point-local-id" module:"tapi-connectivity"`
ConnectivityServiceUuid *string `path:"connectivity-service-uuid" module:"tapi-connectivity"`
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_PeerFwdConnectivityServiceEndPoint implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_PeerFwdConnectivityServiceEndPoint) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_PeerFwdConnectivityServiceEndPoint) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_PeerFwdConnectivityServiceEndPoint"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_PeerFwdConnectivityServiceEndPoint) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_ProtectingConnectivityServiceEndPoint represents the /tapi-common/context/connectivity-context/connectivity-service/end-point/protecting-connectivity-service-end-point YANG schema element.
type TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_ProtectingConnectivityServiceEndPoint struct {
ConnectivityServiceEndPointLocalId *string `path:"connectivity-service-end-point-local-id" module:"tapi-connectivity"`
ConnectivityServiceUuid *string `path:"connectivity-service-uuid" module:"tapi-connectivity"`
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_ProtectingConnectivityServiceEndPoint implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_ProtectingConnectivityServiceEndPoint) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_ProtectingConnectivityServiceEndPoint) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_ProtectingConnectivityServiceEndPoint"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_ProtectingConnectivityServiceEndPoint) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_ServerConnectivityServiceEndPoint represents the /tapi-common/context/connectivity-context/connectivity-service/end-point/server-connectivity-service-end-point YANG schema element.
type TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_ServerConnectivityServiceEndPoint struct {
ConnectivityServiceEndPointLocalId *string `path:"connectivity-service-end-point-local-id" module:"tapi-connectivity"`
ConnectivityServiceUuid *string `path:"connectivity-service-uuid" module:"tapi-connectivity"`
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_ServerConnectivityServiceEndPoint implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_ServerConnectivityServiceEndPoint) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_ServerConnectivityServiceEndPoint) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_ServerConnectivityServiceEndPoint"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_ServerConnectivityServiceEndPoint) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_ServiceInterfacePoint represents the /tapi-common/context/connectivity-context/connectivity-service/end-point/service-interface-point YANG schema element.
type TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_ServiceInterfacePoint struct {
ServiceInterfacePointUuid *string `path:"service-interface-point-uuid" module:"tapi-connectivity"`
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_ServiceInterfacePoint implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_ServiceInterfacePoint) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_ServiceInterfacePoint) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_ServiceInterfacePoint"], t, opts...); err != nil {
return err
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_EndPoint_ServiceInterfacePoint) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_ConnectivityService_Name represents the /tapi-common/context/connectivity-context/connectivity-service/name YANG schema element.
type TapiCommon_Context_ConnectivityContext_ConnectivityService_Name struct {
Value *string `path:"value" module:"tapi-connectivity"`
ValueName *string `path:"value-name" module:"tapi-connectivity"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_ConnectivityService_Name implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_ConnectivityService_Name) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_ConnectivityContext_ConnectivityService_Name struct, which is a YANG list entry.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_Name) ΛListKeyMap() (map[string]interface{}, error) {
if t.ValueName == nil {
return nil, fmt.Errorf("nil value for key ValueName")
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_Name) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_ConnectivityService_Name"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
3178
3179
3180
3181
3182
3183
3184
3185
3186
3187
3188
3189
3190
3191
3192
3193
3194
3195
3196
3197
3198
3199
3200
3201
3202
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_Name) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint represents the /tapi-common/context/connectivity-context/connectivity-service/resilience-constraint YANG schema element.
type TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint struct {
FaultConditionDetermination E_TapiConnectivity_FaultConditionDetermination `path:"fault-condition-determination" module:"tapi-connectivity"`
HoldOffTime *uint64 `path:"hold-off-time" module:"tapi-connectivity"`
IsCoordinatedSwitchingBothEnds *bool `path:"is-coordinated-switching-both-ends" module:"tapi-connectivity"`
IsFrozen *bool `path:"is-frozen" module:"tapi-connectivity"`
IsLockOut *bool `path:"is-lock-out" module:"tapi-connectivity"`
MaxSwitchTimes *uint64 `path:"max-switch-times" module:"tapi-connectivity"`
PreferredRestorationLayer []E_TapiConnectivity_LayerProtocolName `path:"preferred-restoration-layer" module:"tapi-connectivity"`
ResilienceType *TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResilienceType `path:"resilience-type" module:"tapi-connectivity"`
ResiliencyRouteConstraint map[string]*TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint `path:"resiliency-route-constraint" module:"tapi-connectivity"`
RestorationCoordinateType E_TapiConnectivity_CoordinateType `path:"restoration-coordinate-type" module:"tapi-connectivity"`
RestorePriority *uint64 `path:"restore-priority" module:"tapi-connectivity"`
ReversionMode E_TapiConnectivity_ReversionMode `path:"reversion-mode" module:"tapi-connectivity"`
SelectionControl E_TapiConnectivity_SelectionControl `path:"selection-control" module:"tapi-connectivity"`
WaitToRevertTime *uint64 `path:"wait-to-revert-time" module:"tapi-connectivity"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint) IsYANGGoStruct() {}
// NewResiliencyRouteConstraint creates a new entry in the ResiliencyRouteConstraint list of the
// TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint struct. The keys of the list are populated from the input
// arguments.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint) NewResiliencyRouteConstraint(LocalId string) (*TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.ResiliencyRouteConstraint == nil {
t.ResiliencyRouteConstraint = make(map[string]*TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint)
}
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.ResiliencyRouteConstraint[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list ResiliencyRouteConstraint", key)
t.ResiliencyRouteConstraint[key] = &TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint{
LocalId: &LocalId,
}
return t.ResiliencyRouteConstraint[key], nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResilienceType represents the /tapi-common/context/connectivity-context/connectivity-service/resilience-constraint/resilience-type YANG schema element.
type TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResilienceType struct {
ProtectionType E_TapiTopology_ProtectionType `path:"protection-type" module:"tapi-connectivity"`
RestorationPolicy E_TapiTopology_RestorationPolicy `path:"restoration-policy" module:"tapi-connectivity"`
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResilienceType implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResilienceType) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResilienceType) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResilienceType"], t, opts...); err != nil {
return err
}
return nil
3263
3264
3265
3266
3267
3268
3269
3270
3271
3272
3273
3274
3275
3276
3277
3278
3279
3280
3281
3282
3283
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResilienceType) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint represents the /tapi-common/context/connectivity-context/connectivity-service/resilience-constraint/resiliency-route-constraint YANG schema element.
type TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint struct {
LocalId *string `path:"local-id" module:"tapi-connectivity"`
Name map[string]*TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_Name `path:"name" module:"tapi-connectivity"`
Priority *uint64 `path:"priority" module:"tapi-connectivity"`
RoutingConstraint *TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint `path:"routing-constraint" module:"tapi-connectivity"`
TopologyConstraint *TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_TopologyConstraint `path:"topology-constraint" module:"tapi-connectivity"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint) IsYANGGoStruct() {}
// NewName creates a new entry in the Name list of the
// TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint struct. The keys of the list are populated from the input
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint) NewName(ValueName string) (*TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_Name, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.Name == nil {
t.Name = make(map[string]*TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_Name)
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.Name[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list Name", key)
t.Name[key] = &TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_Name{
ValueName: &ValueName,
3306
3307
3308
3309
3310
3311
3312
3313
3314
3315
3316
3317
3318
3319
3320
3321
3322
3323
3324
3325
3326
3327
3328
3329
3330
3331
3332
3333
3334
3335
3336
3337
3338
3339
3340
3341
3342
3343
3344
3345
3346
3347
3348
3349
3350
3351
3352
3353
3354
3355
3356
3357
3358
3359
3360
3361
3362
3363
3364
3365
3366
3367
3368
3369
3370
3371
3372
3373
3374
3375
3376
3377
3378
3379
return t.Name[key], nil
}
// ΛListKeyMap returns the keys of the TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint struct, which is a YANG list entry.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint) ΛListKeyMap() (map[string]interface{}, error) {
if t.LocalId == nil {
return nil, fmt.Errorf("nil value for key LocalId")
}
return map[string]interface{}{
"local-id": *t.LocalId,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_Name represents the /tapi-common/context/connectivity-context/connectivity-service/resilience-constraint/resiliency-route-constraint/name YANG schema element.
type TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_Name struct {
Value *string `path:"value" module:"tapi-connectivity"`
ValueName *string `path:"value-name" module:"tapi-connectivity"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_Name implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_Name) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_Name struct, which is a YANG list entry.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_Name) ΛListKeyMap() (map[string]interface{}, error) {
if t.ValueName == nil {
return nil, fmt.Errorf("nil value for key ValueName")
}
return map[string]interface{}{
"value-name": *t.ValueName,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_Name) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_Name"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_Name) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint represents the /tapi-common/context/connectivity-context/connectivity-service/resilience-constraint/resiliency-route-constraint/routing-constraint YANG schema element.
type TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint struct {
CostCharacteristic map[string]*TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint_CostCharacteristic `path:"cost-characteristic" module:"tapi-connectivity"`
DiversityPolicy E_TapiPathComputation_DiversityPolicy `path:"diversity-policy" module:"tapi-connectivity"`
IsExclusive *bool `path:"is-exclusive" module:"tapi-connectivity"`
LatencyCharacteristic map[string]*TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint_LatencyCharacteristic `path:"latency-characteristic" module:"tapi-connectivity"`
MaxAllowedCost *TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint_MaxAllowedCost `path:"max-allowed-cost" module:"tapi-connectivity"`
MaxAllowedDelay *TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint_MaxAllowedDelay `path:"max-allowed-delay" module:"tapi-connectivity"`
MaxAllowedHops *TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint_MaxAllowedHops `path:"max-allowed-hops" module:"tapi-connectivity"`
RiskDiversityCharacteristic map[string]*TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint_RiskDiversityCharacteristic `path:"risk-diversity-characteristic" module:"tapi-connectivity"`
RouteObjectiveFunction E_TapiPathComputation_RouteObjectiveFunction `path:"route-objective-function" module:"tapi-connectivity"`
TolerableImpact E_TapiPathComputation_GradesOfImpact `path:"tolerable-impact" module:"tapi-connectivity"`
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint) IsYANGGoStruct() {}
// NewCostCharacteristic creates a new entry in the CostCharacteristic list of the
// TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint struct. The keys of the list are populated from the input
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint) NewCostCharacteristic(CostName string) (*TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint_CostCharacteristic, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.CostCharacteristic == nil {
t.CostCharacteristic = make(map[string]*TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint_CostCharacteristic)
}
key := CostName
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.CostCharacteristic[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list CostCharacteristic", key)
}
t.CostCharacteristic[key] = &TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint_CostCharacteristic{
CostName: &CostName,
}
return t.CostCharacteristic[key], nil
}
// NewLatencyCharacteristic creates a new entry in the LatencyCharacteristic list of the
// TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint struct. The keys of the list are populated from the input
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint) NewLatencyCharacteristic(TrafficPropertyName string) (*TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint_LatencyCharacteristic, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.LatencyCharacteristic == nil {
t.LatencyCharacteristic = make(map[string]*TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint_LatencyCharacteristic)
}
key := TrafficPropertyName
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.LatencyCharacteristic[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list LatencyCharacteristic", key)
}
t.LatencyCharacteristic[key] = &TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint_LatencyCharacteristic{
TrafficPropertyName: &TrafficPropertyName,
}
return t.LatencyCharacteristic[key], nil
}
// NewRiskDiversityCharacteristic creates a new entry in the RiskDiversityCharacteristic list of the
// TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint struct. The keys of the list are populated from the input
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint) NewRiskDiversityCharacteristic(RiskCharacteristicName string) (*TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint_RiskDiversityCharacteristic, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.RiskDiversityCharacteristic == nil {
t.RiskDiversityCharacteristic = make(map[string]*TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint_RiskDiversityCharacteristic)
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.RiskDiversityCharacteristic[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list RiskDiversityCharacteristic", key)
t.RiskDiversityCharacteristic[key] = &TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint_RiskDiversityCharacteristic{
RiskCharacteristicName: &RiskCharacteristicName,
return t.RiskDiversityCharacteristic[key], nil
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint"], t, opts...); err != nil {
return err
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint_CostCharacteristic represents the /tapi-common/context/connectivity-context/connectivity-service/resilience-constraint/resiliency-route-constraint/routing-constraint/cost-characteristic YANG schema element.
type TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint_CostCharacteristic struct {
CostAlgorithm *string `path:"cost-algorithm" module:"tapi-connectivity"`
CostName *string `path:"cost-name" module:"tapi-connectivity"`
CostValue *string `path:"cost-value" module:"tapi-connectivity"`
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint_CostCharacteristic implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint_CostCharacteristic) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint_CostCharacteristic struct, which is a YANG list entry.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint_CostCharacteristic) ΛListKeyMap() (map[string]interface{}, error) {
if t.CostName == nil {
return nil, fmt.Errorf("nil value for key CostName")
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint_CostCharacteristic) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint_CostCharacteristic"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint_CostCharacteristic) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint_LatencyCharacteristic represents the /tapi-common/context/connectivity-context/connectivity-service/resilience-constraint/resiliency-route-constraint/routing-constraint/latency-characteristic YANG schema element.
type TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint_LatencyCharacteristic struct {
FixedLatencyCharacteristic *string `path:"fixed-latency-characteristic" module:"tapi-connectivity"`
JitterCharacteristic *string `path:"jitter-characteristic" module:"tapi-connectivity"`
QueingLatencyCharacteristic *string `path:"queing-latency-characteristic" module:"tapi-connectivity"`
TrafficPropertyName *string `path:"traffic-property-name" module:"tapi-connectivity"`
WanderCharacteristic *string `path:"wander-characteristic" module:"tapi-connectivity"`
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint_LatencyCharacteristic implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint_LatencyCharacteristic) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint_LatencyCharacteristic struct, which is a YANG list entry.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint_LatencyCharacteristic) ΛListKeyMap() (map[string]interface{}, error) {
if t.TrafficPropertyName == nil {
return nil, fmt.Errorf("nil value for key TrafficPropertyName")
"traffic-property-name": *t.TrafficPropertyName,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint_LatencyCharacteristic) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint_LatencyCharacteristic"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint_LatencyCharacteristic) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint_MaxAllowedCost represents the /tapi-common/context/connectivity-context/connectivity-service/resilience-constraint/resiliency-route-constraint/routing-constraint/max-allowed-cost YANG schema element.
type TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint_MaxAllowedCost struct {
Priority *uint64 `path:"priority" module:"tapi-connectivity"`
Value *uint64 `path:"value" module:"tapi-connectivity"`
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint_MaxAllowedCost implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint_MaxAllowedCost) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint_MaxAllowedCost) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint_MaxAllowedCost"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint_MaxAllowedCost) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint_MaxAllowedDelay represents the /tapi-common/context/connectivity-context/connectivity-service/resilience-constraint/resiliency-route-constraint/routing-constraint/max-allowed-delay YANG schema element.
type TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint_MaxAllowedDelay struct {
Priority *uint64 `path:"priority" module:"tapi-connectivity"`
Value *uint64 `path:"value" module:"tapi-connectivity"`
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint_MaxAllowedDelay implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint_MaxAllowedDelay) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint_MaxAllowedDelay) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint_MaxAllowedDelay"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint_MaxAllowedDelay) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint_MaxAllowedHops represents the /tapi-common/context/connectivity-context/connectivity-service/resilience-constraint/resiliency-route-constraint/routing-constraint/max-allowed-hops YANG schema element.
type TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint_MaxAllowedHops struct {
Priority *uint64 `path:"priority" module:"tapi-connectivity"`
Value *uint64 `path:"value" module:"tapi-connectivity"`
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint_MaxAllowedHops implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint_MaxAllowedHops) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint_MaxAllowedHops) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint_MaxAllowedHops"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint_MaxAllowedHops) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint_RiskDiversityCharacteristic represents the /tapi-common/context/connectivity-context/connectivity-service/resilience-constraint/resiliency-route-constraint/routing-constraint/risk-diversity-characteristic YANG schema element.
type TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint_RiskDiversityCharacteristic struct {
RiskCharacteristicName *string `path:"risk-characteristic-name" module:"tapi-connectivity"`
RiskIdentifierList []string `path:"risk-identifier-list" module:"tapi-connectivity"`
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint_RiskDiversityCharacteristic implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint_RiskDiversityCharacteristic) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint_RiskDiversityCharacteristic struct, which is a YANG list entry.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint_RiskDiversityCharacteristic) ΛListKeyMap() (map[string]interface{}, error) {
if t.RiskCharacteristicName == nil {
return nil, fmt.Errorf("nil value for key RiskCharacteristicName")
"risk-characteristic-name": *t.RiskCharacteristicName,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint_RiskDiversityCharacteristic) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint_RiskDiversityCharacteristic"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
3659
3660
3661
3662
3663
3664
3665
3666
3667
3668
3669
3670
3671
3672
3673
3674
3675
3676
3677
3678
3679
3680
3681
3682
3683
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_RoutingConstraint_RiskDiversityCharacteristic) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_TopologyConstraint represents the /tapi-common/context/connectivity-context/connectivity-service/resilience-constraint/resiliency-route-constraint/topology-constraint YANG schema element.
type TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_TopologyConstraint struct {
AvoidTopology *string `path:"avoid-topology" module:"tapi-connectivity"`
ConstraintWeight *uint64 `path:"constraint-weight" module:"tapi-connectivity"`
ExcludeLink *string `path:"exclude-link" module:"tapi-connectivity"`
ExcludeNode *string `path:"exclude-node" module:"tapi-connectivity"`
ExcludeNodeEdgePoint *string `path:"exclude-node-edge-point" module:"tapi-connectivity"`
ExcludePath *string `path:"exclude-path" module:"tapi-connectivity"`
IncludeLink *string `path:"include-link" module:"tapi-connectivity"`
IncludeNode *string `path:"include-node" module:"tapi-connectivity"`
IncludeNodeEdgePoint *string `path:"include-node-edge-point" module:"tapi-connectivity"`
IncludePath *string `path:"include-path" module:"tapi-connectivity"`
IncludeTopology *string `path:"include-topology" module:"tapi-connectivity"`
LocalId *string `path:"local-id" module:"tapi-connectivity"`
Name map[string]*TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_TopologyConstraint_Name `path:"name" module:"tapi-connectivity"`
PreferredTransportLayer E_TapiPathComputation_LayerProtocolName `path:"preferred-transport-layer" module:"tapi-connectivity"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_TopologyConstraint implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_TopologyConstraint) IsYANGGoStruct() {}
// NewName creates a new entry in the Name list of the
// TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_TopologyConstraint struct. The keys of the list are populated from the input
// arguments.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_TopologyConstraint) NewName(ValueName string) (*TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_TopologyConstraint_Name, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.Name == nil {
t.Name = make(map[string]*TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_TopologyConstraint_Name)
}
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.Name[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list Name", key)
t.Name[key] = &TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_TopologyConstraint_Name{
ValueName: &ValueName,
}
return t.Name[key], nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_TopologyConstraint) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_TopologyConstraint"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_TopologyConstraint) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_TopologyConstraint_Name represents the /tapi-common/context/connectivity-context/connectivity-service/resilience-constraint/resiliency-route-constraint/topology-constraint/name YANG schema element.
type TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_TopologyConstraint_Name struct {
Value *string `path:"value" module:"tapi-connectivity"`
ValueName *string `path:"value-name" module:"tapi-connectivity"`
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_TopologyConstraint_Name implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_TopologyConstraint_Name) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_TopologyConstraint_Name struct, which is a YANG list entry.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_TopologyConstraint_Name) ΛListKeyMap() (map[string]interface{}, error) {
if t.ValueName == nil {
return nil, fmt.Errorf("nil value for key ValueName")
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_TopologyConstraint_Name) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_TopologyConstraint_Name"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_ResilienceConstraint_ResiliencyRouteConstraint_TopologyConstraint_Name) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint represents the /tapi-common/context/connectivity-context/connectivity-service/routing-constraint YANG schema element.
type TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint struct {
CostCharacteristic map[string]*TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint_CostCharacteristic `path:"cost-characteristic" module:"tapi-connectivity"`
DiversityPolicy E_TapiPathComputation_DiversityPolicy `path:"diversity-policy" module:"tapi-connectivity"`
IsExclusive *bool `path:"is-exclusive" module:"tapi-connectivity"`
LatencyCharacteristic map[string]*TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint_LatencyCharacteristic `path:"latency-characteristic" module:"tapi-connectivity"`
MaxAllowedCost *TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint_MaxAllowedCost `path:"max-allowed-cost" module:"tapi-connectivity"`
MaxAllowedDelay *TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint_MaxAllowedDelay `path:"max-allowed-delay" module:"tapi-connectivity"`
MaxAllowedHops *TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint_MaxAllowedHops `path:"max-allowed-hops" module:"tapi-connectivity"`
RiskDiversityCharacteristic map[string]*TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint_RiskDiversityCharacteristic `path:"risk-diversity-characteristic" module:"tapi-connectivity"`
RouteObjectiveFunction E_TapiPathComputation_RouteObjectiveFunction `path:"route-objective-function" module:"tapi-connectivity"`
TolerableImpact E_TapiPathComputation_GradesOfImpact `path:"tolerable-impact" module:"tapi-connectivity"`
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint) IsYANGGoStruct() {}
// NewCostCharacteristic creates a new entry in the CostCharacteristic list of the
// TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint struct. The keys of the list are populated from the input
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint) NewCostCharacteristic(CostName string) (*TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint_CostCharacteristic, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.CostCharacteristic == nil {
t.CostCharacteristic = make(map[string]*TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint_CostCharacteristic)
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.CostCharacteristic[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list CostCharacteristic", key)
t.CostCharacteristic[key] = &TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint_CostCharacteristic{
CostName: &CostName,
return t.CostCharacteristic[key], nil
// NewLatencyCharacteristic creates a new entry in the LatencyCharacteristic list of the
// TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint struct. The keys of the list are populated from the input
// arguments.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint) NewLatencyCharacteristic(TrafficPropertyName string) (*TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint_LatencyCharacteristic, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.LatencyCharacteristic == nil {
t.LatencyCharacteristic = make(map[string]*TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint_LatencyCharacteristic)
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.LatencyCharacteristic[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list LatencyCharacteristic", key)
t.LatencyCharacteristic[key] = &TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint_LatencyCharacteristic{
TrafficPropertyName: &TrafficPropertyName,
}
return t.LatencyCharacteristic[key], nil
// NewRiskDiversityCharacteristic creates a new entry in the RiskDiversityCharacteristic list of the
// TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint struct. The keys of the list are populated from the input
// arguments.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint) NewRiskDiversityCharacteristic(RiskCharacteristicName string) (*TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint_RiskDiversityCharacteristic, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.RiskDiversityCharacteristic == nil {
t.RiskDiversityCharacteristic = make(map[string]*TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint_RiskDiversityCharacteristic)
}
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.RiskDiversityCharacteristic[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list RiskDiversityCharacteristic", key)
}
t.RiskDiversityCharacteristic[key] = &TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint_RiskDiversityCharacteristic{
RiskCharacteristicName: &RiskCharacteristicName,
}
return t.RiskDiversityCharacteristic[key], nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint_CostCharacteristic represents the /tapi-common/context/connectivity-context/connectivity-service/routing-constraint/cost-characteristic YANG schema element.
type TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint_CostCharacteristic struct {
CostAlgorithm *string `path:"cost-algorithm" module:"tapi-connectivity"`
CostName *string `path:"cost-name" module:"tapi-connectivity"`
CostValue *string `path:"cost-value" module:"tapi-connectivity"`
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint_CostCharacteristic implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint_CostCharacteristic) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint_CostCharacteristic struct, which is a YANG list entry.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint_CostCharacteristic) ΛListKeyMap() (map[string]interface{}, error) {
if t.CostName == nil {
return nil, fmt.Errorf("nil value for key CostName")
}
return map[string]interface{}{
"cost-name": *t.CostName,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint_CostCharacteristic) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint_CostCharacteristic"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint_CostCharacteristic) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint_LatencyCharacteristic represents the /tapi-common/context/connectivity-context/connectivity-service/routing-constraint/latency-characteristic YANG schema element.
type TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint_LatencyCharacteristic struct {
FixedLatencyCharacteristic *string `path:"fixed-latency-characteristic" module:"tapi-connectivity"`
JitterCharacteristic *string `path:"jitter-characteristic" module:"tapi-connectivity"`
QueingLatencyCharacteristic *string `path:"queing-latency-characteristic" module:"tapi-connectivity"`
TrafficPropertyName *string `path:"traffic-property-name" module:"tapi-connectivity"`
WanderCharacteristic *string `path:"wander-characteristic" module:"tapi-connectivity"`
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint_LatencyCharacteristic implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint_LatencyCharacteristic) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint_LatencyCharacteristic struct, which is a YANG list entry.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint_LatencyCharacteristic) ΛListKeyMap() (map[string]interface{}, error) {
if t.TrafficPropertyName == nil {
return nil, fmt.Errorf("nil value for key TrafficPropertyName")
"traffic-property-name": *t.TrafficPropertyName,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint_LatencyCharacteristic) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint_LatencyCharacteristic"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint_LatencyCharacteristic) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint_MaxAllowedCost represents the /tapi-common/context/connectivity-context/connectivity-service/routing-constraint/max-allowed-cost YANG schema element.
type TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint_MaxAllowedCost struct {
Priority *uint64 `path:"priority" module:"tapi-connectivity"`
Value *uint64 `path:"value" module:"tapi-connectivity"`
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint_MaxAllowedCost implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint_MaxAllowedCost) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint_MaxAllowedCost) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint_MaxAllowedCost"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint_MaxAllowedCost) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint_MaxAllowedDelay represents the /tapi-common/context/connectivity-context/connectivity-service/routing-constraint/max-allowed-delay YANG schema element.
type TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint_MaxAllowedDelay struct {
Priority *uint64 `path:"priority" module:"tapi-connectivity"`
Value *uint64 `path:"value" module:"tapi-connectivity"`
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint_MaxAllowedDelay implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint_MaxAllowedDelay) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint_MaxAllowedDelay) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint_MaxAllowedDelay"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint_MaxAllowedDelay) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint_MaxAllowedHops represents the /tapi-common/context/connectivity-context/connectivity-service/routing-constraint/max-allowed-hops YANG schema element.
type TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint_MaxAllowedHops struct {
Priority *uint64 `path:"priority" module:"tapi-connectivity"`
Value *uint64 `path:"value" module:"tapi-connectivity"`
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint_MaxAllowedHops implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint_MaxAllowedHops) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint_MaxAllowedHops) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint_MaxAllowedHops"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint_MaxAllowedHops) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint_RiskDiversityCharacteristic represents the /tapi-common/context/connectivity-context/connectivity-service/routing-constraint/risk-diversity-characteristic YANG schema element.
type TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint_RiskDiversityCharacteristic struct {
RiskCharacteristicName *string `path:"risk-characteristic-name" module:"tapi-connectivity"`
RiskIdentifierList []string `path:"risk-identifier-list" module:"tapi-connectivity"`
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint_RiskDiversityCharacteristic implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint_RiskDiversityCharacteristic) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint_RiskDiversityCharacteristic struct, which is a YANG list entry.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint_RiskDiversityCharacteristic) ΛListKeyMap() (map[string]interface{}, error) {
if t.RiskCharacteristicName == nil {
return nil, fmt.Errorf("nil value for key RiskCharacteristicName")
"risk-characteristic-name": *t.RiskCharacteristicName,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint_RiskDiversityCharacteristic) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint_RiskDiversityCharacteristic"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
4051
4052
4053
4054
4055
4056
4057
4058
4059
4060
4061
4062
4063
4064
4065
4066
4067
4068
4069
4070
4071
4072
4073
4074
4075
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_RoutingConstraint_RiskDiversityCharacteristic) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_ConnectivityService_TopologyConstraint represents the /tapi-common/context/connectivity-context/connectivity-service/topology-constraint YANG schema element.
type TapiCommon_Context_ConnectivityContext_ConnectivityService_TopologyConstraint struct {
AvoidTopology *string `path:"avoid-topology" module:"tapi-connectivity"`
ConstraintWeight *uint64 `path:"constraint-weight" module:"tapi-connectivity"`
ExcludeLink *string `path:"exclude-link" module:"tapi-connectivity"`
ExcludeNode *string `path:"exclude-node" module:"tapi-connectivity"`
ExcludeNodeEdgePoint *string `path:"exclude-node-edge-point" module:"tapi-connectivity"`
ExcludePath *string `path:"exclude-path" module:"tapi-connectivity"`
IncludeLink *string `path:"include-link" module:"tapi-connectivity"`
IncludeNode *string `path:"include-node" module:"tapi-connectivity"`
IncludeNodeEdgePoint *string `path:"include-node-edge-point" module:"tapi-connectivity"`
IncludePath *string `path:"include-path" module:"tapi-connectivity"`
IncludeTopology *string `path:"include-topology" module:"tapi-connectivity"`
LocalId *string `path:"local-id" module:"tapi-connectivity"`
Name map[string]*TapiCommon_Context_ConnectivityContext_ConnectivityService_TopologyConstraint_Name `path:"name" module:"tapi-connectivity"`
PreferredTransportLayer E_TapiPathComputation_LayerProtocolName `path:"preferred-transport-layer" module:"tapi-connectivity"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_ConnectivityService_TopologyConstraint implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_ConnectivityService_TopologyConstraint) IsYANGGoStruct() {}
// NewName creates a new entry in the Name list of the
// TapiCommon_Context_ConnectivityContext_ConnectivityService_TopologyConstraint struct. The keys of the list are populated from the input
// arguments.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_TopologyConstraint) NewName(ValueName string) (*TapiCommon_Context_ConnectivityContext_ConnectivityService_TopologyConstraint_Name, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.Name == nil {
t.Name = make(map[string]*TapiCommon_Context_ConnectivityContext_ConnectivityService_TopologyConstraint_Name)
}
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.Name[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list Name", key)
}
t.Name[key] = &TapiCommon_Context_ConnectivityContext_ConnectivityService_TopologyConstraint_Name{
ValueName: &ValueName,
}
return t.Name[key], nil
}
// ΛListKeyMap returns the keys of the TapiCommon_Context_ConnectivityContext_ConnectivityService_TopologyConstraint struct, which is a YANG list entry.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_TopologyConstraint) ΛListKeyMap() (map[string]interface{}, error) {
if t.LocalId == nil {
return nil, fmt.Errorf("nil value for key LocalId")
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_TopologyConstraint) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_ConnectivityService_TopologyConstraint"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_TopologyConstraint) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ConnectivityContext_ConnectivityService_TopologyConstraint_Name represents the /tapi-common/context/connectivity-context/connectivity-service/topology-constraint/name YANG schema element.
type TapiCommon_Context_ConnectivityContext_ConnectivityService_TopologyConstraint_Name struct {
Value *string `path:"value" module:"tapi-connectivity"`
ValueName *string `path:"value-name" module:"tapi-connectivity"`
// IsYANGGoStruct ensures that TapiCommon_Context_ConnectivityContext_ConnectivityService_TopologyConstraint_Name implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ConnectivityContext_ConnectivityService_TopologyConstraint_Name) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_ConnectivityContext_ConnectivityService_TopologyConstraint_Name struct, which is a YANG list entry.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_TopologyConstraint_Name) ΛListKeyMap() (map[string]interface{}, error) {
if t.ValueName == nil {
return nil, fmt.Errorf("nil value for key ValueName")
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_TopologyConstraint_Name) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ConnectivityContext_ConnectivityService_TopologyConstraint_Name"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ConnectivityContext_ConnectivityService_TopologyConstraint_Name) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_Name represents the /tapi-common/context/name YANG schema element.
type TapiCommon_Context_Name struct {
Value *string `path:"value" module:"tapi-common"`
ValueName *string `path:"value-name" module:"tapi-common"`
// IsYANGGoStruct ensures that TapiCommon_Context_Name implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_Name) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_Name struct, which is a YANG list entry.
func (t *TapiCommon_Context_Name) ΛListKeyMap() (map[string]interface{}, error) {
if t.ValueName == nil {
return nil, fmt.Errorf("nil value for key ValueName")
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_Name) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_Name"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_Name) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_PathComputationContext represents the /tapi-common/context/path-computation-context YANG schema element.
type TapiCommon_Context_PathComputationContext struct {
Path map[string]*TapiCommon_Context_PathComputationContext_Path `path:"path" module:"tapi-path-computation"`
PathCompService map[string]*TapiCommon_Context_PathComputationContext_PathCompService `path:"path-comp-service" module:"tapi-path-computation"`
// IsYANGGoStruct ensures that TapiCommon_Context_PathComputationContext implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_PathComputationContext) IsYANGGoStruct() {}
// NewPath creates a new entry in the Path list of the
// TapiCommon_Context_PathComputationContext struct. The keys of the list are populated from the input
func (t *TapiCommon_Context_PathComputationContext) NewPath(Uuid string) (*TapiCommon_Context_PathComputationContext_Path, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.Path == nil {
t.Path = make(map[string]*TapiCommon_Context_PathComputationContext_Path)
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.Path[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list Path", key)
t.Path[key] = &TapiCommon_Context_PathComputationContext_Path{
Uuid: &Uuid,
// NewPathCompService creates a new entry in the PathCompService list of the
// TapiCommon_Context_PathComputationContext struct. The keys of the list are populated from the input
// arguments.
func (t *TapiCommon_Context_PathComputationContext) NewPathCompService(Uuid string) (*TapiCommon_Context_PathComputationContext_PathCompService, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.PathCompService == nil {
t.PathCompService = make(map[string]*TapiCommon_Context_PathComputationContext_PathCompService)
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.PathCompService[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list PathCompService", key)
}
t.PathCompService[key] = &TapiCommon_Context_PathComputationContext_PathCompService{
Uuid: &Uuid,
}
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_PathComputationContext) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_PathComputationContext"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_PathComputationContext) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_PathComputationContext_Path represents the /tapi-common/context/path-computation-context/path YANG schema element.
type TapiCommon_Context_PathComputationContext_Path struct {
Direction E_TapiPathComputation_ForwardingDirection `path:"direction" module:"tapi-path-computation"`
LayerProtocolName E_TapiPathComputation_LayerProtocolName `path:"layer-protocol-name" module:"tapi-path-computation"`
Link map[TapiCommon_Context_PathComputationContext_Path_Link_Key]*TapiCommon_Context_PathComputationContext_Path_Link `path:"link" module:"tapi-path-computation"`
Name map[string]*TapiCommon_Context_PathComputationContext_Path_Name `path:"name" module:"tapi-path-computation"`
RoutingConstraint *TapiCommon_Context_PathComputationContext_Path_RoutingConstraint `path:"routing-constraint" module:"tapi-path-computation"`
Uuid *string `path:"uuid" module:"tapi-path-computation"`
// IsYANGGoStruct ensures that TapiCommon_Context_PathComputationContext_Path implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_PathComputationContext_Path) IsYANGGoStruct() {}
// TapiCommon_Context_PathComputationContext_Path_Link_Key represents the key for list Link of element /tapi-common/context/path-computation-context/path.
type TapiCommon_Context_PathComputationContext_Path_Link_Key struct {
TopologyUuid string `path:"topology-uuid"`
LinkUuid string `path:"link-uuid"`
// NewLink creates a new entry in the Link list of the
// TapiCommon_Context_PathComputationContext_Path struct. The keys of the list are populated from the input
// arguments.
func (t *TapiCommon_Context_PathComputationContext_Path) NewLink(TopologyUuid string, LinkUuid string) (*TapiCommon_Context_PathComputationContext_Path_Link, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.Link == nil {
t.Link = make(map[TapiCommon_Context_PathComputationContext_Path_Link_Key]*TapiCommon_Context_PathComputationContext_Path_Link)
key := TapiCommon_Context_PathComputationContext_Path_Link_Key{
TopologyUuid: TopologyUuid,
LinkUuid: LinkUuid,
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.Link[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list Link", key)
}
t.Link[key] = &TapiCommon_Context_PathComputationContext_Path_Link{
TopologyUuid: &TopologyUuid,
LinkUuid: &LinkUuid,
}
// NewName creates a new entry in the Name list of the
// TapiCommon_Context_PathComputationContext_Path struct. The keys of the list are populated from the input
// arguments.
func (t *TapiCommon_Context_PathComputationContext_Path) NewName(ValueName string) (*TapiCommon_Context_PathComputationContext_Path_Name, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.Name == nil {
t.Name = make(map[string]*TapiCommon_Context_PathComputationContext_Path_Name)
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.Name[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list Name", key)
}
t.Name[key] = &TapiCommon_Context_PathComputationContext_Path_Name{
ValueName: &ValueName,
// ΛListKeyMap returns the keys of the TapiCommon_Context_PathComputationContext_Path struct, which is a YANG list entry.
func (t *TapiCommon_Context_PathComputationContext_Path) ΛListKeyMap() (map[string]interface{}, error) {
if t.Uuid == nil {
return nil, fmt.Errorf("nil value for key Uuid")
}
return map[string]interface{}{
"uuid": *t.Uuid,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_PathComputationContext_Path) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_PathComputationContext_Path"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_PathComputationContext_Path) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_PathComputationContext_PathCompService represents the /tapi-common/context/path-computation-context/path-comp-service YANG schema element.
type TapiCommon_Context_PathComputationContext_PathCompService struct {
Direction E_TapiPathComputation_ForwardingDirection `path:"direction" module:"tapi-path-computation"`
EndPoint map[string]*TapiCommon_Context_PathComputationContext_PathCompService_EndPoint `path:"end-point" module:"tapi-path-computation"`
LayerProtocolName E_TapiPathComputation_LayerProtocolName `path:"layer-protocol-name" module:"tapi-path-computation"`
Name map[string]*TapiCommon_Context_PathComputationContext_PathCompService_Name `path:"name" module:"tapi-path-computation"`
ObjectiveFunction *TapiCommon_Context_PathComputationContext_PathCompService_ObjectiveFunction `path:"objective-function" module:"tapi-path-computation"`
OptimizationConstraint *TapiCommon_Context_PathComputationContext_PathCompService_OptimizationConstraint `path:"optimization-constraint" module:"tapi-path-computation"`
Path map[string]*TapiCommon_Context_PathComputationContext_PathCompService_Path `path:"path" module:"tapi-path-computation"`
RoutingConstraint *TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint `path:"routing-constraint" module:"tapi-path-computation"`
TopologyConstraint map[string]*TapiCommon_Context_PathComputationContext_PathCompService_TopologyConstraint `path:"topology-constraint" module:"tapi-path-computation"`
Uuid *string `path:"uuid" module:"tapi-path-computation"`
// IsYANGGoStruct ensures that TapiCommon_Context_PathComputationContext_PathCompService implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_PathComputationContext_PathCompService) IsYANGGoStruct() {}
// NewEndPoint creates a new entry in the EndPoint list of the
// TapiCommon_Context_PathComputationContext_PathCompService struct. The keys of the list are populated from the input
func (t *TapiCommon_Context_PathComputationContext_PathCompService) NewEndPoint(LocalId string) (*TapiCommon_Context_PathComputationContext_PathCompService_EndPoint, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.EndPoint == nil {
t.EndPoint = make(map[string]*TapiCommon_Context_PathComputationContext_PathCompService_EndPoint)
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.EndPoint[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list EndPoint", key)
t.EndPoint[key] = &TapiCommon_Context_PathComputationContext_PathCompService_EndPoint{
LocalId: &LocalId,
// NewName creates a new entry in the Name list of the
// TapiCommon_Context_PathComputationContext_PathCompService struct. The keys of the list are populated from the input
func (t *TapiCommon_Context_PathComputationContext_PathCompService) NewName(ValueName string) (*TapiCommon_Context_PathComputationContext_PathCompService_Name, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.Name == nil {
t.Name = make(map[string]*TapiCommon_Context_PathComputationContext_PathCompService_Name)
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.Name[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list Name", key)
t.Name[key] = &TapiCommon_Context_PathComputationContext_PathCompService_Name{
ValueName: &ValueName,
// NewPath creates a new entry in the Path list of the
// TapiCommon_Context_PathComputationContext_PathCompService struct. The keys of the list are populated from the input
func (t *TapiCommon_Context_PathComputationContext_PathCompService) NewPath(PathUuid string) (*TapiCommon_Context_PathComputationContext_PathCompService_Path, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.Path == nil {
t.Path = make(map[string]*TapiCommon_Context_PathComputationContext_PathCompService_Path)
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.Path[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list Path", key)
t.Path[key] = &TapiCommon_Context_PathComputationContext_PathCompService_Path{
PathUuid: &PathUuid,
// NewTopologyConstraint creates a new entry in the TopologyConstraint list of the
// TapiCommon_Context_PathComputationContext_PathCompService struct. The keys of the list are populated from the input
func (t *TapiCommon_Context_PathComputationContext_PathCompService) NewTopologyConstraint(LocalId string) (*TapiCommon_Context_PathComputationContext_PathCompService_TopologyConstraint, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.TopologyConstraint == nil {
t.TopologyConstraint = make(map[string]*TapiCommon_Context_PathComputationContext_PathCompService_TopologyConstraint)
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.TopologyConstraint[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list TopologyConstraint", key)
t.TopologyConstraint[key] = &TapiCommon_Context_PathComputationContext_PathCompService_TopologyConstraint{
LocalId: &LocalId,
return t.TopologyConstraint[key], nil
// ΛListKeyMap returns the keys of the TapiCommon_Context_PathComputationContext_PathCompService struct, which is a YANG list entry.
func (t *TapiCommon_Context_PathComputationContext_PathCompService) ΛListKeyMap() (map[string]interface{}, error) {
if t.Uuid == nil {
return nil, fmt.Errorf("nil value for key Uuid")
}
return map[string]interface{}{
"uuid": *t.Uuid,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_PathComputationContext_PathCompService) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_PathComputationContext_PathCompService"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_PathComputationContext_PathCompService) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_PathComputationContext_PathCompService_EndPoint represents the /tapi-common/context/path-computation-context/path-comp-service/end-point YANG schema element.
type TapiCommon_Context_PathComputationContext_PathCompService_EndPoint struct {
Capacity *TapiCommon_Context_PathComputationContext_PathCompService_EndPoint_Capacity `path:"capacity" module:"tapi-path-computation"`
Direction E_TapiPathComputation_PortDirection `path:"direction" module:"tapi-path-computation"`
LayerProtocolName E_TapiPathComputation_LayerProtocolName `path:"layer-protocol-name" module:"tapi-path-computation"`
LayerProtocolQualifier E_TapiPathComputation_LayerProtocolQualifier `path:"layer-protocol-qualifier" module:"tapi-path-computation"`
LocalId *string `path:"local-id" module:"tapi-path-computation"`
Name map[string]*TapiCommon_Context_PathComputationContext_PathCompService_EndPoint_Name `path:"name" module:"tapi-path-computation"`
Role E_TapiPathComputation_PortRole `path:"role" module:"tapi-path-computation"`
ServiceInterfacePoint *TapiCommon_Context_PathComputationContext_PathCompService_EndPoint_ServiceInterfacePoint `path:"service-interface-point" module:"tapi-path-computation"`
// IsYANGGoStruct ensures that TapiCommon_Context_PathComputationContext_PathCompService_EndPoint implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_PathComputationContext_PathCompService_EndPoint) IsYANGGoStruct() {}
// NewName creates a new entry in the Name list of the
// TapiCommon_Context_PathComputationContext_PathCompService_EndPoint struct. The keys of the list are populated from the input
// arguments.
func (t *TapiCommon_Context_PathComputationContext_PathCompService_EndPoint) NewName(ValueName string) (*TapiCommon_Context_PathComputationContext_PathCompService_EndPoint_Name, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.Name == nil {
t.Name = make(map[string]*TapiCommon_Context_PathComputationContext_PathCompService_EndPoint_Name)
key := ValueName
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.Name[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list Name", key)
t.Name[key] = &TapiCommon_Context_PathComputationContext_PathCompService_EndPoint_Name{
ValueName: &ValueName,
}
return t.Name[key], nil
}
// ΛListKeyMap returns the keys of the TapiCommon_Context_PathComputationContext_PathCompService_EndPoint struct, which is a YANG list entry.
func (t *TapiCommon_Context_PathComputationContext_PathCompService_EndPoint) ΛListKeyMap() (map[string]interface{}, error) {
if t.LocalId == nil {
return nil, fmt.Errorf("nil value for key LocalId")
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_PathComputationContext_PathCompService_EndPoint) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_PathComputationContext_PathCompService_EndPoint"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_PathComputationContext_PathCompService_EndPoint) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_PathComputationContext_PathCompService_EndPoint_Capacity represents the /tapi-common/context/path-computation-context/path-comp-service/end-point/capacity YANG schema element.
type TapiCommon_Context_PathComputationContext_PathCompService_EndPoint_Capacity struct {
TotalSize *TapiCommon_Context_PathComputationContext_PathCompService_EndPoint_Capacity_TotalSize `path:"total-size" module:"tapi-path-computation"`
// IsYANGGoStruct ensures that TapiCommon_Context_PathComputationContext_PathCompService_EndPoint_Capacity implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_PathComputationContext_PathCompService_EndPoint_Capacity) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_PathComputationContext_PathCompService_EndPoint_Capacity) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_PathComputationContext_PathCompService_EndPoint_Capacity"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_PathComputationContext_PathCompService_EndPoint_Capacity) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_PathComputationContext_PathCompService_EndPoint_Capacity_TotalSize represents the /tapi-common/context/path-computation-context/path-comp-service/end-point/capacity/total-size YANG schema element.
type TapiCommon_Context_PathComputationContext_PathCompService_EndPoint_Capacity_TotalSize struct {
Unit E_TapiCommon_CapacityUnit `path:"unit" module:"tapi-path-computation"`
Value *uint64 `path:"value" module:"tapi-path-computation"`
// IsYANGGoStruct ensures that TapiCommon_Context_PathComputationContext_PathCompService_EndPoint_Capacity_TotalSize implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_PathComputationContext_PathCompService_EndPoint_Capacity_TotalSize) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_PathComputationContext_PathCompService_EndPoint_Capacity_TotalSize) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_PathComputationContext_PathCompService_EndPoint_Capacity_TotalSize"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_PathComputationContext_PathCompService_EndPoint_Capacity_TotalSize) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_PathComputationContext_PathCompService_EndPoint_Name represents the /tapi-common/context/path-computation-context/path-comp-service/end-point/name YANG schema element.
type TapiCommon_Context_PathComputationContext_PathCompService_EndPoint_Name struct {
Value *string `path:"value" module:"tapi-path-computation"`
ValueName *string `path:"value-name" module:"tapi-path-computation"`
// IsYANGGoStruct ensures that TapiCommon_Context_PathComputationContext_PathCompService_EndPoint_Name implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_PathComputationContext_PathCompService_EndPoint_Name) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_PathComputationContext_PathCompService_EndPoint_Name struct, which is a YANG list entry.
func (t *TapiCommon_Context_PathComputationContext_PathCompService_EndPoint_Name) ΛListKeyMap() (map[string]interface{}, error) {
if t.ValueName == nil {
return nil, fmt.Errorf("nil value for key ValueName")
}
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_PathComputationContext_PathCompService_EndPoint_Name) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_PathComputationContext_PathCompService_EndPoint_Name"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_PathComputationContext_PathCompService_EndPoint_Name) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_PathComputationContext_PathCompService_EndPoint_ServiceInterfacePoint represents the /tapi-common/context/path-computation-context/path-comp-service/end-point/service-interface-point YANG schema element.
type TapiCommon_Context_PathComputationContext_PathCompService_EndPoint_ServiceInterfacePoint struct {
ServiceInterfacePointUuid *string `path:"service-interface-point-uuid" module:"tapi-path-computation"`
// IsYANGGoStruct ensures that TapiCommon_Context_PathComputationContext_PathCompService_EndPoint_ServiceInterfacePoint implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_PathComputationContext_PathCompService_EndPoint_ServiceInterfacePoint) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_PathComputationContext_PathCompService_EndPoint_ServiceInterfacePoint) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_PathComputationContext_PathCompService_EndPoint_ServiceInterfacePoint"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_PathComputationContext_PathCompService_EndPoint_ServiceInterfacePoint) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_PathComputationContext_PathCompService_Name represents the /tapi-common/context/path-computation-context/path-comp-service/name YANG schema element.
type TapiCommon_Context_PathComputationContext_PathCompService_Name struct {
Value *string `path:"value" module:"tapi-path-computation"`
ValueName *string `path:"value-name" module:"tapi-path-computation"`
// IsYANGGoStruct ensures that TapiCommon_Context_PathComputationContext_PathCompService_Name implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_PathComputationContext_PathCompService_Name) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_PathComputationContext_PathCompService_Name struct, which is a YANG list entry.
func (t *TapiCommon_Context_PathComputationContext_PathCompService_Name) ΛListKeyMap() (map[string]interface{}, error) {
if t.ValueName == nil {
return nil, fmt.Errorf("nil value for key ValueName")
}
return map[string]interface{}{
"value-name": *t.ValueName,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_PathComputationContext_PathCompService_Name) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_PathComputationContext_PathCompService_Name"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_PathComputationContext_PathCompService_Name) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_PathComputationContext_PathCompService_ObjectiveFunction represents the /tapi-common/context/path-computation-context/path-comp-service/objective-function YANG schema element.
type TapiCommon_Context_PathComputationContext_PathCompService_ObjectiveFunction struct {
BandwidthOptimization E_TapiPathComputation_DirectiveValue `path:"bandwidth-optimization" module:"tapi-path-computation"`
ConcurrentPaths E_TapiPathComputation_DirectiveValue `path:"concurrent-paths" module:"tapi-path-computation"`
CostOptimization E_TapiPathComputation_DirectiveValue `path:"cost-optimization" module:"tapi-path-computation"`
LinkUtilization E_TapiPathComputation_DirectiveValue `path:"link-utilization" module:"tapi-path-computation"`
LocalId *string `path:"local-id" module:"tapi-path-computation"`
Name map[string]*TapiCommon_Context_PathComputationContext_PathCompService_ObjectiveFunction_Name `path:"name" module:"tapi-path-computation"`
ResourceSharing E_TapiPathComputation_DirectiveValue `path:"resource-sharing" module:"tapi-path-computation"`
// IsYANGGoStruct ensures that TapiCommon_Context_PathComputationContext_PathCompService_ObjectiveFunction implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
4752
4753
4754
4755
4756
4757
4758
4759
4760
4761
4762
4763
4764
4765
4766
4767
4768
4769
4770
4771
4772
4773
4774
4775
4776
4777
4778
4779
func (*TapiCommon_Context_PathComputationContext_PathCompService_ObjectiveFunction) IsYANGGoStruct() {}
// NewName creates a new entry in the Name list of the
// TapiCommon_Context_PathComputationContext_PathCompService_ObjectiveFunction struct. The keys of the list are populated from the input
// arguments.
func (t *TapiCommon_Context_PathComputationContext_PathCompService_ObjectiveFunction) NewName(ValueName string) (*TapiCommon_Context_PathComputationContext_PathCompService_ObjectiveFunction_Name, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.Name == nil {
t.Name = make(map[string]*TapiCommon_Context_PathComputationContext_PathCompService_ObjectiveFunction_Name)
}
key := ValueName
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.Name[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list Name", key)
}
t.Name[key] = &TapiCommon_Context_PathComputationContext_PathCompService_ObjectiveFunction_Name{
ValueName: &ValueName,
}
return t.Name[key], nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_PathComputationContext_PathCompService_ObjectiveFunction) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_PathComputationContext_PathCompService_ObjectiveFunction"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_PathComputationContext_PathCompService_ObjectiveFunction) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_PathComputationContext_PathCompService_ObjectiveFunction_Name represents the /tapi-common/context/path-computation-context/path-comp-service/objective-function/name YANG schema element.
type TapiCommon_Context_PathComputationContext_PathCompService_ObjectiveFunction_Name struct {
Value *string `path:"value" module:"tapi-path-computation"`
ValueName *string `path:"value-name" module:"tapi-path-computation"`
// IsYANGGoStruct ensures that TapiCommon_Context_PathComputationContext_PathCompService_ObjectiveFunction_Name implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_PathComputationContext_PathCompService_ObjectiveFunction_Name) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_PathComputationContext_PathCompService_ObjectiveFunction_Name struct, which is a YANG list entry.
func (t *TapiCommon_Context_PathComputationContext_PathCompService_ObjectiveFunction_Name) ΛListKeyMap() (map[string]interface{}, error) {
if t.ValueName == nil {
return nil, fmt.Errorf("nil value for key ValueName")
}
return map[string]interface{}{
"value-name": *t.ValueName,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_PathComputationContext_PathCompService_ObjectiveFunction_Name) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_PathComputationContext_PathCompService_ObjectiveFunction_Name"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_PathComputationContext_PathCompService_ObjectiveFunction_Name) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_PathComputationContext_PathCompService_OptimizationConstraint represents the /tapi-common/context/path-computation-context/path-comp-service/optimization-constraint YANG schema element.
type TapiCommon_Context_PathComputationContext_PathCompService_OptimizationConstraint struct {
LocalId *string `path:"local-id" module:"tapi-path-computation"`
Name map[string]*TapiCommon_Context_PathComputationContext_PathCompService_OptimizationConstraint_Name `path:"name" module:"tapi-path-computation"`
TrafficInterruption E_TapiPathComputation_DirectiveValue `path:"traffic-interruption" module:"tapi-path-computation"`
// IsYANGGoStruct ensures that TapiCommon_Context_PathComputationContext_PathCompService_OptimizationConstraint implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
4839
4840
4841
4842
4843
4844
4845
4846
4847
4848
4849
4850
4851
4852
4853
4854
4855
4856
4857
4858
4859
4860
4861
4862
4863
4864
4865
4866
func (*TapiCommon_Context_PathComputationContext_PathCompService_OptimizationConstraint) IsYANGGoStruct() {}
// NewName creates a new entry in the Name list of the
// TapiCommon_Context_PathComputationContext_PathCompService_OptimizationConstraint struct. The keys of the list are populated from the input
// arguments.
func (t *TapiCommon_Context_PathComputationContext_PathCompService_OptimizationConstraint) NewName(ValueName string) (*TapiCommon_Context_PathComputationContext_PathCompService_OptimizationConstraint_Name, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.Name == nil {
t.Name = make(map[string]*TapiCommon_Context_PathComputationContext_PathCompService_OptimizationConstraint_Name)
}
key := ValueName
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.Name[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list Name", key)
}
t.Name[key] = &TapiCommon_Context_PathComputationContext_PathCompService_OptimizationConstraint_Name{
ValueName: &ValueName,
}
return t.Name[key], nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_PathComputationContext_PathCompService_OptimizationConstraint) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_PathComputationContext_PathCompService_OptimizationConstraint"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_PathComputationContext_PathCompService_OptimizationConstraint) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_PathComputationContext_PathCompService_OptimizationConstraint_Name represents the /tapi-common/context/path-computation-context/path-comp-service/optimization-constraint/name YANG schema element.
type TapiCommon_Context_PathComputationContext_PathCompService_OptimizationConstraint_Name struct {
Value *string `path:"value" module:"tapi-path-computation"`
ValueName *string `path:"value-name" module:"tapi-path-computation"`
// IsYANGGoStruct ensures that TapiCommon_Context_PathComputationContext_PathCompService_OptimizationConstraint_Name implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_PathComputationContext_PathCompService_OptimizationConstraint_Name) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_PathComputationContext_PathCompService_OptimizationConstraint_Name struct, which is a YANG list entry.
func (t *TapiCommon_Context_PathComputationContext_PathCompService_OptimizationConstraint_Name) ΛListKeyMap() (map[string]interface{}, error) {
if t.ValueName == nil {
return nil, fmt.Errorf("nil value for key ValueName")
}
return map[string]interface{}{
"value-name": *t.ValueName,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_PathComputationContext_PathCompService_OptimizationConstraint_Name) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_PathComputationContext_PathCompService_OptimizationConstraint_Name"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_PathComputationContext_PathCompService_OptimizationConstraint_Name) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_PathComputationContext_PathCompService_Path represents the /tapi-common/context/path-computation-context/path-comp-service/path YANG schema element.
type TapiCommon_Context_PathComputationContext_PathCompService_Path struct {
PathUuid *string `path:"path-uuid" module:"tapi-path-computation"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_PathComputationContext_PathCompService_Path implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_PathComputationContext_PathCompService_Path) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_PathComputationContext_PathCompService_Path struct, which is a YANG list entry.
func (t *TapiCommon_Context_PathComputationContext_PathCompService_Path) ΛListKeyMap() (map[string]interface{}, error) {
if t.PathUuid == nil {
return nil, fmt.Errorf("nil value for key PathUuid")
}
return map[string]interface{}{
"path-uuid": *t.PathUuid,
}, nil
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_PathComputationContext_PathCompService_Path) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_PathComputationContext_PathCompService_Path"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_PathComputationContext_PathCompService_Path) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint represents the /tapi-common/context/path-computation-context/path-comp-service/routing-constraint YANG schema element.
type TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint struct {
CostCharacteristic map[string]*TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint_CostCharacteristic `path:"cost-characteristic" module:"tapi-path-computation"`
DiversityPolicy E_TapiPathComputation_DiversityPolicy `path:"diversity-policy" module:"tapi-path-computation"`
IsExclusive *bool `path:"is-exclusive" module:"tapi-path-computation"`
LatencyCharacteristic map[string]*TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint_LatencyCharacteristic `path:"latency-characteristic" module:"tapi-path-computation"`
MaxAllowedCost *TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint_MaxAllowedCost `path:"max-allowed-cost" module:"tapi-path-computation"`
MaxAllowedDelay *TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint_MaxAllowedDelay `path:"max-allowed-delay" module:"tapi-path-computation"`
MaxAllowedHops *TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint_MaxAllowedHops `path:"max-allowed-hops" module:"tapi-path-computation"`
RiskDiversityCharacteristic map[string]*TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint_RiskDiversityCharacteristic `path:"risk-diversity-characteristic" module:"tapi-path-computation"`
RouteObjectiveFunction E_TapiPathComputation_RouteObjectiveFunction `path:"route-objective-function" module:"tapi-path-computation"`
TolerableImpact E_TapiPathComputation_GradesOfImpact `path:"tolerable-impact" module:"tapi-path-computation"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint) IsYANGGoStruct() {}
// NewCostCharacteristic creates a new entry in the CostCharacteristic list of the
// TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint struct. The keys of the list are populated from the input
// arguments.
func (t *TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint) NewCostCharacteristic(CostName string) (*TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint_CostCharacteristic, error){
4974
4975
4976
4977
4978
4979
4980
4981
4982
4983
4984
4985
4986
4987
4988
4989
4990
4991
4992
4993
4994
4995
4996
4997
4998
4999
5000
5001
5002
5003
5004
5005
5006
5007
5008
5009
5010
5011
5012
5013
5014
5015
5016
5017
5018
5019
5020
5021
5022
5023
5024
5025
5026
5027
5028
5029
5030
5031
5032
5033
5034
5035
5036
5037
5038
5039
5040
5041
5042
5043
5044
5045
5046
5047
5048
5049
5050
5051
5052
5053
5054
5055
5056
5057
5058
5059
5060
5061
5062
5063
5064
5065
5066
5067
5068
5069
5070
5071
5072
5073
5074
5075
5076
5077
5078
5079
5080
5081
5082
5083
5084
5085
5086
5087
5088
5089
5090
5091
5092
5093
5094
5095
5096
5097
5098
5099
5100
5101
5102
5103
5104
5105
5106
5107
5108
5109
5110
5111
5112
5113
5114
5115
5116
5117
5118
5119
5120
5121
5122
5123
5124
5125
5126
5127
5128
5129
5130
5131
5132
5133
5134
5135
5136
5137
5138
5139
5140
5141
5142
5143
5144
5145
5146
5147
5148
5149
5150
5151
5152
5153
5154
5155
5156
5157
5158
5159
5160
5161
5162
5163
5164
5165
5166
5167
5168
5169
5170
5171
5172
5173
5174
5175
5176
5177
5178
5179
5180
5181
5182
5183
5184
5185
5186
5187
5188
5189
5190
5191
5192
5193
5194
5195
5196
5197
5198
5199
5200
5201
5202
5203
5204
5205
5206
5207
5208
5209
5210
5211
5212
5213
5214
5215
5216
5217
5218
5219
5220
5221
5222
5223
5224
5225
5226
5227
5228
5229
5230
5231
5232
5233
5234
5235
5236
5237
5238
5239
5240
5241
5242
5243
5244
5245
5246
5247
5248
5249
5250
5251
5252
5253
5254
5255
5256
5257
5258
5259
5260
5261
5262
5263
5264
5265
5266
5267
5268
5269
5270
5271
5272
5273
5274
5275
5276
5277
5278
5279
5280
5281
5282
5283
5284
5285
5286
5287
5288
5289
5290
5291
5292
5293
5294
5295
5296
5297
5298
5299
5300
5301
5302
5303
5304
5305
5306
5307
5308
5309
5310
5311
5312
5313
5314
5315
5316
5317
5318
5319
5320
5321
5322
5323
5324
5325
5326
5327
5328
5329
5330
5331
5332
5333
5334
5335
5336
5337
5338
5339
5340
5341
5342
5343
5344
5345
5346
5347
5348
5349
5350
5351
5352
5353
5354
5355
5356
5357
5358
5359
5360
5361
5362
5363
5364
5365
5366
5367
5368
5369
5370
5371
5372
5373
5374
5375
5376
5377
5378
5379
5380
5381
5382
5383
5384
5385
5386
5387
5388
5389
5390
5391
5392
5393
5394
5395
5396
5397
5398
5399
5400
5401
5402
5403
5404
5405
5406
5407
5408
5409
5410
5411
5412
5413
5414
5415
5416
5417
5418
5419
5420
5421
5422
5423
5424
5425
5426
5427
5428
5429
5430
5431
5432
5433
5434
5435
5436
5437
5438
5439
5440
5441
5442
5443
5444
5445
5446
5447
5448
5449
5450
5451
5452
5453
5454
5455
5456
5457
5458
5459
5460
5461
5462
5463
5464
5465
5466
5467
5468
5469
5470
5471
5472
5473
5474
5475
5476
5477
5478
5479
5480
5481
5482
5483
5484
5485
5486
5487
5488
5489
5490
5491
5492
5493
5494
5495
5496
5497
5498
5499
5500
5501
5502
5503
5504
5505
5506
5507
5508
5509
5510
5511
5512
5513
5514
5515
5516
5517
5518
5519
5520
5521
5522
5523
5524
5525
5526
5527
5528
5529
5530
5531
5532
5533
5534
5535
5536
5537
5538
5539
5540
5541
5542
5543
5544
5545
5546
5547
5548
5549
5550
5551
5552
5553
5554
5555
5556
5557
5558
5559
5560
5561
5562
5563
5564
5565
5566
5567
5568
5569
5570
5571
5572
5573
5574
5575
5576
5577
5578
5579
5580
5581
5582
5583
5584
5585
5586
5587
5588
5589
5590
5591
5592
5593
5594
5595
5596
5597
5598
5599
5600
5601
5602
5603
5604
5605
5606
5607
5608
5609
5610
5611
5612
5613
5614
5615
5616
5617
5618
5619
5620
5621
5622
5623
5624
5625
5626
5627
5628
5629
5630
5631
5632
5633
5634
5635
5636
5637
5638
5639
5640
5641
5642
5643
5644
5645
5646
5647
5648
5649
5650
5651
5652
5653
5654
5655
5656
5657
5658
5659
5660
5661
5662
5663
5664
5665
5666
5667
5668
5669
5670
5671
5672
5673
5674
5675
5676
5677
5678
5679
5680
5681
5682
5683
5684
5685
5686
5687
5688
5689
5690
5691
5692
5693
5694
5695
5696
5697
5698
5699
5700
5701
5702
5703
5704
5705
5706
5707
5708
5709
5710
5711
5712
5713
5714
5715
5716
5717
5718
5719
5720
5721
5722
5723
5724
5725
5726
5727
5728
// Initialise the list within the receiver struct if it has not already been
// created.
if t.CostCharacteristic == nil {
t.CostCharacteristic = make(map[string]*TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint_CostCharacteristic)
}
key := CostName
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.CostCharacteristic[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list CostCharacteristic", key)
}
t.CostCharacteristic[key] = &TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint_CostCharacteristic{
CostName: &CostName,
}
return t.CostCharacteristic[key], nil
}
// NewLatencyCharacteristic creates a new entry in the LatencyCharacteristic list of the
// TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint struct. The keys of the list are populated from the input
// arguments.
func (t *TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint) NewLatencyCharacteristic(TrafficPropertyName string) (*TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint_LatencyCharacteristic, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.LatencyCharacteristic == nil {
t.LatencyCharacteristic = make(map[string]*TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint_LatencyCharacteristic)
}
key := TrafficPropertyName
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.LatencyCharacteristic[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list LatencyCharacteristic", key)
}
t.LatencyCharacteristic[key] = &TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint_LatencyCharacteristic{
TrafficPropertyName: &TrafficPropertyName,
}
return t.LatencyCharacteristic[key], nil
}
// NewRiskDiversityCharacteristic creates a new entry in the RiskDiversityCharacteristic list of the
// TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint struct. The keys of the list are populated from the input
// arguments.
func (t *TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint) NewRiskDiversityCharacteristic(RiskCharacteristicName string) (*TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint_RiskDiversityCharacteristic, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.RiskDiversityCharacteristic == nil {
t.RiskDiversityCharacteristic = make(map[string]*TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint_RiskDiversityCharacteristic)
}
key := RiskCharacteristicName
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.RiskDiversityCharacteristic[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list RiskDiversityCharacteristic", key)
}
t.RiskDiversityCharacteristic[key] = &TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint_RiskDiversityCharacteristic{
RiskCharacteristicName: &RiskCharacteristicName,
}
return t.RiskDiversityCharacteristic[key], nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint_CostCharacteristic represents the /tapi-common/context/path-computation-context/path-comp-service/routing-constraint/cost-characteristic YANG schema element.
type TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint_CostCharacteristic struct {
CostAlgorithm *string `path:"cost-algorithm" module:"tapi-path-computation"`
CostName *string `path:"cost-name" module:"tapi-path-computation"`
CostValue *string `path:"cost-value" module:"tapi-path-computation"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint_CostCharacteristic implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint_CostCharacteristic) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint_CostCharacteristic struct, which is a YANG list entry.
func (t *TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint_CostCharacteristic) ΛListKeyMap() (map[string]interface{}, error) {
if t.CostName == nil {
return nil, fmt.Errorf("nil value for key CostName")
}
return map[string]interface{}{
"cost-name": *t.CostName,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint_CostCharacteristic) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint_CostCharacteristic"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint_CostCharacteristic) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint_LatencyCharacteristic represents the /tapi-common/context/path-computation-context/path-comp-service/routing-constraint/latency-characteristic YANG schema element.
type TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint_LatencyCharacteristic struct {
FixedLatencyCharacteristic *string `path:"fixed-latency-characteristic" module:"tapi-path-computation"`
JitterCharacteristic *string `path:"jitter-characteristic" module:"tapi-path-computation"`
QueingLatencyCharacteristic *string `path:"queing-latency-characteristic" module:"tapi-path-computation"`
TrafficPropertyName *string `path:"traffic-property-name" module:"tapi-path-computation"`
WanderCharacteristic *string `path:"wander-characteristic" module:"tapi-path-computation"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint_LatencyCharacteristic implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint_LatencyCharacteristic) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint_LatencyCharacteristic struct, which is a YANG list entry.
func (t *TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint_LatencyCharacteristic) ΛListKeyMap() (map[string]interface{}, error) {
if t.TrafficPropertyName == nil {
return nil, fmt.Errorf("nil value for key TrafficPropertyName")
}
return map[string]interface{}{
"traffic-property-name": *t.TrafficPropertyName,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint_LatencyCharacteristic) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint_LatencyCharacteristic"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint_LatencyCharacteristic) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint_MaxAllowedCost represents the /tapi-common/context/path-computation-context/path-comp-service/routing-constraint/max-allowed-cost YANG schema element.
type TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint_MaxAllowedCost struct {
Priority *uint64 `path:"priority" module:"tapi-path-computation"`
Value *uint64 `path:"value" module:"tapi-path-computation"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint_MaxAllowedCost implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint_MaxAllowedCost) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint_MaxAllowedCost) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint_MaxAllowedCost"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint_MaxAllowedCost) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint_MaxAllowedDelay represents the /tapi-common/context/path-computation-context/path-comp-service/routing-constraint/max-allowed-delay YANG schema element.
type TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint_MaxAllowedDelay struct {
Priority *uint64 `path:"priority" module:"tapi-path-computation"`
Value *uint64 `path:"value" module:"tapi-path-computation"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint_MaxAllowedDelay implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint_MaxAllowedDelay) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint_MaxAllowedDelay) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint_MaxAllowedDelay"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint_MaxAllowedDelay) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint_MaxAllowedHops represents the /tapi-common/context/path-computation-context/path-comp-service/routing-constraint/max-allowed-hops YANG schema element.
type TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint_MaxAllowedHops struct {
Priority *uint64 `path:"priority" module:"tapi-path-computation"`
Value *uint64 `path:"value" module:"tapi-path-computation"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint_MaxAllowedHops implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint_MaxAllowedHops) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint_MaxAllowedHops) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint_MaxAllowedHops"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint_MaxAllowedHops) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint_RiskDiversityCharacteristic represents the /tapi-common/context/path-computation-context/path-comp-service/routing-constraint/risk-diversity-characteristic YANG schema element.
type TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint_RiskDiversityCharacteristic struct {
RiskCharacteristicName *string `path:"risk-characteristic-name" module:"tapi-path-computation"`
RiskIdentifierList []string `path:"risk-identifier-list" module:"tapi-path-computation"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint_RiskDiversityCharacteristic implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint_RiskDiversityCharacteristic) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint_RiskDiversityCharacteristic struct, which is a YANG list entry.
func (t *TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint_RiskDiversityCharacteristic) ΛListKeyMap() (map[string]interface{}, error) {
if t.RiskCharacteristicName == nil {
return nil, fmt.Errorf("nil value for key RiskCharacteristicName")
}
return map[string]interface{}{
"risk-characteristic-name": *t.RiskCharacteristicName,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint_RiskDiversityCharacteristic) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint_RiskDiversityCharacteristic"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_PathComputationContext_PathCompService_RoutingConstraint_RiskDiversityCharacteristic) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_PathComputationContext_PathCompService_TopologyConstraint represents the /tapi-common/context/path-computation-context/path-comp-service/topology-constraint YANG schema element.
type TapiCommon_Context_PathComputationContext_PathCompService_TopologyConstraint struct {
AvoidTopology *string `path:"avoid-topology" module:"tapi-path-computation"`
ConstraintWeight *uint64 `path:"constraint-weight" module:"tapi-path-computation"`
ExcludeLink *string `path:"exclude-link" module:"tapi-path-computation"`
ExcludeNode *string `path:"exclude-node" module:"tapi-path-computation"`
ExcludeNodeEdgePoint *string `path:"exclude-node-edge-point" module:"tapi-path-computation"`
ExcludePath *string `path:"exclude-path" module:"tapi-path-computation"`
IncludeLink *string `path:"include-link" module:"tapi-path-computation"`
IncludeNode *string `path:"include-node" module:"tapi-path-computation"`
IncludeNodeEdgePoint *string `path:"include-node-edge-point" module:"tapi-path-computation"`
IncludePath *string `path:"include-path" module:"tapi-path-computation"`
IncludeTopology *string `path:"include-topology" module:"tapi-path-computation"`
LocalId *string `path:"local-id" module:"tapi-path-computation"`
Name map[string]*TapiCommon_Context_PathComputationContext_PathCompService_TopologyConstraint_Name `path:"name" module:"tapi-path-computation"`
PreferredTransportLayer E_TapiPathComputation_LayerProtocolName `path:"preferred-transport-layer" module:"tapi-path-computation"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_PathComputationContext_PathCompService_TopologyConstraint implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_PathComputationContext_PathCompService_TopologyConstraint) IsYANGGoStruct() {}
// NewName creates a new entry in the Name list of the
// TapiCommon_Context_PathComputationContext_PathCompService_TopologyConstraint struct. The keys of the list are populated from the input
// arguments.
func (t *TapiCommon_Context_PathComputationContext_PathCompService_TopologyConstraint) NewName(ValueName string) (*TapiCommon_Context_PathComputationContext_PathCompService_TopologyConstraint_Name, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.Name == nil {
t.Name = make(map[string]*TapiCommon_Context_PathComputationContext_PathCompService_TopologyConstraint_Name)
}
key := ValueName
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.Name[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list Name", key)
}
t.Name[key] = &TapiCommon_Context_PathComputationContext_PathCompService_TopologyConstraint_Name{
ValueName: &ValueName,
}
return t.Name[key], nil
}
// ΛListKeyMap returns the keys of the TapiCommon_Context_PathComputationContext_PathCompService_TopologyConstraint struct, which is a YANG list entry.
func (t *TapiCommon_Context_PathComputationContext_PathCompService_TopologyConstraint) ΛListKeyMap() (map[string]interface{}, error) {
if t.LocalId == nil {
return nil, fmt.Errorf("nil value for key LocalId")
}
return map[string]interface{}{
"local-id": *t.LocalId,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_PathComputationContext_PathCompService_TopologyConstraint) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_PathComputationContext_PathCompService_TopologyConstraint"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_PathComputationContext_PathCompService_TopologyConstraint) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_PathComputationContext_PathCompService_TopologyConstraint_Name represents the /tapi-common/context/path-computation-context/path-comp-service/topology-constraint/name YANG schema element.
type TapiCommon_Context_PathComputationContext_PathCompService_TopologyConstraint_Name struct {
Value *string `path:"value" module:"tapi-path-computation"`
ValueName *string `path:"value-name" module:"tapi-path-computation"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_PathComputationContext_PathCompService_TopologyConstraint_Name implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_PathComputationContext_PathCompService_TopologyConstraint_Name) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_PathComputationContext_PathCompService_TopologyConstraint_Name struct, which is a YANG list entry.
func (t *TapiCommon_Context_PathComputationContext_PathCompService_TopologyConstraint_Name) ΛListKeyMap() (map[string]interface{}, error) {
if t.ValueName == nil {
return nil, fmt.Errorf("nil value for key ValueName")
}
return map[string]interface{}{
"value-name": *t.ValueName,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_PathComputationContext_PathCompService_TopologyConstraint_Name) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_PathComputationContext_PathCompService_TopologyConstraint_Name"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_PathComputationContext_PathCompService_TopologyConstraint_Name) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_PathComputationContext_Path_Link represents the /tapi-common/context/path-computation-context/path/link YANG schema element.
type TapiCommon_Context_PathComputationContext_Path_Link struct {
LinkUuid *string `path:"link-uuid" module:"tapi-path-computation"`
TopologyUuid *string `path:"topology-uuid" module:"tapi-path-computation"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_PathComputationContext_Path_Link implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_PathComputationContext_Path_Link) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_PathComputationContext_Path_Link struct, which is a YANG list entry.
func (t *TapiCommon_Context_PathComputationContext_Path_Link) ΛListKeyMap() (map[string]interface{}, error) {
if t.LinkUuid == nil {
return nil, fmt.Errorf("nil value for key LinkUuid")
}
if t.TopologyUuid == nil {
return nil, fmt.Errorf("nil value for key TopologyUuid")
}
return map[string]interface{}{
"link-uuid": *t.LinkUuid,
"topology-uuid": *t.TopologyUuid,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_PathComputationContext_Path_Link) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_PathComputationContext_Path_Link"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_PathComputationContext_Path_Link) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_PathComputationContext_Path_Name represents the /tapi-common/context/path-computation-context/path/name YANG schema element.
type TapiCommon_Context_PathComputationContext_Path_Name struct {
Value *string `path:"value" module:"tapi-path-computation"`
ValueName *string `path:"value-name" module:"tapi-path-computation"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_PathComputationContext_Path_Name implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_PathComputationContext_Path_Name) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_PathComputationContext_Path_Name struct, which is a YANG list entry.
func (t *TapiCommon_Context_PathComputationContext_Path_Name) ΛListKeyMap() (map[string]interface{}, error) {
if t.ValueName == nil {
return nil, fmt.Errorf("nil value for key ValueName")
}
return map[string]interface{}{
"value-name": *t.ValueName,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_PathComputationContext_Path_Name) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_PathComputationContext_Path_Name"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_PathComputationContext_Path_Name) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_PathComputationContext_Path_RoutingConstraint represents the /tapi-common/context/path-computation-context/path/routing-constraint YANG schema element.
type TapiCommon_Context_PathComputationContext_Path_RoutingConstraint struct {
CostCharacteristic map[string]*TapiCommon_Context_PathComputationContext_Path_RoutingConstraint_CostCharacteristic `path:"cost-characteristic" module:"tapi-path-computation"`
DiversityPolicy E_TapiPathComputation_DiversityPolicy `path:"diversity-policy" module:"tapi-path-computation"`
IsExclusive *bool `path:"is-exclusive" module:"tapi-path-computation"`
LatencyCharacteristic map[string]*TapiCommon_Context_PathComputationContext_Path_RoutingConstraint_LatencyCharacteristic `path:"latency-characteristic" module:"tapi-path-computation"`
MaxAllowedCost *TapiCommon_Context_PathComputationContext_Path_RoutingConstraint_MaxAllowedCost `path:"max-allowed-cost" module:"tapi-path-computation"`
MaxAllowedDelay *TapiCommon_Context_PathComputationContext_Path_RoutingConstraint_MaxAllowedDelay `path:"max-allowed-delay" module:"tapi-path-computation"`
MaxAllowedHops *TapiCommon_Context_PathComputationContext_Path_RoutingConstraint_MaxAllowedHops `path:"max-allowed-hops" module:"tapi-path-computation"`
RiskDiversityCharacteristic map[string]*TapiCommon_Context_PathComputationContext_Path_RoutingConstraint_RiskDiversityCharacteristic `path:"risk-diversity-characteristic" module:"tapi-path-computation"`
RouteObjectiveFunction E_TapiPathComputation_RouteObjectiveFunction `path:"route-objective-function" module:"tapi-path-computation"`
TolerableImpact E_TapiPathComputation_GradesOfImpact `path:"tolerable-impact" module:"tapi-path-computation"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_PathComputationContext_Path_RoutingConstraint implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_PathComputationContext_Path_RoutingConstraint) IsYANGGoStruct() {}
// NewCostCharacteristic creates a new entry in the CostCharacteristic list of the
// TapiCommon_Context_PathComputationContext_Path_RoutingConstraint struct. The keys of the list are populated from the input
// arguments.
func (t *TapiCommon_Context_PathComputationContext_Path_RoutingConstraint) NewCostCharacteristic(CostName string) (*TapiCommon_Context_PathComputationContext_Path_RoutingConstraint_CostCharacteristic, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.CostCharacteristic == nil {
t.CostCharacteristic = make(map[string]*TapiCommon_Context_PathComputationContext_Path_RoutingConstraint_CostCharacteristic)
}
key := CostName
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.CostCharacteristic[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list CostCharacteristic", key)
}
t.CostCharacteristic[key] = &TapiCommon_Context_PathComputationContext_Path_RoutingConstraint_CostCharacteristic{
CostName: &CostName,
}
return t.CostCharacteristic[key], nil
}
// NewLatencyCharacteristic creates a new entry in the LatencyCharacteristic list of the
// TapiCommon_Context_PathComputationContext_Path_RoutingConstraint struct. The keys of the list are populated from the input
// arguments.
func (t *TapiCommon_Context_PathComputationContext_Path_RoutingConstraint) NewLatencyCharacteristic(TrafficPropertyName string) (*TapiCommon_Context_PathComputationContext_Path_RoutingConstraint_LatencyCharacteristic, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.LatencyCharacteristic == nil {
t.LatencyCharacteristic = make(map[string]*TapiCommon_Context_PathComputationContext_Path_RoutingConstraint_LatencyCharacteristic)
}
key := TrafficPropertyName
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.LatencyCharacteristic[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list LatencyCharacteristic", key)
}
t.LatencyCharacteristic[key] = &TapiCommon_Context_PathComputationContext_Path_RoutingConstraint_LatencyCharacteristic{
TrafficPropertyName: &TrafficPropertyName,
}
return t.LatencyCharacteristic[key], nil
}
// NewRiskDiversityCharacteristic creates a new entry in the RiskDiversityCharacteristic list of the
// TapiCommon_Context_PathComputationContext_Path_RoutingConstraint struct. The keys of the list are populated from the input
// arguments.
func (t *TapiCommon_Context_PathComputationContext_Path_RoutingConstraint) NewRiskDiversityCharacteristic(RiskCharacteristicName string) (*TapiCommon_Context_PathComputationContext_Path_RoutingConstraint_RiskDiversityCharacteristic, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.RiskDiversityCharacteristic == nil {
t.RiskDiversityCharacteristic = make(map[string]*TapiCommon_Context_PathComputationContext_Path_RoutingConstraint_RiskDiversityCharacteristic)
}
key := RiskCharacteristicName
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.RiskDiversityCharacteristic[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list RiskDiversityCharacteristic", key)
}
t.RiskDiversityCharacteristic[key] = &TapiCommon_Context_PathComputationContext_Path_RoutingConstraint_RiskDiversityCharacteristic{
RiskCharacteristicName: &RiskCharacteristicName,
}
return t.RiskDiversityCharacteristic[key], nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_PathComputationContext_Path_RoutingConstraint) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_PathComputationContext_Path_RoutingConstraint"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_PathComputationContext_Path_RoutingConstraint) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_PathComputationContext_Path_RoutingConstraint_CostCharacteristic represents the /tapi-common/context/path-computation-context/path/routing-constraint/cost-characteristic YANG schema element.
type TapiCommon_Context_PathComputationContext_Path_RoutingConstraint_CostCharacteristic struct {
CostAlgorithm *string `path:"cost-algorithm" module:"tapi-path-computation"`
CostName *string `path:"cost-name" module:"tapi-path-computation"`
CostValue *string `path:"cost-value" module:"tapi-path-computation"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_PathComputationContext_Path_RoutingConstraint_CostCharacteristic implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_PathComputationContext_Path_RoutingConstraint_CostCharacteristic) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_PathComputationContext_Path_RoutingConstraint_CostCharacteristic struct, which is a YANG list entry.
func (t *TapiCommon_Context_PathComputationContext_Path_RoutingConstraint_CostCharacteristic) ΛListKeyMap() (map[string]interface{}, error) {
if t.CostName == nil {
return nil, fmt.Errorf("nil value for key CostName")
}
return map[string]interface{}{
"cost-name": *t.CostName,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_PathComputationContext_Path_RoutingConstraint_CostCharacteristic) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_PathComputationContext_Path_RoutingConstraint_CostCharacteristic"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_PathComputationContext_Path_RoutingConstraint_CostCharacteristic) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_PathComputationContext_Path_RoutingConstraint_LatencyCharacteristic represents the /tapi-common/context/path-computation-context/path/routing-constraint/latency-characteristic YANG schema element.
type TapiCommon_Context_PathComputationContext_Path_RoutingConstraint_LatencyCharacteristic struct {
FixedLatencyCharacteristic *string `path:"fixed-latency-characteristic" module:"tapi-path-computation"`
JitterCharacteristic *string `path:"jitter-characteristic" module:"tapi-path-computation"`
QueingLatencyCharacteristic *string `path:"queing-latency-characteristic" module:"tapi-path-computation"`
TrafficPropertyName *string `path:"traffic-property-name" module:"tapi-path-computation"`
WanderCharacteristic *string `path:"wander-characteristic" module:"tapi-path-computation"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_PathComputationContext_Path_RoutingConstraint_LatencyCharacteristic implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_PathComputationContext_Path_RoutingConstraint_LatencyCharacteristic) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_PathComputationContext_Path_RoutingConstraint_LatencyCharacteristic struct, which is a YANG list entry.
func (t *TapiCommon_Context_PathComputationContext_Path_RoutingConstraint_LatencyCharacteristic) ΛListKeyMap() (map[string]interface{}, error) {
if t.TrafficPropertyName == nil {
return nil, fmt.Errorf("nil value for key TrafficPropertyName")
}
return map[string]interface{}{
"traffic-property-name": *t.TrafficPropertyName,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_PathComputationContext_Path_RoutingConstraint_LatencyCharacteristic) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_PathComputationContext_Path_RoutingConstraint_LatencyCharacteristic"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_PathComputationContext_Path_RoutingConstraint_LatencyCharacteristic) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_PathComputationContext_Path_RoutingConstraint_MaxAllowedCost represents the /tapi-common/context/path-computation-context/path/routing-constraint/max-allowed-cost YANG schema element.
type TapiCommon_Context_PathComputationContext_Path_RoutingConstraint_MaxAllowedCost struct {
Priority *uint64 `path:"priority" module:"tapi-path-computation"`
Value *uint64 `path:"value" module:"tapi-path-computation"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_PathComputationContext_Path_RoutingConstraint_MaxAllowedCost implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_PathComputationContext_Path_RoutingConstraint_MaxAllowedCost) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_PathComputationContext_Path_RoutingConstraint_MaxAllowedCost) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_PathComputationContext_Path_RoutingConstraint_MaxAllowedCost"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_PathComputationContext_Path_RoutingConstraint_MaxAllowedCost) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_PathComputationContext_Path_RoutingConstraint_MaxAllowedDelay represents the /tapi-common/context/path-computation-context/path/routing-constraint/max-allowed-delay YANG schema element.
type TapiCommon_Context_PathComputationContext_Path_RoutingConstraint_MaxAllowedDelay struct {
Priority *uint64 `path:"priority" module:"tapi-path-computation"`
Value *uint64 `path:"value" module:"tapi-path-computation"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_PathComputationContext_Path_RoutingConstraint_MaxAllowedDelay implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_PathComputationContext_Path_RoutingConstraint_MaxAllowedDelay) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_PathComputationContext_Path_RoutingConstraint_MaxAllowedDelay) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_PathComputationContext_Path_RoutingConstraint_MaxAllowedDelay"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_PathComputationContext_Path_RoutingConstraint_MaxAllowedDelay) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_PathComputationContext_Path_RoutingConstraint_MaxAllowedHops represents the /tapi-common/context/path-computation-context/path/routing-constraint/max-allowed-hops YANG schema element.
type TapiCommon_Context_PathComputationContext_Path_RoutingConstraint_MaxAllowedHops struct {
Priority *uint64 `path:"priority" module:"tapi-path-computation"`
Value *uint64 `path:"value" module:"tapi-path-computation"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_PathComputationContext_Path_RoutingConstraint_MaxAllowedHops implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_PathComputationContext_Path_RoutingConstraint_MaxAllowedHops) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_PathComputationContext_Path_RoutingConstraint_MaxAllowedHops) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_PathComputationContext_Path_RoutingConstraint_MaxAllowedHops"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_PathComputationContext_Path_RoutingConstraint_MaxAllowedHops) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_PathComputationContext_Path_RoutingConstraint_RiskDiversityCharacteristic represents the /tapi-common/context/path-computation-context/path/routing-constraint/risk-diversity-characteristic YANG schema element.
type TapiCommon_Context_PathComputationContext_Path_RoutingConstraint_RiskDiversityCharacteristic struct {
RiskCharacteristicName *string `path:"risk-characteristic-name" module:"tapi-path-computation"`
RiskIdentifierList []string `path:"risk-identifier-list" module:"tapi-path-computation"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_PathComputationContext_Path_RoutingConstraint_RiskDiversityCharacteristic implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_PathComputationContext_Path_RoutingConstraint_RiskDiversityCharacteristic) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_PathComputationContext_Path_RoutingConstraint_RiskDiversityCharacteristic struct, which is a YANG list entry.
func (t *TapiCommon_Context_PathComputationContext_Path_RoutingConstraint_RiskDiversityCharacteristic) ΛListKeyMap() (map[string]interface{}, error) {
if t.RiskCharacteristicName == nil {
return nil, fmt.Errorf("nil value for key RiskCharacteristicName")
}
return map[string]interface{}{
"risk-characteristic-name": *t.RiskCharacteristicName,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_PathComputationContext_Path_RoutingConstraint_RiskDiversityCharacteristic) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_PathComputationContext_Path_RoutingConstraint_RiskDiversityCharacteristic"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_PathComputationContext_Path_RoutingConstraint_RiskDiversityCharacteristic) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ServiceInterfacePoint represents the /tapi-common/context/service-interface-point YANG schema element.
type TapiCommon_Context_ServiceInterfacePoint struct {
AdministrativeState E_TapiCommon_AdministrativeState `path:"administrative-state" module:"tapi-common"`
AvailableCapacity *TapiCommon_Context_ServiceInterfacePoint_AvailableCapacity `path:"available-capacity" module:"tapi-common"`
Direction E_TapiCommon_PortDirection `path:"direction" module:"tapi-common"`
LayerProtocolName E_TapiCommon_LayerProtocolName `path:"layer-protocol-name" module:"tapi-common"`
LifecycleState E_TapiCommon_LifecycleState `path:"lifecycle-state" module:"tapi-common"`
MediaChannelServiceInterfacePointSpec *TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec `path:"media-channel-service-interface-point-spec" module:"tapi-photonic-media"`
Name map[string]*TapiCommon_Context_ServiceInterfacePoint_Name `path:"name" module:"tapi-common"`
OperationalState E_TapiCommon_OperationalState `path:"operational-state" module:"tapi-common"`
OtsiServiceInterfacePointSpec *TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec `path:"otsi-service-interface-point-spec" module:"tapi-photonic-media"`
5733
5734
5735
5736
5737
5738
5739
5740
5741
5742
5743
5744
5745
5746
5747
5748
5749
5750
5751
5752
5753
5754
5755
5756
5757
5758
5759
5760
5761
5762
5763
5764
5765
5766
5767
5768
5769
5770
5771
5772
5773
5774
5775
5776
5777
5778
5779
5780
5781
5782
5783
5784
5785
5786
5787
5788
5789
5790
5791
5792
5793
5794
5795
5796
5797
5798
5799
5800
5801
5802
5803
5804
5805
5806
5807
5808
5809
5810
5811
5812
5813
5814
5815
5816
5817
5818
5819
5820
5821
5822
5823
5824
5825
5826
5827
5828
5829
5830
5831
5832
5833
5834
5835
5836
5837
5838
5839
5840
SupportedLayerProtocolQualifier []E_TapiCommon_LayerProtocolQualifier `path:"supported-layer-protocol-qualifier" module:"tapi-common"`
TotalPotentialCapacity *TapiCommon_Context_ServiceInterfacePoint_TotalPotentialCapacity `path:"total-potential-capacity" module:"tapi-common"`
Uuid *string `path:"uuid" module:"tapi-common"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_ServiceInterfacePoint implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ServiceInterfacePoint) IsYANGGoStruct() {}
// NewName creates a new entry in the Name list of the
// TapiCommon_Context_ServiceInterfacePoint struct. The keys of the list are populated from the input
// arguments.
func (t *TapiCommon_Context_ServiceInterfacePoint) NewName(ValueName string) (*TapiCommon_Context_ServiceInterfacePoint_Name, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.Name == nil {
t.Name = make(map[string]*TapiCommon_Context_ServiceInterfacePoint_Name)
}
key := ValueName
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.Name[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list Name", key)
}
t.Name[key] = &TapiCommon_Context_ServiceInterfacePoint_Name{
ValueName: &ValueName,
}
return t.Name[key], nil
}
// ΛListKeyMap returns the keys of the TapiCommon_Context_ServiceInterfacePoint struct, which is a YANG list entry.
func (t *TapiCommon_Context_ServiceInterfacePoint) ΛListKeyMap() (map[string]interface{}, error) {
if t.Uuid == nil {
return nil, fmt.Errorf("nil value for key Uuid")
}
return map[string]interface{}{
"uuid": *t.Uuid,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ServiceInterfacePoint) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ServiceInterfacePoint"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ServiceInterfacePoint) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ServiceInterfacePoint_AvailableCapacity represents the /tapi-common/context/service-interface-point/available-capacity YANG schema element.
type TapiCommon_Context_ServiceInterfacePoint_AvailableCapacity struct {
TotalSize *TapiCommon_Context_ServiceInterfacePoint_AvailableCapacity_TotalSize `path:"total-size" module:"tapi-common"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_ServiceInterfacePoint_AvailableCapacity implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ServiceInterfacePoint_AvailableCapacity) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ServiceInterfacePoint_AvailableCapacity) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ServiceInterfacePoint_AvailableCapacity"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ServiceInterfacePoint_AvailableCapacity) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ServiceInterfacePoint_AvailableCapacity_TotalSize represents the /tapi-common/context/service-interface-point/available-capacity/total-size YANG schema element.
type TapiCommon_Context_ServiceInterfacePoint_AvailableCapacity_TotalSize struct {
Unit E_TapiCommon_CapacityUnit `path:"unit" module:"tapi-common"`
Value *uint64 `path:"value" module:"tapi-common"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_ServiceInterfacePoint_AvailableCapacity_TotalSize implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ServiceInterfacePoint_AvailableCapacity_TotalSize) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ServiceInterfacePoint_AvailableCapacity_TotalSize) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ServiceInterfacePoint_AvailableCapacity_TotalSize"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ServiceInterfacePoint_AvailableCapacity_TotalSize) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec represents the /tapi-common/context/service-interface-point/media-channel-service-interface-point-spec YANG schema element.
type TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec struct {
McPool *TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool `path:"mc-pool" module:"tapi-photonic-media"`
PowerManagementCapability *TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_PowerManagementCapability `path:"power-management-capability" module:"tapi-photonic-media"`
// IsYANGGoStruct ensures that TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool represents the /tapi-common/context/service-interface-point/media-channel-service-interface-point-spec/mc-pool YANG schema element.
type TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool struct {
AvailableSpectrum map[TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_AvailableSpectrum_Key]*TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_AvailableSpectrum `path:"available-spectrum" module:"tapi-photonic-media"`
OccupiedSpectrum map[TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_OccupiedSpectrum_Key]*TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_OccupiedSpectrum `path:"occupied-spectrum" module:"tapi-photonic-media"`
SupportableSpectrum map[TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_SupportableSpectrum_Key]*TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_SupportableSpectrum `path:"supportable-spectrum" module:"tapi-photonic-media"`
// IsYANGGoStruct ensures that TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool) IsYANGGoStruct() {}
// TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_AvailableSpectrum_Key represents the key for list AvailableSpectrum of element /tapi-common/context/service-interface-point/media-channel-service-interface-point-spec/mc-pool.
type TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_AvailableSpectrum_Key struct {
UpperFrequency uint64 `path:"upper-frequency"`
LowerFrequency uint64 `path:"lower-frequency"`
// TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_OccupiedSpectrum_Key represents the key for list OccupiedSpectrum of element /tapi-common/context/service-interface-point/media-channel-service-interface-point-spec/mc-pool.
type TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_OccupiedSpectrum_Key struct {
UpperFrequency uint64 `path:"upper-frequency"`
LowerFrequency uint64 `path:"lower-frequency"`
// TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_SupportableSpectrum_Key represents the key for list SupportableSpectrum of element /tapi-common/context/service-interface-point/media-channel-service-interface-point-spec/mc-pool.
type TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_SupportableSpectrum_Key struct {
UpperFrequency uint64 `path:"upper-frequency"`
LowerFrequency uint64 `path:"lower-frequency"`
// NewAvailableSpectrum creates a new entry in the AvailableSpectrum list of the
// TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool struct. The keys of the list are populated from the input
func (t *TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool) NewAvailableSpectrum(UpperFrequency uint64, LowerFrequency uint64) (*TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_AvailableSpectrum, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.AvailableSpectrum == nil {
t.AvailableSpectrum = make(map[TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_AvailableSpectrum_Key]*TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_AvailableSpectrum)
key := TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_AvailableSpectrum_Key{
UpperFrequency: UpperFrequency,
LowerFrequency: LowerFrequency,
}
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.AvailableSpectrum[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list AvailableSpectrum", key)
t.AvailableSpectrum[key] = &TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_AvailableSpectrum{
UpperFrequency: &UpperFrequency,
LowerFrequency: &LowerFrequency,
// NewOccupiedSpectrum creates a new entry in the OccupiedSpectrum list of the
// TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool struct. The keys of the list are populated from the input
func (t *TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool) NewOccupiedSpectrum(UpperFrequency uint64, LowerFrequency uint64) (*TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_OccupiedSpectrum, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.OccupiedSpectrum == nil {
t.OccupiedSpectrum = make(map[TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_OccupiedSpectrum_Key]*TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_OccupiedSpectrum)
key := TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_OccupiedSpectrum_Key{
UpperFrequency: UpperFrequency,
LowerFrequency: LowerFrequency,
}
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.OccupiedSpectrum[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list OccupiedSpectrum", key)
t.OccupiedSpectrum[key] = &TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_OccupiedSpectrum{
UpperFrequency: &UpperFrequency,
LowerFrequency: &LowerFrequency,
// NewSupportableSpectrum creates a new entry in the SupportableSpectrum list of the
// TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool struct. The keys of the list are populated from the input
func (t *TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool) NewSupportableSpectrum(UpperFrequency uint64, LowerFrequency uint64) (*TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_SupportableSpectrum, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.SupportableSpectrum == nil {
t.SupportableSpectrum = make(map[TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_SupportableSpectrum_Key]*TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_SupportableSpectrum)
key := TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_SupportableSpectrum_Key{
UpperFrequency: UpperFrequency,
LowerFrequency: LowerFrequency,
}
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.SupportableSpectrum[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list SupportableSpectrum", key)
t.SupportableSpectrum[key] = &TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_SupportableSpectrum{
UpperFrequency: &UpperFrequency,
LowerFrequency: &LowerFrequency,
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_AvailableSpectrum represents the /tapi-common/context/service-interface-point/media-channel-service-interface-point-spec/mc-pool/available-spectrum YANG schema element.
type TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_AvailableSpectrum struct {
FrequencyConstraint *TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_AvailableSpectrum_FrequencyConstraint `path:"frequency-constraint" module:"tapi-photonic-media"`
LowerFrequency *uint64 `path:"lower-frequency" module:"tapi-photonic-media"`
UpperFrequency *uint64 `path:"upper-frequency" module:"tapi-photonic-media"`
// IsYANGGoStruct ensures that TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_AvailableSpectrum implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_AvailableSpectrum) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_AvailableSpectrum struct, which is a YANG list entry.
func (t *TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_AvailableSpectrum) ΛListKeyMap() (map[string]interface{}, error) {
if t.LowerFrequency == nil {
return nil, fmt.Errorf("nil value for key LowerFrequency")
}
if t.UpperFrequency == nil {
return nil, fmt.Errorf("nil value for key UpperFrequency")
}
return map[string]interface{}{
"lower-frequency": *t.LowerFrequency,
"upper-frequency": *t.UpperFrequency,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_AvailableSpectrum) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_AvailableSpectrum"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_AvailableSpectrum) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_AvailableSpectrum_FrequencyConstraint represents the /tapi-common/context/service-interface-point/media-channel-service-interface-point-spec/mc-pool/available-spectrum/frequency-constraint YANG schema element.
type TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_AvailableSpectrum_FrequencyConstraint struct {
AdjustmentGranularity E_TapiPhotonicMedia_AdjustmentGranularity `path:"adjustment-granularity" module:"tapi-photonic-media"`
GridType E_TapiPhotonicMedia_GridType `path:"grid-type" module:"tapi-photonic-media"`
// IsYANGGoStruct ensures that TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_AvailableSpectrum_FrequencyConstraint implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_AvailableSpectrum_FrequencyConstraint) IsYANGGoStruct() {}
6053
6054
6055
6056
6057
6058
6059
6060
6061
6062
6063
6064
6065
6066
6067
6068
6069
6070
6071
6072
6073
6074
6075
6076
6077
6078
6079
6080
6081
6082
6083
6084
6085
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_AvailableSpectrum_FrequencyConstraint) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_AvailableSpectrum_FrequencyConstraint"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_AvailableSpectrum_FrequencyConstraint) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_OccupiedSpectrum represents the /tapi-common/context/service-interface-point/media-channel-service-interface-point-spec/mc-pool/occupied-spectrum YANG schema element.
type TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_OccupiedSpectrum struct {
FrequencyConstraint *TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_OccupiedSpectrum_FrequencyConstraint `path:"frequency-constraint" module:"tapi-photonic-media"`
LowerFrequency *uint64 `path:"lower-frequency" module:"tapi-photonic-media"`
UpperFrequency *uint64 `path:"upper-frequency" module:"tapi-photonic-media"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_OccupiedSpectrum implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_OccupiedSpectrum) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_OccupiedSpectrum struct, which is a YANG list entry.
func (t *TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_OccupiedSpectrum) ΛListKeyMap() (map[string]interface{}, error) {
if t.LowerFrequency == nil {
return nil, fmt.Errorf("nil value for key LowerFrequency")
}
if t.UpperFrequency == nil {
return nil, fmt.Errorf("nil value for key UpperFrequency")
}
return map[string]interface{}{
"lower-frequency": *t.LowerFrequency,
"upper-frequency": *t.UpperFrequency,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_OccupiedSpectrum) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_OccupiedSpectrum"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_OccupiedSpectrum) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_OccupiedSpectrum_FrequencyConstraint represents the /tapi-common/context/service-interface-point/media-channel-service-interface-point-spec/mc-pool/occupied-spectrum/frequency-constraint YANG schema element.
type TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_OccupiedSpectrum_FrequencyConstraint struct {
AdjustmentGranularity E_TapiPhotonicMedia_AdjustmentGranularity `path:"adjustment-granularity" module:"tapi-photonic-media"`
GridType E_TapiPhotonicMedia_GridType `path:"grid-type" module:"tapi-photonic-media"`
// IsYANGGoStruct ensures that TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_OccupiedSpectrum_FrequencyConstraint implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_OccupiedSpectrum_FrequencyConstraint) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_OccupiedSpectrum_FrequencyConstraint) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_OccupiedSpectrum_FrequencyConstraint"], t, opts...); err != nil {
return err
}
return nil
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_OccupiedSpectrum_FrequencyConstraint) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_SupportableSpectrum represents the /tapi-common/context/service-interface-point/media-channel-service-interface-point-spec/mc-pool/supportable-spectrum YANG schema element.
type TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_SupportableSpectrum struct {
FrequencyConstraint *TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_SupportableSpectrum_FrequencyConstraint `path:"frequency-constraint" module:"tapi-photonic-media"`
LowerFrequency *uint64 `path:"lower-frequency" module:"tapi-photonic-media"`
UpperFrequency *uint64 `path:"upper-frequency" module:"tapi-photonic-media"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_SupportableSpectrum implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_SupportableSpectrum) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_SupportableSpectrum struct, which is a YANG list entry.
func (t *TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_SupportableSpectrum) ΛListKeyMap() (map[string]interface{}, error) {
if t.LowerFrequency == nil {
return nil, fmt.Errorf("nil value for key LowerFrequency")
if t.UpperFrequency == nil {
return nil, fmt.Errorf("nil value for key UpperFrequency")
return map[string]interface{}{
"lower-frequency": *t.LowerFrequency,
"upper-frequency": *t.UpperFrequency,
}, nil
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_SupportableSpectrum) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_SupportableSpectrum"], t, opts...); err != nil {
return err
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_SupportableSpectrum) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_SupportableSpectrum_FrequencyConstraint represents the /tapi-common/context/service-interface-point/media-channel-service-interface-point-spec/mc-pool/supportable-spectrum/frequency-constraint YANG schema element.
type TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_SupportableSpectrum_FrequencyConstraint struct {
AdjustmentGranularity E_TapiPhotonicMedia_AdjustmentGranularity `path:"adjustment-granularity" module:"tapi-photonic-media"`
GridType E_TapiPhotonicMedia_GridType `path:"grid-type" module:"tapi-photonic-media"`
// IsYANGGoStruct ensures that TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_SupportableSpectrum_FrequencyConstraint implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_SupportableSpectrum_FrequencyConstraint) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_SupportableSpectrum_FrequencyConstraint) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_SupportableSpectrum_FrequencyConstraint"], t, opts...); err != nil {
return err
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_McPool_SupportableSpectrum_FrequencyConstraint) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_PowerManagementCapability represents the /tapi-common/context/service-interface-point/media-channel-service-interface-point-spec/power-management-capability YANG schema element.
type TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_PowerManagementCapability struct {
SupportableMaximumOutputPower *TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_PowerManagementCapability_SupportableMaximumOutputPower `path:"supportable-maximum-output-power" module:"tapi-photonic-media"`
SupportableMinimumOutputPower *TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_PowerManagementCapability_SupportableMinimumOutputPower `path:"supportable-minimum-output-power" module:"tapi-photonic-media"`
TolerableMaximumInputPower *TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_PowerManagementCapability_TolerableMaximumInputPower `path:"tolerable-maximum-input-power" module:"tapi-photonic-media"`
TolerableMinimumInputPower *TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_PowerManagementCapability_TolerableMinimumInputPower `path:"tolerable-minimum-input-power" module:"tapi-photonic-media"`
// IsYANGGoStruct ensures that TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_PowerManagementCapability implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_PowerManagementCapability) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_PowerManagementCapability) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_PowerManagementCapability"], t, opts...); err != nil {
return err
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_PowerManagementCapability) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_PowerManagementCapability_SupportableMaximumOutputPower represents the /tapi-common/context/service-interface-point/media-channel-service-interface-point-spec/power-management-capability/supportable-maximum-output-power YANG schema element.
type TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_PowerManagementCapability_SupportableMaximumOutputPower struct {
PowerSpectralDensity *float64 `path:"power-spectral-density" module:"tapi-photonic-media"`
TotalPower *float64 `path:"total-power" module:"tapi-photonic-media"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_PowerManagementCapability_SupportableMaximumOutputPower implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_PowerManagementCapability_SupportableMaximumOutputPower) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_PowerManagementCapability_SupportableMaximumOutputPower) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_PowerManagementCapability_SupportableMaximumOutputPower"], t, opts...); err != nil {
return err
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_PowerManagementCapability_SupportableMaximumOutputPower) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_PowerManagementCapability_SupportableMinimumOutputPower represents the /tapi-common/context/service-interface-point/media-channel-service-interface-point-spec/power-management-capability/supportable-minimum-output-power YANG schema element.
type TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_PowerManagementCapability_SupportableMinimumOutputPower struct {
PowerSpectralDensity *float64 `path:"power-spectral-density" module:"tapi-photonic-media"`
TotalPower *float64 `path:"total-power" module:"tapi-photonic-media"`
// IsYANGGoStruct ensures that TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_PowerManagementCapability_SupportableMinimumOutputPower implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_PowerManagementCapability_SupportableMinimumOutputPower) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_PowerManagementCapability_SupportableMinimumOutputPower) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_PowerManagementCapability_SupportableMinimumOutputPower"], t, opts...); err != nil {
return err
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_PowerManagementCapability_SupportableMinimumOutputPower) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_PowerManagementCapability_TolerableMaximumInputPower represents the /tapi-common/context/service-interface-point/media-channel-service-interface-point-spec/power-management-capability/tolerable-maximum-input-power YANG schema element.
type TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_PowerManagementCapability_TolerableMaximumInputPower struct {
PowerSpectralDensity *float64 `path:"power-spectral-density" module:"tapi-photonic-media"`
TotalPower *float64 `path:"total-power" module:"tapi-photonic-media"`
// IsYANGGoStruct ensures that TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_PowerManagementCapability_TolerableMaximumInputPower implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_PowerManagementCapability_TolerableMaximumInputPower) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_PowerManagementCapability_TolerableMaximumInputPower) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_PowerManagementCapability_TolerableMaximumInputPower"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_PowerManagementCapability_TolerableMaximumInputPower) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_PowerManagementCapability_TolerableMinimumInputPower represents the /tapi-common/context/service-interface-point/media-channel-service-interface-point-spec/power-management-capability/tolerable-minimum-input-power YANG schema element.
type TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_PowerManagementCapability_TolerableMinimumInputPower struct {
PowerSpectralDensity *float64 `path:"power-spectral-density" module:"tapi-photonic-media"`
TotalPower *float64 `path:"total-power" module:"tapi-photonic-media"`
// IsYANGGoStruct ensures that TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_PowerManagementCapability_TolerableMinimumInputPower implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_PowerManagementCapability_TolerableMinimumInputPower) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_PowerManagementCapability_TolerableMinimumInputPower) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_PowerManagementCapability_TolerableMinimumInputPower"], t, opts...); err != nil {
return err
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ServiceInterfacePoint_MediaChannelServiceInterfacePointSpec_PowerManagementCapability_TolerableMinimumInputPower) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ServiceInterfacePoint_Name represents the /tapi-common/context/service-interface-point/name YANG schema element.
type TapiCommon_Context_ServiceInterfacePoint_Name struct {
Value *string `path:"value" module:"tapi-common"`
ValueName *string `path:"value-name" module:"tapi-common"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_ServiceInterfacePoint_Name implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ServiceInterfacePoint_Name) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_ServiceInterfacePoint_Name struct, which is a YANG list entry.
func (t *TapiCommon_Context_ServiceInterfacePoint_Name) ΛListKeyMap() (map[string]interface{}, error) {
if t.ValueName == nil {
return nil, fmt.Errorf("nil value for key ValueName")
}
return map[string]interface{}{
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ServiceInterfacePoint_Name) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ServiceInterfacePoint_Name"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ServiceInterfacePoint_Name) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec represents the /tapi-common/context/service-interface-point/otsi-service-interface-point-spec YANG schema element.
type TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec struct {
OtsiCapability *TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_OtsiCapability `path:"otsi-capability" module:"tapi-photonic-media"`
PowerManagementCapability *TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_PowerManagementCapability `path:"power-management-capability" module:"tapi-photonic-media"`
// IsYANGGoStruct ensures that TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec"], t, opts...); err != nil {
return err
}
return nil
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_OtsiCapability represents the /tapi-common/context/service-interface-point/otsi-service-interface-point-spec/otsi-capability YANG schema element.
type TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_OtsiCapability struct {
SupportableApplicationIdentifier map[string]*TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_OtsiCapability_SupportableApplicationIdentifier `path:"supportable-application-identifier" module:"tapi-photonic-media"`
SupportableCentralFrequencySpectrumBand map[TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_OtsiCapability_SupportableCentralFrequencySpectrumBand_Key]*TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_OtsiCapability_SupportableCentralFrequencySpectrumBand `path:"supportable-central-frequency-spectrum-band" module:"tapi-photonic-media"`
SupportableModulation []E_TapiPhotonicMedia_ModulationTechnique `path:"supportable-modulation" module:"tapi-photonic-media"`
TotalPowerWarnThreshold *TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_OtsiCapability_TotalPowerWarnThreshold `path:"total-power-warn-threshold" module:"tapi-photonic-media"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_OtsiCapability implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_OtsiCapability) IsYANGGoStruct() {}
// TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_OtsiCapability_SupportableCentralFrequencySpectrumBand_Key represents the key for list SupportableCentralFrequencySpectrumBand of element /tapi-common/context/service-interface-point/otsi-service-interface-point-spec/otsi-capability.
type TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_OtsiCapability_SupportableCentralFrequencySpectrumBand_Key struct {
LowerCentralFrequency uint64 `path:"lower-central-frequency"`
UpperCentralFrequency uint64 `path:"upper-central-frequency"`
// NewSupportableApplicationIdentifier creates a new entry in the SupportableApplicationIdentifier list of the
// TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_OtsiCapability struct. The keys of the list are populated from the input
func (t *TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_OtsiCapability) NewSupportableApplicationIdentifier(ApplicationCode string) (*TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_OtsiCapability_SupportableApplicationIdentifier, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.SupportableApplicationIdentifier == nil {
t.SupportableApplicationIdentifier = make(map[string]*TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_OtsiCapability_SupportableApplicationIdentifier)
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.SupportableApplicationIdentifier[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list SupportableApplicationIdentifier", key)
t.SupportableApplicationIdentifier[key] = &TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_OtsiCapability_SupportableApplicationIdentifier{
ApplicationCode: &ApplicationCode,
return t.SupportableApplicationIdentifier[key], nil
// NewSupportableCentralFrequencySpectrumBand creates a new entry in the SupportableCentralFrequencySpectrumBand list of the
// TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_OtsiCapability struct. The keys of the list are populated from the input
func (t *TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_OtsiCapability) NewSupportableCentralFrequencySpectrumBand(LowerCentralFrequency uint64, UpperCentralFrequency uint64) (*TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_OtsiCapability_SupportableCentralFrequencySpectrumBand, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.SupportableCentralFrequencySpectrumBand == nil {
t.SupportableCentralFrequencySpectrumBand = make(map[TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_OtsiCapability_SupportableCentralFrequencySpectrumBand_Key]*TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_OtsiCapability_SupportableCentralFrequencySpectrumBand)
key := TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_OtsiCapability_SupportableCentralFrequencySpectrumBand_Key{
LowerCentralFrequency: LowerCentralFrequency,
UpperCentralFrequency: UpperCentralFrequency,
}
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.SupportableCentralFrequencySpectrumBand[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list SupportableCentralFrequencySpectrumBand", key)
t.SupportableCentralFrequencySpectrumBand[key] = &TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_OtsiCapability_SupportableCentralFrequencySpectrumBand{
LowerCentralFrequency: &LowerCentralFrequency,
UpperCentralFrequency: &UpperCentralFrequency,
return t.SupportableCentralFrequencySpectrumBand[key], nil
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_OtsiCapability) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_OtsiCapability"], t, opts...); err != nil {
return err
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_OtsiCapability) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_OtsiCapability_SupportableApplicationIdentifier represents the /tapi-common/context/service-interface-point/otsi-service-interface-point-spec/otsi-capability/supportable-application-identifier YANG schema element.
type TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_OtsiCapability_SupportableApplicationIdentifier struct {
ApplicationCode *string `path:"application-code" module:"tapi-photonic-media"`
ApplicationIdentifierType E_TapiPhotonicMedia_ApplicationIdentifierType `path:"application-identifier-type" module:"tapi-photonic-media"`
// IsYANGGoStruct ensures that TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_OtsiCapability_SupportableApplicationIdentifier implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_OtsiCapability_SupportableApplicationIdentifier) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_OtsiCapability_SupportableApplicationIdentifier struct, which is a YANG list entry.
func (t *TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_OtsiCapability_SupportableApplicationIdentifier) ΛListKeyMap() (map[string]interface{}, error) {
if t.ApplicationCode == nil {
return nil, fmt.Errorf("nil value for key ApplicationCode")
}
return map[string]interface{}{
"application-code": *t.ApplicationCode,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_OtsiCapability_SupportableApplicationIdentifier) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_OtsiCapability_SupportableApplicationIdentifier"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_OtsiCapability_SupportableApplicationIdentifier) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_OtsiCapability_SupportableCentralFrequencySpectrumBand represents the /tapi-common/context/service-interface-point/otsi-service-interface-point-spec/otsi-capability/supportable-central-frequency-spectrum-band YANG schema element.
type TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_OtsiCapability_SupportableCentralFrequencySpectrumBand struct {
FrequencyConstraint *TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_OtsiCapability_SupportableCentralFrequencySpectrumBand_FrequencyConstraint `path:"frequency-constraint" module:"tapi-photonic-media"`
LowerCentralFrequency *uint64 `path:"lower-central-frequency" module:"tapi-photonic-media"`
UpperCentralFrequency *uint64 `path:"upper-central-frequency" module:"tapi-photonic-media"`
// IsYANGGoStruct ensures that TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_OtsiCapability_SupportableCentralFrequencySpectrumBand implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_OtsiCapability_SupportableCentralFrequencySpectrumBand) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_OtsiCapability_SupportableCentralFrequencySpectrumBand struct, which is a YANG list entry.
func (t *TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_OtsiCapability_SupportableCentralFrequencySpectrumBand) ΛListKeyMap() (map[string]interface{}, error) {
if t.LowerCentralFrequency == nil {
return nil, fmt.Errorf("nil value for key LowerCentralFrequency")
}
if t.UpperCentralFrequency == nil {
return nil, fmt.Errorf("nil value for key UpperCentralFrequency")
}
return map[string]interface{}{
"lower-central-frequency": *t.LowerCentralFrequency,
"upper-central-frequency": *t.UpperCentralFrequency,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_OtsiCapability_SupportableCentralFrequencySpectrumBand) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_OtsiCapability_SupportableCentralFrequencySpectrumBand"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_OtsiCapability_SupportableCentralFrequencySpectrumBand) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_OtsiCapability_SupportableCentralFrequencySpectrumBand_FrequencyConstraint represents the /tapi-common/context/service-interface-point/otsi-service-interface-point-spec/otsi-capability/supportable-central-frequency-spectrum-band/frequency-constraint YANG schema element.
type TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_OtsiCapability_SupportableCentralFrequencySpectrumBand_FrequencyConstraint struct {
AdjustmentGranularity E_TapiPhotonicMedia_AdjustmentGranularity `path:"adjustment-granularity" module:"tapi-photonic-media"`
GridType E_TapiPhotonicMedia_GridType `path:"grid-type" module:"tapi-photonic-media"`
// IsYANGGoStruct ensures that TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_OtsiCapability_SupportableCentralFrequencySpectrumBand_FrequencyConstraint implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_OtsiCapability_SupportableCentralFrequencySpectrumBand_FrequencyConstraint) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_OtsiCapability_SupportableCentralFrequencySpectrumBand_FrequencyConstraint) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_OtsiCapability_SupportableCentralFrequencySpectrumBand_FrequencyConstraint"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_OtsiCapability_SupportableCentralFrequencySpectrumBand_FrequencyConstraint) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_OtsiCapability_TotalPowerWarnThreshold represents the /tapi-common/context/service-interface-point/otsi-service-interface-point-spec/otsi-capability/total-power-warn-threshold YANG schema element.
type TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_OtsiCapability_TotalPowerWarnThreshold struct {
TotalPowerLowerWarnThresholdDefault *float64 `path:"total-power-lower-warn-threshold-default" module:"tapi-photonic-media"`
TotalPowerLowerWarnThresholdMax *float64 `path:"total-power-lower-warn-threshold-max" module:"tapi-photonic-media"`
TotalPowerLowerWarnThresholdMin *float64 `path:"total-power-lower-warn-threshold-min" module:"tapi-photonic-media"`
TotalPowerUpperWarnThresholdDefault *float64 `path:"total-power-upper-warn-threshold-default" module:"tapi-photonic-media"`
TotalPowerUpperWarnThresholdMax *float64 `path:"total-power-upper-warn-threshold-max" module:"tapi-photonic-media"`
TotalPowerUpperWarnThresholdMin *float64 `path:"total-power-upper-warn-threshold-min" module:"tapi-photonic-media"`
// IsYANGGoStruct ensures that TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_OtsiCapability_TotalPowerWarnThreshold implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_OtsiCapability_TotalPowerWarnThreshold) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_OtsiCapability_TotalPowerWarnThreshold) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_OtsiCapability_TotalPowerWarnThreshold"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_OtsiCapability_TotalPowerWarnThreshold) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_PowerManagementCapability represents the /tapi-common/context/service-interface-point/otsi-service-interface-point-spec/power-management-capability YANG schema element.
type TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_PowerManagementCapability struct {
SupportableMaximumOutputPower *TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_PowerManagementCapability_SupportableMaximumOutputPower `path:"supportable-maximum-output-power" module:"tapi-photonic-media"`
SupportableMinimumOutputPower *TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_PowerManagementCapability_SupportableMinimumOutputPower `path:"supportable-minimum-output-power" module:"tapi-photonic-media"`
TolerableMaximumInputPower *TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_PowerManagementCapability_TolerableMaximumInputPower `path:"tolerable-maximum-input-power" module:"tapi-photonic-media"`
TolerableMinimumInputPower *TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_PowerManagementCapability_TolerableMinimumInputPower `path:"tolerable-minimum-input-power" module:"tapi-photonic-media"`
// IsYANGGoStruct ensures that TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_PowerManagementCapability implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_PowerManagementCapability) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_PowerManagementCapability) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_PowerManagementCapability"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_PowerManagementCapability) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_PowerManagementCapability_SupportableMaximumOutputPower represents the /tapi-common/context/service-interface-point/otsi-service-interface-point-spec/power-management-capability/supportable-maximum-output-power YANG schema element.
type TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_PowerManagementCapability_SupportableMaximumOutputPower struct {
PowerSpectralDensity *float64 `path:"power-spectral-density" module:"tapi-photonic-media"`
TotalPower *float64 `path:"total-power" module:"tapi-photonic-media"`
// IsYANGGoStruct ensures that TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_PowerManagementCapability_SupportableMaximumOutputPower implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_PowerManagementCapability_SupportableMaximumOutputPower) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_PowerManagementCapability_SupportableMaximumOutputPower) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_PowerManagementCapability_SupportableMaximumOutputPower"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_PowerManagementCapability_SupportableMaximumOutputPower) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_PowerManagementCapability_SupportableMinimumOutputPower represents the /tapi-common/context/service-interface-point/otsi-service-interface-point-spec/power-management-capability/supportable-minimum-output-power YANG schema element.
type TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_PowerManagementCapability_SupportableMinimumOutputPower struct {
PowerSpectralDensity *float64 `path:"power-spectral-density" module:"tapi-photonic-media"`
TotalPower *float64 `path:"total-power" module:"tapi-photonic-media"`
// IsYANGGoStruct ensures that TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_PowerManagementCapability_SupportableMinimumOutputPower implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_PowerManagementCapability_SupportableMinimumOutputPower) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_PowerManagementCapability_SupportableMinimumOutputPower) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_PowerManagementCapability_SupportableMinimumOutputPower"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_PowerManagementCapability_SupportableMinimumOutputPower) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_PowerManagementCapability_TolerableMaximumInputPower represents the /tapi-common/context/service-interface-point/otsi-service-interface-point-spec/power-management-capability/tolerable-maximum-input-power YANG schema element.
type TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_PowerManagementCapability_TolerableMaximumInputPower struct {
PowerSpectralDensity *float64 `path:"power-spectral-density" module:"tapi-photonic-media"`
TotalPower *float64 `path:"total-power" module:"tapi-photonic-media"`
// IsYANGGoStruct ensures that TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_PowerManagementCapability_TolerableMaximumInputPower implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_PowerManagementCapability_TolerableMaximumInputPower) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_PowerManagementCapability_TolerableMaximumInputPower) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_PowerManagementCapability_TolerableMaximumInputPower"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_PowerManagementCapability_TolerableMaximumInputPower) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_PowerManagementCapability_TolerableMinimumInputPower represents the /tapi-common/context/service-interface-point/otsi-service-interface-point-spec/power-management-capability/tolerable-minimum-input-power YANG schema element.
type TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_PowerManagementCapability_TolerableMinimumInputPower struct {
PowerSpectralDensity *float64 `path:"power-spectral-density" module:"tapi-photonic-media"`
TotalPower *float64 `path:"total-power" module:"tapi-photonic-media"`
// IsYANGGoStruct ensures that TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_PowerManagementCapability_TolerableMinimumInputPower implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_PowerManagementCapability_TolerableMinimumInputPower) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_PowerManagementCapability_TolerableMinimumInputPower) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_PowerManagementCapability_TolerableMinimumInputPower"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ServiceInterfacePoint_OtsiServiceInterfacePointSpec_PowerManagementCapability_TolerableMinimumInputPower) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ServiceInterfacePoint_TotalPotentialCapacity represents the /tapi-common/context/service-interface-point/total-potential-capacity YANG schema element.
type TapiCommon_Context_ServiceInterfacePoint_TotalPotentialCapacity struct {
TotalSize *TapiCommon_Context_ServiceInterfacePoint_TotalPotentialCapacity_TotalSize `path:"total-size" module:"tapi-common"`
// IsYANGGoStruct ensures that TapiCommon_Context_ServiceInterfacePoint_TotalPotentialCapacity implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ServiceInterfacePoint_TotalPotentialCapacity) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ServiceInterfacePoint_TotalPotentialCapacity) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ServiceInterfacePoint_TotalPotentialCapacity"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ServiceInterfacePoint_TotalPotentialCapacity) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_ServiceInterfacePoint_TotalPotentialCapacity_TotalSize represents the /tapi-common/context/service-interface-point/total-potential-capacity/total-size YANG schema element.
type TapiCommon_Context_ServiceInterfacePoint_TotalPotentialCapacity_TotalSize struct {
Unit E_TapiCommon_CapacityUnit `path:"unit" module:"tapi-common"`
Value *uint64 `path:"value" module:"tapi-common"`
// IsYANGGoStruct ensures that TapiCommon_Context_ServiceInterfacePoint_TotalPotentialCapacity_TotalSize implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_ServiceInterfacePoint_TotalPotentialCapacity_TotalSize) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_ServiceInterfacePoint_TotalPotentialCapacity_TotalSize) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_ServiceInterfacePoint_TotalPotentialCapacity_TotalSize"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_ServiceInterfacePoint_TotalPotentialCapacity_TotalSize) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext represents the /tapi-common/context/topology-context YANG schema element.
type TapiCommon_Context_TopologyContext struct {
NwTopologyService *TapiCommon_Context_TopologyContext_NwTopologyService `path:"nw-topology-service" module:"tapi-topology"`
Topology map[string]*TapiCommon_Context_TopologyContext_Topology `path:"topology" module:"tapi-topology"`
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext) IsYANGGoStruct() {}
// NewTopology creates a new entry in the Topology list of the
// TapiCommon_Context_TopologyContext struct. The keys of the list are populated from the input
// arguments.
func (t *TapiCommon_Context_TopologyContext) NewTopology(Uuid string) (*TapiCommon_Context_TopologyContext_Topology, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.Topology == nil {
t.Topology = make(map[string]*TapiCommon_Context_TopologyContext_Topology)
key := Uuid
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.Topology[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list Topology", key)
}
t.Topology[key] = &TapiCommon_Context_TopologyContext_Topology{
Uuid: &Uuid,
}
return t.Topology[key], nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
6815
6816
6817
6818
6819
6820
6821
6822
6823
6824
6825
6826
6827
6828
6829
6830
6831
6832
6833
6834
6835
6836
6837
6838
6839
6840
6841
6842
6843
6844
6845
6846
6847
6848
6849
6850
6851
6852
6853
6854
6855
6856
6857
6858
6859
6860
6861
6862
6863
6864
6865
6866
6867
6868
6869
6870
6871
6872
6873
6874
6875
6876
6877
6878
6879
6880
6881
6882
6883
6884
6885
6886
6887
6888
6889
6890
6891
6892
6893
6894
6895
// TapiCommon_Context_TopologyContext_NwTopologyService represents the /tapi-common/context/topology-context/nw-topology-service YANG schema element.
type TapiCommon_Context_TopologyContext_NwTopologyService struct {
Name map[string]*TapiCommon_Context_TopologyContext_NwTopologyService_Name `path:"name" module:"tapi-topology"`
Topology map[string]*TapiCommon_Context_TopologyContext_NwTopologyService_Topology `path:"topology" module:"tapi-topology"`
Uuid *string `path:"uuid" module:"tapi-topology"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_NwTopologyService implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_NwTopologyService) IsYANGGoStruct() {}
// NewName creates a new entry in the Name list of the
// TapiCommon_Context_TopologyContext_NwTopologyService struct. The keys of the list are populated from the input
// arguments.
func (t *TapiCommon_Context_TopologyContext_NwTopologyService) NewName(ValueName string) (*TapiCommon_Context_TopologyContext_NwTopologyService_Name, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.Name == nil {
t.Name = make(map[string]*TapiCommon_Context_TopologyContext_NwTopologyService_Name)
}
key := ValueName
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.Name[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list Name", key)
}
t.Name[key] = &TapiCommon_Context_TopologyContext_NwTopologyService_Name{
ValueName: &ValueName,
}
return t.Name[key], nil
}
// NewTopology creates a new entry in the Topology list of the
// TapiCommon_Context_TopologyContext_NwTopologyService struct. The keys of the list are populated from the input
// arguments.
func (t *TapiCommon_Context_TopologyContext_NwTopologyService) NewTopology(TopologyUuid string) (*TapiCommon_Context_TopologyContext_NwTopologyService_Topology, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.Topology == nil {
t.Topology = make(map[string]*TapiCommon_Context_TopologyContext_NwTopologyService_Topology)
}
key := TopologyUuid
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.Topology[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list Topology", key)
}
t.Topology[key] = &TapiCommon_Context_TopologyContext_NwTopologyService_Topology{
TopologyUuid: &TopologyUuid,
}
return t.Topology[key], nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_NwTopologyService) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_NwTopologyService"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_NwTopologyService) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext_NwTopologyService_Name represents the /tapi-common/context/topology-context/nw-topology-service/name YANG schema element.
type TapiCommon_Context_TopologyContext_NwTopologyService_Name struct {
Value *string `path:"value" module:"tapi-topology"`
ValueName *string `path:"value-name" module:"tapi-topology"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_NwTopologyService_Name implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_NwTopologyService_Name) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_TopologyContext_NwTopologyService_Name struct, which is a YANG list entry.
func (t *TapiCommon_Context_TopologyContext_NwTopologyService_Name) ΛListKeyMap() (map[string]interface{}, error) {
if t.ValueName == nil {
return nil, fmt.Errorf("nil value for key ValueName")
}
return map[string]interface{}{
"value-name": *t.ValueName,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_NwTopologyService_Name) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_NwTopologyService_Name"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_NwTopologyService_Name) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
6929
6930
6931
6932
6933
6934
6935
6936
6937
6938
6939
6940
6941
6942
6943
6944
6945
6946
6947
6948
6949
6950
6951
6952
6953
6954
6955
6956
6957
6958
6959
6960
6961
6962
6963
6964
6965
// TapiCommon_Context_TopologyContext_NwTopologyService_Topology represents the /tapi-common/context/topology-context/nw-topology-service/topology YANG schema element.
type TapiCommon_Context_TopologyContext_NwTopologyService_Topology struct {
TopologyUuid *string `path:"topology-uuid" module:"tapi-topology"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_NwTopologyService_Topology implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_NwTopologyService_Topology) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_TopologyContext_NwTopologyService_Topology struct, which is a YANG list entry.
func (t *TapiCommon_Context_TopologyContext_NwTopologyService_Topology) ΛListKeyMap() (map[string]interface{}, error) {
if t.TopologyUuid == nil {
return nil, fmt.Errorf("nil value for key TopologyUuid")
}
return map[string]interface{}{
"topology-uuid": *t.TopologyUuid,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_NwTopologyService_Topology) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_NwTopologyService_Topology"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_NwTopologyService_Topology) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext_Topology represents the /tapi-common/context/topology-context/topology YANG schema element.
type TapiCommon_Context_TopologyContext_Topology struct {
BoundaryNodeEdgePoint map[TapiCommon_Context_TopologyContext_Topology_BoundaryNodeEdgePoint_Key]*TapiCommon_Context_TopologyContext_Topology_BoundaryNodeEdgePoint `path:"boundary-node-edge-point" module:"tapi-topology"`
LayerProtocolName []E_TapiTopology_LayerProtocolName `path:"layer-protocol-name" module:"tapi-topology"`
Link map[string]*TapiCommon_Context_TopologyContext_Topology_Link `path:"link" module:"tapi-topology"`
Name map[string]*TapiCommon_Context_TopologyContext_Topology_Name `path:"name" module:"tapi-topology"`
Node map[string]*TapiCommon_Context_TopologyContext_Topology_Node `path:"node" module:"tapi-topology"`
Uuid *string `path:"uuid" module:"tapi-topology"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_Topology) IsYANGGoStruct() {}
// TapiCommon_Context_TopologyContext_Topology_BoundaryNodeEdgePoint_Key represents the key for list BoundaryNodeEdgePoint of element /tapi-common/context/topology-context/topology.
type TapiCommon_Context_TopologyContext_Topology_BoundaryNodeEdgePoint_Key struct {
TopologyUuid string `path:"topology-uuid"`
NodeUuid string `path:"node-uuid"`
NodeEdgePointUuid string `path:"node-edge-point-uuid"`
}
// NewBoundaryNodeEdgePoint creates a new entry in the BoundaryNodeEdgePoint list of the
// TapiCommon_Context_TopologyContext_Topology struct. The keys of the list are populated from the input
func (t *TapiCommon_Context_TopologyContext_Topology) NewBoundaryNodeEdgePoint(TopologyUuid string, NodeUuid string, NodeEdgePointUuid string) (*TapiCommon_Context_TopologyContext_Topology_BoundaryNodeEdgePoint, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.BoundaryNodeEdgePoint == nil {
t.BoundaryNodeEdgePoint = make(map[TapiCommon_Context_TopologyContext_Topology_BoundaryNodeEdgePoint_Key]*TapiCommon_Context_TopologyContext_Topology_BoundaryNodeEdgePoint)
key := TapiCommon_Context_TopologyContext_Topology_BoundaryNodeEdgePoint_Key{
TopologyUuid: TopologyUuid,
NodeUuid: NodeUuid,
NodeEdgePointUuid: NodeEdgePointUuid,
}
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.BoundaryNodeEdgePoint[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list BoundaryNodeEdgePoint", key)
t.BoundaryNodeEdgePoint[key] = &TapiCommon_Context_TopologyContext_Topology_BoundaryNodeEdgePoint{
TopologyUuid: &TopologyUuid,
NodeUuid: &NodeUuid,
NodeEdgePointUuid: &NodeEdgePointUuid,
}
return t.BoundaryNodeEdgePoint[key], nil
// NewLink creates a new entry in the Link list of the
// TapiCommon_Context_TopologyContext_Topology struct. The keys of the list are populated from the input
func (t *TapiCommon_Context_TopologyContext_Topology) NewLink(Uuid string) (*TapiCommon_Context_TopologyContext_Topology_Link, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.Link == nil {
t.Link = make(map[string]*TapiCommon_Context_TopologyContext_Topology_Link)
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.Link[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list Link", key)
t.Link[key] = &TapiCommon_Context_TopologyContext_Topology_Link{
Uuid: &Uuid,
// NewName creates a new entry in the Name list of the
// TapiCommon_Context_TopologyContext_Topology struct. The keys of the list are populated from the input
func (t *TapiCommon_Context_TopologyContext_Topology) NewName(ValueName string) (*TapiCommon_Context_TopologyContext_Topology_Name, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.Name == nil {
t.Name = make(map[string]*TapiCommon_Context_TopologyContext_Topology_Name)
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.Name[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list Name", key)
}
t.Name[key] = &TapiCommon_Context_TopologyContext_Topology_Name{
ValueName: &ValueName,
}
return t.Name[key], nil
}
// NewNode creates a new entry in the Node list of the
// TapiCommon_Context_TopologyContext_Topology struct. The keys of the list are populated from the input
func (t *TapiCommon_Context_TopologyContext_Topology) NewNode(Uuid string) (*TapiCommon_Context_TopologyContext_Topology_Node, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.Node == nil {
t.Node = make(map[string]*TapiCommon_Context_TopologyContext_Topology_Node)
}
key := Uuid
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.Node[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list Node", key)
t.Node[key] = &TapiCommon_Context_TopologyContext_Topology_Node{
// ΛListKeyMap returns the keys of the TapiCommon_Context_TopologyContext_Topology struct, which is a YANG list entry.
func (t *TapiCommon_Context_TopologyContext_Topology) ΛListKeyMap() (map[string]interface{}, error) {
if t.Uuid == nil {
return nil, fmt.Errorf("nil value for key Uuid")
}
return map[string]interface{}{
"uuid": *t.Uuid,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_Topology) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_Topology"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_Topology) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext_Topology_BoundaryNodeEdgePoint represents the /tapi-common/context/topology-context/topology/boundary-node-edge-point YANG schema element.
type TapiCommon_Context_TopologyContext_Topology_BoundaryNodeEdgePoint struct {
NodeEdgePointUuid *string `path:"node-edge-point-uuid" module:"tapi-topology"`
NodeUuid *string `path:"node-uuid" module:"tapi-topology"`
TopologyUuid *string `path:"topology-uuid" module:"tapi-topology"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology_BoundaryNodeEdgePoint implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_Topology_BoundaryNodeEdgePoint) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_TopologyContext_Topology_BoundaryNodeEdgePoint struct, which is a YANG list entry.
func (t *TapiCommon_Context_TopologyContext_Topology_BoundaryNodeEdgePoint) ΛListKeyMap() (map[string]interface{}, error) {
if t.NodeEdgePointUuid == nil {
return nil, fmt.Errorf("nil value for key NodeEdgePointUuid")
}
if t.NodeUuid == nil {
return nil, fmt.Errorf("nil value for key NodeUuid")
}
if t.TopologyUuid == nil {
return nil, fmt.Errorf("nil value for key TopologyUuid")
}
return map[string]interface{}{
"node-edge-point-uuid": *t.NodeEdgePointUuid,
"node-uuid": *t.NodeUuid,
"topology-uuid": *t.TopologyUuid,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_Topology_BoundaryNodeEdgePoint) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_Topology_BoundaryNodeEdgePoint"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_Topology_BoundaryNodeEdgePoint) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
7169
7170
7171
7172
7173
7174
7175
7176
7177
7178
7179
7180
7181
7182
7183
7184
7185
7186
7187
7188
7189
7190
7191
7192
// TapiCommon_Context_TopologyContext_Topology_Link represents the /tapi-common/context/topology-context/topology/link YANG schema element.
type TapiCommon_Context_TopologyContext_Topology_Link struct {
AdministrativeState E_TapiCommon_AdministrativeState `path:"administrative-state" module:"tapi-topology"`
AvailableCapacity *TapiCommon_Context_TopologyContext_Topology_Link_AvailableCapacity `path:"available-capacity" module:"tapi-topology"`
CostCharacteristic map[string]*TapiCommon_Context_TopologyContext_Topology_Link_CostCharacteristic `path:"cost-characteristic" module:"tapi-topology"`
DeliveryOrderCharacteristic *string `path:"delivery-order-characteristic" module:"tapi-topology"`
Direction E_TapiTopology_ForwardingDirection `path:"direction" module:"tapi-topology"`
ErrorCharacteristic *string `path:"error-characteristic" module:"tapi-topology"`
LatencyCharacteristic map[string]*TapiCommon_Context_TopologyContext_Topology_Link_LatencyCharacteristic `path:"latency-characteristic" module:"tapi-topology"`
LayerProtocolName []E_TapiTopology_LayerProtocolName `path:"layer-protocol-name" module:"tapi-topology"`
LifecycleState E_TapiCommon_LifecycleState `path:"lifecycle-state" module:"tapi-topology"`
LossCharacteristic *string `path:"loss-characteristic" module:"tapi-topology"`
Name map[string]*TapiCommon_Context_TopologyContext_Topology_Link_Name `path:"name" module:"tapi-topology"`
NodeEdgePoint map[TapiCommon_Context_TopologyContext_Topology_Link_NodeEdgePoint_Key]*TapiCommon_Context_TopologyContext_Topology_Link_NodeEdgePoint `path:"node-edge-point" module:"tapi-topology"`
OperationalState E_TapiCommon_OperationalState `path:"operational-state" module:"tapi-topology"`
RepeatDeliveryCharacteristic *string `path:"repeat-delivery-characteristic" module:"tapi-topology"`
ResilienceType *TapiCommon_Context_TopologyContext_Topology_Link_ResilienceType `path:"resilience-type" module:"tapi-topology"`
RiskCharacteristic map[string]*TapiCommon_Context_TopologyContext_Topology_Link_RiskCharacteristic `path:"risk-characteristic" module:"tapi-topology"`
ServerIntegrityProcessCharacteristic *string `path:"server-integrity-process-characteristic" module:"tapi-topology"`
TotalPotentialCapacity *TapiCommon_Context_TopologyContext_Topology_Link_TotalPotentialCapacity `path:"total-potential-capacity" module:"tapi-topology"`
TransitionedLayerProtocolName []string `path:"transitioned-layer-protocol-name" module:"tapi-topology"`
UnavailableTimeCharacteristic *string `path:"unavailable-time-characteristic" module:"tapi-topology"`
Uuid *string `path:"uuid" module:"tapi-topology"`
ValidationMechanism map[string]*TapiCommon_Context_TopologyContext_Topology_Link_ValidationMechanism `path:"validation-mechanism" module:"tapi-topology"`
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology_Link implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_Topology_Link) IsYANGGoStruct() {}
// TapiCommon_Context_TopologyContext_Topology_Link_NodeEdgePoint_Key represents the key for list NodeEdgePoint of element /tapi-common/context/topology-context/topology/link.
type TapiCommon_Context_TopologyContext_Topology_Link_NodeEdgePoint_Key struct {
TopologyUuid string `path:"topology-uuid"`
NodeUuid string `path:"node-uuid"`
NodeEdgePointUuid string `path:"node-edge-point-uuid"`
// NewCostCharacteristic creates a new entry in the CostCharacteristic list of the
// TapiCommon_Context_TopologyContext_Topology_Link struct. The keys of the list are populated from the input
// arguments.
func (t *TapiCommon_Context_TopologyContext_Topology_Link) NewCostCharacteristic(CostName string) (*TapiCommon_Context_TopologyContext_Topology_Link_CostCharacteristic, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.CostCharacteristic == nil {
t.CostCharacteristic = make(map[string]*TapiCommon_Context_TopologyContext_Topology_Link_CostCharacteristic)
}
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.CostCharacteristic[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list CostCharacteristic", key)
t.CostCharacteristic[key] = &TapiCommon_Context_TopologyContext_Topology_Link_CostCharacteristic{
CostName: &CostName,
}
// NewLatencyCharacteristic creates a new entry in the LatencyCharacteristic list of the
// TapiCommon_Context_TopologyContext_Topology_Link struct. The keys of the list are populated from the input
// arguments.
func (t *TapiCommon_Context_TopologyContext_Topology_Link) NewLatencyCharacteristic(TrafficPropertyName string) (*TapiCommon_Context_TopologyContext_Topology_Link_LatencyCharacteristic, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.LatencyCharacteristic == nil {
t.LatencyCharacteristic = make(map[string]*TapiCommon_Context_TopologyContext_Topology_Link_LatencyCharacteristic)
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.LatencyCharacteristic[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list LatencyCharacteristic", key)
t.LatencyCharacteristic[key] = &TapiCommon_Context_TopologyContext_Topology_Link_LatencyCharacteristic{
TrafficPropertyName: &TrafficPropertyName,
}
return t.LatencyCharacteristic[key], nil
// NewName creates a new entry in the Name list of the
// TapiCommon_Context_TopologyContext_Topology_Link struct. The keys of the list are populated from the input
// arguments.
func (t *TapiCommon_Context_TopologyContext_Topology_Link) NewName(ValueName string) (*TapiCommon_Context_TopologyContext_Topology_Link_Name, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.Name == nil {
t.Name = make(map[string]*TapiCommon_Context_TopologyContext_Topology_Link_Name)
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.Name[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list Name", key)
t.Name[key] = &TapiCommon_Context_TopologyContext_Topology_Link_Name{
ValueName: &ValueName,
// NewNodeEdgePoint creates a new entry in the NodeEdgePoint list of the
// TapiCommon_Context_TopologyContext_Topology_Link struct. The keys of the list are populated from the input
func (t *TapiCommon_Context_TopologyContext_Topology_Link) NewNodeEdgePoint(TopologyUuid string, NodeUuid string, NodeEdgePointUuid string) (*TapiCommon_Context_TopologyContext_Topology_Link_NodeEdgePoint, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.NodeEdgePoint == nil {
t.NodeEdgePoint = make(map[TapiCommon_Context_TopologyContext_Topology_Link_NodeEdgePoint_Key]*TapiCommon_Context_TopologyContext_Topology_Link_NodeEdgePoint)
key := TapiCommon_Context_TopologyContext_Topology_Link_NodeEdgePoint_Key{
TopologyUuid: TopologyUuid,
NodeUuid: NodeUuid,
}
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.NodeEdgePoint[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list NodeEdgePoint", key)
t.NodeEdgePoint[key] = &TapiCommon_Context_TopologyContext_Topology_Link_NodeEdgePoint{
TopologyUuid: &TopologyUuid,
NodeUuid: &NodeUuid,
// NewRiskCharacteristic creates a new entry in the RiskCharacteristic list of the
// TapiCommon_Context_TopologyContext_Topology_Link struct. The keys of the list are populated from the input
func (t *TapiCommon_Context_TopologyContext_Topology_Link) NewRiskCharacteristic(RiskCharacteristicName string) (*TapiCommon_Context_TopologyContext_Topology_Link_RiskCharacteristic, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.RiskCharacteristic == nil {
t.RiskCharacteristic = make(map[string]*TapiCommon_Context_TopologyContext_Topology_Link_RiskCharacteristic)
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.RiskCharacteristic[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list RiskCharacteristic", key)
t.RiskCharacteristic[key] = &TapiCommon_Context_TopologyContext_Topology_Link_RiskCharacteristic{
RiskCharacteristicName: &RiskCharacteristicName,
// NewValidationMechanism creates a new entry in the ValidationMechanism list of the
// TapiCommon_Context_TopologyContext_Topology_Link struct. The keys of the list are populated from the input
func (t *TapiCommon_Context_TopologyContext_Topology_Link) NewValidationMechanism(ValidationMechanism string) (*TapiCommon_Context_TopologyContext_Topology_Link_ValidationMechanism, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.ValidationMechanism == nil {
t.ValidationMechanism = make(map[string]*TapiCommon_Context_TopologyContext_Topology_Link_ValidationMechanism)
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.ValidationMechanism[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list ValidationMechanism", key)
t.ValidationMechanism[key] = &TapiCommon_Context_TopologyContext_Topology_Link_ValidationMechanism{
ValidationMechanism: &ValidationMechanism,
// ΛListKeyMap returns the keys of the TapiCommon_Context_TopologyContext_Topology_Link struct, which is a YANG list entry.
func (t *TapiCommon_Context_TopologyContext_Topology_Link) ΛListKeyMap() (map[string]interface{}, error) {
if t.Uuid == nil {
return nil, fmt.Errorf("nil value for key Uuid")
return map[string]interface{}{
"uuid": *t.Uuid,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_Topology_Link) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_Topology_Link"], t, opts...); err != nil {
return err
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_Topology_Link) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext_Topology_Link_AvailableCapacity represents the /tapi-common/context/topology-context/topology/link/available-capacity YANG schema element.
type TapiCommon_Context_TopologyContext_Topology_Link_AvailableCapacity struct {
TotalSize *TapiCommon_Context_TopologyContext_Topology_Link_AvailableCapacity_TotalSize `path:"total-size" module:"tapi-topology"`
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology_Link_AvailableCapacity implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_Topology_Link_AvailableCapacity) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_Topology_Link_AvailableCapacity) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_Topology_Link_AvailableCapacity"], t, opts...); err != nil {
return err
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_Topology_Link_AvailableCapacity) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext_Topology_Link_AvailableCapacity_TotalSize represents the /tapi-common/context/topology-context/topology/link/available-capacity/total-size YANG schema element.
type TapiCommon_Context_TopologyContext_Topology_Link_AvailableCapacity_TotalSize struct {
Unit E_TapiCommon_CapacityUnit `path:"unit" module:"tapi-topology"`
Value *uint64 `path:"value" module:"tapi-topology"`
7428
7429
7430
7431
7432
7433
7434
7435
7436
7437
7438
7439
7440
7441
7442
7443
7444
7445
7446
7447
7448
7449
7450
7451
7452
7453
7454
7455
7456
7457
7458
7459
7460
7461
7462
7463
7464
7465
7466
7467
7468
7469
7470
7471
7472
7473
7474
7475
7476
7477
7478
7479
7480
7481
7482
7483
7484
7485
7486
7487
7488
7489
7490
7491
7492
7493
7494
7495
7496
7497
7498
7499
7500
7501
7502
7503
7504
7505
7506
7507
7508
7509
7510
7511
7512
7513
7514
7515
7516
7517
7518
7519
7520
7521
7522
7523
7524
7525
7526
7527
7528
7529
7530
7531
7532
7533
7534
7535
7536
7537
7538
7539
7540
7541
7542
7543
7544
7545
7546
7547
7548
7549
7550
7551
7552
7553
7554
7555
7556
7557
7558
7559
7560
7561
7562
7563
7564
7565
7566
7567
7568
7569
7570
7571
7572
7573
7574
7575
7576
7577
7578
7579
7580
7581
7582
7583
7584
7585
7586
7587
7588
7589
7590
7591
7592
7593
7594
7595
7596
7597
7598
7599
7600
7601
7602
7603
7604
7605
7606
7607
7608
7609
7610
7611
7612
7613
7614
7615
7616
7617
7618
7619
7620
7621
7622
7623
7624
7625
7626
7627
7628
7629
7630
7631
7632
7633
7634
7635
7636
7637
7638
7639
7640
7641
7642
7643
7644
7645
7646
7647
7648
7649
7650
7651
7652
7653
7654
7655
7656
7657
7658
7659
7660
7661
7662
7663
7664
7665
7666
7667
7668
7669
7670
7671
7672
7673
7674
7675
7676
7677
7678
7679
7680
7681
7682
7683
7684
7685
7686
7687
7688
7689
7690
7691
7692
7693
7694
7695
7696
7697
7698
7699
7700
7701
7702
7703
7704
7705
7706
7707
7708
7709
7710
7711
7712
7713
7714
7715
7716
7717
7718
7719
7720
7721
7722
7723
7724
7725
7726
7727
7728
7729
7730
7731
7732
7733
7734
7735
7736
7737
7738
7739
7740
7741
7742
7743
7744
7745
7746
7747
7748
7749
7750
7751
7752
7753
7754
7755
7756
7757
7758
7759
7760
7761
7762
7763
7764
7765
7766
7767
7768
7769
7770
7771
7772
7773
7774
7775
7776
7777
7778
7779
7780
7781
7782
7783
7784
7785
7786
7787
7788
7789
7790
7791
7792
7793
7794
7795
7796
7797
7798
7799
7800
7801
7802
7803
7804
7805
7806
7807
7808
7809
7810
7811
7812
7813
7814
7815
7816
7817
7818
7819
7820
7821
7822
7823
7824
7825
7826
7827
7828
7829
7830
7831
7832
7833
7834
7835
7836
7837
7838
7839
7840
7841
7842
7843
7844
7845
7846
7847
7848
7849
7850
7851
7852
7853
7854
7855
7856
7857
7858
7859
7860
7861
7862
7863
7864
7865
7866
7867
7868
7869
7870
7871
7872
7873
7874
7875
7876
7877
7878
7879
7880
7881
7882
7883
7884
7885
7886
7887
7888
7889
7890
7891
7892
7893
7894
7895
7896
7897
7898
7899
7900
7901
7902
7903
7904
7905
7906
7907
7908
7909
7910
7911
7912
7913
7914
7915
7916
7917
7918
7919
7920
7921
7922
7923
7924
7925
7926
7927
7928
7929
7930
7931
7932
7933
7934
7935
7936
7937
7938
7939
7940
7941
7942
7943
7944
7945
7946
7947
7948
7949
7950
7951
7952
7953
7954
7955
7956
7957
7958
7959
7960
7961
7962
7963
7964
7965
7966
7967
7968
7969
7970
7971
7972
7973
7974
7975
7976
7977
7978
7979
7980
7981
7982
7983
7984
7985
7986
7987
7988
7989
7990
7991
7992
7993
7994
7995
7996
7997
7998
7999
8000
8001
8002
8003
8004
8005
8006
8007
8008
8009
8010
8011
8012
8013
8014
8015
8016
8017
8018
8019
8020
8021
8022
8023
8024
8025
8026
8027
8028
8029
8030
8031
8032
8033
8034
8035
8036
8037
8038
8039
8040
8041
8042
8043
8044
8045
8046
8047
8048
8049
8050
8051
8052
8053
8054
8055
8056
8057
8058
8059
8060
8061
8062
8063
8064
8065
8066
8067
8068
8069
8070
8071
8072
8073
8074
8075
8076
8077
8078
8079
8080
8081
8082
8083
8084
8085
8086
8087
8088
8089
8090
8091
8092
8093
8094
8095
8096
8097
8098
8099
8100
8101
8102
8103
8104
8105
8106
8107
8108
8109
8110
8111
8112
8113
8114
8115
8116
8117
8118
8119
8120
8121
8122
8123
8124
8125
8126
8127
8128
8129
8130
8131
8132
8133
8134
8135
8136
8137
8138
8139
8140
8141
8142
8143
8144
8145
8146
8147
8148
8149
8150
8151
8152
8153
8154
8155
8156
8157
8158
8159
8160
8161
8162
8163
8164
8165
8166
8167
8168
8169
8170
8171
8172
8173
8174
8175
8176
8177
8178
8179
8180
8181
8182
8183
8184
8185
8186
8187
8188
8189
8190
8191
8192
8193
8194
8195
8196
8197
8198
8199
8200
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology_Link_AvailableCapacity_TotalSize implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_Topology_Link_AvailableCapacity_TotalSize) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_Topology_Link_AvailableCapacity_TotalSize) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_Topology_Link_AvailableCapacity_TotalSize"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_Topology_Link_AvailableCapacity_TotalSize) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext_Topology_Link_CostCharacteristic represents the /tapi-common/context/topology-context/topology/link/cost-characteristic YANG schema element.
type TapiCommon_Context_TopologyContext_Topology_Link_CostCharacteristic struct {
CostAlgorithm *string `path:"cost-algorithm" module:"tapi-topology"`
CostName *string `path:"cost-name" module:"tapi-topology"`
CostValue *string `path:"cost-value" module:"tapi-topology"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology_Link_CostCharacteristic implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_Topology_Link_CostCharacteristic) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_TopologyContext_Topology_Link_CostCharacteristic struct, which is a YANG list entry.
func (t *TapiCommon_Context_TopologyContext_Topology_Link_CostCharacteristic) ΛListKeyMap() (map[string]interface{}, error) {
if t.CostName == nil {
return nil, fmt.Errorf("nil value for key CostName")
}
return map[string]interface{}{
"cost-name": *t.CostName,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_Topology_Link_CostCharacteristic) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_Topology_Link_CostCharacteristic"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_Topology_Link_CostCharacteristic) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext_Topology_Link_LatencyCharacteristic represents the /tapi-common/context/topology-context/topology/link/latency-characteristic YANG schema element.
type TapiCommon_Context_TopologyContext_Topology_Link_LatencyCharacteristic struct {
FixedLatencyCharacteristic *string `path:"fixed-latency-characteristic" module:"tapi-topology"`
JitterCharacteristic *string `path:"jitter-characteristic" module:"tapi-topology"`
QueingLatencyCharacteristic *string `path:"queing-latency-characteristic" module:"tapi-topology"`
TrafficPropertyName *string `path:"traffic-property-name" module:"tapi-topology"`
WanderCharacteristic *string `path:"wander-characteristic" module:"tapi-topology"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology_Link_LatencyCharacteristic implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_Topology_Link_LatencyCharacteristic) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_TopologyContext_Topology_Link_LatencyCharacteristic struct, which is a YANG list entry.
func (t *TapiCommon_Context_TopologyContext_Topology_Link_LatencyCharacteristic) ΛListKeyMap() (map[string]interface{}, error) {
if t.TrafficPropertyName == nil {
return nil, fmt.Errorf("nil value for key TrafficPropertyName")
}
return map[string]interface{}{
"traffic-property-name": *t.TrafficPropertyName,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_Topology_Link_LatencyCharacteristic) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_Topology_Link_LatencyCharacteristic"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_Topology_Link_LatencyCharacteristic) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext_Topology_Link_Name represents the /tapi-common/context/topology-context/topology/link/name YANG schema element.
type TapiCommon_Context_TopologyContext_Topology_Link_Name struct {
Value *string `path:"value" module:"tapi-topology"`
ValueName *string `path:"value-name" module:"tapi-topology"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology_Link_Name implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_Topology_Link_Name) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_TopologyContext_Topology_Link_Name struct, which is a YANG list entry.
func (t *TapiCommon_Context_TopologyContext_Topology_Link_Name) ΛListKeyMap() (map[string]interface{}, error) {
if t.ValueName == nil {
return nil, fmt.Errorf("nil value for key ValueName")
}
return map[string]interface{}{
"value-name": *t.ValueName,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_Topology_Link_Name) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_Topology_Link_Name"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_Topology_Link_Name) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext_Topology_Link_NodeEdgePoint represents the /tapi-common/context/topology-context/topology/link/node-edge-point YANG schema element.
type TapiCommon_Context_TopologyContext_Topology_Link_NodeEdgePoint struct {
NodeEdgePointUuid *string `path:"node-edge-point-uuid" module:"tapi-topology"`
NodeUuid *string `path:"node-uuid" module:"tapi-topology"`
TopologyUuid *string `path:"topology-uuid" module:"tapi-topology"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology_Link_NodeEdgePoint implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_Topology_Link_NodeEdgePoint) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_TopologyContext_Topology_Link_NodeEdgePoint struct, which is a YANG list entry.
func (t *TapiCommon_Context_TopologyContext_Topology_Link_NodeEdgePoint) ΛListKeyMap() (map[string]interface{}, error) {
if t.NodeEdgePointUuid == nil {
return nil, fmt.Errorf("nil value for key NodeEdgePointUuid")
}
if t.NodeUuid == nil {
return nil, fmt.Errorf("nil value for key NodeUuid")
}
if t.TopologyUuid == nil {
return nil, fmt.Errorf("nil value for key TopologyUuid")
}
return map[string]interface{}{
"node-edge-point-uuid": *t.NodeEdgePointUuid,
"node-uuid": *t.NodeUuid,
"topology-uuid": *t.TopologyUuid,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_Topology_Link_NodeEdgePoint) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_Topology_Link_NodeEdgePoint"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_Topology_Link_NodeEdgePoint) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext_Topology_Link_ResilienceType represents the /tapi-common/context/topology-context/topology/link/resilience-type YANG schema element.
type TapiCommon_Context_TopologyContext_Topology_Link_ResilienceType struct {
ProtectionType E_TapiTopology_ProtectionType `path:"protection-type" module:"tapi-topology"`
RestorationPolicy E_TapiTopology_RestorationPolicy `path:"restoration-policy" module:"tapi-topology"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology_Link_ResilienceType implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_Topology_Link_ResilienceType) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_Topology_Link_ResilienceType) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_Topology_Link_ResilienceType"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_Topology_Link_ResilienceType) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext_Topology_Link_RiskCharacteristic represents the /tapi-common/context/topology-context/topology/link/risk-characteristic YANG schema element.
type TapiCommon_Context_TopologyContext_Topology_Link_RiskCharacteristic struct {
RiskCharacteristicName *string `path:"risk-characteristic-name" module:"tapi-topology"`
RiskIdentifierList []string `path:"risk-identifier-list" module:"tapi-topology"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology_Link_RiskCharacteristic implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_Topology_Link_RiskCharacteristic) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_TopologyContext_Topology_Link_RiskCharacteristic struct, which is a YANG list entry.
func (t *TapiCommon_Context_TopologyContext_Topology_Link_RiskCharacteristic) ΛListKeyMap() (map[string]interface{}, error) {
if t.RiskCharacteristicName == nil {
return nil, fmt.Errorf("nil value for key RiskCharacteristicName")
}
return map[string]interface{}{
"risk-characteristic-name": *t.RiskCharacteristicName,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_Topology_Link_RiskCharacteristic) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_Topology_Link_RiskCharacteristic"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_Topology_Link_RiskCharacteristic) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext_Topology_Link_TotalPotentialCapacity represents the /tapi-common/context/topology-context/topology/link/total-potential-capacity YANG schema element.
type TapiCommon_Context_TopologyContext_Topology_Link_TotalPotentialCapacity struct {
TotalSize *TapiCommon_Context_TopologyContext_Topology_Link_TotalPotentialCapacity_TotalSize `path:"total-size" module:"tapi-topology"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology_Link_TotalPotentialCapacity implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_Topology_Link_TotalPotentialCapacity) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_Topology_Link_TotalPotentialCapacity) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_Topology_Link_TotalPotentialCapacity"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_Topology_Link_TotalPotentialCapacity) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext_Topology_Link_TotalPotentialCapacity_TotalSize represents the /tapi-common/context/topology-context/topology/link/total-potential-capacity/total-size YANG schema element.
type TapiCommon_Context_TopologyContext_Topology_Link_TotalPotentialCapacity_TotalSize struct {
Unit E_TapiCommon_CapacityUnit `path:"unit" module:"tapi-topology"`
Value *uint64 `path:"value" module:"tapi-topology"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology_Link_TotalPotentialCapacity_TotalSize implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_Topology_Link_TotalPotentialCapacity_TotalSize) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_Topology_Link_TotalPotentialCapacity_TotalSize) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_Topology_Link_TotalPotentialCapacity_TotalSize"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_Topology_Link_TotalPotentialCapacity_TotalSize) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext_Topology_Link_ValidationMechanism represents the /tapi-common/context/topology-context/topology/link/validation-mechanism YANG schema element.
type TapiCommon_Context_TopologyContext_Topology_Link_ValidationMechanism struct {
LayerProtocolAdjacencyValidated *string `path:"layer-protocol-adjacency-validated" module:"tapi-topology"`
ValidationMechanism *string `path:"validation-mechanism" module:"tapi-topology"`
ValidationRobustness *string `path:"validation-robustness" module:"tapi-topology"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology_Link_ValidationMechanism implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_Topology_Link_ValidationMechanism) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_TopologyContext_Topology_Link_ValidationMechanism struct, which is a YANG list entry.
func (t *TapiCommon_Context_TopologyContext_Topology_Link_ValidationMechanism) ΛListKeyMap() (map[string]interface{}, error) {
if t.ValidationMechanism == nil {
return nil, fmt.Errorf("nil value for key ValidationMechanism")
}
return map[string]interface{}{
"validation-mechanism": *t.ValidationMechanism,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_Topology_Link_ValidationMechanism) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_Topology_Link_ValidationMechanism"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_Topology_Link_ValidationMechanism) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext_Topology_Name represents the /tapi-common/context/topology-context/topology/name YANG schema element.
type TapiCommon_Context_TopologyContext_Topology_Name struct {
Value *string `path:"value" module:"tapi-topology"`
ValueName *string `path:"value-name" module:"tapi-topology"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology_Name implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_Topology_Name) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_TopologyContext_Topology_Name struct, which is a YANG list entry.
func (t *TapiCommon_Context_TopologyContext_Topology_Name) ΛListKeyMap() (map[string]interface{}, error) {
if t.ValueName == nil {
return nil, fmt.Errorf("nil value for key ValueName")
}
return map[string]interface{}{
"value-name": *t.ValueName,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_Topology_Name) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_Topology_Name"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_Topology_Name) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext_Topology_Node represents the /tapi-common/context/topology-context/topology/node YANG schema element.
type TapiCommon_Context_TopologyContext_Topology_Node struct {
AdministrativeState E_TapiCommon_AdministrativeState `path:"administrative-state" module:"tapi-topology"`
AggregatedNodeEdgePoint map[TapiCommon_Context_TopologyContext_Topology_Node_AggregatedNodeEdgePoint_Key]*TapiCommon_Context_TopologyContext_Topology_Node_AggregatedNodeEdgePoint `path:"aggregated-node-edge-point" module:"tapi-topology"`
AvailableCapacity *TapiCommon_Context_TopologyContext_Topology_Node_AvailableCapacity `path:"available-capacity" module:"tapi-topology"`
CostCharacteristic map[string]*TapiCommon_Context_TopologyContext_Topology_Node_CostCharacteristic `path:"cost-characteristic" module:"tapi-topology"`
DeliveryOrderCharacteristic *string `path:"delivery-order-characteristic" module:"tapi-topology"`
EncapTopology *TapiCommon_Context_TopologyContext_Topology_Node_EncapTopology `path:"encap-topology" module:"tapi-topology"`
ErrorCharacteristic *string `path:"error-characteristic" module:"tapi-topology"`
LatencyCharacteristic map[string]*TapiCommon_Context_TopologyContext_Topology_Node_LatencyCharacteristic `path:"latency-characteristic" module:"tapi-topology"`
LayerProtocolName []E_TapiTopology_LayerProtocolName `path:"layer-protocol-name" module:"tapi-topology"`
LifecycleState E_TapiCommon_LifecycleState `path:"lifecycle-state" module:"tapi-topology"`
LossCharacteristic *string `path:"loss-characteristic" module:"tapi-topology"`
Name map[string]*TapiCommon_Context_TopologyContext_Topology_Node_Name `path:"name" module:"tapi-topology"`
NodeRuleGroup map[string]*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup `path:"node-rule-group" module:"tapi-topology"`
OperationalState E_TapiCommon_OperationalState `path:"operational-state" module:"tapi-topology"`
OwnedNodeEdgePoint map[string]*TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint `path:"owned-node-edge-point" module:"tapi-topology"`
RepeatDeliveryCharacteristic *string `path:"repeat-delivery-characteristic" module:"tapi-topology"`
ServerIntegrityProcessCharacteristic *string `path:"server-integrity-process-characteristic" module:"tapi-topology"`
TotalPotentialCapacity *TapiCommon_Context_TopologyContext_Topology_Node_TotalPotentialCapacity `path:"total-potential-capacity" module:"tapi-topology"`
UnavailableTimeCharacteristic *string `path:"unavailable-time-characteristic" module:"tapi-topology"`
Uuid *string `path:"uuid" module:"tapi-topology"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology_Node implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_Topology_Node) IsYANGGoStruct() {}
// TapiCommon_Context_TopologyContext_Topology_Node_AggregatedNodeEdgePoint_Key represents the key for list AggregatedNodeEdgePoint of element /tapi-common/context/topology-context/topology/node.
type TapiCommon_Context_TopologyContext_Topology_Node_AggregatedNodeEdgePoint_Key struct {
TopologyUuid string `path:"topology-uuid"`
NodeUuid string `path:"node-uuid"`
NodeEdgePointUuid string `path:"node-edge-point-uuid"`
}
// NewAggregatedNodeEdgePoint creates a new entry in the AggregatedNodeEdgePoint list of the
// TapiCommon_Context_TopologyContext_Topology_Node struct. The keys of the list are populated from the input
// arguments.
func (t *TapiCommon_Context_TopologyContext_Topology_Node) NewAggregatedNodeEdgePoint(TopologyUuid string, NodeUuid string, NodeEdgePointUuid string) (*TapiCommon_Context_TopologyContext_Topology_Node_AggregatedNodeEdgePoint, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.AggregatedNodeEdgePoint == nil {
t.AggregatedNodeEdgePoint = make(map[TapiCommon_Context_TopologyContext_Topology_Node_AggregatedNodeEdgePoint_Key]*TapiCommon_Context_TopologyContext_Topology_Node_AggregatedNodeEdgePoint)
}
key := TapiCommon_Context_TopologyContext_Topology_Node_AggregatedNodeEdgePoint_Key{
TopologyUuid: TopologyUuid,
NodeUuid: NodeUuid,
NodeEdgePointUuid: NodeEdgePointUuid,
}
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.AggregatedNodeEdgePoint[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list AggregatedNodeEdgePoint", key)
}
t.AggregatedNodeEdgePoint[key] = &TapiCommon_Context_TopologyContext_Topology_Node_AggregatedNodeEdgePoint{
TopologyUuid: &TopologyUuid,
NodeUuid: &NodeUuid,
NodeEdgePointUuid: &NodeEdgePointUuid,
}
return t.AggregatedNodeEdgePoint[key], nil
}
// NewCostCharacteristic creates a new entry in the CostCharacteristic list of the
// TapiCommon_Context_TopologyContext_Topology_Node struct. The keys of the list are populated from the input
// arguments.
func (t *TapiCommon_Context_TopologyContext_Topology_Node) NewCostCharacteristic(CostName string) (*TapiCommon_Context_TopologyContext_Topology_Node_CostCharacteristic, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.CostCharacteristic == nil {
t.CostCharacteristic = make(map[string]*TapiCommon_Context_TopologyContext_Topology_Node_CostCharacteristic)
}
key := CostName
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.CostCharacteristic[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list CostCharacteristic", key)
}
t.CostCharacteristic[key] = &TapiCommon_Context_TopologyContext_Topology_Node_CostCharacteristic{
CostName: &CostName,
}
return t.CostCharacteristic[key], nil
}
// NewLatencyCharacteristic creates a new entry in the LatencyCharacteristic list of the
// TapiCommon_Context_TopologyContext_Topology_Node struct. The keys of the list are populated from the input
// arguments.
func (t *TapiCommon_Context_TopologyContext_Topology_Node) NewLatencyCharacteristic(TrafficPropertyName string) (*TapiCommon_Context_TopologyContext_Topology_Node_LatencyCharacteristic, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.LatencyCharacteristic == nil {
t.LatencyCharacteristic = make(map[string]*TapiCommon_Context_TopologyContext_Topology_Node_LatencyCharacteristic)
}
key := TrafficPropertyName
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.LatencyCharacteristic[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list LatencyCharacteristic", key)
}
t.LatencyCharacteristic[key] = &TapiCommon_Context_TopologyContext_Topology_Node_LatencyCharacteristic{
TrafficPropertyName: &TrafficPropertyName,
}
return t.LatencyCharacteristic[key], nil
}
// NewName creates a new entry in the Name list of the
// TapiCommon_Context_TopologyContext_Topology_Node struct. The keys of the list are populated from the input
// arguments.
func (t *TapiCommon_Context_TopologyContext_Topology_Node) NewName(ValueName string) (*TapiCommon_Context_TopologyContext_Topology_Node_Name, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.Name == nil {
t.Name = make(map[string]*TapiCommon_Context_TopologyContext_Topology_Node_Name)
}
key := ValueName
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.Name[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list Name", key)
}
t.Name[key] = &TapiCommon_Context_TopologyContext_Topology_Node_Name{
ValueName: &ValueName,
}
return t.Name[key], nil
}
// NewNodeRuleGroup creates a new entry in the NodeRuleGroup list of the
// TapiCommon_Context_TopologyContext_Topology_Node struct. The keys of the list are populated from the input
// arguments.
func (t *TapiCommon_Context_TopologyContext_Topology_Node) NewNodeRuleGroup(Uuid string) (*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.NodeRuleGroup == nil {
t.NodeRuleGroup = make(map[string]*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup)
}
key := Uuid
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.NodeRuleGroup[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list NodeRuleGroup", key)
}
t.NodeRuleGroup[key] = &TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup{
Uuid: &Uuid,
}
return t.NodeRuleGroup[key], nil
}
// NewOwnedNodeEdgePoint creates a new entry in the OwnedNodeEdgePoint list of the
// TapiCommon_Context_TopologyContext_Topology_Node struct. The keys of the list are populated from the input
// arguments.
func (t *TapiCommon_Context_TopologyContext_Topology_Node) NewOwnedNodeEdgePoint(Uuid string) (*TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.OwnedNodeEdgePoint == nil {
t.OwnedNodeEdgePoint = make(map[string]*TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint)
}
key := Uuid
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.OwnedNodeEdgePoint[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list OwnedNodeEdgePoint", key)
}
t.OwnedNodeEdgePoint[key] = &TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint{
Uuid: &Uuid,
}
return t.OwnedNodeEdgePoint[key], nil
}
// ΛListKeyMap returns the keys of the TapiCommon_Context_TopologyContext_Topology_Node struct, which is a YANG list entry.
func (t *TapiCommon_Context_TopologyContext_Topology_Node) ΛListKeyMap() (map[string]interface{}, error) {
if t.Uuid == nil {
return nil, fmt.Errorf("nil value for key Uuid")
}
return map[string]interface{}{
"uuid": *t.Uuid,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_Topology_Node) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_Topology_Node"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_Topology_Node) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext_Topology_Node_AggregatedNodeEdgePoint represents the /tapi-common/context/topology-context/topology/node/aggregated-node-edge-point YANG schema element.
type TapiCommon_Context_TopologyContext_Topology_Node_AggregatedNodeEdgePoint struct {
NodeEdgePointUuid *string `path:"node-edge-point-uuid" module:"tapi-topology"`
NodeUuid *string `path:"node-uuid" module:"tapi-topology"`
TopologyUuid *string `path:"topology-uuid" module:"tapi-topology"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology_Node_AggregatedNodeEdgePoint implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_Topology_Node_AggregatedNodeEdgePoint) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_TopologyContext_Topology_Node_AggregatedNodeEdgePoint struct, which is a YANG list entry.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_AggregatedNodeEdgePoint) ΛListKeyMap() (map[string]interface{}, error) {
if t.NodeEdgePointUuid == nil {
return nil, fmt.Errorf("nil value for key NodeEdgePointUuid")
}
if t.NodeUuid == nil {
return nil, fmt.Errorf("nil value for key NodeUuid")
}
if t.TopologyUuid == nil {
return nil, fmt.Errorf("nil value for key TopologyUuid")
}
return map[string]interface{}{
"node-edge-point-uuid": *t.NodeEdgePointUuid,
"node-uuid": *t.NodeUuid,
"topology-uuid": *t.TopologyUuid,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_AggregatedNodeEdgePoint) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_Topology_Node_AggregatedNodeEdgePoint"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_AggregatedNodeEdgePoint) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext_Topology_Node_AvailableCapacity represents the /tapi-common/context/topology-context/topology/node/available-capacity YANG schema element.
type TapiCommon_Context_TopologyContext_Topology_Node_AvailableCapacity struct {
TotalSize *TapiCommon_Context_TopologyContext_Topology_Node_AvailableCapacity_TotalSize `path:"total-size" module:"tapi-topology"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology_Node_AvailableCapacity implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_Topology_Node_AvailableCapacity) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_AvailableCapacity) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_Topology_Node_AvailableCapacity"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_AvailableCapacity) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext_Topology_Node_AvailableCapacity_TotalSize represents the /tapi-common/context/topology-context/topology/node/available-capacity/total-size YANG schema element.
type TapiCommon_Context_TopologyContext_Topology_Node_AvailableCapacity_TotalSize struct {
Unit E_TapiCommon_CapacityUnit `path:"unit" module:"tapi-topology"`
Value *uint64 `path:"value" module:"tapi-topology"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology_Node_AvailableCapacity_TotalSize implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_Topology_Node_AvailableCapacity_TotalSize) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_AvailableCapacity_TotalSize) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_Topology_Node_AvailableCapacity_TotalSize"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_AvailableCapacity_TotalSize) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext_Topology_Node_CostCharacteristic represents the /tapi-common/context/topology-context/topology/node/cost-characteristic YANG schema element.
type TapiCommon_Context_TopologyContext_Topology_Node_CostCharacteristic struct {
CostAlgorithm *string `path:"cost-algorithm" module:"tapi-topology"`
CostName *string `path:"cost-name" module:"tapi-topology"`
CostValue *string `path:"cost-value" module:"tapi-topology"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology_Node_CostCharacteristic implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_Topology_Node_CostCharacteristic) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_TopologyContext_Topology_Node_CostCharacteristic struct, which is a YANG list entry.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_CostCharacteristic) ΛListKeyMap() (map[string]interface{}, error) {
if t.CostName == nil {
return nil, fmt.Errorf("nil value for key CostName")
}
return map[string]interface{}{
"cost-name": *t.CostName,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_CostCharacteristic) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_Topology_Node_CostCharacteristic"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_CostCharacteristic) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext_Topology_Node_EncapTopology represents the /tapi-common/context/topology-context/topology/node/encap-topology YANG schema element.
type TapiCommon_Context_TopologyContext_Topology_Node_EncapTopology struct {
TopologyUuid *string `path:"topology-uuid" module:"tapi-topology"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology_Node_EncapTopology implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_Topology_Node_EncapTopology) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_EncapTopology) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_Topology_Node_EncapTopology"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_EncapTopology) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext_Topology_Node_LatencyCharacteristic represents the /tapi-common/context/topology-context/topology/node/latency-characteristic YANG schema element.
type TapiCommon_Context_TopologyContext_Topology_Node_LatencyCharacteristic struct {
FixedLatencyCharacteristic *string `path:"fixed-latency-characteristic" module:"tapi-topology"`
JitterCharacteristic *string `path:"jitter-characteristic" module:"tapi-topology"`
QueingLatencyCharacteristic *string `path:"queing-latency-characteristic" module:"tapi-topology"`
TrafficPropertyName *string `path:"traffic-property-name" module:"tapi-topology"`
WanderCharacteristic *string `path:"wander-characteristic" module:"tapi-topology"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology_Node_LatencyCharacteristic implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_Topology_Node_LatencyCharacteristic) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_TopologyContext_Topology_Node_LatencyCharacteristic struct, which is a YANG list entry.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_LatencyCharacteristic) ΛListKeyMap() (map[string]interface{}, error) {
if t.TrafficPropertyName == nil {
return nil, fmt.Errorf("nil value for key TrafficPropertyName")
}
return map[string]interface{}{
"traffic-property-name": *t.TrafficPropertyName,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_LatencyCharacteristic) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_Topology_Node_LatencyCharacteristic"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_LatencyCharacteristic) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext_Topology_Node_Name represents the /tapi-common/context/topology-context/topology/node/name YANG schema element.
type TapiCommon_Context_TopologyContext_Topology_Node_Name struct {
Value *string `path:"value" module:"tapi-topology"`
ValueName *string `path:"value-name" module:"tapi-topology"`
}
8201
8202
8203
8204
8205
8206
8207
8208
8209
8210
8211
8212
8213
8214
8215
8216
8217
8218
8219
8220
8221
8222
8223
8224
8225
8226
8227
8228
8229
8230
8231
8232
8233
8234
8235
8236
8237
8238
8239
8240
8241
8242
8243
8244
8245
8246
8247
8248
8249
8250
8251
8252
8253
8254
8255
8256
8257
8258
8259
8260
8261
8262
8263
8264
8265
8266
8267
8268
8269
8270
8271
8272
8273
8274
8275
8276
8277
8278
8279
8280
8281
8282
8283
8284
8285
8286
8287
8288
8289
8290
8291
8292
8293
8294
8295
8296
8297
8298
8299
8300
8301
8302
8303
8304
8305
8306
8307
8308
8309
8310
8311
8312
8313
8314
8315
8316
8317
8318
8319
8320
8321
8322
8323
8324
8325
8326
8327
8328
8329
8330
8331
8332
8333
8334
8335
8336
8337
8338
8339
8340
8341
8342
8343
8344
8345
8346
8347
8348
8349
8350
8351
8352
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology_Node_Name implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_Topology_Node_Name) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_TopologyContext_Topology_Node_Name struct, which is a YANG list entry.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_Name) ΛListKeyMap() (map[string]interface{}, error) {
if t.ValueName == nil {
return nil, fmt.Errorf("nil value for key ValueName")
}
return map[string]interface{}{
"value-name": *t.ValueName,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_Name) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_Topology_Node_Name"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_Name) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup represents the /tapi-common/context/topology-context/topology/node/node-rule-group YANG schema element.
type TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup struct {
AvailableCapacity *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_AvailableCapacity `path:"available-capacity" module:"tapi-topology"`
ComposedRuleGroup map[TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_ComposedRuleGroup_Key]*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_ComposedRuleGroup `path:"composed-rule-group" module:"tapi-topology"`
CostCharacteristic map[string]*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_CostCharacteristic `path:"cost-characteristic" module:"tapi-topology"`
InterRuleGroup map[string]*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup `path:"inter-rule-group" module:"tapi-topology"`
LatencyCharacteristic map[string]*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_LatencyCharacteristic `path:"latency-characteristic" module:"tapi-topology"`
Name map[string]*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_Name `path:"name" module:"tapi-topology"`
NodeEdgePoint map[TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_NodeEdgePoint_Key]*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_NodeEdgePoint `path:"node-edge-point" module:"tapi-topology"`
RiskCharacteristic map[string]*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_RiskCharacteristic `path:"risk-characteristic" module:"tapi-topology"`
Rule map[string]*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_Rule `path:"rule" module:"tapi-topology"`
TotalPotentialCapacity *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_TotalPotentialCapacity `path:"total-potential-capacity" module:"tapi-topology"`
Uuid *string `path:"uuid" module:"tapi-topology"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup) IsYANGGoStruct() {}
// TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_ComposedRuleGroup_Key represents the key for list ComposedRuleGroup of element /tapi-common/context/topology-context/topology/node/node-rule-group.
type TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_ComposedRuleGroup_Key struct {
TopologyUuid string `path:"topology-uuid"`
NodeUuid string `path:"node-uuid"`
NodeRuleGroupUuid string `path:"node-rule-group-uuid"`
}
// TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_NodeEdgePoint_Key represents the key for list NodeEdgePoint of element /tapi-common/context/topology-context/topology/node/node-rule-group.
type TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_NodeEdgePoint_Key struct {
TopologyUuid string `path:"topology-uuid"`
NodeUuid string `path:"node-uuid"`
NodeEdgePointUuid string `path:"node-edge-point-uuid"`
}
// NewComposedRuleGroup creates a new entry in the ComposedRuleGroup list of the
// TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup struct. The keys of the list are populated from the input
// arguments.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup) NewComposedRuleGroup(TopologyUuid string, NodeUuid string, NodeRuleGroupUuid string) (*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_ComposedRuleGroup, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.ComposedRuleGroup == nil {
t.ComposedRuleGroup = make(map[TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_ComposedRuleGroup_Key]*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_ComposedRuleGroup)
}
key := TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_ComposedRuleGroup_Key{
TopologyUuid: TopologyUuid,
NodeUuid: NodeUuid,
NodeRuleGroupUuid: NodeRuleGroupUuid,
}
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.ComposedRuleGroup[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list ComposedRuleGroup", key)
}
t.ComposedRuleGroup[key] = &TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_ComposedRuleGroup{
TopologyUuid: &TopologyUuid,
NodeUuid: &NodeUuid,
NodeRuleGroupUuid: &NodeRuleGroupUuid,
}
return t.ComposedRuleGroup[key], nil
}
// NewCostCharacteristic creates a new entry in the CostCharacteristic list of the
// TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup struct. The keys of the list are populated from the input
// arguments.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup) NewCostCharacteristic(CostName string) (*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_CostCharacteristic, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.CostCharacteristic == nil {
t.CostCharacteristic = make(map[string]*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_CostCharacteristic)
}
key := CostName
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.CostCharacteristic[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list CostCharacteristic", key)
}
t.CostCharacteristic[key] = &TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_CostCharacteristic{
CostName: &CostName,
}
return t.CostCharacteristic[key], nil
}
// NewInterRuleGroup creates a new entry in the InterRuleGroup list of the
// TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup struct. The keys of the list are populated from the input
// arguments.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup) NewInterRuleGroup(Uuid string) (*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.InterRuleGroup == nil {
t.InterRuleGroup = make(map[string]*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup)
}
key := Uuid
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.InterRuleGroup[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list InterRuleGroup", key)
}
t.InterRuleGroup[key] = &TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup{
Uuid: &Uuid,
}
return t.InterRuleGroup[key], nil
}
// NewLatencyCharacteristic creates a new entry in the LatencyCharacteristic list of the
// TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup struct. The keys of the list are populated from the input
// arguments.
8355
8356
8357
8358
8359
8360
8361
8362
8363
8364
8365
8366
8367
8368
8369
8370
8371
8372
8373
8374
8375
8376
8377
8378
8379
8380
8381
8382
8383
8384
8385
8386
8387
8388
8389
8390
8391
8392
8393
8394
8395
8396
8397
8398
8399
8400
8401
8402
8403
8404
8405
8406
8407
8408
8409
8410
8411
8412
8413
8414
8415
8416
8417
8418
8419
8420
8421
8422
8423
8424
8425
8426
8427
8428
8429
8430
8431
8432
8433
8434
8435
8436
8437
8438
8439
8440
8441
8442
8443
8444
8445
8446
8447
8448
8449
8450
8451
8452
8453
8454
8455
8456
8457
8458
8459
8460
8461
8462
8463
8464
8465
8466
8467
8468
8469
8470
8471
8472
8473
8474
8475
8476
8477
8478
8479
8480
8481
8482
8483
8484
8485
8486
8487
8488
8489
8490
8491
8492
8493
8494
8495
8496
8497
8498
8499
8500
8501
8502
8503
8504
8505
8506
8507
8508
8509
8510
8511
8512
8513
8514
8515
8516
8517
8518
8519
8520
8521
8522
8523
8524
8525
8526
8527
8528
8529
8530
8531
8532
8533
8534
8535
8536
8537
8538
8539
8540
8541
8542
8543
8544
8545
8546
8547
8548
8549
8550
8551
8552
8553
8554
8555
8556
8557
8558
8559
8560
8561
8562
8563
8564
8565
8566
8567
8568
8569
8570
8571
8572
8573
8574
8575
8576
8577
8578
8579
8580
8581
8582
8583
8584
8585
8586
8587
8588
8589
8590
8591
8592
8593
8594
8595
8596
8597
8598
8599
8600
8601
8602
8603
8604
8605
8606
8607
8608
8609
8610
8611
8612
8613
8614
8615
8616
8617
8618
8619
8620
8621
8622
8623
8624
8625
8626
8627
8628
8629
8630
8631
8632
8633
8634
8635
8636
8637
8638
8639
8640
8641
8642
8643
8644
8645
8646
8647
8648
8649
8650
8651
8652
8653
8654
8655
8656
8657
8658
8659
8660
8661
8662
8663
8664
8665
8666
8667
8668
8669
8670
8671
8672
8673
8674
8675
8676
8677
8678
8679
8680
8681
8682
8683
8684
8685
8686
8687
8688
8689
8690
8691
8692
8693
8694
8695
8696
8697
8698
8699
8700
8701
8702
8703
8704
8705
8706
8707
8708
8709
8710
8711
8712
8713
8714
8715
8716
8717
8718
8719
8720
8721
8722
8723
8724
8725
8726
8727
8728
8729
8730
8731
8732
8733
8734
8735
8736
8737
8738
8739
8740
8741
8742
8743
8744
8745
8746
8747
8748
8749
8750
8751
8752
8753
8754
8755
8756
8757
8758
8759
8760
8761
8762
8763
8764
8765
8766
8767
8768
8769
8770
8771
8772
8773
8774
8775
8776
8777
8778
8779
8780
8781
8782
8783
8784
8785
8786
8787
8788
8789
8790
8791
8792
8793
8794
8795
8796
8797
8798
8799
8800
8801
8802
8803
8804
8805
8806
8807
8808
8809
8810
8811
8812
8813
8814
8815
8816
8817
8818
8819
8820
8821
8822
8823
8824
8825
8826
8827
8828
8829
8830
8831
8832
8833
8834
8835
8836
8837
8838
8839
8840
8841
8842
8843
8844
8845
8846
8847
8848
8849
8850
8851
8852
8853
8854
8855
8856
8857
8858
8859
8860
8861
8862
8863
8864
8865
8866
8867
8868
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup) NewLatencyCharacteristic(TrafficPropertyName string) (*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_LatencyCharacteristic, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.LatencyCharacteristic == nil {
t.LatencyCharacteristic = make(map[string]*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_LatencyCharacteristic)
}
key := TrafficPropertyName
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.LatencyCharacteristic[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list LatencyCharacteristic", key)
}
t.LatencyCharacteristic[key] = &TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_LatencyCharacteristic{
TrafficPropertyName: &TrafficPropertyName,
}
return t.LatencyCharacteristic[key], nil
}
// NewName creates a new entry in the Name list of the
// TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup struct. The keys of the list are populated from the input
// arguments.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup) NewName(ValueName string) (*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_Name, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.Name == nil {
t.Name = make(map[string]*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_Name)
}
key := ValueName
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.Name[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list Name", key)
}
t.Name[key] = &TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_Name{
ValueName: &ValueName,
}
return t.Name[key], nil
}
// NewNodeEdgePoint creates a new entry in the NodeEdgePoint list of the
// TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup struct. The keys of the list are populated from the input
// arguments.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup) NewNodeEdgePoint(TopologyUuid string, NodeUuid string, NodeEdgePointUuid string) (*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_NodeEdgePoint, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.NodeEdgePoint == nil {
t.NodeEdgePoint = make(map[TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_NodeEdgePoint_Key]*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_NodeEdgePoint)
}
key := TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_NodeEdgePoint_Key{
TopologyUuid: TopologyUuid,
NodeUuid: NodeUuid,
NodeEdgePointUuid: NodeEdgePointUuid,
}
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.NodeEdgePoint[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list NodeEdgePoint", key)
}
t.NodeEdgePoint[key] = &TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_NodeEdgePoint{
TopologyUuid: &TopologyUuid,
NodeUuid: &NodeUuid,
NodeEdgePointUuid: &NodeEdgePointUuid,
}
return t.NodeEdgePoint[key], nil
}
// NewRiskCharacteristic creates a new entry in the RiskCharacteristic list of the
// TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup struct. The keys of the list are populated from the input
// arguments.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup) NewRiskCharacteristic(RiskCharacteristicName string) (*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_RiskCharacteristic, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.RiskCharacteristic == nil {
t.RiskCharacteristic = make(map[string]*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_RiskCharacteristic)
}
key := RiskCharacteristicName
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.RiskCharacteristic[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list RiskCharacteristic", key)
}
t.RiskCharacteristic[key] = &TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_RiskCharacteristic{
RiskCharacteristicName: &RiskCharacteristicName,
}
return t.RiskCharacteristic[key], nil
}
// NewRule creates a new entry in the Rule list of the
// TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup struct. The keys of the list are populated from the input
// arguments.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup) NewRule(LocalId string) (*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_Rule, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.Rule == nil {
t.Rule = make(map[string]*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_Rule)
}
key := LocalId
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.Rule[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list Rule", key)
}
t.Rule[key] = &TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_Rule{
LocalId: &LocalId,
}
return t.Rule[key], nil
}
// ΛListKeyMap returns the keys of the TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup struct, which is a YANG list entry.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup) ΛListKeyMap() (map[string]interface{}, error) {
if t.Uuid == nil {
return nil, fmt.Errorf("nil value for key Uuid")
}
return map[string]interface{}{
"uuid": *t.Uuid,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_AvailableCapacity represents the /tapi-common/context/topology-context/topology/node/node-rule-group/available-capacity YANG schema element.
type TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_AvailableCapacity struct {
TotalSize *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_AvailableCapacity_TotalSize `path:"total-size" module:"tapi-topology"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_AvailableCapacity implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_AvailableCapacity) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_AvailableCapacity) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_AvailableCapacity"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_AvailableCapacity) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_AvailableCapacity_TotalSize represents the /tapi-common/context/topology-context/topology/node/node-rule-group/available-capacity/total-size YANG schema element.
type TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_AvailableCapacity_TotalSize struct {
Unit E_TapiCommon_CapacityUnit `path:"unit" module:"tapi-topology"`
Value *uint64 `path:"value" module:"tapi-topology"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_AvailableCapacity_TotalSize implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_AvailableCapacity_TotalSize) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_AvailableCapacity_TotalSize) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_AvailableCapacity_TotalSize"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_AvailableCapacity_TotalSize) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_ComposedRuleGroup represents the /tapi-common/context/topology-context/topology/node/node-rule-group/composed-rule-group YANG schema element.
type TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_ComposedRuleGroup struct {
NodeRuleGroupUuid *string `path:"node-rule-group-uuid" module:"tapi-topology"`
NodeUuid *string `path:"node-uuid" module:"tapi-topology"`
TopologyUuid *string `path:"topology-uuid" module:"tapi-topology"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_ComposedRuleGroup implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_ComposedRuleGroup) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_ComposedRuleGroup struct, which is a YANG list entry.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_ComposedRuleGroup) ΛListKeyMap() (map[string]interface{}, error) {
if t.NodeRuleGroupUuid == nil {
return nil, fmt.Errorf("nil value for key NodeRuleGroupUuid")
}
if t.NodeUuid == nil {
return nil, fmt.Errorf("nil value for key NodeUuid")
}
if t.TopologyUuid == nil {
return nil, fmt.Errorf("nil value for key TopologyUuid")
}
return map[string]interface{}{
"node-rule-group-uuid": *t.NodeRuleGroupUuid,
"node-uuid": *t.NodeUuid,
"topology-uuid": *t.TopologyUuid,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_ComposedRuleGroup) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_ComposedRuleGroup"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_ComposedRuleGroup) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_CostCharacteristic represents the /tapi-common/context/topology-context/topology/node/node-rule-group/cost-characteristic YANG schema element.
type TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_CostCharacteristic struct {
CostAlgorithm *string `path:"cost-algorithm" module:"tapi-topology"`
CostName *string `path:"cost-name" module:"tapi-topology"`
CostValue *string `path:"cost-value" module:"tapi-topology"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_CostCharacteristic implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_CostCharacteristic) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_CostCharacteristic struct, which is a YANG list entry.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_CostCharacteristic) ΛListKeyMap() (map[string]interface{}, error) {
if t.CostName == nil {
return nil, fmt.Errorf("nil value for key CostName")
}
return map[string]interface{}{
"cost-name": *t.CostName,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_CostCharacteristic) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_CostCharacteristic"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_CostCharacteristic) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup represents the /tapi-common/context/topology-context/topology/node/node-rule-group/inter-rule-group YANG schema element.
type TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup struct {
AssociatedNodeRuleGroup map[TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_AssociatedNodeRuleGroup_Key]*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_AssociatedNodeRuleGroup `path:"associated-node-rule-group" module:"tapi-topology"`
AvailableCapacity *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_AvailableCapacity `path:"available-capacity" module:"tapi-topology"`
CostCharacteristic map[string]*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_CostCharacteristic `path:"cost-characteristic" module:"tapi-topology"`
LatencyCharacteristic map[string]*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_LatencyCharacteristic `path:"latency-characteristic" module:"tapi-topology"`
Name map[string]*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_Name `path:"name" module:"tapi-topology"`
RiskCharacteristic map[string]*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_RiskCharacteristic `path:"risk-characteristic" module:"tapi-topology"`
Rule map[string]*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_Rule `path:"rule" module:"tapi-topology"`
TotalPotentialCapacity *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_TotalPotentialCapacity `path:"total-potential-capacity" module:"tapi-topology"`
Uuid *string `path:"uuid" module:"tapi-topology"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup) IsYANGGoStruct() {}
// TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_AssociatedNodeRuleGroup_Key represents the key for list AssociatedNodeRuleGroup of element /tapi-common/context/topology-context/topology/node/node-rule-group/inter-rule-group.
type TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_AssociatedNodeRuleGroup_Key struct {
TopologyUuid string `path:"topology-uuid"`
NodeUuid string `path:"node-uuid"`
NodeRuleGroupUuid string `path:"node-rule-group-uuid"`
}
// NewAssociatedNodeRuleGroup creates a new entry in the AssociatedNodeRuleGroup list of the
// TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup struct. The keys of the list are populated from the input
// arguments.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup) NewAssociatedNodeRuleGroup(TopologyUuid string, NodeUuid string, NodeRuleGroupUuid string) (*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_AssociatedNodeRuleGroup, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.AssociatedNodeRuleGroup == nil {
t.AssociatedNodeRuleGroup = make(map[TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_AssociatedNodeRuleGroup_Key]*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_AssociatedNodeRuleGroup)
}
key := TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_AssociatedNodeRuleGroup_Key{
TopologyUuid: TopologyUuid,
NodeUuid: NodeUuid,
NodeRuleGroupUuid: NodeRuleGroupUuid,
}
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.AssociatedNodeRuleGroup[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list AssociatedNodeRuleGroup", key)
}
t.AssociatedNodeRuleGroup[key] = &TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_AssociatedNodeRuleGroup{
TopologyUuid: &TopologyUuid,
NodeUuid: &NodeUuid,
NodeRuleGroupUuid: &NodeRuleGroupUuid,
}
return t.AssociatedNodeRuleGroup[key], nil
}
// NewCostCharacteristic creates a new entry in the CostCharacteristic list of the
// TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup struct. The keys of the list are populated from the input
// arguments.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup) NewCostCharacteristic(CostName string) (*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_CostCharacteristic, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.CostCharacteristic == nil {
t.CostCharacteristic = make(map[string]*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_CostCharacteristic)
}
key := CostName
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.CostCharacteristic[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list CostCharacteristic", key)
}
t.CostCharacteristic[key] = &TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_CostCharacteristic{
CostName: &CostName,
}
return t.CostCharacteristic[key], nil
}
// NewLatencyCharacteristic creates a new entry in the LatencyCharacteristic list of the
// TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup struct. The keys of the list are populated from the input
// arguments.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup) NewLatencyCharacteristic(TrafficPropertyName string) (*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_LatencyCharacteristic, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.LatencyCharacteristic == nil {
t.LatencyCharacteristic = make(map[string]*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_LatencyCharacteristic)
}
key := TrafficPropertyName
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.LatencyCharacteristic[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list LatencyCharacteristic", key)
}
t.LatencyCharacteristic[key] = &TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_LatencyCharacteristic{
TrafficPropertyName: &TrafficPropertyName,
}
return t.LatencyCharacteristic[key], nil
}
// NewName creates a new entry in the Name list of the
// TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup struct. The keys of the list are populated from the input
// arguments.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup) NewName(ValueName string) (*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_Name, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.Name == nil {
t.Name = make(map[string]*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_Name)
}
key := ValueName
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.Name[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list Name", key)
}
t.Name[key] = &TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_Name{
ValueName: &ValueName,
}
return t.Name[key], nil
}
// NewRiskCharacteristic creates a new entry in the RiskCharacteristic list of the
// TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup struct. The keys of the list are populated from the input
// arguments.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup) NewRiskCharacteristic(RiskCharacteristicName string) (*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_RiskCharacteristic, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.RiskCharacteristic == nil {
t.RiskCharacteristic = make(map[string]*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_RiskCharacteristic)
}
key := RiskCharacteristicName
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.RiskCharacteristic[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list RiskCharacteristic", key)
}
t.RiskCharacteristic[key] = &TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_RiskCharacteristic{
RiskCharacteristicName: &RiskCharacteristicName,
}
return t.RiskCharacteristic[key], nil
}
// NewRule creates a new entry in the Rule list of the
// TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup struct. The keys of the list are populated from the input
// arguments.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup) NewRule(LocalId string) (*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_Rule, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.Rule == nil {
t.Rule = make(map[string]*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_Rule)
}
key := LocalId
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.Rule[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list Rule", key)
}
t.Rule[key] = &TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_Rule{
LocalId: &LocalId,
}
return t.Rule[key], nil
}
// ΛListKeyMap returns the keys of the TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup struct, which is a YANG list entry.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup) ΛListKeyMap() (map[string]interface{}, error) {
if t.Uuid == nil {
return nil, fmt.Errorf("nil value for key Uuid")
}
return map[string]interface{}{
"uuid": *t.Uuid,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_AssociatedNodeRuleGroup represents the /tapi-common/context/topology-context/topology/node/node-rule-group/inter-rule-group/associated-node-rule-group YANG schema element.
type TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_AssociatedNodeRuleGroup struct {
NodeRuleGroupUuid *string `path:"node-rule-group-uuid" module:"tapi-topology"`
NodeUuid *string `path:"node-uuid" module:"tapi-topology"`
TopologyUuid *string `path:"topology-uuid" module:"tapi-topology"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_AssociatedNodeRuleGroup implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_AssociatedNodeRuleGroup) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_AssociatedNodeRuleGroup struct, which is a YANG list entry.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_AssociatedNodeRuleGroup) ΛListKeyMap() (map[string]interface{}, error) {
if t.NodeRuleGroupUuid == nil {
return nil, fmt.Errorf("nil value for key NodeRuleGroupUuid")
if t.NodeUuid == nil {
return nil, fmt.Errorf("nil value for key NodeUuid")
if t.TopologyUuid == nil {
return nil, fmt.Errorf("nil value for key TopologyUuid")
return map[string]interface{}{
"node-rule-group-uuid": *t.NodeRuleGroupUuid,
"node-uuid": *t.NodeUuid,
"topology-uuid": *t.TopologyUuid,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_AssociatedNodeRuleGroup) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_AssociatedNodeRuleGroup"], t, opts...); err != nil {
return err
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_AssociatedNodeRuleGroup) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_AvailableCapacity represents the /tapi-common/context/topology-context/topology/node/node-rule-group/inter-rule-group/available-capacity YANG schema element.
type TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_AvailableCapacity struct {
TotalSize *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_AvailableCapacity_TotalSize `path:"total-size" module:"tapi-topology"`
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_AvailableCapacity implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_AvailableCapacity) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_AvailableCapacity) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_AvailableCapacity"], t, opts...); err != nil {
return err
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_AvailableCapacity) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_AvailableCapacity_TotalSize represents the /tapi-common/context/topology-context/topology/node/node-rule-group/inter-rule-group/available-capacity/total-size YANG schema element.
type TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_AvailableCapacity_TotalSize struct {
Unit E_TapiCommon_CapacityUnit `path:"unit" module:"tapi-topology"`
Value *uint64 `path:"value" module:"tapi-topology"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_AvailableCapacity_TotalSize implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_AvailableCapacity_TotalSize) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_AvailableCapacity_TotalSize) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_AvailableCapacity_TotalSize"], t, opts...); err != nil {
return err
8951
8952
8953
8954
8955
8956
8957
8958
8959
8960
8961
8962
8963
8964
8965
8966
8967
8968
8969
8970
8971
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_AvailableCapacity_TotalSize) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_CostCharacteristic represents the /tapi-common/context/topology-context/topology/node/node-rule-group/inter-rule-group/cost-characteristic YANG schema element.
type TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_CostCharacteristic struct {
CostAlgorithm *string `path:"cost-algorithm" module:"tapi-topology"`
CostName *string `path:"cost-name" module:"tapi-topology"`
CostValue *string `path:"cost-value" module:"tapi-topology"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_CostCharacteristic implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_CostCharacteristic) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_CostCharacteristic struct, which is a YANG list entry.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_CostCharacteristic) ΛListKeyMap() (map[string]interface{}, error) {
if t.CostName == nil {
return nil, fmt.Errorf("nil value for key CostName")
8974
8975
8976
8977
8978
8979
8980
8981
8982
8983
8984
8985
8986
8987
8988
8989
8990
8991
8992
8993
8994
8995
8996
8997
8998
8999
9000
9001
9002
9003
9004
9005
9006
9007
9008
9009
9010
9011
9012
9013
9014
9015
9016
9017
9018
9019
9020
9021
9022
9023
9024
9025
9026
9027
9028
9029
9030
9031
9032
9033
9034
9035
9036
9037
9038
9039
9040
9041
9042
9043
9044
9045
9046
9047
9048
9049
9050
9051
9052
9053
9054
9055
9056
9057
9058
9059
9060
9061
9062
9063
9064
9065
9066
9067
9068
9069
9070
9071
9072
9073
9074
9075
9076
9077
9078
9079
9080
9081
9082
9083
9084
9085
9086
9087
9088
9089
9090
9091
9092
9093
9094
9095
9096
9097
9098
9099
9100
9101
9102
9103
9104
9105
9106
9107
9108
9109
9110
9111
9112
return map[string]interface{}{
"cost-name": *t.CostName,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_CostCharacteristic) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_CostCharacteristic"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_CostCharacteristic) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_LatencyCharacteristic represents the /tapi-common/context/topology-context/topology/node/node-rule-group/inter-rule-group/latency-characteristic YANG schema element.
type TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_LatencyCharacteristic struct {
FixedLatencyCharacteristic *string `path:"fixed-latency-characteristic" module:"tapi-topology"`
JitterCharacteristic *string `path:"jitter-characteristic" module:"tapi-topology"`
QueingLatencyCharacteristic *string `path:"queing-latency-characteristic" module:"tapi-topology"`
TrafficPropertyName *string `path:"traffic-property-name" module:"tapi-topology"`
WanderCharacteristic *string `path:"wander-characteristic" module:"tapi-topology"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_LatencyCharacteristic implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_LatencyCharacteristic) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_LatencyCharacteristic struct, which is a YANG list entry.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_LatencyCharacteristic) ΛListKeyMap() (map[string]interface{}, error) {
if t.TrafficPropertyName == nil {
return nil, fmt.Errorf("nil value for key TrafficPropertyName")
}
return map[string]interface{}{
"traffic-property-name": *t.TrafficPropertyName,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_LatencyCharacteristic) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_LatencyCharacteristic"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_LatencyCharacteristic) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_Name represents the /tapi-common/context/topology-context/topology/node/node-rule-group/inter-rule-group/name YANG schema element.
type TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_Name struct {
Value *string `path:"value" module:"tapi-topology"`
ValueName *string `path:"value-name" module:"tapi-topology"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_Name implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_Name) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_Name struct, which is a YANG list entry.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_Name) ΛListKeyMap() (map[string]interface{}, error) {
if t.ValueName == nil {
return nil, fmt.Errorf("nil value for key ValueName")
}
return map[string]interface{}{
"value-name": *t.ValueName,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_Name) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_Name"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_Name) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_RiskCharacteristic represents the /tapi-common/context/topology-context/topology/node/node-rule-group/inter-rule-group/risk-characteristic YANG schema element.
type TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_RiskCharacteristic struct {
RiskCharacteristicName *string `path:"risk-characteristic-name" module:"tapi-topology"`
RiskIdentifierList []string `path:"risk-identifier-list" module:"tapi-topology"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_RiskCharacteristic implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_RiskCharacteristic) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_RiskCharacteristic struct, which is a YANG list entry.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_RiskCharacteristic) ΛListKeyMap() (map[string]interface{}, error) {
if t.RiskCharacteristicName == nil {
return nil, fmt.Errorf("nil value for key RiskCharacteristicName")
}
return map[string]interface{}{
"risk-characteristic-name": *t.RiskCharacteristicName,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_RiskCharacteristic) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_RiskCharacteristic"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_RiskCharacteristic) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_Rule represents the /tapi-common/context/topology-context/topology/node/node-rule-group/inter-rule-group/rule YANG schema element.
type TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_Rule struct {
CepDirection []E_TapiTopology_PortDirection `path:"cep-direction" module:"tapi-topology"`
CepPortRole []*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_Rule_CepPortRole `path:"cep-port-role" module:"tapi-topology"`
ComplexRule []string `path:"complex-rule" module:"tapi-topology"`
ConnectionSpecReference []*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_Rule_ConnectionSpecReference `path:"connection-spec-reference" module:"tapi-topology"`
ForwardingRule E_TapiTopology_ForwardingRule `path:"forwarding-rule" module:"tapi-topology"`
LayerProtocolQualifier []E_TapiTopology_LayerProtocolQualifier `path:"layer-protocol-qualifier" module:"tapi-topology"`
LocalId *string `path:"local-id" module:"tapi-topology"`
Name map[string]*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_Rule_Name `path:"name" module:"tapi-topology"`
OverridePriority *uint64 `path:"override-priority" module:"tapi-topology"`
RuleType E_TapiTopology_RuleType `path:"rule-type" module:"tapi-topology"`
SignalProperty *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_Rule_SignalProperty `path:"signal-property" module:"tapi-topology"`
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_Rule implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_Rule) IsYANGGoStruct() {}
// NewName creates a new entry in the Name list of the
// TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_Rule struct. The keys of the list are populated from the input
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_Rule) NewName(ValueName string) (*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_Rule_Name, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.Name == nil {
t.Name = make(map[string]*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_Rule_Name)
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.Name[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list Name", key)
t.Name[key] = &TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_Rule_Name{
ValueName: &ValueName,
// ΛListKeyMap returns the keys of the TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_Rule struct, which is a YANG list entry.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_Rule) ΛListKeyMap() (map[string]interface{}, error) {
if t.LocalId == nil {
return nil, fmt.Errorf("nil value for key LocalId")
}
return map[string]interface{}{
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_Rule) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_Rule"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_Rule) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_Rule_CepPortRole represents the /tapi-common/context/topology-context/topology/node/node-rule-group/inter-rule-group/rule/cep-port-role YANG schema element.
type TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_Rule_CepPortRole struct {
PortRole []string `path:"port-role" module:"tapi-topology"`
PortRoleRule []E_TapiTopology_PortRoleRuleOption `path:"port-role-rule" module:"tapi-topology"`
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_Rule_CepPortRole implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_Rule_CepPortRole) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_Rule_CepPortRole) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_Rule_CepPortRole"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_Rule_CepPortRole) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_Rule_ConnectionSpecReference represents the /tapi-common/context/topology-context/topology/node/node-rule-group/inter-rule-group/rule/connection-spec-reference YANG schema element.
type TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_Rule_ConnectionSpecReference struct {
ConnectionSpec *string `path:"connection-spec" module:"tapi-topology"`
ConnectionSpecName *string `path:"connection-spec-name" module:"tapi-topology"`
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_Rule_ConnectionSpecReference implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_Rule_ConnectionSpecReference) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_Rule_ConnectionSpecReference) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_Rule_ConnectionSpecReference"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_Rule_ConnectionSpecReference) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_Rule_Name represents the /tapi-common/context/topology-context/topology/node/node-rule-group/inter-rule-group/rule/name YANG schema element.
type TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_Rule_Name struct {
Value *string `path:"value" module:"tapi-topology"`
ValueName *string `path:"value-name" module:"tapi-topology"`
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_Rule_Name implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_Rule_Name) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_Rule_Name struct, which is a YANG list entry.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_Rule_Name) ΛListKeyMap() (map[string]interface{}, error) {
if t.ValueName == nil {
return nil, fmt.Errorf("nil value for key ValueName")
}
return map[string]interface{}{
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_Rule_Name) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_Rule_Name"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_Rule_Name) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_Rule_SignalProperty represents the /tapi-common/context/topology-context/topology/node/node-rule-group/inter-rule-group/rule/signal-property YANG schema element.
type TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_Rule_SignalProperty struct {
ApplicableSignalValue []string `path:"applicable-signal-value" module:"tapi-topology"`
NumberOfSignalValues *uint64 `path:"number-of-signal-values" module:"tapi-topology"`
SignalPropertyName *string `path:"signal-property-name" module:"tapi-topology"`
SignalPropertyValueRule E_TapiTopology_SignalPropertyValueRule `path:"signal-property-value-rule" module:"tapi-topology"`
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_Rule_SignalProperty implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_Rule_SignalProperty) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_Rule_SignalProperty) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_Rule_SignalProperty"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_Rule_SignalProperty) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_TotalPotentialCapacity represents the /tapi-common/context/topology-context/topology/node/node-rule-group/inter-rule-group/total-potential-capacity YANG schema element.
type TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_TotalPotentialCapacity struct {
TotalSize *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_TotalPotentialCapacity_TotalSize `path:"total-size" module:"tapi-topology"`
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_TotalPotentialCapacity implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_TotalPotentialCapacity) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_TotalPotentialCapacity) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_TotalPotentialCapacity"], t, opts...); err != nil {
return err
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_TotalPotentialCapacity) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_TotalPotentialCapacity_TotalSize represents the /tapi-common/context/topology-context/topology/node/node-rule-group/inter-rule-group/total-potential-capacity/total-size YANG schema element.
type TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_TotalPotentialCapacity_TotalSize struct {
Unit E_TapiCommon_CapacityUnit `path:"unit" module:"tapi-topology"`
Value *uint64 `path:"value" module:"tapi-topology"`
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_TotalPotentialCapacity_TotalSize implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_TotalPotentialCapacity_TotalSize) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_TotalPotentialCapacity_TotalSize) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_TotalPotentialCapacity_TotalSize"], t, opts...); err != nil {
return err
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_InterRuleGroup_TotalPotentialCapacity_TotalSize) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_LatencyCharacteristic represents the /tapi-common/context/topology-context/topology/node/node-rule-group/latency-characteristic YANG schema element.
type TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_LatencyCharacteristic struct {
FixedLatencyCharacteristic *string `path:"fixed-latency-characteristic" module:"tapi-topology"`
JitterCharacteristic *string `path:"jitter-characteristic" module:"tapi-topology"`
QueingLatencyCharacteristic *string `path:"queing-latency-characteristic" module:"tapi-topology"`
TrafficPropertyName *string `path:"traffic-property-name" module:"tapi-topology"`
WanderCharacteristic *string `path:"wander-characteristic" module:"tapi-topology"`
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_LatencyCharacteristic implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_LatencyCharacteristic) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_LatencyCharacteristic struct, which is a YANG list entry.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_LatencyCharacteristic) ΛListKeyMap() (map[string]interface{}, error) {
if t.TrafficPropertyName == nil {
return nil, fmt.Errorf("nil value for key TrafficPropertyName")
return map[string]interface{}{
"traffic-property-name": *t.TrafficPropertyName,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_LatencyCharacteristic) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_LatencyCharacteristic"], t, opts...); err != nil {
return err
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_LatencyCharacteristic) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_Name represents the /tapi-common/context/topology-context/topology/node/node-rule-group/name YANG schema element.
type TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_Name struct {
Value *string `path:"value" module:"tapi-topology"`
ValueName *string `path:"value-name" module:"tapi-topology"`
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_Name implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_Name) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_Name struct, which is a YANG list entry.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_Name) ΛListKeyMap() (map[string]interface{}, error) {
if t.ValueName == nil {
return nil, fmt.Errorf("nil value for key ValueName")
return map[string]interface{}{
"value-name": *t.ValueName,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_Name) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_Name"], t, opts...); err != nil {
return err
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_Name) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_NodeEdgePoint represents the /tapi-common/context/topology-context/topology/node/node-rule-group/node-edge-point YANG schema element.
type TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_NodeEdgePoint struct {
NodeEdgePointUuid *string `path:"node-edge-point-uuid" module:"tapi-topology"`
NodeUuid *string `path:"node-uuid" module:"tapi-topology"`
TopologyUuid *string `path:"topology-uuid" module:"tapi-topology"`
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_NodeEdgePoint implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_NodeEdgePoint) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_NodeEdgePoint struct, which is a YANG list entry.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_NodeEdgePoint) ΛListKeyMap() (map[string]interface{}, error) {
if t.NodeEdgePointUuid == nil {
return nil, fmt.Errorf("nil value for key NodeEdgePointUuid")
if t.NodeUuid == nil {
return nil, fmt.Errorf("nil value for key NodeUuid")
if t.TopologyUuid == nil {
return nil, fmt.Errorf("nil value for key TopologyUuid")
return map[string]interface{}{
"node-edge-point-uuid": *t.NodeEdgePointUuid,
"node-uuid": *t.NodeUuid,
"topology-uuid": *t.TopologyUuid,
}, nil
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_NodeEdgePoint) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_NodeEdgePoint"], t, opts...); err != nil {
return err
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_NodeEdgePoint) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_RiskCharacteristic represents the /tapi-common/context/topology-context/topology/node/node-rule-group/risk-characteristic YANG schema element.
type TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_RiskCharacteristic struct {
RiskCharacteristicName *string `path:"risk-characteristic-name" module:"tapi-topology"`
RiskIdentifierList []string `path:"risk-identifier-list" module:"tapi-topology"`
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_RiskCharacteristic implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_RiskCharacteristic) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_RiskCharacteristic struct, which is a YANG list entry.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_RiskCharacteristic) ΛListKeyMap() (map[string]interface{}, error) {
if t.RiskCharacteristicName == nil {
return nil, fmt.Errorf("nil value for key RiskCharacteristicName")
}
return map[string]interface{}{
"risk-characteristic-name": *t.RiskCharacteristicName,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_RiskCharacteristic) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_RiskCharacteristic"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_RiskCharacteristic) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_Rule represents the /tapi-common/context/topology-context/topology/node/node-rule-group/rule YANG schema element.
type TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_Rule struct {
CepDirection []E_TapiTopology_PortDirection `path:"cep-direction" module:"tapi-topology"`
CepPortRole []*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_Rule_CepPortRole `path:"cep-port-role" module:"tapi-topology"`
ComplexRule []string `path:"complex-rule" module:"tapi-topology"`
ConnectionSpecReference []*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_Rule_ConnectionSpecReference `path:"connection-spec-reference" module:"tapi-topology"`
ForwardingRule E_TapiTopology_ForwardingRule `path:"forwarding-rule" module:"tapi-topology"`
LayerProtocolQualifier []E_TapiTopology_LayerProtocolQualifier `path:"layer-protocol-qualifier" module:"tapi-topology"`
LocalId *string `path:"local-id" module:"tapi-topology"`
Name map[string]*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_Rule_Name `path:"name" module:"tapi-topology"`
OverridePriority *uint64 `path:"override-priority" module:"tapi-topology"`
RuleType E_TapiTopology_RuleType `path:"rule-type" module:"tapi-topology"`
SignalProperty *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_Rule_SignalProperty `path:"signal-property" module:"tapi-topology"`
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_Rule implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_Rule) IsYANGGoStruct() {}
// NewName creates a new entry in the Name list of the
// TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_Rule struct. The keys of the list are populated from the input
// arguments.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_Rule) NewName(ValueName string) (*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_Rule_Name, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.Name == nil {
t.Name = make(map[string]*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_Rule_Name)
key := ValueName
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.Name[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list Name", key)
t.Name[key] = &TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_Rule_Name{
ValueName: &ValueName,
}
return t.Name[key], nil
}
// ΛListKeyMap returns the keys of the TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_Rule struct, which is a YANG list entry.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_Rule) ΛListKeyMap() (map[string]interface{}, error) {
if t.LocalId == nil {
return nil, fmt.Errorf("nil value for key LocalId")
}
return map[string]interface{}{
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_Rule) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_Rule"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_Rule) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_Rule_CepPortRole represents the /tapi-common/context/topology-context/topology/node/node-rule-group/rule/cep-port-role YANG schema element.
type TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_Rule_CepPortRole struct {
PortRole []string `path:"port-role" module:"tapi-topology"`
PortRoleRule []E_TapiTopology_PortRoleRuleOption `path:"port-role-rule" module:"tapi-topology"`
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_Rule_CepPortRole implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_Rule_CepPortRole) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_Rule_CepPortRole) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_Rule_CepPortRole"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_Rule_CepPortRole) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_Rule_ConnectionSpecReference represents the /tapi-common/context/topology-context/topology/node/node-rule-group/rule/connection-spec-reference YANG schema element.
type TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_Rule_ConnectionSpecReference struct {
ConnectionSpec *string `path:"connection-spec" module:"tapi-topology"`
ConnectionSpecName *string `path:"connection-spec-name" module:"tapi-topology"`
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_Rule_ConnectionSpecReference implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_Rule_ConnectionSpecReference) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_Rule_ConnectionSpecReference) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_Rule_ConnectionSpecReference"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_Rule_ConnectionSpecReference) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_Rule_Name represents the /tapi-common/context/topology-context/topology/node/node-rule-group/rule/name YANG schema element.
type TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_Rule_Name struct {
Value *string `path:"value" module:"tapi-topology"`
ValueName *string `path:"value-name" module:"tapi-topology"`
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_Rule_Name implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_Rule_Name) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_Rule_Name struct, which is a YANG list entry.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_Rule_Name) ΛListKeyMap() (map[string]interface{}, error) {
if t.ValueName == nil {
return nil, fmt.Errorf("nil value for key ValueName")
}
return map[string]interface{}{
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_Rule_Name) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_Rule_Name"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_Rule_Name) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_Rule_SignalProperty represents the /tapi-common/context/topology-context/topology/node/node-rule-group/rule/signal-property YANG schema element.
type TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_Rule_SignalProperty struct {
ApplicableSignalValue []string `path:"applicable-signal-value" module:"tapi-topology"`
NumberOfSignalValues *uint64 `path:"number-of-signal-values" module:"tapi-topology"`
SignalPropertyName *string `path:"signal-property-name" module:"tapi-topology"`
SignalPropertyValueRule E_TapiTopology_SignalPropertyValueRule `path:"signal-property-value-rule" module:"tapi-topology"`
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_Rule_SignalProperty implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_Rule_SignalProperty) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_Rule_SignalProperty) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_Rule_SignalProperty"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_Rule_SignalProperty) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_TotalPotentialCapacity represents the /tapi-common/context/topology-context/topology/node/node-rule-group/total-potential-capacity YANG schema element.
type TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_TotalPotentialCapacity struct {
TotalSize *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_TotalPotentialCapacity_TotalSize `path:"total-size" module:"tapi-topology"`
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_TotalPotentialCapacity implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_TotalPotentialCapacity) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_TotalPotentialCapacity) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_TotalPotentialCapacity"], t, opts...); err != nil {
return err
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_TotalPotentialCapacity) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_TotalPotentialCapacity_TotalSize represents the /tapi-common/context/topology-context/topology/node/node-rule-group/total-potential-capacity/total-size YANG schema element.
type TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_TotalPotentialCapacity_TotalSize struct {
Unit E_TapiCommon_CapacityUnit `path:"unit" module:"tapi-topology"`
Value *uint64 `path:"value" module:"tapi-topology"`
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_TotalPotentialCapacity_TotalSize implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_TotalPotentialCapacity_TotalSize) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_TotalPotentialCapacity_TotalSize) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_TotalPotentialCapacity_TotalSize"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_NodeRuleGroup_TotalPotentialCapacity_TotalSize) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint represents the /tapi-common/context/topology-context/topology/node/owned-node-edge-point YANG schema element.
type TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint struct {
AdministrativeState E_TapiCommon_AdministrativeState `path:"administrative-state" module:"tapi-topology"`
AggregatedNodeEdgePoint map[TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_AggregatedNodeEdgePoint_Key]*TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_AggregatedNodeEdgePoint `path:"aggregated-node-edge-point" module:"tapi-topology"`
AvailableCapacity *TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_AvailableCapacity `path:"available-capacity" module:"tapi-topology"`
AvailableCepLayerProtocol map[E_TapiTopology_LayerProtocolQualifier]*TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_AvailableCepLayerProtocol `path:"available-cep-layer-protocol" module:"tapi-topology"`
CepList *TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList `path:"cep-list" module:"tapi-connectivity"`
LayerProtocolName E_TapiTopology_LayerProtocolName `path:"layer-protocol-name" module:"tapi-topology"`
LifecycleState E_TapiCommon_LifecycleState `path:"lifecycle-state" module:"tapi-topology"`
LinkPortDirection E_TapiTopology_PortDirection `path:"link-port-direction" module:"tapi-topology"`
LinkPortRole E_TapiTopology_PortRole `path:"link-port-role" module:"tapi-topology"`
MappedServiceInterfacePoint map[string]*TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_MappedServiceInterfacePoint `path:"mapped-service-interface-point" module:"tapi-topology"`
MediaChannelNodeEdgePointSpec *TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_MediaChannelNodeEdgePointSpec `path:"media-channel-node-edge-point-spec" module:"tapi-photonic-media"`
Name map[string]*TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_Name `path:"name" module:"tapi-topology"`
OperationalState E_TapiCommon_OperationalState `path:"operational-state" module:"tapi-topology"`
TerminationDirection E_TapiCommon_TerminationDirection `path:"termination-direction" module:"tapi-topology"`
TerminationState E_TapiCommon_TerminationState `path:"termination-state" module:"tapi-topology"`
TotalPotentialCapacity *TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_TotalPotentialCapacity `path:"total-potential-capacity" module:"tapi-topology"`
Uuid *string `path:"uuid" module:"tapi-topology"`
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint) IsYANGGoStruct() {}
// TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_AggregatedNodeEdgePoint_Key represents the key for list AggregatedNodeEdgePoint of element /tapi-common/context/topology-context/topology/node/owned-node-edge-point.
type TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_AggregatedNodeEdgePoint_Key struct {
TopologyUuid string `path:"topology-uuid"`
NodeUuid string `path:"node-uuid"`
NodeEdgePointUuid string `path:"node-edge-point-uuid"`
}
// NewAggregatedNodeEdgePoint creates a new entry in the AggregatedNodeEdgePoint list of the
// TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint struct. The keys of the list are populated from the input
// arguments.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint) NewAggregatedNodeEdgePoint(TopologyUuid string, NodeUuid string, NodeEdgePointUuid string) (*TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_AggregatedNodeEdgePoint, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.AggregatedNodeEdgePoint == nil {
t.AggregatedNodeEdgePoint = make(map[TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_AggregatedNodeEdgePoint_Key]*TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_AggregatedNodeEdgePoint)
key := TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_AggregatedNodeEdgePoint_Key{
TopologyUuid: TopologyUuid,
NodeUuid: NodeUuid,
NodeEdgePointUuid: NodeEdgePointUuid,
}
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.AggregatedNodeEdgePoint[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list AggregatedNodeEdgePoint", key)
}
t.AggregatedNodeEdgePoint[key] = &TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_AggregatedNodeEdgePoint{
TopologyUuid: &TopologyUuid,
NodeUuid: &NodeUuid,
NodeEdgePointUuid: &NodeEdgePointUuid,
}
return t.AggregatedNodeEdgePoint[key], nil
// NewAvailableCepLayerProtocol creates a new entry in the AvailableCepLayerProtocol list of the
// TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint struct. The keys of the list are populated from the input
// arguments.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint) NewAvailableCepLayerProtocol(LayerProtocolQualifier E_TapiTopology_LayerProtocolQualifier) (*TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_AvailableCepLayerProtocol, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.AvailableCepLayerProtocol == nil {
t.AvailableCepLayerProtocol = make(map[E_TapiTopology_LayerProtocolQualifier]*TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_AvailableCepLayerProtocol)
key := LayerProtocolQualifier
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.AvailableCepLayerProtocol[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list AvailableCepLayerProtocol", key)
}
t.AvailableCepLayerProtocol[key] = &TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_AvailableCepLayerProtocol{
LayerProtocolQualifier: LayerProtocolQualifier,
}
return t.AvailableCepLayerProtocol[key], nil
// NewMappedServiceInterfacePoint creates a new entry in the MappedServiceInterfacePoint list of the
// TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint struct. The keys of the list are populated from the input
// arguments.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint) NewMappedServiceInterfacePoint(ServiceInterfacePointUuid string) (*TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_MappedServiceInterfacePoint, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.MappedServiceInterfacePoint == nil {
t.MappedServiceInterfacePoint = make(map[string]*TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_MappedServiceInterfacePoint)
}
key := ServiceInterfacePointUuid
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.MappedServiceInterfacePoint[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list MappedServiceInterfacePoint", key)
}
t.MappedServiceInterfacePoint[key] = &TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_MappedServiceInterfacePoint{
ServiceInterfacePointUuid: &ServiceInterfacePointUuid,
}
return t.MappedServiceInterfacePoint[key], nil
}
// NewName creates a new entry in the Name list of the
// TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint struct. The keys of the list are populated from the input
func (t *TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint) NewName(ValueName string) (*TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_Name, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.Name == nil {
t.Name = make(map[string]*TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_Name)
}
key := ValueName
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.Name[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list Name", key)
}
t.Name[key] = &TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_Name{
ValueName: &ValueName,
}
return t.Name[key], nil
}
// ΛListKeyMap returns the keys of the TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint struct, which is a YANG list entry.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint) ΛListKeyMap() (map[string]interface{}, error) {
if t.Uuid == nil {
return nil, fmt.Errorf("nil value for key Uuid")
}
return map[string]interface{}{
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_AggregatedNodeEdgePoint represents the /tapi-common/context/topology-context/topology/node/owned-node-edge-point/aggregated-node-edge-point YANG schema element.
type TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_AggregatedNodeEdgePoint struct {
NodeEdgePointUuid *string `path:"node-edge-point-uuid" module:"tapi-topology"`
NodeUuid *string `path:"node-uuid" module:"tapi-topology"`
TopologyUuid *string `path:"topology-uuid" module:"tapi-topology"`
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_AggregatedNodeEdgePoint implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
9889
9890
9891
9892
9893
9894
9895
9896
9897
9898
9899
9900
9901
9902
9903
9904
9905
9906
9907
9908
9909
9910
func (*TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_AggregatedNodeEdgePoint) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_AggregatedNodeEdgePoint struct, which is a YANG list entry.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_AggregatedNodeEdgePoint) ΛListKeyMap() (map[string]interface{}, error) {
if t.NodeEdgePointUuid == nil {
return nil, fmt.Errorf("nil value for key NodeEdgePointUuid")
}
if t.NodeUuid == nil {
return nil, fmt.Errorf("nil value for key NodeUuid")
}
if t.TopologyUuid == nil {
return nil, fmt.Errorf("nil value for key TopologyUuid")
}
return map[string]interface{}{
"node-edge-point-uuid": *t.NodeEdgePointUuid,
"node-uuid": *t.NodeUuid,
"topology-uuid": *t.TopologyUuid,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_AggregatedNodeEdgePoint) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_AggregatedNodeEdgePoint"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_AggregatedNodeEdgePoint) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_AvailableCapacity represents the /tapi-common/context/topology-context/topology/node/owned-node-edge-point/available-capacity YANG schema element.
type TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_AvailableCapacity struct {
TotalSize *TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_AvailableCapacity_TotalSize `path:"total-size" module:"tapi-topology"`
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_AvailableCapacity implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_AvailableCapacity) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_AvailableCapacity) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_AvailableCapacity"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_AvailableCapacity) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_AvailableCapacity_TotalSize represents the /tapi-common/context/topology-context/topology/node/owned-node-edge-point/available-capacity/total-size YANG schema element.
type TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_AvailableCapacity_TotalSize struct {
Unit E_TapiCommon_CapacityUnit `path:"unit" module:"tapi-topology"`
Value *uint64 `path:"value" module:"tapi-topology"`
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_AvailableCapacity_TotalSize implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_AvailableCapacity_TotalSize) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_AvailableCapacity_TotalSize) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_AvailableCapacity_TotalSize"], t, opts...); err != nil {
return err
9964
9965
9966
9967
9968
9969
9970
9971
9972
9973
9974
9975
9976
9977
9978
9979
9980
9981
9982
9983
9984
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_AvailableCapacity_TotalSize) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_AvailableCepLayerProtocol represents the /tapi-common/context/topology-context/topology/node/owned-node-edge-point/available-cep-layer-protocol YANG schema element.
type TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_AvailableCepLayerProtocol struct {
LayerProtocolQualifier E_TapiTopology_LayerProtocolQualifier `path:"layer-protocol-qualifier" module:"tapi-topology"`
NumberOfCepInstances *uint64 `path:"number-of-cep-instances" module:"tapi-topology"`
}
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_AvailableCepLayerProtocol implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_AvailableCepLayerProtocol) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_AvailableCepLayerProtocol struct, which is a YANG list entry.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_AvailableCepLayerProtocol) ΛListKeyMap() (map[string]interface{}, error) {
"layer-protocol-qualifier": t.LayerProtocolQualifier,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_AvailableCepLayerProtocol) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_AvailableCepLayerProtocol"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_AvailableCepLayerProtocol) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList represents the /tapi-common/context/topology-context/topology/node/owned-node-edge-point/cep-list YANG schema element.
type TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList struct {
ConnectionEndPoint map[string]*TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint `path:"connection-end-point" module:"tapi-connectivity"`
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
10012
10013
10014
10015
10016
10017
10018
10019
10020
10021
10022
10023
10024
10025
10026
10027
10028
10029
10030
10031
10032
10033
10034
10035
10036
10037
10038
10039
func (*TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList) IsYANGGoStruct() {}
// NewConnectionEndPoint creates a new entry in the ConnectionEndPoint list of the
// TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList struct. The keys of the list are populated from the input
// arguments.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList) NewConnectionEndPoint(Uuid string) (*TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.ConnectionEndPoint == nil {
t.ConnectionEndPoint = make(map[string]*TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint)
}
key := Uuid
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.ConnectionEndPoint[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list ConnectionEndPoint", key)
}
t.ConnectionEndPoint[key] = &TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint{
Uuid: &Uuid,
}
return t.ConnectionEndPoint[key], nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
10054
10055
10056
10057
10058
10059
10060
10061
10062
10063
10064
10065
10066
10067
10068
10069
10070
10071
10072
// TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint represents the /tapi-common/context/topology-context/topology/node/owned-node-edge-point/cep-list/connection-end-point YANG schema element.
type TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint struct {
AggregatedConnectionEndPoint map[TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_AggregatedConnectionEndPoint_Key]*TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_AggregatedConnectionEndPoint `path:"aggregated-connection-end-point" module:"tapi-connectivity"`
ClientNodeEdgePoint map[TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_ClientNodeEdgePoint_Key]*TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_ClientNodeEdgePoint `path:"client-node-edge-point" module:"tapi-connectivity"`
ConnectionPortDirection E_TapiConnectivity_PortDirection `path:"connection-port-direction" module:"tapi-connectivity"`
ConnectionPortRole E_TapiConnectivity_PortRole `path:"connection-port-role" module:"tapi-connectivity"`
LayerProtocolName E_TapiConnectivity_LayerProtocolName `path:"layer-protocol-name" module:"tapi-connectivity"`
LayerProtocolQualifier E_TapiConnectivity_LayerProtocolQualifier `path:"layer-protocol-qualifier" module:"tapi-connectivity"`
LifecycleState E_TapiCommon_LifecycleState `path:"lifecycle-state" module:"tapi-connectivity"`
MediaChannelConnectionEndPointSpec *TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_MediaChannelConnectionEndPointSpec `path:"media-channel-connection-end-point-spec" module:"tapi-photonic-media"`
Name map[string]*TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_Name `path:"name" module:"tapi-connectivity"`
OperationalState E_TapiCommon_OperationalState `path:"operational-state" module:"tapi-connectivity"`
OtsiAssemblyConnectionEndPointSpec *TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_OtsiAssemblyConnectionEndPointSpec `path:"otsi-assembly-connection-end-point-spec" module:"tapi-photonic-media"`
OtsiConnectionEndPointSpec *TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_OtsiConnectionEndPointSpec `path:"otsi-connection-end-point-spec" module:"tapi-photonic-media"`
ParentNodeEdgePoint *TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_ParentNodeEdgePoint `path:"parent-node-edge-point" module:"tapi-connectivity"`
ProtectionRole E_TapiConnectivity_ProtectionRole `path:"protection-role" module:"tapi-connectivity"`
TerminationDirection E_TapiCommon_TerminationDirection `path:"termination-direction" module:"tapi-connectivity"`
TerminationState E_TapiCommon_TerminationState `path:"termination-state" module:"tapi-connectivity"`
Uuid *string `path:"uuid" module:"tapi-connectivity"`
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint) IsYANGGoStruct() {}
10080
10081
10082
10083
10084
10085
10086
10087
10088
10089
10090
10091
10092
10093
10094
10095
10096
10097
10098
10099
10100
10101
10102
10103
10104
10105
10106
10107
10108
10109
10110
// TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_AggregatedConnectionEndPoint_Key represents the key for list AggregatedConnectionEndPoint of element /tapi-common/context/topology-context/topology/node/owned-node-edge-point/cep-list/connection-end-point.
type TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_AggregatedConnectionEndPoint_Key struct {
TopologyUuid string `path:"topology-uuid"`
NodeUuid string `path:"node-uuid"`
NodeEdgePointUuid string `path:"node-edge-point-uuid"`
ConnectionEndPointUuid string `path:"connection-end-point-uuid"`
}
// TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_ClientNodeEdgePoint_Key represents the key for list ClientNodeEdgePoint of element /tapi-common/context/topology-context/topology/node/owned-node-edge-point/cep-list/connection-end-point.
type TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_ClientNodeEdgePoint_Key struct {
TopologyUuid string `path:"topology-uuid"`
NodeUuid string `path:"node-uuid"`
NodeEdgePointUuid string `path:"node-edge-point-uuid"`
}
// NewAggregatedConnectionEndPoint creates a new entry in the AggregatedConnectionEndPoint list of the
// TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint struct. The keys of the list are populated from the input
// arguments.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint) NewAggregatedConnectionEndPoint(TopologyUuid string, NodeUuid string, NodeEdgePointUuid string, ConnectionEndPointUuid string) (*TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_AggregatedConnectionEndPoint, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.AggregatedConnectionEndPoint == nil {
t.AggregatedConnectionEndPoint = make(map[TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_AggregatedConnectionEndPoint_Key]*TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_AggregatedConnectionEndPoint)
}
key := TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_AggregatedConnectionEndPoint_Key{
TopologyUuid: TopologyUuid,
NodeUuid: NodeUuid,
NodeEdgePointUuid: NodeEdgePointUuid,
ConnectionEndPointUuid: ConnectionEndPointUuid,
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.AggregatedConnectionEndPoint[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list AggregatedConnectionEndPoint", key)
}
t.AggregatedConnectionEndPoint[key] = &TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_AggregatedConnectionEndPoint{
TopologyUuid: &TopologyUuid,
NodeUuid: &NodeUuid,
NodeEdgePointUuid: &NodeEdgePointUuid,
ConnectionEndPointUuid: &ConnectionEndPointUuid,
}
return t.AggregatedConnectionEndPoint[key], nil
// NewClientNodeEdgePoint creates a new entry in the ClientNodeEdgePoint list of the
// TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint struct. The keys of the list are populated from the input
// arguments.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint) NewClientNodeEdgePoint(TopologyUuid string, NodeUuid string, NodeEdgePointUuid string) (*TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_ClientNodeEdgePoint, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.ClientNodeEdgePoint == nil {
t.ClientNodeEdgePoint = make(map[TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_ClientNodeEdgePoint_Key]*TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_ClientNodeEdgePoint)
key := TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_ClientNodeEdgePoint_Key{
TopologyUuid: TopologyUuid,
NodeUuid: NodeUuid,
NodeEdgePointUuid: NodeEdgePointUuid,
}
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.ClientNodeEdgePoint[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list ClientNodeEdgePoint", key)
}
t.ClientNodeEdgePoint[key] = &TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_ClientNodeEdgePoint{
TopologyUuid: &TopologyUuid,
NodeUuid: &NodeUuid,
NodeEdgePointUuid: &NodeEdgePointUuid,
}
return t.ClientNodeEdgePoint[key], nil
// NewName creates a new entry in the Name list of the
// TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint struct. The keys of the list are populated from the input
// arguments.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint) NewName(ValueName string) (*TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_Name, error){
// Initialise the list within the receiver struct if it has not already been
// created.
if t.Name == nil {
t.Name = make(map[string]*TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_Name)
// Ensure that this key has not already been used in the
// list. Keyed YANG lists do not allow duplicate keys to
// be created.
if _, ok := t.Name[key]; ok {
return nil, fmt.Errorf("duplicate key %v for list Name", key)
t.Name[key] = &TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_Name{
ValueName: &ValueName,
}
// ΛListKeyMap returns the keys of the TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint struct, which is a YANG list entry.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint) ΛListKeyMap() (map[string]interface{}, error) {
if t.Uuid == nil {
return nil, fmt.Errorf("nil value for key Uuid")
}
return map[string]interface{}{
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_AggregatedConnectionEndPoint represents the /tapi-common/context/topology-context/topology/node/owned-node-edge-point/cep-list/connection-end-point/aggregated-connection-end-point YANG schema element.
type TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_AggregatedConnectionEndPoint struct {
ConnectionEndPointUuid *string `path:"connection-end-point-uuid" module:"tapi-connectivity"`
NodeEdgePointUuid *string `path:"node-edge-point-uuid" module:"tapi-connectivity"`
NodeUuid *string `path:"node-uuid" module:"tapi-connectivity"`
TopologyUuid *string `path:"topology-uuid" module:"tapi-connectivity"`
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_AggregatedConnectionEndPoint implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_AggregatedConnectionEndPoint) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_AggregatedConnectionEndPoint struct, which is a YANG list entry.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_AggregatedConnectionEndPoint) ΛListKeyMap() (map[string]interface{}, error) {
if t.ConnectionEndPointUuid == nil {
return nil, fmt.Errorf("nil value for key ConnectionEndPointUuid")
}
if t.NodeEdgePointUuid == nil {
return nil, fmt.Errorf("nil value for key NodeEdgePointUuid")
}
if t.NodeUuid == nil {
return nil, fmt.Errorf("nil value for key NodeUuid")
}
if t.TopologyUuid == nil {
return nil, fmt.Errorf("nil value for key TopologyUuid")
}
return map[string]interface{}{
"connection-end-point-uuid": *t.ConnectionEndPointUuid,
"node-edge-point-uuid": *t.NodeEdgePointUuid,
"node-uuid": *t.NodeUuid,
"topology-uuid": *t.TopologyUuid,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_AggregatedConnectionEndPoint) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_AggregatedConnectionEndPoint"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_AggregatedConnectionEndPoint) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_ClientNodeEdgePoint represents the /tapi-common/context/topology-context/topology/node/owned-node-edge-point/cep-list/connection-end-point/client-node-edge-point YANG schema element.
type TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_ClientNodeEdgePoint struct {
NodeEdgePointUuid *string `path:"node-edge-point-uuid" module:"tapi-connectivity"`
NodeUuid *string `path:"node-uuid" module:"tapi-connectivity"`
TopologyUuid *string `path:"topology-uuid" module:"tapi-connectivity"`
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_ClientNodeEdgePoint implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_ClientNodeEdgePoint) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_ClientNodeEdgePoint struct, which is a YANG list entry.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_ClientNodeEdgePoint) ΛListKeyMap() (map[string]interface{}, error) {
if t.NodeEdgePointUuid == nil {
return nil, fmt.Errorf("nil value for key NodeEdgePointUuid")
if t.NodeUuid == nil {
return nil, fmt.Errorf("nil value for key NodeUuid")
}
if t.TopologyUuid == nil {
return nil, fmt.Errorf("nil value for key TopologyUuid")
}
return map[string]interface{}{
"node-edge-point-uuid": *t.NodeEdgePointUuid,
"node-uuid": *t.NodeUuid,
"topology-uuid": *t.TopologyUuid,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_ClientNodeEdgePoint) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_ClientNodeEdgePoint"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_ClientNodeEdgePoint) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_MediaChannelConnectionEndPointSpec represents the /tapi-common/context/topology-context/topology/node/owned-node-edge-point/cep-list/connection-end-point/media-channel-connection-end-point-spec YANG schema element.
type TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_MediaChannelConnectionEndPointSpec struct {
MediaChannel *TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_MediaChannelConnectionEndPointSpec_MediaChannel `path:"media-channel" module:"tapi-photonic-media"`
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_MediaChannelConnectionEndPointSpec implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_MediaChannelConnectionEndPointSpec) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_MediaChannelConnectionEndPointSpec) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_MediaChannelConnectionEndPointSpec"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_MediaChannelConnectionEndPointSpec) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_MediaChannelConnectionEndPointSpec_MediaChannel represents the /tapi-common/context/topology-context/topology/node/owned-node-edge-point/cep-list/connection-end-point/media-channel-connection-end-point-spec/media-channel YANG schema element.
type TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_MediaChannelConnectionEndPointSpec_MediaChannel struct {
MeasuredPowerEgress *TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_MediaChannelConnectionEndPointSpec_MediaChannel_MeasuredPowerEgress `path:"measured-power-egress" module:"tapi-photonic-media"`
MeasuredPowerIngress *TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_MediaChannelConnectionEndPointSpec_MediaChannel_MeasuredPowerIngress `path:"measured-power-ingress" module:"tapi-photonic-media"`
OccupiedSpectrum *TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_MediaChannelConnectionEndPointSpec_MediaChannel_OccupiedSpectrum `path:"occupied-spectrum" module:"tapi-photonic-media"`
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_MediaChannelConnectionEndPointSpec_MediaChannel implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_MediaChannelConnectionEndPointSpec_MediaChannel) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_MediaChannelConnectionEndPointSpec_MediaChannel) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_MediaChannelConnectionEndPointSpec_MediaChannel"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_MediaChannelConnectionEndPointSpec_MediaChannel) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_MediaChannelConnectionEndPointSpec_MediaChannel_MeasuredPowerEgress represents the /tapi-common/context/topology-context/topology/node/owned-node-edge-point/cep-list/connection-end-point/media-channel-connection-end-point-spec/media-channel/measured-power-egress YANG schema element.
type TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_MediaChannelConnectionEndPointSpec_MediaChannel_MeasuredPowerEgress struct {
PowerSpectralDensity *float64 `path:"power-spectral-density" module:"tapi-photonic-media"`
TotalPower *float64 `path:"total-power" module:"tapi-photonic-media"`
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_MediaChannelConnectionEndPointSpec_MediaChannel_MeasuredPowerEgress implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_MediaChannelConnectionEndPointSpec_MediaChannel_MeasuredPowerEgress) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_MediaChannelConnectionEndPointSpec_MediaChannel_MeasuredPowerEgress) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_MediaChannelConnectionEndPointSpec_MediaChannel_MeasuredPowerEgress"], t, opts...); err != nil {
return err
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_MediaChannelConnectionEndPointSpec_MediaChannel_MeasuredPowerEgress) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_MediaChannelConnectionEndPointSpec_MediaChannel_MeasuredPowerIngress represents the /tapi-common/context/topology-context/topology/node/owned-node-edge-point/cep-list/connection-end-point/media-channel-connection-end-point-spec/media-channel/measured-power-ingress YANG schema element.
type TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_MediaChannelConnectionEndPointSpec_MediaChannel_MeasuredPowerIngress struct {
PowerSpectralDensity *float64 `path:"power-spectral-density" module:"tapi-photonic-media"`
TotalPower *float64 `path:"total-power" module:"tapi-photonic-media"`
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_MediaChannelConnectionEndPointSpec_MediaChannel_MeasuredPowerIngress implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_MediaChannelConnectionEndPointSpec_MediaChannel_MeasuredPowerIngress) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_MediaChannelConnectionEndPointSpec_MediaChannel_MeasuredPowerIngress) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_MediaChannelConnectionEndPointSpec_MediaChannel_MeasuredPowerIngress"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_MediaChannelConnectionEndPointSpec_MediaChannel_MeasuredPowerIngress) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_MediaChannelConnectionEndPointSpec_MediaChannel_OccupiedSpectrum represents the /tapi-common/context/topology-context/topology/node/owned-node-edge-point/cep-list/connection-end-point/media-channel-connection-end-point-spec/media-channel/occupied-spectrum YANG schema element.
type TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_MediaChannelConnectionEndPointSpec_MediaChannel_OccupiedSpectrum struct {
FrequencyConstraint *TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_MediaChannelConnectionEndPointSpec_MediaChannel_OccupiedSpectrum_FrequencyConstraint `path:"frequency-constraint" module:"tapi-photonic-media"`
LowerFrequency *uint64 `path:"lower-frequency" module:"tapi-photonic-media"`
UpperFrequency *uint64 `path:"upper-frequency" module:"tapi-photonic-media"`
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_MediaChannelConnectionEndPointSpec_MediaChannel_OccupiedSpectrum implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_MediaChannelConnectionEndPointSpec_MediaChannel_OccupiedSpectrum) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_MediaChannelConnectionEndPointSpec_MediaChannel_OccupiedSpectrum) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_MediaChannelConnectionEndPointSpec_MediaChannel_OccupiedSpectrum"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_MediaChannelConnectionEndPointSpec_MediaChannel_OccupiedSpectrum) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_MediaChannelConnectionEndPointSpec_MediaChannel_OccupiedSpectrum_FrequencyConstraint represents the /tapi-common/context/topology-context/topology/node/owned-node-edge-point/cep-list/connection-end-point/media-channel-connection-end-point-spec/media-channel/occupied-spectrum/frequency-constraint YANG schema element.
type TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_MediaChannelConnectionEndPointSpec_MediaChannel_OccupiedSpectrum_FrequencyConstraint struct {
AdjustmentGranularity E_TapiPhotonicMedia_AdjustmentGranularity `path:"adjustment-granularity" module:"tapi-photonic-media"`
GridType E_TapiPhotonicMedia_GridType `path:"grid-type" module:"tapi-photonic-media"`
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_MediaChannelConnectionEndPointSpec_MediaChannel_OccupiedSpectrum_FrequencyConstraint implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_MediaChannelConnectionEndPointSpec_MediaChannel_OccupiedSpectrum_FrequencyConstraint) IsYANGGoStruct() {}
// Validate validates s against the YANG schema corresponding to its type.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_MediaChannelConnectionEndPointSpec_MediaChannel_OccupiedSpectrum_FrequencyConstraint) Validate(opts ...ygot.ValidationOption) error {
if err := ytypes.Validate(SchemaTree["TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_MediaChannelConnectionEndPointSpec_MediaChannel_OccupiedSpectrum_FrequencyConstraint"], t, opts...); err != nil {
return err
}
return nil
}
// ΛEnumTypeMap returns a map, keyed by YANG schema path, of the enumerated types
// that are included in the generated code.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_MediaChannelConnectionEndPointSpec_MediaChannel_OccupiedSpectrum_FrequencyConstraint) ΛEnumTypeMap() map[string][]reflect.Type { return ΛEnumTypes }
// TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_Name represents the /tapi-common/context/topology-context/topology/node/owned-node-edge-point/cep-list/connection-end-point/name YANG schema element.
type TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_Name struct {
Value *string `path:"value" module:"tapi-connectivity"`
ValueName *string `path:"value-name" module:"tapi-connectivity"`
// IsYANGGoStruct ensures that TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_Name implements the yang.GoStruct
// interface. This allows functions that need to handle this struct to
// identify it as being generated by ygen.
func (*TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_Name) IsYANGGoStruct() {}
// ΛListKeyMap returns the keys of the TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_Name struct, which is a YANG list entry.
func (t *TapiCommon_Context_TopologyContext_Topology_Node_OwnedNodeEdgePoint_CepList_ConnectionEndPoint_Name) ΛListKeyMap() (map[string]interface{}, error) {
if t.ValueName == nil {
return nil, fmt.Errorf("nil value for key ValueName")
}
return map[string]interface{}{
"value-name": *t.ValueName,
}, nil
}
// Validate validates s against the YANG schema corresponding to its type.
Loading
Loading full blame...