blob: acd1fd45136270ecff5c0ee4afe4cc0647cd9bad [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,
49 .memb_constraints = 0, /* Defer constraints checking to the member type */
Lev Walkinb33425f2017-07-14 14:59:52 +040050 .oer_constraints = 0, /* OER is not compiled, use -gen-OER */
Lev Walkin9ab21b82006-10-19 02:46:01 +000051 .per_constraints = 0, /* PER is not compiled, use -gen-PER */
52 .default_value = 0,
53 .name = "i"
54 },
55 { ATF_NOFLAGS, 0, offsetof(struct b, choice.n),
56 .tag = (ASN_TAG_CLASS_CONTEXT | (1 << 2)),
57 .tag_mode = -1, /* IMPLICIT tag at current level */
58 .type = &asn_DEF_IA5String,
59 .memb_constraints = 0, /* Defer constraints checking to the member type */
Lev Walkinb33425f2017-07-14 14:59:52 +040060 .oer_constraints = 0, /* OER is not compiled, use -gen-OER */
Lev Walkin9ab21b82006-10-19 02:46:01 +000061 .per_constraints = 0, /* PER is not compiled, use -gen-PER */
62 .default_value = 0,
63 .name = "n"
64 },
65};
Lev Walkina7591b52014-10-12 18:37:35 -070066static const asn_TYPE_tag2member_t asn_MAP_b_tag2el_3[] = {
Lev Walkin4062b012013-10-11 14:29:38 -070067 { (ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, 0 }, /* i */
68 { (ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, 0 } /* n */
Lev Walkin9ab21b82006-10-19 02:46:01 +000069};
70static asn_CHOICE_specifics_t asn_SPC_b_specs_3 = {
71 sizeof(struct b),
72 offsetof(struct b, _asn_ctx),
73 offsetof(struct b, present),
74 sizeof(((struct b *)0)->present),
75 asn_MAP_b_tag2el_3,
76 2, /* Count of tags in the map */
77 .canonical_order = 0,
78 .ext_start = -1 /* Extensions start */
79};
80static /* Use -fall-defs-global to expose */
81asn_TYPE_descriptor_t asn_DEF_b_3 = {
82 "b",
83 "b",
84 CHOICE_free,
85 CHOICE_print,
86 CHOICE_constraint,
87 CHOICE_decode_ber,
88 CHOICE_encode_der,
89 CHOICE_decode_xer,
90 CHOICE_encode_xer,
Lev Walkinba68c912017-07-06 07:52:39 -070091 0, 0, /* No OER support, use "-gen-OER" to enable */
Lev Walkinb33425f2017-07-14 14:59:52 +040092 0, 0, /* No PER support, use "-gen-PER" to enable */
Lev Walkin9ab21b82006-10-19 02:46:01 +000093 CHOICE_outmost_tag,
94 0, /* No effective tags (pointer) */
95 0, /* No effective tags (count) */
96 0, /* No tags (pointer) */
97 0, /* No tags (count) */
Lev Walkinb33425f2017-07-14 14:59:52 +040098 0, /* No OER visible constraints */
Lev Walkin9ab21b82006-10-19 02:46:01 +000099 0, /* No PER visible constraints */
100 asn_MBR_b_3,
101 2, /* Elements count */
102 &asn_SPC_b_specs_3 /* Additional specs */
103};
104
105static asn_TYPE_member_t asn_MBR_T1_1[] = {
106 { ATF_NOFLAGS, 0, offsetof(struct T1, a),
107 .tag = (ASN_TAG_CLASS_CONTEXT | (0 << 2)),
108 .tag_mode = -1, /* IMPLICIT tag at current level */
109 .type = &asn_DEF_INTEGER,
110 .memb_constraints = 0, /* Defer constraints checking to the member type */
Lev Walkinb33425f2017-07-14 14:59:52 +0400111 .oer_constraints = 0, /* OER is not compiled, use -gen-OER */
Lev Walkin9ab21b82006-10-19 02:46:01 +0000112 .per_constraints = 0, /* PER is not compiled, use -gen-PER */
113 .default_value = 0,
114 .name = "a"
115 },
116 { ATF_NOFLAGS, 0, offsetof(struct T1, b),
117 .tag = (ASN_TAG_CLASS_CONTEXT | (1 << 2)),
118 .tag_mode = +1, /* EXPLICIT tag at current level */
119 .type = &asn_DEF_b_3,
120 .memb_constraints = 0, /* Defer constraints checking to the member type */
Lev Walkinb33425f2017-07-14 14:59:52 +0400121 .oer_constraints = 0, /* OER is not compiled, use -gen-OER */
Lev Walkin9ab21b82006-10-19 02:46:01 +0000122 .per_constraints = 0, /* PER is not compiled, use -gen-PER */
123 .default_value = 0,
124 .name = "b"
125 },
126 { ATF_NOFLAGS, 0, offsetof(struct T1, c),
127 .tag = (ASN_TAG_CLASS_CONTEXT | (2 << 2)),
128 .tag_mode = -1, /* IMPLICIT tag at current level */
129 .type = &asn_DEF_UTF8String,
130 .memb_constraints = 0, /* Defer constraints checking to the member type */
Lev Walkinb33425f2017-07-14 14:59:52 +0400131 .oer_constraints = 0, /* OER is not compiled, use -gen-OER */
Lev Walkin9ab21b82006-10-19 02:46:01 +0000132 .per_constraints = 0, /* PER is not compiled, use -gen-PER */
133 .default_value = 0,
134 .name = "c"
135 },
136};
Lev Walkina7591b52014-10-12 18:37:35 -0700137static const ber_tlv_tag_t asn_DEF_T1_tags_1[] = {
Lev Walkin9ab21b82006-10-19 02:46:01 +0000138 (ASN_TAG_CLASS_UNIVERSAL | (16 << 2))
139};
Lev Walkina7591b52014-10-12 18:37:35 -0700140static const asn_TYPE_tag2member_t asn_MAP_T1_tag2el_1[] = {
Lev Walkin4062b012013-10-11 14:29:38 -0700141 { (ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, 0 }, /* a */
142 { (ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, 0 }, /* b */
143 { (ASN_TAG_CLASS_CONTEXT | (2 << 2)), 2, 0, 0 } /* c */
Lev Walkin9ab21b82006-10-19 02:46:01 +0000144};
145static asn_SEQUENCE_specifics_t asn_SPC_T1_specs_1 = {
146 sizeof(struct T1),
147 offsetof(struct T1, _asn_ctx),
148 asn_MAP_T1_tag2el_1,
149 3, /* Count of tags in the map */
150 0, 0, 0, /* Optional elements (not needed) */
151 -1, /* Start extensions */
152 -1 /* Stop extensions */
153};
154asn_TYPE_descriptor_t asn_DEF_T1 = {
155 "T1",
156 "T1",
157 SEQUENCE_free,
158 SEQUENCE_print,
159 SEQUENCE_constraint,
160 SEQUENCE_decode_ber,
161 SEQUENCE_encode_der,
162 SEQUENCE_decode_xer,
163 SEQUENCE_encode_xer,
Lev Walkinba68c912017-07-06 07:52:39 -0700164 0, 0, /* No OER support, use "-gen-OER" to enable */
Lev Walkinb33425f2017-07-14 14:59:52 +0400165 0, 0, /* No PER support, use "-gen-PER" to enable */
Lev Walkin9ab21b82006-10-19 02:46:01 +0000166 0, /* Use generic outmost tag fetcher */
167 asn_DEF_T1_tags_1,
168 sizeof(asn_DEF_T1_tags_1)
169 /sizeof(asn_DEF_T1_tags_1[0]), /* 1 */
170 asn_DEF_T1_tags_1, /* Same as above */
171 sizeof(asn_DEF_T1_tags_1)
172 /sizeof(asn_DEF_T1_tags_1[0]), /* 1 */
Lev Walkinb33425f2017-07-14 14:59:52 +0400173 0, /* No OER visible constraints */
Lev Walkin9ab21b82006-10-19 02:46:01 +0000174 0, /* No PER visible constraints */
175 asn_MBR_T1_1,
176 3, /* Elements count */
177 &asn_SPC_T1_specs_1 /* Additional specs */
178};
179