blob: de356380914b8fd570653a215a30b8744955ff7d [file] [log] [blame]
Lev Walkin67ec2092004-09-08 00:26:56 +00001
2/*** <<< INCLUDES [Test-structure-1] >>> ***/
3
4#include <Test-structure-1.h>
5#include <INTEGER.h>
6#include <asn_SET_OF.h>
7#include <constr_SET_OF.h>
8#include <asn_SEQUENCE_OF.h>
9#include <constr_SEQUENCE_OF.h>
10#include <constr_SEQUENCE.h>
11
12/*** <<< DEPS [Test-structure-1] >>> ***/
13
Lev Walkin1ca69672004-09-29 13:19:12 +000014
15struct Test_structure_1; /* Forward declaration */
16extern asn_TYPE_descriptor_t asn_DEF_Test_structure_1;
Lev Walkin67ec2092004-09-08 00:26:56 +000017
18/*** <<< TYPE-DECLS [Test-structure-1] >>> ***/
19
20
21typedef struct Test_structure_1 {
22 struct t_member1 {
23 A_SET_OF(struct Test_structure_1) list;
24
25 /* Context for parsing across buffer boundaries */
Lev Walkin1ca69672004-09-29 13:19:12 +000026 asn_struct_ctx_t _asn_ctx;
Lev Walkin67ec2092004-09-08 00:26:56 +000027 } t_member1;
28 struct t_member2 {
29 A_SEQUENCE_OF(struct Test_structure_1) list;
30
31 /* Context for parsing across buffer boundaries */
Lev Walkin1ca69672004-09-29 13:19:12 +000032 asn_struct_ctx_t _asn_ctx;
Lev Walkin67ec2092004-09-08 00:26:56 +000033 } t_member2;
34 struct Test_structure_1 *t_member3 /* OPTIONAL */;
35 INTEGER_t t_member4;
36
37 /* Context for parsing across buffer boundaries */
Lev Walkin1ca69672004-09-29 13:19:12 +000038 asn_struct_ctx_t _asn_ctx;
Lev Walkin67ec2092004-09-08 00:26:56 +000039} Test_structure_1_t;
40
41/*** <<< STAT-DEFS [Test-structure-1] >>> ***/
42
Lev Walkine0272aa2005-03-04 11:26:08 +000043static asn_TYPE_member_t asn_MBR_t_member1_2[] = {
Lev Walkincc93b0f2004-09-10 09:18:20 +000044 { ATF_NOFLAGS, 0, 0,
Lev Walkin67ec2092004-09-08 00:26:56 +000045 .tag = (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)),
46 .tag_mode = 0,
Lev Walkin1ca69672004-09-29 13:19:12 +000047 .type = (void *)&asn_DEF_Test_structure_1,
Lev Walkinba58e1b2005-01-17 12:20:19 +000048 .memb_constraints = 0, /* Defer constraints checking to the member type */
Lev Walkin67ec2092004-09-08 00:26:56 +000049 .name = ""
50 },
51};
Lev Walkine0272aa2005-03-04 11:26:08 +000052static ber_tlv_tag_t asn_DEF_t_member1_2_tags[] = {
Lev Walkin67ec2092004-09-08 00:26:56 +000053 (ASN_TAG_CLASS_UNIVERSAL | (17 << 2))
54};
Lev Walkine0272aa2005-03-04 11:26:08 +000055static asn_SET_OF_specifics_t asn_SPC_t_member1_2_specs = {
Lev Walkin67ec2092004-09-08 00:26:56 +000056 sizeof(struct t_member1),
Lev Walkin1ca69672004-09-29 13:19:12 +000057 offsetof(struct t_member1, _asn_ctx),
Lev Walkina9cc46e2004-09-22 16:06:28 +000058 0, /* XER encoding is XMLDelimitedItemList */
Lev Walkin67ec2092004-09-08 00:26:56 +000059};
60static /* Use -fall-defs-global to expose */
Lev Walkine0272aa2005-03-04 11:26:08 +000061asn_TYPE_descriptor_t asn_DEF_t_member1_2 = {
Lev Walkin67ec2092004-09-08 00:26:56 +000062 "t-member1",
Lev Walkindc06f6b2004-10-20 15:50:55 +000063 "t-member1",
Lev Walkina9cc46e2004-09-22 16:06:28 +000064 SET_OF_free,
65 SET_OF_print,
Lev Walkin67ec2092004-09-08 00:26:56 +000066 SET_OF_constraint,
67 SET_OF_decode_ber,
68 SET_OF_encode_der,
Lev Walkinb2230802005-02-14 20:31:31 +000069 SET_OF_decode_xer,
Lev Walkina9cc46e2004-09-22 16:06:28 +000070 SET_OF_encode_xer,
Lev Walkin67ec2092004-09-08 00:26:56 +000071 0, /* Use generic outmost tag fetcher */
Lev Walkine0272aa2005-03-04 11:26:08 +000072 asn_DEF_t_member1_2_tags,
73 sizeof(asn_DEF_t_member1_2_tags)
74 /sizeof(asn_DEF_t_member1_2_tags[0]), /* 1 */
75 asn_DEF_t_member1_2_tags, /* Same as above */
76 sizeof(asn_DEF_t_member1_2_tags)
77 /sizeof(asn_DEF_t_member1_2_tags[0]), /* 1 */
78 asn_MBR_t_member1_2,
Lev Walkin67ec2092004-09-08 00:26:56 +000079 1, /* Single element */
Lev Walkine0272aa2005-03-04 11:26:08 +000080 &asn_SPC_t_member1_2_specs /* Additional specs */
Lev Walkin67ec2092004-09-08 00:26:56 +000081};
82
Lev Walkine0272aa2005-03-04 11:26:08 +000083static asn_TYPE_member_t asn_MBR_t_member2_3[] = {
Lev Walkincc93b0f2004-09-10 09:18:20 +000084 { ATF_NOFLAGS, 0, 0,
Lev Walkin67ec2092004-09-08 00:26:56 +000085 .tag = (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)),
86 .tag_mode = 0,
Lev Walkin1ca69672004-09-29 13:19:12 +000087 .type = (void *)&asn_DEF_Test_structure_1,
Lev Walkinba58e1b2005-01-17 12:20:19 +000088 .memb_constraints = 0, /* Defer constraints checking to the member type */
Lev Walkin67ec2092004-09-08 00:26:56 +000089 .name = ""
90 },
91};
Lev Walkine0272aa2005-03-04 11:26:08 +000092static ber_tlv_tag_t asn_DEF_t_member2_3_tags[] = {
Lev Walkin67ec2092004-09-08 00:26:56 +000093 (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))
94};
Lev Walkine0272aa2005-03-04 11:26:08 +000095static asn_SET_OF_specifics_t asn_SPC_t_member2_3_specs = {
Lev Walkin67ec2092004-09-08 00:26:56 +000096 sizeof(struct t_member2),
Lev Walkin1ca69672004-09-29 13:19:12 +000097 offsetof(struct t_member2, _asn_ctx),
Lev Walkina9cc46e2004-09-22 16:06:28 +000098 0, /* XER encoding is XMLDelimitedItemList */
Lev Walkin67ec2092004-09-08 00:26:56 +000099};
100static /* Use -fall-defs-global to expose */
Lev Walkine0272aa2005-03-04 11:26:08 +0000101asn_TYPE_descriptor_t asn_DEF_t_member2_3 = {
Lev Walkin67ec2092004-09-08 00:26:56 +0000102 "t-member2",
Lev Walkindc06f6b2004-10-20 15:50:55 +0000103 "t-member2",
Lev Walkina9cc46e2004-09-22 16:06:28 +0000104 SEQUENCE_OF_free,
105 SEQUENCE_OF_print,
Lev Walkin67ec2092004-09-08 00:26:56 +0000106 SEQUENCE_OF_constraint,
107 SEQUENCE_OF_decode_ber,
108 SEQUENCE_OF_encode_der,
Lev Walkinb2230802005-02-14 20:31:31 +0000109 SEQUENCE_OF_decode_xer,
Lev Walkina9cc46e2004-09-22 16:06:28 +0000110 SEQUENCE_OF_encode_xer,
Lev Walkin67ec2092004-09-08 00:26:56 +0000111 0, /* Use generic outmost tag fetcher */
Lev Walkine0272aa2005-03-04 11:26:08 +0000112 asn_DEF_t_member2_3_tags,
113 sizeof(asn_DEF_t_member2_3_tags)
114 /sizeof(asn_DEF_t_member2_3_tags[0]), /* 1 */
115 asn_DEF_t_member2_3_tags, /* Same as above */
116 sizeof(asn_DEF_t_member2_3_tags)
117 /sizeof(asn_DEF_t_member2_3_tags[0]), /* 1 */
118 asn_MBR_t_member2_3,
Lev Walkin67ec2092004-09-08 00:26:56 +0000119 1, /* Single element */
Lev Walkine0272aa2005-03-04 11:26:08 +0000120 &asn_SPC_t_member2_3_specs /* Additional specs */
Lev Walkin67ec2092004-09-08 00:26:56 +0000121};
122
Lev Walkine0272aa2005-03-04 11:26:08 +0000123static asn_TYPE_member_t asn_MBR_Test_structure_1_1[] = {
Lev Walkincc93b0f2004-09-10 09:18:20 +0000124 { ATF_NOFLAGS, 0, offsetof(struct Test_structure_1, t_member1),
Lev Walkin67ec2092004-09-08 00:26:56 +0000125 .tag = (ASN_TAG_CLASS_UNIVERSAL | (17 << 2)),
126 .tag_mode = 0,
Lev Walkine0272aa2005-03-04 11:26:08 +0000127 .type = (void *)&asn_DEF_t_member1_2,
Lev Walkinba58e1b2005-01-17 12:20:19 +0000128 .memb_constraints = 0, /* Defer constraints checking to the member type */
Lev Walkin67ec2092004-09-08 00:26:56 +0000129 .name = "t-member1"
130 },
Lev Walkincc93b0f2004-09-10 09:18:20 +0000131 { ATF_NOFLAGS, 0, offsetof(struct Test_structure_1, t_member2),
Lev Walkin67ec2092004-09-08 00:26:56 +0000132 .tag = (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)),
133 .tag_mode = 0,
Lev Walkine0272aa2005-03-04 11:26:08 +0000134 .type = (void *)&asn_DEF_t_member2_3,
Lev Walkinba58e1b2005-01-17 12:20:19 +0000135 .memb_constraints = 0, /* Defer constraints checking to the member type */
Lev Walkin67ec2092004-09-08 00:26:56 +0000136 .name = "t-member2"
137 },
Lev Walkincc93b0f2004-09-10 09:18:20 +0000138 { ATF_POINTER, 1, offsetof(struct Test_structure_1, t_member3),
Lev Walkin67ec2092004-09-08 00:26:56 +0000139 .tag = (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)),
140 .tag_mode = 0,
Lev Walkin1ca69672004-09-29 13:19:12 +0000141 .type = (void *)&asn_DEF_Test_structure_1,
Lev Walkinba58e1b2005-01-17 12:20:19 +0000142 .memb_constraints = 0, /* Defer constraints checking to the member type */
Lev Walkin67ec2092004-09-08 00:26:56 +0000143 .name = "t-member3"
144 },
Lev Walkincc93b0f2004-09-10 09:18:20 +0000145 { ATF_NOFLAGS, 0, offsetof(struct Test_structure_1, t_member4),
Lev Walkin67ec2092004-09-08 00:26:56 +0000146 .tag = (ASN_TAG_CLASS_UNIVERSAL | (2 << 2)),
147 .tag_mode = 0,
Lev Walkin1ca69672004-09-29 13:19:12 +0000148 .type = (void *)&asn_DEF_INTEGER,
Lev Walkinba58e1b2005-01-17 12:20:19 +0000149 .memb_constraints = 0, /* Defer constraints checking to the member type */
Lev Walkin67ec2092004-09-08 00:26:56 +0000150 .name = "t-member4"
151 },
152};
Lev Walkine0272aa2005-03-04 11:26:08 +0000153static ber_tlv_tag_t asn_DEF_Test_structure_1_1_tags[] = {
Lev Walkin67ec2092004-09-08 00:26:56 +0000154 (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))
155};
Lev Walkine0272aa2005-03-04 11:26:08 +0000156static asn_TYPE_tag2member_t asn_MAP_Test_structure_1_1_tag2el[] = {
Lev Walkin67ec2092004-09-08 00:26:56 +0000157 { (ASN_TAG_CLASS_UNIVERSAL | (2 << 2)), 3, 0, 0 }, /* t-member4 at 19 */
158 { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)), 1, 0, 1 }, /* t-member2 at 16 */
159 { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)), 2, -1, 0 }, /* t-member3 at 17 */
Lev Walkinf82138b2005-02-25 08:20:32 +0000160 { (ASN_TAG_CLASS_UNIVERSAL | (17 << 2)), 0, 0, 0 } /* t-member1 at 15 */
Lev Walkin67ec2092004-09-08 00:26:56 +0000161};
Lev Walkine0272aa2005-03-04 11:26:08 +0000162static asn_SEQUENCE_specifics_t asn_SPC_Test_structure_1_1_specs = {
Lev Walkin67ec2092004-09-08 00:26:56 +0000163 sizeof(struct Test_structure_1),
Lev Walkin1ca69672004-09-29 13:19:12 +0000164 offsetof(struct Test_structure_1, _asn_ctx),
Lev Walkine0272aa2005-03-04 11:26:08 +0000165 asn_MAP_Test_structure_1_1_tag2el,
Lev Walkin67ec2092004-09-08 00:26:56 +0000166 4, /* Count of tags in the map */
167 -1, /* Start extensions */
168 -1 /* Stop extensions */
169};
Lev Walkin1ca69672004-09-29 13:19:12 +0000170asn_TYPE_descriptor_t asn_DEF_Test_structure_1 = {
Lev Walkin67ec2092004-09-08 00:26:56 +0000171 "Test-structure-1",
Lev Walkindc06f6b2004-10-20 15:50:55 +0000172 "Test-structure-1",
Lev Walkina9cc46e2004-09-22 16:06:28 +0000173 SEQUENCE_free,
174 SEQUENCE_print,
Lev Walkin67ec2092004-09-08 00:26:56 +0000175 SEQUENCE_constraint,
176 SEQUENCE_decode_ber,
177 SEQUENCE_encode_der,
Lev Walkin61b40d82004-10-23 15:07:45 +0000178 SEQUENCE_decode_xer,
Lev Walkina9cc46e2004-09-22 16:06:28 +0000179 SEQUENCE_encode_xer,
Lev Walkin67ec2092004-09-08 00:26:56 +0000180 0, /* Use generic outmost tag fetcher */
Lev Walkine0272aa2005-03-04 11:26:08 +0000181 asn_DEF_Test_structure_1_1_tags,
182 sizeof(asn_DEF_Test_structure_1_1_tags)
183 /sizeof(asn_DEF_Test_structure_1_1_tags[0]), /* 1 */
184 asn_DEF_Test_structure_1_1_tags, /* Same as above */
185 sizeof(asn_DEF_Test_structure_1_1_tags)
186 /sizeof(asn_DEF_Test_structure_1_1_tags[0]), /* 1 */
187 asn_MBR_Test_structure_1_1,
Lev Walkin67ec2092004-09-08 00:26:56 +0000188 4, /* Elements count */
Lev Walkine0272aa2005-03-04 11:26:08 +0000189 &asn_SPC_Test_structure_1_1_specs /* Additional specs */
Lev Walkin67ec2092004-09-08 00:26:56 +0000190};
191
192
193/*** <<< INCLUDES [Choice-1] >>> ***/
194
195#include <Choice-1.h>
196#include <INTEGER.h>
197#include <asn_SET_OF.h>
198#include <constr_SET_OF.h>
199#include <constr_CHOICE.h>
200
201/*** <<< DEPS [Choice-1] >>> ***/
202
203typedef enum Choice_1_PR {
204 Choice_1_PR_NOTHING, /* No components present */
205 Choice_1_PR_and,
206 Choice_1_PR_or,
207 Choice_1_PR_not,
208 Choice_1_PR_other,
209} Choice_1_PR;
Lev Walkin1ca69672004-09-29 13:19:12 +0000210
211struct Choice_1; /* Forward declaration */
212
213struct Choice_1; /* Forward declaration */
214extern asn_TYPE_descriptor_t asn_DEF_Choice_1;
Lev Walkin67ec2092004-09-08 00:26:56 +0000215
216/*** <<< TYPE-DECLS [Choice-1] >>> ***/
217
218
219typedef struct Choice_1 {
220 Choice_1_PR present;
221 union {
Lev Walkincc93b0f2004-09-10 09:18:20 +0000222 struct Choice_1 *and;
Lev Walkin67ec2092004-09-08 00:26:56 +0000223 struct or {
224 A_SET_OF(struct Choice_1) list;
225
226 /* Context for parsing across buffer boundaries */
Lev Walkin1ca69672004-09-29 13:19:12 +0000227 asn_struct_ctx_t _asn_ctx;
Lev Walkin67ec2092004-09-08 00:26:56 +0000228 } or;
Lev Walkincc93b0f2004-09-10 09:18:20 +0000229 struct Choice_1 *not;
Lev Walkin67ec2092004-09-08 00:26:56 +0000230 INTEGER_t other;
231 } choice;
232
233 /* Context for parsing across buffer boundaries */
Lev Walkin1ca69672004-09-29 13:19:12 +0000234 asn_struct_ctx_t _asn_ctx;
Lev Walkin67ec2092004-09-08 00:26:56 +0000235} Choice_1_t;
236
237/*** <<< STAT-DEFS [Choice-1] >>> ***/
238
Lev Walkine0272aa2005-03-04 11:26:08 +0000239static asn_TYPE_member_t asn_MBR_or_2[] = {
Lev Walkincc93b0f2004-09-10 09:18:20 +0000240 { ATF_NOFLAGS, 0, 0,
Lev Walkinb9189732004-09-10 09:37:12 +0000241 .tag = -1 /* Ambiguous tag (CHOICE?) */,
Lev Walkin67ec2092004-09-08 00:26:56 +0000242 .tag_mode = 0,
Lev Walkin1ca69672004-09-29 13:19:12 +0000243 .type = (void *)&asn_DEF_Choice_1,
Lev Walkinba58e1b2005-01-17 12:20:19 +0000244 .memb_constraints = 0, /* Defer constraints checking to the member type */
Lev Walkin67ec2092004-09-08 00:26:56 +0000245 .name = ""
246 },
247};
Lev Walkine0272aa2005-03-04 11:26:08 +0000248static ber_tlv_tag_t asn_DEF_or_2_tags[] = {
Lev Walkin188ed2c2004-09-13 08:31:01 +0000249 (ASN_TAG_CLASS_CONTEXT | (2 << 2)),
250 (ASN_TAG_CLASS_UNIVERSAL | (17 << 2))
Lev Walkin67ec2092004-09-08 00:26:56 +0000251};
Lev Walkine0272aa2005-03-04 11:26:08 +0000252static asn_SET_OF_specifics_t asn_SPC_or_2_specs = {
Lev Walkin67ec2092004-09-08 00:26:56 +0000253 sizeof(struct or),
Lev Walkin1ca69672004-09-29 13:19:12 +0000254 offsetof(struct or, _asn_ctx),
Lev Walkina9cc46e2004-09-22 16:06:28 +0000255 1, /* XER encoding is XMLValueList */
Lev Walkin67ec2092004-09-08 00:26:56 +0000256};
257static /* Use -fall-defs-global to expose */
Lev Walkine0272aa2005-03-04 11:26:08 +0000258asn_TYPE_descriptor_t asn_DEF_or_2 = {
Lev Walkin67ec2092004-09-08 00:26:56 +0000259 "or",
Lev Walkindc06f6b2004-10-20 15:50:55 +0000260 "or",
Lev Walkina9cc46e2004-09-22 16:06:28 +0000261 SET_OF_free,
262 SET_OF_print,
Lev Walkin67ec2092004-09-08 00:26:56 +0000263 SET_OF_constraint,
264 SET_OF_decode_ber,
265 SET_OF_encode_der,
Lev Walkinb2230802005-02-14 20:31:31 +0000266 SET_OF_decode_xer,
Lev Walkina9cc46e2004-09-22 16:06:28 +0000267 SET_OF_encode_xer,
Lev Walkin67ec2092004-09-08 00:26:56 +0000268 0, /* Use generic outmost tag fetcher */
Lev Walkine0272aa2005-03-04 11:26:08 +0000269 asn_DEF_or_2_tags,
270 sizeof(asn_DEF_or_2_tags)
271 /sizeof(asn_DEF_or_2_tags[0]) - 1, /* 1 */
272 asn_DEF_or_2_tags, /* Same as above */
273 sizeof(asn_DEF_or_2_tags)
274 /sizeof(asn_DEF_or_2_tags[0]), /* 2 */
275 asn_MBR_or_2,
Lev Walkin67ec2092004-09-08 00:26:56 +0000276 1, /* Single element */
Lev Walkine0272aa2005-03-04 11:26:08 +0000277 &asn_SPC_or_2_specs /* Additional specs */
Lev Walkin67ec2092004-09-08 00:26:56 +0000278};
279
Lev Walkine0272aa2005-03-04 11:26:08 +0000280static asn_TYPE_member_t asn_MBR_Choice_1_1[] = {
Lev Walkincc93b0f2004-09-10 09:18:20 +0000281 { ATF_POINTER, 0, offsetof(struct Choice_1, choice.and),
Lev Walkin67ec2092004-09-08 00:26:56 +0000282 .tag = (ASN_TAG_CLASS_CONTEXT | (1 << 2)),
283 .tag_mode = +1, /* EXPLICIT tag at current level */
Lev Walkin1ca69672004-09-29 13:19:12 +0000284 .type = (void *)&asn_DEF_Choice_1,
Lev Walkinba58e1b2005-01-17 12:20:19 +0000285 .memb_constraints = 0, /* Defer constraints checking to the member type */
Lev Walkin67ec2092004-09-08 00:26:56 +0000286 .name = "and"
287 },
Lev Walkincc93b0f2004-09-10 09:18:20 +0000288 { ATF_NOFLAGS, 0, offsetof(struct Choice_1, choice.or),
Lev Walkin67ec2092004-09-08 00:26:56 +0000289 .tag = (ASN_TAG_CLASS_CONTEXT | (2 << 2)),
290 .tag_mode = -1, /* IMPLICIT tag at current level */
Lev Walkine0272aa2005-03-04 11:26:08 +0000291 .type = (void *)&asn_DEF_or_2,
Lev Walkinba58e1b2005-01-17 12:20:19 +0000292 .memb_constraints = 0, /* Defer constraints checking to the member type */
Lev Walkin67ec2092004-09-08 00:26:56 +0000293 .name = "or"
294 },
Lev Walkincc93b0f2004-09-10 09:18:20 +0000295 { ATF_POINTER, 0, offsetof(struct Choice_1, choice.not),
Lev Walkin67ec2092004-09-08 00:26:56 +0000296 .tag = (ASN_TAG_CLASS_CONTEXT | (3 << 2)),
297 .tag_mode = +1, /* EXPLICIT tag at current level */
Lev Walkin1ca69672004-09-29 13:19:12 +0000298 .type = (void *)&asn_DEF_Choice_1,
Lev Walkinba58e1b2005-01-17 12:20:19 +0000299 .memb_constraints = 0, /* Defer constraints checking to the member type */
Lev Walkin67ec2092004-09-08 00:26:56 +0000300 .name = "not"
301 },
Lev Walkincc93b0f2004-09-10 09:18:20 +0000302 { ATF_NOFLAGS, 0, offsetof(struct Choice_1, choice.other),
Lev Walkin67ec2092004-09-08 00:26:56 +0000303 .tag = (ASN_TAG_CLASS_CONTEXT | (4 << 2)),
304 .tag_mode = +1, /* EXPLICIT tag at current level */
Lev Walkin1ca69672004-09-29 13:19:12 +0000305 .type = (void *)&asn_DEF_INTEGER,
Lev Walkinba58e1b2005-01-17 12:20:19 +0000306 .memb_constraints = 0, /* Defer constraints checking to the member type */
Lev Walkin67ec2092004-09-08 00:26:56 +0000307 .name = "other"
308 },
309};
Lev Walkine0272aa2005-03-04 11:26:08 +0000310static asn_TYPE_tag2member_t asn_MAP_Choice_1_1_tag2el[] = {
Lev Walkin67ec2092004-09-08 00:26:56 +0000311 { (ASN_TAG_CLASS_CONTEXT | (1 << 2)), 0, 0, 0 }, /* and at 22 */
312 { (ASN_TAG_CLASS_CONTEXT | (2 << 2)), 1, 0, 0 }, /* or at 23 */
313 { (ASN_TAG_CLASS_CONTEXT | (3 << 2)), 2, 0, 0 }, /* not at 24 */
Lev Walkinf82138b2005-02-25 08:20:32 +0000314 { (ASN_TAG_CLASS_CONTEXT | (4 << 2)), 3, 0, 0 } /* other at 26 */
Lev Walkin67ec2092004-09-08 00:26:56 +0000315};
Lev Walkine0272aa2005-03-04 11:26:08 +0000316static asn_CHOICE_specifics_t asn_SPC_Choice_1_1_specs = {
Lev Walkin67ec2092004-09-08 00:26:56 +0000317 sizeof(struct Choice_1),
Lev Walkin1ca69672004-09-29 13:19:12 +0000318 offsetof(struct Choice_1, _asn_ctx),
Lev Walkin67ec2092004-09-08 00:26:56 +0000319 offsetof(struct Choice_1, present),
320 sizeof(((struct Choice_1 *)0)->present),
Lev Walkine0272aa2005-03-04 11:26:08 +0000321 asn_MAP_Choice_1_1_tag2el,
Lev Walkin67ec2092004-09-08 00:26:56 +0000322 4, /* Count of tags in the map */
323 0 /* Whether extensible */
324};
Lev Walkin1ca69672004-09-29 13:19:12 +0000325asn_TYPE_descriptor_t asn_DEF_Choice_1 = {
Lev Walkin67ec2092004-09-08 00:26:56 +0000326 "Choice-1",
Lev Walkindc06f6b2004-10-20 15:50:55 +0000327 "Choice-1",
Lev Walkina9cc46e2004-09-22 16:06:28 +0000328 CHOICE_free,
329 CHOICE_print,
Lev Walkin67ec2092004-09-08 00:26:56 +0000330 CHOICE_constraint,
331 CHOICE_decode_ber,
332 CHOICE_encode_der,
Lev Walkin61b40d82004-10-23 15:07:45 +0000333 CHOICE_decode_xer,
Lev Walkina9cc46e2004-09-22 16:06:28 +0000334 CHOICE_encode_xer,
Lev Walkin67ec2092004-09-08 00:26:56 +0000335 CHOICE_outmost_tag,
Lev Walkin188ed2c2004-09-13 08:31:01 +0000336 0, /* No effective tags (pointer) */
337 0, /* No effective tags (count) */
338 0, /* No tags (pointer) */
339 0, /* No tags (count) */
Lev Walkine0272aa2005-03-04 11:26:08 +0000340 asn_MBR_Choice_1_1,
Lev Walkin67ec2092004-09-08 00:26:56 +0000341 4, /* Elements count */
Lev Walkine0272aa2005-03-04 11:26:08 +0000342 &asn_SPC_Choice_1_1_specs /* Additional specs */
Lev Walkin1ca69672004-09-29 13:19:12 +0000343};
344
345
346/*** <<< INCLUDES [Test-structure-2] >>> ***/
347
348#include <Test-structure-3.h>
349#include <constr_SET.h>
350
351/*** <<< DEPS [Test-structure-2] >>> ***/
352
353
354/*
355 * Method of determining the components presence
356 */
357typedef enum Test_structure_2_PR {
358 Test_structure_2_PR_m1, /* Member m1 is present */
359} Test_structure_2_PR;
360
361struct Test_structure_3; /* Forward declaration */
362extern asn_TYPE_descriptor_t asn_DEF_Test_structure_2;
363
364/*** <<< TYPE-DECLS [Test-structure-2] >>> ***/
365
366
367typedef struct Test_structure_2 {
368 struct Test_structure_3 *m1 /* OPTIONAL */;
369
370 /* Presence bitmask: ASN_SET_ISPRESENT(pTest_structure_2, Test_structure_2_PR_x) */
371 unsigned int _presence_map
372 [((1+(8*sizeof(unsigned int))-1)/(8*sizeof(unsigned int)))];
373
374 /* Context for parsing across buffer boundaries */
375 asn_struct_ctx_t _asn_ctx;
376} Test_structure_2_t;
377
378/*** <<< STAT-DEFS [Test-structure-2] >>> ***/
379
Lev Walkine0272aa2005-03-04 11:26:08 +0000380static asn_TYPE_member_t asn_MBR_Test_structure_2_1[] = {
Lev Walkin1ca69672004-09-29 13:19:12 +0000381 { ATF_POINTER, 1, offsetof(struct Test_structure_2, m1),
382 .tag = (ASN_TAG_CLASS_UNIVERSAL | (17 << 2)),
383 .tag_mode = 0,
384 .type = (void *)&asn_DEF_Test_structure_3,
Lev Walkinba58e1b2005-01-17 12:20:19 +0000385 .memb_constraints = 0, /* Defer constraints checking to the member type */
Lev Walkin1ca69672004-09-29 13:19:12 +0000386 .name = "m1"
387 },
388};
Lev Walkine0272aa2005-03-04 11:26:08 +0000389static ber_tlv_tag_t asn_DEF_Test_structure_2_1_tags[] = {
Lev Walkin1ca69672004-09-29 13:19:12 +0000390 (ASN_TAG_CLASS_UNIVERSAL | (17 << 2))
391};
Lev Walkine0272aa2005-03-04 11:26:08 +0000392static asn_TYPE_tag2member_t asn_MAP_Test_structure_2_1_tag2el[] = {
Lev Walkinf82138b2005-02-25 08:20:32 +0000393 { (ASN_TAG_CLASS_UNIVERSAL | (17 << 2)), 0, 0, 0 } /* m1 at 28 */
Lev Walkin1ca69672004-09-29 13:19:12 +0000394};
Lev Walkine0272aa2005-03-04 11:26:08 +0000395static uint8_t asn_MAP_Test_structure_2_1_mmap[(1 + (8 * sizeof(unsigned int)) - 1) / 8] = {
Lev Walkin1ca69672004-09-29 13:19:12 +0000396 (0 << 7)
397};
Lev Walkine0272aa2005-03-04 11:26:08 +0000398static asn_SET_specifics_t asn_SPC_Test_structure_2_1_specs = {
Lev Walkin1ca69672004-09-29 13:19:12 +0000399 sizeof(struct Test_structure_2),
400 offsetof(struct Test_structure_2, _asn_ctx),
401 offsetof(struct Test_structure_2, _presence_map),
Lev Walkine0272aa2005-03-04 11:26:08 +0000402 asn_MAP_Test_structure_2_1_tag2el,
Lev Walkin1ca69672004-09-29 13:19:12 +0000403 1, /* Count of tags in the map */
Lev Walkine0272aa2005-03-04 11:26:08 +0000404 asn_MAP_Test_structure_2_1_tag2el, /* Same as above */
Lev Walkinf82138b2005-02-25 08:20:32 +0000405 1, /* Count of tags in the CXER map */
Lev Walkin1ca69672004-09-29 13:19:12 +0000406 0, /* Whether extensible */
Lev Walkine0272aa2005-03-04 11:26:08 +0000407 (unsigned int *)asn_MAP_Test_structure_2_1_mmap /* Mandatory elements map */
Lev Walkin1ca69672004-09-29 13:19:12 +0000408};
409asn_TYPE_descriptor_t asn_DEF_Test_structure_2 = {
410 "Test-structure-2",
Lev Walkindc06f6b2004-10-20 15:50:55 +0000411 "Test-structure-2",
Lev Walkin1ca69672004-09-29 13:19:12 +0000412 SET_free,
413 SET_print,
414 SET_constraint,
415 SET_decode_ber,
416 SET_encode_der,
Lev Walkinb2230802005-02-14 20:31:31 +0000417 SET_decode_xer,
Lev Walkin1ca69672004-09-29 13:19:12 +0000418 SET_encode_xer,
419 0, /* Use generic outmost tag fetcher */
Lev Walkine0272aa2005-03-04 11:26:08 +0000420 asn_DEF_Test_structure_2_1_tags,
421 sizeof(asn_DEF_Test_structure_2_1_tags)
422 /sizeof(asn_DEF_Test_structure_2_1_tags[0]), /* 1 */
423 asn_DEF_Test_structure_2_1_tags, /* Same as above */
424 sizeof(asn_DEF_Test_structure_2_1_tags)
425 /sizeof(asn_DEF_Test_structure_2_1_tags[0]), /* 1 */
426 asn_MBR_Test_structure_2_1,
Lev Walkin1ca69672004-09-29 13:19:12 +0000427 1, /* Elements count */
Lev Walkine0272aa2005-03-04 11:26:08 +0000428 &asn_SPC_Test_structure_2_1_specs /* Additional specs */
Lev Walkin1ca69672004-09-29 13:19:12 +0000429};
430
431
432/*** <<< INCLUDES [Test-structure-3] >>> ***/
433
434#include <Test-structure-2.h>
435#include <constr_SET.h>
436
437/*** <<< DEPS [Test-structure-3] >>> ***/
438
439
440/*
441 * Method of determining the components presence
442 */
443typedef enum Test_structure_3_PR {
444 Test_structure_3_PR_m1, /* Member m1 is present */
445} Test_structure_3_PR;
446
447struct Test_structure_2; /* Forward declaration */
448extern asn_TYPE_descriptor_t asn_DEF_Test_structure_3;
449
450/*** <<< TYPE-DECLS [Test-structure-3] >>> ***/
451
452
453typedef struct Test_structure_3 {
454 struct Test_structure_2 *m1 /* OPTIONAL */;
455
456 /* Presence bitmask: ASN_SET_ISPRESENT(pTest_structure_3, Test_structure_3_PR_x) */
457 unsigned int _presence_map
458 [((1+(8*sizeof(unsigned int))-1)/(8*sizeof(unsigned int)))];
459
460 /* Context for parsing across buffer boundaries */
461 asn_struct_ctx_t _asn_ctx;
462} Test_structure_3_t;
463
464/*** <<< STAT-DEFS [Test-structure-3] >>> ***/
465
Lev Walkine0272aa2005-03-04 11:26:08 +0000466static asn_TYPE_member_t asn_MBR_Test_structure_3_1[] = {
Lev Walkin1ca69672004-09-29 13:19:12 +0000467 { ATF_POINTER, 1, offsetof(struct Test_structure_3, m1),
468 .tag = (ASN_TAG_CLASS_UNIVERSAL | (17 << 2)),
469 .tag_mode = 0,
470 .type = (void *)&asn_DEF_Test_structure_2,
Lev Walkinba58e1b2005-01-17 12:20:19 +0000471 .memb_constraints = 0, /* Defer constraints checking to the member type */
Lev Walkin1ca69672004-09-29 13:19:12 +0000472 .name = "m1"
473 },
474};
Lev Walkine0272aa2005-03-04 11:26:08 +0000475static ber_tlv_tag_t asn_DEF_Test_structure_3_1_tags[] = {
Lev Walkin1ca69672004-09-29 13:19:12 +0000476 (ASN_TAG_CLASS_UNIVERSAL | (17 << 2))
477};
Lev Walkine0272aa2005-03-04 11:26:08 +0000478static asn_TYPE_tag2member_t asn_MAP_Test_structure_3_1_tag2el[] = {
Lev Walkinf82138b2005-02-25 08:20:32 +0000479 { (ASN_TAG_CLASS_UNIVERSAL | (17 << 2)), 0, 0, 0 } /* m1 at 29 */
Lev Walkin1ca69672004-09-29 13:19:12 +0000480};
Lev Walkine0272aa2005-03-04 11:26:08 +0000481static uint8_t asn_MAP_Test_structure_3_1_mmap[(1 + (8 * sizeof(unsigned int)) - 1) / 8] = {
Lev Walkin1ca69672004-09-29 13:19:12 +0000482 (0 << 7)
483};
Lev Walkine0272aa2005-03-04 11:26:08 +0000484static asn_SET_specifics_t asn_SPC_Test_structure_3_1_specs = {
Lev Walkin1ca69672004-09-29 13:19:12 +0000485 sizeof(struct Test_structure_3),
486 offsetof(struct Test_structure_3, _asn_ctx),
487 offsetof(struct Test_structure_3, _presence_map),
Lev Walkine0272aa2005-03-04 11:26:08 +0000488 asn_MAP_Test_structure_3_1_tag2el,
Lev Walkin1ca69672004-09-29 13:19:12 +0000489 1, /* Count of tags in the map */
Lev Walkine0272aa2005-03-04 11:26:08 +0000490 asn_MAP_Test_structure_3_1_tag2el, /* Same as above */
Lev Walkinf82138b2005-02-25 08:20:32 +0000491 1, /* Count of tags in the CXER map */
Lev Walkin1ca69672004-09-29 13:19:12 +0000492 0, /* Whether extensible */
Lev Walkine0272aa2005-03-04 11:26:08 +0000493 (unsigned int *)asn_MAP_Test_structure_3_1_mmap /* Mandatory elements map */
Lev Walkin1ca69672004-09-29 13:19:12 +0000494};
495asn_TYPE_descriptor_t asn_DEF_Test_structure_3 = {
496 "Test-structure-3",
Lev Walkindc06f6b2004-10-20 15:50:55 +0000497 "Test-structure-3",
Lev Walkin1ca69672004-09-29 13:19:12 +0000498 SET_free,
499 SET_print,
500 SET_constraint,
501 SET_decode_ber,
502 SET_encode_der,
Lev Walkinb2230802005-02-14 20:31:31 +0000503 SET_decode_xer,
Lev Walkin1ca69672004-09-29 13:19:12 +0000504 SET_encode_xer,
505 0, /* Use generic outmost tag fetcher */
Lev Walkine0272aa2005-03-04 11:26:08 +0000506 asn_DEF_Test_structure_3_1_tags,
507 sizeof(asn_DEF_Test_structure_3_1_tags)
508 /sizeof(asn_DEF_Test_structure_3_1_tags[0]), /* 1 */
509 asn_DEF_Test_structure_3_1_tags, /* Same as above */
510 sizeof(asn_DEF_Test_structure_3_1_tags)
511 /sizeof(asn_DEF_Test_structure_3_1_tags[0]), /* 1 */
512 asn_MBR_Test_structure_3_1,
Lev Walkin1ca69672004-09-29 13:19:12 +0000513 1, /* Elements count */
Lev Walkine0272aa2005-03-04 11:26:08 +0000514 &asn_SPC_Test_structure_3_1_specs /* Additional specs */
Lev Walkin67ec2092004-09-08 00:26:56 +0000515};
516