Reorganize directories and switch libaries to using asn1c
[it/test.git] / simulators / e2sim / src / ASN1 / generated / E2AP-PDU-Contents.hpp
1 /*****************************************************************************
2 # Copyright 2019 AT&T Intellectual Property                                  *
3 #                                                                            *
4 # Licensed under the Apache License, Version 2.0 (the "License");            *
5 # you may not use this file except in compliance with the License.           *
6 # You may obtain a copy of the License at                                    *
7 #                                                                            *
8 #      http://www.apache.org/licenses/LICENSE-2.0                            *
9 #                                                                            *
10 # Unless required by applicable law or agreed to in writing, software        *
11 # distributed under the License is distributed on an "AS IS" BASIS,          *
12 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.   *
13 # See the License for the specific language governing permissions and        *
14 # limitations under the License.                                             *
15 #                                                                            *
16 ******************************************************************************/
17
18 #pragma once
19
20 #include "asn/asn.hpp"
21 static_assert(ASN_API_VERSION_MAJOR == 5, "re-generate the ASN parser's code using 'make regen-asn' (do not use -j option)");
22
23 #include "E2AP-IEs.hpp"
24 #include "X2AP-IEs.hpp"
25 #include "X2AP-Constants.hpp"
26 #include "X2AP-Containers.hpp"
27 #include "E2AP-Constants.hpp"
28
29 /*
30 RANfunction-Item ::= SEQUENCE {
31         ranFunctionID                           RANfunctionID,
32         ranFunctionDefinition           RANfunctionDefinition,
33         ...
34 }
35 */
36
37 struct RANfunction_Item : asn::sequence<2, 0, true, 0>
38 {
39         static constexpr const char* name() {return "RANfunction-Item";}
40         using parent_t = asn::sequence<2, 0, true, 0>;
41         struct ranFunctionID_t : RANfunctionID
42         {
43                 static constexpr const char* name() {return "ranFunctionID_t";}
44                 using parent_t = RANfunctionID;
45
46         };
47         ranFunctionID_t& ref_ranFunctionID() {return ranFunctionID;}
48         ranFunctionID_t const& ref_ranFunctionID() const {return ranFunctionID;}
49         struct ranFunctionDefinition_t : RANfunctionDefinition
50         {
51                 static constexpr const char* name() {return "ranFunctionDefinition_t";}
52                 using parent_t = RANfunctionDefinition;
53
54         };
55         ranFunctionDefinition_t& ref_ranFunctionDefinition() {return ranFunctionDefinition;}
56         ranFunctionDefinition_t const& ref_ranFunctionDefinition() const {return ranFunctionDefinition;}
57         template<typename V> void decode(V& v)
58         {
59                 v(ranFunctionID);
60                 v(ranFunctionDefinition);
61
62         };
63         template<typename V> void encode(V& v) const
64         {
65                 v(ranFunctionID);
66                 v(ranFunctionDefinition);
67
68         };
69         void clear()
70         {
71                 ranFunctionID.clear();
72                 ranFunctionDefinition.clear();
73
74         };
75         private:
76         ranFunctionID_t ranFunctionID;
77         ranFunctionDefinition_t ranFunctionDefinition;
78
79 };
80 /*
81 RANfunction-ItemIEs     X2AP-PROTOCOL-IES ::= {
82         { ID id-RANfunction-Item                        CRITICALITY ignore      TYPE RANfunction-Item                           PRESENCE mandatory },
83         ...
84 }
85 */
86
87 struct RANfunction_ItemIEs
88 {
89         struct id_t : asn::fixedtypefield<X2AP_PROTOCOL_IES::id_t, true>
90         {
91                 size_t get_index() const {return type;}
92                 bool is_unknown() const { return type == 2; }
93                 void clear() {type = 0;}
94                 void select_id_RANfunction_Item() { set(id_RANfunction_Item); type=1;}
95                 X2AP_PROTOCOL_IES::id_t const& ref_value() const {return ref_nested();}
96                 template<typename V>  bool decode(V& v)
97                 {
98                         clear();
99                         if(!v(ref_nested())) return false;
100                         if(equal(id_RANfunction_Item)) { type = 1; return true; }
101                         else { type = 2; return true;}
102                         return false;
103
104                 }
105                 template<typename V> bool encode(V& v) const
106                 {
107                         return v(ref_nested());
108
109                 }
110                 protected:
111                 template<typename V>  bool decode(size_t index, V& v)
112                 {
113                         clear();
114                         switch(index)
115                         {
116                         case 1: type = 1; if(v(ref_nested())) { return equal(id_RANfunction_Item);} return false;
117                         case 2: type = 2; return v(ref_nested());
118                         ref_nested().clear();
119                         }
120                         return false;
121
122                 }
123                 template<typename V> bool encode(size_t index, V& v) const
124                 {
125                         if(index != type) {return false;} return v(ref_nested());
126
127                 }
128                 private:
129                 size_t type {0};
130
131         };
132         struct criticality_t : asn::fixedtypefield<X2AP_PROTOCOL_IES::criticality_t, true>
133         {
134                 size_t get_index() const {return type;}
135                 bool is_unknown() const { return type == 2; }
136                 void clear() {type = 0;}
137                 void select_id_RANfunction_Item() { set(ignore); type=1;}
138                 X2AP_PROTOCOL_IES::criticality_t const& ref_value() const {return ref_nested();}
139                 template<typename V>  bool decode(V& v)
140                 {
141                         clear();
142                         if(!v(ref_nested())) return false;
143                         if(equal(ignore)) { type = 1; return true; }
144                         else { type = 2; return true;}
145                         return false;
146
147                 }
148                 template<typename V> bool encode(V& v) const
149                 {
150                         return v(ref_nested());
151
152                 }
153                 protected:
154                 template<typename V>  bool decode(size_t index, V& v)
155                 {
156                         clear();
157                         switch(index)
158                         {
159                         case 1: type = 1; if(v(ref_nested())) { return equal(ignore);} return false;
160                         case 2: type = 2; return v(ref_nested());
161                         ref_nested().clear();
162                         }
163                         return false;
164
165                 }
166                 template<typename V> bool encode(size_t index, V& v) const
167                 {
168                         if(index != type) {return false;} return v(ref_nested());
169
170                 }
171                 private:
172                 size_t type {0};
173
174         };
175         struct Value_t : asn::typefield<true>
176         {
177                 ~Value_t()      {clear();}
178                 size_t get_index() const {return type;}
179                 RANfunction_Item& select_id_RANfunction_Item() { return set<RANfunction_Item>(1); }
180                 RANfunction_Item const* get_id_RANfunction_Item() const { return get<RANfunction_Item>(1); }
181                 bool is_unknown() const { return type == 2; }
182                 void clear()
183                 {
184                         switch(type)
185                         {
186                         case 1: var.destroy<RANfunction_Item>(); break;
187                         }
188                         type = 0; ref_nested().clear();
189                 }
190                 template<typename V> static inline void enumerate(V& v)
191                 {
192                         v.template operator()<RANfunction_Item>(1);
193
194                 }
195                 protected:
196                 template<typename V> bool decode(size_t index, V& v)
197                 {
198                         clear();
199                         switch(index)
200                         {
201                         case 1: v(select_id_RANfunction_Item()); return true;
202                         case 2: if(type != 2) {clear(); asn::base::set();} type = 2; return true;
203                         }
204                         return false;
205
206                 }
207                 template<typename V> bool encode(size_t index, V& v) const
208                 {
209                         if(index != type) return false;
210                         switch(type)
211                         {
212                         case 1: v(var.as<RANfunction_Item>()); return true;
213                         }
214                         return false;
215
216                 }
217                 private:
218                 template<class T> T& set(size_t index) {if(type != index) {clear(); type = index; return var.build<T>();} return var.as<T>();}
219                 template<class T> T const* get(size_t index) const {if(type == index) {return &var.as<T>();} return nullptr;}
220                 union union_type
221                 {
222                         char dummy1[sizeof(RANfunction_Item)];
223
224                 };
225                 asn::variant<sizeof(union_type)> var;
226                 size_t type {0};
227
228         };
229         struct presence_t : asn::fixedtypefield<X2AP_PROTOCOL_IES::presence_t, true>
230         {
231                 size_t get_index() const {return type;}
232                 bool is_unknown() const { return type == 2; }
233                 void clear() {type = 0;}
234                 void select_id_RANfunction_Item() { set(mandatory); type=1;}
235                 X2AP_PROTOCOL_IES::presence_t const& ref_value() const {return ref_nested();}
236                 template<typename V>  bool decode(V& v)
237                 {
238                         clear();
239                         if(!v(ref_nested())) return false;
240                         if(equal(mandatory)) { type = 1; return true; }
241                         else { type = 2; return true;}
242                         return false;
243
244                 }
245                 template<typename V> bool encode(V& v) const
246                 {
247                         return v(ref_nested());
248
249                 }
250                 protected:
251                 template<typename V>  bool decode(size_t index, V& v)
252                 {
253                         clear();
254                         switch(index)
255                         {
256                         case 1: type = 1; if(v(ref_nested())) { return equal(mandatory);} return false;
257                         case 2: type = 2; return v(ref_nested());
258                         ref_nested().clear();
259                         }
260                         return false;
261
262                 }
263                 template<typename V> bool encode(size_t index, V& v) const
264                 {
265                         if(index != type) {return false;} return v(ref_nested());
266
267                 }
268                 private:
269                 size_t type {0};
270
271         };
272
273 };
274 /*
275 RANfunctionID-Item ::= SEQUENCE {
276         ranFunctionID                           RANfunctionID,
277         ...
278 }
279 */
280
281 struct RANfunctionID_Item : asn::sequence<1, 0, true, 0>
282 {
283         static constexpr const char* name() {return "RANfunctionID-Item";}
284         using parent_t = asn::sequence<1, 0, true, 0>;
285         struct ranFunctionID_t : RANfunctionID
286         {
287                 static constexpr const char* name() {return "ranFunctionID_t";}
288                 using parent_t = RANfunctionID;
289
290         };
291         ranFunctionID_t& ref_ranFunctionID() {return ranFunctionID;}
292         ranFunctionID_t const& ref_ranFunctionID() const {return ranFunctionID;}
293         template<typename V> void decode(V& v)
294         {
295                 v(ranFunctionID);
296
297         };
298         template<typename V> void encode(V& v) const
299         {
300                 v(ranFunctionID);
301
302         };
303         void clear()
304         {
305                 ranFunctionID.clear();
306
307         };
308         private:
309         ranFunctionID_t ranFunctionID;
310
311 };
312 /*
313 RANfunctionID-ItemIEs X2AP-PROTOCOL-IES ::= {
314         { ID id-RANfunctionID-Item                      CRITICALITY ignore              TYPE RANfunctionID-Item                 PRESENCE mandatory },
315         ...
316 }
317 */
318
319 struct RANfunctionID_ItemIEs
320 {
321         struct id_t : asn::fixedtypefield<X2AP_PROTOCOL_IES::id_t, true>
322         {
323                 size_t get_index() const {return type;}
324                 bool is_unknown() const { return type == 2; }
325                 void clear() {type = 0;}
326                 void select_id_RANfunctionID_Item() { set(id_RANfunctionID_Item); type=1;}
327                 X2AP_PROTOCOL_IES::id_t const& ref_value() const {return ref_nested();}
328                 template<typename V>  bool decode(V& v)
329                 {
330                         clear();
331                         if(!v(ref_nested())) return false;
332                         if(equal(id_RANfunctionID_Item)) { type = 1; return true; }
333                         else { type = 2; return true;}
334                         return false;
335
336                 }
337                 template<typename V> bool encode(V& v) const
338                 {
339                         return v(ref_nested());
340
341                 }
342                 protected:
343                 template<typename V>  bool decode(size_t index, V& v)
344                 {
345                         clear();
346                         switch(index)
347                         {
348                         case 1: type = 1; if(v(ref_nested())) { return equal(id_RANfunctionID_Item);} return false;
349                         case 2: type = 2; return v(ref_nested());
350                         ref_nested().clear();
351                         }
352                         return false;
353
354                 }
355                 template<typename V> bool encode(size_t index, V& v) const
356                 {
357                         if(index != type) {return false;} return v(ref_nested());
358
359                 }
360                 private:
361                 size_t type {0};
362
363         };
364         struct criticality_t : asn::fixedtypefield<X2AP_PROTOCOL_IES::criticality_t, true>
365         {
366                 size_t get_index() const {return type;}
367                 bool is_unknown() const { return type == 2; }
368                 void clear() {type = 0;}
369                 void select_id_RANfunctionID_Item() { set(ignore); type=1;}
370                 X2AP_PROTOCOL_IES::criticality_t const& ref_value() const {return ref_nested();}
371                 template<typename V>  bool decode(V& v)
372                 {
373                         clear();
374                         if(!v(ref_nested())) return false;
375                         if(equal(ignore)) { type = 1; return true; }
376                         else { type = 2; return true;}
377                         return false;
378
379                 }
380                 template<typename V> bool encode(V& v) const
381                 {
382                         return v(ref_nested());
383
384                 }
385                 protected:
386                 template<typename V>  bool decode(size_t index, V& v)
387                 {
388                         clear();
389                         switch(index)
390                         {
391                         case 1: type = 1; if(v(ref_nested())) { return equal(ignore);} return false;
392                         case 2: type = 2; return v(ref_nested());
393                         ref_nested().clear();
394                         }
395                         return false;
396
397                 }
398                 template<typename V> bool encode(size_t index, V& v) const
399                 {
400                         if(index != type) {return false;} return v(ref_nested());
401
402                 }
403                 private:
404                 size_t type {0};
405
406         };
407         struct Value_t : asn::typefield<true>
408         {
409                 ~Value_t()      {clear();}
410                 size_t get_index() const {return type;}
411                 RANfunctionID_Item& select_id_RANfunctionID_Item() { return set<RANfunctionID_Item>(1); }
412                 RANfunctionID_Item const* get_id_RANfunctionID_Item() const { return get<RANfunctionID_Item>(1); }
413                 bool is_unknown() const { return type == 2; }
414                 void clear()
415                 {
416                         switch(type)
417                         {
418                         case 1: var.destroy<RANfunctionID_Item>(); break;
419                         }
420                         type = 0; ref_nested().clear();
421                 }
422                 template<typename V> static inline void enumerate(V& v)
423                 {
424                         v.template operator()<RANfunctionID_Item>(1);
425
426                 }
427                 protected:
428                 template<typename V> bool decode(size_t index, V& v)
429                 {
430                         clear();
431                         switch(index)
432                         {
433                         case 1: v(select_id_RANfunctionID_Item()); return true;
434                         case 2: if(type != 2) {clear(); asn::base::set();} type = 2; return true;
435                         }
436                         return false;
437
438                 }
439                 template<typename V> bool encode(size_t index, V& v) const
440                 {
441                         if(index != type) return false;
442                         switch(type)
443                         {
444                         case 1: v(var.as<RANfunctionID_Item>()); return true;
445                         }
446                         return false;
447
448                 }
449                 private:
450                 template<class T> T& set(size_t index) {if(type != index) {clear(); type = index; return var.build<T>();} return var.as<T>();}
451                 template<class T> T const* get(size_t index) const {if(type == index) {return &var.as<T>();} return nullptr;}
452                 union union_type
453                 {
454                         char dummy1[sizeof(RANfunctionID_Item)];
455
456                 };
457                 asn::variant<sizeof(union_type)> var;
458                 size_t type {0};
459
460         };
461         struct presence_t : asn::fixedtypefield<X2AP_PROTOCOL_IES::presence_t, true>
462         {
463                 size_t get_index() const {return type;}
464                 bool is_unknown() const { return type == 2; }
465                 void clear() {type = 0;}
466                 void select_id_RANfunctionID_Item() { set(mandatory); type=1;}
467                 X2AP_PROTOCOL_IES::presence_t const& ref_value() const {return ref_nested();}
468                 template<typename V>  bool decode(V& v)
469                 {
470                         clear();
471                         if(!v(ref_nested())) return false;
472                         if(equal(mandatory)) { type = 1; return true; }
473                         else { type = 2; return true;}
474                         return false;
475
476                 }
477                 template<typename V> bool encode(V& v) const
478                 {
479                         return v(ref_nested());
480
481                 }
482                 protected:
483                 template<typename V>  bool decode(size_t index, V& v)
484                 {
485                         clear();
486                         switch(index)
487                         {
488                         case 1: type = 1; if(v(ref_nested())) { return equal(mandatory);} return false;
489                         case 2: type = 2; return v(ref_nested());
490                         ref_nested().clear();
491                         }
492                         return false;
493
494                 }
495                 template<typename V> bool encode(size_t index, V& v) const
496                 {
497                         if(index != type) {return false;} return v(ref_nested());
498
499                 }
500                 private:
501                 size_t type {0};
502
503         };
504
505 };
506 /*
507 RANfunctionIDcause-Item ::= SEQUENCE {
508         ranFunctionID                           RANfunctionID,
509         ricCause                                RICcause,
510         ...
511 }
512 */
513
514 struct RANfunctionIDcause_Item : asn::sequence<2, 0, true, 0>
515 {
516         static constexpr const char* name() {return "RANfunctionIDcause-Item";}
517         using parent_t = asn::sequence<2, 0, true, 0>;
518         struct ranFunctionID_t : RANfunctionID
519         {
520                 static constexpr const char* name() {return "ranFunctionID_t";}
521                 using parent_t = RANfunctionID;
522
523         };
524         ranFunctionID_t& ref_ranFunctionID() {return ranFunctionID;}
525         ranFunctionID_t const& ref_ranFunctionID() const {return ranFunctionID;}
526         struct ricCause_t : RICcause
527         {
528                 static constexpr const char* name() {return "ricCause_t";}
529                 using parent_t = RICcause;
530
531         };
532         ricCause_t& ref_ricCause() {return ricCause;}
533         ricCause_t const& ref_ricCause() const {return ricCause;}
534         template<typename V> void decode(V& v)
535         {
536                 v(ranFunctionID);
537                 v(ricCause);
538
539         };
540         template<typename V> void encode(V& v) const
541         {
542                 v(ranFunctionID);
543                 v(ricCause);
544
545         };
546         void clear()
547         {
548                 ranFunctionID.clear();
549                 ricCause.clear();
550
551         };
552         private:
553         ranFunctionID_t ranFunctionID;
554         ricCause_t      ricCause;
555
556 };
557 /*
558 RANfunctionIDcause-ItemIEs      X2AP-PROTOCOL-IES ::= {
559         { ID id-RANfunctionIEcause-Item         CRITICALITY ignore      TYPE RANfunctionIDcause-Item            PRESENCE mandatory },
560         ...
561 }
562 */
563
564 struct RANfunctionIDcause_ItemIEs
565 {
566         struct id_t : asn::fixedtypefield<X2AP_PROTOCOL_IES::id_t, true>
567         {
568                 size_t get_index() const {return type;}
569                 bool is_unknown() const { return type == 2; }
570                 void clear() {type = 0;}
571                 void select_id_RANfunctionIEcause_Item() { set(id_RANfunctionIEcause_Item); type=1;}
572                 X2AP_PROTOCOL_IES::id_t const& ref_value() const {return ref_nested();}
573                 template<typename V>  bool decode(V& v)
574                 {
575                         clear();
576                         if(!v(ref_nested())) return false;
577                         if(equal(id_RANfunctionIEcause_Item)) { type = 1; return true; }
578                         else { type = 2; return true;}
579                         return false;
580
581                 }
582                 template<typename V> bool encode(V& v) const
583                 {
584                         return v(ref_nested());
585
586                 }
587                 protected:
588                 template<typename V>  bool decode(size_t index, V& v)
589                 {
590                         clear();
591                         switch(index)
592                         {
593                         case 1: type = 1; if(v(ref_nested())) { return equal(id_RANfunctionIEcause_Item);} return false;
594                         case 2: type = 2; return v(ref_nested());
595                         ref_nested().clear();
596                         }
597                         return false;
598
599                 }
600                 template<typename V> bool encode(size_t index, V& v) const
601                 {
602                         if(index != type) {return false;} return v(ref_nested());
603
604                 }
605                 private:
606                 size_t type {0};
607
608         };
609         struct criticality_t : asn::fixedtypefield<X2AP_PROTOCOL_IES::criticality_t, true>
610         {
611                 size_t get_index() const {return type;}
612                 bool is_unknown() const { return type == 2; }
613                 void clear() {type = 0;}
614                 void select_id_RANfunctionIEcause_Item() { set(ignore); type=1;}
615                 X2AP_PROTOCOL_IES::criticality_t const& ref_value() const {return ref_nested();}
616                 template<typename V>  bool decode(V& v)
617                 {
618                         clear();
619                         if(!v(ref_nested())) return false;
620                         if(equal(ignore)) { type = 1; return true; }
621                         else { type = 2; return true;}
622                         return false;
623
624                 }
625                 template<typename V> bool encode(V& v) const
626                 {
627                         return v(ref_nested());
628
629                 }
630                 protected:
631                 template<typename V>  bool decode(size_t index, V& v)
632                 {
633                         clear();
634                         switch(index)
635                         {
636                         case 1: type = 1; if(v(ref_nested())) { return equal(ignore);} return false;
637                         case 2: type = 2; return v(ref_nested());
638                         ref_nested().clear();
639                         }
640                         return false;
641
642                 }
643                 template<typename V> bool encode(size_t index, V& v) const
644                 {
645                         if(index != type) {return false;} return v(ref_nested());
646
647                 }
648                 private:
649                 size_t type {0};
650
651         };
652         struct Value_t : asn::typefield<true>
653         {
654                 ~Value_t()      {clear();}
655                 size_t get_index() const {return type;}
656                 RANfunctionIDcause_Item& select_id_RANfunctionIEcause_Item() { return set<RANfunctionIDcause_Item>(1); }
657                 RANfunctionIDcause_Item const* get_id_RANfunctionIEcause_Item() const { return get<RANfunctionIDcause_Item>(1); }
658                 bool is_unknown() const { return type == 2; }
659                 void clear()
660                 {
661                         switch(type)
662                         {
663                         case 1: var.destroy<RANfunctionIDcause_Item>(); break;
664                         }
665                         type = 0; ref_nested().clear();
666                 }
667                 template<typename V> static inline void enumerate(V& v)
668                 {
669                         v.template operator()<RANfunctionIDcause_Item>(1);
670
671                 }
672                 protected:
673                 template<typename V> bool decode(size_t index, V& v)
674                 {
675                         clear();
676                         switch(index)
677                         {
678                         case 1: v(select_id_RANfunctionIEcause_Item()); return true;
679                         case 2: if(type != 2) {clear(); asn::base::set();} type = 2; return true;
680                         }
681                         return false;
682
683                 }
684                 template<typename V> bool encode(size_t index, V& v) const
685                 {
686                         if(index != type) return false;
687                         switch(type)
688                         {
689                         case 1: v(var.as<RANfunctionIDcause_Item>()); return true;
690                         }
691                         return false;
692
693                 }
694                 private:
695                 template<class T> T& set(size_t index) {if(type != index) {clear(); type = index; return var.build<T>();} return var.as<T>();}
696                 template<class T> T const* get(size_t index) const {if(type == index) {return &var.as<T>();} return nullptr;}
697                 union union_type
698                 {
699                         char dummy1[sizeof(RANfunctionIDcause_Item)];
700
701                 };
702                 asn::variant<sizeof(union_type)> var;
703                 size_t type {0};
704
705         };
706         struct presence_t : asn::fixedtypefield<X2AP_PROTOCOL_IES::presence_t, true>
707         {
708                 size_t get_index() const {return type;}
709                 bool is_unknown() const { return type == 2; }
710                 void clear() {type = 0;}
711                 void select_id_RANfunctionIEcause_Item() { set(mandatory); type=1;}
712                 X2AP_PROTOCOL_IES::presence_t const& ref_value() const {return ref_nested();}
713                 template<typename V>  bool decode(V& v)
714                 {
715                         clear();
716                         if(!v(ref_nested())) return false;
717                         if(equal(mandatory)) { type = 1; return true; }
718                         else { type = 2; return true;}
719                         return false;
720
721                 }
722                 template<typename V> bool encode(V& v) const
723                 {
724                         return v(ref_nested());
725
726                 }
727                 protected:
728                 template<typename V>  bool decode(size_t index, V& v)
729                 {
730                         clear();
731                         switch(index)
732                         {
733                         case 1: type = 1; if(v(ref_nested())) { return equal(mandatory);} return false;
734                         case 2: type = 2; return v(ref_nested());
735                         ref_nested().clear();
736                         }
737                         return false;
738
739                 }
740                 template<typename V> bool encode(size_t index, V& v) const
741                 {
742                         if(index != type) {return false;} return v(ref_nested());
743
744                 }
745                 private:
746                 size_t type {0};
747
748         };
749
750 };
751 /*
752 RANfunctions-List ::= SEQUENCE (SIZE(0..maxofRANfunctionID)) OF ProtocolIE-Single-Container { {RANfunction-ItemIEs} }
753 */
754
755 struct RANfunctions_List_elm : ProtocolIE_Single_Container<RANfunction_ItemIEs>
756 {
757         static constexpr const char* name() {return "RANfunctions_List_elm";}
758         using parent_t = ProtocolIE_Single_Container<RANfunction_ItemIEs>;
759
760 };
761 struct RANfunctions_List : asn::sequenceof<RANfunctions_List_elm>
762 {
763         static constexpr const char* name() {return "RANfunctions-List";}
764         using parent_t = asn::sequenceof<RANfunctions_List_elm>;
765         using constraint_t = asn::constraints<false,asn::span<0,  maxofRANfunctionID >>;
766
767 };
768 /*
769 RANfunctionsID-List ::= SEQUENCE (SIZE(0..maxofRANfunctionID)) OF ProtocolIE-Single-Container{{RANfunctionID-ItemIEs}}
770 */
771
772 struct RANfunctionsID_List_elm : ProtocolIE_Single_Container<RANfunctionID_ItemIEs>
773 {
774         static constexpr const char* name() {return "RANfunctionsID_List_elm";}
775         using parent_t = ProtocolIE_Single_Container<RANfunctionID_ItemIEs>;
776
777 };
778 struct RANfunctionsID_List : asn::sequenceof<RANfunctionsID_List_elm>
779 {
780         static constexpr const char* name() {return "RANfunctionsID-List";}
781         using parent_t = asn::sequenceof<RANfunctionsID_List_elm>;
782         using constraint_t = asn::constraints<false,asn::span<0,  maxofRANfunctionID >>;
783
784 };
785 /*
786 RANfunctionsIDcause-List ::= SEQUENCE (SIZE(0..maxofRANfunctionID)) OF ProtocolIE-Single-Container { {RANfunctionIDcause-ItemIEs} }
787 */
788
789 struct RANfunctionsIDcause_List_elm : ProtocolIE_Single_Container<RANfunctionIDcause_ItemIEs>
790 {
791         static constexpr const char* name() {return "RANfunctionsIDcause_List_elm";}
792         using parent_t = ProtocolIE_Single_Container<RANfunctionIDcause_ItemIEs>;
793
794 };
795 struct RANfunctionsIDcause_List : asn::sequenceof<RANfunctionsIDcause_List_elm>
796 {
797         static constexpr const char* name() {return "RANfunctionsIDcause-List";}
798         using parent_t = asn::sequenceof<RANfunctionsIDcause_List_elm>;
799         using constraint_t = asn::constraints<false,asn::span<0,  maxofRANfunctionID >>;
800
801 };
802 /*
803 RICaction-Admitted-Item ::= SEQUENCE {
804         ricActionID                                     RICactionID,
805         ...
806 }
807 */
808
809 struct RICaction_Admitted_Item : asn::sequence<1, 0, true, 0>
810 {
811         static constexpr const char* name() {return "RICaction-Admitted-Item";}
812         using parent_t = asn::sequence<1, 0, true, 0>;
813         struct ricActionID_t : RICactionID
814         {
815                 static constexpr const char* name() {return "ricActionID_t";}
816                 using parent_t = RICactionID;
817
818         };
819         ricActionID_t& ref_ricActionID() {return ricActionID;}
820         ricActionID_t const& ref_ricActionID() const {return ricActionID;}
821         template<typename V> void decode(V& v)
822         {
823                 v(ricActionID);
824
825         };
826         template<typename V> void encode(V& v) const
827         {
828                 v(ricActionID);
829
830         };
831         void clear()
832         {
833                 ricActionID.clear();
834
835         };
836         private:
837         ricActionID_t   ricActionID;
838
839 };
840 /*
841 RICaction-Admitted-ItemIEs X2AP-PROTOCOL-IES ::= {
842         { ID id-RICaction-Admitted-Item         CRITICALITY ignore              TYPE RICaction-Admitted-Item    PRESENCE mandatory },
843         ...
844 }
845 */
846
847 struct RICaction_Admitted_ItemIEs
848 {
849         struct id_t : asn::fixedtypefield<X2AP_PROTOCOL_IES::id_t, true>
850         {
851                 size_t get_index() const {return type;}
852                 bool is_unknown() const { return type == 2; }
853                 void clear() {type = 0;}
854                 void select_id_RICaction_Admitted_Item() { set(id_RICaction_Admitted_Item); type=1;}
855                 X2AP_PROTOCOL_IES::id_t const& ref_value() const {return ref_nested();}
856                 template<typename V>  bool decode(V& v)
857                 {
858                         clear();
859                         if(!v(ref_nested())) return false;
860                         if(equal(id_RICaction_Admitted_Item)) { type = 1; return true; }
861                         else { type = 2; return true;}
862                         return false;
863
864                 }
865                 template<typename V> bool encode(V& v) const
866                 {
867                         return v(ref_nested());
868
869                 }
870                 protected:
871                 template<typename V>  bool decode(size_t index, V& v)
872                 {
873                         clear();
874                         switch(index)
875                         {
876                         case 1: type = 1; if(v(ref_nested())) { return equal(id_RICaction_Admitted_Item);} return false;
877                         case 2: type = 2; return v(ref_nested());
878                         ref_nested().clear();
879                         }
880                         return false;
881
882                 }
883                 template<typename V> bool encode(size_t index, V& v) const
884                 {
885                         if(index != type) {return false;} return v(ref_nested());
886
887                 }
888                 private:
889                 size_t type {0};
890
891         };
892         struct criticality_t : asn::fixedtypefield<X2AP_PROTOCOL_IES::criticality_t, true>
893         {
894                 size_t get_index() const {return type;}
895                 bool is_unknown() const { return type == 2; }
896                 void clear() {type = 0;}
897                 void select_id_RICaction_Admitted_Item() { set(ignore); type=1;}
898                 X2AP_PROTOCOL_IES::criticality_t const& ref_value() const {return ref_nested();}
899                 template<typename V>  bool decode(V& v)
900                 {
901                         clear();
902                         if(!v(ref_nested())) return false;
903                         if(equal(ignore)) { type = 1; return true; }
904                         else { type = 2; return true;}
905                         return false;
906
907                 }
908                 template<typename V> bool encode(V& v) const
909                 {
910                         return v(ref_nested());
911
912                 }
913                 protected:
914                 template<typename V>  bool decode(size_t index, V& v)
915                 {
916                         clear();
917                         switch(index)
918                         {
919                         case 1: type = 1; if(v(ref_nested())) { return equal(ignore);} return false;
920                         case 2: type = 2; return v(ref_nested());
921                         ref_nested().clear();
922                         }
923                         return false;
924
925                 }
926                 template<typename V> bool encode(size_t index, V& v) const
927                 {
928                         if(index != type) {return false;} return v(ref_nested());
929
930                 }
931                 private:
932                 size_t type {0};
933
934         };
935         struct Value_t : asn::typefield<true>
936         {
937                 ~Value_t()      {clear();}
938                 size_t get_index() const {return type;}
939                 RICaction_Admitted_Item& select_id_RICaction_Admitted_Item() { return set<RICaction_Admitted_Item>(1); }
940                 RICaction_Admitted_Item const* get_id_RICaction_Admitted_Item() const { return get<RICaction_Admitted_Item>(1); }
941                 bool is_unknown() const { return type == 2; }
942                 void clear()
943                 {
944                         switch(type)
945                         {
946                         case 1: var.destroy<RICaction_Admitted_Item>(); break;
947                         }
948                         type = 0; ref_nested().clear();
949                 }
950                 template<typename V> static inline void enumerate(V& v)
951                 {
952                         v.template operator()<RICaction_Admitted_Item>(1);
953
954                 }
955                 protected:
956                 template<typename V> bool decode(size_t index, V& v)
957                 {
958                         clear();
959                         switch(index)
960                         {
961                         case 1: v(select_id_RICaction_Admitted_Item()); return true;
962                         case 2: if(type != 2) {clear(); asn::base::set();} type = 2; return true;
963                         }
964                         return false;
965
966                 }
967                 template<typename V> bool encode(size_t index, V& v) const
968                 {
969                         if(index != type) return false;
970                         switch(type)
971                         {
972                         case 1: v(var.as<RICaction_Admitted_Item>()); return true;
973                         }
974                         return false;
975
976                 }
977                 private:
978                 template<class T> T& set(size_t index) {if(type != index) {clear(); type = index; return var.build<T>();} return var.as<T>();}
979                 template<class T> T const* get(size_t index) const {if(type == index) {return &var.as<T>();} return nullptr;}
980                 union union_type
981                 {
982                         char dummy1[sizeof(RICaction_Admitted_Item)];
983
984                 };
985                 asn::variant<sizeof(union_type)> var;
986                 size_t type {0};
987
988         };
989         struct presence_t : asn::fixedtypefield<X2AP_PROTOCOL_IES::presence_t, true>
990         {
991                 size_t get_index() const {return type;}
992                 bool is_unknown() const { return type == 2; }
993                 void clear() {type = 0;}
994                 void select_id_RICaction_Admitted_Item() { set(mandatory); type=1;}
995                 X2AP_PROTOCOL_IES::presence_t const& ref_value() const {return ref_nested();}
996                 template<typename V>  bool decode(V& v)
997                 {
998                         clear();
999                         if(!v(ref_nested())) return false;
1000                         if(equal(mandatory)) { type = 1; return true; }
1001                         else { type = 2; return true;}
1002                         return false;
1003
1004                 }
1005                 template<typename V> bool encode(V& v) const
1006                 {
1007                         return v(ref_nested());
1008
1009                 }
1010                 protected:
1011                 template<typename V>  bool decode(size_t index, V& v)
1012                 {
1013                         clear();
1014                         switch(index)
1015                         {
1016                         case 1: type = 1; if(v(ref_nested())) { return equal(mandatory);} return false;
1017                         case 2: type = 2; return v(ref_nested());
1018                         ref_nested().clear();
1019                         }
1020                         return false;
1021
1022                 }
1023                 template<typename V> bool encode(size_t index, V& v) const
1024                 {
1025                         if(index != type) {return false;} return v(ref_nested());
1026
1027                 }
1028                 private:
1029                 size_t type {0};
1030
1031         };
1032
1033 };
1034 /*
1035 RICaction-Admitted-List ::= SEQUENCE (SIZE(1..maxofRICactionID)) OF ProtocolIE-Single-Container{{RICaction-Admitted-ItemIEs}}
1036 */
1037
1038 struct RICaction_Admitted_List_elm : ProtocolIE_Single_Container<RICaction_Admitted_ItemIEs>
1039 {
1040         static constexpr const char* name() {return "RICaction_Admitted_List_elm";}
1041         using parent_t = ProtocolIE_Single_Container<RICaction_Admitted_ItemIEs>;
1042
1043 };
1044 struct RICaction_Admitted_List : asn::sequenceof<RICaction_Admitted_List_elm>
1045 {
1046         static constexpr const char* name() {return "RICaction-Admitted-List";}
1047         using parent_t = asn::sequenceof<RICaction_Admitted_List_elm>;
1048         using constraint_t = asn::constraints<false,asn::span<1,  maxofRICactionID >>;
1049
1050 };
1051 /*
1052 RICaction-NotAdmitted-Item ::= SEQUENCE {
1053         ricActionID                                     RICactionID,
1054         ricCause                                        RICcause,
1055         ...
1056 }
1057 */
1058
1059 struct RICaction_NotAdmitted_Item : asn::sequence<2, 0, true, 0>
1060 {
1061         static constexpr const char* name() {return "RICaction-NotAdmitted-Item";}
1062         using parent_t = asn::sequence<2, 0, true, 0>;
1063         struct ricActionID_t : RICactionID
1064         {
1065                 static constexpr const char* name() {return "ricActionID_t";}
1066                 using parent_t = RICactionID;
1067
1068         };
1069         ricActionID_t& ref_ricActionID() {return ricActionID;}
1070         ricActionID_t const& ref_ricActionID() const {return ricActionID;}
1071         struct ricCause_t : RICcause
1072         {
1073                 static constexpr const char* name() {return "ricCause_t";}
1074                 using parent_t = RICcause;
1075
1076         };
1077         ricCause_t& ref_ricCause() {return ricCause;}
1078         ricCause_t const& ref_ricCause() const {return ricCause;}
1079         template<typename V> void decode(V& v)
1080         {
1081                 v(ricActionID);
1082                 v(ricCause);
1083
1084         };
1085         template<typename V> void encode(V& v) const
1086         {
1087                 v(ricActionID);
1088                 v(ricCause);
1089
1090         };
1091         void clear()
1092         {
1093                 ricActionID.clear();
1094                 ricCause.clear();
1095
1096         };
1097         private:
1098         ricActionID_t   ricActionID;
1099         ricCause_t      ricCause;
1100
1101 };
1102 /*
1103 RICaction-NotAdmitted-ItemIEs X2AP-PROTOCOL-IES ::= {
1104         { ID id-RICaction-NotAdmitted-Item      CRITICALITY ignore      TYPE RICaction-NotAdmitted-Item         PRESENCE mandatory },
1105         ...
1106 }
1107 */
1108
1109 struct RICaction_NotAdmitted_ItemIEs
1110 {
1111         struct id_t : asn::fixedtypefield<X2AP_PROTOCOL_IES::id_t, true>
1112         {
1113                 size_t get_index() const {return type;}
1114                 bool is_unknown() const { return type == 2; }
1115                 void clear() {type = 0;}
1116                 void select_id_RICaction_NotAdmitted_Item() { set(id_RICaction_NotAdmitted_Item); type=1;}
1117                 X2AP_PROTOCOL_IES::id_t const& ref_value() const {return ref_nested();}
1118                 template<typename V>  bool decode(V& v)
1119                 {
1120                         clear();
1121                         if(!v(ref_nested())) return false;
1122                         if(equal(id_RICaction_NotAdmitted_Item)) { type = 1; return true; }
1123                         else { type = 2; return true;}
1124                         return false;
1125
1126                 }
1127                 template<typename V> bool encode(V& v) const
1128                 {
1129                         return v(ref_nested());
1130
1131                 }
1132                 protected:
1133                 template<typename V>  bool decode(size_t index, V& v)
1134                 {
1135                         clear();
1136                         switch(index)
1137                         {
1138                         case 1: type = 1; if(v(ref_nested())) { return equal(id_RICaction_NotAdmitted_Item);} return false;
1139                         case 2: type = 2; return v(ref_nested());
1140                         ref_nested().clear();
1141                         }
1142                         return false;
1143
1144                 }
1145                 template<typename V> bool encode(size_t index, V& v) const
1146                 {
1147                         if(index != type) {return false;} return v(ref_nested());
1148
1149                 }
1150                 private:
1151                 size_t type {0};
1152
1153         };
1154         struct criticality_t : asn::fixedtypefield<X2AP_PROTOCOL_IES::criticality_t, true>
1155         {
1156                 size_t get_index() const {return type;}
1157                 bool is_unknown() const { return type == 2; }
1158                 void clear() {type = 0;}
1159                 void select_id_RICaction_NotAdmitted_Item() { set(ignore); type=1;}
1160                 X2AP_PROTOCOL_IES::criticality_t const& ref_value() const {return ref_nested();}
1161                 template<typename V>  bool decode(V& v)
1162                 {
1163                         clear();
1164                         if(!v(ref_nested())) return false;
1165                         if(equal(ignore)) { type = 1; return true; }
1166                         else { type = 2; return true;}
1167                         return false;
1168
1169                 }
1170                 template<typename V> bool encode(V& v) const
1171                 {
1172                         return v(ref_nested());
1173
1174                 }
1175                 protected:
1176                 template<typename V>  bool decode(size_t index, V& v)
1177                 {
1178                         clear();
1179                         switch(index)
1180                         {
1181                         case 1: type = 1; if(v(ref_nested())) { return equal(ignore);} return false;
1182                         case 2: type = 2; return v(ref_nested());
1183                         ref_nested().clear();
1184                         }
1185                         return false;
1186
1187                 }
1188                 template<typename V> bool encode(size_t index, V& v) const
1189                 {
1190                         if(index != type) {return false;} return v(ref_nested());
1191
1192                 }
1193                 private:
1194                 size_t type {0};
1195
1196         };
1197         struct Value_t : asn::typefield<true>
1198         {
1199                 ~Value_t()      {clear();}
1200                 size_t get_index() const {return type;}
1201                 RICaction_NotAdmitted_Item& select_id_RICaction_NotAdmitted_Item() { return set<RICaction_NotAdmitted_Item>(1); }
1202                 RICaction_NotAdmitted_Item const* get_id_RICaction_NotAdmitted_Item() const { return get<RICaction_NotAdmitted_Item>(1); }
1203                 bool is_unknown() const { return type == 2; }
1204                 void clear()
1205                 {
1206                         switch(type)
1207                         {
1208                         case 1: var.destroy<RICaction_NotAdmitted_Item>(); break;
1209                         }
1210                         type = 0; ref_nested().clear();
1211                 }
1212                 template<typename V> static inline void enumerate(V& v)
1213                 {
1214                         v.template operator()<RICaction_NotAdmitted_Item>(1);
1215
1216                 }
1217                 protected:
1218                 template<typename V> bool decode(size_t index, V& v)
1219                 {
1220                         clear();
1221                         switch(index)
1222                         {
1223                         case 1: v(select_id_RICaction_NotAdmitted_Item()); return true;
1224                         case 2: if(type != 2) {clear(); asn::base::set();} type = 2; return true;
1225                         }
1226                         return false;
1227
1228                 }
1229                 template<typename V> bool encode(size_t index, V& v) const
1230                 {
1231                         if(index != type) return false;
1232                         switch(type)
1233                         {
1234                         case 1: v(var.as<RICaction_NotAdmitted_Item>()); return true;
1235                         }
1236                         return false;
1237
1238                 }
1239                 private:
1240                 template<class T> T& set(size_t index) {if(type != index) {clear(); type = index; return var.build<T>();} return var.as<T>();}
1241                 template<class T> T const* get(size_t index) const {if(type == index) {return &var.as<T>();} return nullptr;}
1242                 union union_type
1243                 {
1244                         char dummy1[sizeof(RICaction_NotAdmitted_Item)];
1245
1246                 };
1247                 asn::variant<sizeof(union_type)> var;
1248                 size_t type {0};
1249
1250         };
1251         struct presence_t : asn::fixedtypefield<X2AP_PROTOCOL_IES::presence_t, true>
1252         {
1253                 size_t get_index() const {return type;}
1254                 bool is_unknown() const { return type == 2; }
1255                 void clear() {type = 0;}
1256                 void select_id_RICaction_NotAdmitted_Item() { set(mandatory); type=1;}
1257                 X2AP_PROTOCOL_IES::presence_t const& ref_value() const {return ref_nested();}
1258                 template<typename V>  bool decode(V& v)
1259                 {
1260                         clear();
1261                         if(!v(ref_nested())) return false;
1262                         if(equal(mandatory)) { type = 1; return true; }
1263                         else { type = 2; return true;}
1264                         return false;
1265
1266                 }
1267                 template<typename V> bool encode(V& v) const
1268                 {
1269                         return v(ref_nested());
1270
1271                 }
1272                 protected:
1273                 template<typename V>  bool decode(size_t index, V& v)
1274                 {
1275                         clear();
1276                         switch(index)
1277                         {
1278                         case 1: type = 1; if(v(ref_nested())) { return equal(mandatory);} return false;
1279                         case 2: type = 2; return v(ref_nested());
1280                         ref_nested().clear();
1281                         }
1282                         return false;
1283
1284                 }
1285                 template<typename V> bool encode(size_t index, V& v) const
1286                 {
1287                         if(index != type) {return false;} return v(ref_nested());
1288
1289                 }
1290                 private:
1291                 size_t type {0};
1292
1293         };
1294
1295 };
1296 /*
1297 RICaction-NotAdmitted-List ::= SEQUENCE (SIZE(0..maxofRICactionID)) OF ProtocolIE-Single-Container { {RICaction-NotAdmitted-ItemIEs} }
1298 */
1299
1300 struct RICaction_NotAdmitted_List_elm : ProtocolIE_Single_Container<RICaction_NotAdmitted_ItemIEs>
1301 {
1302         static constexpr const char* name() {return "RICaction_NotAdmitted_List_elm";}
1303         using parent_t = ProtocolIE_Single_Container<RICaction_NotAdmitted_ItemIEs>;
1304
1305 };
1306 struct RICaction_NotAdmitted_List : asn::sequenceof<RICaction_NotAdmitted_List_elm>
1307 {
1308         static constexpr const char* name() {return "RICaction-NotAdmitted-List";}
1309         using parent_t = asn::sequenceof<RICaction_NotAdmitted_List_elm>;
1310         using constraint_t = asn::constraints<false,asn::span<0,  maxofRICactionID >>;
1311
1312 };
1313 /*
1314 RICaction-ToBeSetup-Item ::= SEQUENCE {
1315         ricActionID                                     RICactionID,
1316         ricActionType                           RICactionType,
1317         ricActionDefinition                     RICactionDefinition     OPTIONAL,
1318         ricSubsequentAction                     RICsubsequentAction     OPTIONAL,
1319         ...
1320 }
1321 */
1322
1323 struct RICaction_ToBeSetup_Item : asn::sequence<4, 0, true, 2>
1324 {
1325         static constexpr const char* name() {return "RICaction-ToBeSetup-Item";}
1326         using parent_t = asn::sequence<4, 0, true, 2>;
1327         struct ricActionID_t : RICactionID
1328         {
1329                 static constexpr const char* name() {return "ricActionID_t";}
1330                 using parent_t = RICactionID;
1331
1332         };
1333         ricActionID_t& ref_ricActionID() {return ricActionID;}
1334         ricActionID_t const& ref_ricActionID() const {return ricActionID;}
1335         struct ricActionType_t : RICactionType
1336         {
1337                 static constexpr const char* name() {return "ricActionType_t";}
1338                 using parent_t = RICactionType;
1339
1340         };
1341         ricActionType_t& ref_ricActionType() {return ricActionType;}
1342         ricActionType_t const& ref_ricActionType() const {return ricActionType;}
1343         struct ricActionDefinition_t : RICactionDefinition
1344         {
1345                 static constexpr const char* name() {return "ricActionDefinition_t";}
1346                 using parent_t = RICactionDefinition;
1347                 static constexpr bool optional = true;
1348
1349         };
1350         ricActionDefinition_t& set_ricActionDefinition() { ricActionDefinition.setpresent(true); return ricActionDefinition;}
1351         ricActionDefinition_t const* get_ricActionDefinition() const {return ricActionDefinition.is_valid() ? &ricActionDefinition : nullptr;}
1352         struct ricSubsequentAction_t : RICsubsequentAction
1353         {
1354                 static constexpr const char* name() {return "ricSubsequentAction_t";}
1355                 using parent_t = RICsubsequentAction;
1356                 static constexpr bool optional = true;
1357
1358         };
1359         ricSubsequentAction_t& set_ricSubsequentAction() { ricSubsequentAction.setpresent(true); return ricSubsequentAction;}
1360         ricSubsequentAction_t const* get_ricSubsequentAction() const {return ricSubsequentAction.is_valid() ? &ricSubsequentAction : nullptr;}
1361         template<typename V> void decode(V& v)
1362         {
1363                 v(ricActionID);
1364                 v(ricActionType);
1365                 v(ricActionDefinition);
1366                 v(ricSubsequentAction);
1367
1368         };
1369         template<typename V> void encode(V& v) const
1370         {
1371                 v(ricActionID);
1372                 v(ricActionType);
1373                 v(ricActionDefinition);
1374                 v(ricSubsequentAction);
1375
1376         };
1377         void clear()
1378         {
1379                 ricActionID.clear();
1380                 ricActionType.clear();
1381                 ricActionDefinition.clear();
1382                 ricSubsequentAction.clear();
1383
1384         };
1385         private:
1386         ricActionID_t   ricActionID;
1387         ricActionType_t ricActionType;
1388         ricActionDefinition_t   ricActionDefinition;
1389         ricSubsequentAction_t   ricSubsequentAction;
1390
1391 };
1392 /*
1393 RICaction-ToBeSetup-ItemIEs     X2AP-PROTOCOL-IES ::= {
1394         { ID id-RICaction-ToBeSetup-Item         CRITICALITY ignore     TYPE RICaction-ToBeSetup-Item   PRESENCE mandatory },
1395         ...
1396 }
1397 */
1398
1399 struct RICaction_ToBeSetup_ItemIEs
1400 {
1401         struct id_t : asn::fixedtypefield<X2AP_PROTOCOL_IES::id_t, true>
1402         {
1403                 size_t get_index() const {return type;}
1404                 bool is_unknown() const { return type == 2; }
1405                 void clear() {type = 0;}
1406                 void select_id_RICaction_ToBeSetup_Item() { set(id_RICaction_ToBeSetup_Item); type=1;}
1407                 X2AP_PROTOCOL_IES::id_t const& ref_value() const {return ref_nested();}
1408                 template<typename V>  bool decode(V& v)
1409                 {
1410                         clear();
1411                         if(!v(ref_nested())) return false;
1412                         if(equal(id_RICaction_ToBeSetup_Item)) { type = 1; return true; }
1413                         else { type = 2; return true;}
1414                         return false;
1415
1416                 }
1417                 template<typename V> bool encode(V& v) const
1418                 {
1419                         return v(ref_nested());
1420
1421                 }
1422                 protected:
1423                 template<typename V>  bool decode(size_t index, V& v)
1424                 {
1425                         clear();
1426                         switch(index)
1427                         {
1428                         case 1: type = 1; if(v(ref_nested())) { return equal(id_RICaction_ToBeSetup_Item);} return false;
1429                         case 2: type = 2; return v(ref_nested());
1430                         ref_nested().clear();
1431                         }
1432                         return false;
1433
1434                 }
1435                 template<typename V> bool encode(size_t index, V& v) const
1436                 {
1437                         if(index != type) {return false;} return v(ref_nested());
1438
1439                 }
1440                 private:
1441                 size_t type {0};
1442
1443         };
1444         struct criticality_t : asn::fixedtypefield<X2AP_PROTOCOL_IES::criticality_t, true>
1445         {
1446                 size_t get_index() const {return type;}
1447                 bool is_unknown() const { return type == 2; }
1448                 void clear() {type = 0;}
1449                 void select_id_RICaction_ToBeSetup_Item() { set(ignore); type=1;}
1450                 X2AP_PROTOCOL_IES::criticality_t const& ref_value() const {return ref_nested();}
1451                 template<typename V>  bool decode(V& v)
1452                 {
1453                         clear();
1454                         if(!v(ref_nested())) return false;
1455                         if(equal(ignore)) { type = 1; return true; }
1456                         else { type = 2; return true;}
1457                         return false;
1458
1459                 }
1460                 template<typename V> bool encode(V& v) const
1461                 {
1462                         return v(ref_nested());
1463
1464                 }
1465                 protected:
1466                 template<typename V>  bool decode(size_t index, V& v)
1467                 {
1468                         clear();
1469                         switch(index)
1470                         {
1471                         case 1: type = 1; if(v(ref_nested())) { return equal(ignore);} return false;
1472                         case 2: type = 2; return v(ref_nested());
1473                         ref_nested().clear();
1474                         }
1475                         return false;
1476
1477                 }
1478                 template<typename V> bool encode(size_t index, V& v) const
1479                 {
1480                         if(index != type) {return false;} return v(ref_nested());
1481
1482                 }
1483                 private:
1484                 size_t type {0};
1485
1486         };
1487         struct Value_t : asn::typefield<true>
1488         {
1489                 ~Value_t()      {clear();}
1490                 size_t get_index() const {return type;}
1491                 RICaction_ToBeSetup_Item& select_id_RICaction_ToBeSetup_Item() { return set<RICaction_ToBeSetup_Item>(1); }
1492                 RICaction_ToBeSetup_Item const* get_id_RICaction_ToBeSetup_Item() const { return get<RICaction_ToBeSetup_Item>(1); }
1493                 bool is_unknown() const { return type == 2; }
1494                 void clear()
1495                 {
1496                         switch(type)
1497                         {
1498                         case 1: var.destroy<RICaction_ToBeSetup_Item>(); break;
1499                         }
1500                         type = 0; ref_nested().clear();
1501                 }
1502                 template<typename V> static inline void enumerate(V& v)
1503                 {
1504                         v.template operator()<RICaction_ToBeSetup_Item>(1);
1505
1506                 }
1507                 protected:
1508                 template<typename V> bool decode(size_t index, V& v)
1509                 {
1510                         clear();
1511                         switch(index)
1512                         {
1513                         case 1: v(select_id_RICaction_ToBeSetup_Item()); return true;
1514                         case 2: if(type != 2) {clear(); asn::base::set();} type = 2; return true;
1515                         }
1516                         return false;
1517
1518                 }
1519                 template<typename V> bool encode(size_t index, V& v) const
1520                 {
1521                         if(index != type) return false;
1522                         switch(type)
1523                         {
1524                         case 1: v(var.as<RICaction_ToBeSetup_Item>()); return true;
1525                         }
1526                         return false;
1527
1528                 }
1529                 private:
1530                 template<class T> T& set(size_t index) {if(type != index) {clear(); type = index; return var.build<T>();} return var.as<T>();}
1531                 template<class T> T const* get(size_t index) const {if(type == index) {return &var.as<T>();} return nullptr;}
1532                 union union_type
1533                 {
1534                         char dummy1[sizeof(RICaction_ToBeSetup_Item)];
1535
1536                 };
1537                 asn::variant<sizeof(union_type)> var;
1538                 size_t type {0};
1539
1540         };
1541         struct presence_t : asn::fixedtypefield<X2AP_PROTOCOL_IES::presence_t, true>
1542         {
1543                 size_t get_index() const {return type;}
1544                 bool is_unknown() const { return type == 2; }
1545                 void clear() {type = 0;}
1546                 void select_id_RICaction_ToBeSetup_Item() { set(mandatory); type=1;}
1547                 X2AP_PROTOCOL_IES::presence_t const& ref_value() const {return ref_nested();}
1548                 template<typename V>  bool decode(V& v)
1549                 {
1550                         clear();
1551                         if(!v(ref_nested())) return false;
1552                         if(equal(mandatory)) { type = 1; return true; }
1553                         else { type = 2; return true;}
1554                         return false;
1555
1556                 }
1557                 template<typename V> bool encode(V& v) const
1558                 {
1559                         return v(ref_nested());
1560
1561                 }
1562                 protected:
1563                 template<typename V>  bool decode(size_t index, V& v)
1564                 {
1565                         clear();
1566                         switch(index)
1567                         {
1568                         case 1: type = 1; if(v(ref_nested())) { return equal(mandatory);} return false;
1569                         case 2: type = 2; return v(ref_nested());
1570                         ref_nested().clear();
1571                         }
1572                         return false;
1573
1574                 }
1575                 template<typename V> bool encode(size_t index, V& v) const
1576                 {
1577                         if(index != type) {return false;} return v(ref_nested());
1578
1579                 }
1580                 private:
1581                 size_t type {0};
1582
1583         };
1584
1585 };
1586 /*
1587 RICactions-ToBeSetup-List ::= SEQUENCE (SIZE(1..maxofRICactionID)) OF ProtocolIE-Single-Container { {RICaction-ToBeSetup-ItemIEs} }
1588 */
1589
1590 struct RICactions_ToBeSetup_List_elm : ProtocolIE_Single_Container<RICaction_ToBeSetup_ItemIEs>
1591 {
1592         static constexpr const char* name() {return "RICactions_ToBeSetup_List_elm";}
1593         using parent_t = ProtocolIE_Single_Container<RICaction_ToBeSetup_ItemIEs>;
1594
1595 };
1596 struct RICactions_ToBeSetup_List : asn::sequenceof<RICactions_ToBeSetup_List_elm>
1597 {
1598         static constexpr const char* name() {return "RICactions-ToBeSetup-List";}
1599         using parent_t = asn::sequenceof<RICactions_ToBeSetup_List_elm>;
1600         using constraint_t = asn::constraints<false,asn::span<1,  maxofRICactionID >>;
1601
1602 };
1603 /*
1604 RICcontrolAcknowledge-IEs X2AP-PROTOCOL-IES ::= {
1605         { ID id-RICrequestID                            CRITICALITY reject      TYPE RICrequestID                                       PRESENCE mandatory}|
1606         { ID id-RANfunctionID                           CRITICALITY reject      TYPE RANfunctionID                                      PRESENCE mandatory}|
1607         { ID id-RICcallProcessID                        CRITICALITY reject      TYPE RICcallProcessID                           PRESENCE optional}|
1608         { ID id-RICcontrolStatus                        CRITICALITY reject      TYPE RICcontrolStatus                           PRESENCE mandatory},
1609     ...
1610 }
1611 */
1612
1613 struct RICcontrolAcknowledge_IEs
1614 {
1615         struct id_t : asn::fixedtypefield<X2AP_PROTOCOL_IES::id_t, true>
1616         {
1617                 size_t get_index() const {return type;}
1618                 bool is_unknown() const { return type == 5; }
1619                 void clear() {type = 0;}
1620                 void select_id_RICrequestID() { set(id_RICrequestID); type=1;}
1621                 void select_id_RANfunctionID() { set(id_RANfunctionID); type=2;}
1622                 void select_id_RICcallProcessID() { set(id_RICcallProcessID); type=3;}
1623                 void select_id_RICcontrolStatus() { set(id_RICcontrolStatus); type=4;}
1624                 X2AP_PROTOCOL_IES::id_t const& ref_value() const {return ref_nested();}
1625                 template<typename V>  bool decode(V& v)
1626                 {
1627                         clear();
1628                         if(!v(ref_nested())) return false;
1629                         if(equal(id_RICrequestID)) { type = 1; return true; }
1630                         else if(equal(id_RANfunctionID)) { type = 2; return true; }
1631                         else if(equal(id_RICcallProcessID)) { type = 3; return true; }
1632                         else if(equal(id_RICcontrolStatus)) { type = 4; return true; }
1633                         else { type = 5; return true;}
1634                         return false;
1635
1636                 }
1637                 template<typename V> bool encode(V& v) const
1638                 {
1639                         return v(ref_nested());
1640
1641                 }
1642                 protected:
1643                 template<typename V>  bool decode(size_t index, V& v)
1644                 {
1645                         clear();
1646                         switch(index)
1647                         {
1648                         case 1: type = 1; if(v(ref_nested())) { return equal(id_RICrequestID);} return false;
1649                         case 2: type = 2; if(v(ref_nested())) { return equal(id_RANfunctionID);} return false;
1650                         case 3: type = 3; if(v(ref_nested())) { return equal(id_RICcallProcessID);} return false;
1651                         case 4: type = 4; if(v(ref_nested())) { return equal(id_RICcontrolStatus);} return false;
1652                         case 5: type = 5; return v(ref_nested());
1653                         ref_nested().clear();
1654                         }
1655                         return false;
1656
1657                 }
1658                 template<typename V> bool encode(size_t index, V& v) const
1659                 {
1660                         if(index != type) {return false;} return v(ref_nested());
1661
1662                 }
1663                 private:
1664                 size_t type {0};
1665
1666         };
1667         struct criticality_t : asn::fixedtypefield<X2AP_PROTOCOL_IES::criticality_t, true>
1668         {
1669                 size_t get_index() const {return type;}
1670                 bool is_unknown() const { return type == 5; }
1671                 void clear() {type = 0;}
1672                 void select_id_RICrequestID() { set(reject); type=1;}
1673                 void select_id_RANfunctionID() { set(reject); type=2;}
1674                 void select_id_RICcallProcessID() { set(reject); type=3;}
1675                 void select_id_RICcontrolStatus() { set(reject); type=4;}
1676                 X2AP_PROTOCOL_IES::criticality_t const& ref_value() const {return ref_nested();}
1677                 template<typename V>  bool decode(V& v)
1678                 {
1679                         clear();
1680                         if(!v(ref_nested())) return false;
1681                         if(equal(reject)) { type = 1; return true; }
1682                         else if(equal(reject)) { type = 2; return true; }
1683                         else if(equal(reject)) { type = 3; return true; }
1684                         else if(equal(reject)) { type = 4; return true; }
1685                         else { type = 5; return true;}
1686                         return false;
1687
1688                 }
1689                 template<typename V> bool encode(V& v) const
1690                 {
1691                         return v(ref_nested());
1692
1693                 }
1694                 protected:
1695                 template<typename V>  bool decode(size_t index, V& v)
1696                 {
1697                         clear();
1698                         switch(index)
1699                         {
1700                         case 1: type = 1; if(v(ref_nested())) { return equal(reject);} return false;
1701                         case 2: type = 2; if(v(ref_nested())) { return equal(reject);} return false;
1702                         case 3: type = 3; if(v(ref_nested())) { return equal(reject);} return false;
1703                         case 4: type = 4; if(v(ref_nested())) { return equal(reject);} return false;
1704                         case 5: type = 5; return v(ref_nested());
1705                         ref_nested().clear();
1706                         }
1707                         return false;
1708
1709                 }
1710                 template<typename V> bool encode(size_t index, V& v) const
1711                 {
1712                         if(index != type) {return false;} return v(ref_nested());
1713
1714                 }
1715                 private:
1716                 size_t type {0};
1717
1718         };
1719         struct Value_t : asn::typefield<true>
1720         {
1721                 ~Value_t()      {clear();}
1722                 size_t get_index() const {return type;}
1723                 RICrequestID& select_id_RICrequestID() { return set<RICrequestID>(1); }
1724                 RICrequestID const* get_id_RICrequestID() const { return get<RICrequestID>(1); }
1725                 RANfunctionID& select_id_RANfunctionID() { return set<RANfunctionID>(2); }
1726                 RANfunctionID const* get_id_RANfunctionID() const { return get<RANfunctionID>(2); }
1727                 RICcallProcessID& select_id_RICcallProcessID() { return set<RICcallProcessID>(3); }
1728                 RICcallProcessID const* get_id_RICcallProcessID() const { return get<RICcallProcessID>(3); }
1729                 RICcontrolStatus& select_id_RICcontrolStatus() { return set<RICcontrolStatus>(4); }
1730                 RICcontrolStatus const* get_id_RICcontrolStatus() const { return get<RICcontrolStatus>(4); }
1731                 bool is_unknown() const { return type == 5; }
1732                 void clear()
1733                 {
1734                         switch(type)
1735                         {
1736                         case 1: var.destroy<RICrequestID>(); break;
1737                         case 2: var.destroy<RANfunctionID>(); break;
1738                         case 3: var.destroy<RICcallProcessID>(); break;
1739                         case 4: var.destroy<RICcontrolStatus>(); break;
1740                         }
1741                         type = 0; ref_nested().clear();
1742                 }
1743                 template<typename V> static inline void enumerate(V& v)
1744                 {
1745                         v.template operator()<RICrequestID>(1);
1746                         v.template operator()<RANfunctionID>(2);
1747                         v.template operator()<RICcallProcessID>(3);
1748                         v.template operator()<RICcontrolStatus>(4);
1749
1750                 }
1751                 protected:
1752                 template<typename V> bool decode(size_t index, V& v)
1753                 {
1754                         clear();
1755                         switch(index)
1756                         {
1757                         case 1: v(select_id_RICrequestID()); return true;
1758                         case 2: v(select_id_RANfunctionID()); return true;
1759                         case 3: v(select_id_RICcallProcessID()); return true;
1760                         case 4: v(select_id_RICcontrolStatus()); return true;
1761                         case 5: if(type != 5) {clear(); asn::base::set();} type = 5; return true;
1762                         }
1763                         return false;
1764
1765                 }
1766                 template<typename V> bool encode(size_t index, V& v) const
1767                 {
1768                         if(index != type) return false;
1769                         switch(type)
1770                         {
1771                         case 1: v(var.as<RICrequestID>()); return true;
1772                         case 2: v(var.as<RANfunctionID>()); return true;
1773                         case 3: v(var.as<RICcallProcessID>()); return true;
1774                         case 4: v(var.as<RICcontrolStatus>()); return true;
1775                         }
1776                         return false;
1777
1778                 }
1779                 private:
1780                 template<class T> T& set(size_t index) {if(type != index) {clear(); type = index; return var.build<T>();} return var.as<T>();}
1781                 template<class T> T const* get(size_t index) const {if(type == index) {return &var.as<T>();} return nullptr;}
1782                 union union_type
1783                 {
1784                         char dummy1[sizeof(RANfunctionID)];
1785                         char dummy2[sizeof(RICcallProcessID)];
1786                         char dummy3[sizeof(RICcontrolStatus)];
1787                         char dummy4[sizeof(RICrequestID)];
1788
1789                 };
1790                 asn::variant<sizeof(union_type)> var;
1791                 size_t type {0};
1792
1793         };
1794         struct presence_t : asn::fixedtypefield<X2AP_PROTOCOL_IES::presence_t, true>
1795         {
1796                 size_t get_index() const {return type;}
1797                 bool is_unknown() const { return type == 5; }
1798                 void clear() {type = 0;}
1799                 void select_id_RICrequestID() { set(mandatory); type=1;}
1800                 void select_id_RANfunctionID() { set(mandatory); type=2;}
1801                 void select_id_RICcallProcessID() { set(optional); type=3;}
1802                 void select_id_RICcontrolStatus() { set(mandatory); type=4;}
1803                 X2AP_PROTOCOL_IES::presence_t const& ref_value() const {return ref_nested();}
1804                 template<typename V>  bool decode(V& v)
1805                 {
1806                         clear();
1807                         if(!v(ref_nested())) return false;
1808                         if(equal(mandatory)) { type = 1; return true; }
1809                         else if(equal(mandatory)) { type = 2; return true; }
1810                         else if(equal(optional)) { type = 3; return true; }
1811                         else if(equal(mandatory)) { type = 4; return true; }
1812                         else { type = 5; return true;}
1813                         return false;
1814
1815                 }
1816                 template<typename V> bool encode(V& v) const
1817                 {
1818                         return v(ref_nested());
1819
1820                 }
1821                 protected:
1822                 template<typename V>  bool decode(size_t index, V& v)
1823                 {
1824                         clear();
1825                         switch(index)
1826                         {
1827                         case 1: type = 1; if(v(ref_nested())) { return equal(mandatory);} return false;
1828                         case 2: type = 2; if(v(ref_nested())) { return equal(mandatory);} return false;
1829                         case 3: type = 3; if(v(ref_nested())) { return equal(optional);} return false;
1830                         case 4: type = 4; if(v(ref_nested())) { return equal(mandatory);} return false;
1831                         case 5: type = 5; return v(ref_nested());
1832                         ref_nested().clear();
1833                         }
1834                         return false;
1835
1836                 }
1837                 template<typename V> bool encode(size_t index, V& v) const
1838                 {
1839                         if(index != type) {return false;} return v(ref_nested());
1840
1841                 }
1842                 private:
1843                 size_t type {0};
1844
1845         };
1846
1847 };
1848 /*
1849 RICcontrolAcknowledge ::= SEQUENCE {
1850         protocolIEs                                     ProtocolIE-Container    {{RICcontrolAcknowledge-IEs}},
1851         ...
1852 }
1853 */
1854
1855 struct RICcontrolAcknowledge : asn::sequence<1, 0, true, 0>
1856 {
1857         static constexpr const char* name() {return "RICcontrolAcknowledge";}
1858         using parent_t = asn::sequence<1, 0, true, 0>;
1859         struct protocolIEs_t : ProtocolIE_Container<RICcontrolAcknowledge_IEs>
1860         {
1861                 static constexpr const char* name() {return "protocolIEs_t";}
1862                 using parent_t = ProtocolIE_Container<RICcontrolAcknowledge_IEs>;
1863
1864         };
1865         protocolIEs_t& ref_protocolIEs() {return protocolIEs;}
1866         protocolIEs_t const& ref_protocolIEs() const {return protocolIEs;}
1867         template<typename V> void decode(V& v)
1868         {
1869                 v(protocolIEs);
1870
1871         };
1872         template<typename V> void encode(V& v) const
1873         {
1874                 v(protocolIEs);
1875
1876         };
1877         void clear()
1878         {
1879                 protocolIEs.clear();
1880
1881         };
1882         private:
1883         protocolIEs_t   protocolIEs;
1884
1885 };
1886 /*
1887 RICcontrolFailure-IEs X2AP-PROTOCOL-IES ::= {
1888         { ID id-RICrequestID                            CRITICALITY reject      TYPE RICrequestID                                       PRESENCE mandatory}|
1889         { ID id-RANfunctionID                           CRITICALITY reject      TYPE RANfunctionID                                      PRESENCE mandatory}|
1890         { ID id-RICcallProcessID                        CRITICALITY reject      TYPE RICcallProcessID                           PRESENCE optional}|
1891         { ID id-RICcause                                    CRITICALITY reject  TYPE RICcause                                   PRESENCE mandatory},
1892     ...
1893 }
1894 */
1895
1896 struct RICcontrolFailure_IEs
1897 {
1898         struct id_t : asn::fixedtypefield<X2AP_PROTOCOL_IES::id_t, true>
1899         {
1900                 size_t get_index() const {return type;}
1901                 bool is_unknown() const { return type == 5; }
1902                 void clear() {type = 0;}
1903                 void select_id_RICrequestID() { set(id_RICrequestID); type=1;}
1904                 void select_id_RANfunctionID() { set(id_RANfunctionID); type=2;}
1905                 void select_id_RICcallProcessID() { set(id_RICcallProcessID); type=3;}
1906                 void select_id_RICcause() { set(id_RICcause); type=4;}
1907                 X2AP_PROTOCOL_IES::id_t const& ref_value() const {return ref_nested();}
1908                 template<typename V>  bool decode(V& v)
1909                 {
1910                         clear();
1911                         if(!v(ref_nested())) return false;
1912                         if(equal(id_RICrequestID)) { type = 1; return true; }
1913                         else if(equal(id_RANfunctionID)) { type = 2; return true; }
1914                         else if(equal(id_RICcallProcessID)) { type = 3; return true; }
1915                         else if(equal(id_RICcause)) { type = 4; return true; }
1916                         else { type = 5; return true;}
1917                         return false;
1918
1919                 }
1920                 template<typename V> bool encode(V& v) const
1921                 {
1922                         return v(ref_nested());
1923
1924                 }
1925                 protected:
1926                 template<typename V>  bool decode(size_t index, V& v)
1927                 {
1928                         clear();
1929                         switch(index)
1930                         {
1931                         case 1: type = 1; if(v(ref_nested())) { return equal(id_RICrequestID);} return false;
1932                         case 2: type = 2; if(v(ref_nested())) { return equal(id_RANfunctionID);} return false;
1933                         case 3: type = 3; if(v(ref_nested())) { return equal(id_RICcallProcessID);} return false;
1934                         case 4: type = 4; if(v(ref_nested())) { return equal(id_RICcause);} return false;
1935                         case 5: type = 5; return v(ref_nested());
1936                         ref_nested().clear();
1937                         }
1938                         return false;
1939
1940                 }
1941                 template<typename V> bool encode(size_t index, V& v) const
1942                 {
1943                         if(index != type) {return false;} return v(ref_nested());
1944
1945                 }
1946                 private:
1947                 size_t type {0};
1948
1949         };
1950         struct criticality_t : asn::fixedtypefield<X2AP_PROTOCOL_IES::criticality_t, true>
1951         {
1952                 size_t get_index() const {return type;}
1953                 bool is_unknown() const { return type == 5; }
1954                 void clear() {type = 0;}
1955                 void select_id_RICrequestID() { set(reject); type=1;}
1956                 void select_id_RANfunctionID() { set(reject); type=2;}
1957                 void select_id_RICcallProcessID() { set(reject); type=3;}
1958                 void select_id_RICcause() { set(reject); type=4;}
1959                 X2AP_PROTOCOL_IES::criticality_t const& ref_value() const {return ref_nested();}
1960                 template<typename V>  bool decode(V& v)
1961                 {
1962                         clear();
1963                         if(!v(ref_nested())) return false;
1964                         if(equal(reject)) { type = 1; return true; }
1965                         else if(equal(reject)) { type = 2; return true; }
1966                         else if(equal(reject)) { type = 3; return true; }
1967                         else if(equal(reject)) { type = 4; return true; }
1968                         else { type = 5; return true;}
1969                         return false;
1970
1971                 }
1972                 template<typename V> bool encode(V& v) const
1973                 {
1974                         return v(ref_nested());
1975
1976                 }
1977                 protected:
1978                 template<typename V>  bool decode(size_t index, V& v)
1979                 {
1980                         clear();
1981                         switch(index)
1982                         {
1983                         case 1: type = 1; if(v(ref_nested())) { return equal(reject);} return false;
1984                         case 2: type = 2; if(v(ref_nested())) { return equal(reject);} return false;
1985                         case 3: type = 3; if(v(ref_nested())) { return equal(reject);} return false;
1986                         case 4: type = 4; if(v(ref_nested())) { return equal(reject);} return false;
1987                         case 5: type = 5; return v(ref_nested());
1988                         ref_nested().clear();
1989                         }
1990                         return false;
1991
1992                 }
1993                 template<typename V> bool encode(size_t index, V& v) const
1994                 {
1995                         if(index != type) {return false;} return v(ref_nested());
1996
1997                 }
1998                 private:
1999                 size_t type {0};
2000
2001         };
2002         struct Value_t : asn::typefield<true>
2003         {
2004                 ~Value_t()      {clear();}
2005                 size_t get_index() const {return type;}
2006                 RICrequestID& select_id_RICrequestID() { return set<RICrequestID>(1); }
2007                 RICrequestID const* get_id_RICrequestID() const { return get<RICrequestID>(1); }
2008                 RANfunctionID& select_id_RANfunctionID() { return set<RANfunctionID>(2); }
2009                 RANfunctionID const* get_id_RANfunctionID() const { return get<RANfunctionID>(2); }
2010                 RICcallProcessID& select_id_RICcallProcessID() { return set<RICcallProcessID>(3); }
2011                 RICcallProcessID const* get_id_RICcallProcessID() const { return get<RICcallProcessID>(3); }
2012                 RICcause& select_id_RICcause() { return set<RICcause>(4); }
2013                 RICcause const* get_id_RICcause() const { return get<RICcause>(4); }
2014                 bool is_unknown() const { return type == 5; }
2015                 void clear()
2016                 {
2017                         switch(type)
2018                         {
2019                         case 1: var.destroy<RICrequestID>(); break;
2020                         case 2: var.destroy<RANfunctionID>(); break;
2021                         case 3: var.destroy<RICcallProcessID>(); break;
2022                         case 4: var.destroy<RICcause>(); break;
2023                         }
2024                         type = 0; ref_nested().clear();
2025                 }
2026                 template<typename V> static inline void enumerate(V& v)
2027                 {
2028                         v.template operator()<RICrequestID>(1);
2029                         v.template operator()<RANfunctionID>(2);
2030                         v.template operator()<RICcallProcessID>(3);
2031                         v.template operator()<RICcause>(4);
2032
2033                 }
2034                 protected:
2035                 template<typename V> bool decode(size_t index, V& v)
2036                 {
2037                         clear();
2038                         switch(index)
2039                         {
2040                         case 1: v(select_id_RICrequestID()); return true;
2041                         case 2: v(select_id_RANfunctionID()); return true;
2042                         case 3: v(select_id_RICcallProcessID()); return true;
2043                         case 4: v(select_id_RICcause()); return true;
2044                         case 5: if(type != 5) {clear(); asn::base::set();} type = 5; return true;
2045                         }
2046                         return false;
2047
2048                 }
2049                 template<typename V> bool encode(size_t index, V& v) const
2050                 {
2051                         if(index != type) return false;
2052                         switch(type)
2053                         {
2054                         case 1: v(var.as<RICrequestID>()); return true;
2055                         case 2: v(var.as<RANfunctionID>()); return true;
2056                         case 3: v(var.as<RICcallProcessID>()); return true;
2057                         case 4: v(var.as<RICcause>()); return true;
2058                         }
2059                         return false;
2060
2061                 }
2062                 private:
2063                 template<class T> T& set(size_t index) {if(type != index) {clear(); type = index; return var.build<T>();} return var.as<T>();}
2064                 template<class T> T const* get(size_t index) const {if(type == index) {return &var.as<T>();} return nullptr;}
2065                 union union_type
2066                 {
2067                         char dummy1[sizeof(RANfunctionID)];
2068                         char dummy2[sizeof(RICcallProcessID)];
2069                         char dummy3[sizeof(RICcause)];
2070                         char dummy4[sizeof(RICrequestID)];
2071
2072                 };
2073                 asn::variant<sizeof(union_type)> var;
2074                 size_t type {0};
2075
2076         };
2077         struct presence_t : asn::fixedtypefield<X2AP_PROTOCOL_IES::presence_t, true>
2078         {
2079                 size_t get_index() const {return type;}
2080                 bool is_unknown() const { return type == 5; }
2081                 void clear() {type = 0;}
2082                 void select_id_RICrequestID() { set(mandatory); type=1;}
2083                 void select_id_RANfunctionID() { set(mandatory); type=2;}
2084                 void select_id_RICcallProcessID() { set(optional); type=3;}
2085                 void select_id_RICcause() { set(mandatory); type=4;}
2086                 X2AP_PROTOCOL_IES::presence_t const& ref_value() const {return ref_nested();}
2087                 template<typename V>  bool decode(V& v)
2088                 {
2089                         clear();
2090                         if(!v(ref_nested())) return false;
2091                         if(equal(mandatory)) { type = 1; return true; }
2092                         else if(equal(mandatory)) { type = 2; return true; }
2093                         else if(equal(optional)) { type = 3; return true; }
2094                         else if(equal(mandatory)) { type = 4; return true; }
2095                         else { type = 5; return true;}
2096                         return false;
2097
2098                 }
2099                 template<typename V> bool encode(V& v) const
2100                 {
2101                         return v(ref_nested());
2102
2103                 }
2104                 protected:
2105                 template<typename V>  bool decode(size_t index, V& v)
2106                 {
2107                         clear();
2108                         switch(index)
2109                         {
2110                         case 1: type = 1; if(v(ref_nested())) { return equal(mandatory);} return false;
2111                         case 2: type = 2; if(v(ref_nested())) { return equal(mandatory);} return false;
2112                         case 3: type = 3; if(v(ref_nested())) { return equal(optional);} return false;
2113                         case 4: type = 4; if(v(ref_nested())) { return equal(mandatory);} return false;
2114                         case 5: type = 5; return v(ref_nested());
2115                         ref_nested().clear();
2116                         }
2117                         return false;
2118
2119                 }
2120                 template<typename V> bool encode(size_t index, V& v) const
2121                 {
2122                         if(index != type) {return false;} return v(ref_nested());
2123
2124                 }
2125                 private:
2126                 size_t type {0};
2127
2128         };
2129
2130 };
2131 /*
2132 RICcontrolFailure ::= SEQUENCE {
2133         protocolIEs                                     ProtocolIE-Container    {{RICcontrolFailure-IEs}},
2134         ...
2135 }
2136 */
2137
2138 struct RICcontrolFailure : asn::sequence<1, 0, true, 0>
2139 {
2140         static constexpr const char* name() {return "RICcontrolFailure";}
2141         using parent_t = asn::sequence<1, 0, true, 0>;
2142         struct protocolIEs_t : ProtocolIE_Container<RICcontrolFailure_IEs>
2143         {
2144                 static constexpr const char* name() {return "protocolIEs_t";}
2145                 using parent_t = ProtocolIE_Container<RICcontrolFailure_IEs>;
2146
2147         };
2148         protocolIEs_t& ref_protocolIEs() {return protocolIEs;}
2149         protocolIEs_t const& ref_protocolIEs() const {return protocolIEs;}
2150         template<typename V> void decode(V& v)
2151         {
2152                 v(protocolIEs);
2153
2154         };
2155         template<typename V> void encode(V& v) const
2156         {
2157                 v(protocolIEs);
2158
2159         };
2160         void clear()
2161         {
2162                 protocolIEs.clear();
2163
2164         };
2165         private:
2166         protocolIEs_t   protocolIEs;
2167
2168 };
2169 /*
2170 RICcontrolRequest-IEs X2AP-PROTOCOL-IES ::= {
2171         { ID id-RICrequestID                            CRITICALITY reject      TYPE RICrequestID                                       PRESENCE mandatory}|
2172         { ID id-RANfunctionID                           CRITICALITY reject      TYPE RANfunctionID                                      PRESENCE mandatory}|
2173         { ID id-RICcallProcessID                        CRITICALITY reject      TYPE RICcallProcessID                           PRESENCE optional}|
2174         { ID id-RICcontrolHeader                        CRITICALITY reject      TYPE RICcontrolHeader                           PRESENCE mandatory}|
2175         { ID id-RICcontrolMessage                       CRITICALITY reject      TYPE RICcontrolMessage                          PRESENCE mandatory}|
2176     { ID id-RICcontrolAckRequest                CRITICALITY reject      TYPE RICcontrolAckRequest               PRESENCE optional},
2177     ...
2178 }
2179 */
2180
2181 struct RICcontrolRequest_IEs
2182 {
2183         struct id_t : asn::fixedtypefield<X2AP_PROTOCOL_IES::id_t, true>
2184         {
2185                 size_t get_index() const {return type;}
2186                 bool is_unknown() const { return type == 7; }
2187                 void clear() {type = 0;}
2188                 void select_id_RICrequestID() { set(id_RICrequestID); type=1;}
2189                 void select_id_RANfunctionID() { set(id_RANfunctionID); type=2;}
2190                 void select_id_RICcallProcessID() { set(id_RICcallProcessID); type=3;}
2191                 void select_id_RICcontrolHeader() { set(id_RICcontrolHeader); type=4;}
2192                 void select_id_RICcontrolMessage() { set(id_RICcontrolMessage); type=5;}
2193                 void select_id_RICcontrolAckRequest() { set(id_RICcontrolAckRequest); type=6;}
2194                 X2AP_PROTOCOL_IES::id_t const& ref_value() const {return ref_nested();}
2195                 template<typename V>  bool decode(V& v)
2196                 {
2197                         clear();
2198                         if(!v(ref_nested())) return false;
2199                         if(equal(id_RICrequestID)) { type = 1; return true; }
2200                         else if(equal(id_RANfunctionID)) { type = 2; return true; }
2201                         else if(equal(id_RICcallProcessID)) { type = 3; return true; }
2202                         else if(equal(id_RICcontrolHeader)) { type = 4; return true; }
2203                         else if(equal(id_RICcontrolMessage)) { type = 5; return true; }
2204                         else if(equal(id_RICcontrolAckRequest)) { type = 6; return true; }
2205                         else { type = 7; return true;}
2206                         return false;
2207
2208                 }
2209                 template<typename V> bool encode(V& v) const
2210                 {
2211                         return v(ref_nested());
2212
2213                 }
2214                 protected:
2215                 template<typename V>  bool decode(size_t index, V& v)
2216                 {
2217                         clear();
2218                         switch(index)
2219                         {
2220                         case 1: type = 1; if(v(ref_nested())) { return equal(id_RICrequestID);} return false;
2221                         case 2: type = 2; if(v(ref_nested())) { return equal(id_RANfunctionID);} return false;
2222                         case 3: type = 3; if(v(ref_nested())) { return equal(id_RICcallProcessID);} return false;
2223                         case 4: type = 4; if(v(ref_nested())) { return equal(id_RICcontrolHeader);} return false;
2224                         case 5: type = 5; if(v(ref_nested())) { return equal(id_RICcontrolMessage);} return false;
2225                         case 6: type = 6; if(v(ref_nested())) { return equal(id_RICcontrolAckRequest);} return false;
2226                         case 7: type = 7; return v(ref_nested());
2227                         ref_nested().clear();
2228                         }
2229                         return false;
2230
2231                 }
2232                 template<typename V> bool encode(size_t index, V& v) const
2233                 {
2234                         if(index != type) {return false;} return v(ref_nested());
2235
2236                 }
2237                 private:
2238                 size_t type {0};
2239
2240         };
2241         struct criticality_t : asn::fixedtypefield<X2AP_PROTOCOL_IES::criticality_t, true>
2242         {
2243                 size_t get_index() const {return type;}
2244                 bool is_unknown() const { return type == 7; }
2245                 void clear() {type = 0;}
2246                 void select_id_RICrequestID() { set(reject); type=1;}
2247                 void select_id_RANfunctionID() { set(reject); type=2;}
2248                 void select_id_RICcallProcessID() { set(reject); type=3;}
2249                 void select_id_RICcontrolHeader() { set(reject); type=4;}
2250                 void select_id_RICcontrolMessage() { set(reject); type=5;}
2251                 void select_id_RICcontrolAckRequest() { set(reject); type=6;}
2252                 X2AP_PROTOCOL_IES::criticality_t const& ref_value() const {return ref_nested();}
2253                 template<typename V>  bool decode(V& v)
2254                 {
2255                         clear();
2256                         if(!v(ref_nested())) return false;
2257                         if(equal(reject)) { type = 1; return true; }
2258                         else if(equal(reject)) { type = 2; return true; }
2259                         else if(equal(reject)) { type = 3; return true; }
2260                         else if(equal(reject)) { type = 4; return true; }
2261                         else if(equal(reject)) { type = 5; return true; }
2262                         else if(equal(reject)) { type = 6; return true; }
2263                         else { type = 7; return true;}
2264                         return false;
2265
2266                 }
2267                 template<typename V> bool encode(V& v) const
2268                 {
2269                         return v(ref_nested());
2270
2271                 }
2272                 protected:
2273                 template<typename V>  bool decode(size_t index, V& v)
2274                 {
2275                         clear();
2276                         switch(index)
2277                         {
2278                         case 1: type = 1; if(v(ref_nested())) { return equal(reject);} return false;
2279                         case 2: type = 2; if(v(ref_nested())) { return equal(reject);} return false;
2280                         case 3: type = 3; if(v(ref_nested())) { return equal(reject);} return false;
2281                         case 4: type = 4; if(v(ref_nested())) { return equal(reject);} return false;
2282                         case 5: type = 5; if(v(ref_nested())) { return equal(reject);} return false;
2283                         case 6: type = 6; if(v(ref_nested())) { return equal(reject);} return false;
2284                         case 7: type = 7; return v(ref_nested());
2285                         ref_nested().clear();
2286                         }
2287                         return false;
2288
2289                 }
2290                 template<typename V> bool encode(size_t index, V& v) const
2291                 {
2292                         if(index != type) {return false;} return v(ref_nested());
2293
2294                 }
2295                 private:
2296                 size_t type {0};
2297
2298         };
2299         struct Value_t : asn::typefield<true>
2300         {
2301                 ~Value_t()      {clear();}
2302                 size_t get_index() const {return type;}
2303                 RICrequestID& select_id_RICrequestID() { return set<RICrequestID>(1); }
2304                 RICrequestID const* get_id_RICrequestID() const { return get<RICrequestID>(1); }
2305                 RANfunctionID& select_id_RANfunctionID() { return set<RANfunctionID>(2); }
2306                 RANfunctionID const* get_id_RANfunctionID() const { return get<RANfunctionID>(2); }
2307                 RICcallProcessID& select_id_RICcallProcessID() { return set<RICcallProcessID>(3); }
2308                 RICcallProcessID const* get_id_RICcallProcessID() const { return get<RICcallProcessID>(3); }
2309                 RICcontrolHeader& select_id_RICcontrolHeader() { return set<RICcontrolHeader>(4); }
2310                 RICcontrolHeader const* get_id_RICcontrolHeader() const { return get<RICcontrolHeader>(4); }
2311                 RICcontrolMessage& select_id_RICcontrolMessage() { return set<RICcontrolMessage>(5); }
2312                 RICcontrolMessage const* get_id_RICcontrolMessage() const { return get<RICcontrolMessage>(5); }
2313                 RICcontrolAckRequest& select_id_RICcontrolAckRequest() { return set<RICcontrolAckRequest>(6); }
2314                 RICcontrolAckRequest const* get_id_RICcontrolAckRequest() const { return get<RICcontrolAckRequest>(6); }
2315                 bool is_unknown() const { return type == 7; }
2316                 void clear()
2317                 {
2318                         switch(type)
2319                         {
2320                         case 1: var.destroy<RICrequestID>(); break;
2321                         case 2: var.destroy<RANfunctionID>(); break;
2322                         case 3: var.destroy<RICcallProcessID>(); break;
2323                         case 4: var.destroy<RICcontrolHeader>(); break;
2324                         case 5: var.destroy<RICcontrolMessage>(); break;
2325                         case 6: var.destroy<RICcontrolAckRequest>(); break;
2326                         }
2327                         type = 0; ref_nested().clear();
2328                 }
2329                 template<typename V> static inline void enumerate(V& v)
2330                 {
2331                         v.template operator()<RICrequestID>(1);
2332                         v.template operator()<RANfunctionID>(2);
2333                         v.template operator()<RICcallProcessID>(3);
2334                         v.template operator()<RICcontrolHeader>(4);
2335                         v.template operator()<RICcontrolMessage>(5);
2336                         v.template operator()<RICcontrolAckRequest>(6);
2337
2338                 }
2339                 protected:
2340                 template<typename V> bool decode(size_t index, V& v)
2341                 {
2342                         clear();
2343                         switch(index)
2344                         {
2345                         case 1: v(select_id_RICrequestID()); return true;
2346                         case 2: v(select_id_RANfunctionID()); return true;
2347                         case 3: v(select_id_RICcallProcessID()); return true;
2348                         case 4: v(select_id_RICcontrolHeader()); return true;
2349                         case 5: v(select_id_RICcontrolMessage()); return true;
2350                         case 6: v(select_id_RICcontrolAckRequest()); return true;
2351                         case 7: if(type != 7) {clear(); asn::base::set();} type = 7; return true;
2352                         }
2353                         return false;
2354
2355                 }
2356                 template<typename V> bool encode(size_t index, V& v) const
2357                 {
2358                         if(index != type) return false;
2359                         switch(type)
2360                         {
2361                         case 1: v(var.as<RICrequestID>()); return true;
2362                         case 2: v(var.as<RANfunctionID>()); return true;
2363                         case 3: v(var.as<RICcallProcessID>()); return true;
2364                         case 4: v(var.as<RICcontrolHeader>()); return true;
2365                         case 5: v(var.as<RICcontrolMessage>()); return true;
2366                         case 6: v(var.as<RICcontrolAckRequest>()); return true;
2367                         }
2368                         return false;
2369
2370                 }
2371                 private:
2372                 template<class T> T& set(size_t index) {if(type != index) {clear(); type = index; return var.build<T>();} return var.as<T>();}
2373                 template<class T> T const* get(size_t index) const {if(type == index) {return &var.as<T>();} return nullptr;}
2374                 union union_type
2375                 {
2376                         char dummy1[sizeof(RANfunctionID)];
2377                         char dummy2[sizeof(RICcallProcessID)];
2378                         char dummy3[sizeof(RICcontrolAckRequest)];
2379                         char dummy4[sizeof(RICcontrolHeader)];
2380                         char dummy5[sizeof(RICcontrolMessage)];
2381                         char dummy6[sizeof(RICrequestID)];
2382
2383                 };
2384                 asn::variant<sizeof(union_type)> var;
2385                 size_t type {0};
2386
2387         };
2388         struct presence_t : asn::fixedtypefield<X2AP_PROTOCOL_IES::presence_t, true>
2389         {
2390                 size_t get_index() const {return type;}
2391                 bool is_unknown() const { return type == 7; }
2392                 void clear() {type = 0;}
2393                 void select_id_RICrequestID() { set(mandatory); type=1;}
2394                 void select_id_RANfunctionID() { set(mandatory); type=2;}
2395                 void select_id_RICcallProcessID() { set(optional); type=3;}
2396                 void select_id_RICcontrolHeader() { set(mandatory); type=4;}
2397                 void select_id_RICcontrolMessage() { set(mandatory); type=5;}
2398                 void select_id_RICcontrolAckRequest() { set(optional); type=6;}
2399                 X2AP_PROTOCOL_IES::presence_t const& ref_value() const {return ref_nested();}
2400                 template<typename V>  bool decode(V& v)
2401                 {
2402                         clear();
2403                         if(!v(ref_nested())) return false;
2404                         if(equal(mandatory)) { type = 1; return true; }
2405                         else if(equal(mandatory)) { type = 2; return true; }
2406                         else if(equal(optional)) { type = 3; return true; }
2407                         else if(equal(mandatory)) { type = 4; return true; }
2408                         else if(equal(mandatory)) { type = 5; return true; }
2409                         else if(equal(optional)) { type = 6; return true; }
2410                         else { type = 7; return true;}
2411                         return false;
2412
2413                 }
2414                 template<typename V> bool encode(V& v) const
2415                 {
2416                         return v(ref_nested());
2417
2418                 }
2419                 protected:
2420                 template<typename V>  bool decode(size_t index, V& v)
2421                 {
2422                         clear();
2423                         switch(index)
2424                         {
2425                         case 1: type = 1; if(v(ref_nested())) { return equal(mandatory);} return false;
2426                         case 2: type = 2; if(v(ref_nested())) { return equal(mandatory);} return false;
2427                         case 3: type = 3; if(v(ref_nested())) { return equal(optional);} return false;
2428                         case 4: type = 4; if(v(ref_nested())) { return equal(mandatory);} return false;
2429                         case 5: type = 5; if(v(ref_nested())) { return equal(mandatory);} return false;
2430                         case 6: type = 6; if(v(ref_nested())) { return equal(optional);} return false;
2431                         case 7: type = 7; return v(ref_nested());
2432                         ref_nested().clear();
2433                         }
2434                         return false;
2435
2436                 }
2437                 template<typename V> bool encode(size_t index, V& v) const
2438                 {
2439                         if(index != type) {return false;} return v(ref_nested());
2440
2441                 }
2442                 private:
2443                 size_t type {0};
2444
2445         };
2446
2447 };
2448 /*
2449 RICcontrolRequest ::= SEQUENCE {
2450         protocolIEs                                     ProtocolIE-Container    {{RICcontrolRequest-IEs}},
2451         ...
2452 }
2453 */
2454
2455 struct RICcontrolRequest : asn::sequence<1, 0, true, 0>
2456 {
2457         static constexpr const char* name() {return "RICcontrolRequest";}
2458         using parent_t = asn::sequence<1, 0, true, 0>;
2459         struct protocolIEs_t : ProtocolIE_Container<RICcontrolRequest_IEs>
2460         {
2461                 static constexpr const char* name() {return "protocolIEs_t";}
2462                 using parent_t = ProtocolIE_Container<RICcontrolRequest_IEs>;
2463
2464         };
2465         protocolIEs_t& ref_protocolIEs() {return protocolIEs;}
2466         protocolIEs_t const& ref_protocolIEs() const {return protocolIEs;}
2467         template<typename V> void decode(V& v)
2468         {
2469                 v(protocolIEs);
2470
2471         };
2472         template<typename V> void encode(V& v) const
2473         {
2474                 v(protocolIEs);
2475
2476         };
2477         void clear()
2478         {
2479                 protocolIEs.clear();
2480
2481         };
2482         private:
2483         protocolIEs_t   protocolIEs;
2484
2485 };
2486 /*
2487 RICindication-IEs X2AP-PROTOCOL-IES ::= {
2488         { ID id-RICrequestID                            CRITICALITY reject      TYPE RICrequestID                                       PRESENCE mandatory}|
2489         { ID id-RANfunctionID                           CRITICALITY reject      TYPE RANfunctionID                                      PRESENCE mandatory}|
2490         { ID id-RICactionID                                     CRITICALITY reject      TYPE RICactionID                                        PRESENCE mandatory}|
2491         { ID id-RICindicationSN                         CRITICALITY reject      TYPE RICindicationSN                            PRESENCE mandatory}|
2492     { ID id-RICindicationType                   CRITICALITY reject      TYPE RICindicationType                          PRESENCE mandatory}|
2493         { ID id-RICindicationHeader                     CRITICALITY reject      TYPE RICindicationHeader                        PRESENCE mandatory}|
2494         { ID id-RICindicationMessage            CRITICALITY reject      TYPE RICindicationMessage           PRESENCE mandatory} |
2495         { ID id-RICcallProcessID                        CRITICALITY reject      TYPE RICcallProcessID                           PRESENCE optional},
2496     ...
2497 }
2498 */
2499
2500 struct RICindication_IEs
2501 {
2502         struct id_t : asn::fixedtypefield<X2AP_PROTOCOL_IES::id_t, true>
2503         {
2504                 size_t get_index() const {return type;}
2505                 bool is_unknown() const { return type == 9; }
2506                 void clear() {type = 0;}
2507                 void select_id_RICrequestID() { set(id_RICrequestID); type=1;}
2508                 void select_id_RANfunctionID() { set(id_RANfunctionID); type=2;}
2509                 void select_id_RICactionID() { set(id_RICactionID); type=3;}
2510                 void select_id_RICindicationSN() { set(id_RICindicationSN); type=4;}
2511                 void select_id_RICindicationType() { set(id_RICindicationType); type=5;}
2512                 void select_id_RICindicationHeader() { set(id_RICindicationHeader); type=6;}
2513                 void select_id_RICindicationMessage() { set(id_RICindicationMessage); type=7;}
2514                 void select_id_RICcallProcessID() { set(id_RICcallProcessID); type=8;}
2515                 X2AP_PROTOCOL_IES::id_t const& ref_value() const {return ref_nested();}
2516                 template<typename V>  bool decode(V& v)
2517                 {
2518                         clear();
2519                         if(!v(ref_nested())) return false;
2520                         if(equal(id_RICrequestID)) { type = 1; return true; }
2521                         else if(equal(id_RANfunctionID)) { type = 2; return true; }
2522                         else if(equal(id_RICactionID)) { type = 3; return true; }
2523                         else if(equal(id_RICindicationSN)) { type = 4; return true; }
2524                         else if(equal(id_RICindicationType)) { type = 5; return true; }
2525                         else if(equal(id_RICindicationHeader)) { type = 6; return true; }
2526                         else if(equal(id_RICindicationMessage)) { type = 7; return true; }
2527                         else if(equal(id_RICcallProcessID)) { type = 8; return true; }
2528                         else { type = 9; return true;}
2529                         return false;
2530
2531                 }
2532                 template<typename V> bool encode(V& v) const
2533                 {
2534                         return v(ref_nested());
2535
2536                 }
2537                 protected:
2538                 template<typename V>  bool decode(size_t index, V& v)
2539                 {
2540                         clear();
2541                         switch(index)
2542                         {
2543                         case 1: type = 1; if(v(ref_nested())) { return equal(id_RICrequestID);} return false;
2544                         case 2: type = 2; if(v(ref_nested())) { return equal(id_RANfunctionID);} return false;
2545                         case 3: type = 3; if(v(ref_nested())) { return equal(id_RICactionID);} return false;
2546                         case 4: type = 4; if(v(ref_nested())) { return equal(id_RICindicationSN);} return false;
2547                         case 5: type = 5; if(v(ref_nested())) { return equal(id_RICindicationType);} return false;
2548                         case 6: type = 6; if(v(ref_nested())) { return equal(id_RICindicationHeader);} return false;
2549                         case 7: type = 7; if(v(ref_nested())) { return equal(id_RICindicationMessage);} return false;
2550                         case 8: type = 8; if(v(ref_nested())) { return equal(id_RICcallProcessID);} return false;
2551                         case 9: type = 9; return v(ref_nested());
2552                         ref_nested().clear();
2553                         }
2554                         return false;
2555
2556                 }
2557                 template<typename V> bool encode(size_t index, V& v) const
2558                 {
2559                         if(index != type) {return false;} return v(ref_nested());
2560
2561                 }
2562                 private:
2563                 size_t type {0};
2564
2565         };
2566         struct criticality_t : asn::fixedtypefield<X2AP_PROTOCOL_IES::criticality_t, true>
2567         {
2568                 size_t get_index() const {return type;}
2569                 bool is_unknown() const { return type == 9; }
2570                 void clear() {type = 0;}
2571                 void select_id_RICrequestID() { set(reject); type=1;}
2572                 void select_id_RANfunctionID() { set(reject); type=2;}
2573                 void select_id_RICactionID() { set(reject); type=3;}
2574                 void select_id_RICindicationSN() { set(reject); type=4;}
2575                 void select_id_RICindicationType() { set(reject); type=5;}
2576                 void select_id_RICindicationHeader() { set(reject); type=6;}
2577                 void select_id_RICindicationMessage() { set(reject); type=7;}
2578                 void select_id_RICcallProcessID() { set(reject); type=8;}
2579                 X2AP_PROTOCOL_IES::criticality_t const& ref_value() const {return ref_nested();}
2580                 template<typename V>  bool decode(V& v)
2581                 {
2582                         clear();
2583                         if(!v(ref_nested())) return false;
2584                         if(equal(reject)) { type = 1; return true; }
2585                         else if(equal(reject)) { type = 2; return true; }
2586                         else if(equal(reject)) { type = 3; return true; }
2587                         else if(equal(reject)) { type = 4; return true; }
2588                         else if(equal(reject)) { type = 5; return true; }
2589                         else if(equal(reject)) { type = 6; return true; }
2590                         else if(equal(reject)) { type = 7; return true; }
2591                         else if(equal(reject)) { type = 8; return true; }
2592                         else { type = 9; return true;}
2593                         return false;
2594
2595                 }
2596                 template<typename V> bool encode(V& v) const
2597                 {
2598                         return v(ref_nested());
2599
2600                 }
2601                 protected:
2602                 template<typename V>  bool decode(size_t index, V& v)
2603                 {
2604                         clear();
2605                         switch(index)
2606                         {
2607                         case 1: type = 1; if(v(ref_nested())) { return equal(reject);} return false;
2608                         case 2: type = 2; if(v(ref_nested())) { return equal(reject);} return false;
2609                         case 3: type = 3; if(v(ref_nested())) { return equal(reject);} return false;
2610                         case 4: type = 4; if(v(ref_nested())) { return equal(reject);} return false;
2611                         case 5: type = 5; if(v(ref_nested())) { return equal(reject);} return false;
2612                         case 6: type = 6; if(v(ref_nested())) { return equal(reject);} return false;
2613                         case 7: type = 7; if(v(ref_nested())) { return equal(reject);} return false;
2614                         case 8: type = 8; if(v(ref_nested())) { return equal(reject);} return false;
2615                         case 9: type = 9; return v(ref_nested());
2616                         ref_nested().clear();
2617                         }
2618                         return false;
2619
2620                 }
2621                 template<typename V> bool encode(size_t index, V& v) const
2622                 {
2623                         if(index != type) {return false;} return v(ref_nested());
2624
2625                 }
2626                 private:
2627                 size_t type {0};
2628
2629         };
2630         struct Value_t : asn::typefield<true>
2631         {
2632                 ~Value_t()      {clear();}
2633                 size_t get_index() const {return type;}
2634                 RICrequestID& select_id_RICrequestID() { return set<RICrequestID>(1); }
2635                 RICrequestID const* get_id_RICrequestID() const { return get<RICrequestID>(1); }
2636                 RANfunctionID& select_id_RANfunctionID() { return set<RANfunctionID>(2); }
2637                 RANfunctionID const* get_id_RANfunctionID() const { return get<RANfunctionID>(2); }
2638                 RICactionID& select_id_RICactionID() { return set<RICactionID>(3); }
2639                 RICactionID const* get_id_RICactionID() const { return get<RICactionID>(3); }
2640                 RICindicationSN& select_id_RICindicationSN() { return set<RICindicationSN>(4); }
2641                 RICindicationSN const* get_id_RICindicationSN() const { return get<RICindicationSN>(4); }
2642                 RICindicationType& select_id_RICindicationType() { return set<RICindicationType>(5); }
2643                 RICindicationType const* get_id_RICindicationType() const { return get<RICindicationType>(5); }
2644                 RICindicationHeader& select_id_RICindicationHeader() { return set<RICindicationHeader>(6); }
2645                 RICindicationHeader const* get_id_RICindicationHeader() const { return get<RICindicationHeader>(6); }
2646                 RICindicationMessage& select_id_RICindicationMessage() { return set<RICindicationMessage>(7); }
2647                 RICindicationMessage const* get_id_RICindicationMessage() const { return get<RICindicationMessage>(7); }
2648                 RICcallProcessID& select_id_RICcallProcessID() { return set<RICcallProcessID>(8); }
2649                 RICcallProcessID const* get_id_RICcallProcessID() const { return get<RICcallProcessID>(8); }
2650                 bool is_unknown() const { return type == 9; }
2651                 void clear()
2652                 {
2653                         switch(type)
2654                         {
2655                         case 1: var.destroy<RICrequestID>(); break;
2656                         case 2: var.destroy<RANfunctionID>(); break;
2657                         case 3: var.destroy<RICactionID>(); break;
2658                         case 4: var.destroy<RICindicationSN>(); break;
2659                         case 5: var.destroy<RICindicationType>(); break;
2660                         case 6: var.destroy<RICindicationHeader>(); break;
2661                         case 7: var.destroy<RICindicationMessage>(); break;
2662                         case 8: var.destroy<RICcallProcessID>(); break;
2663                         }
2664                         type = 0; ref_nested().clear();
2665                 }
2666                 template<typename V> static inline void enumerate(V& v)
2667                 {
2668                         v.template operator()<RICrequestID>(1);
2669                         v.template operator()<RANfunctionID>(2);
2670                         v.template operator()<RICactionID>(3);
2671                         v.template operator()<RICindicationSN>(4);
2672                         v.template operator()<RICindicationType>(5);
2673                         v.template operator()<RICindicationHeader>(6);
2674                         v.template operator()<RICindicationMessage>(7);
2675                         v.template operator()<RICcallProcessID>(8);
2676
2677                 }
2678                 protected:
2679                 template<typename V> bool decode(size_t index, V& v)
2680                 {
2681                         clear();
2682                         switch(index)
2683                         {
2684                         case 1: v(select_id_RICrequestID()); return true;
2685                         case 2: v(select_id_RANfunctionID()); return true;
2686                         case 3: v(select_id_RICactionID()); return true;
2687                         case 4: v(select_id_RICindicationSN()); return true;
2688                         case 5: v(select_id_RICindicationType()); return true;
2689                         case 6: v(select_id_RICindicationHeader()); return true;
2690                         case 7: v(select_id_RICindicationMessage()); return true;
2691                         case 8: v(select_id_RICcallProcessID()); return true;
2692                         case 9: if(type != 9) {clear(); asn::base::set();} type = 9; return true;
2693                         }
2694                         return false;
2695
2696                 }
2697                 template<typename V> bool encode(size_t index, V& v) const
2698                 {
2699                         if(index != type) return false;
2700                         switch(type)
2701                         {
2702                         case 1: v(var.as<RICrequestID>()); return true;
2703                         case 2: v(var.as<RANfunctionID>()); return true;
2704                         case 3: v(var.as<RICactionID>()); return true;
2705                         case 4: v(var.as<RICindicationSN>()); return true;
2706                         case 5: v(var.as<RICindicationType>()); return true;
2707                         case 6: v(var.as<RICindicationHeader>()); return true;
2708                         case 7: v(var.as<RICindicationMessage>()); return true;
2709                         case 8: v(var.as<RICcallProcessID>()); return true;
2710                         }
2711                         return false;
2712
2713                 }
2714                 private:
2715                 template<class T> T& set(size_t index) {if(type != index) {clear(); type = index; return var.build<T>();} return var.as<T>();}
2716                 template<class T> T const* get(size_t index) const {if(type == index) {return &var.as<T>();} return nullptr;}
2717                 union union_type
2718                 {
2719                         char dummy1[sizeof(RANfunctionID)];
2720                         char dummy2[sizeof(RICactionID)];
2721                         char dummy3[sizeof(RICcallProcessID)];
2722                         char dummy4[sizeof(RICindicationHeader)];
2723                         char dummy5[sizeof(RICindicationMessage)];
2724                         char dummy6[sizeof(RICindicationSN)];
2725                         char dummy7[sizeof(RICindicationType)];
2726                         char dummy8[sizeof(RICrequestID)];
2727
2728                 };
2729                 asn::variant<sizeof(union_type)> var;
2730                 size_t type {0};
2731
2732         };
2733         struct presence_t : asn::fixedtypefield<X2AP_PROTOCOL_IES::presence_t, true>
2734         {
2735                 size_t get_index() const {return type;}
2736                 bool is_unknown() const { return type == 9; }
2737                 void clear() {type = 0;}
2738                 void select_id_RICrequestID() { set(mandatory); type=1;}
2739                 void select_id_RANfunctionID() { set(mandatory); type=2;}
2740                 void select_id_RICactionID() { set(mandatory); type=3;}
2741                 void select_id_RICindicationSN() { set(mandatory); type=4;}
2742                 void select_id_RICindicationType() { set(mandatory); type=5;}
2743                 void select_id_RICindicationHeader() { set(mandatory); type=6;}
2744                 void select_id_RICindicationMessage() { set(mandatory); type=7;}
2745                 void select_id_RICcallProcessID() { set(optional); type=8;}
2746                 X2AP_PROTOCOL_IES::presence_t const& ref_value() const {return ref_nested();}
2747                 template<typename V>  bool decode(V& v)
2748                 {
2749                         clear();
2750                         if(!v(ref_nested())) return false;
2751                         if(equal(mandatory)) { type = 1; return true; }
2752                         else if(equal(mandatory)) { type = 2; return true; }
2753                         else if(equal(mandatory)) { type = 3; return true; }
2754                         else if(equal(mandatory)) { type = 4; return true; }
2755                         else if(equal(mandatory)) { type = 5; return true; }
2756                         else if(equal(mandatory)) { type = 6; return true; }
2757                         else if(equal(mandatory)) { type = 7; return true; }
2758                         else if(equal(optional)) { type = 8; return true; }
2759                         else { type = 9; return true;}
2760                         return false;
2761
2762                 }
2763                 template<typename V> bool encode(V& v) const
2764                 {
2765                         return v(ref_nested());
2766
2767                 }
2768                 protected:
2769                 template<typename V>  bool decode(size_t index, V& v)
2770                 {
2771                         clear();
2772                         switch(index)
2773                         {
2774                         case 1: type = 1; if(v(ref_nested())) { return equal(mandatory);} return false;
2775                         case 2: type = 2; if(v(ref_nested())) { return equal(mandatory);} return false;
2776                         case 3: type = 3; if(v(ref_nested())) { return equal(mandatory);} return false;
2777                         case 4: type = 4; if(v(ref_nested())) { return equal(mandatory);} return false;
2778                         case 5: type = 5; if(v(ref_nested())) { return equal(mandatory);} return false;
2779                         case 6: type = 6; if(v(ref_nested())) { return equal(mandatory);} return false;
2780                         case 7: type = 7; if(v(ref_nested())) { return equal(mandatory);} return false;
2781                         case 8: type = 8; if(v(ref_nested())) { return equal(optional);} return false;
2782                         case 9: type = 9; return v(ref_nested());
2783                         ref_nested().clear();
2784                         }
2785                         return false;
2786
2787                 }
2788                 template<typename V> bool encode(size_t index, V& v) const
2789                 {
2790                         if(index != type) {return false;} return v(ref_nested());
2791
2792                 }
2793                 private:
2794                 size_t type {0};
2795
2796         };
2797
2798 };
2799 /*
2800 RICindication ::= SEQUENCE {
2801         protocolIEs                                     ProtocolIE-Container    {{RICindication-IEs}},
2802         ...
2803 }
2804 */
2805
2806 struct RICindication : asn::sequence<1, 0, true, 0>
2807 {
2808         static constexpr const char* name() {return "RICindication";}
2809         using parent_t = asn::sequence<1, 0, true, 0>;
2810         struct protocolIEs_t : ProtocolIE_Container<RICindication_IEs>
2811         {
2812                 static constexpr const char* name() {return "protocolIEs_t";}
2813                 using parent_t = ProtocolIE_Container<RICindication_IEs>;
2814
2815         };
2816         protocolIEs_t& ref_protocolIEs() {return protocolIEs;}
2817         protocolIEs_t const& ref_protocolIEs() const {return protocolIEs;}
2818         template<typename V> void decode(V& v)
2819         {
2820                 v(protocolIEs);
2821
2822         };
2823         template<typename V> void encode(V& v) const
2824         {
2825                 v(protocolIEs);
2826
2827         };
2828         void clear()
2829         {
2830                 protocolIEs.clear();
2831
2832         };
2833         private:
2834         protocolIEs_t   protocolIEs;
2835
2836 };
2837 /*
2838 RICserviceQuery-IEs X2AP-PROTOCOL-IES ::= {
2839         { ID id-RANfunctionsAccepted            CRITICALITY reject      TYPE RANfunctionsID-List                        PRESENCE optional},
2840         ...
2841 }
2842 */
2843
2844 struct RICserviceQuery_IEs
2845 {
2846         struct id_t : asn::fixedtypefield<X2AP_PROTOCOL_IES::id_t, true>
2847         {
2848                 size_t get_index() const {return type;}
2849                 bool is_unknown() const { return type == 2; }
2850                 void clear() {type = 0;}
2851                 void select_id_RANfunctionsAccepted() { set(id_RANfunctionsAccepted); type=1;}
2852                 X2AP_PROTOCOL_IES::id_t const& ref_value() const {return ref_nested();}
2853                 template<typename V>  bool decode(V& v)
2854                 {
2855                         clear();
2856                         if(!v(ref_nested())) return false;
2857                         if(equal(id_RANfunctionsAccepted)) { type = 1; return true; }
2858                         else { type = 2; return true;}
2859                         return false;
2860
2861                 }
2862                 template<typename V> bool encode(V& v) const
2863                 {
2864                         return v(ref_nested());
2865
2866                 }
2867                 protected:
2868                 template<typename V>  bool decode(size_t index, V& v)
2869                 {
2870                         clear();
2871                         switch(index)
2872                         {
2873                         case 1: type = 1; if(v(ref_nested())) { return equal(id_RANfunctionsAccepted);} return false;
2874                         case 2: type = 2; return v(ref_nested());
2875                         ref_nested().clear();
2876                         }
2877                         return false;
2878
2879                 }
2880                 template<typename V> bool encode(size_t index, V& v) const
2881                 {
2882                         if(index != type) {return false;} return v(ref_nested());
2883
2884                 }
2885                 private:
2886                 size_t type {0};
2887
2888         };
2889         struct criticality_t : asn::fixedtypefield<X2AP_PROTOCOL_IES::criticality_t, true>
2890         {
2891                 size_t get_index() const {return type;}
2892                 bool is_unknown() const { return type == 2; }
2893                 void clear() {type = 0;}
2894                 void select_id_RANfunctionsAccepted() { set(reject); type=1;}
2895                 X2AP_PROTOCOL_IES::criticality_t const& ref_value() const {return ref_nested();}
2896                 template<typename V>  bool decode(V& v)
2897                 {
2898                         clear();
2899                         if(!v(ref_nested())) return false;
2900                         if(equal(reject)) { type = 1; return true; }
2901                         else { type = 2; return true;}
2902                         return false;
2903
2904                 }
2905                 template<typename V> bool encode(V& v) const
2906                 {
2907                         return v(ref_nested());
2908
2909                 }
2910                 protected:
2911                 template<typename V>  bool decode(size_t index, V& v)
2912                 {
2913                         clear();
2914                         switch(index)
2915                         {
2916                         case 1: type = 1; if(v(ref_nested())) { return equal(reject);} return false;
2917                         case 2: type = 2; return v(ref_nested());
2918                         ref_nested().clear();
2919                         }
2920                         return false;
2921
2922                 }
2923                 template<typename V> bool encode(size_t index, V& v) const
2924                 {
2925                         if(index != type) {return false;} return v(ref_nested());
2926
2927                 }
2928                 private:
2929                 size_t type {0};
2930
2931         };
2932         struct Value_t : asn::typefield<true>
2933         {
2934                 ~Value_t()      {clear();}
2935                 size_t get_index() const {return type;}
2936                 RANfunctionsID_List& select_id_RANfunctionsAccepted() { return set<RANfunctionsID_List>(1); }
2937                 RANfunctionsID_List const* get_id_RANfunctionsAccepted() const { return get<RANfunctionsID_List>(1); }
2938                 bool is_unknown() const { return type == 2; }
2939                 void clear()
2940                 {
2941                         switch(type)
2942                         {
2943                         case 1: var.destroy<RANfunctionsID_List>(); break;
2944                         }
2945                         type = 0; ref_nested().clear();
2946                 }
2947                 template<typename V> static inline void enumerate(V& v)
2948                 {
2949                         v.template operator()<RANfunctionsID_List>(1);
2950
2951                 }
2952                 protected:
2953                 template<typename V> bool decode(size_t index, V& v)
2954                 {
2955                         clear();
2956                         switch(index)
2957                         {
2958                         case 1: v(select_id_RANfunctionsAccepted()); return true;
2959                         case 2: if(type != 2) {clear(); asn::base::set();} type = 2; return true;
2960                         }
2961                         return false;
2962
2963                 }
2964                 template<typename V> bool encode(size_t index, V& v) const
2965                 {
2966                         if(index != type) return false;
2967                         switch(type)
2968                         {
2969                         case 1: v(var.as<RANfunctionsID_List>()); return true;
2970                         }
2971                         return false;
2972
2973                 }
2974                 private:
2975                 template<class T> T& set(size_t index) {if(type != index) {clear(); type = index; return var.build<T>();} return var.as<T>();}
2976                 template<class T> T const* get(size_t index) const {if(type == index) {return &var.as<T>();} return nullptr;}
2977                 union union_type
2978                 {
2979                         char dummy1[sizeof(RANfunctionsID_List)];
2980
2981                 };
2982                 asn::variant<sizeof(union_type)> var;
2983                 size_t type {0};
2984
2985         };
2986         struct presence_t : asn::fixedtypefield<X2AP_PROTOCOL_IES::presence_t, true>
2987         {
2988                 size_t get_index() const {return type;}
2989                 bool is_unknown() const { return type == 2; }
2990                 void clear() {type = 0;}
2991                 void select_id_RANfunctionsAccepted() { set(optional); type=1;}
2992                 X2AP_PROTOCOL_IES::presence_t const& ref_value() const {return ref_nested();}
2993                 template<typename V>  bool decode(V& v)
2994                 {
2995                         clear();
2996                         if(!v(ref_nested())) return false;
2997                         if(equal(optional)) { type = 1; return true; }
2998                         else { type = 2; return true;}
2999                         return false;
3000
3001                 }
3002                 template<typename V> bool encode(V& v) const
3003                 {
3004                         return v(ref_nested());
3005
3006                 }
3007                 protected:
3008                 template<typename V>  bool decode(size_t index, V& v)
3009                 {
3010                         clear();
3011                         switch(index)
3012                         {
3013                         case 1: type = 1; if(v(ref_nested())) { return equal(optional);} return false;
3014                         case 2: type = 2; return v(ref_nested());
3015                         ref_nested().clear();
3016                         }
3017                         return false;
3018
3019                 }
3020                 template<typename V> bool encode(size_t index, V& v) const
3021                 {
3022                         if(index != type) {return false;} return v(ref_nested());
3023
3024                 }
3025                 private:
3026                 size_t type {0};
3027
3028         };
3029
3030 };
3031 /*
3032 RICserviceQuery ::= SEQUENCE {
3033         protocolIEs                                     ProtocolIE-Container    {{RICserviceQuery-IEs}},
3034         ...
3035 }
3036 */
3037
3038 struct RICserviceQuery : asn::sequence<1, 0, true, 0>
3039 {
3040         static constexpr const char* name() {return "RICserviceQuery";}
3041         using parent_t = asn::sequence<1, 0, true, 0>;
3042         struct protocolIEs_t : ProtocolIE_Container<RICserviceQuery_IEs>
3043         {
3044                 static constexpr const char* name() {return "protocolIEs_t";}
3045                 using parent_t = ProtocolIE_Container<RICserviceQuery_IEs>;
3046
3047         };
3048         protocolIEs_t& ref_protocolIEs() {return protocolIEs;}
3049         protocolIEs_t const& ref_protocolIEs() const {return protocolIEs;}
3050         template<typename V> void decode(V& v)
3051         {
3052                 v(protocolIEs);
3053
3054         };
3055         template<typename V> void encode(V& v) const
3056         {
3057                 v(protocolIEs);
3058
3059         };
3060         void clear()
3061         {
3062                 protocolIEs.clear();
3063
3064         };
3065         private:
3066         protocolIEs_t   protocolIEs;
3067
3068 };
3069 /*
3070 RICserviceUpdate-IEs X2AP-PROTOCOL-IES ::= {
3071         { ID id-RANfunctionsAdded                       CRITICALITY reject      TYPE RANfunctions-List                  PRESENCE optional}|
3072         { ID id-RANfunctionsModified            CRITICALITY reject      TYPE RANfunctions-List                  PRESENCE optional}|
3073     { ID id-RANfunctionsDeleted                 CRITICALITY reject      TYPE RANfunctionsID-List                PRESENCE optional},
3074         ...
3075 }
3076 */
3077
3078 struct RICserviceUpdate_IEs
3079 {
3080         struct id_t : asn::fixedtypefield<X2AP_PROTOCOL_IES::id_t, true>
3081         {
3082                 size_t get_index() const {return type;}
3083                 bool is_unknown() const { return type == 4; }
3084                 void clear() {type = 0;}
3085                 void select_id_RANfunctionsAdded() { set(id_RANfunctionsAdded); type=1;}
3086                 void select_id_RANfunctionsModified() { set(id_RANfunctionsModified); type=2;}
3087                 void select_id_RANfunctionsDeleted() { set(id_RANfunctionsDeleted); type=3;}
3088                 X2AP_PROTOCOL_IES::id_t const& ref_value() const {return ref_nested();}
3089                 template<typename V>  bool decode(V& v)
3090                 {
3091                         clear();
3092                         if(!v(ref_nested())) return false;
3093                         if(equal(id_RANfunctionsAdded)) { type = 1; return true; }
3094                         else if(equal(id_RANfunctionsModified)) { type = 2; return true; }
3095                         else if(equal(id_RANfunctionsDeleted)) { type = 3; return true; }
3096                         else { type = 4; return true;}
3097                         return false;
3098
3099                 }
3100                 template<typename V> bool encode(V& v) const
3101                 {
3102                         return v(ref_nested());
3103
3104                 }
3105                 protected:
3106                 template<typename V>  bool decode(size_t index, V& v)
3107                 {
3108                         clear();
3109                         switch(index)
3110                         {
3111                         case 1: type = 1; if(v(ref_nested())) { return equal(id_RANfunctionsAdded);} return false;
3112                         case 2: type = 2; if(v(ref_nested())) { return equal(id_RANfunctionsModified);} return false;
3113                         case 3: type = 3; if(v(ref_nested())) { return equal(id_RANfunctionsDeleted);} return false;
3114                         case 4: type = 4; return v(ref_nested());
3115                         ref_nested().clear();
3116                         }
3117                         return false;
3118
3119                 }
3120                 template<typename V> bool encode(size_t index, V& v) const
3121                 {
3122                         if(index != type) {return false;} return v(ref_nested());
3123
3124                 }
3125                 private:
3126                 size_t type {0};
3127
3128         };
3129         struct criticality_t : asn::fixedtypefield<X2AP_PROTOCOL_IES::criticality_t, true>
3130         {
3131                 size_t get_index() const {return type;}
3132                 bool is_unknown() const { return type == 4; }
3133                 void clear() {type = 0;}
3134                 void select_id_RANfunctionsAdded() { set(reject); type=1;}
3135                 void select_id_RANfunctionsModified() { set(reject); type=2;}
3136                 void select_id_RANfunctionsDeleted() { set(reject); type=3;}
3137                 X2AP_PROTOCOL_IES::criticality_t const& ref_value() const {return ref_nested();}
3138                 template<typename V>  bool decode(V& v)
3139                 {
3140                         clear();
3141                         if(!v(ref_nested())) return false;
3142                         if(equal(reject)) { type = 1; return true; }
3143                         else if(equal(reject)) { type = 2; return true; }
3144                         else if(equal(reject)) { type = 3; return true; }
3145                         else { type = 4; return true;}
3146                         return false;
3147
3148                 }
3149                 template<typename V> bool encode(V& v) const
3150                 {
3151                         return v(ref_nested());
3152
3153                 }
3154                 protected:
3155                 template<typename V>  bool decode(size_t index, V& v)
3156                 {
3157                         clear();
3158                         switch(index)
3159                         {
3160                         case 1: type = 1; if(v(ref_nested())) { return equal(reject);} return false;
3161                         case 2: type = 2; if(v(ref_nested())) { return equal(reject);} return false;
3162                         case 3: type = 3; if(v(ref_nested())) { return equal(reject);} return false;
3163                         case 4: type = 4; return v(ref_nested());
3164                         ref_nested().clear();
3165                         }
3166                         return false;
3167
3168                 }
3169                 template<typename V> bool encode(size_t index, V& v) const
3170                 {
3171                         if(index != type) {return false;} return v(ref_nested());
3172
3173                 }
3174                 private:
3175                 size_t type {0};
3176
3177         };
3178         struct Value_t : asn::typefield<true>
3179         {
3180                 ~Value_t()      {clear();}
3181                 size_t get_index() const {return type;}
3182                 RANfunctions_List& select_id_RANfunctionsAdded() { return set<RANfunctions_List>(1); }
3183                 RANfunctions_List const* get_id_RANfunctionsAdded() const { return get<RANfunctions_List>(1); }
3184                 RANfunctions_List& select_id_RANfunctionsModified() { return set<RANfunctions_List>(2); }
3185                 RANfunctions_List const* get_id_RANfunctionsModified() const { return get<RANfunctions_List>(2); }
3186                 RANfunctionsID_List& select_id_RANfunctionsDeleted() { return set<RANfunctionsID_List>(3); }
3187                 RANfunctionsID_List const* get_id_RANfunctionsDeleted() const { return get<RANfunctionsID_List>(3); }
3188                 bool is_unknown() const { return type == 4; }
3189                 void clear()
3190                 {
3191                         switch(type)
3192                         {
3193                         case 1: var.destroy<RANfunctions_List>(); break;
3194                         case 2: var.destroy<RANfunctions_List>(); break;
3195                         case 3: var.destroy<RANfunctionsID_List>(); break;
3196                         }
3197                         type = 0; ref_nested().clear();
3198                 }
3199                 template<typename V> static inline void enumerate(V& v)
3200                 {
3201                         v.template operator()<RANfunctions_List>(1);
3202                         v.template operator()<RANfunctions_List>(2);
3203                         v.template operator()<RANfunctionsID_List>(3);
3204
3205                 }
3206                 protected:
3207                 template<typename V> bool decode(size_t index, V& v)
3208                 {
3209                         clear();
3210                         switch(index)
3211                         {
3212                         case 1: v(select_id_RANfunctionsAdded()); return true;
3213                         case 2: v(select_id_RANfunctionsModified()); return true;
3214                         case 3: v(select_id_RANfunctionsDeleted()); return true;
3215                         case 4: if(type != 4) {clear(); asn::base::set();} type = 4; return true;
3216                         }
3217                         return false;
3218
3219                 }
3220                 template<typename V> bool encode(size_t index, V& v) const
3221                 {
3222                         if(index != type) return false;
3223                         switch(type)
3224                         {
3225                         case 1: v(var.as<RANfunctions_List>()); return true;
3226                         case 2: v(var.as<RANfunctions_List>()); return true;
3227                         case 3: v(var.as<RANfunctionsID_List>()); return true;
3228                         }
3229                         return false;
3230
3231                 }
3232                 private:
3233                 template<class T> T& set(size_t index) {if(type != index) {clear(); type = index; return var.build<T>();} return var.as<T>();}
3234                 template<class T> T const* get(size_t index) const {if(type == index) {return &var.as<T>();} return nullptr;}
3235                 union union_type
3236                 {
3237                         char dummy1[sizeof(RANfunctionsID_List)];
3238                         char dummy2[sizeof(RANfunctions_List)];
3239
3240                 };
3241                 asn::variant<sizeof(union_type)> var;
3242                 size_t type {0};
3243
3244         };
3245         struct presence_t : asn::fixedtypefield<X2AP_PROTOCOL_IES::presence_t, true>
3246         {
3247                 size_t get_index() const {return type;}
3248                 bool is_unknown() const { return type == 4; }
3249                 void clear() {type = 0;}
3250                 void select_id_RANfunctionsAdded() { set(optional); type=1;}
3251                 void select_id_RANfunctionsModified() { set(optional); type=2;}
3252                 void select_id_RANfunctionsDeleted() { set(optional); type=3;}
3253                 X2AP_PROTOCOL_IES::presence_t const& ref_value() const {return ref_nested();}
3254                 template<typename V>  bool decode(V& v)
3255                 {
3256                         clear();
3257                         if(!v(ref_nested())) return false;
3258                         if(equal(optional)) { type = 1; return true; }
3259                         else if(equal(optional)) { type = 2; return true; }
3260                         else if(equal(optional)) { type = 3; return true; }
3261                         else { type = 4; return true;}
3262                         return false;
3263
3264                 }
3265                 template<typename V> bool encode(V& v) const
3266                 {
3267                         return v(ref_nested());
3268
3269                 }
3270                 protected:
3271                 template<typename V>  bool decode(size_t index, V& v)
3272                 {
3273                         clear();
3274                         switch(index)
3275                         {
3276                         case 1: type = 1; if(v(ref_nested())) { return equal(optional);} return false;
3277                         case 2: type = 2; if(v(ref_nested())) { return equal(optional);} return false;
3278                         case 3: type = 3; if(v(ref_nested())) { return equal(optional);} return false;
3279                         case 4: type = 4; return v(ref_nested());
3280                         ref_nested().clear();
3281                         }
3282                         return false;
3283
3284                 }
3285                 template<typename V> bool encode(size_t index, V& v) const
3286                 {
3287                         if(index != type) {return false;} return v(ref_nested());
3288
3289                 }
3290                 private:
3291                 size_t type {0};
3292
3293         };
3294
3295 };
3296 /*
3297 RICserviceUpdate ::= SEQUENCE {
3298         protocolIEs                                     ProtocolIE-Container    {{RICserviceUpdate-IEs}},
3299         ...
3300 }
3301 */
3302
3303 struct RICserviceUpdate : asn::sequence<1, 0, true, 0>
3304 {
3305         static constexpr const char* name() {return "RICserviceUpdate";}
3306         using parent_t = asn::sequence<1, 0, true, 0>;
3307         struct protocolIEs_t : ProtocolIE_Container<RICserviceUpdate_IEs>
3308         {
3309                 static constexpr const char* name() {return "protocolIEs_t";}
3310                 using parent_t = ProtocolIE_Container<RICserviceUpdate_IEs>;
3311
3312         };
3313         protocolIEs_t& ref_protocolIEs() {return protocolIEs;}
3314         protocolIEs_t const& ref_protocolIEs() const {return protocolIEs;}
3315         template<typename V> void decode(V& v)
3316         {
3317                 v(protocolIEs);
3318
3319         };
3320         template<typename V> void encode(V& v) const
3321         {
3322                 v(protocolIEs);
3323
3324         };
3325         void clear()
3326         {
3327                 protocolIEs.clear();
3328
3329         };
3330         private:
3331         protocolIEs_t   protocolIEs;
3332
3333 };
3334 /*
3335 RICserviceUpdateAcknowledge-IEs X2AP-PROTOCOL-IES ::= {
3336         { ID id-RANfunctionsAccepted            CRITICALITY reject      TYPE RANfunctionsID-List                        PRESENCE optional}|
3337         { ID id-RANfunctionsRejected            CRITICALITY reject      TYPE RANfunctionsIDcause-List           PRESENCE optional},
3338         ...
3339 }
3340 */
3341
3342 struct RICserviceUpdateAcknowledge_IEs
3343 {
3344         struct id_t : asn::fixedtypefield<X2AP_PROTOCOL_IES::id_t, true>
3345         {
3346                 size_t get_index() const {return type;}
3347                 bool is_unknown() const { return type == 3; }
3348                 void clear() {type = 0;}
3349                 void select_id_RANfunctionsAccepted() { set(id_RANfunctionsAccepted); type=1;}
3350                 void select_id_RANfunctionsRejected() { set(id_RANfunctionsRejected); type=2;}
3351                 X2AP_PROTOCOL_IES::id_t const& ref_value() const {return ref_nested();}
3352                 template<typename V>  bool decode(V& v)
3353                 {
3354                         clear();
3355                         if(!v(ref_nested())) return false;
3356                         if(equal(id_RANfunctionsAccepted)) { type = 1; return true; }
3357                         else if(equal(id_RANfunctionsRejected)) { type = 2; return true; }
3358                         else { type = 3; return true;}
3359                         return false;
3360
3361                 }
3362                 template<typename V> bool encode(V& v) const
3363                 {
3364                         return v(ref_nested());
3365
3366                 }
3367                 protected:
3368                 template<typename V>  bool decode(size_t index, V& v)
3369                 {
3370                         clear();
3371                         switch(index)
3372                         {
3373                         case 1: type = 1; if(v(ref_nested())) { return equal(id_RANfunctionsAccepted);} return false;
3374                         case 2: type = 2; if(v(ref_nested())) { return equal(id_RANfunctionsRejected);} return false;
3375                         case 3: type = 3; return v(ref_nested());
3376                         ref_nested().clear();
3377                         }
3378                         return false;
3379
3380                 }
3381                 template<typename V> bool encode(size_t index, V& v) const
3382                 {
3383                         if(index != type) {return false;} return v(ref_nested());
3384
3385                 }
3386                 private:
3387                 size_t type {0};
3388
3389         };
3390         struct criticality_t : asn::fixedtypefield<X2AP_PROTOCOL_IES::criticality_t, true>
3391         {
3392                 size_t get_index() const {return type;}
3393                 bool is_unknown() const { return type == 3; }
3394                 void clear() {type = 0;}
3395                 void select_id_RANfunctionsAccepted() { set(reject); type=1;}
3396                 void select_id_RANfunctionsRejected() { set(reject); type=2;}
3397                 X2AP_PROTOCOL_IES::criticality_t const& ref_value() const {return ref_nested();}
3398                 template<typename V>  bool decode(V& v)
3399                 {
3400                         clear();
3401                         if(!v(ref_nested())) return false;
3402                         if(equal(reject)) { type = 1; return true; }
3403                         else if(equal(reject)) { type = 2; return true; }
3404                         else { type = 3; return true;}
3405                         return false;
3406
3407                 }
3408                 template<typename V> bool encode(V& v) const
3409                 {
3410                         return v(ref_nested());
3411
3412                 }
3413                 protected:
3414                 template<typename V>  bool decode(size_t index, V& v)
3415                 {
3416                         clear();
3417                         switch(index)
3418                         {
3419                         case 1: type = 1; if(v(ref_nested())) { return equal(reject);} return false;
3420                         case 2: type = 2; if(v(ref_nested())) { return equal(reject);} return false;
3421                         case 3: type = 3; return v(ref_nested());
3422                         ref_nested().clear();
3423                         }
3424                         return false;
3425
3426                 }
3427                 template<typename V> bool encode(size_t index, V& v) const
3428                 {
3429                         if(index != type) {return false;} return v(ref_nested());
3430
3431                 }
3432                 private:
3433                 size_t type {0};
3434
3435         };
3436         struct Value_t : asn::typefield<true>
3437         {
3438                 ~Value_t()      {clear();}
3439                 size_t get_index() const {return type;}
3440                 RANfunctionsID_List& select_id_RANfunctionsAccepted() { return set<RANfunctionsID_List>(1); }
3441                 RANfunctionsID_List const* get_id_RANfunctionsAccepted() const { return get<RANfunctionsID_List>(1); }
3442                 RANfunctionsIDcause_List& select_id_RANfunctionsRejected() { return set<RANfunctionsIDcause_List>(2); }
3443                 RANfunctionsIDcause_List const* get_id_RANfunctionsRejected() const { return get<RANfunctionsIDcause_List>(2); }
3444                 bool is_unknown() const { return type == 3; }
3445                 void clear()
3446                 {
3447                         switch(type)
3448                         {
3449                         case 1: var.destroy<RANfunctionsID_List>(); break;
3450                         case 2: var.destroy<RANfunctionsIDcause_List>(); break;
3451                         }
3452                         type = 0; ref_nested().clear();
3453                 }
3454                 template<typename V> static inline void enumerate(V& v)
3455                 {
3456                         v.template operator()<RANfunctionsID_List>(1);
3457                         v.template operator()<RANfunctionsIDcause_List>(2);
3458
3459                 }
3460                 protected:
3461                 template<typename V> bool decode(size_t index, V& v)
3462                 {
3463                         clear();
3464                         switch(index)
3465                         {
3466                         case 1: v(select_id_RANfunctionsAccepted()); return true;
3467                         case 2: v(select_id_RANfunctionsRejected()); return true;
3468                         case 3: if(type != 3) {clear(); asn::base::set();} type = 3; return true;
3469                         }
3470                         return false;
3471
3472                 }
3473                 template<typename V> bool encode(size_t index, V& v) const
3474                 {
3475                         if(index != type) return false;
3476                         switch(type)
3477                         {
3478                         case 1: v(var.as<RANfunctionsID_List>()); return true;
3479                         case 2: v(var.as<RANfunctionsIDcause_List>()); return true;
3480                         }
3481                         return false;
3482
3483                 }
3484                 private:
3485                 template<class T> T& set(size_t index) {if(type != index) {clear(); type = index; return var.build<T>();} return var.as<T>();}
3486                 template<class T> T const* get(size_t index) const {if(type == index) {return &var.as<T>();} return nullptr;}
3487                 union union_type
3488                 {
3489                         char dummy1[sizeof(RANfunctionsID_List)];
3490                         char dummy2[sizeof(RANfunctionsIDcause_List)];
3491
3492                 };
3493                 asn::variant<sizeof(union_type)> var;
3494                 size_t type {0};
3495
3496         };
3497         struct presence_t : asn::fixedtypefield<X2AP_PROTOCOL_IES::presence_t, true>
3498         {
3499                 size_t get_index() const {return type;}
3500                 bool is_unknown() const { return type == 3; }
3501                 void clear() {type = 0;}
3502                 void select_id_RANfunctionsAccepted() { set(optional); type=1;}
3503                 void select_id_RANfunctionsRejected() { set(optional); type=2;}
3504                 X2AP_PROTOCOL_IES::presence_t const& ref_value() const {return ref_nested();}
3505                 template<typename V>  bool decode(V& v)
3506                 {
3507                         clear();
3508                         if(!v(ref_nested())) return false;
3509                         if(equal(optional)) { type = 1; return true; }
3510                         else if(equal(optional)) { type = 2; return true; }
3511                         else { type = 3; return true;}
3512                         return false;
3513
3514                 }
3515                 template<typename V> bool encode(V& v) const
3516                 {
3517                         return v(ref_nested());
3518
3519                 }
3520                 protected:
3521                 template<typename V>  bool decode(size_t index, V& v)
3522                 {
3523                         clear();
3524                         switch(index)
3525                         {
3526                         case 1: type = 1; if(v(ref_nested())) { return equal(optional);} return false;
3527                         case 2: type = 2; if(v(ref_nested())) { return equal(optional);} return false;
3528                         case 3: type = 3; return v(ref_nested());
3529                         ref_nested().clear();
3530                         }
3531                         return false;
3532
3533                 }
3534                 template<typename V> bool encode(size_t index, V& v) const
3535                 {
3536                         if(index != type) {return false;} return v(ref_nested());
3537
3538                 }
3539                 private:
3540                 size_t type {0};
3541
3542         };
3543
3544 };
3545 /*
3546 RICserviceUpdateAcknowledge ::= SEQUENCE {
3547         protocolIEs                                     ProtocolIE-Container    {{RICserviceUpdateAcknowledge-IEs}},
3548         ...
3549 }
3550 */
3551
3552 struct RICserviceUpdateAcknowledge : asn::sequence<1, 0, true, 0>
3553 {
3554         static constexpr const char* name() {return "RICserviceUpdateAcknowledge";}
3555         using parent_t = asn::sequence<1, 0, true, 0>;
3556         struct protocolIEs_t : ProtocolIE_Container<RICserviceUpdateAcknowledge_IEs>
3557         {
3558                 static constexpr const char* name() {return "protocolIEs_t";}
3559                 using parent_t = ProtocolIE_Container<RICserviceUpdateAcknowledge_IEs>;
3560
3561         };
3562         protocolIEs_t& ref_protocolIEs() {return protocolIEs;}
3563         protocolIEs_t const& ref_protocolIEs() const {return protocolIEs;}
3564         template<typename V> void decode(V& v)
3565         {
3566                 v(protocolIEs);
3567
3568         };
3569         template<typename V> void encode(V& v) const
3570         {
3571                 v(protocolIEs);
3572
3573         };
3574         void clear()
3575         {
3576                 protocolIEs.clear();
3577
3578         };
3579         private:
3580         protocolIEs_t   protocolIEs;
3581
3582 };
3583 /*
3584 RICserviceUpdateFailure-IEs X2AP-PROTOCOL-IES ::= {
3585         { ID id-RANfunctionsRejected            CRITICALITY reject      TYPE RANfunctionsIDcause-List           PRESENCE optional}|
3586         { ID id-TimeToWait                                      CRITICALITY ignore      TYPE TimeToWait                                         PRESENCE optional}|
3587     { ID id-CriticalityDiagnostics              CRITICALITY ignore      TYPE CriticalityDiagnostics                     PRESENCE optional},
3588         ...
3589 }
3590 */
3591
3592 struct RICserviceUpdateFailure_IEs
3593 {
3594         struct id_t : asn::fixedtypefield<X2AP_PROTOCOL_IES::id_t, true>
3595         {
3596                 size_t get_index() const {return type;}
3597                 bool is_unknown() const { return type == 4; }
3598                 void clear() {type = 0;}
3599                 void select_id_RANfunctionsRejected() { set(id_RANfunctionsRejected); type=1;}
3600                 void select_id_TimeToWait() { set(id_TimeToWait); type=2;}
3601                 void select_id_CriticalityDiagnostics() { set(id_CriticalityDiagnostics); type=3;}
3602                 X2AP_PROTOCOL_IES::id_t const& ref_value() const {return ref_nested();}
3603                 template<typename V>  bool decode(V& v)
3604                 {
3605                         clear();
3606                         if(!v(ref_nested())) return false;
3607                         if(equal(id_RANfunctionsRejected)) { type = 1; return true; }
3608                         else if(equal(id_TimeToWait)) { type = 2; return true; }
3609                         else if(equal(id_CriticalityDiagnostics)) { type = 3; return true; }
3610                         else { type = 4; return true;}
3611                         return false;
3612
3613                 }
3614                 template<typename V> bool encode(V& v) const
3615                 {
3616                         return v(ref_nested());
3617
3618                 }
3619                 protected:
3620                 template<typename V>  bool decode(size_t index, V& v)
3621                 {
3622                         clear();
3623                         switch(index)
3624                         {
3625                         case 1: type = 1; if(v(ref_nested())) { return equal(id_RANfunctionsRejected);} return false;
3626                         case 2: type = 2; if(v(ref_nested())) { return equal(id_TimeToWait);} return false;
3627                         case 3: type = 3; if(v(ref_nested())) { return equal(id_CriticalityDiagnostics);} return false;
3628                         case 4: type = 4; return v(ref_nested());
3629                         ref_nested().clear();
3630                         }
3631                         return false;
3632
3633                 }
3634                 template<typename V> bool encode(size_t index, V& v) const
3635                 {
3636                         if(index != type) {return false;} return v(ref_nested());
3637
3638                 }
3639                 private:
3640                 size_t type {0};
3641
3642         };
3643         struct criticality_t : asn::fixedtypefield<X2AP_PROTOCOL_IES::criticality_t, true>
3644         {
3645                 size_t get_index() const {return type;}
3646                 bool is_unknown() const { return type == 4; }
3647                 void clear() {type = 0;}
3648                 void select_id_RANfunctionsRejected() { set(reject); type=1;}
3649                 void select_id_TimeToWait() { set(ignore); type=2;}
3650                 void select_id_CriticalityDiagnostics() { set(ignore); type=3;}
3651                 X2AP_PROTOCOL_IES::criticality_t const& ref_value() const {return ref_nested();}
3652                 template<typename V>  bool decode(V& v)
3653                 {
3654                         clear();
3655                         if(!v(ref_nested())) return false;
3656                         if(equal(reject)) { type = 1; return true; }
3657                         else if(equal(ignore)) { type = 2; return true; }
3658                         else if(equal(ignore)) { type = 3; return true; }
3659                         else { type = 4; return true;}
3660                         return false;
3661
3662                 }
3663                 template<typename V> bool encode(V& v) const
3664                 {
3665                         return v(ref_nested());
3666
3667                 }
3668                 protected:
3669                 template<typename V>  bool decode(size_t index, V& v)
3670                 {
3671                         clear();
3672                         switch(index)
3673                         {
3674                         case 1: type = 1; if(v(ref_nested())) { return equal(reject);} return false;
3675                         case 2: type = 2; if(v(ref_nested())) { return equal(ignore);} return false;
3676                         case 3: type = 3; if(v(ref_nested())) { return equal(ignore);} return false;
3677                         case 4: type = 4; return v(ref_nested());
3678                         ref_nested().clear();
3679                         }
3680                         return false;
3681
3682                 }
3683                 template<typename V> bool encode(size_t index, V& v) const
3684                 {
3685                         if(index != type) {return false;} return v(ref_nested());
3686
3687                 }
3688                 private:
3689                 size_t type {0};
3690
3691         };
3692         struct Value_t : asn::typefield<true>
3693         {
3694                 ~Value_t()      {clear();}
3695                 size_t get_index() const {return type;}
3696                 RANfunctionsIDcause_List& select_id_RANfunctionsRejected() { return set<RANfunctionsIDcause_List>(1); }
3697                 RANfunctionsIDcause_List const* get_id_RANfunctionsRejected() const { return get<RANfunctionsIDcause_List>(1); }
3698                 TimeToWait& select_id_TimeToWait() { return set<TimeToWait>(2); }
3699                 TimeToWait const* get_id_TimeToWait() const { return get<TimeToWait>(2); }
3700                 CriticalityDiagnostics& select_id_CriticalityDiagnostics() { return set<CriticalityDiagnostics>(3); }
3701                 CriticalityDiagnostics const* get_id_CriticalityDiagnostics() const { return get<CriticalityDiagnostics>(3); }
3702                 bool is_unknown() const { return type == 4; }
3703                 void clear()
3704                 {
3705                         switch(type)
3706                         {
3707                         case 1: var.destroy<RANfunctionsIDcause_List>(); break;
3708                         case 2: var.destroy<TimeToWait>(); break;
3709                         case 3: var.destroy<CriticalityDiagnostics>(); break;
3710                         }
3711                         type = 0; ref_nested().clear();
3712                 }
3713                 template<typename V> static inline void enumerate(V& v)
3714                 {
3715                         v.template operator()<RANfunctionsIDcause_List>(1);
3716                         v.template operator()<TimeToWait>(2);
3717                         v.template operator()<CriticalityDiagnostics>(3);
3718
3719                 }
3720                 protected:
3721                 template<typename V> bool decode(size_t index, V& v)
3722                 {
3723                         clear();
3724                         switch(index)
3725                         {
3726                         case 1: v(select_id_RANfunctionsRejected()); return true;
3727                         case 2: v(select_id_TimeToWait()); return true;
3728                         case 3: v(select_id_CriticalityDiagnostics()); return true;
3729                         case 4: if(type != 4) {clear(); asn::base::set();} type = 4; return true;
3730                         }
3731                         return false;
3732
3733                 }
3734                 template<typename V> bool encode(size_t index, V& v) const
3735                 {
3736                         if(index != type) return false;
3737                         switch(type)
3738                         {
3739                         case 1: v(var.as<RANfunctionsIDcause_List>()); return true;
3740                         case 2: v(var.as<TimeToWait>()); return true;
3741                         case 3: v(var.as<CriticalityDiagnostics>()); return true;
3742                         }
3743                         return false;
3744
3745                 }
3746                 private:
3747                 template<class T> T& set(size_t index) {if(type != index) {clear(); type = index; return var.build<T>();} return var.as<T>();}
3748                 template<class T> T const* get(size_t index) const {if(type == index) {return &var.as<T>();} return nullptr;}
3749                 union union_type
3750                 {
3751                         char dummy1[sizeof(CriticalityDiagnostics)];
3752                         char dummy2[sizeof(RANfunctionsIDcause_List)];
3753                         char dummy3[sizeof(TimeToWait)];
3754
3755                 };
3756                 asn::variant<sizeof(union_type)> var;
3757                 size_t type {0};
3758
3759         };
3760         struct presence_t : asn::fixedtypefield<X2AP_PROTOCOL_IES::presence_t, true>
3761         {
3762                 size_t get_index() const {return type;}
3763                 bool is_unknown() const { return type == 4; }
3764                 void clear() {type = 0;}
3765                 void select_id_RANfunctionsRejected() { set(optional); type=1;}
3766                 void select_id_TimeToWait() { set(optional); type=2;}
3767                 void select_id_CriticalityDiagnostics() { set(optional); type=3;}
3768                 X2AP_PROTOCOL_IES::presence_t const& ref_value() const {return ref_nested();}
3769                 template<typename V>  bool decode(V& v)
3770                 {
3771                         clear();
3772                         if(!v(ref_nested())) return false;
3773                         if(equal(optional)) { type = 1; return true; }
3774                         else if(equal(optional)) { type = 2; return true; }
3775                         else if(equal(optional)) { type = 3; return true; }
3776                         else { type = 4; return true;}
3777                         return false;
3778
3779                 }
3780                 template<typename V> bool encode(V& v) const
3781                 {
3782                         return v(ref_nested());
3783
3784                 }
3785                 protected:
3786                 template<typename V>  bool decode(size_t index, V& v)
3787                 {
3788                         clear();
3789                         switch(index)
3790                         {
3791                         case 1: type = 1; if(v(ref_nested())) { return equal(optional);} return false;
3792                         case 2: type = 2; if(v(ref_nested())) { return equal(optional);} return false;
3793                         case 3: type = 3; if(v(ref_nested())) { return equal(optional);} return false;
3794                         case 4: type = 4; return v(ref_nested());
3795                         ref_nested().clear();
3796                         }
3797                         return false;
3798
3799                 }
3800                 template<typename V> bool encode(size_t index, V& v) const
3801                 {
3802                         if(index != type) {return false;} return v(ref_nested());
3803
3804                 }
3805                 private:
3806                 size_t type {0};
3807
3808         };
3809
3810 };
3811 /*
3812 RICserviceUpdateFailure ::= SEQUENCE {
3813         protocolIEs                     ProtocolIE-Container    {{RICserviceUpdateFailure-IEs}},
3814         ...
3815 }
3816 */
3817
3818 struct RICserviceUpdateFailure : asn::sequence<1, 0, true, 0>
3819 {
3820         static constexpr const char* name() {return "RICserviceUpdateFailure";}
3821         using parent_t = asn::sequence<1, 0, true, 0>;
3822         struct protocolIEs_t : ProtocolIE_Container<RICserviceUpdateFailure_IEs>
3823         {
3824                 static constexpr const char* name() {return "protocolIEs_t";}
3825                 using parent_t = ProtocolIE_Container<RICserviceUpdateFailure_IEs>;
3826
3827         };
3828         protocolIEs_t& ref_protocolIEs() {return protocolIEs;}
3829         protocolIEs_t const& ref_protocolIEs() const {return protocolIEs;}
3830         template<typename V> void decode(V& v)
3831         {
3832                 v(protocolIEs);
3833
3834         };
3835         template<typename V> void encode(V& v) const
3836         {
3837                 v(protocolIEs);
3838
3839         };
3840         void clear()
3841         {
3842                 protocolIEs.clear();
3843
3844         };
3845         private:
3846         protocolIEs_t   protocolIEs;
3847
3848 };
3849 /*
3850 RICsubscription ::= SEQUENCE {
3851         ricEventTriggerDefinition       RICeventTriggerDefinition,
3852         ricAction-ToBeSetup-List        RICactions-ToBeSetup-List,
3853         ...
3854 }
3855 */
3856
3857 struct RICsubscription : asn::sequence<2, 0, true, 0>
3858 {
3859         static constexpr const char* name() {return "RICsubscription";}
3860         using parent_t = asn::sequence<2, 0, true, 0>;
3861         struct ricEventTriggerDefinition_t : RICeventTriggerDefinition
3862         {
3863                 static constexpr const char* name() {return "ricEventTriggerDefinition_t";}
3864                 using parent_t = RICeventTriggerDefinition;
3865
3866         };
3867         ricEventTriggerDefinition_t& ref_ricEventTriggerDefinition() {return ricEventTriggerDefinition;}
3868         ricEventTriggerDefinition_t const& ref_ricEventTriggerDefinition() const {return ricEventTriggerDefinition;}
3869         struct ricAction_ToBeSetup_List_t : RICactions_ToBeSetup_List
3870         {
3871                 static constexpr const char* name() {return "ricAction_ToBeSetup_List_t";}
3872                 using parent_t = RICactions_ToBeSetup_List;
3873
3874         };
3875         ricAction_ToBeSetup_List_t& ref_ricAction_ToBeSetup_List() {return ricAction_ToBeSetup_List;}
3876         ricAction_ToBeSetup_List_t const& ref_ricAction_ToBeSetup_List() const {return ricAction_ToBeSetup_List;}
3877         template<typename V> void decode(V& v)
3878         {
3879                 v(ricEventTriggerDefinition);
3880                 v(ricAction_ToBeSetup_List);
3881
3882         };
3883         template<typename V> void encode(V& v) const
3884         {
3885                 v(ricEventTriggerDefinition);
3886                 v(ricAction_ToBeSetup_List);
3887
3888         };
3889         void clear()
3890         {
3891                 ricEventTriggerDefinition.clear();
3892                 ricAction_ToBeSetup_List.clear();
3893
3894         };
3895         private:
3896         ricEventTriggerDefinition_t     ricEventTriggerDefinition;
3897         ricAction_ToBeSetup_List_t      ricAction_ToBeSetup_List;
3898
3899 };
3900 /*
3901 RICsubscriptionDeleteFailure-IEs X2AP-PROTOCOL-IES ::= {
3902         { ID id-RICrequestID                            CRITICALITY reject      TYPE RICrequestID                                       PRESENCE mandatory}|
3903         { ID id-RANfunctionID                           CRITICALITY reject      TYPE RANfunctionID                                      PRESENCE mandatory}|
3904     { ID id-RICcause                                    CRITICALITY reject      TYPE RICcause                                           PRESENCE mandatory}|
3905     { ID id-CriticalityDiagnostics              CRITICALITY ignore      TYPE CriticalityDiagnostics                     PRESENCE optional},
3906     ...
3907 }
3908 */
3909
3910 struct RICsubscriptionDeleteFailure_IEs
3911 {
3912         struct id_t : asn::fixedtypefield<X2AP_PROTOCOL_IES::id_t, true>
3913         {
3914                 size_t get_index() const {return type;}
3915                 bool is_unknown() const { return type == 5; }
3916                 void clear() {type = 0;}
3917                 void select_id_RICrequestID() { set(id_RICrequestID); type=1;}
3918                 void select_id_RANfunctionID() { set(id_RANfunctionID); type=2;}
3919                 void select_id_RICcause() { set(id_RICcause); type=3;}
3920                 void select_id_CriticalityDiagnostics() { set(id_CriticalityDiagnostics); type=4;}
3921                 X2AP_PROTOCOL_IES::id_t const& ref_value() const {return ref_nested();}
3922                 template<typename V>  bool decode(V& v)
3923                 {
3924                         clear();
3925                         if(!v(ref_nested())) return false;
3926                         if(equal(id_RICrequestID)) { type = 1; return true; }
3927                         else if(equal(id_RANfunctionID)) { type = 2; return true; }
3928                         else if(equal(id_RICcause)) { type = 3; return true; }
3929                         else if(equal(id_CriticalityDiagnostics)) { type = 4; return true; }
3930                         else { type = 5; return true;}
3931                         return false;
3932
3933                 }
3934                 template<typename V> bool encode(V& v) const
3935                 {
3936                         return v(ref_nested());
3937
3938                 }
3939                 protected:
3940                 template<typename V>  bool decode(size_t index, V& v)
3941                 {
3942                         clear();
3943                         switch(index)
3944                         {
3945                         case 1: type = 1; if(v(ref_nested())) { return equal(id_RICrequestID);} return false;
3946                         case 2: type = 2; if(v(ref_nested())) { return equal(id_RANfunctionID);} return false;
3947                         case 3: type = 3; if(v(ref_nested())) { return equal(id_RICcause);} return false;
3948                         case 4: type = 4; if(v(ref_nested())) { return equal(id_CriticalityDiagnostics);} return false;
3949                         case 5: type = 5; return v(ref_nested());
3950                         ref_nested().clear();
3951                         }
3952                         return false;
3953
3954                 }
3955                 template<typename V> bool encode(size_t index, V& v) const
3956                 {
3957                         if(index != type) {return false;} return v(ref_nested());
3958
3959                 }
3960                 private:
3961                 size_t type {0};
3962
3963         };
3964         struct criticality_t : asn::fixedtypefield<X2AP_PROTOCOL_IES::criticality_t, true>
3965         {
3966                 size_t get_index() const {return type;}
3967                 bool is_unknown() const { return type == 5; }
3968                 void clear() {type = 0;}
3969                 void select_id_RICrequestID() { set(reject); type=1;}
3970                 void select_id_RANfunctionID() { set(reject); type=2;}
3971                 void select_id_RICcause() { set(reject); type=3;}
3972                 void select_id_CriticalityDiagnostics() { set(ignore); type=4;}
3973                 X2AP_PROTOCOL_IES::criticality_t const& ref_value() const {return ref_nested();}
3974                 template<typename V>  bool decode(V& v)
3975                 {
3976                         clear();
3977                         if(!v(ref_nested())) return false;
3978                         if(equal(reject)) { type = 1; return true; }
3979                         else if(equal(reject)) { type = 2; return true; }
3980                         else if(equal(reject)) { type = 3; return true; }
3981                         else if(equal(ignore)) { type = 4; return true; }
3982                         else { type = 5; return true;}
3983                         return false;
3984
3985                 }
3986                 template<typename V> bool encode(V& v) const
3987                 {
3988                         return v(ref_nested());
3989
3990                 }
3991                 protected:
3992                 template<typename V>  bool decode(size_t index, V& v)
3993                 {
3994                         clear();
3995                         switch(index)
3996                         {
3997                         case 1: type = 1; if(v(ref_nested())) { return equal(reject);} return false;
3998                         case 2: type = 2; if(v(ref_nested())) { return equal(reject);} return false;
3999                         case 3: type = 3; if(v(ref_nested())) { return equal(reject);} return false;
4000                         case 4: type = 4; if(v(ref_nested())) { return equal(ignore);} return false;
4001                         case 5: type = 5; return v(ref_nested());
4002                         ref_nested().clear();
4003                         }
4004                         return false;
4005
4006                 }
4007                 template<typename V> bool encode(size_t index, V& v) const
4008                 {
4009                         if(index != type) {return false;} return v(ref_nested());
4010
4011                 }
4012                 private:
4013                 size_t type {0};
4014
4015         };
4016         struct Value_t : asn::typefield<true>
4017         {
4018                 ~Value_t()      {clear();}
4019                 size_t get_index() const {return type;}
4020                 RICrequestID& select_id_RICrequestID() { return set<RICrequestID>(1); }
4021                 RICrequestID const* get_id_RICrequestID() const { return get<RICrequestID>(1); }
4022                 RANfunctionID& select_id_RANfunctionID() { return set<RANfunctionID>(2); }
4023                 RANfunctionID const* get_id_RANfunctionID() const { return get<RANfunctionID>(2); }
4024                 RICcause& select_id_RICcause() { return set<RICcause>(3); }
4025                 RICcause const* get_id_RICcause() const { return get<RICcause>(3); }
4026                 CriticalityDiagnostics& select_id_CriticalityDiagnostics() { return set<CriticalityDiagnostics>(4); }
4027                 CriticalityDiagnostics const* get_id_CriticalityDiagnostics() const { return get<CriticalityDiagnostics>(4); }
4028                 bool is_unknown() const { return type == 5; }
4029                 void clear()
4030                 {
4031                         switch(type)
4032                         {
4033                         case 1: var.destroy<RICrequestID>(); break;
4034                         case 2: var.destroy<RANfunctionID>(); break;
4035                         case 3: var.destroy<RICcause>(); break;
4036                         case 4: var.destroy<CriticalityDiagnostics>(); break;
4037                         }
4038                         type = 0; ref_nested().clear();
4039                 }
4040                 template<typename V> static inline void enumerate(V& v)
4041                 {
4042                         v.template operator()<RICrequestID>(1);
4043                         v.template operator()<RANfunctionID>(2);
4044                         v.template operator()<RICcause>(3);
4045                         v.template operator()<CriticalityDiagnostics>(4);
4046
4047                 }
4048                 protected:
4049                 template<typename V> bool decode(size_t index, V& v)
4050                 {
4051                         clear();
4052                         switch(index)
4053                         {
4054                         case 1: v(select_id_RICrequestID()); return true;
4055                         case 2: v(select_id_RANfunctionID()); return true;
4056                         case 3: v(select_id_RICcause()); return true;
4057                         case 4: v(select_id_CriticalityDiagnostics()); return true;
4058                         case 5: if(type != 5) {clear(); asn::base::set();} type = 5; return true;
4059                         }
4060                         return false;
4061
4062                 }
4063                 template<typename V> bool encode(size_t index, V& v) const
4064                 {
4065                         if(index != type) return false;
4066                         switch(type)
4067                         {
4068                         case 1: v(var.as<RICrequestID>()); return true;
4069                         case 2: v(var.as<RANfunctionID>()); return true;
4070                         case 3: v(var.as<RICcause>()); return true;
4071                         case 4: v(var.as<CriticalityDiagnostics>()); return true;
4072                         }
4073                         return false;
4074
4075                 }
4076                 private:
4077                 template<class T> T& set(size_t index) {if(type != index) {clear(); type = index; return var.build<T>();} return var.as<T>();}
4078                 template<class T> T const* get(size_t index) const {if(type == index) {return &var.as<T>();} return nullptr;}
4079                 union union_type
4080                 {
4081                         char dummy1[sizeof(CriticalityDiagnostics)];
4082                         char dummy2[sizeof(RANfunctionID)];
4083                         char dummy3[sizeof(RICcause)];
4084                         char dummy4[sizeof(RICrequestID)];
4085
4086                 };
4087                 asn::variant<sizeof(union_type)> var;
4088                 size_t type {0};
4089
4090         };
4091         struct presence_t : asn::fixedtypefield<X2AP_PROTOCOL_IES::presence_t, true>
4092         {
4093                 size_t get_index() const {return type;}
4094                 bool is_unknown() const { return type == 5; }
4095                 void clear() {type = 0;}
4096                 void select_id_RICrequestID() { set(mandatory); type=1;}
4097                 void select_id_RANfunctionID() { set(mandatory); type=2;}
4098                 void select_id_RICcause() { set(mandatory); type=3;}
4099                 void select_id_CriticalityDiagnostics() { set(optional); type=4;}
4100                 X2AP_PROTOCOL_IES::presence_t const& ref_value() const {return ref_nested();}
4101                 template<typename V>  bool decode(V& v)
4102                 {
4103                         clear();
4104                         if(!v(ref_nested())) return false;
4105                         if(equal(mandatory)) { type = 1; return true; }
4106                         else if(equal(mandatory)) { type = 2; return true; }
4107                         else if(equal(mandatory)) { type = 3; return true; }
4108                         else if(equal(optional)) { type = 4; return true; }
4109                         else { type = 5; return true;}
4110                         return false;
4111
4112                 }
4113                 template<typename V> bool encode(V& v) const
4114                 {
4115                         return v(ref_nested());
4116
4117                 }
4118                 protected:
4119                 template<typename V>  bool decode(size_t index, V& v)
4120                 {
4121                         clear();
4122                         switch(index)
4123                         {
4124                         case 1: type = 1; if(v(ref_nested())) { return equal(mandatory);} return false;
4125                         case 2: type = 2; if(v(ref_nested())) { return equal(mandatory);} return false;
4126                         case 3: type = 3; if(v(ref_nested())) { return equal(mandatory);} return false;
4127                         case 4: type = 4; if(v(ref_nested())) { return equal(optional);} return false;
4128                         case 5: type = 5; return v(ref_nested());
4129                         ref_nested().clear();
4130                         }
4131                         return false;
4132
4133                 }
4134                 template<typename V> bool encode(size_t index, V& v) const
4135                 {
4136                         if(index != type) {return false;} return v(ref_nested());
4137
4138                 }
4139                 private:
4140                 size_t type {0};
4141
4142         };
4143
4144 };
4145 /*
4146 RICsubscriptionDeleteFailure ::= SEQUENCE {
4147         protocolIEs                                     ProtocolIE-Container    {{RICsubscriptionDeleteFailure-IEs}},
4148         ...
4149 }
4150 */
4151
4152 struct RICsubscriptionDeleteFailure : asn::sequence<1, 0, true, 0>
4153 {
4154         static constexpr const char* name() {return "RICsubscriptionDeleteFailure";}
4155         using parent_t = asn::sequence<1, 0, true, 0>;
4156         struct protocolIEs_t : ProtocolIE_Container<RICsubscriptionDeleteFailure_IEs>
4157         {
4158                 static constexpr const char* name() {return "protocolIEs_t";}
4159                 using parent_t = ProtocolIE_Container<RICsubscriptionDeleteFailure_IEs>;
4160
4161         };
4162         protocolIEs_t& ref_protocolIEs() {return protocolIEs;}
4163         protocolIEs_t const& ref_protocolIEs() const {return protocolIEs;}
4164         template<typename V> void decode(V& v)
4165         {
4166                 v(protocolIEs);
4167
4168         };
4169         template<typename V> void encode(V& v) const
4170         {
4171                 v(protocolIEs);
4172
4173         };
4174         void clear()
4175         {
4176                 protocolIEs.clear();
4177
4178         };
4179         private:
4180         protocolIEs_t   protocolIEs;
4181
4182 };
4183 /*
4184 RICsubscriptionDeleteRequest-IEs X2AP-PROTOCOL-IES ::= {
4185         { ID id-RICrequestID                            CRITICALITY reject      TYPE RICrequestID                                       PRESENCE mandatory}|
4186         { ID id-RANfunctionID                           CRITICALITY reject      TYPE RANfunctionID                                      PRESENCE mandatory},
4187     ...
4188 }
4189 */
4190
4191 struct RICsubscriptionDeleteRequest_IEs
4192 {
4193         struct id_t : asn::fixedtypefield<X2AP_PROTOCOL_IES::id_t, true>
4194         {
4195                 size_t get_index() const {return type;}
4196                 bool is_unknown() const { return type == 3; }
4197                 void clear() {type = 0;}
4198                 void select_id_RICrequestID() { set(id_RICrequestID); type=1;}
4199                 void select_id_RANfunctionID() { set(id_RANfunctionID); type=2;}
4200                 X2AP_PROTOCOL_IES::id_t const& ref_value() const {return ref_nested();}
4201                 template<typename V>  bool decode(V& v)
4202                 {
4203                         clear();
4204                         if(!v(ref_nested())) return false;
4205                         if(equal(id_RICrequestID)) { type = 1; return true; }
4206                         else if(equal(id_RANfunctionID)) { type = 2; return true; }
4207                         else { type = 3; return true;}
4208                         return false;
4209
4210                 }
4211                 template<typename V> bool encode(V& v) const
4212                 {
4213                         return v(ref_nested());
4214
4215                 }
4216                 protected:
4217                 template<typename V>  bool decode(size_t index, V& v)
4218                 {
4219                         clear();
4220                         switch(index)
4221                         {
4222                         case 1: type = 1; if(v(ref_nested())) { return equal(id_RICrequestID);} return false;
4223                         case 2: type = 2; if(v(ref_nested())) { return equal(id_RANfunctionID);} return false;
4224                         case 3: type = 3; return v(ref_nested());
4225                         ref_nested().clear();
4226                         }
4227                         return false;
4228
4229                 }
4230                 template<typename V> bool encode(size_t index, V& v) const
4231                 {
4232                         if(index != type) {return false;} return v(ref_nested());
4233
4234                 }
4235                 private:
4236                 size_t type {0};
4237
4238         };
4239         struct criticality_t : asn::fixedtypefield<X2AP_PROTOCOL_IES::criticality_t, true>
4240         {
4241                 size_t get_index() const {return type;}
4242                 bool is_unknown() const { return type == 3; }
4243                 void clear() {type = 0;}
4244                 void select_id_RICrequestID() { set(reject); type=1;}
4245                 void select_id_RANfunctionID() { set(reject); type=2;}
4246                 X2AP_PROTOCOL_IES::criticality_t const& ref_value() const {return ref_nested();}
4247                 template<typename V>  bool decode(V& v)
4248                 {
4249                         clear();
4250                         if(!v(ref_nested())) return false;
4251                         if(equal(reject)) { type = 1; return true; }
4252                         else if(equal(reject)) { type = 2; return true; }
4253                         else { type = 3; return true;}
4254                         return false;
4255
4256                 }
4257                 template<typename V> bool encode(V& v) const
4258                 {
4259                         return v(ref_nested());
4260
4261                 }
4262                 protected:
4263                 template<typename V>  bool decode(size_t index, V& v)
4264                 {
4265                         clear();
4266                         switch(index)
4267                         {
4268                         case 1: type = 1; if(v(ref_nested())) { return equal(reject);} return false;
4269                         case 2: type = 2; if(v(ref_nested())) { return equal(reject);} return false;
4270                         case 3: type = 3; return v(ref_nested());
4271                         ref_nested().clear();
4272                         }
4273                         return false;
4274
4275                 }
4276                 template<typename V> bool encode(size_t index, V& v) const
4277                 {
4278                         if(index != type) {return false;} return v(ref_nested());
4279
4280                 }
4281                 private:
4282                 size_t type {0};
4283
4284         };
4285         struct Value_t : asn::typefield<true>
4286         {
4287                 ~Value_t()      {clear();}
4288                 size_t get_index() const {return type;}
4289                 RICrequestID& select_id_RICrequestID() { return set<RICrequestID>(1); }
4290                 RICrequestID const* get_id_RICrequestID() const { return get<RICrequestID>(1); }
4291                 RANfunctionID& select_id_RANfunctionID() { return set<RANfunctionID>(2); }
4292                 RANfunctionID const* get_id_RANfunctionID() const { return get<RANfunctionID>(2); }
4293                 bool is_unknown() const { return type == 3; }
4294                 void clear()
4295                 {
4296                         switch(type)
4297                         {
4298                         case 1: var.destroy<RICrequestID>(); break;
4299                         case 2: var.destroy<RANfunctionID>(); break;
4300                         }
4301                         type = 0; ref_nested().clear();
4302                 }
4303                 template<typename V> static inline void enumerate(V& v)
4304                 {
4305                         v.template operator()<RICrequestID>(1);
4306                         v.template operator()<RANfunctionID>(2);
4307
4308                 }
4309                 protected:
4310                 template<typename V> bool decode(size_t index, V& v)
4311                 {
4312                         clear();
4313                         switch(index)
4314                         {
4315                         case 1: v(select_id_RICrequestID()); return true;
4316                         case 2: v(select_id_RANfunctionID()); return true;
4317                         case 3: if(type != 3) {clear(); asn::base::set();} type = 3; return true;
4318                         }
4319                         return false;
4320
4321                 }
4322                 template<typename V> bool encode(size_t index, V& v) const
4323                 {
4324                         if(index != type) return false;
4325                         switch(type)
4326                         {
4327                         case 1: v(var.as<RICrequestID>()); return true;
4328                         case 2: v(var.as<RANfunctionID>()); return true;
4329                         }
4330                         return false;
4331
4332                 }
4333                 private:
4334                 template<class T> T& set(size_t index) {if(type != index) {clear(); type = index; return var.build<T>();} return var.as<T>();}
4335                 template<class T> T const* get(size_t index) const {if(type == index) {return &var.as<T>();} return nullptr;}
4336                 union union_type
4337                 {
4338                         char dummy1[sizeof(RANfunctionID)];
4339                         char dummy2[sizeof(RICrequestID)];
4340
4341                 };
4342                 asn::variant<sizeof(union_type)> var;
4343                 size_t type {0};
4344
4345         };
4346         struct presence_t : asn::fixedtypefield<X2AP_PROTOCOL_IES::presence_t, true>
4347         {
4348                 size_t get_index() const {return type;}
4349                 bool is_unknown() const { return type == 3; }
4350                 void clear() {type = 0;}
4351                 void select_id_RICrequestID() { set(mandatory); type=1;}
4352                 void select_id_RANfunctionID() { set(mandatory); type=2;}
4353                 X2AP_PROTOCOL_IES::presence_t const& ref_value() const {return ref_nested();}
4354                 template<typename V>  bool decode(V& v)
4355                 {
4356                         clear();
4357                         if(!v(ref_nested())) return false;
4358                         if(equal(mandatory)) { type = 1; return true; }
4359                         else if(equal(mandatory)) { type = 2; return true; }
4360                         else { type = 3; return true;}
4361                         return false;
4362
4363                 }
4364                 template<typename V> bool encode(V& v) const
4365                 {
4366                         return v(ref_nested());
4367
4368                 }
4369                 protected:
4370                 template<typename V>  bool decode(size_t index, V& v)
4371                 {
4372                         clear();
4373                         switch(index)
4374                         {
4375                         case 1: type = 1; if(v(ref_nested())) { return equal(mandatory);} return false;
4376                         case 2: type = 2; if(v(ref_nested())) { return equal(mandatory);} return false;
4377                         case 3: type = 3; return v(ref_nested());
4378                         ref_nested().clear();
4379                         }
4380                         return false;
4381
4382                 }
4383                 template<typename V> bool encode(size_t index, V& v) const
4384                 {
4385                         if(index != type) {return false;} return v(ref_nested());
4386
4387                 }
4388                 private:
4389                 size_t type {0};
4390
4391         };
4392
4393 };
4394 /*
4395 RICsubscriptionDeleteRequest ::= SEQUENCE {
4396         protocolIEs                                     ProtocolIE-Container    {{RICsubscriptionDeleteRequest-IEs}},
4397         ...
4398 }
4399 */
4400
4401 struct RICsubscriptionDeleteRequest : asn::sequence<1, 0, true, 0>
4402 {
4403         static constexpr const char* name() {return "RICsubscriptionDeleteRequest";}
4404         using parent_t = asn::sequence<1, 0, true, 0>;
4405         struct protocolIEs_t : ProtocolIE_Container<RICsubscriptionDeleteRequest_IEs>
4406         {
4407                 static constexpr const char* name() {return "protocolIEs_t";}
4408                 using parent_t = ProtocolIE_Container<RICsubscriptionDeleteRequest_IEs>;
4409
4410         };
4411         protocolIEs_t& ref_protocolIEs() {return protocolIEs;}
4412         protocolIEs_t const& ref_protocolIEs() const {return protocolIEs;}
4413         template<typename V> void decode(V& v)
4414         {
4415                 v(protocolIEs);
4416
4417         };
4418         template<typename V> void encode(V& v) const
4419         {
4420                 v(protocolIEs);
4421
4422         };
4423         void clear()
4424         {
4425                 protocolIEs.clear();
4426
4427         };
4428         private:
4429         protocolIEs_t   protocolIEs;
4430
4431 };
4432 /*
4433 RICsubscriptionDeleteResponse-IEs X2AP-PROTOCOL-IES ::= {
4434         { ID id-RICrequestID                            CRITICALITY reject      TYPE RICrequestID                                       PRESENCE mandatory}|
4435         { ID id-RANfunctionID                           CRITICALITY reject      TYPE RANfunctionID                                      PRESENCE mandatory},
4436     ...
4437 }
4438 */
4439
4440 struct RICsubscriptionDeleteResponse_IEs
4441 {
4442         struct id_t : asn::fixedtypefield<X2AP_PROTOCOL_IES::id_t, true>
4443         {
4444                 size_t get_index() const {return type;}
4445                 bool is_unknown() const { return type == 3; }
4446                 void clear() {type = 0;}
4447                 void select_id_RICrequestID() { set(id_RICrequestID); type=1;}
4448                 void select_id_RANfunctionID() { set(id_RANfunctionID); type=2;}
4449                 X2AP_PROTOCOL_IES::id_t const& ref_value() const {return ref_nested();}
4450                 template<typename V>  bool decode(V& v)
4451                 {
4452                         clear();
4453                         if(!v(ref_nested())) return false;
4454                         if(equal(id_RICrequestID)) { type = 1; return true; }
4455                         else if(equal(id_RANfunctionID)) { type = 2; return true; }
4456                         else { type = 3; return true;}
4457                         return false;
4458
4459                 }
4460                 template<typename V> bool encode(V& v) const
4461                 {
4462                         return v(ref_nested());
4463
4464                 }
4465                 protected:
4466                 template<typename V>  bool decode(size_t index, V& v)
4467                 {
4468                         clear();
4469                         switch(index)
4470                         {
4471                         case 1: type = 1; if(v(ref_nested())) { return equal(id_RICrequestID);} return false;
4472                         case 2: type = 2; if(v(ref_nested())) { return equal(id_RANfunctionID);} return false;
4473                         case 3: type = 3; return v(ref_nested());
4474                         ref_nested().clear();
4475                         }
4476                         return false;
4477
4478                 }
4479                 template<typename V> bool encode(size_t index, V& v) const
4480                 {
4481                         if(index != type) {return false;} return v(ref_nested());
4482
4483                 }
4484                 private:
4485                 size_t type {0};
4486
4487         };
4488         struct criticality_t : asn::fixedtypefield<X2AP_PROTOCOL_IES::criticality_t, true>
4489         {
4490                 size_t get_index() const {return type;}
4491                 bool is_unknown() const { return type == 3; }
4492                 void clear() {type = 0;}
4493                 void select_id_RICrequestID() { set(reject); type=1;}
4494                 void select_id_RANfunctionID() { set(reject); type=2;}
4495                 X2AP_PROTOCOL_IES::criticality_t const& ref_value() const {return ref_nested();}
4496                 template<typename V>  bool decode(V& v)
4497                 {
4498                         clear();
4499                         if(!v(ref_nested())) return false;
4500                         if(equal(reject)) { type = 1; return true; }
4501                         else if(equal(reject)) { type = 2; return true; }
4502                         else { type = 3; return true;}
4503                         return false;
4504
4505                 }
4506                 template<typename V> bool encode(V& v) const
4507                 {
4508                         return v(ref_nested());
4509
4510                 }
4511                 protected:
4512                 template<typename V>  bool decode(size_t index, V& v)
4513                 {
4514                         clear();
4515                         switch(index)
4516                         {
4517                         case 1: type = 1; if(v(ref_nested())) { return equal(reject);} return false;
4518                         case 2: type = 2; if(v(ref_nested())) { return equal(reject);} return false;
4519                         case 3: type = 3; return v(ref_nested());
4520                         ref_nested().clear();
4521                         }
4522                         return false;
4523
4524                 }
4525                 template<typename V> bool encode(size_t index, V& v) const
4526                 {
4527                         if(index != type) {return false;} return v(ref_nested());
4528
4529                 }
4530                 private:
4531                 size_t type {0};
4532
4533         };
4534         struct Value_t : asn::typefield<true>
4535         {
4536                 ~Value_t()      {clear();}
4537                 size_t get_index() const {return type;}
4538                 RICrequestID& select_id_RICrequestID() { return set<RICrequestID>(1); }
4539                 RICrequestID const* get_id_RICrequestID() const { return get<RICrequestID>(1); }
4540                 RANfunctionID& select_id_RANfunctionID() { return set<RANfunctionID>(2); }
4541                 RANfunctionID const* get_id_RANfunctionID() const { return get<RANfunctionID>(2); }
4542                 bool is_unknown() const { return type == 3; }
4543                 void clear()
4544                 {
4545                         switch(type)
4546                         {
4547                         case 1: var.destroy<RICrequestID>(); break;
4548                         case 2: var.destroy<RANfunctionID>(); break;
4549                         }
4550                         type = 0; ref_nested().clear();
4551                 }
4552                 template<typename V> static inline void enumerate(V& v)
4553                 {
4554                         v.template operator()<RICrequestID>(1);
4555                         v.template operator()<RANfunctionID>(2);
4556
4557                 }
4558                 protected:
4559                 template<typename V> bool decode(size_t index, V& v)
4560                 {
4561                         clear();
4562                         switch(index)
4563                         {
4564                         case 1: v(select_id_RICrequestID()); return true;
4565                         case 2: v(select_id_RANfunctionID()); return true;
4566                         case 3: if(type != 3) {clear(); asn::base::set();} type = 3; return true;
4567                         }
4568                         return false;
4569
4570                 }
4571                 template<typename V> bool encode(size_t index, V& v) const
4572                 {
4573                         if(index != type) return false;
4574                         switch(type)
4575                         {
4576                         case 1: v(var.as<RICrequestID>()); return true;
4577                         case 2: v(var.as<RANfunctionID>()); return true;
4578                         }
4579                         return false;
4580
4581                 }
4582                 private:
4583                 template<class T> T& set(size_t index) {if(type != index) {clear(); type = index; return var.build<T>();} return var.as<T>();}
4584                 template<class T> T const* get(size_t index) const {if(type == index) {return &var.as<T>();} return nullptr;}
4585                 union union_type
4586                 {
4587                         char dummy1[sizeof(RANfunctionID)];
4588                         char dummy2[sizeof(RICrequestID)];
4589
4590                 };
4591                 asn::variant<sizeof(union_type)> var;
4592                 size_t type {0};
4593
4594         };
4595         struct presence_t : asn::fixedtypefield<X2AP_PROTOCOL_IES::presence_t, true>
4596         {
4597                 size_t get_index() const {return type;}
4598                 bool is_unknown() const { return type == 3; }
4599                 void clear() {type = 0;}
4600                 void select_id_RICrequestID() { set(mandatory); type=1;}
4601                 void select_id_RANfunctionID() { set(mandatory); type=2;}
4602                 X2AP_PROTOCOL_IES::presence_t const& ref_value() const {return ref_nested();}
4603                 template<typename V>  bool decode(V& v)
4604                 {
4605                         clear();
4606                         if(!v(ref_nested())) return false;
4607                         if(equal(mandatory)) { type = 1; return true; }
4608                         else if(equal(mandatory)) { type = 2; return true; }
4609                         else { type = 3; return true;}
4610                         return false;
4611
4612                 }
4613                 template<typename V> bool encode(V& v) const
4614                 {
4615                         return v(ref_nested());
4616
4617                 }
4618                 protected:
4619                 template<typename V>  bool decode(size_t index, V& v)
4620                 {
4621                         clear();
4622                         switch(index)
4623                         {
4624                         case 1: type = 1; if(v(ref_nested())) { return equal(mandatory);} return false;
4625                         case 2: type = 2; if(v(ref_nested())) { return equal(mandatory);} return false;
4626                         case 3: type = 3; return v(ref_nested());
4627                         ref_nested().clear();
4628                         }
4629                         return false;
4630
4631                 }
4632                 template<typename V> bool encode(size_t index, V& v) const
4633                 {
4634                         if(index != type) {return false;} return v(ref_nested());
4635
4636                 }
4637                 private:
4638                 size_t type {0};
4639
4640         };
4641
4642 };
4643 /*
4644 RICsubscriptionDeleteResponse ::= SEQUENCE {
4645         protocolIEs                                     ProtocolIE-Container    {{RICsubscriptionDeleteResponse-IEs}},
4646         ...
4647 }
4648 */
4649
4650 struct RICsubscriptionDeleteResponse : asn::sequence<1, 0, true, 0>
4651 {
4652         static constexpr const char* name() {return "RICsubscriptionDeleteResponse";}
4653         using parent_t = asn::sequence<1, 0, true, 0>;
4654         struct protocolIEs_t : ProtocolIE_Container<RICsubscriptionDeleteResponse_IEs>
4655         {
4656                 static constexpr const char* name() {return "protocolIEs_t";}
4657                 using parent_t = ProtocolIE_Container<RICsubscriptionDeleteResponse_IEs>;
4658
4659         };
4660         protocolIEs_t& ref_protocolIEs() {return protocolIEs;}
4661         protocolIEs_t const& ref_protocolIEs() const {return protocolIEs;}
4662         template<typename V> void decode(V& v)
4663         {
4664                 v(protocolIEs);
4665
4666         };
4667         template<typename V> void encode(V& v) const
4668         {
4669                 v(protocolIEs);
4670
4671         };
4672         void clear()
4673         {
4674                 protocolIEs.clear();
4675
4676         };
4677         private:
4678         protocolIEs_t   protocolIEs;
4679
4680 };
4681 /*
4682 RICsubscriptionFailure-IEs X2AP-PROTOCOL-IES ::= {
4683         { ID id-RICrequestID                            CRITICALITY reject      TYPE RICrequestID                                       PRESENCE mandatory}|
4684         { ID id-RANfunctionID                           CRITICALITY reject      TYPE RANfunctionID                                      PRESENCE mandatory}|
4685         { ID id-RICactions-NotAdmitted          CRITICALITY reject      TYPE RICaction-NotAdmitted-List         PRESENCE mandatory}|
4686     { ID id-CriticalityDiagnostics              CRITICALITY ignore      TYPE CriticalityDiagnostics                     PRESENCE optional},
4687     ...
4688 }
4689 */
4690
4691 struct RICsubscriptionFailure_IEs
4692 {
4693         struct id_t : asn::fixedtypefield<X2AP_PROTOCOL_IES::id_t, true>
4694         {
4695                 size_t get_index() const {return type;}
4696                 bool is_unknown() const { return type == 5; }
4697                 void clear() {type = 0;}
4698                 void select_id_RICrequestID() { set(id_RICrequestID); type=1;}
4699                 void select_id_RANfunctionID() { set(id_RANfunctionID); type=2;}
4700                 void select_id_RICactions_NotAdmitted() { set(id_RICactions_NotAdmitted); type=3;}
4701                 void select_id_CriticalityDiagnostics() { set(id_CriticalityDiagnostics); type=4;}
4702                 X2AP_PROTOCOL_IES::id_t const& ref_value() const {return ref_nested();}
4703                 template<typename V>  bool decode(V& v)
4704                 {
4705                         clear();
4706                         if(!v(ref_nested())) return false;
4707                         if(equal(id_RICrequestID)) { type = 1; return true; }
4708                         else if(equal(id_RANfunctionID)) { type = 2; return true; }
4709                         else if(equal(id_RICactions_NotAdmitted)) { type = 3; return true; }
4710                         else if(equal(id_CriticalityDiagnostics)) { type = 4; return true; }
4711                         else { type = 5; return true;}
4712                         return false;
4713
4714                 }
4715                 template<typename V> bool encode(V& v) const
4716                 {
4717                         return v(ref_nested());
4718
4719                 }
4720                 protected:
4721                 template<typename V>  bool decode(size_t index, V& v)
4722                 {
4723                         clear();
4724                         switch(index)
4725                         {
4726                         case 1: type = 1; if(v(ref_nested())) { return equal(id_RICrequestID);} return false;
4727                         case 2: type = 2; if(v(ref_nested())) { return equal(id_RANfunctionID);} return false;
4728                         case 3: type = 3; if(v(ref_nested())) { return equal(id_RICactions_NotAdmitted);} return false;
4729                         case 4: type = 4; if(v(ref_nested())) { return equal(id_CriticalityDiagnostics);} return false;
4730                         case 5: type = 5; return v(ref_nested());
4731                         ref_nested().clear();
4732                         }
4733                         return false;
4734
4735                 }
4736                 template<typename V> bool encode(size_t index, V& v) const
4737                 {
4738                         if(index != type) {return false;} return v(ref_nested());
4739
4740                 }
4741                 private:
4742                 size_t type {0};
4743
4744         };
4745         struct criticality_t : asn::fixedtypefield<X2AP_PROTOCOL_IES::criticality_t, true>
4746         {
4747                 size_t get_index() const {return type;}
4748                 bool is_unknown() const { return type == 5; }
4749                 void clear() {type = 0;}
4750                 void select_id_RICrequestID() { set(reject); type=1;}
4751                 void select_id_RANfunctionID() { set(reject); type=2;}
4752                 void select_id_RICactions_NotAdmitted() { set(reject); type=3;}
4753                 void select_id_CriticalityDiagnostics() { set(ignore); type=4;}
4754                 X2AP_PROTOCOL_IES::criticality_t const& ref_value() const {return ref_nested();}
4755                 template<typename V>  bool decode(V& v)
4756                 {
4757                         clear();
4758                         if(!v(ref_nested())) return false;
4759                         if(equal(reject)) { type = 1; return true; }
4760                         else if(equal(reject)) { type = 2; return true; }
4761                         else if(equal(reject)) { type = 3; return true; }
4762                         else if(equal(ignore)) { type = 4; return true; }
4763                         else { type = 5; return true;}
4764                         return false;
4765
4766                 }
4767                 template<typename V> bool encode(V& v) const
4768                 {
4769                         return v(ref_nested());
4770
4771                 }
4772                 protected:
4773                 template<typename V>  bool decode(size_t index, V& v)
4774                 {
4775                         clear();
4776                         switch(index)
4777                         {
4778                         case 1: type = 1; if(v(ref_nested())) { return equal(reject);} return false;
4779                         case 2: type = 2; if(v(ref_nested())) { return equal(reject);} return false;
4780                         case 3: type = 3; if(v(ref_nested())) { return equal(reject);} return false;
4781                         case 4: type = 4; if(v(ref_nested())) { return equal(ignore);} return false;
4782                         case 5: type = 5; return v(ref_nested());
4783                         ref_nested().clear();
4784                         }
4785                         return false;
4786
4787                 }
4788                 template<typename V> bool encode(size_t index, V& v) const
4789                 {
4790                         if(index != type) {return false;} return v(ref_nested());
4791
4792                 }
4793                 private:
4794                 size_t type {0};
4795
4796         };
4797         struct Value_t : asn::typefield<true>
4798         {
4799                 ~Value_t()      {clear();}
4800                 size_t get_index() const {return type;}
4801                 RICrequestID& select_id_RICrequestID() { return set<RICrequestID>(1); }
4802                 RICrequestID const* get_id_RICrequestID() const { return get<RICrequestID>(1); }
4803                 RANfunctionID& select_id_RANfunctionID() { return set<RANfunctionID>(2); }
4804                 RANfunctionID const* get_id_RANfunctionID() const { return get<RANfunctionID>(2); }
4805                 RICaction_NotAdmitted_List& select_id_RICactions_NotAdmitted() { return set<RICaction_NotAdmitted_List>(3); }
4806                 RICaction_NotAdmitted_List const* get_id_RICactions_NotAdmitted() const { return get<RICaction_NotAdmitted_List>(3); }
4807                 CriticalityDiagnostics& select_id_CriticalityDiagnostics() { return set<CriticalityDiagnostics>(4); }
4808                 CriticalityDiagnostics const* get_id_CriticalityDiagnostics() const { return get<CriticalityDiagnostics>(4); }
4809                 bool is_unknown() const { return type == 5; }
4810                 void clear()
4811                 {
4812                         switch(type)
4813                         {
4814                         case 1: var.destroy<RICrequestID>(); break;
4815                         case 2: var.destroy<RANfunctionID>(); break;
4816                         case 3: var.destroy<RICaction_NotAdmitted_List>(); break;
4817                         case 4: var.destroy<CriticalityDiagnostics>(); break;
4818                         }
4819                         type = 0; ref_nested().clear();
4820                 }
4821                 template<typename V> static inline void enumerate(V& v)
4822                 {
4823                         v.template operator()<RICrequestID>(1);
4824                         v.template operator()<RANfunctionID>(2);
4825                         v.template operator()<RICaction_NotAdmitted_List>(3);
4826                         v.template operator()<CriticalityDiagnostics>(4);
4827
4828                 }
4829                 protected:
4830                 template<typename V> bool decode(size_t index, V& v)
4831                 {
4832                         clear();
4833                         switch(index)
4834                         {
4835                         case 1: v(select_id_RICrequestID()); return true;
4836                         case 2: v(select_id_RANfunctionID()); return true;
4837                         case 3: v(select_id_RICactions_NotAdmitted()); return true;
4838                         case 4: v(select_id_CriticalityDiagnostics()); return true;
4839                         case 5: if(type != 5) {clear(); asn::base::set();} type = 5; return true;
4840                         }
4841                         return false;
4842
4843                 }
4844                 template<typename V> bool encode(size_t index, V& v) const
4845                 {
4846                         if(index != type) return false;
4847                         switch(type)
4848                         {
4849                         case 1: v(var.as<RICrequestID>()); return true;
4850                         case 2: v(var.as<RANfunctionID>()); return true;
4851                         case 3: v(var.as<RICaction_NotAdmitted_List>()); return true;
4852                         case 4: v(var.as<CriticalityDiagnostics>()); return true;
4853                         }
4854                         return false;
4855
4856                 }
4857                 private:
4858                 template<class T> T& set(size_t index) {if(type != index) {clear(); type = index; return var.build<T>();} return var.as<T>();}
4859                 template<class T> T const* get(size_t index) const {if(type == index) {return &var.as<T>();} return nullptr;}
4860                 union union_type
4861                 {
4862                         char dummy1[sizeof(CriticalityDiagnostics)];
4863                         char dummy2[sizeof(RANfunctionID)];
4864                         char dummy3[sizeof(RICaction_NotAdmitted_List)];
4865                         char dummy4[sizeof(RICrequestID)];
4866
4867                 };
4868                 asn::variant<sizeof(union_type)> var;
4869                 size_t type {0};
4870
4871         };
4872         struct presence_t : asn::fixedtypefield<X2AP_PROTOCOL_IES::presence_t, true>
4873         {
4874                 size_t get_index() const {return type;}
4875                 bool is_unknown() const { return type == 5; }
4876                 void clear() {type = 0;}
4877                 void select_id_RICrequestID() { set(mandatory); type=1;}
4878                 void select_id_RANfunctionID() { set(mandatory); type=2;}
4879                 void select_id_RICactions_NotAdmitted() { set(mandatory); type=3;}
4880                 void select_id_CriticalityDiagnostics() { set(optional); type=4;}
4881                 X2AP_PROTOCOL_IES::presence_t const& ref_value() const {return ref_nested();}
4882                 template<typename V>  bool decode(V& v)
4883                 {
4884                         clear();
4885                         if(!v(ref_nested())) return false;
4886                         if(equal(mandatory)) { type = 1; return true; }
4887                         else if(equal(mandatory)) { type = 2; return true; }
4888                         else if(equal(mandatory)) { type = 3; return true; }
4889                         else if(equal(optional)) { type = 4; return true; }
4890                         else { type = 5; return true;}
4891                         return false;
4892
4893                 }
4894                 template<typename V> bool encode(V& v) const
4895                 {
4896                         return v(ref_nested());
4897
4898                 }
4899                 protected:
4900                 template<typename V>  bool decode(size_t index, V& v)
4901                 {
4902                         clear();
4903                         switch(index)
4904                         {
4905                         case 1: type = 1; if(v(ref_nested())) { return equal(mandatory);} return false;
4906                         case 2: type = 2; if(v(ref_nested())) { return equal(mandatory);} return false;
4907                         case 3: type = 3; if(v(ref_nested())) { return equal(mandatory);} return false;
4908                         case 4: type = 4; if(v(ref_nested())) { return equal(optional);} return false;
4909                         case 5: type = 5; return v(ref_nested());
4910                         ref_nested().clear();
4911                         }
4912                         return false;
4913
4914                 }
4915                 template<typename V> bool encode(size_t index, V& v) const
4916                 {
4917                         if(index != type) {return false;} return v(ref_nested());
4918
4919                 }
4920                 private:
4921                 size_t type {0};
4922
4923         };
4924
4925 };
4926 /*
4927 RICsubscriptionFailure ::= SEQUENCE {
4928         protocolIEs                                     ProtocolIE-Container    {{RICsubscriptionFailure-IEs}},
4929         ...
4930 }
4931 */
4932
4933 struct RICsubscriptionFailure : asn::sequence<1, 0, true, 0>
4934 {
4935         static constexpr const char* name() {return "RICsubscriptionFailure";}
4936         using parent_t = asn::sequence<1, 0, true, 0>;
4937         struct protocolIEs_t : ProtocolIE_Container<RICsubscriptionFailure_IEs>
4938         {
4939                 static constexpr const char* name() {return "protocolIEs_t";}
4940                 using parent_t = ProtocolIE_Container<RICsubscriptionFailure_IEs>;
4941
4942         };
4943         protocolIEs_t& ref_protocolIEs() {return protocolIEs;}
4944         protocolIEs_t const& ref_protocolIEs() const {return protocolIEs;}
4945         template<typename V> void decode(V& v)
4946         {
4947                 v(protocolIEs);
4948
4949         };
4950         template<typename V> void encode(V& v) const
4951         {
4952                 v(protocolIEs);
4953
4954         };
4955         void clear()
4956         {
4957                 protocolIEs.clear();
4958
4959         };
4960         private:
4961         protocolIEs_t   protocolIEs;
4962
4963 };
4964 /*
4965 RICsubscriptionRequest-IEs X2AP-PROTOCOL-IES ::= {
4966         { ID id-RICrequestID                            CRITICALITY reject      TYPE RICrequestID                                       PRESENCE mandatory}|
4967         { ID id-RANfunctionID                           CRITICALITY reject      TYPE RANfunctionID                                      PRESENCE mandatory}|
4968         { ID id-RICsubscription                         CRITICALITY reject      TYPE RICsubscription                            PRESENCE mandatory},
4969         ...
4970 }
4971 */
4972
4973 struct RICsubscriptionRequest_IEs
4974 {
4975         struct id_t : asn::fixedtypefield<X2AP_PROTOCOL_IES::id_t, true>
4976         {
4977                 size_t get_index() const {return type;}
4978                 bool is_unknown() const { return type == 4; }
4979                 void clear() {type = 0;}
4980                 void select_id_RICrequestID() { set(id_RICrequestID); type=1;}
4981                 void select_id_RANfunctionID() { set(id_RANfunctionID); type=2;}
4982                 void select_id_RICsubscription() { set(id_RICsubscription); type=3;}
4983                 X2AP_PROTOCOL_IES::id_t const& ref_value() const {return ref_nested();}
4984                 template<typename V>  bool decode(V& v)
4985                 {
4986                         clear();
4987                         if(!v(ref_nested())) return false;
4988                         if(equal(id_RICrequestID)) { type = 1; return true; }
4989                         else if(equal(id_RANfunctionID)) { type = 2; return true; }
4990                         else if(equal(id_RICsubscription)) { type = 3; return true; }
4991                         else { type = 4; return true;}
4992                         return false;
4993
4994                 }
4995                 template<typename V> bool encode(V& v) const
4996                 {
4997                         return v(ref_nested());
4998
4999                 }
5000                 protected:
5001                 template<typename V>  bool decode(size_t index, V& v)
5002                 {
5003                         clear();
5004                         switch(index)
5005                         {
5006                         case 1: type = 1; if(v(ref_nested())) { return equal(id_RICrequestID);} return false;
5007                         case 2: type = 2; if(v(ref_nested())) { return equal(id_RANfunctionID);} return false;
5008                         case 3: type = 3; if(v(ref_nested())) { return equal(id_RICsubscription);} return false;
5009                         case 4: type = 4; return v(ref_nested());
5010                         ref_nested().clear();
5011                         }
5012                         return false;
5013
5014                 }
5015                 template<typename V> bool encode(size_t index, V& v) const
5016                 {
5017                         if(index != type) {return false;} return v(ref_nested());
5018
5019                 }
5020                 private:
5021                 size_t type {0};
5022
5023         };
5024         struct criticality_t : asn::fixedtypefield<X2AP_PROTOCOL_IES::criticality_t, true>
5025         {
5026                 size_t get_index() const {return type;}
5027                 bool is_unknown() const { return type == 4; }
5028                 void clear() {type = 0;}
5029                 void select_id_RICrequestID() { set(reject); type=1;}
5030                 void select_id_RANfunctionID() { set(reject); type=2;}
5031                 void select_id_RICsubscription() { set(reject); type=3;}
5032                 X2AP_PROTOCOL_IES::criticality_t const& ref_value() const {return ref_nested();}
5033                 template<typename V>  bool decode(V& v)
5034                 {
5035                         clear();
5036                         if(!v(ref_nested())) return false;
5037                         if(equal(reject)) { type = 1; return true; }
5038                         else if(equal(reject)) { type = 2; return true; }
5039                         else if(equal(reject)) { type = 3; return true; }
5040                         else { type = 4; return true;}
5041                         return false;
5042
5043                 }
5044                 template<typename V> bool encode(V& v) const
5045                 {
5046                         return v(ref_nested());
5047
5048                 }
5049                 protected:
5050                 template<typename V>  bool decode(size_t index, V& v)
5051                 {
5052                         clear();
5053                         switch(index)
5054                         {
5055                         case 1: type = 1; if(v(ref_nested())) { return equal(reject);} return false;
5056                         case 2: type = 2; if(v(ref_nested())) { return equal(reject);} return false;
5057                         case 3: type = 3; if(v(ref_nested())) { return equal(reject);} return false;
5058                         case 4: type = 4; return v(ref_nested());
5059                         ref_nested().clear();
5060                         }
5061                         return false;
5062
5063                 }
5064                 template<typename V> bool encode(size_t index, V& v) const
5065                 {
5066                         if(index != type) {return false;} return v(ref_nested());
5067
5068                 }
5069                 private:
5070                 size_t type {0};
5071
5072         };
5073         struct Value_t : asn::typefield<true>
5074         {
5075                 ~Value_t()      {clear();}
5076                 size_t get_index() const {return type;}
5077                 RICrequestID& select_id_RICrequestID() { return set<RICrequestID>(1); }
5078                 RICrequestID const* get_id_RICrequestID() const { return get<RICrequestID>(1); }
5079                 RANfunctionID& select_id_RANfunctionID() { return set<RANfunctionID>(2); }
5080                 RANfunctionID const* get_id_RANfunctionID() const { return get<RANfunctionID>(2); }
5081                 RICsubscription& select_id_RICsubscription() { return set<RICsubscription>(3); }
5082                 RICsubscription const* get_id_RICsubscription() const { return get<RICsubscription>(3); }
5083                 bool is_unknown() const { return type == 4; }
5084                 void clear()
5085                 {
5086                         switch(type)
5087                         {
5088                         case 1: var.destroy<RICrequestID>(); break;
5089                         case 2: var.destroy<RANfunctionID>(); break;
5090                         case 3: var.destroy<RICsubscription>(); break;
5091                         }
5092                         type = 0; ref_nested().clear();
5093                 }
5094                 template<typename V> static inline void enumerate(V& v)
5095                 {
5096                         v.template operator()<RICrequestID>(1);
5097                         v.template operator()<RANfunctionID>(2);
5098                         v.template operator()<RICsubscription>(3);
5099
5100                 }
5101                 protected:
5102                 template<typename V> bool decode(size_t index, V& v)
5103                 {
5104                         clear();
5105                         switch(index)
5106                         {
5107                         case 1: v(select_id_RICrequestID()); return true;
5108                         case 2: v(select_id_RANfunctionID()); return true;
5109                         case 3: v(select_id_RICsubscription()); return true;
5110                         case 4: if(type != 4) {clear(); asn::base::set();} type = 4; return true;
5111                         }
5112                         return false;
5113
5114                 }
5115                 template<typename V> bool encode(size_t index, V& v) const
5116                 {
5117                         if(index != type) return false;
5118                         switch(type)
5119                         {
5120                         case 1: v(var.as<RICrequestID>()); return true;
5121                         case 2: v(var.as<RANfunctionID>()); return true;
5122                         case 3: v(var.as<RICsubscription>()); return true;
5123                         }
5124                         return false;
5125
5126                 }
5127                 private:
5128                 template<class T> T& set(size_t index) {if(type != index) {clear(); type = index; return var.build<T>();} return var.as<T>();}
5129                 template<class T> T const* get(size_t index) const {if(type == index) {return &var.as<T>();} return nullptr;}
5130                 union union_type
5131                 {
5132                         char dummy1[sizeof(RANfunctionID)];
5133                         char dummy2[sizeof(RICrequestID)];
5134                         char dummy3[sizeof(RICsubscription)];
5135
5136                 };
5137                 asn::variant<sizeof(union_type)> var;
5138                 size_t type {0};
5139
5140         };
5141         struct presence_t : asn::fixedtypefield<X2AP_PROTOCOL_IES::presence_t, true>
5142         {
5143                 size_t get_index() const {return type;}
5144                 bool is_unknown() const { return type == 4; }
5145                 void clear() {type = 0;}
5146                 void select_id_RICrequestID() { set(mandatory); type=1;}
5147                 void select_id_RANfunctionID() { set(mandatory); type=2;}
5148                 void select_id_RICsubscription() { set(mandatory); type=3;}
5149                 X2AP_PROTOCOL_IES::presence_t const& ref_value() const {return ref_nested();}
5150                 template<typename V>  bool decode(V& v)
5151                 {
5152                         clear();
5153                         if(!v(ref_nested())) return false;
5154                         if(equal(mandatory)) { type = 1; return true; }
5155                         else if(equal(mandatory)) { type = 2; return true; }
5156                         else if(equal(mandatory)) { type = 3; return true; }
5157                         else { type = 4; return true;}
5158                         return false;
5159
5160                 }
5161                 template<typename V> bool encode(V& v) const
5162                 {
5163                         return v(ref_nested());
5164
5165                 }
5166                 protected:
5167                 template<typename V>  bool decode(size_t index, V& v)
5168                 {
5169                         clear();
5170                         switch(index)
5171                         {
5172                         case 1: type = 1; if(v(ref_nested())) { return equal(mandatory);} return false;
5173                         case 2: type = 2; if(v(ref_nested())) { return equal(mandatory);} return false;
5174                         case 3: type = 3; if(v(ref_nested())) { return equal(mandatory);} return false;
5175                         case 4: type = 4; return v(ref_nested());
5176                         ref_nested().clear();
5177                         }
5178                         return false;
5179
5180                 }
5181                 template<typename V> bool encode(size_t index, V& v) const
5182                 {
5183                         if(index != type) {return false;} return v(ref_nested());
5184
5185                 }
5186                 private:
5187                 size_t type {0};
5188
5189         };
5190
5191 };
5192 /*
5193 RICsubscriptionRequest ::= SEQUENCE {
5194         protocolIEs                                     ProtocolIE-Container    {{RICsubscriptionRequest-IEs}},
5195         ...
5196 }
5197 */
5198
5199 struct RICsubscriptionRequest : asn::sequence<1, 0, true, 0>
5200 {
5201         static constexpr const char* name() {return "RICsubscriptionRequest";}
5202         using parent_t = asn::sequence<1, 0, true, 0>;
5203         struct protocolIEs_t : ProtocolIE_Container<RICsubscriptionRequest_IEs>
5204         {
5205                 static constexpr const char* name() {return "protocolIEs_t";}
5206                 using parent_t = ProtocolIE_Container<RICsubscriptionRequest_IEs>;
5207
5208         };
5209         protocolIEs_t& ref_protocolIEs() {return protocolIEs;}
5210         protocolIEs_t const& ref_protocolIEs() const {return protocolIEs;}
5211         template<typename V> void decode(V& v)
5212         {
5213                 v(protocolIEs);
5214
5215         };
5216         template<typename V> void encode(V& v) const
5217         {
5218                 v(protocolIEs);
5219
5220         };
5221         void clear()
5222         {
5223                 protocolIEs.clear();
5224
5225         };
5226         private:
5227         protocolIEs_t   protocolIEs;
5228
5229 };
5230 /*
5231 RICsubscriptionResponse-IEs X2AP-PROTOCOL-IES ::= {
5232         { ID id-RICrequestID                            CRITICALITY reject              TYPE RICrequestID                               PRESENCE mandatory } |
5233         { ID id-RANfunctionID                           CRITICALITY reject              TYPE RANfunctionID                              PRESENCE mandatory } |
5234         { ID id-RICactions-Admitted                     CRITICALITY reject              TYPE RICaction-Admitted-List    PRESENCE mandatory } |
5235         { ID id-RICactions-NotAdmitted          CRITICALITY reject              TYPE RICaction-NotAdmitted-List PRESENCE optional },
5236     ...
5237 }
5238 */
5239
5240 struct RICsubscriptionResponse_IEs
5241 {
5242         struct id_t : asn::fixedtypefield<X2AP_PROTOCOL_IES::id_t, true>
5243         {
5244                 size_t get_index() const {return type;}
5245                 bool is_unknown() const { return type == 5; }
5246                 void clear() {type = 0;}
5247                 void select_id_RICrequestID() { set(id_RICrequestID); type=1;}
5248                 void select_id_RANfunctionID() { set(id_RANfunctionID); type=2;}
5249                 void select_id_RICactions_Admitted() { set(id_RICactions_Admitted); type=3;}
5250                 void select_id_RICactions_NotAdmitted() { set(id_RICactions_NotAdmitted); type=4;}
5251                 X2AP_PROTOCOL_IES::id_t const& ref_value() const {return ref_nested();}
5252                 template<typename V>  bool decode(V& v)
5253                 {
5254                         clear();
5255                         if(!v(ref_nested())) return false;
5256                         if(equal(id_RICrequestID)) { type = 1; return true; }
5257                         else if(equal(id_RANfunctionID)) { type = 2; return true; }
5258                         else if(equal(id_RICactions_Admitted)) { type = 3; return true; }
5259                         else if(equal(id_RICactions_NotAdmitted)) { type = 4; return true; }
5260                         else { type = 5; return true;}
5261                         return false;
5262
5263                 }
5264                 template<typename V> bool encode(V& v) const
5265                 {
5266                         return v(ref_nested());
5267
5268                 }
5269                 protected:
5270                 template<typename V>  bool decode(size_t index, V& v)
5271                 {
5272                         clear();
5273                         switch(index)
5274                         {
5275                         case 1: type = 1; if(v(ref_nested())) { return equal(id_RICrequestID);} return false;
5276                         case 2: type = 2; if(v(ref_nested())) { return equal(id_RANfunctionID);} return false;
5277                         case 3: type = 3; if(v(ref_nested())) { return equal(id_RICactions_Admitted);} return false;
5278                         case 4: type = 4; if(v(ref_nested())) { return equal(id_RICactions_NotAdmitted);} return false;
5279                         case 5: type = 5; return v(ref_nested());
5280                         ref_nested().clear();
5281                         }
5282                         return false;
5283
5284                 }
5285                 template<typename V> bool encode(size_t index, V& v) const
5286                 {
5287                         if(index != type) {return false;} return v(ref_nested());
5288
5289                 }
5290                 private:
5291                 size_t type {0};
5292
5293         };
5294         struct criticality_t : asn::fixedtypefield<X2AP_PROTOCOL_IES::criticality_t, true>
5295         {
5296                 size_t get_index() const {return type;}
5297                 bool is_unknown() const { return type == 5; }
5298                 void clear() {type = 0;}
5299                 void select_id_RICrequestID() { set(reject); type=1;}
5300                 void select_id_RANfunctionID() { set(reject); type=2;}
5301                 void select_id_RICactions_Admitted() { set(reject); type=3;}
5302                 void select_id_RICactions_NotAdmitted() { set(reject); type=4;}
5303                 X2AP_PROTOCOL_IES::criticality_t const& ref_value() const {return ref_nested();}
5304                 template<typename V>  bool decode(V& v)
5305                 {
5306                         clear();
5307                         if(!v(ref_nested())) return false;
5308                         if(equal(reject)) { type = 1; return true; }
5309                         else if(equal(reject)) { type = 2; return true; }
5310                         else if(equal(reject)) { type = 3; return true; }
5311                         else if(equal(reject)) { type = 4; return true; }
5312                         else { type = 5; return true;}
5313                         return false;
5314
5315                 }
5316                 template<typename V> bool encode(V& v) const
5317                 {
5318                         return v(ref_nested());
5319
5320                 }
5321                 protected:
5322                 template<typename V>  bool decode(size_t index, V& v)
5323                 {
5324                         clear();
5325                         switch(index)
5326                         {
5327                         case 1: type = 1; if(v(ref_nested())) { return equal(reject);} return false;
5328                         case 2: type = 2; if(v(ref_nested())) { return equal(reject);} return false;
5329                         case 3: type = 3; if(v(ref_nested())) { return equal(reject);} return false;
5330                         case 4: type = 4; if(v(ref_nested())) { return equal(reject);} return false;
5331                         case 5: type = 5; return v(ref_nested());
5332                         ref_nested().clear();
5333                         }
5334                         return false;
5335
5336                 }
5337                 template<typename V> bool encode(size_t index, V& v) const
5338                 {
5339                         if(index != type) {return false;} return v(ref_nested());
5340
5341                 }
5342                 private:
5343                 size_t type {0};
5344
5345         };
5346         struct Value_t : asn::typefield<true>
5347         {
5348                 ~Value_t()      {clear();}
5349                 size_t get_index() const {return type;}
5350                 RICrequestID& select_id_RICrequestID() { return set<RICrequestID>(1); }
5351                 RICrequestID const* get_id_RICrequestID() const { return get<RICrequestID>(1); }
5352                 RANfunctionID& select_id_RANfunctionID() { return set<RANfunctionID>(2); }
5353                 RANfunctionID const* get_id_RANfunctionID() const { return get<RANfunctionID>(2); }
5354                 RICaction_Admitted_List& select_id_RICactions_Admitted() { return set<RICaction_Admitted_List>(3); }
5355                 RICaction_Admitted_List const* get_id_RICactions_Admitted() const { return get<RICaction_Admitted_List>(3); }
5356                 RICaction_NotAdmitted_List& select_id_RICactions_NotAdmitted() { return set<RICaction_NotAdmitted_List>(4); }
5357                 RICaction_NotAdmitted_List const* get_id_RICactions_NotAdmitted() const { return get<RICaction_NotAdmitted_List>(4); }
5358                 bool is_unknown() const { return type == 5; }
5359                 void clear()
5360                 {
5361                         switch(type)
5362                         {
5363                         case 1: var.destroy<RICrequestID>(); break;
5364                         case 2: var.destroy<RANfunctionID>(); break;
5365                         case 3: var.destroy<RICaction_Admitted_List>(); break;
5366                         case 4: var.destroy<RICaction_NotAdmitted_List>(); break;
5367                         }
5368                         type = 0; ref_nested().clear();
5369                 }
5370                 template<typename V> static inline void enumerate(V& v)
5371                 {
5372                         v.template operator()<RICrequestID>(1);
5373                         v.template operator()<RANfunctionID>(2);
5374                         v.template operator()<RICaction_Admitted_List>(3);
5375                         v.template operator()<RICaction_NotAdmitted_List>(4);
5376
5377                 }
5378                 protected:
5379                 template<typename V> bool decode(size_t index, V& v)
5380                 {
5381                         clear();
5382                         switch(index)
5383                         {
5384                         case 1: v(select_id_RICrequestID()); return true;
5385                         case 2: v(select_id_RANfunctionID()); return true;
5386                         case 3: v(select_id_RICactions_Admitted()); return true;
5387                         case 4: v(select_id_RICactions_NotAdmitted()); return true;
5388                         case 5: if(type != 5) {clear(); asn::base::set();} type = 5; return true;
5389                         }
5390                         return false;
5391
5392                 }
5393                 template<typename V> bool encode(size_t index, V& v) const
5394                 {
5395                         if(index != type) return false;
5396                         switch(type)
5397                         {
5398                         case 1: v(var.as<RICrequestID>()); return true;
5399                         case 2: v(var.as<RANfunctionID>()); return true;
5400                         case 3: v(var.as<RICaction_Admitted_List>()); return true;
5401                         case 4: v(var.as<RICaction_NotAdmitted_List>()); return true;
5402                         }
5403                         return false;
5404
5405                 }
5406                 private:
5407                 template<class T> T& set(size_t index) {if(type != index) {clear(); type = index; return var.build<T>();} return var.as<T>();}
5408                 template<class T> T const* get(size_t index) const {if(type == index) {return &var.as<T>();} return nullptr;}
5409                 union union_type
5410                 {
5411                         char dummy1[sizeof(RANfunctionID)];
5412                         char dummy2[sizeof(RICaction_Admitted_List)];
5413                         char dummy3[sizeof(RICaction_NotAdmitted_List)];
5414                         char dummy4[sizeof(RICrequestID)];
5415
5416                 };
5417                 asn::variant<sizeof(union_type)> var;
5418                 size_t type {0};
5419
5420         };
5421         struct presence_t : asn::fixedtypefield<X2AP_PROTOCOL_IES::presence_t, true>
5422         {
5423                 size_t get_index() const {return type;}
5424                 bool is_unknown() const { return type == 5; }
5425                 void clear() {type = 0;}
5426                 void select_id_RICrequestID() { set(mandatory); type=1;}
5427                 void select_id_RANfunctionID() { set(mandatory); type=2;}
5428                 void select_id_RICactions_Admitted() { set(mandatory); type=3;}
5429                 void select_id_RICactions_NotAdmitted() { set(optional); type=4;}
5430                 X2AP_PROTOCOL_IES::presence_t const& ref_value() const {return ref_nested();}
5431                 template<typename V>  bool decode(V& v)
5432                 {
5433                         clear();
5434                         if(!v(ref_nested())) return false;
5435                         if(equal(mandatory)) { type = 1; return true; }
5436                         else if(equal(mandatory)) { type = 2; return true; }
5437                         else if(equal(mandatory)) { type = 3; return true; }
5438                         else if(equal(optional)) { type = 4; return true; }
5439                         else { type = 5; return true;}
5440                         return false;
5441
5442                 }
5443                 template<typename V> bool encode(V& v) const
5444                 {
5445                         return v(ref_nested());
5446
5447                 }
5448                 protected:
5449                 template<typename V>  bool decode(size_t index, V& v)
5450                 {
5451                         clear();
5452                         switch(index)
5453                         {
5454                         case 1: type = 1; if(v(ref_nested())) { return equal(mandatory);} return false;
5455                         case 2: type = 2; if(v(ref_nested())) { return equal(mandatory);} return false;
5456                         case 3: type = 3; if(v(ref_nested())) { return equal(mandatory);} return false;
5457                         case 4: type = 4; if(v(ref_nested())) { return equal(optional);} return false;
5458                         case 5: type = 5; return v(ref_nested());
5459                         ref_nested().clear();
5460                         }
5461                         return false;
5462
5463                 }
5464                 template<typename V> bool encode(size_t index, V& v) const
5465                 {
5466                         if(index != type) {return false;} return v(ref_nested());
5467
5468                 }
5469                 private:
5470                 size_t type {0};
5471
5472         };
5473
5474 };
5475 /*
5476 RICsubscriptionResponse ::= SEQUENCE {
5477         protocolIEs                                     ProtocolIE-Container{{RICsubscriptionResponse-IEs}},
5478         ...
5479 }
5480 */
5481
5482 struct RICsubscriptionResponse : asn::sequence<1, 0, true, 0>
5483 {
5484         static constexpr const char* name() {return "RICsubscriptionResponse";}
5485         using parent_t = asn::sequence<1, 0, true, 0>;
5486         struct protocolIEs_t : ProtocolIE_Container<RICsubscriptionResponse_IEs>
5487         {
5488                 static constexpr const char* name() {return "protocolIEs_t";}
5489                 using parent_t = ProtocolIE_Container<RICsubscriptionResponse_IEs>;
5490
5491         };
5492         protocolIEs_t& ref_protocolIEs() {return protocolIEs;}
5493         protocolIEs_t const& ref_protocolIEs() const {return protocolIEs;}
5494         template<typename V> void decode(V& v)
5495         {
5496                 v(protocolIEs);
5497
5498         };
5499         template<typename V> void encode(V& v) const
5500         {
5501                 v(protocolIEs);
5502
5503         };
5504         void clear()
5505         {
5506                 protocolIEs.clear();
5507
5508         };
5509         private:
5510         protocolIEs_t   protocolIEs;
5511
5512 };