2 * Generated by asn1c-0.9.29 (http://lionet.info/asn1c)
3 * From ASN.1 module "E2AP-IEs"
4 * found in "spec/e2ap-v01.00.00.asn"
5 * `asn1c -pdu=auto -fincludes-quoted -fcompound-names -fno-include-deps -gen-PER -no-gen-OER -no-gen-example`
8 #include "ENB-ID-Choice.h"
11 memb_enb_ID_macro_constraint_1(const asn_TYPE_descriptor_t *td, const void *sptr,
12 asn_app_constraint_failed_f *ctfailcb, void *app_key) {
13 const BIT_STRING_t *st = (const BIT_STRING_t *)sptr;
17 ASN__CTFAIL(app_key, td, sptr,
18 "%s: value not given (%s:%d)",
19 td->name, __FILE__, __LINE__);
25 size = 8 * st->size - (st->bits_unused & 0x07);
31 /* Constraint check succeeded */
34 ASN__CTFAIL(app_key, td, sptr,
35 "%s: constraint failed (%s:%d)",
36 td->name, __FILE__, __LINE__);
42 memb_enb_ID_shortmacro_constraint_1(const asn_TYPE_descriptor_t *td, const void *sptr,
43 asn_app_constraint_failed_f *ctfailcb, void *app_key) {
44 const BIT_STRING_t *st = (const BIT_STRING_t *)sptr;
48 ASN__CTFAIL(app_key, td, sptr,
49 "%s: value not given (%s:%d)",
50 td->name, __FILE__, __LINE__);
56 size = 8 * st->size - (st->bits_unused & 0x07);
62 /* Constraint check succeeded */
65 ASN__CTFAIL(app_key, td, sptr,
66 "%s: constraint failed (%s:%d)",
67 td->name, __FILE__, __LINE__);
73 memb_enb_ID_longmacro_constraint_1(const asn_TYPE_descriptor_t *td, const void *sptr,
74 asn_app_constraint_failed_f *ctfailcb, void *app_key) {
75 const BIT_STRING_t *st = (const BIT_STRING_t *)sptr;
79 ASN__CTFAIL(app_key, td, sptr,
80 "%s: value not given (%s:%d)",
81 td->name, __FILE__, __LINE__);
87 size = 8 * st->size - (st->bits_unused & 0x07);
93 /* Constraint check succeeded */
96 ASN__CTFAIL(app_key, td, sptr,
97 "%s: constraint failed (%s:%d)",
98 td->name, __FILE__, __LINE__);
103 static asn_per_constraints_t asn_PER_memb_enb_ID_macro_constr_2 CC_NOTUSED = {
104 { APC_UNCONSTRAINED, -1, -1, 0, 0 },
105 { APC_CONSTRAINED, 0, 0, 20, 20 } /* (SIZE(20..20)) */,
106 0, 0 /* No PER value map */
108 static asn_per_constraints_t asn_PER_memb_enb_ID_shortmacro_constr_3 CC_NOTUSED = {
109 { APC_UNCONSTRAINED, -1, -1, 0, 0 },
110 { APC_CONSTRAINED, 0, 0, 18, 18 } /* (SIZE(18..18)) */,
111 0, 0 /* No PER value map */
113 static asn_per_constraints_t asn_PER_memb_enb_ID_longmacro_constr_4 CC_NOTUSED = {
114 { APC_UNCONSTRAINED, -1, -1, 0, 0 },
115 { APC_CONSTRAINED, 0, 0, 21, 21 } /* (SIZE(21..21)) */,
116 0, 0 /* No PER value map */
118 asn_per_constraints_t asn_PER_type_ENB_ID_Choice_constr_1 CC_NOTUSED = {
119 { APC_CONSTRAINED | APC_EXTENSIBLE, 2, 2, 0, 2 } /* (0..2,...) */,
120 { APC_UNCONSTRAINED, -1, -1, 0, 0 },
121 0, 0 /* No PER value map */
123 asn_TYPE_member_t asn_MBR_ENB_ID_Choice_1[] = {
124 { ATF_NOFLAGS, 0, offsetof(struct ENB_ID_Choice, choice.enb_ID_macro),
125 (ASN_TAG_CLASS_CONTEXT | (0 << 2)),
126 -1, /* IMPLICIT tag at current level */
129 { 0, &asn_PER_memb_enb_ID_macro_constr_2, memb_enb_ID_macro_constraint_1 },
130 0, 0, /* No default value */
133 { ATF_NOFLAGS, 0, offsetof(struct ENB_ID_Choice, choice.enb_ID_shortmacro),
134 (ASN_TAG_CLASS_CONTEXT | (1 << 2)),
135 -1, /* IMPLICIT tag at current level */
138 { 0, &asn_PER_memb_enb_ID_shortmacro_constr_3, memb_enb_ID_shortmacro_constraint_1 },
139 0, 0, /* No default value */
142 { ATF_NOFLAGS, 0, offsetof(struct ENB_ID_Choice, choice.enb_ID_longmacro),
143 (ASN_TAG_CLASS_CONTEXT | (2 << 2)),
144 -1, /* IMPLICIT tag at current level */
147 { 0, &asn_PER_memb_enb_ID_longmacro_constr_4, memb_enb_ID_longmacro_constraint_1 },
148 0, 0, /* No default value */
152 static const asn_TYPE_tag2member_t asn_MAP_ENB_ID_Choice_tag2el_1[] = {
153 { (ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, 0 }, /* enb-ID-macro */
154 { (ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, 0 }, /* enb-ID-shortmacro */
155 { (ASN_TAG_CLASS_CONTEXT | (2 << 2)), 2, 0, 0 } /* enb-ID-longmacro */
157 asn_CHOICE_specifics_t asn_SPC_ENB_ID_Choice_specs_1 = {
158 sizeof(struct ENB_ID_Choice),
159 offsetof(struct ENB_ID_Choice, _asn_ctx),
160 offsetof(struct ENB_ID_Choice, present),
161 sizeof(((struct ENB_ID_Choice *)0)->present),
162 asn_MAP_ENB_ID_Choice_tag2el_1,
163 3, /* Count of tags in the map */
165 3 /* Extensions start */
167 asn_TYPE_descriptor_t asn_DEF_ENB_ID_Choice = {
171 0, /* No effective tags (pointer) */
172 0, /* No effective tags (count) */
173 0, /* No tags (pointer) */
174 0, /* No tags (count) */
175 { 0, &asn_PER_type_ENB_ID_Choice_constr_1, CHOICE_constraint },
176 asn_MBR_ENB_ID_Choice_1,
177 3, /* Elements count */
178 &asn_SPC_ENB_ID_Choice_specs_1 /* Additional specs */