blob: e9d863dfe91381574442a31f1da37b750d309152 [file] [log] [blame]
Lev Walkin9ab21b82006-10-19 02:46:01 +00001
2/*** <<< INCLUDES [T1] >>> ***/
3
4#include <INTEGER.h>
5#include <UTF8String.h>
6#include <IA5String.h>
7#include <constr_CHOICE.h>
8#include <constr_SEQUENCE.h>
9
10/*** <<< DEPS [T1] >>> ***/
11
12typedef enum b_PR {
13 b_PR_NOTHING, /* No components present */
14 b_PR_i,
15 b_PR_n
16} b_PR;
17
18/*** <<< TYPE-DECLS [T1] >>> ***/
19
20typedef struct T1 {
21 INTEGER_t a;
22 struct b {
23 b_PR present;
24 union T1__b_u {
25 INTEGER_t i;
26 IA5String_t n;
27 } choice;
28
29 /* Context for parsing across buffer boundaries */
30 asn_struct_ctx_t _asn_ctx;
31 } b;
32 UTF8String_t c;
33
34 /* Context for parsing across buffer boundaries */
35 asn_struct_ctx_t _asn_ctx;
36} T1_t;
37
38/*** <<< FUNC-DECLS [T1] >>> ***/
39
40extern asn_TYPE_descriptor_t asn_DEF_T1;
41
42/*** <<< STAT-DEFS [T1] >>> ***/
43
44static asn_TYPE_member_t asn_MBR_b_3[] = {
45 { ATF_NOFLAGS, 0, offsetof(struct b, choice.i),
46 .tag = (ASN_TAG_CLASS_CONTEXT | (0 << 2)),
47 .tag_mode = -1, /* IMPLICIT tag at current level */
48 .type = &asn_DEF_INTEGER,
Lev Walkin67a30122017-08-10 05:48:54 -070049 .type_selector = 0,
Lev Walkin0bfea562017-09-29 23:16:48 -070050 { .oer_constraints = 0, .per_constraints = 0, .general_constraints = 0 },
Lev Walkin20696a42017-10-17 21:27:33 -070051 0, 0, /* No default value */
Lev Walkin9ab21b82006-10-19 02:46:01 +000052 .name = "i"
53 },
54 { ATF_NOFLAGS, 0, offsetof(struct b, choice.n),
55 .tag = (ASN_TAG_CLASS_CONTEXT | (1 << 2)),
56 .tag_mode = -1, /* IMPLICIT tag at current level */
57 .type = &asn_DEF_IA5String,
Lev Walkin67a30122017-08-10 05:48:54 -070058 .type_selector = 0,
Lev Walkin0bfea562017-09-29 23:16:48 -070059 { .oer_constraints = 0, .per_constraints = 0, .general_constraints = 0 },
Lev Walkin20696a42017-10-17 21:27:33 -070060 0, 0, /* No default value */
Lev Walkin9ab21b82006-10-19 02:46:01 +000061 .name = "n"
62 },
63};
Lev Walkina7591b52014-10-12 18:37:35 -070064static const asn_TYPE_tag2member_t asn_MAP_b_tag2el_3[] = {
Lev Walkin4062b012013-10-11 14:29:38 -070065 { (ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, 0 }, /* i */
66 { (ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, 0 } /* n */
Lev Walkin9ab21b82006-10-19 02:46:01 +000067};
68static asn_CHOICE_specifics_t asn_SPC_b_specs_3 = {
69 sizeof(struct b),
70 offsetof(struct b, _asn_ctx),
71 offsetof(struct b, present),
72 sizeof(((struct b *)0)->present),
Lev Walkine3917082017-08-23 10:29:38 -070073 .tag2el = asn_MAP_b_tag2el_3,
74 .tag2el_count = 2, /* Count of tags in the map */
Lev Walkin20696a42017-10-17 21:27:33 -070075 0, 0,
Lev Walkindf2edbb2017-10-21 13:40:07 -070076 .first_extension = -1 /* Extensions start */
Lev Walkin9ab21b82006-10-19 02:46:01 +000077};
78static /* Use -fall-defs-global to expose */
79asn_TYPE_descriptor_t asn_DEF_b_3 = {
80 "b",
81 "b",
Bi-Ruei, Chiu1f87ac02017-08-20 01:25:45 +080082 &asn_OP_CHOICE,
Lev Walkin9ab21b82006-10-19 02:46:01 +000083 0, /* No effective tags (pointer) */
84 0, /* No effective tags (count) */
85 0, /* No tags (pointer) */
86 0, /* No tags (count) */
Lev Walkin0bfea562017-09-29 23:16:48 -070087 { 0, 0, CHOICE_constraint },
Lev Walkin9ab21b82006-10-19 02:46:01 +000088 asn_MBR_b_3,
89 2, /* Elements count */
90 &asn_SPC_b_specs_3 /* Additional specs */
91};
92
93static asn_TYPE_member_t asn_MBR_T1_1[] = {
94 { ATF_NOFLAGS, 0, offsetof(struct T1, a),
95 .tag = (ASN_TAG_CLASS_CONTEXT | (0 << 2)),
96 .tag_mode = -1, /* IMPLICIT tag at current level */
97 .type = &asn_DEF_INTEGER,
Lev Walkin67a30122017-08-10 05:48:54 -070098 .type_selector = 0,
Lev Walkin0bfea562017-09-29 23:16:48 -070099 { .oer_constraints = 0, .per_constraints = 0, .general_constraints = 0 },
Lev Walkin20696a42017-10-17 21:27:33 -0700100 0, 0, /* No default value */
Lev Walkin9ab21b82006-10-19 02:46:01 +0000101 .name = "a"
102 },
103 { ATF_NOFLAGS, 0, offsetof(struct T1, b),
104 .tag = (ASN_TAG_CLASS_CONTEXT | (1 << 2)),
105 .tag_mode = +1, /* EXPLICIT tag at current level */
106 .type = &asn_DEF_b_3,
Lev Walkin67a30122017-08-10 05:48:54 -0700107 .type_selector = 0,
Lev Walkin0bfea562017-09-29 23:16:48 -0700108 { .oer_constraints = 0, .per_constraints = 0, .general_constraints = 0 },
Lev Walkin20696a42017-10-17 21:27:33 -0700109 0, 0, /* No default value */
Lev Walkin9ab21b82006-10-19 02:46:01 +0000110 .name = "b"
111 },
112 { ATF_NOFLAGS, 0, offsetof(struct T1, c),
113 .tag = (ASN_TAG_CLASS_CONTEXT | (2 << 2)),
114 .tag_mode = -1, /* IMPLICIT tag at current level */
115 .type = &asn_DEF_UTF8String,
Lev Walkin67a30122017-08-10 05:48:54 -0700116 .type_selector = 0,
Lev Walkin0bfea562017-09-29 23:16:48 -0700117 { .oer_constraints = 0, .per_constraints = 0, .general_constraints = 0 },
Lev Walkin20696a42017-10-17 21:27:33 -0700118 0, 0, /* No default value */
Lev Walkin9ab21b82006-10-19 02:46:01 +0000119 .name = "c"
120 },
121};
Lev Walkina7591b52014-10-12 18:37:35 -0700122static const ber_tlv_tag_t asn_DEF_T1_tags_1[] = {
Lev Walkin9ab21b82006-10-19 02:46:01 +0000123 (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))
124};
Lev Walkina7591b52014-10-12 18:37:35 -0700125static const asn_TYPE_tag2member_t asn_MAP_T1_tag2el_1[] = {
Lev Walkin4062b012013-10-11 14:29:38 -0700126 { (ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, 0 }, /* a */
127 { (ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, 0 }, /* b */
128 { (ASN_TAG_CLASS_CONTEXT | (2 << 2)), 2, 0, 0 } /* c */
Lev Walkin9ab21b82006-10-19 02:46:01 +0000129};
130static asn_SEQUENCE_specifics_t asn_SPC_T1_specs_1 = {
131 sizeof(struct T1),
132 offsetof(struct T1, _asn_ctx),
Lev Walkine3917082017-08-23 10:29:38 -0700133 .tag2el = asn_MAP_T1_tag2el_1,
134 .tag2el_count = 3, /* Count of tags in the map */
Lev Walkin9ab21b82006-10-19 02:46:01 +0000135 0, 0, 0, /* Optional elements (not needed) */
Lev Walkindf2edbb2017-10-21 13:40:07 -0700136 -1, /* First extension addition */
Lev Walkin9ab21b82006-10-19 02:46:01 +0000137};
138asn_TYPE_descriptor_t asn_DEF_T1 = {
139 "T1",
140 "T1",
Bi-Ruei, Chiu1f87ac02017-08-20 01:25:45 +0800141 &asn_OP_SEQUENCE,
Lev Walkin9ab21b82006-10-19 02:46:01 +0000142 asn_DEF_T1_tags_1,
143 sizeof(asn_DEF_T1_tags_1)
144 /sizeof(asn_DEF_T1_tags_1[0]), /* 1 */
145 asn_DEF_T1_tags_1, /* Same as above */
146 sizeof(asn_DEF_T1_tags_1)
147 /sizeof(asn_DEF_T1_tags_1[0]), /* 1 */
Lev Walkin0bfea562017-09-29 23:16:48 -0700148 { 0, 0, SEQUENCE_constraint },
Lev Walkin9ab21b82006-10-19 02:46:01 +0000149 asn_MBR_T1_1,
150 3, /* Elements count */
151 &asn_SPC_T1_specs_1 /* Additional specs */
152};
153