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_GA-EllipsoidArc.h" |
| 8 | |
| 9 | static int |
| 10 | memb_innerRadius_constraint_1(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 int |
| 35 | memb_uncertaintyRadius_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, |
| 36 | asn_app_constraint_failed_f *ctfailcb, void *app_key) { |
| 37 | long value; |
| 38 | |
| 39 | if(!sptr) { |
| 40 | _ASN_CTFAIL(app_key, td, sptr, |
| 41 | "%s: value not given (%s:%d)", |
| 42 | td->name, __FILE__, __LINE__); |
| 43 | return -1; |
| 44 | } |
| 45 | |
| 46 | value = *(const long *)sptr; |
| 47 | |
| 48 | if((value >= 0l && value <= 127l)) { |
| 49 | /* Constraint check succeeded */ |
| 50 | return 0; |
| 51 | } else { |
| 52 | _ASN_CTFAIL(app_key, td, sptr, |
| 53 | "%s: constraint failed (%s:%d)", |
| 54 | td->name, __FILE__, __LINE__); |
| 55 | return -1; |
| 56 | } |
| 57 | } |
| 58 | |
| 59 | static int |
| 60 | memb_offsetAngle_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, |
| 61 | asn_app_constraint_failed_f *ctfailcb, void *app_key) { |
| 62 | long value; |
| 63 | |
| 64 | if(!sptr) { |
| 65 | _ASN_CTFAIL(app_key, td, sptr, |
| 66 | "%s: value not given (%s:%d)", |
| 67 | td->name, __FILE__, __LINE__); |
| 68 | return -1; |
| 69 | } |
| 70 | |
| 71 | value = *(const long *)sptr; |
| 72 | |
| 73 | if((value >= 0l && value <= 179l)) { |
| 74 | /* Constraint check succeeded */ |
| 75 | return 0; |
| 76 | } else { |
| 77 | _ASN_CTFAIL(app_key, td, sptr, |
| 78 | "%s: constraint failed (%s:%d)", |
| 79 | td->name, __FILE__, __LINE__); |
| 80 | return -1; |
| 81 | } |
| 82 | } |
| 83 | |
| 84 | static int |
| 85 | memb_includedAngle_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, |
| 86 | asn_app_constraint_failed_f *ctfailcb, void *app_key) { |
| 87 | long value; |
| 88 | |
| 89 | if(!sptr) { |
| 90 | _ASN_CTFAIL(app_key, td, sptr, |
| 91 | "%s: value not given (%s:%d)", |
| 92 | td->name, __FILE__, __LINE__); |
| 93 | return -1; |
| 94 | } |
| 95 | |
| 96 | value = *(const long *)sptr; |
| 97 | |
| 98 | if((value >= 0l && value <= 179l)) { |
| 99 | /* Constraint check succeeded */ |
| 100 | return 0; |
| 101 | } else { |
| 102 | _ASN_CTFAIL(app_key, td, sptr, |
| 103 | "%s: constraint failed (%s:%d)", |
| 104 | td->name, __FILE__, __LINE__); |
| 105 | return -1; |
| 106 | } |
| 107 | } |
| 108 | |
| 109 | static int |
| 110 | memb_confidence_constraint_1(asn_TYPE_descriptor_t *td, const void *sptr, |
| 111 | asn_app_constraint_failed_f *ctfailcb, void *app_key) { |
| 112 | long value; |
| 113 | |
| 114 | if(!sptr) { |
| 115 | _ASN_CTFAIL(app_key, td, sptr, |
| 116 | "%s: value not given (%s:%d)", |
| 117 | td->name, __FILE__, __LINE__); |
| 118 | return -1; |
| 119 | } |
| 120 | |
| 121 | value = *(const long *)sptr; |
| 122 | |
| 123 | if((value >= 0l && value <= 127l)) { |
| 124 | /* Constraint check succeeded */ |
| 125 | return 0; |
| 126 | } else { |
| 127 | _ASN_CTFAIL(app_key, td, sptr, |
| 128 | "%s: constraint failed (%s:%d)", |
| 129 | td->name, __FILE__, __LINE__); |
| 130 | return -1; |
| 131 | } |
| 132 | } |
| 133 | |
| 134 | static asn_per_constraints_t asn_PER_memb_innerRadius_constr_3 GCC_NOTUSED = { |
| 135 | { APC_CONSTRAINED, 16, 16, 0l, 65535l } /* (0..65535) */, |
| 136 | { APC_UNCONSTRAINED, -1, -1, 0, 0 }, |
| 137 | 0, 0 /* No PER value map */ |
| 138 | }; |
| 139 | static asn_per_constraints_t asn_PER_memb_uncertaintyRadius_constr_4 GCC_NOTUSED = { |
| 140 | { APC_CONSTRAINED, 7, 7, 0l, 127l } /* (0..127) */, |
| 141 | { APC_UNCONSTRAINED, -1, -1, 0, 0 }, |
| 142 | 0, 0 /* No PER value map */ |
| 143 | }; |
| 144 | static asn_per_constraints_t asn_PER_memb_offsetAngle_constr_5 GCC_NOTUSED = { |
| 145 | { APC_CONSTRAINED, 8, 8, 0l, 179l } /* (0..179) */, |
| 146 | { APC_UNCONSTRAINED, -1, -1, 0, 0 }, |
| 147 | 0, 0 /* No PER value map */ |
| 148 | }; |
| 149 | static asn_per_constraints_t asn_PER_memb_includedAngle_constr_6 GCC_NOTUSED = { |
| 150 | { APC_CONSTRAINED, 8, 8, 0l, 179l } /* (0..179) */, |
| 151 | { APC_UNCONSTRAINED, -1, -1, 0, 0 }, |
| 152 | 0, 0 /* No PER value map */ |
| 153 | }; |
| 154 | static asn_per_constraints_t asn_PER_memb_confidence_constr_7 GCC_NOTUSED = { |
| 155 | { APC_CONSTRAINED, 7, 7, 0l, 127l } /* (0..127) */, |
| 156 | { APC_UNCONSTRAINED, -1, -1, 0, 0 }, |
| 157 | 0, 0 /* No PER value map */ |
| 158 | }; |
| 159 | static asn_TYPE_member_t asn_MBR_RANAP_GA_EllipsoidArc_1[] = { |
| 160 | { ATF_NOFLAGS, 0, offsetof(struct RANAP_GA_EllipsoidArc, geographicalCoordinates), |
| 161 | (ASN_TAG_CLASS_CONTEXT | (0 << 2)), |
| 162 | -1, /* IMPLICIT tag at current level */ |
| 163 | &asn_DEF_RANAP_GeographicalCoordinates, |
| 164 | 0, /* Defer constraints checking to the member type */ |
| 165 | 0, /* No PER visible constraints */ |
| 166 | 0, |
| 167 | "geographicalCoordinates" |
| 168 | }, |
| 169 | { ATF_NOFLAGS, 0, offsetof(struct RANAP_GA_EllipsoidArc, innerRadius), |
| 170 | (ASN_TAG_CLASS_CONTEXT | (1 << 2)), |
| 171 | -1, /* IMPLICIT tag at current level */ |
| 172 | &asn_DEF_NativeInteger, |
| 173 | memb_innerRadius_constraint_1, |
| 174 | &asn_PER_memb_innerRadius_constr_3, |
| 175 | 0, |
| 176 | "innerRadius" |
| 177 | }, |
| 178 | { ATF_NOFLAGS, 0, offsetof(struct RANAP_GA_EllipsoidArc, uncertaintyRadius), |
| 179 | (ASN_TAG_CLASS_CONTEXT | (2 << 2)), |
| 180 | -1, /* IMPLICIT tag at current level */ |
| 181 | &asn_DEF_NativeInteger, |
| 182 | memb_uncertaintyRadius_constraint_1, |
| 183 | &asn_PER_memb_uncertaintyRadius_constr_4, |
| 184 | 0, |
| 185 | "uncertaintyRadius" |
| 186 | }, |
| 187 | { ATF_NOFLAGS, 0, offsetof(struct RANAP_GA_EllipsoidArc, offsetAngle), |
| 188 | (ASN_TAG_CLASS_CONTEXT | (3 << 2)), |
| 189 | -1, /* IMPLICIT tag at current level */ |
| 190 | &asn_DEF_NativeInteger, |
| 191 | memb_offsetAngle_constraint_1, |
| 192 | &asn_PER_memb_offsetAngle_constr_5, |
| 193 | 0, |
| 194 | "offsetAngle" |
| 195 | }, |
| 196 | { ATF_NOFLAGS, 0, offsetof(struct RANAP_GA_EllipsoidArc, includedAngle), |
| 197 | (ASN_TAG_CLASS_CONTEXT | (4 << 2)), |
| 198 | -1, /* IMPLICIT tag at current level */ |
| 199 | &asn_DEF_NativeInteger, |
| 200 | memb_includedAngle_constraint_1, |
| 201 | &asn_PER_memb_includedAngle_constr_6, |
| 202 | 0, |
| 203 | "includedAngle" |
| 204 | }, |
| 205 | { ATF_NOFLAGS, 0, offsetof(struct RANAP_GA_EllipsoidArc, confidence), |
| 206 | (ASN_TAG_CLASS_CONTEXT | (5 << 2)), |
| 207 | -1, /* IMPLICIT tag at current level */ |
| 208 | &asn_DEF_NativeInteger, |
| 209 | memb_confidence_constraint_1, |
| 210 | &asn_PER_memb_confidence_constr_7, |
| 211 | 0, |
| 212 | "confidence" |
| 213 | }, |
| 214 | { ATF_POINTER, 1, offsetof(struct RANAP_GA_EllipsoidArc, iE_Extensions), |
| 215 | (ASN_TAG_CLASS_CONTEXT | (6 << 2)), |
| 216 | -1, /* IMPLICIT tag at current level */ |
| 217 | &asn_DEF_RANAP_IE_Extensions, |
| 218 | 0, /* Defer constraints checking to the member type */ |
| 219 | 0, /* No PER visible constraints */ |
| 220 | 0, |
| 221 | "iE-Extensions" |
| 222 | }, |
| 223 | }; |
| 224 | static const int asn_MAP_RANAP_GA_EllipsoidArc_oms_1[] = { 6 }; |
| 225 | static const ber_tlv_tag_t asn_DEF_RANAP_GA_EllipsoidArc_tags_1[] = { |
| 226 | (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)) |
| 227 | }; |
| 228 | static const asn_TYPE_tag2member_t asn_MAP_RANAP_GA_EllipsoidArc_tag2el_1[] = { |
| 229 | { (ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, 0 }, /* geographicalCoordinates */ |
| 230 | { (ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, 0 }, /* innerRadius */ |
| 231 | { (ASN_TAG_CLASS_CONTEXT | (2 << 2)), 2, 0, 0 }, /* uncertaintyRadius */ |
| 232 | { (ASN_TAG_CLASS_CONTEXT | (3 << 2)), 3, 0, 0 }, /* offsetAngle */ |
| 233 | { (ASN_TAG_CLASS_CONTEXT | (4 << 2)), 4, 0, 0 }, /* includedAngle */ |
| 234 | { (ASN_TAG_CLASS_CONTEXT | (5 << 2)), 5, 0, 0 }, /* confidence */ |
| 235 | { (ASN_TAG_CLASS_CONTEXT | (6 << 2)), 6, 0, 0 } /* iE-Extensions */ |
| 236 | }; |
| 237 | static asn_SEQUENCE_specifics_t asn_SPC_RANAP_GA_EllipsoidArc_specs_1 = { |
| 238 | sizeof(struct RANAP_GA_EllipsoidArc), |
| 239 | offsetof(struct RANAP_GA_EllipsoidArc, _asn_ctx), |
| 240 | asn_MAP_RANAP_GA_EllipsoidArc_tag2el_1, |
| 241 | 7, /* Count of tags in the map */ |
| 242 | asn_MAP_RANAP_GA_EllipsoidArc_oms_1, /* Optional members */ |
| 243 | 1, 0, /* Root/Additions */ |
| 244 | 6, /* Start extensions */ |
| 245 | 8 /* Stop extensions */ |
| 246 | }; |
| 247 | asn_TYPE_descriptor_t asn_DEF_RANAP_GA_EllipsoidArc = { |
| 248 | "RANAP_GA-EllipsoidArc", |
| 249 | "RANAP_GA-EllipsoidArc", |
| 250 | SEQUENCE_free, |
| 251 | SEQUENCE_print, |
| 252 | SEQUENCE_constraint, |
| 253 | SEQUENCE_decode_ber, |
| 254 | SEQUENCE_encode_der, |
| 255 | SEQUENCE_decode_xer, |
| 256 | SEQUENCE_encode_xer, |
| 257 | SEQUENCE_decode_uper, |
| 258 | SEQUENCE_encode_uper, |
| 259 | SEQUENCE_decode_aper, |
| 260 | SEQUENCE_encode_aper, |
| 261 | 0, /* Use generic outmost tag fetcher */ |
| 262 | asn_DEF_RANAP_GA_EllipsoidArc_tags_1, |
| 263 | sizeof(asn_DEF_RANAP_GA_EllipsoidArc_tags_1) |
| 264 | /sizeof(asn_DEF_RANAP_GA_EllipsoidArc_tags_1[0]), /* 1 */ |
| 265 | asn_DEF_RANAP_GA_EllipsoidArc_tags_1, /* Same as above */ |
| 266 | sizeof(asn_DEF_RANAP_GA_EllipsoidArc_tags_1) |
| 267 | /sizeof(asn_DEF_RANAP_GA_EllipsoidArc_tags_1[0]), /* 1 */ |
| 268 | 0, /* No PER visible constraints */ |
| 269 | asn_MBR_RANAP_GA_EllipsoidArc_1, |
| 270 | 7, /* Elements count */ |
| 271 | &asn_SPC_RANAP_GA_EllipsoidArc_specs_1 /* Additional specs */ |
| 272 | }; |
| 273 | |