ISSUE ID:- RICAPP-216
[ric-app/bouncer.git] / Bouncer / e2sm_kpm / lib / E2SM-KPM-RANfunction-Description.c
1 /*
2  * Generated by asn1c-0.9.29 (http://lionet.info/asn1c)
3  * From ASN.1 module "E2SM-KPM-IEs"
4  *      found in "kpmv2.asn"
5  *      `asn1c -pdu=auto -fincludes-quoted -fcompound-names -findirect-choice -fno-include-deps -gen-PER -no-gen-OER -no-gen-example`
6  */
7
8 #include "E2SM-KPM-RANfunction-Description.h"
9
10 #include "RIC-EventTriggerStyle-Item.h"
11 #include "RIC-ReportStyle-Item.h"
12 static int
13 memb_ric_EventTriggerStyle_List_constraint_1(const asn_TYPE_descriptor_t *td, const void *sptr,
14                         asn_app_constraint_failed_f *ctfailcb, void *app_key) {
15         size_t size;
16         
17         if(!sptr) {
18                 ASN__CTFAIL(app_key, td, sptr,
19                         "%s: value not given (%s:%d)",
20                         td->name, __FILE__, __LINE__);
21                 return -1;
22         }
23         
24         /* Determine the number of elements */
25         size = _A_CSEQUENCE_FROM_VOID(sptr)->count;
26         
27         if((size >= 1 && size <= 63)) {
28                 /* Perform validation of the inner elements */
29                 return td->encoding_constraints.general_constraints(td, sptr, ctfailcb, app_key);
30         } else {
31                 ASN__CTFAIL(app_key, td, sptr,
32                         "%s: constraint failed (%s:%d)",
33                         td->name, __FILE__, __LINE__);
34                 return -1;
35         }
36 }
37
38 static int
39 memb_ric_ReportStyle_List_constraint_1(const asn_TYPE_descriptor_t *td, const void *sptr,
40                         asn_app_constraint_failed_f *ctfailcb, void *app_key) {
41         size_t size;
42         
43         if(!sptr) {
44                 ASN__CTFAIL(app_key, td, sptr,
45                         "%s: value not given (%s:%d)",
46                         td->name, __FILE__, __LINE__);
47                 return -1;
48         }
49         
50         /* Determine the number of elements */
51         size = _A_CSEQUENCE_FROM_VOID(sptr)->count;
52         
53         if((size >= 1 && size <= 63)) {
54                 /* Perform validation of the inner elements */
55                 return td->encoding_constraints.general_constraints(td, sptr, ctfailcb, app_key);
56         } else {
57                 ASN__CTFAIL(app_key, td, sptr,
58                         "%s: constraint failed (%s:%d)",
59                         td->name, __FILE__, __LINE__);
60                 return -1;
61         }
62 }
63
64 static asn_per_constraints_t asn_PER_type_ric_EventTriggerStyle_List_constr_3 CC_NOTUSED = {
65         { APC_UNCONSTRAINED,    -1, -1,  0,  0 },
66         { APC_CONSTRAINED,       6,  6,  1,  63 }       /* (SIZE(1..63)) */,
67         0, 0    /* No PER value map */
68 };
69 static asn_per_constraints_t asn_PER_type_ric_ReportStyle_List_constr_5 CC_NOTUSED = {
70         { APC_UNCONSTRAINED,    -1, -1,  0,  0 },
71         { APC_CONSTRAINED,       6,  6,  1,  63 }       /* (SIZE(1..63)) */,
72         0, 0    /* No PER value map */
73 };
74 static asn_per_constraints_t asn_PER_memb_ric_EventTriggerStyle_List_constr_3 CC_NOTUSED = {
75         { APC_UNCONSTRAINED,    -1, -1,  0,  0 },
76         { APC_CONSTRAINED,       6,  6,  1,  63 }       /* (SIZE(1..63)) */,
77         0, 0    /* No PER value map */
78 };
79 static asn_per_constraints_t asn_PER_memb_ric_ReportStyle_List_constr_5 CC_NOTUSED = {
80         { APC_UNCONSTRAINED,    -1, -1,  0,  0 },
81         { APC_CONSTRAINED,       6,  6,  1,  63 }       /* (SIZE(1..63)) */,
82         0, 0    /* No PER value map */
83 };
84 static asn_TYPE_member_t asn_MBR_ric_EventTriggerStyle_List_3[] = {
85         { ATF_POINTER, 0, 0,
86                 (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)),
87                 0,
88                 &asn_DEF_RIC_EventTriggerStyle_Item,
89                 0,
90                 { 0, 0, 0 },
91                 0, 0, /* No default value */
92                 ""
93                 },
94 };
95 static const ber_tlv_tag_t asn_DEF_ric_EventTriggerStyle_List_tags_3[] = {
96         (ASN_TAG_CLASS_CONTEXT | (1 << 2)),
97         (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))
98 };
99 static asn_SET_OF_specifics_t asn_SPC_ric_EventTriggerStyle_List_specs_3 = {
100         sizeof(struct E2SM_KPM_RANfunction_Description__ric_EventTriggerStyle_List),
101         offsetof(struct E2SM_KPM_RANfunction_Description__ric_EventTriggerStyle_List, _asn_ctx),
102         0,      /* XER encoding is XMLDelimitedItemList */
103 };
104 static /* Use -fall-defs-global to expose */
105 asn_TYPE_descriptor_t asn_DEF_ric_EventTriggerStyle_List_3 = {
106         "ric-EventTriggerStyle-List",
107         "ric-EventTriggerStyle-List",
108         &asn_OP_SEQUENCE_OF,
109         asn_DEF_ric_EventTriggerStyle_List_tags_3,
110         sizeof(asn_DEF_ric_EventTriggerStyle_List_tags_3)
111                 /sizeof(asn_DEF_ric_EventTriggerStyle_List_tags_3[0]) - 1, /* 1 */
112         asn_DEF_ric_EventTriggerStyle_List_tags_3,      /* Same as above */
113         sizeof(asn_DEF_ric_EventTriggerStyle_List_tags_3)
114                 /sizeof(asn_DEF_ric_EventTriggerStyle_List_tags_3[0]), /* 2 */
115         { 0, &asn_PER_type_ric_EventTriggerStyle_List_constr_3, SEQUENCE_OF_constraint },
116         asn_MBR_ric_EventTriggerStyle_List_3,
117         1,      /* Single element */
118         &asn_SPC_ric_EventTriggerStyle_List_specs_3     /* Additional specs */
119 };
120
121 static asn_TYPE_member_t asn_MBR_ric_ReportStyle_List_5[] = {
122         { ATF_POINTER, 0, 0,
123                 (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)),
124                 0,
125                 &asn_DEF_RIC_ReportStyle_Item,
126                 0,
127                 { 0, 0, 0 },
128                 0, 0, /* No default value */
129                 ""
130                 },
131 };
132 static const ber_tlv_tag_t asn_DEF_ric_ReportStyle_List_tags_5[] = {
133         (ASN_TAG_CLASS_CONTEXT | (2 << 2)),
134         (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))
135 };
136 static asn_SET_OF_specifics_t asn_SPC_ric_ReportStyle_List_specs_5 = {
137         sizeof(struct E2SM_KPM_RANfunction_Description__ric_ReportStyle_List),
138         offsetof(struct E2SM_KPM_RANfunction_Description__ric_ReportStyle_List, _asn_ctx),
139         0,      /* XER encoding is XMLDelimitedItemList */
140 };
141 static /* Use -fall-defs-global to expose */
142 asn_TYPE_descriptor_t asn_DEF_ric_ReportStyle_List_5 = {
143         "ric-ReportStyle-List",
144         "ric-ReportStyle-List",
145         &asn_OP_SEQUENCE_OF,
146         asn_DEF_ric_ReportStyle_List_tags_5,
147         sizeof(asn_DEF_ric_ReportStyle_List_tags_5)
148                 /sizeof(asn_DEF_ric_ReportStyle_List_tags_5[0]) - 1, /* 1 */
149         asn_DEF_ric_ReportStyle_List_tags_5,    /* Same as above */
150         sizeof(asn_DEF_ric_ReportStyle_List_tags_5)
151                 /sizeof(asn_DEF_ric_ReportStyle_List_tags_5[0]), /* 2 */
152         { 0, &asn_PER_type_ric_ReportStyle_List_constr_5, SEQUENCE_OF_constraint },
153         asn_MBR_ric_ReportStyle_List_5,
154         1,      /* Single element */
155         &asn_SPC_ric_ReportStyle_List_specs_5   /* Additional specs */
156 };
157
158 static asn_TYPE_member_t asn_MBR_E2SM_KPM_RANfunction_Description_1[] = {
159         { ATF_NOFLAGS, 0, offsetof(struct E2SM_KPM_RANfunction_Description, ranFunction_Name),
160                 (ASN_TAG_CLASS_CONTEXT | (0 << 2)),
161                 -1,     /* IMPLICIT tag at current level */
162                 &asn_DEF_RANfunction_Name,
163                 0,
164                 { 0, 0, 0 },
165                 0, 0, /* No default value */
166                 "ranFunction-Name"
167                 },
168         { ATF_POINTER, 2, offsetof(struct E2SM_KPM_RANfunction_Description, ric_EventTriggerStyle_List),
169                 (ASN_TAG_CLASS_CONTEXT | (1 << 2)),
170                 0,
171                 &asn_DEF_ric_EventTriggerStyle_List_3,
172                 0,
173                 { 0, &asn_PER_memb_ric_EventTriggerStyle_List_constr_3,  memb_ric_EventTriggerStyle_List_constraint_1 },
174                 0, 0, /* No default value */
175                 "ric-EventTriggerStyle-List"
176                 },
177         { ATF_POINTER, 1, offsetof(struct E2SM_KPM_RANfunction_Description, ric_ReportStyle_List),
178                 (ASN_TAG_CLASS_CONTEXT | (2 << 2)),
179                 0,
180                 &asn_DEF_ric_ReportStyle_List_5,
181                 0,
182                 { 0, &asn_PER_memb_ric_ReportStyle_List_constr_5,  memb_ric_ReportStyle_List_constraint_1 },
183                 0, 0, /* No default value */
184                 "ric-ReportStyle-List"
185                 },
186 };
187 static const int asn_MAP_E2SM_KPM_RANfunction_Description_oms_1[] = { 1, 2 };
188 static const ber_tlv_tag_t asn_DEF_E2SM_KPM_RANfunction_Description_tags_1[] = {
189         (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))
190 };
191 static const asn_TYPE_tag2member_t asn_MAP_E2SM_KPM_RANfunction_Description_tag2el_1[] = {
192     { (ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, 0 }, /* ranFunction-Name */
193     { (ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, 0 }, /* ric-EventTriggerStyle-List */
194     { (ASN_TAG_CLASS_CONTEXT | (2 << 2)), 2, 0, 0 } /* ric-ReportStyle-List */
195 };
196 static asn_SEQUENCE_specifics_t asn_SPC_E2SM_KPM_RANfunction_Description_specs_1 = {
197         sizeof(struct E2SM_KPM_RANfunction_Description),
198         offsetof(struct E2SM_KPM_RANfunction_Description, _asn_ctx),
199         asn_MAP_E2SM_KPM_RANfunction_Description_tag2el_1,
200         3,      /* Count of tags in the map */
201         asn_MAP_E2SM_KPM_RANfunction_Description_oms_1, /* Optional members */
202         2, 0,   /* Root/Additions */
203         3,      /* First extension addition */
204 };
205 asn_TYPE_descriptor_t asn_DEF_E2SM_KPM_RANfunction_Description = {
206         "E2SM-KPM-RANfunction-Description",
207         "E2SM-KPM-RANfunction-Description",
208         &asn_OP_SEQUENCE,
209         asn_DEF_E2SM_KPM_RANfunction_Description_tags_1,
210         sizeof(asn_DEF_E2SM_KPM_RANfunction_Description_tags_1)
211                 /sizeof(asn_DEF_E2SM_KPM_RANfunction_Description_tags_1[0]), /* 1 */
212         asn_DEF_E2SM_KPM_RANfunction_Description_tags_1,        /* Same as above */
213         sizeof(asn_DEF_E2SM_KPM_RANfunction_Description_tags_1)
214                 /sizeof(asn_DEF_E2SM_KPM_RANfunction_Description_tags_1[0]), /* 1 */
215         { 0, 0, SEQUENCE_constraint },
216         asn_MBR_E2SM_KPM_RANfunction_Description_1,
217         3,      /* Elements count */
218         &asn_SPC_E2SM_KPM_RANfunction_Description_specs_1       /* Additional specs */
219 };
220