c6fef1438ea14226bf098988411e38b3a8862e49
[scp/ric-app/kpimon.git] / control / types.go
1 package control
2
3 const MAX_SUBSCRIPTION_ATTEMPTS = 100
4
5 type DecodedIndicationMessage struct {
6         RequestID             int32
7         RequestSequenceNumber int32
8         FuncID                int32
9         ActionID              int32
10         IndSN                 int32
11         IndType               int32
12         IndHeader             []byte
13         IndHeaderLength       int32
14         IndMessage            []byte
15         IndMessageLength      int32
16         CallProcessID         []byte
17         CallProcessIDLength   int32
18 }
19
20 type CauseItemType struct {
21         CauseType int32
22         CauseID   int32
23 }
24
25 type ActionAdmittedListType struct {
26         ActionID [16]int32
27         Count    int
28 }
29
30 type ActionNotAdmittedListType struct {
31         ActionID [16]int32
32         Cause    [16]CauseItemType
33         Count    int
34 }
35
36 type DecodedSubscriptionResponseMessage struct {
37         RequestID             int32
38         RequestSequenceNumber int32
39         FuncID                int32
40         ActionAdmittedList    ActionAdmittedListType
41         ActionNotAdmittedList ActionNotAdmittedListType
42 }
43
44 type IntPair64 struct {
45         DL int64
46         UL int64
47 }
48
49 type OctetString struct {
50         Buf  []byte
51         Size int
52 }
53
54 type Integer OctetString
55
56 type PrintableString OctetString
57
58 type ActionDefinition OctetString
59
60 type BitString struct {
61         Buf        []byte
62         Size       int
63         BitsUnused int
64 }
65
66 type SubsequentAction struct {
67         IsValid              int
68         SubsequentActionType int64
69         TimeToWait           int64
70 }
71
72 type GNBID BitString
73
74 type GlobalgNBIDType struct {
75         PlmnID    OctetString
76         GnbIDType int
77         GnbID     interface{}
78 }
79
80 type GlobalKPMnodegNBIDType struct {
81         GlobalgNBID GlobalgNBIDType
82         GnbCUUPID   *Integer
83         GnbDUID     *Integer
84 }
85
86 type ENGNBID BitString
87
88 type GlobalKPMnodeengNBIDType struct {
89         PlmnID    OctetString
90         GnbIDType int
91         GnbID     interface{}
92 }
93
94 type NGENBID_Macro BitString
95
96 type NGENBID_ShortMacro BitString
97
98 type NGENBID_LongMacro BitString
99
100 type GlobalKPMnodengeNBIDType struct {
101         PlmnID    OctetString
102         EnbIDType int
103         EnbID     interface{}
104 }
105
106 type ENBID_Macro BitString
107
108 type ENBID_Home BitString
109
110 type ENBID_ShortMacro BitString
111
112 type ENBID_LongMacro BitString
113
114 type GlobalKPMnodeeNBIDType struct {
115         PlmnID    OctetString
116         EnbIDType int
117         EnbID     interface{}
118 }
119
120 type NRCGIType struct {
121         PlmnID   OctetString
122         NRCellID BitString
123 }
124
125 type SliceIDType struct {
126         SST OctetString
127         SD  *OctetString
128 }
129
130 type GNB_DU_Name PrintableString
131
132 type GNB_CU_CP_Name PrintableString
133
134 type GNB_CU_UP_Name PrintableString
135
136 type IndicationHeaderFormat1 struct {
137         GlobalKPMnodeIDType int32
138         GlobalKPMnodeID     interface{}
139         NRCGI               *NRCGIType
140         PlmnID              *OctetString
141         SliceID             *SliceIDType
142         FiveQI              int64
143         Qci                 int64
144         UeMessageType       int32
145         GnbDUID             *Integer
146         GnbNameType         int32
147         GnbName             interface{}
148         GlobalgNBID         *GlobalgNBIDType
149 }
150
151 type IndicationHeader struct {
152         IndHdrType int32
153         IndHdr     interface{}
154 }
155
156 type FQIPERSlicesPerPlmnPerCellType struct {
157         FiveQI   int64
158         PrbUsage IntPair64
159 }
160
161 type SlicePerPlmnPerCellType struct {
162         SliceID                         SliceIDType
163         FQIPERSlicesPerPlmnPerCells     [64]FQIPERSlicesPerPlmnPerCellType
164         FQIPERSlicesPerPlmnPerCellCount int
165 }
166
167 type DUPM5GCContainerType struct {
168         SlicePerPlmnPerCells     [1024]SlicePerPlmnPerCellType
169         SlicePerPlmnPerCellCount int
170 }
171
172 type DUPMEPCPerQCIReportType struct {
173         QCI      int64
174         PrbUsage IntPair64
175 }
176
177 type DUPMEPCContainerType struct {
178         PerQCIReports     [256]DUPMEPCPerQCIReportType
179         PerQCIReportCount int
180 }
181
182 type ServedPlmnPerCellType struct {
183         PlmnID  OctetString
184         DUPM5GC *DUPM5GCContainerType
185         DUPMEPC *DUPMEPCContainerType
186 }
187
188 type CellResourceReportType struct {
189         NRCGI                  NRCGIType
190         TotalofAvailablePRBs   IntPair64
191         ServedPlmnPerCells     [12]ServedPlmnPerCellType
192         ServedPlmnPerCellCount int
193 }
194
195 type ODUPFContainerType struct {
196         CellResourceReports     [512]CellResourceReportType
197         CellResourceReportCount int
198 }
199
200 type CUCPResourceStatusType struct {
201         NumberOfActiveUEs int64
202 }
203
204 type OCUCPPFContainerType struct {
205         GNBCUCPName        *PrintableString
206         CUCPResourceStatus CUCPResourceStatusType
207 }
208
209 type FQIPERSlicesPerPlmnType struct {
210         FiveQI      int64
211         PDCPBytesDL *Integer
212         PDCPBytesUL *Integer
213 }
214
215 type SliceToReportType struct {
216         SliceID                  SliceIDType
217         FQIPERSlicesPerPlmns     [64]FQIPERSlicesPerPlmnType
218         FQIPERSlicesPerPlmnCount int
219 }
220
221 type CUUPPM5GCType struct {
222         SliceToReports     [1024]SliceToReportType
223         SliceToReportCount int
224 }
225
226 type CUUPPMEPCPerQCIReportType struct {
227         QCI         int64
228         PDCPBytesDL *Integer
229         PDCPBytesUL *Integer
230 }
231
232 type CUUPPMEPCType struct {
233         CUUPPMEPCPerQCIReports     [256]CUUPPMEPCPerQCIReportType
234         CUUPPMEPCPerQCIReportCount int
235 }
236
237 type CUUPPlmnType struct {
238         PlmnID    OctetString
239         CUUPPM5GC *CUUPPM5GCType
240         CUUPPMEPC *CUUPPMEPCType
241 }
242
243 type CUUPMeasurementContainerType struct {
244         CUUPPlmns     [12]CUUPPlmnType
245         CUUPPlmnCount int
246 }
247
248 type CUUPPFContainerItemType struct {
249         InterfaceType    int64
250         OCUUPPMContainer CUUPMeasurementContainerType
251 }
252
253 type OCUUPPFContainerType struct {
254         GNBCUUPName              *PrintableString
255         CUUPPFContainerItems     [3]CUUPPFContainerItemType
256         CUUPPFContainerItemCount int
257 }
258
259 type DUUsageReportUeResourceReportItemType struct {
260         CRNTI      Integer
261         PRBUsageDL int64
262         PRBUsageUL int64
263 }
264
265 type DUUsageReportCellResourceReportItemType struct {
266         NRCGI                     NRCGIType
267         UeResourceReportItems     [32]DUUsageReportUeResourceReportItemType
268         UeResourceReportItemCount int
269 }
270
271 type DUUsageReportType struct {
272         CellResourceReportItems     [512]DUUsageReportCellResourceReportItemType
273         CellResourceReportItemCount int
274 }
275
276 type CUCPUsageReportUeResourceReportItemType struct {
277         CRNTI          Integer
278         ServingCellRF  *OctetString
279         NeighborCellRF *OctetString
280 }
281
282 type CUCPUsageReportCellResourceReportItemType struct {
283         NRCGI                     NRCGIType
284         UeResourceReportItems     [32]CUCPUsageReportUeResourceReportItemType
285         UeResourceReportItemCount int
286 }
287
288 type CUCPUsageReportType struct {
289         CellResourceReportItems     [16384]CUCPUsageReportCellResourceReportItemType
290         CellResourceReportItemCount int
291 }
292
293 type CUUPUsageReportUeResourceReportItemType struct {
294         CRNTI       Integer
295         PDCPBytesDL *Integer
296         PDCPBytesUL *Integer
297 }
298
299 type CUUPUsageReportCellResourceReportItemType struct {
300         NRCGI                     NRCGIType
301         UeResourceReportItems     [32]CUUPUsageReportUeResourceReportItemType
302         UeResourceReportItemCount int
303 }
304
305 type CUUPUsageReportType struct {
306         CellResourceReportItems     [512]CUUPUsageReportCellResourceReportItemType
307         CellResourceReportItemCount int
308 }
309
310 type PFContainerType struct {
311         ContainerType int32
312         Container     interface{}
313 }
314
315 type RANContainerType struct {
316         Timestamp     OctetString
317         ContainerType int32
318         Container     interface{}
319 }
320
321 type PMContainerType struct {
322         PFContainer  *PFContainerType
323         RANContainer *RANContainerType
324 }
325
326 type IndicationMessageFormat1 struct {
327         PMContainers     [8]PMContainerType
328         PMContainerCount int
329 }
330
331 type IndicationMessage struct {
332         StyleType  int64
333         IndMsgType int32
334         IndMsg     interface{}
335 }
336
337 type Timestamp struct {
338         TVsec  int64 `json:"tv_sec"`
339         TVnsec int64 `json:"tv_nsec"`
340 }
341
342 type CellMetricsEntry struct {
343         MeasTimestampPDCPBytes Timestamp `json:"Meas-Timestamp-PDCP-Bytes"`
344         PDCPBytesDL            int64     `json:"PDCP-Bytes-DL"`
345         PDCPBytesUL            int64     `json:"PDCP-Bytes-UL"`
346         MeasTimestampPRB       Timestamp `json:"Meas-Timestamp-PRB"`
347         AvailPRBDL             int64     `json:"Avail-PRB-DL"`
348         AvailPRBUL             int64     `json:"Avail-PRB-UL"`
349 }
350
351 type CellRFType struct {
352         RSRP   int `json:"rsrp"`
353         RSRQ   int `json:"rsrq"`
354         RSSINR int `json:"rsSinr"`
355 }
356
357 type NeighborCellRFType struct {
358         CellID string     `json:"CID"`
359         CellRF CellRFType `json:"Cell-RF"`
360 }
361
362 type UeMetricsEntry struct {
363         UeID                   string               `json:"UE ID"`
364         ServingCellID          string               `json:"Serving Cell ID"`
365         MeasTimestampPDCPBytes Timestamp            `json:"Meas-Timestamp-PDCP-Bytes"`
366         PDCPBytesDL            int64                `json:"PDCP-Bytes-DL"`
367         PDCPBytesUL            int64                `json:"PDCP-Bytes-UL"`
368         MeasTimestampPRB       Timestamp            `json:"Meas-Timestamp-PRB"`
369         PRBUsageDL             int64                `json:"PRB-Usage-DL"`
370         PRBUsageUL             int64                `json:"PRB-Usage-UL"`
371         MeasTimeRF             Timestamp            `json:"Meas-Time-RF"`
372         ServingCellRF          CellRFType           `json:"Serving-Cell-RF"`
373         NeighborCellsRF        []NeighborCellRFType `json:"Neighbor-Cell-RF"`
374 }