2 * Generated by asn1c-0.9.29 (http://lionet.info/asn1c)
3 * From ASN.1 module "X2AP-IEs"
4 * found in "Spec/e2ap-v031ex.asn"
5 * `asn1c -fcompound-names -fno-include-deps -findirect-choice -gen-PER`
8 #include "ProtectedResourceList-Item.h"
10 #include "ProtocolExtensionContainer.h"
12 memb_intraPRBProtectedResourceFootprint_constraint_1(const asn_TYPE_descriptor_t *td, const void *sptr,
13 asn_app_constraint_failed_f *ctfailcb, void *app_key) {
14 const BIT_STRING_t *st = (const BIT_STRING_t *)sptr;
18 ASN__CTFAIL(app_key, td, sptr,
19 "%s: value not given (%s:%d)",
20 td->name, __FILE__, __LINE__);
26 size = 8 * st->size - (st->bits_unused & 0x07);
32 /* Constraint check succeeded */
35 ASN__CTFAIL(app_key, td, sptr,
36 "%s: constraint failed (%s:%d)",
37 td->name, __FILE__, __LINE__);
43 memb_protectedFootprintFrequencyPattern_constraint_1(const asn_TYPE_descriptor_t *td, const void *sptr,
44 asn_app_constraint_failed_f *ctfailcb, void *app_key) {
45 const BIT_STRING_t *st = (const BIT_STRING_t *)sptr;
49 ASN__CTFAIL(app_key, td, sptr,
50 "%s: value not given (%s:%d)",
51 td->name, __FILE__, __LINE__);
57 size = 8 * st->size - (st->bits_unused & 0x07);
62 if((size >= 6 && size <= 110)) {
63 /* Constraint check succeeded */
66 ASN__CTFAIL(app_key, td, sptr,
67 "%s: constraint failed (%s:%d)",
68 td->name, __FILE__, __LINE__);
73 static asn_oer_constraints_t asn_OER_memb_intraPRBProtectedResourceFootprint_constr_3 CC_NOTUSED = {
75 -1 /* (SIZE(0..MAX)) */};
76 static asn_per_constraints_t asn_PER_memb_intraPRBProtectedResourceFootprint_constr_3 CC_NOTUSED = {
77 { APC_UNCONSTRAINED, -1, -1, 0, 0 },
78 { APC_CONSTRAINED | APC_EXTENSIBLE, 0, 0, 84, 84 } /* (SIZE(84..84,...)) */,
79 0, 0 /* No PER value map */
81 static asn_oer_constraints_t asn_OER_memb_protectedFootprintFrequencyPattern_constr_4 CC_NOTUSED = {
83 -1 /* (SIZE(0..MAX)) */};
84 static asn_per_constraints_t asn_PER_memb_protectedFootprintFrequencyPattern_constr_4 CC_NOTUSED = {
85 { APC_UNCONSTRAINED, -1, -1, 0, 0 },
86 { APC_CONSTRAINED | APC_EXTENSIBLE, 7, 7, 6, 110 } /* (SIZE(6..110,...)) */,
87 0, 0 /* No PER value map */
89 asn_TYPE_member_t asn_MBR_ProtectedResourceList_Item_1[] = {
90 { ATF_NOFLAGS, 0, offsetof(struct ProtectedResourceList_Item, resourceType),
91 (ASN_TAG_CLASS_CONTEXT | (0 << 2)),
92 -1, /* IMPLICIT tag at current level */
93 &asn_DEF_ResourceType,
96 0, 0, /* No default value */
99 { ATF_NOFLAGS, 0, offsetof(struct ProtectedResourceList_Item, intraPRBProtectedResourceFootprint),
100 (ASN_TAG_CLASS_CONTEXT | (1 << 2)),
101 -1, /* IMPLICIT tag at current level */
104 { &asn_OER_memb_intraPRBProtectedResourceFootprint_constr_3, &asn_PER_memb_intraPRBProtectedResourceFootprint_constr_3, memb_intraPRBProtectedResourceFootprint_constraint_1 },
105 0, 0, /* No default value */
106 "intraPRBProtectedResourceFootprint"
108 { ATF_NOFLAGS, 0, offsetof(struct ProtectedResourceList_Item, protectedFootprintFrequencyPattern),
109 (ASN_TAG_CLASS_CONTEXT | (2 << 2)),
110 -1, /* IMPLICIT tag at current level */
113 { &asn_OER_memb_protectedFootprintFrequencyPattern_constr_4, &asn_PER_memb_protectedFootprintFrequencyPattern_constr_4, memb_protectedFootprintFrequencyPattern_constraint_1 },
114 0, 0, /* No default value */
115 "protectedFootprintFrequencyPattern"
117 { ATF_NOFLAGS, 0, offsetof(struct ProtectedResourceList_Item, protectedFootprintTimePattern),
118 (ASN_TAG_CLASS_CONTEXT | (3 << 2)),
119 -1, /* IMPLICIT tag at current level */
120 &asn_DEF_ProtectedFootprintTimePattern,
123 0, 0, /* No default value */
124 "protectedFootprintTimePattern"
126 { ATF_POINTER, 1, offsetof(struct ProtectedResourceList_Item, iE_Extensions),
127 (ASN_TAG_CLASS_CONTEXT | (4 << 2)),
128 -1, /* IMPLICIT tag at current level */
129 &asn_DEF_ProtocolExtensionContainer_9566P182,
132 0, 0, /* No default value */
136 static const int asn_MAP_ProtectedResourceList_Item_oms_1[] = { 4 };
137 static const ber_tlv_tag_t asn_DEF_ProtectedResourceList_Item_tags_1[] = {
138 (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))
140 static const asn_TYPE_tag2member_t asn_MAP_ProtectedResourceList_Item_tag2el_1[] = {
141 { (ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, 0 }, /* resourceType */
142 { (ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, 0 }, /* intraPRBProtectedResourceFootprint */
143 { (ASN_TAG_CLASS_CONTEXT | (2 << 2)), 2, 0, 0 }, /* protectedFootprintFrequencyPattern */
144 { (ASN_TAG_CLASS_CONTEXT | (3 << 2)), 3, 0, 0 }, /* protectedFootprintTimePattern */
145 { (ASN_TAG_CLASS_CONTEXT | (4 << 2)), 4, 0, 0 } /* iE-Extensions */
147 asn_SEQUENCE_specifics_t asn_SPC_ProtectedResourceList_Item_specs_1 = {
148 sizeof(struct ProtectedResourceList_Item),
149 offsetof(struct ProtectedResourceList_Item, _asn_ctx),
150 asn_MAP_ProtectedResourceList_Item_tag2el_1,
151 5, /* Count of tags in the map */
152 asn_MAP_ProtectedResourceList_Item_oms_1, /* Optional members */
153 1, 0, /* Root/Additions */
154 5, /* First extension addition */
156 asn_TYPE_descriptor_t asn_DEF_ProtectedResourceList_Item = {
157 "ProtectedResourceList-Item",
158 "ProtectedResourceList-Item",
160 asn_DEF_ProtectedResourceList_Item_tags_1,
161 sizeof(asn_DEF_ProtectedResourceList_Item_tags_1)
162 /sizeof(asn_DEF_ProtectedResourceList_Item_tags_1[0]), /* 1 */
163 asn_DEF_ProtectedResourceList_Item_tags_1, /* Same as above */
164 sizeof(asn_DEF_ProtectedResourceList_Item_tags_1)
165 /sizeof(asn_DEF_ProtectedResourceList_Item_tags_1[0]), /* 1 */
166 { 0, 0, SEQUENCE_constraint },
167 asn_MBR_ProtectedResourceList_Item_1,
168 5, /* Elements count */
169 &asn_SPC_ProtectedResourceList_Item_specs_1 /* Additional specs */