2 * Generated by asn1c-0.9.29 (http://lionet.info/asn1c)
3 * From ASN.1 module "E2AP-PDU-Descriptions"
4 * found in "Spec/e2ap-v031ex.asn"
5 * `asn1c -fcompound-names -fno-include-deps -findirect-choice -gen-PER`
8 #include "InitiatingMessageE2.h"
10 static const long asn_VAL_1_id_ricSubscription = 201;
11 static const long asn_VAL_1_reject = 0;
12 static const long asn_VAL_2_id_ricSubscriptionDelete = 202;
13 static const long asn_VAL_2_reject = 0;
14 static const long asn_VAL_3_id_ricServiceUpdate = 203;
15 static const long asn_VAL_3_reject = 0;
16 static const long asn_VAL_4_id_ricControl = 204;
17 static const long asn_VAL_4_reject = 0;
18 static const long asn_VAL_5_id_ricIndication = 205;
19 static const long asn_VAL_5_ignore = 1;
20 static const long asn_VAL_6_id_ricServiceQuery = 206;
21 static const long asn_VAL_6_ignore = 1;
22 static const asn_ioc_cell_t asn_IOS_E2AP_ELEMENTARY_PROCEDURES_1_rows[] = {
23 { "&InitiatingMessage", aioc__type, &asn_DEF_RICsubscriptionRequest },
24 { "&SuccessfulOutcome", aioc__type, &asn_DEF_RICsubscriptionResponse },
25 { "&UnsuccessfulOutcome", aioc__type, &asn_DEF_RICsubscriptionFailure },
26 { "&procedureCode", aioc__value, &asn_DEF_ProcedureCode, &asn_VAL_1_id_ricSubscription },
27 { "&criticality", aioc__value, &asn_DEF_Criticality, &asn_VAL_1_reject },
28 { "&InitiatingMessage", aioc__type, &asn_DEF_RICsubscriptionDeleteRequest },
29 { "&SuccessfulOutcome", aioc__type, &asn_DEF_RICsubscriptionDeleteResponse },
30 { "&UnsuccessfulOutcome", aioc__type, &asn_DEF_RICsubscriptionDeleteFailure },
31 { "&procedureCode", aioc__value, &asn_DEF_ProcedureCode, &asn_VAL_2_id_ricSubscriptionDelete },
32 { "&criticality", aioc__value, &asn_DEF_Criticality, &asn_VAL_2_reject },
33 { "&InitiatingMessage", aioc__type, &asn_DEF_RICserviceUpdate },
34 { "&SuccessfulOutcome", aioc__type, &asn_DEF_RICserviceUpdateAcknowledge },
35 { "&UnsuccessfulOutcome", aioc__type, &asn_DEF_RICserviceUpdateFailure },
36 { "&procedureCode", aioc__value, &asn_DEF_ProcedureCode, &asn_VAL_3_id_ricServiceUpdate },
37 { "&criticality", aioc__value, &asn_DEF_Criticality, &asn_VAL_3_reject },
38 { "&InitiatingMessage", aioc__type, &asn_DEF_RICcontrolRequest },
39 { "&SuccessfulOutcome", aioc__type, &asn_DEF_RICcontrolAcknowledge },
40 { "&UnsuccessfulOutcome", aioc__type, &asn_DEF_RICcontrolFailure },
41 { "&procedureCode", aioc__value, &asn_DEF_ProcedureCode, &asn_VAL_4_id_ricControl },
42 { "&criticality", aioc__value, &asn_DEF_Criticality, &asn_VAL_4_reject },
43 { "&InitiatingMessage", aioc__type, &asn_DEF_RICindication },
44 { "&SuccessfulOutcome", },
45 { "&UnsuccessfulOutcome", },
46 { "&procedureCode", aioc__value, &asn_DEF_ProcedureCode, &asn_VAL_5_id_ricIndication },
47 { "&criticality", aioc__value, &asn_DEF_Criticality, &asn_VAL_5_ignore },
48 { "&InitiatingMessage", aioc__type, &asn_DEF_RICserviceQuery },
49 { "&SuccessfulOutcome", },
50 { "&UnsuccessfulOutcome", },
51 { "&procedureCode", aioc__value, &asn_DEF_ProcedureCode, &asn_VAL_6_id_ricServiceQuery },
52 { "&criticality", aioc__value, &asn_DEF_Criticality, &asn_VAL_6_ignore }
54 static const asn_ioc_set_t asn_IOS_E2AP_ELEMENTARY_PROCEDURES_1[] = {
55 { 6, 5, asn_IOS_E2AP_ELEMENTARY_PROCEDURES_1_rows }
58 memb_procedureCode_constraint_1(const asn_TYPE_descriptor_t *td, const void *sptr,
59 asn_app_constraint_failed_f *ctfailcb, void *app_key) {
63 ASN__CTFAIL(app_key, td, sptr,
64 "%s: value not given (%s:%d)",
65 td->name, __FILE__, __LINE__);
69 value = *(const long *)sptr;
71 if((value >= 0 && value <= 255)) {
72 /* Constraint check succeeded */
75 ASN__CTFAIL(app_key, td, sptr,
76 "%s: constraint failed (%s:%d)",
77 td->name, __FILE__, __LINE__);
82 static asn_type_selector_result_t
83 select_InitiatingMessageE2_criticality_type(const asn_TYPE_descriptor_t *parent_type, const void *parent_sptr) {
84 asn_type_selector_result_t result = {0, 0};
85 const asn_ioc_set_t *itable = asn_IOS_E2AP_ELEMENTARY_PROCEDURES_1;
86 size_t constraining_column = 3; /* &procedureCode */
87 size_t for_column = 4; /* &criticality */
88 size_t row, presence_index = 0;
89 const long *constraining_value = (const long *)((const char *)parent_sptr + offsetof(struct InitiatingMessageE2, procedureCode));
91 for(row=0; row < itable->rows_count; row++) {
92 const asn_ioc_cell_t *constraining_cell = &itable->rows[row * itable->columns_count + constraining_column];
93 const asn_ioc_cell_t *type_cell = &itable->rows[row * itable->columns_count + for_column];
95 if(type_cell->cell_kind == aioc__undefined)
99 if(constraining_cell->type_descriptor->op->compare_struct(constraining_cell->type_descriptor, constraining_value, constraining_cell->value_sptr) == 0) {
100 result.type_descriptor = type_cell->type_descriptor;
101 result.presence_index = presence_index;
110 memb_criticality_constraint_1(const asn_TYPE_descriptor_t *td, const void *sptr,
111 asn_app_constraint_failed_f *ctfailcb, void *app_key) {
114 ASN__CTFAIL(app_key, td, sptr,
115 "%s: value not given (%s:%d)",
116 td->name, __FILE__, __LINE__);
121 if(1 /* No applicable constraints whatsoever */) {
122 /* Nothing is here. See below */
125 return td->encoding_constraints.general_constraints(td, sptr, ctfailcb, app_key);
128 static asn_type_selector_result_t
129 select_InitiatingMessageE2_value_type(const asn_TYPE_descriptor_t *parent_type, const void *parent_sptr) {
130 asn_type_selector_result_t result = {0, 0};
131 const asn_ioc_set_t *itable = asn_IOS_E2AP_ELEMENTARY_PROCEDURES_1;
132 size_t constraining_column = 3; /* &procedureCode */
133 size_t for_column = 0; /* &InitiatingMessage */
134 size_t row, presence_index = 0;
135 const long *constraining_value = (const long *)((const char *)parent_sptr + offsetof(struct InitiatingMessageE2, procedureCode));
137 for(row=0; row < itable->rows_count; row++) {
138 const asn_ioc_cell_t *constraining_cell = &itable->rows[row * itable->columns_count + constraining_column];
139 const asn_ioc_cell_t *type_cell = &itable->rows[row * itable->columns_count + for_column];
141 if(type_cell->cell_kind == aioc__undefined)
145 if(constraining_cell->type_descriptor->op->compare_struct(constraining_cell->type_descriptor, constraining_value, constraining_cell->value_sptr) == 0) {
146 result.type_descriptor = type_cell->type_descriptor;
147 result.presence_index = presence_index;
156 memb_value_constraint_1(const asn_TYPE_descriptor_t *td, const void *sptr,
157 asn_app_constraint_failed_f *ctfailcb, void *app_key) {
160 ASN__CTFAIL(app_key, td, sptr,
161 "%s: value not given (%s:%d)",
162 td->name, __FILE__, __LINE__);
167 if(1 /* No applicable constraints whatsoever */) {
168 /* Nothing is here. See below */
171 return td->encoding_constraints.general_constraints(td, sptr, ctfailcb, app_key);
174 static asn_oer_constraints_t asn_OER_memb_procedureCode_constr_2 CC_NOTUSED = {
175 { 1, 1 } /* (0..255) */,
177 static asn_per_constraints_t asn_PER_memb_procedureCode_constr_2 CC_NOTUSED = {
178 { APC_CONSTRAINED, 8, 8, 0, 255 } /* (0..255) */,
179 { APC_UNCONSTRAINED, -1, -1, 0, 0 },
180 0, 0 /* No PER value map */
182 static asn_oer_constraints_t asn_OER_memb_criticality_constr_3 CC_NOTUSED = {
185 static asn_per_constraints_t asn_PER_memb_criticality_constr_3 CC_NOTUSED = {
186 { APC_CONSTRAINED, 2, 2, 0, 2 } /* (0..2) */,
187 { APC_UNCONSTRAINED, -1, -1, 0, 0 },
188 0, 0 /* No PER value map */
190 static asn_oer_constraints_t asn_OER_memb_value_constr_4 CC_NOTUSED = {
193 static asn_per_constraints_t asn_PER_memb_value_constr_4 CC_NOTUSED = {
194 { APC_UNCONSTRAINED, -1, -1, 0, 0 },
195 { APC_UNCONSTRAINED, -1, -1, 0, 0 },
196 0, 0 /* No PER value map */
198 static asn_TYPE_member_t asn_MBR_value_4[] = {
199 { ATF_NOFLAGS, 0, offsetof(struct InitiatingMessageE2__value, choice.RICsubscriptionRequest),
200 (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)),
202 &asn_DEF_RICsubscriptionRequest,
205 0, 0, /* No default value */
206 "RICsubscriptionRequest"
208 { ATF_NOFLAGS, 0, offsetof(struct InitiatingMessageE2__value, choice.RICsubscriptionDeleteRequest),
209 (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)),
211 &asn_DEF_RICsubscriptionDeleteRequest,
214 0, 0, /* No default value */
215 "RICsubscriptionDeleteRequest"
217 { ATF_NOFLAGS, 0, offsetof(struct InitiatingMessageE2__value, choice.RICserviceUpdate),
218 (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)),
220 &asn_DEF_RICserviceUpdate,
223 0, 0, /* No default value */
226 { ATF_NOFLAGS, 0, offsetof(struct InitiatingMessageE2__value, choice.RICcontrolRequest),
227 (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)),
229 &asn_DEF_RICcontrolRequest,
232 0, 0, /* No default value */
235 { ATF_NOFLAGS, 0, offsetof(struct InitiatingMessageE2__value, choice.RICindication),
236 (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)),
238 &asn_DEF_RICindication,
241 0, 0, /* No default value */
244 { ATF_NOFLAGS, 0, offsetof(struct InitiatingMessageE2__value, choice.RICserviceQuery),
245 (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)),
247 &asn_DEF_RICserviceQuery,
250 0, 0, /* No default value */
254 static const asn_TYPE_tag2member_t asn_MAP_value_tag2el_4[] = {
255 { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)), 0, 0, 5 }, /* RICsubscriptionRequest */
256 { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)), 1, -1, 4 }, /* RICsubscriptionDeleteRequest */
257 { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)), 2, -2, 3 }, /* RICserviceUpdate */
258 { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)), 3, -3, 2 }, /* RICcontrolRequest */
259 { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)), 4, -4, 1 }, /* RICindication */
260 { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)), 5, -5, 0 } /* RICserviceQuery */
262 static asn_CHOICE_specifics_t asn_SPC_value_specs_4 = {
263 sizeof(struct InitiatingMessageE2__value),
264 offsetof(struct InitiatingMessageE2__value, _asn_ctx),
265 offsetof(struct InitiatingMessageE2__value, present),
266 sizeof(((struct InitiatingMessageE2__value *)0)->present),
267 asn_MAP_value_tag2el_4,
268 6, /* Count of tags in the map */
270 -1 /* Extensions start */
272 static /* Use -fall-defs-global to expose */
273 asn_TYPE_descriptor_t asn_DEF_value_4 = {
277 0, /* No effective tags (pointer) */
278 0, /* No effective tags (count) */
279 0, /* No tags (pointer) */
280 0, /* No tags (count) */
281 { 0, 0, OPEN_TYPE_constraint },
283 6, /* Elements count */
284 &asn_SPC_value_specs_4 /* Additional specs */
287 asn_TYPE_member_t asn_MBR_InitiatingMessageE2_1[] = {
288 { ATF_NOFLAGS, 0, offsetof(struct InitiatingMessageE2, procedureCode),
289 (ASN_TAG_CLASS_CONTEXT | (0 << 2)),
290 -1, /* IMPLICIT tag at current level */
291 &asn_DEF_ProcedureCode,
293 { &asn_OER_memb_procedureCode_constr_2, &asn_PER_memb_procedureCode_constr_2, memb_procedureCode_constraint_1 },
294 0, 0, /* No default value */
297 { ATF_NOFLAGS, 0, offsetof(struct InitiatingMessageE2, criticality),
298 (ASN_TAG_CLASS_CONTEXT | (1 << 2)),
299 -1, /* IMPLICIT tag at current level */
300 &asn_DEF_Criticality,
301 select_InitiatingMessageE2_criticality_type,
302 { &asn_OER_memb_criticality_constr_3, &asn_PER_memb_criticality_constr_3, memb_criticality_constraint_1 },
303 0, 0, /* No default value */
306 { ATF_OPEN_TYPE | ATF_NOFLAGS, 0, offsetof(struct InitiatingMessageE2, value),
307 (ASN_TAG_CLASS_CONTEXT | (2 << 2)),
308 +1, /* EXPLICIT tag at current level */
310 select_InitiatingMessageE2_value_type,
311 { &asn_OER_memb_value_constr_4, &asn_PER_memb_value_constr_4, memb_value_constraint_1 },
312 0, 0, /* No default value */
316 static const ber_tlv_tag_t asn_DEF_InitiatingMessageE2_tags_1[] = {
317 (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))
319 static const asn_TYPE_tag2member_t asn_MAP_InitiatingMessageE2_tag2el_1[] = {
320 { (ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, 0 }, /* procedureCode */
321 { (ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, 0 }, /* criticality */
322 { (ASN_TAG_CLASS_CONTEXT | (2 << 2)), 2, 0, 0 } /* value */
324 asn_SEQUENCE_specifics_t asn_SPC_InitiatingMessageE2_specs_1 = {
325 sizeof(struct InitiatingMessageE2),
326 offsetof(struct InitiatingMessageE2, _asn_ctx),
327 asn_MAP_InitiatingMessageE2_tag2el_1,
328 3, /* Count of tags in the map */
329 0, 0, 0, /* Optional elements (not needed) */
330 -1, /* First extension addition */
332 asn_TYPE_descriptor_t asn_DEF_InitiatingMessageE2 = {
333 "InitiatingMessageE2",
334 "InitiatingMessageE2",
336 asn_DEF_InitiatingMessageE2_tags_1,
337 sizeof(asn_DEF_InitiatingMessageE2_tags_1)
338 /sizeof(asn_DEF_InitiatingMessageE2_tags_1[0]), /* 1 */
339 asn_DEF_InitiatingMessageE2_tags_1, /* Same as above */
340 sizeof(asn_DEF_InitiatingMessageE2_tags_1)
341 /sizeof(asn_DEF_InitiatingMessageE2_tags_1[0]), /* 1 */
342 { 0, 0, SEQUENCE_constraint },
343 asn_MBR_InitiatingMessageE2_1,
344 3, /* Elements count */
345 &asn_SPC_InitiatingMessageE2_specs_1 /* Additional specs */