| 1 |
|
| 2 |
/*** <<< INCLUDES [Sequence] >>> ***/ |
| 3 |
|
| 4 |
#include <INTEGER.h> |
| 5 |
#include <constr_SEQUENCE.h> |
| 6 |
|
| 7 |
/*** <<< TYPE-DECLS [Sequence] >>> ***/ |
| 8 |
|
| 9 |
typedef struct Sequence { |
| 10 |
INTEGER_t ainl; |
| 11 |
INTEGER_t *aptr; |
| 12 |
|
| 13 |
/* Context for parsing across buffer boundaries */ |
| 14 |
asn_struct_ctx_t _asn_ctx; |
| 15 |
} Sequence_t; |
| 16 |
|
| 17 |
/*** <<< FUNC-DECLS [Sequence] >>> ***/ |
| 18 |
|
| 19 |
extern asn_TYPE_descriptor_t asn_DEF_Sequence; |
| 20 |
|
| 21 |
/*** <<< STAT-DEFS [Sequence] >>> ***/ |
| 22 |
|
| 23 |
static asn_TYPE_member_t asn_MBR_Sequence_1[] = { |
| 24 |
{ ATF_NOFLAGS, 0, offsetof(struct Sequence, ainl), |
| 25 |
.tag = (ASN_TAG_CLASS_CONTEXT | (0 << 2)), |
| 26 |
.tag_mode = -1, /* IMPLICIT tag at current level */ |
| 27 |
.type = &asn_DEF_INTEGER, |
| 28 |
.memb_constraints = 0, /* Defer constraints checking to the member type */ |
| 29 |
.per_constraints = 0, /* PER is not compiled, use -gen-PER */ |
| 30 |
.default_value = 0, |
| 31 |
.name = "ainl" |
| 32 |
}, |
| 33 |
{ ATF_POINTER, 0, offsetof(struct Sequence, aptr), |
| 34 |
.tag = (ASN_TAG_CLASS_CONTEXT | (1 << 2)), |
| 35 |
.tag_mode = -1, /* IMPLICIT tag at current level */ |
| 36 |
.type = &asn_DEF_INTEGER, |
| 37 |
.memb_constraints = 0, /* Defer constraints checking to the member type */ |
| 38 |
.per_constraints = 0, /* PER is not compiled, use -gen-PER */ |
| 39 |
.default_value = 0, |
| 40 |
.name = "aptr" |
| 41 |
}, |
| 42 |
}; |
| 43 |
static const ber_tlv_tag_t asn_DEF_Sequence_tags_1[] = { |
| 44 |
(ASN_TAG_CLASS_UNIVERSAL | (16 << 2)) |
| 45 |
}; |
| 46 |
static const asn_TYPE_tag2member_t asn_MAP_Sequence_tag2el_1[] = { |
| 47 |
{ (ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, 0 }, /* ainl */ |
| 48 |
{ (ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, 0 } /* aptr */ |
| 49 |
}; |
| 50 |
static asn_SEQUENCE_specifics_t asn_SPC_Sequence_specs_1 = { |
| 51 |
sizeof(struct Sequence), |
| 52 |
offsetof(struct Sequence, _asn_ctx), |
| 53 |
asn_MAP_Sequence_tag2el_1, |
| 54 |
2, /* Count of tags in the map */ |
| 55 |
0, 0, 0, /* Optional elements (not needed) */ |
| 56 |
-1, /* Start extensions */ |
| 57 |
-1 /* Stop extensions */ |
| 58 |
}; |
| 59 |
asn_TYPE_descriptor_t asn_DEF_Sequence = { |
| 60 |
"Sequence", |
| 61 |
"Sequence", |
| 62 |
SEQUENCE_free, |
| 63 |
SEQUENCE_print, |
| 64 |
SEQUENCE_constraint, |
| 65 |
SEQUENCE_decode_ber, |
| 66 |
SEQUENCE_encode_der, |
| 67 |
SEQUENCE_decode_xer, |
| 68 |
SEQUENCE_encode_xer, |
| 69 |
0, 0, /* No PER support, use "-gen-PER" to enable */ |
| 70 |
0, /* Use generic outmost tag fetcher */ |
| 71 |
asn_DEF_Sequence_tags_1, |
| 72 |
sizeof(asn_DEF_Sequence_tags_1) |
| 73 |
/sizeof(asn_DEF_Sequence_tags_1[0]), /* 1 */ |
| 74 |
asn_DEF_Sequence_tags_1, /* Same as above */ |
| 75 |
sizeof(asn_DEF_Sequence_tags_1) |
| 76 |
/sizeof(asn_DEF_Sequence_tags_1[0]), /* 1 */ |
| 77 |
0, /* No PER visible constraints */ |
| 78 |
asn_MBR_Sequence_1, |
| 79 |
2, /* Elements count */ |
| 80 |
&asn_SPC_Sequence_specs_1 /* Additional specs */ |
| 81 |
}; |
| 82 |
|
| 83 |
|
| 84 |
/*** <<< INCLUDES [Set] >>> ***/ |
| 85 |
|
| 86 |
#include "Sequence.h" |
| 87 |
#include <constr_SET.h> |
| 88 |
|
| 89 |
/*** <<< DEPS [Set] >>> ***/ |
| 90 |
|
| 91 |
|
| 92 |
/* |
| 93 |
* Method of determining the components presence |
| 94 |
*/ |
| 95 |
typedef enum Set_PR { |
| 96 |
Set_PR_ainl, /* Member ainl is present */ |
| 97 |
Set_PR_aptr, /* Member aptr is present */ |
| 98 |
} Set_PR; |
| 99 |
|
| 100 |
/*** <<< FWD-DECLS [Set] >>> ***/ |
| 101 |
|
| 102 |
struct Sequence; |
| 103 |
|
| 104 |
/*** <<< TYPE-DECLS [Set] >>> ***/ |
| 105 |
|
| 106 |
typedef struct Set { |
| 107 |
Sequence_t ainl; |
| 108 |
struct Sequence *aptr; |
| 109 |
|
| 110 |
/* Presence bitmask: ASN_SET_ISPRESENT(pSet, Set_PR_x) */ |
| 111 |
unsigned int _presence_map |
| 112 |
[((2+(8*sizeof(unsigned int))-1)/(8*sizeof(unsigned int)))]; |
| 113 |
|
| 114 |
/* Context for parsing across buffer boundaries */ |
| 115 |
asn_struct_ctx_t _asn_ctx; |
| 116 |
} Set_t; |
| 117 |
|
| 118 |
/*** <<< FUNC-DECLS [Set] >>> ***/ |
| 119 |
|
| 120 |
extern asn_TYPE_descriptor_t asn_DEF_Set; |
| 121 |
|
| 122 |
/*** <<< POST-INCLUDE [Set] >>> ***/ |
| 123 |
|
| 124 |
#include "Sequence.h" |
| 125 |
|
| 126 |
/*** <<< STAT-DEFS [Set] >>> ***/ |
| 127 |
|
| 128 |
static asn_TYPE_member_t asn_MBR_Set_1[] = { |
| 129 |
{ ATF_NOFLAGS, 0, offsetof(struct Set, ainl), |
| 130 |
.tag = (ASN_TAG_CLASS_CONTEXT | (0 << 2)), |
| 131 |
.tag_mode = -1, /* IMPLICIT tag at current level */ |
| 132 |
.type = &asn_DEF_Sequence, |
| 133 |
.memb_constraints = 0, /* Defer constraints checking to the member type */ |
| 134 |
.per_constraints = 0, /* PER is not compiled, use -gen-PER */ |
| 135 |
.default_value = 0, |
| 136 |
.name = "ainl" |
| 137 |
}, |
| 138 |
{ ATF_POINTER, 0, offsetof(struct Set, aptr), |
| 139 |
.tag = (ASN_TAG_CLASS_CONTEXT | (1 << 2)), |
| 140 |
.tag_mode = -1, /* IMPLICIT tag at current level */ |
| 141 |
.type = &asn_DEF_Sequence, |
| 142 |
.memb_constraints = 0, /* Defer constraints checking to the member type */ |
| 143 |
.per_constraints = 0, /* PER is not compiled, use -gen-PER */ |
| 144 |
.default_value = 0, |
| 145 |
.name = "aptr" |
| 146 |
}, |
| 147 |
}; |
| 148 |
static const ber_tlv_tag_t asn_DEF_Set_tags_1[] = { |
| 149 |
(ASN_TAG_CLASS_UNIVERSAL | (17 << 2)) |
| 150 |
}; |
| 151 |
static const asn_TYPE_tag2member_t asn_MAP_Set_tag2el_1[] = { |
| 152 |
{ (ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, 0 }, /* ainl */ |
| 153 |
{ (ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, 0 } /* aptr */ |
| 154 |
}; |
| 155 |
static const uint8_t asn_MAP_Set_mmap_1[(2 + (8 * sizeof(unsigned int)) - 1) / 8] = { |
| 156 |
(1 << 7) | (1 << 6) |
| 157 |
}; |
| 158 |
static asn_SET_specifics_t asn_SPC_Set_specs_1 = { |
| 159 |
sizeof(struct Set), |
| 160 |
offsetof(struct Set, _asn_ctx), |
| 161 |
offsetof(struct Set, _presence_map), |
| 162 |
asn_MAP_Set_tag2el_1, |
| 163 |
2, /* Count of tags in the map */ |
| 164 |
asn_MAP_Set_tag2el_1, /* Same as above */ |
| 165 |
2, /* Count of tags in the CXER map */ |
| 166 |
0, /* Whether extensible */ |
| 167 |
(unsigned int *)asn_MAP_Set_mmap_1 /* Mandatory elements map */ |
| 168 |
}; |
| 169 |
asn_TYPE_descriptor_t asn_DEF_Set = { |
| 170 |
"Set", |
| 171 |
"Set", |
| 172 |
SET_free, |
| 173 |
SET_print, |
| 174 |
SET_constraint, |
| 175 |
SET_decode_ber, |
| 176 |
SET_encode_der, |
| 177 |
SET_decode_xer, |
| 178 |
SET_encode_xer, |
| 179 |
0, 0, /* No PER support, use "-gen-PER" to enable */ |
| 180 |
0, /* Use generic outmost tag fetcher */ |
| 181 |
asn_DEF_Set_tags_1, |
| 182 |
sizeof(asn_DEF_Set_tags_1) |
| 183 |
/sizeof(asn_DEF_Set_tags_1[0]), /* 1 */ |
| 184 |
asn_DEF_Set_tags_1, /* Same as above */ |
| 185 |
sizeof(asn_DEF_Set_tags_1) |
| 186 |
/sizeof(asn_DEF_Set_tags_1[0]), /* 1 */ |
| 187 |
0, /* No PER visible constraints */ |
| 188 |
asn_MBR_Set_1, |
| 189 |
2, /* Elements count */ |
| 190 |
&asn_SPC_Set_specs_1 /* Additional specs */ |
| 191 |
}; |
| 192 |
|
| 193 |
|
| 194 |
/*** <<< INCLUDES [Choice] >>> ***/ |
| 195 |
|
| 196 |
#include "Sequence.h" |
| 197 |
#include <INTEGER.h> |
| 198 |
#include <asn_SET_OF.h> |
| 199 |
#include <constr_SET_OF.h> |
| 200 |
#include <constr_CHOICE.h> |
| 201 |
|
| 202 |
/*** <<< DEPS [Choice] >>> ***/ |
| 203 |
|
| 204 |
typedef enum Choice_PR { |
| 205 |
Choice_PR_NOTHING, /* No components present */ |
| 206 |
Choice_PR_setof, |
| 207 |
Choice_PR_aptr, |
| 208 |
Choice_PR_ainl |
| 209 |
} Choice_PR; |
| 210 |
|
| 211 |
/*** <<< FWD-DECLS [Choice] >>> ***/ |
| 212 |
|
| 213 |
struct Sequence; |
| 214 |
|
| 215 |
/*** <<< TYPE-DECLS [Choice] >>> ***/ |
| 216 |
|
| 217 |
typedef struct Choice { |
| 218 |
Choice_PR present; |
| 219 |
union Choice_u { |
| 220 |
struct setof { |
| 221 |
A_SET_OF(INTEGER_t) list; |
| 222 |
|
| 223 |
/* Context for parsing across buffer boundaries */ |
| 224 |
asn_struct_ctx_t _asn_ctx; |
| 225 |
} *setof; |
| 226 |
struct Sequence *aptr; |
| 227 |
Sequence_t ainl; |
| 228 |
} choice; |
| 229 |
|
| 230 |
/* Context for parsing across buffer boundaries */ |
| 231 |
asn_struct_ctx_t _asn_ctx; |
| 232 |
} Choice_t; |
| 233 |
|
| 234 |
/*** <<< FUNC-DECLS [Choice] >>> ***/ |
| 235 |
|
| 236 |
extern asn_TYPE_descriptor_t asn_DEF_Choice; |
| 237 |
|
| 238 |
/*** <<< POST-INCLUDE [Choice] >>> ***/ |
| 239 |
|
| 240 |
#include "Sequence.h" |
| 241 |
|
| 242 |
/*** <<< STAT-DEFS [Choice] >>> ***/ |
| 243 |
|
| 244 |
static asn_TYPE_member_t asn_MBR_setof_2[] = { |
| 245 |
{ ATF_POINTER, 0, 0, |
| 246 |
.tag = (ASN_TAG_CLASS_UNIVERSAL | (2 << 2)), |
| 247 |
.tag_mode = 0, |
| 248 |
.type = &asn_DEF_INTEGER, |
| 249 |
.memb_constraints = 0, /* Defer constraints checking to the member type */ |
| 250 |
.per_constraints = 0, /* PER is not compiled, use -gen-PER */ |
| 251 |
.default_value = 0, |
| 252 |
.name = "" |
| 253 |
}, |
| 254 |
}; |
| 255 |
static const ber_tlv_tag_t asn_DEF_setof_tags_2[] = { |
| 256 |
(ASN_TAG_CLASS_CONTEXT | (0 << 2)), |
| 257 |
(ASN_TAG_CLASS_UNIVERSAL | (17 << 2)) |
| 258 |
}; |
| 259 |
static asn_SET_OF_specifics_t asn_SPC_setof_specs_2 = { |
| 260 |
sizeof(struct setof), |
| 261 |
offsetof(struct setof, _asn_ctx), |
| 262 |
0, /* XER encoding is XMLDelimitedItemList */ |
| 263 |
}; |
| 264 |
static /* Use -fall-defs-global to expose */ |
| 265 |
asn_TYPE_descriptor_t asn_DEF_setof_2 = { |
| 266 |
"setof", |
| 267 |
"setof", |
| 268 |
SET_OF_free, |
| 269 |
SET_OF_print, |
| 270 |
SET_OF_constraint, |
| 271 |
SET_OF_decode_ber, |
| 272 |
SET_OF_encode_der, |
| 273 |
SET_OF_decode_xer, |
| 274 |
SET_OF_encode_xer, |
| 275 |
0, 0, /* No PER support, use "-gen-PER" to enable */ |
| 276 |
0, /* Use generic outmost tag fetcher */ |
| 277 |
asn_DEF_setof_tags_2, |
| 278 |
sizeof(asn_DEF_setof_tags_2) |
| 279 |
/sizeof(asn_DEF_setof_tags_2[0]) - 1, /* 1 */ |
| 280 |
asn_DEF_setof_tags_2, /* Same as above */ |
| 281 |
sizeof(asn_DEF_setof_tags_2) |
| 282 |
/sizeof(asn_DEF_setof_tags_2[0]), /* 2 */ |
| 283 |
0, /* No PER visible constraints */ |
| 284 |
asn_MBR_setof_2, |
| 285 |
1, /* Single element */ |
| 286 |
&asn_SPC_setof_specs_2 /* Additional specs */ |
| 287 |
}; |
| 288 |
|
| 289 |
static asn_TYPE_member_t asn_MBR_Choice_1[] = { |
| 290 |
{ ATF_POINTER, 0, offsetof(struct Choice, choice.setof), |
| 291 |
.tag = (ASN_TAG_CLASS_CONTEXT | (0 << 2)), |
| 292 |
.tag_mode = 0, |
| 293 |
.type = &asn_DEF_setof_2, |
| 294 |
.memb_constraints = 0, /* Defer constraints checking to the member type */ |
| 295 |
.per_constraints = 0, /* PER is not compiled, use -gen-PER */ |
| 296 |
.default_value = 0, |
| 297 |
.name = "setof" |
| 298 |
}, |
| 299 |
{ ATF_POINTER, 0, offsetof(struct Choice, choice.aptr), |
| 300 |
.tag = (ASN_TAG_CLASS_CONTEXT | (1 << 2)), |
| 301 |
.tag_mode = -1, /* IMPLICIT tag at current level */ |
| 302 |
.type = &asn_DEF_Sequence, |
| 303 |
.memb_constraints = 0, /* Defer constraints checking to the member type */ |
| 304 |
.per_constraints = 0, /* PER is not compiled, use -gen-PER */ |
| 305 |
.default_value = 0, |
| 306 |
.name = "aptr" |
| 307 |
}, |
| 308 |
{ ATF_NOFLAGS, 0, offsetof(struct Choice, choice.ainl), |
| 309 |
.tag = (ASN_TAG_CLASS_CONTEXT | (2 << 2)), |
| 310 |
.tag_mode = -1, /* IMPLICIT tag at current level */ |
| 311 |
.type = &asn_DEF_Sequence, |
| 312 |
.memb_constraints = 0, /* Defer constraints checking to the member type */ |
| 313 |
.per_constraints = 0, /* PER is not compiled, use -gen-PER */ |
| 314 |
.default_value = 0, |
| 315 |
.name = "ainl" |
| 316 |
}, |
| 317 |
}; |
| 318 |
static const asn_TYPE_tag2member_t asn_MAP_Choice_tag2el_1[] = { |
| 319 |
{ (ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, 0 }, /* setof */ |
| 320 |
{ (ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, 0 }, /* aptr */ |
| 321 |
{ (ASN_TAG_CLASS_CONTEXT | (2 << 2)), 2, 0, 0 } /* ainl */ |
| 322 |
}; |
| 323 |
static asn_CHOICE_specifics_t asn_SPC_Choice_specs_1 = { |
| 324 |
sizeof(struct Choice), |
| 325 |
offsetof(struct Choice, _asn_ctx), |
| 326 |
offsetof(struct Choice, present), |
| 327 |
sizeof(((struct Choice *)0)->present), |
| 328 |
asn_MAP_Choice_tag2el_1, |
| 329 |
3, /* Count of tags in the map */ |
| 330 |
.canonical_order = 0, |
| 331 |
.ext_start = -1 /* Extensions start */ |
| 332 |
}; |
| 333 |
asn_TYPE_descriptor_t asn_DEF_Choice = { |
| 334 |
"Choice", |
| 335 |
"Choice", |
| 336 |
CHOICE_free, |
| 337 |
CHOICE_print, |
| 338 |
CHOICE_constraint, |
| 339 |
CHOICE_decode_ber, |
| 340 |
CHOICE_encode_der, |
| 341 |
CHOICE_decode_xer, |
| 342 |
CHOICE_encode_xer, |
| 343 |
0, 0, /* No PER support, use "-gen-PER" to enable */ |
| 344 |
CHOICE_outmost_tag, |
| 345 |
0, /* No effective tags (pointer) */ |
| 346 |
0, /* No effective tags (count) */ |
| 347 |
0, /* No tags (pointer) */ |
| 348 |
0, /* No tags (count) */ |
| 349 |
0, /* No PER visible constraints */ |
| 350 |
asn_MBR_Choice_1, |
| 351 |
3, /* Elements count */ |
| 352 |
&asn_SPC_Choice_specs_1 /* Additional specs */ |
| 353 |
}; |
| 354 |
|