//
// Copyright 2019 AT&T Intellectual Property
// Copyright 2019 Nokia
+// Copyright 2023 Capgemini
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// GetNodeb retrieves responding nodeb entity from redis DB by nodeb inventory name
GetNodeb(inventoryName string) (*entities.NodebInfo, error)
// GetNodebByGlobalNbId retrieves responding nodeb entity from redis DB by nodeb global Id
- GetNodebByGlobalNbId(nodeType entities.Node_Type, globalNbId *entities.GlobalNbId) (*entities.NodebInfo, error)
+ GetNodebByGlobalNbId(nodeType entities.Node_Type, globalNbId *entities.GlobalNbId, cuupId string,duid string) (*entities.NodebInfo, error)
// GetCellList retrieves the list of cell entities belonging to responding nodeb entity from redis DB by nodeb inventory name
GetCellList(inventoryName string) (*entities.Cells, error)
// GetListGnbIds retrieves the list of gNodeb identity entities
GetE2TAddresses() ([]string, error)
GetGeneralConfiguration() (*entities.GeneralConfiguration, error)
+
+ GetRanFunctionDefinition(inventoryName string, Oid string) ([]string, error)
}
//GetNewRNibReader returns reference to RNibReader
}
}
+//GetRanFunctionDefinition from the OID
+func (w *rNibReaderInstance) GetRanFunctionDefinition(inventoryName string, oid string) ([]string, error){
+ nb, err := w.GetNodeb (inventoryName)
+ if (nb.GetGnb() != nil) {
+ ranFunction := nb.GetGnb().RanFunctions
+ functionDefinitionList := make([]string, 0)
+ for _, ranFunction := range ranFunction {
+ if (oid == ranFunction.RanFunctionOid) {
+ functionDefinitionList = append(functionDefinitionList ,ranFunction.RanFunctionDefinition)
+ }
+ }
+ return functionDefinitionList, err
+ }
+ return nil, common.NewResourceNotFoundErrorf("#rNibReader.GetCellList - served cells not found. Responding node RAN name: % s.", inventoryName)
+}
+
//GetRNibReader returns reference to RNibReader
//Deprecated: Will be removed in a future release, please use GetNewRNibReader instead.
func GetRNibReader(sdl common.ISdlInstance) RNibReader {
return nbInfo, nil
}
-func (w *rNibReaderInstance) GetNodebByGlobalNbId(nodeType entities.Node_Type, globalNbId *entities.GlobalNbId) (*entities.NodebInfo, error) {
- key, rNibErr := common.ValidateAndBuildNodeBIdKey(nodeType.String(), globalNbId.GetPlmnId(), globalNbId.GetNbId())
+func (w *rNibReaderInstance) GetNodebByGlobalNbId(nodeType entities.Node_Type, globalNbId *entities.GlobalNbId, cuupid string, duid string) (*entities.NodebInfo, error) {
+ key, rNibErr := common.ValidateAndBuildNodeBIdKey(nodeType.String(), globalNbId.GetPlmnId(), globalNbId.GetNbId(), cuupid, duid)
if rNibErr != nil {
return nil, rNibErr
}