blob: 5c8c27e9d8c199c45bf78878a611aa0e1d7bf122 [file] [log] [blame]
Lev Walkin4696c742005-08-22 12:23:54 +00001
2/*** <<< INCLUDES [Sequence] >>> ***/
3
4#include <INTEGER.h>
5#include <constr_SEQUENCE.h>
6
7/*** <<< TYPE-DECLS [Sequence] >>> ***/
8
9typedef 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
19extern asn_TYPE_descriptor_t asn_DEF_Sequence;
Bi-Ruei, Chiu1fa31c92016-05-16 13:50:09 +080020extern asn_SEQUENCE_specifics_t asn_SPC_Sequence_specs_1;
21extern asn_TYPE_member_t asn_MBR_Sequence_1[2];
Lev Walkin4696c742005-08-22 12:23:54 +000022
23/*** <<< STAT-DEFS [Sequence] >>> ***/
24
Bi-Ruei, Chiu1fa31c92016-05-16 13:50:09 +080025asn_TYPE_member_t asn_MBR_Sequence_1[] = {
Lev Walkin4696c742005-08-22 12:23:54 +000026 { ATF_NOFLAGS, 0, offsetof(struct Sequence, ainl),
27 .tag = (ASN_TAG_CLASS_CONTEXT | (0 << 2)),
28 .tag_mode = -1, /* IMPLICIT tag at current level */
Lev Walkinae7bf3f2005-08-29 10:31:14 +000029 .type = &asn_DEF_INTEGER,
Lev Walkin67a30122017-08-10 05:48:54 -070030 .type_selector = 0,
Lev Walkin4696c742005-08-22 12:23:54 +000031 .memb_constraints = 0, /* Defer constraints checking to the member type */
Lev Walkinb33425f2017-07-14 14:59:52 +040032 .oer_constraints = 0, /* OER is not compiled, use -gen-OER */
Lev Walkin59b176e2005-11-26 11:25:14 +000033 .per_constraints = 0, /* PER is not compiled, use -gen-PER */
34 .default_value = 0,
Lev Walkin4696c742005-08-22 12:23:54 +000035 .name = "ainl"
36 },
37 { ATF_POINTER, 0, offsetof(struct Sequence, aptr),
38 .tag = (ASN_TAG_CLASS_CONTEXT | (1 << 2)),
39 .tag_mode = -1, /* IMPLICIT tag at current level */
Lev Walkinae7bf3f2005-08-29 10:31:14 +000040 .type = &asn_DEF_INTEGER,
Lev Walkin67a30122017-08-10 05:48:54 -070041 .type_selector = 0,
Lev Walkin4696c742005-08-22 12:23:54 +000042 .memb_constraints = 0, /* Defer constraints checking to the member type */
Lev Walkinb33425f2017-07-14 14:59:52 +040043 .oer_constraints = 0, /* OER is not compiled, use -gen-OER */
Lev Walkin59b176e2005-11-26 11:25:14 +000044 .per_constraints = 0, /* PER is not compiled, use -gen-PER */
45 .default_value = 0,
Lev Walkin4696c742005-08-22 12:23:54 +000046 .name = "aptr"
47 },
48};
Lev Walkina7591b52014-10-12 18:37:35 -070049static const ber_tlv_tag_t asn_DEF_Sequence_tags_1[] = {
Lev Walkin4696c742005-08-22 12:23:54 +000050 (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))
51};
Lev Walkina7591b52014-10-12 18:37:35 -070052static const asn_TYPE_tag2member_t asn_MAP_Sequence_tag2el_1[] = {
Lev Walkin4062b012013-10-11 14:29:38 -070053 { (ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, 0 }, /* ainl */
54 { (ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, 0 } /* aptr */
Lev Walkin4696c742005-08-22 12:23:54 +000055};
Bi-Ruei, Chiu1fa31c92016-05-16 13:50:09 +080056asn_SEQUENCE_specifics_t asn_SPC_Sequence_specs_1 = {
Lev Walkin4696c742005-08-22 12:23:54 +000057 sizeof(struct Sequence),
58 offsetof(struct Sequence, _asn_ctx),
Lev Walkine3917082017-08-23 10:29:38 -070059 .tag2el = asn_MAP_Sequence_tag2el_1,
60 .tag2el_count = 2, /* Count of tags in the map */
Lev Walkin59b176e2005-11-26 11:25:14 +000061 0, 0, 0, /* Optional elements (not needed) */
Lev Walkin4696c742005-08-22 12:23:54 +000062 -1, /* Start extensions */
63 -1 /* Stop extensions */
64};
65asn_TYPE_descriptor_t asn_DEF_Sequence = {
66 "Sequence",
67 "Sequence",
Bi-Ruei, Chiu1f87ac02017-08-20 01:25:45 +080068 &asn_OP_SEQUENCE,
Lev Walkin4696c742005-08-22 12:23:54 +000069 SEQUENCE_constraint,
Lev Walkin59b176e2005-11-26 11:25:14 +000070 asn_DEF_Sequence_tags_1,
71 sizeof(asn_DEF_Sequence_tags_1)
72 /sizeof(asn_DEF_Sequence_tags_1[0]), /* 1 */
73 asn_DEF_Sequence_tags_1, /* Same as above */
74 sizeof(asn_DEF_Sequence_tags_1)
75 /sizeof(asn_DEF_Sequence_tags_1[0]), /* 1 */
Lev Walkinb33425f2017-07-14 14:59:52 +040076 0, /* No OER visible constraints */
Lev Walkin59b176e2005-11-26 11:25:14 +000077 0, /* No PER visible constraints */
Lev Walkin4696c742005-08-22 12:23:54 +000078 asn_MBR_Sequence_1,
79 2, /* Elements count */
Lev Walkin59b176e2005-11-26 11:25:14 +000080 &asn_SPC_Sequence_specs_1 /* Additional specs */
Lev Walkin4696c742005-08-22 12:23:54 +000081};
82
83
84/*** <<< INCLUDES [Set] >>> ***/
85
Lev Walkin22b5ed42006-09-13 02:51:20 +000086#include "Sequence.h"
Lev Walkin4696c742005-08-22 12:23:54 +000087#include <constr_SET.h>
88
89/*** <<< DEPS [Set] >>> ***/
90
91
92/*
93 * Method of determining the components presence
94 */
95typedef 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
102struct Sequence;
103
104/*** <<< TYPE-DECLS [Set] >>> ***/
105
106typedef 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
120extern asn_TYPE_descriptor_t asn_DEF_Set;
121
122/*** <<< POST-INCLUDE [Set] >>> ***/
123
Lev Walkin22b5ed42006-09-13 02:51:20 +0000124#include "Sequence.h"
Lev Walkin4696c742005-08-22 12:23:54 +0000125
126/*** <<< STAT-DEFS [Set] >>> ***/
127
128static 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 */
Lev Walkinae7bf3f2005-08-29 10:31:14 +0000132 .type = &asn_DEF_Sequence,
Lev Walkin67a30122017-08-10 05:48:54 -0700133 .type_selector = 0,
Lev Walkin4696c742005-08-22 12:23:54 +0000134 .memb_constraints = 0, /* Defer constraints checking to the member type */
Lev Walkinb33425f2017-07-14 14:59:52 +0400135 .oer_constraints = 0, /* OER is not compiled, use -gen-OER */
Lev Walkin59b176e2005-11-26 11:25:14 +0000136 .per_constraints = 0, /* PER is not compiled, use -gen-PER */
137 .default_value = 0,
Lev Walkin4696c742005-08-22 12:23:54 +0000138 .name = "ainl"
139 },
140 { ATF_POINTER, 0, offsetof(struct Set, aptr),
141 .tag = (ASN_TAG_CLASS_CONTEXT | (1 << 2)),
142 .tag_mode = -1, /* IMPLICIT tag at current level */
Lev Walkinae7bf3f2005-08-29 10:31:14 +0000143 .type = &asn_DEF_Sequence,
Lev Walkin67a30122017-08-10 05:48:54 -0700144 .type_selector = 0,
Lev Walkin4696c742005-08-22 12:23:54 +0000145 .memb_constraints = 0, /* Defer constraints checking to the member type */
Lev Walkinb33425f2017-07-14 14:59:52 +0400146 .oer_constraints = 0, /* OER is not compiled, use -gen-OER */
Lev Walkin59b176e2005-11-26 11:25:14 +0000147 .per_constraints = 0, /* PER is not compiled, use -gen-PER */
148 .default_value = 0,
Lev Walkin4696c742005-08-22 12:23:54 +0000149 .name = "aptr"
150 },
151};
Lev Walkina7591b52014-10-12 18:37:35 -0700152static const ber_tlv_tag_t asn_DEF_Set_tags_1[] = {
Lev Walkin4696c742005-08-22 12:23:54 +0000153 (ASN_TAG_CLASS_UNIVERSAL | (17 << 2))
154};
Lev Walkina7591b52014-10-12 18:37:35 -0700155static const asn_TYPE_tag2member_t asn_MAP_Set_tag2el_1[] = {
Lev Walkin4062b012013-10-11 14:29:38 -0700156 { (ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, 0 }, /* ainl */
157 { (ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, 0 } /* aptr */
Lev Walkin4696c742005-08-22 12:23:54 +0000158};
Lev Walkina7591b52014-10-12 18:37:35 -0700159static const uint8_t asn_MAP_Set_mmap_1[(2 + (8 * sizeof(unsigned int)) - 1) / 8] = {
Lev Walkin4696c742005-08-22 12:23:54 +0000160 (1 << 7) | (1 << 6)
161};
Bi-Ruei, Chiu1fa31c92016-05-16 13:50:09 +0800162static
163asn_SET_specifics_t asn_SPC_Set_specs_1 = {
Lev Walkin4696c742005-08-22 12:23:54 +0000164 sizeof(struct Set),
165 offsetof(struct Set, _asn_ctx),
166 offsetof(struct Set, _presence_map),
Lev Walkine3917082017-08-23 10:29:38 -0700167 .tag2el = asn_MAP_Set_tag2el_1,
168 .tag2el_count = 2, /* Count of tags in the map */
Lev Walkin59b176e2005-11-26 11:25:14 +0000169 asn_MAP_Set_tag2el_1, /* Same as above */
Lev Walkin4696c742005-08-22 12:23:54 +0000170 2, /* Count of tags in the CXER map */
171 0, /* Whether extensible */
Lev Walkin46ef3f32017-07-06 08:47:53 -0700172 (const unsigned int *)asn_MAP_Set_mmap_1 /* Mandatory elements map */
Lev Walkin4696c742005-08-22 12:23:54 +0000173};
174asn_TYPE_descriptor_t asn_DEF_Set = {
175 "Set",
176 "Set",
Bi-Ruei, Chiu1f87ac02017-08-20 01:25:45 +0800177 &asn_OP_SET,
Lev Walkin4696c742005-08-22 12:23:54 +0000178 SET_constraint,
Lev Walkin59b176e2005-11-26 11:25:14 +0000179 asn_DEF_Set_tags_1,
180 sizeof(asn_DEF_Set_tags_1)
181 /sizeof(asn_DEF_Set_tags_1[0]), /* 1 */
182 asn_DEF_Set_tags_1, /* Same as above */
183 sizeof(asn_DEF_Set_tags_1)
184 /sizeof(asn_DEF_Set_tags_1[0]), /* 1 */
Lev Walkinb33425f2017-07-14 14:59:52 +0400185 0, /* No OER visible constraints */
Lev Walkin59b176e2005-11-26 11:25:14 +0000186 0, /* No PER visible constraints */
Lev Walkin4696c742005-08-22 12:23:54 +0000187 asn_MBR_Set_1,
188 2, /* Elements count */
Lev Walkin59b176e2005-11-26 11:25:14 +0000189 &asn_SPC_Set_specs_1 /* Additional specs */
Lev Walkin4696c742005-08-22 12:23:54 +0000190};
191
192
193/*** <<< INCLUDES [Choice] >>> ***/
194
Lev Walkin22b5ed42006-09-13 02:51:20 +0000195#include "Sequence.h"
Lev Walkin4696c742005-08-22 12:23:54 +0000196#include <INTEGER.h>
197#include <asn_SET_OF.h>
198#include <constr_SET_OF.h>
199#include <constr_CHOICE.h>
200
201/*** <<< DEPS [Choice] >>> ***/
202
203typedef enum Choice_PR {
204 Choice_PR_NOTHING, /* No components present */
205 Choice_PR_setof,
206 Choice_PR_aptr,
Lev Walkin9f5bb3a2006-08-18 01:46:46 +0000207 Choice_PR_ainl
Lev Walkin4696c742005-08-22 12:23:54 +0000208} Choice_PR;
209
210/*** <<< FWD-DECLS [Choice] >>> ***/
211
212struct Sequence;
213
214/*** <<< TYPE-DECLS [Choice] >>> ***/
215
216typedef struct Choice {
217 Choice_PR present;
218 union Choice_u {
219 struct setof {
220 A_SET_OF(INTEGER_t) list;
221
222 /* Context for parsing across buffer boundaries */
223 asn_struct_ctx_t _asn_ctx;
224 } *setof;
225 struct Sequence *aptr;
226 Sequence_t ainl;
227 } choice;
228
229 /* Context for parsing across buffer boundaries */
230 asn_struct_ctx_t _asn_ctx;
231} Choice_t;
232
233/*** <<< FUNC-DECLS [Choice] >>> ***/
234
235extern asn_TYPE_descriptor_t asn_DEF_Choice;
236
237/*** <<< POST-INCLUDE [Choice] >>> ***/
238
Lev Walkin22b5ed42006-09-13 02:51:20 +0000239#include "Sequence.h"
Lev Walkin4696c742005-08-22 12:23:54 +0000240
241/*** <<< STAT-DEFS [Choice] >>> ***/
242
243static asn_TYPE_member_t asn_MBR_setof_2[] = {
244 { ATF_POINTER, 0, 0,
245 .tag = (ASN_TAG_CLASS_UNIVERSAL | (2 << 2)),
246 .tag_mode = 0,
Lev Walkinae7bf3f2005-08-29 10:31:14 +0000247 .type = &asn_DEF_INTEGER,
Lev Walkin67a30122017-08-10 05:48:54 -0700248 .type_selector = 0,
Lev Walkin4696c742005-08-22 12:23:54 +0000249 .memb_constraints = 0, /* Defer constraints checking to the member type */
Lev Walkinb33425f2017-07-14 14:59:52 +0400250 .oer_constraints = 0, /* OER is not compiled, use -gen-OER */
Lev Walkin59b176e2005-11-26 11:25:14 +0000251 .per_constraints = 0, /* PER is not compiled, use -gen-PER */
252 .default_value = 0,
Lev Walkin4696c742005-08-22 12:23:54 +0000253 .name = ""
254 },
255};
Lev Walkina7591b52014-10-12 18:37:35 -0700256static const ber_tlv_tag_t asn_DEF_setof_tags_2[] = {
Lev Walkin4696c742005-08-22 12:23:54 +0000257 (ASN_TAG_CLASS_CONTEXT | (0 << 2)),
258 (ASN_TAG_CLASS_UNIVERSAL | (17 << 2))
259};
Lev Walkin59b176e2005-11-26 11:25:14 +0000260static asn_SET_OF_specifics_t asn_SPC_setof_specs_2 = {
Lev Walkin4696c742005-08-22 12:23:54 +0000261 sizeof(struct setof),
262 offsetof(struct setof, _asn_ctx),
263 0, /* XER encoding is XMLDelimitedItemList */
264};
265static /* Use -fall-defs-global to expose */
266asn_TYPE_descriptor_t asn_DEF_setof_2 = {
267 "setof",
268 "setof",
Bi-Ruei, Chiu1f87ac02017-08-20 01:25:45 +0800269 &asn_OP_SET_OF,
Lev Walkin4696c742005-08-22 12:23:54 +0000270 SET_OF_constraint,
Lev Walkin59b176e2005-11-26 11:25:14 +0000271 asn_DEF_setof_tags_2,
272 sizeof(asn_DEF_setof_tags_2)
273 /sizeof(asn_DEF_setof_tags_2[0]) - 1, /* 1 */
274 asn_DEF_setof_tags_2, /* Same as above */
275 sizeof(asn_DEF_setof_tags_2)
276 /sizeof(asn_DEF_setof_tags_2[0]), /* 2 */
Lev Walkinb33425f2017-07-14 14:59:52 +0400277 0, /* No OER visible constraints */
Lev Walkin59b176e2005-11-26 11:25:14 +0000278 0, /* No PER visible constraints */
Lev Walkin4696c742005-08-22 12:23:54 +0000279 asn_MBR_setof_2,
280 1, /* Single element */
Lev Walkin59b176e2005-11-26 11:25:14 +0000281 &asn_SPC_setof_specs_2 /* Additional specs */
Lev Walkin4696c742005-08-22 12:23:54 +0000282};
283
284static asn_TYPE_member_t asn_MBR_Choice_1[] = {
285 { ATF_POINTER, 0, offsetof(struct Choice, choice.setof),
286 .tag = (ASN_TAG_CLASS_CONTEXT | (0 << 2)),
Lev Walkin9ab21b82006-10-19 02:46:01 +0000287 .tag_mode = 0,
Lev Walkinae7bf3f2005-08-29 10:31:14 +0000288 .type = &asn_DEF_setof_2,
Lev Walkin67a30122017-08-10 05:48:54 -0700289 .type_selector = 0,
Lev Walkin4696c742005-08-22 12:23:54 +0000290 .memb_constraints = 0, /* Defer constraints checking to the member type */
Lev Walkinb33425f2017-07-14 14:59:52 +0400291 .oer_constraints = 0, /* OER is not compiled, use -gen-OER */
Lev Walkin59b176e2005-11-26 11:25:14 +0000292 .per_constraints = 0, /* PER is not compiled, use -gen-PER */
293 .default_value = 0,
Lev Walkin4696c742005-08-22 12:23:54 +0000294 .name = "setof"
295 },
296 { ATF_POINTER, 0, offsetof(struct Choice, choice.aptr),
297 .tag = (ASN_TAG_CLASS_CONTEXT | (1 << 2)),
298 .tag_mode = -1, /* IMPLICIT tag at current level */
Lev Walkinae7bf3f2005-08-29 10:31:14 +0000299 .type = &asn_DEF_Sequence,
Lev Walkin67a30122017-08-10 05:48:54 -0700300 .type_selector = 0,
Lev Walkin4696c742005-08-22 12:23:54 +0000301 .memb_constraints = 0, /* Defer constraints checking to the member type */
Lev Walkinb33425f2017-07-14 14:59:52 +0400302 .oer_constraints = 0, /* OER is not compiled, use -gen-OER */
Lev Walkin59b176e2005-11-26 11:25:14 +0000303 .per_constraints = 0, /* PER is not compiled, use -gen-PER */
304 .default_value = 0,
Lev Walkin4696c742005-08-22 12:23:54 +0000305 .name = "aptr"
306 },
307 { ATF_NOFLAGS, 0, offsetof(struct Choice, choice.ainl),
308 .tag = (ASN_TAG_CLASS_CONTEXT | (2 << 2)),
309 .tag_mode = -1, /* IMPLICIT tag at current level */
Lev Walkinae7bf3f2005-08-29 10:31:14 +0000310 .type = &asn_DEF_Sequence,
Lev Walkin67a30122017-08-10 05:48:54 -0700311 .type_selector = 0,
Lev Walkin4696c742005-08-22 12:23:54 +0000312 .memb_constraints = 0, /* Defer constraints checking to the member type */
Lev Walkinb33425f2017-07-14 14:59:52 +0400313 .oer_constraints = 0, /* OER is not compiled, use -gen-OER */
Lev Walkin59b176e2005-11-26 11:25:14 +0000314 .per_constraints = 0, /* PER is not compiled, use -gen-PER */
315 .default_value = 0,
Lev Walkin4696c742005-08-22 12:23:54 +0000316 .name = "ainl"
317 },
318};
Lev Walkina7591b52014-10-12 18:37:35 -0700319static const asn_TYPE_tag2member_t asn_MAP_Choice_tag2el_1[] = {
Lev Walkin4062b012013-10-11 14:29:38 -0700320 { (ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, 0 }, /* setof */
321 { (ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, 0 }, /* aptr */
322 { (ASN_TAG_CLASS_CONTEXT | (2 << 2)), 2, 0, 0 } /* ainl */
Lev Walkin4696c742005-08-22 12:23:54 +0000323};
Lev Walkin59b176e2005-11-26 11:25:14 +0000324static asn_CHOICE_specifics_t asn_SPC_Choice_specs_1 = {
Lev Walkin4696c742005-08-22 12:23:54 +0000325 sizeof(struct Choice),
326 offsetof(struct Choice, _asn_ctx),
327 offsetof(struct Choice, present),
328 sizeof(((struct Choice *)0)->present),
Lev Walkine3917082017-08-23 10:29:38 -0700329 .tag2el = asn_MAP_Choice_tag2el_1,
330 .tag2el_count = 3, /* Count of tags in the map */
Lev Walkin59b176e2005-11-26 11:25:14 +0000331 .canonical_order = 0,
332 .ext_start = -1 /* Extensions start */
Lev Walkin4696c742005-08-22 12:23:54 +0000333};
334asn_TYPE_descriptor_t asn_DEF_Choice = {
335 "Choice",
336 "Choice",
Bi-Ruei, Chiu1f87ac02017-08-20 01:25:45 +0800337 &asn_OP_CHOICE,
Lev Walkin4696c742005-08-22 12:23:54 +0000338 CHOICE_constraint,
Lev Walkin4696c742005-08-22 12:23:54 +0000339 0, /* No effective tags (pointer) */
340 0, /* No effective tags (count) */
341 0, /* No tags (pointer) */
342 0, /* No tags (count) */
Lev Walkinb33425f2017-07-14 14:59:52 +0400343 0, /* No OER visible constraints */
Lev Walkin59b176e2005-11-26 11:25:14 +0000344 0, /* No PER visible constraints */
Lev Walkin4696c742005-08-22 12:23:54 +0000345 asn_MBR_Choice_1,
346 3, /* Elements count */
Lev Walkin59b176e2005-11-26 11:25:14 +0000347 &asn_SPC_Choice_specs_1 /* Additional specs */
Lev Walkin4696c742005-08-22 12:23:54 +0000348};
349