Harald Welte | ee09189 | 2015-09-10 10:22:03 +0200 | [diff] [blame] | 1 | /* |
| 2 | * Generated by asn1c-0.9.28 (http://lionet.info/asn1c) |
| 3 | * From ASN.1 module "RANAP-IEs" |
| 4 | * found in "../../asn1/ranap/RANAP-IEs.asn" |
| 5 | */ |
| 6 | |
| 7 | #include "RANAP_EUTRANFrequencies.h" |
| 8 | |
| 9 | static int |
| 10 | memb_earfcn_constraint_2(asn_TYPE_descriptor_t *td, const void *sptr, |
| 11 | asn_app_constraint_failed_f *ctfailcb, void *app_key) { |
| 12 | long value; |
| 13 | |
| 14 | if(!sptr) { |
| 15 | _ASN_CTFAIL(app_key, td, sptr, |
| 16 | "%s: value not given (%s:%d)", |
| 17 | td->name, __FILE__, __LINE__); |
| 18 | return -1; |
| 19 | } |
| 20 | |
| 21 | value = *(const long *)sptr; |
| 22 | |
| 23 | if((value >= 0l && value <= 65535l)) { |
| 24 | /* Constraint check succeeded */ |
| 25 | return 0; |
| 26 | } else { |
| 27 | _ASN_CTFAIL(app_key, td, sptr, |
| 28 | "%s: constraint failed (%s:%d)", |
| 29 | td->name, __FILE__, __LINE__); |
| 30 | return -1; |
| 31 | } |
| 32 | } |
| 33 | |
| 34 | static asn_per_constraints_t asn_PER_memb_earfcn_constr_3 GCC_NOTUSED = { |
| 35 | { APC_CONSTRAINED, 16, 16, 0l, 65535l } /* (0..65535) */, |
| 36 | { APC_UNCONSTRAINED, -1, -1, 0, 0 }, |
| 37 | 0, 0 /* No PER value map */ |
| 38 | }; |
| 39 | static asn_per_constraints_t asn_PER_type_RANAP_EUTRANFrequencies_constr_1 GCC_NOTUSED = { |
| 40 | { APC_UNCONSTRAINED, -1, -1, 0, 0 }, |
| 41 | { APC_CONSTRAINED, 3, 3, 1l, 8l } /* (SIZE(1..8)) */, |
| 42 | 0, 0 /* No PER value map */ |
| 43 | }; |
| 44 | static asn_TYPE_member_t asn_MBR_Member_2[] = { |
| 45 | { ATF_NOFLAGS, 0, offsetof(struct Member, earfcn), |
| 46 | (ASN_TAG_CLASS_CONTEXT | (0 << 2)), |
| 47 | -1, /* IMPLICIT tag at current level */ |
| 48 | &asn_DEF_NativeInteger, |
| 49 | memb_earfcn_constraint_2, |
| 50 | &asn_PER_memb_earfcn_constr_3, |
| 51 | 0, |
| 52 | "earfcn" |
| 53 | }, |
| 54 | { ATF_POINTER, 2, offsetof(struct Member, measBand), |
| 55 | (ASN_TAG_CLASS_CONTEXT | (1 << 2)), |
| 56 | -1, /* IMPLICIT tag at current level */ |
| 57 | &asn_DEF_RANAP_MeasBand, |
| 58 | 0, /* Defer constraints checking to the member type */ |
| 59 | 0, /* No PER visible constraints */ |
| 60 | 0, |
| 61 | "measBand" |
| 62 | }, |
| 63 | { ATF_POINTER, 1, offsetof(struct Member, iE_Extensions), |
| 64 | (ASN_TAG_CLASS_CONTEXT | (2 << 2)), |
| 65 | -1, /* IMPLICIT tag at current level */ |
| 66 | &asn_DEF_RANAP_IE_Extensions, |
| 67 | 0, /* Defer constraints checking to the member type */ |
| 68 | 0, /* No PER visible constraints */ |
| 69 | 0, |
| 70 | "iE-Extensions" |
| 71 | }, |
| 72 | }; |
| 73 | static const int asn_MAP_Member_oms_2[] = { 1, 2 }; |
| 74 | static const ber_tlv_tag_t asn_DEF_Member_tags_2[] = { |
| 75 | (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)) |
| 76 | }; |
| 77 | static const asn_TYPE_tag2member_t asn_MAP_Member_tag2el_2[] = { |
| 78 | { (ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, 0 }, /* earfcn */ |
| 79 | { (ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, 0 }, /* measBand */ |
| 80 | { (ASN_TAG_CLASS_CONTEXT | (2 << 2)), 2, 0, 0 } /* iE-Extensions */ |
| 81 | }; |
| 82 | static asn_SEQUENCE_specifics_t asn_SPC_Member_specs_2 = { |
| 83 | sizeof(struct Member), |
| 84 | offsetof(struct Member, _asn_ctx), |
| 85 | asn_MAP_Member_tag2el_2, |
| 86 | 3, /* Count of tags in the map */ |
| 87 | asn_MAP_Member_oms_2, /* Optional members */ |
| 88 | 2, 0, /* Root/Additions */ |
| 89 | -1, /* Start extensions */ |
| 90 | -1 /* Stop extensions */ |
| 91 | }; |
| 92 | static /* Use -fall-defs-global to expose */ |
| 93 | asn_TYPE_descriptor_t asn_DEF_Member_2 = { |
| 94 | "SEQUENCE", |
| 95 | "SEQUENCE", |
| 96 | SEQUENCE_free, |
| 97 | SEQUENCE_print, |
| 98 | SEQUENCE_constraint, |
| 99 | SEQUENCE_decode_ber, |
| 100 | SEQUENCE_encode_der, |
| 101 | SEQUENCE_decode_xer, |
| 102 | SEQUENCE_encode_xer, |
| 103 | SEQUENCE_decode_uper, |
| 104 | SEQUENCE_encode_uper, |
| 105 | SEQUENCE_decode_aper, |
| 106 | SEQUENCE_encode_aper, |
| 107 | 0, /* Use generic outmost tag fetcher */ |
| 108 | asn_DEF_Member_tags_2, |
| 109 | sizeof(asn_DEF_Member_tags_2) |
| 110 | /sizeof(asn_DEF_Member_tags_2[0]), /* 1 */ |
| 111 | asn_DEF_Member_tags_2, /* Same as above */ |
| 112 | sizeof(asn_DEF_Member_tags_2) |
| 113 | /sizeof(asn_DEF_Member_tags_2[0]), /* 1 */ |
| 114 | 0, /* No PER visible constraints */ |
| 115 | asn_MBR_Member_2, |
| 116 | 3, /* Elements count */ |
| 117 | &asn_SPC_Member_specs_2 /* Additional specs */ |
| 118 | }; |
| 119 | |
| 120 | static asn_TYPE_member_t asn_MBR_RANAP_EUTRANFrequencies_1[] = { |
| 121 | { ATF_POINTER, 0, 0, |
| 122 | (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)), |
| 123 | 0, |
| 124 | &asn_DEF_Member_2, |
| 125 | 0, /* Defer constraints checking to the member type */ |
| 126 | 0, /* No PER visible constraints */ |
| 127 | 0, |
| 128 | "" |
| 129 | }, |
| 130 | }; |
| 131 | static const ber_tlv_tag_t asn_DEF_RANAP_EUTRANFrequencies_tags_1[] = { |
| 132 | (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)) |
| 133 | }; |
| 134 | static asn_SET_OF_specifics_t asn_SPC_RANAP_EUTRANFrequencies_specs_1 = { |
| 135 | sizeof(struct RANAP_EUTRANFrequencies), |
| 136 | offsetof(struct RANAP_EUTRANFrequencies, _asn_ctx), |
| 137 | 0, /* XER encoding is XMLDelimitedItemList */ |
| 138 | }; |
| 139 | asn_TYPE_descriptor_t asn_DEF_RANAP_EUTRANFrequencies = { |
| 140 | "RANAP_EUTRANFrequencies", |
| 141 | "RANAP_EUTRANFrequencies", |
| 142 | SEQUENCE_OF_free, |
| 143 | SEQUENCE_OF_print, |
| 144 | SEQUENCE_OF_constraint, |
| 145 | SEQUENCE_OF_decode_ber, |
| 146 | SEQUENCE_OF_encode_der, |
| 147 | SEQUENCE_OF_decode_xer, |
| 148 | SEQUENCE_OF_encode_xer, |
| 149 | SEQUENCE_OF_decode_uper, |
| 150 | SEQUENCE_OF_encode_uper, |
| 151 | SEQUENCE_OF_decode_aper, |
| 152 | SEQUENCE_OF_encode_aper, |
| 153 | 0, /* Use generic outmost tag fetcher */ |
| 154 | asn_DEF_RANAP_EUTRANFrequencies_tags_1, |
| 155 | sizeof(asn_DEF_RANAP_EUTRANFrequencies_tags_1) |
| 156 | /sizeof(asn_DEF_RANAP_EUTRANFrequencies_tags_1[0]), /* 1 */ |
| 157 | asn_DEF_RANAP_EUTRANFrequencies_tags_1, /* Same as above */ |
| 158 | sizeof(asn_DEF_RANAP_EUTRANFrequencies_tags_1) |
| 159 | /sizeof(asn_DEF_RANAP_EUTRANFrequencies_tags_1[0]), /* 1 */ |
| 160 | &asn_PER_type_RANAP_EUTRANFrequencies_constr_1, |
| 161 | asn_MBR_RANAP_EUTRANFrequencies_1, |
| 162 | 1, /* Single element */ |
| 163 | &asn_SPC_RANAP_EUTRANFrequencies_specs_1 /* Additional specs */ |
| 164 | }; |
| 165 | |