blob: 9b1f885e0b8ff9878bcbc2469b83238d5cd1d26d [file] [log] [blame]
Lev Walkinf15320b2004-06-03 03:38:44 +00001
Lev Walkin5d5e6522004-08-11 05:22:22 +00002/*** <<< INCLUDES [T] >>> ***/
Lev Walkinf15320b2004-06-03 03:38:44 +00003
Lev Walkinf15320b2004-06-03 03:38:44 +00004#include <INTEGER.h>
Lev Walkinf15320b2004-06-03 03:38:44 +00005#include <asn_SEQUENCE_OF.h>
Lev Walkin5d5e6522004-08-11 05:22:22 +00006#include <constr_SEQUENCE_OF.h>
Lev Walkinf15320b2004-06-03 03:38:44 +00007#include <constr_SEQUENCE.h>
8
Lev Walkinc8285712005-03-04 22:18:20 +00009/*** <<< FWD-DECLS [T] >>> ***/
Lev Walkin5d5e6522004-08-11 05:22:22 +000010
Lev Walkinbf56d542005-03-04 23:50:56 +000011struct T2;
Lev Walkinf15320b2004-06-03 03:38:44 +000012
13/*** <<< TYPE-DECLS [T] >>> ***/
14
Lev Walkinf15320b2004-06-03 03:38:44 +000015typedef struct T {
Lev Walkin64d99e92005-01-30 18:34:07 +000016 INTEGER_t Int;
Lev Walkinf15320b2004-06-03 03:38:44 +000017 struct collection {
Lev Walkinc8285712005-03-04 22:18:20 +000018 A_SEQUENCE_OF(struct T2) list;
Lev Walkinf15320b2004-06-03 03:38:44 +000019
20 /* Context for parsing across buffer boundaries */
Lev Walkindfae9752004-09-29 13:19:37 +000021 asn_struct_ctx_t _asn_ctx;
Lev Walkinf15320b2004-06-03 03:38:44 +000022 } collection;
23
24 /* Context for parsing across buffer boundaries */
Lev Walkindfae9752004-09-29 13:19:37 +000025 asn_struct_ctx_t _asn_ctx;
Lev Walkinf15320b2004-06-03 03:38:44 +000026} T_t;
27
Lev Walkinc8285712005-03-04 22:18:20 +000028/*** <<< FUNC-DECLS [T] >>> ***/
29
30extern asn_TYPE_descriptor_t asn_DEF_T;
31
32/*** <<< POST-INCLUDE [T] >>> ***/
33
Lev Walkin22b5ed42006-09-13 02:51:20 +000034#include "T2.h"
Lev Walkinc8285712005-03-04 22:18:20 +000035
Lev Walkinf15320b2004-06-03 03:38:44 +000036/*** <<< STAT-DEFS [T] >>> ***/
37
Lev Walkine8318b82005-03-06 09:29:03 +000038static asn_TYPE_member_t asn_MBR_collection_3[] = {
Lev Walkin8eb4b572005-08-16 16:57:17 +000039 { ATF_POINTER, 0, 0,
Lev Walkin2e3055d2004-08-20 13:36:32 +000040 .tag = (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)),
41 .tag_mode = 0,
Lev Walkinae7bf3f2005-08-29 10:31:14 +000042 .type = &asn_DEF_T2,
Lev Walkinba58e1b2005-01-17 12:20:19 +000043 .memb_constraints = 0, /* Defer constraints checking to the member type */
Lev Walkinb33425f2017-07-14 14:59:52 +040044 .oer_constraints = 0, /* OER is not compiled, use -gen-OER */
Lev Walkin59b176e2005-11-26 11:25:14 +000045 .per_constraints = 0, /* PER is not compiled, use -gen-PER */
46 .default_value = 0,
Lev Walkin2e3055d2004-08-20 13:36:32 +000047 .name = ""
Lev Walkinf15320b2004-06-03 03:38:44 +000048 },
Lev Walkin2e3055d2004-08-20 13:36:32 +000049};
Lev Walkina7591b52014-10-12 18:37:35 -070050static const ber_tlv_tag_t asn_DEF_collection_tags_3[] = {
Lev Walkin2e3055d2004-08-20 13:36:32 +000051 (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))
52};
Lev Walkin59b176e2005-11-26 11:25:14 +000053static asn_SET_OF_specifics_t asn_SPC_collection_specs_3 = {
Lev Walkin2e3055d2004-08-20 13:36:32 +000054 sizeof(struct collection),
Lev Walkindfae9752004-09-29 13:19:37 +000055 offsetof(struct collection, _asn_ctx),
Lev Walkina9cc46e2004-09-22 16:06:28 +000056 0, /* XER encoding is XMLDelimitedItemList */
Lev Walkin2e3055d2004-08-20 13:36:32 +000057};
Lev Walkind04430c2004-09-07 06:44:29 +000058static /* Use -fall-defs-global to expose */
Lev Walkine8318b82005-03-06 09:29:03 +000059asn_TYPE_descriptor_t asn_DEF_collection_3 = {
Lev Walkin2e3055d2004-08-20 13:36:32 +000060 "collection",
Lev Walkindc06f6b2004-10-20 15:50:55 +000061 "collection",
Lev Walkina9cc46e2004-09-22 16:06:28 +000062 SEQUENCE_OF_free,
63 SEQUENCE_OF_print,
Lev Walkin2e3055d2004-08-20 13:36:32 +000064 SEQUENCE_OF_constraint,
65 SEQUENCE_OF_decode_ber,
66 SEQUENCE_OF_encode_der,
Lev Walkinb2230802005-02-14 20:31:31 +000067 SEQUENCE_OF_decode_xer,
Lev Walkina9cc46e2004-09-22 16:06:28 +000068 SEQUENCE_OF_encode_xer,
Lev Walkinba68c912017-07-06 07:52:39 -070069 0, 0, /* No OER support, use "-gen-OER" to enable */
Lev Walkinb33425f2017-07-14 14:59:52 +040070 0, 0, /* No PER support, use "-gen-PER" to enable */
Lev Walkin2e3055d2004-08-20 13:36:32 +000071 0, /* Use generic outmost tag fetcher */
Lev Walkin59b176e2005-11-26 11:25:14 +000072 asn_DEF_collection_tags_3,
73 sizeof(asn_DEF_collection_tags_3)
74 /sizeof(asn_DEF_collection_tags_3[0]), /* 1 */
75 asn_DEF_collection_tags_3, /* Same as above */
76 sizeof(asn_DEF_collection_tags_3)
77 /sizeof(asn_DEF_collection_tags_3[0]), /* 1 */
Lev Walkinb33425f2017-07-14 14:59:52 +040078 0, /* No OER visible constraints */
Lev Walkin59b176e2005-11-26 11:25:14 +000079 0, /* No PER visible constraints */
Lev Walkine8318b82005-03-06 09:29:03 +000080 asn_MBR_collection_3,
Lev Walkin2e3055d2004-08-20 13:36:32 +000081 1, /* Single element */
Lev Walkin59b176e2005-11-26 11:25:14 +000082 &asn_SPC_collection_specs_3 /* Additional specs */
Lev Walkin2e3055d2004-08-20 13:36:32 +000083};
84
Lev Walkine0272aa2005-03-04 11:26:08 +000085static asn_TYPE_member_t asn_MBR_T_1[] = {
Lev Walkin64d99e92005-01-30 18:34:07 +000086 { ATF_NOFLAGS, 0, offsetof(struct T, Int),
Lev Walkin2e3055d2004-08-20 13:36:32 +000087 .tag = (ASN_TAG_CLASS_UNIVERSAL | (2 << 2)),
88 .tag_mode = 0,
Lev Walkinae7bf3f2005-08-29 10:31:14 +000089 .type = &asn_DEF_INTEGER,
Lev Walkinba58e1b2005-01-17 12:20:19 +000090 .memb_constraints = 0, /* Defer constraints checking to the member type */
Lev Walkinb33425f2017-07-14 14:59:52 +040091 .oer_constraints = 0, /* OER is not compiled, use -gen-OER */
Lev Walkin59b176e2005-11-26 11:25:14 +000092 .per_constraints = 0, /* PER is not compiled, use -gen-PER */
93 .default_value = 0,
Lev Walkin2e3055d2004-08-20 13:36:32 +000094 .name = "int"
95 },
Lev Walkincc93b0f2004-09-10 09:18:20 +000096 { ATF_NOFLAGS, 0, offsetof(struct T, collection),
Lev Walkin2e3055d2004-08-20 13:36:32 +000097 .tag = (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)),
98 .tag_mode = 0,
Lev Walkinae7bf3f2005-08-29 10:31:14 +000099 .type = &asn_DEF_collection_3,
Lev Walkinba58e1b2005-01-17 12:20:19 +0000100 .memb_constraints = 0, /* Defer constraints checking to the member type */
Lev Walkinb33425f2017-07-14 14:59:52 +0400101 .oer_constraints = 0, /* OER is not compiled, use -gen-OER */
Lev Walkin59b176e2005-11-26 11:25:14 +0000102 .per_constraints = 0, /* PER is not compiled, use -gen-PER */
103 .default_value = 0,
Lev Walkin2e3055d2004-08-20 13:36:32 +0000104 .name = "collection"
Lev Walkinf15320b2004-06-03 03:38:44 +0000105 },
106};
Lev Walkina7591b52014-10-12 18:37:35 -0700107static const ber_tlv_tag_t asn_DEF_T_tags_1[] = {
Lev Walkinf15320b2004-06-03 03:38:44 +0000108 (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))
109};
Lev Walkina7591b52014-10-12 18:37:35 -0700110static const asn_TYPE_tag2member_t asn_MAP_T_tag2el_1[] = {
Lev Walkin4062b012013-10-11 14:29:38 -0700111 { (ASN_TAG_CLASS_UNIVERSAL | (2 << 2)), 0, 0, 0 }, /* int */
112 { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)), 1, 0, 0 } /* collection */
Lev Walkincda6b8a2004-06-06 07:20:52 +0000113};
Lev Walkin59b176e2005-11-26 11:25:14 +0000114static asn_SEQUENCE_specifics_t asn_SPC_T_specs_1 = {
Lev Walkinf15320b2004-06-03 03:38:44 +0000115 sizeof(struct T),
Lev Walkindfae9752004-09-29 13:19:37 +0000116 offsetof(struct T, _asn_ctx),
Lev Walkin59b176e2005-11-26 11:25:14 +0000117 asn_MAP_T_tag2el_1,
Lev Walkincda6b8a2004-06-06 07:20:52 +0000118 2, /* Count of tags in the map */
Lev Walkin59b176e2005-11-26 11:25:14 +0000119 0, 0, 0, /* Optional elements (not needed) */
Lev Walkinf15320b2004-06-03 03:38:44 +0000120 -1, /* Start extensions */
121 -1 /* Stop extensions */
122};
Lev Walkindfae9752004-09-29 13:19:37 +0000123asn_TYPE_descriptor_t asn_DEF_T = {
Lev Walkinf15320b2004-06-03 03:38:44 +0000124 "T",
Lev Walkindc06f6b2004-10-20 15:50:55 +0000125 "T",
Lev Walkina9cc46e2004-09-22 16:06:28 +0000126 SEQUENCE_free,
127 SEQUENCE_print,
Lev Walkinf15320b2004-06-03 03:38:44 +0000128 SEQUENCE_constraint,
129 SEQUENCE_decode_ber,
130 SEQUENCE_encode_der,
Lev Walkin61b40d82004-10-23 15:07:45 +0000131 SEQUENCE_decode_xer,
Lev Walkina9cc46e2004-09-22 16:06:28 +0000132 SEQUENCE_encode_xer,
Lev Walkinba68c912017-07-06 07:52:39 -0700133 0, 0, /* No OER support, use "-gen-OER" to enable */
Lev Walkinb33425f2017-07-14 14:59:52 +0400134 0, 0, /* No PER support, use "-gen-PER" to enable */
Lev Walkinf15320b2004-06-03 03:38:44 +0000135 0, /* Use generic outmost tag fetcher */
Lev Walkin59b176e2005-11-26 11:25:14 +0000136 asn_DEF_T_tags_1,
137 sizeof(asn_DEF_T_tags_1)
138 /sizeof(asn_DEF_T_tags_1[0]), /* 1 */
139 asn_DEF_T_tags_1, /* Same as above */
140 sizeof(asn_DEF_T_tags_1)
141 /sizeof(asn_DEF_T_tags_1[0]), /* 1 */
Lev Walkinb33425f2017-07-14 14:59:52 +0400142 0, /* No OER visible constraints */
Lev Walkin59b176e2005-11-26 11:25:14 +0000143 0, /* No PER visible constraints */
Lev Walkine0272aa2005-03-04 11:26:08 +0000144 asn_MBR_T_1,
Lev Walkin2e3055d2004-08-20 13:36:32 +0000145 2, /* Elements count */
Lev Walkin59b176e2005-11-26 11:25:14 +0000146 &asn_SPC_T_specs_1 /* Additional specs */
Lev Walkinf15320b2004-06-03 03:38:44 +0000147};
148
149
Lev Walkin5d5e6522004-08-11 05:22:22 +0000150/*** <<< INCLUDES [T2] >>> ***/
Lev Walkinf15320b2004-06-03 03:38:44 +0000151
Lev Walkinf15320b2004-06-03 03:38:44 +0000152#include <BOOLEAN.h>
153#include <UTF8String.h>
Lev Walkinf15320b2004-06-03 03:38:44 +0000154#include <constr_SEQUENCE.h>
155
Lev Walkinf15320b2004-06-03 03:38:44 +0000156/*** <<< TYPE-DECLS [T2] >>> ***/
157
Lev Walkinf15320b2004-06-03 03:38:44 +0000158typedef struct T2 {
159 BOOLEAN_t flag;
160 UTF8String_t str;
161
162 /* Context for parsing across buffer boundaries */
Lev Walkindfae9752004-09-29 13:19:37 +0000163 asn_struct_ctx_t _asn_ctx;
Lev Walkinf15320b2004-06-03 03:38:44 +0000164} T2_t;
165
Lev Walkinc8285712005-03-04 22:18:20 +0000166/*** <<< FUNC-DECLS [T2] >>> ***/
167
168extern asn_TYPE_descriptor_t asn_DEF_T2;
169
Lev Walkinf15320b2004-06-03 03:38:44 +0000170/*** <<< STAT-DEFS [T2] >>> ***/
171
Lev Walkine0272aa2005-03-04 11:26:08 +0000172static asn_TYPE_member_t asn_MBR_T2_1[] = {
Lev Walkincc93b0f2004-09-10 09:18:20 +0000173 { ATF_NOFLAGS, 0, offsetof(struct T2, flag),
Lev Walkin2e3055d2004-08-20 13:36:32 +0000174 .tag = (ASN_TAG_CLASS_UNIVERSAL | (1 << 2)),
175 .tag_mode = 0,
Lev Walkinae7bf3f2005-08-29 10:31:14 +0000176 .type = &asn_DEF_BOOLEAN,
Lev Walkinba58e1b2005-01-17 12:20:19 +0000177 .memb_constraints = 0, /* Defer constraints checking to the member type */
Lev Walkinb33425f2017-07-14 14:59:52 +0400178 .oer_constraints = 0, /* OER is not compiled, use -gen-OER */
Lev Walkin59b176e2005-11-26 11:25:14 +0000179 .per_constraints = 0, /* PER is not compiled, use -gen-PER */
180 .default_value = 0,
Lev Walkin2e3055d2004-08-20 13:36:32 +0000181 .name = "flag"
Lev Walkinf15320b2004-06-03 03:38:44 +0000182 },
Lev Walkincc93b0f2004-09-10 09:18:20 +0000183 { ATF_NOFLAGS, 0, offsetof(struct T2, str),
Lev Walkin2e3055d2004-08-20 13:36:32 +0000184 .tag = (ASN_TAG_CLASS_UNIVERSAL | (12 << 2)),
185 .tag_mode = 0,
Lev Walkinae7bf3f2005-08-29 10:31:14 +0000186 .type = &asn_DEF_UTF8String,
Lev Walkinba58e1b2005-01-17 12:20:19 +0000187 .memb_constraints = 0, /* Defer constraints checking to the member type */
Lev Walkinb33425f2017-07-14 14:59:52 +0400188 .oer_constraints = 0, /* OER is not compiled, use -gen-OER */
Lev Walkin59b176e2005-11-26 11:25:14 +0000189 .per_constraints = 0, /* PER is not compiled, use -gen-PER */
190 .default_value = 0,
Lev Walkin2e3055d2004-08-20 13:36:32 +0000191 .name = "str"
Lev Walkinf15320b2004-06-03 03:38:44 +0000192 },
193};
Lev Walkina7591b52014-10-12 18:37:35 -0700194static const ber_tlv_tag_t asn_DEF_T2_tags_1[] = {
Lev Walkinf15320b2004-06-03 03:38:44 +0000195 (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))
196};
Lev Walkina7591b52014-10-12 18:37:35 -0700197static const asn_TYPE_tag2member_t asn_MAP_T2_tag2el_1[] = {
Lev Walkin4062b012013-10-11 14:29:38 -0700198 { (ASN_TAG_CLASS_UNIVERSAL | (1 << 2)), 0, 0, 0 }, /* flag */
199 { (ASN_TAG_CLASS_UNIVERSAL | (12 << 2)), 1, 0, 0 } /* str */
Lev Walkincda6b8a2004-06-06 07:20:52 +0000200};
Lev Walkin59b176e2005-11-26 11:25:14 +0000201static asn_SEQUENCE_specifics_t asn_SPC_T2_specs_1 = {
Lev Walkinf15320b2004-06-03 03:38:44 +0000202 sizeof(struct T2),
Lev Walkindfae9752004-09-29 13:19:37 +0000203 offsetof(struct T2, _asn_ctx),
Lev Walkin59b176e2005-11-26 11:25:14 +0000204 asn_MAP_T2_tag2el_1,
Lev Walkincda6b8a2004-06-06 07:20:52 +0000205 2, /* Count of tags in the map */
Lev Walkin59b176e2005-11-26 11:25:14 +0000206 0, 0, 0, /* Optional elements (not needed) */
Lev Walkinf15320b2004-06-03 03:38:44 +0000207 -1, /* Start extensions */
208 -1 /* Stop extensions */
209};
Lev Walkindfae9752004-09-29 13:19:37 +0000210asn_TYPE_descriptor_t asn_DEF_T2 = {
Lev Walkinf15320b2004-06-03 03:38:44 +0000211 "T2",
Lev Walkindc06f6b2004-10-20 15:50:55 +0000212 "T2",
Lev Walkina9cc46e2004-09-22 16:06:28 +0000213 SEQUENCE_free,
214 SEQUENCE_print,
Lev Walkinf15320b2004-06-03 03:38:44 +0000215 SEQUENCE_constraint,
216 SEQUENCE_decode_ber,
217 SEQUENCE_encode_der,
Lev Walkin61b40d82004-10-23 15:07:45 +0000218 SEQUENCE_decode_xer,
Lev Walkina9cc46e2004-09-22 16:06:28 +0000219 SEQUENCE_encode_xer,
Lev Walkinba68c912017-07-06 07:52:39 -0700220 0, 0, /* No OER support, use "-gen-OER" to enable */
Lev Walkinb33425f2017-07-14 14:59:52 +0400221 0, 0, /* No PER support, use "-gen-PER" to enable */
Lev Walkinf15320b2004-06-03 03:38:44 +0000222 0, /* Use generic outmost tag fetcher */
Lev Walkin59b176e2005-11-26 11:25:14 +0000223 asn_DEF_T2_tags_1,
224 sizeof(asn_DEF_T2_tags_1)
225 /sizeof(asn_DEF_T2_tags_1[0]), /* 1 */
226 asn_DEF_T2_tags_1, /* Same as above */
227 sizeof(asn_DEF_T2_tags_1)
228 /sizeof(asn_DEF_T2_tags_1[0]), /* 1 */
Lev Walkinb33425f2017-07-14 14:59:52 +0400229 0, /* No OER visible constraints */
Lev Walkin59b176e2005-11-26 11:25:14 +0000230 0, /* No PER visible constraints */
Lev Walkine0272aa2005-03-04 11:26:08 +0000231 asn_MBR_T2_1,
Lev Walkin2e3055d2004-08-20 13:36:32 +0000232 2, /* Elements count */
Lev Walkin59b176e2005-11-26 11:25:14 +0000233 &asn_SPC_T2_specs_1 /* Additional specs */
Lev Walkinf15320b2004-06-03 03:38:44 +0000234};
235