blob: 88d7b33fbc443a020a54eaf269177a2bd78749e7 [file] [log] [blame]
Lev Walkin59b176e2005-11-26 11:25:14 +00001
2/*** <<< INCLUDES [CN-IntegerUnlimited] >>> ***/
3
4#include <INTEGER.h>
5
6/*** <<< TYPE-DECLS [CN-IntegerUnlimited] >>> ***/
7
8typedef INTEGER_t CN_IntegerUnlimited_t;
9
10/*** <<< FUNC-DECLS [CN-IntegerUnlimited] >>> ***/
11
12extern asn_TYPE_descriptor_t asn_DEF_CN_IntegerUnlimited;
13asn_struct_free_f CN_IntegerUnlimited_free;
14asn_struct_print_f CN_IntegerUnlimited_print;
15asn_constr_check_f CN_IntegerUnlimited_constraint;
16ber_type_decoder_f CN_IntegerUnlimited_decode_ber;
17der_type_encoder_f CN_IntegerUnlimited_encode_der;
18xer_type_decoder_f CN_IntegerUnlimited_decode_xer;
19xer_type_encoder_f CN_IntegerUnlimited_encode_xer;
20per_type_decoder_f CN_IntegerUnlimited_decode_uper;
21
22/*** <<< CODE [CN-IntegerUnlimited] >>> ***/
23
24int
25CN_IntegerUnlimited_constraint(asn_TYPE_descriptor_t *td, const void *sptr,
26 asn_app_consume_bytes_f *app_errlog, void *app_key) {
27 /* Replace with underlying type checker */
28 td->check_constraints = asn_DEF_INTEGER.check_constraints;
29 return td->check_constraints(td, sptr, app_errlog, app_key);
30}
31
32/*
33 * This type is implemented using INTEGER,
34 * so here we adjust the DEF accordingly.
35 */
36static void
37CN_IntegerUnlimited_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) {
38 td->free_struct = asn_DEF_INTEGER.free_struct;
39 td->print_struct = asn_DEF_INTEGER.print_struct;
40 td->ber_decoder = asn_DEF_INTEGER.ber_decoder;
41 td->der_encoder = asn_DEF_INTEGER.der_encoder;
42 td->xer_decoder = asn_DEF_INTEGER.xer_decoder;
43 td->xer_encoder = asn_DEF_INTEGER.xer_encoder;
44 td->uper_decoder = asn_DEF_INTEGER.uper_decoder;
45 if(!td->per_constraints)
46 td->per_constraints = asn_DEF_INTEGER.per_constraints;
47 td->elements = asn_DEF_INTEGER.elements;
48 td->elements_count = asn_DEF_INTEGER.elements_count;
49 td->specifics = asn_DEF_INTEGER.specifics;
50}
51
52void
53CN_IntegerUnlimited_free(asn_TYPE_descriptor_t *td,
54 void *struct_ptr, int contents_only) {
55 CN_IntegerUnlimited_1_inherit_TYPE_descriptor(td);
56 td->free_struct(td, struct_ptr, contents_only);
57}
58
59int
60CN_IntegerUnlimited_print(asn_TYPE_descriptor_t *td, const void *struct_ptr,
61 int ilevel, asn_app_consume_bytes_f *cb, void *app_key) {
62 CN_IntegerUnlimited_1_inherit_TYPE_descriptor(td);
63 return td->print_struct(td, struct_ptr, ilevel, cb, app_key);
64}
65
66asn_dec_rval_t
67CN_IntegerUnlimited_decode_ber(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td,
68 void **structure, const void *bufptr, size_t size, int tag_mode) {
69 CN_IntegerUnlimited_1_inherit_TYPE_descriptor(td);
70 return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, tag_mode);
71}
72
73asn_enc_rval_t
74CN_IntegerUnlimited_encode_der(asn_TYPE_descriptor_t *td,
75 void *structure, int tag_mode, ber_tlv_tag_t tag,
76 asn_app_consume_bytes_f *cb, void *app_key) {
77 CN_IntegerUnlimited_1_inherit_TYPE_descriptor(td);
78 return td->der_encoder(td, structure, tag_mode, tag, cb, app_key);
79}
80
81asn_dec_rval_t
82CN_IntegerUnlimited_decode_xer(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td,
83 void **structure, const char *opt_mname, const void *bufptr, size_t size) {
84 CN_IntegerUnlimited_1_inherit_TYPE_descriptor(td);
85 return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, size);
86}
87
88asn_enc_rval_t
89CN_IntegerUnlimited_encode_xer(asn_TYPE_descriptor_t *td, void *structure,
90 int ilevel, enum xer_encoder_flags_e flags,
91 asn_app_consume_bytes_f *cb, void *app_key) {
92 CN_IntegerUnlimited_1_inherit_TYPE_descriptor(td);
93 return td->xer_encoder(td, structure, ilevel, flags, cb, app_key);
94}
95
96asn_dec_rval_t
97CN_IntegerUnlimited_decode_uper(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td,
98 asn_per_constraints_t *constraints, void **structure, asn_per_data_t *per_data) {
99 CN_IntegerUnlimited_1_inherit_TYPE_descriptor(td);
100 return td->uper_decoder(opt_codec_ctx, td, constraints, structure, per_data);
101}
102
103
104/*** <<< STAT-DEFS [CN-IntegerUnlimited] >>> ***/
105
106static ber_tlv_tag_t asn_DEF_CN_IntegerUnlimited_tags_1[] = {
107 (ASN_TAG_CLASS_UNIVERSAL | (2 << 2))
108};
109asn_TYPE_descriptor_t asn_DEF_CN_IntegerUnlimited = {
110 "CN-IntegerUnlimited",
111 "CN-IntegerUnlimited",
112 CN_IntegerUnlimited_free,
113 CN_IntegerUnlimited_print,
114 CN_IntegerUnlimited_constraint,
115 CN_IntegerUnlimited_decode_ber,
116 CN_IntegerUnlimited_encode_der,
117 CN_IntegerUnlimited_decode_xer,
118 CN_IntegerUnlimited_encode_xer,
119 CN_IntegerUnlimited_decode_uper,
120 0, /* Use generic outmost tag fetcher */
121 asn_DEF_CN_IntegerUnlimited_tags_1,
122 sizeof(asn_DEF_CN_IntegerUnlimited_tags_1)
123 /sizeof(asn_DEF_CN_IntegerUnlimited_tags_1[0]), /* 1 */
124 asn_DEF_CN_IntegerUnlimited_tags_1, /* Same as above */
125 sizeof(asn_DEF_CN_IntegerUnlimited_tags_1)
126 /sizeof(asn_DEF_CN_IntegerUnlimited_tags_1[0]), /* 1 */
127 0, /* No PER visible constraints */
128 0, 0, /* No members */
129 0 /* No specifics */
130};
131
132
133/*** <<< INCLUDES [CN-IntegerMinMax] >>> ***/
134
135#include <INTEGER.h>
136
137/*** <<< TYPE-DECLS [CN-IntegerMinMax] >>> ***/
138
139typedef INTEGER_t CN_IntegerMinMax_t;
140
141/*** <<< FUNC-DECLS [CN-IntegerMinMax] >>> ***/
142
143extern asn_TYPE_descriptor_t asn_DEF_CN_IntegerMinMax;
144asn_struct_free_f CN_IntegerMinMax_free;
145asn_struct_print_f CN_IntegerMinMax_print;
146asn_constr_check_f CN_IntegerMinMax_constraint;
147ber_type_decoder_f CN_IntegerMinMax_decode_ber;
148der_type_encoder_f CN_IntegerMinMax_encode_der;
149xer_type_decoder_f CN_IntegerMinMax_decode_xer;
150xer_type_encoder_f CN_IntegerMinMax_encode_xer;
151per_type_decoder_f CN_IntegerMinMax_decode_uper;
152
153/*** <<< CODE [CN-IntegerMinMax] >>> ***/
154
155int
156CN_IntegerMinMax_constraint(asn_TYPE_descriptor_t *td, const void *sptr,
157 asn_app_consume_bytes_f *app_errlog, void *app_key) {
158 const INTEGER_t *st = (const INTEGER_t *)sptr;
159
160 if(!sptr) {
161 _ASN_ERRLOG(app_errlog, app_key,
162 "%s: value not given (%s:%d)",
163 td->name, __FILE__, __LINE__);
164 return -1;
165 }
166
167
168 if(1 /* No applicable constraints whatsoever */) {
169 /* Nothing is here. See below */
170 }
171
172 /* Replace with underlying type checker */
173 td->check_constraints = asn_DEF_INTEGER.check_constraints;
174 return td->check_constraints(td, sptr, app_errlog, app_key);
175}
176
177/*
178 * This type is implemented using INTEGER,
179 * so here we adjust the DEF accordingly.
180 */
181static void
182CN_IntegerMinMax_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) {
183 td->free_struct = asn_DEF_INTEGER.free_struct;
184 td->print_struct = asn_DEF_INTEGER.print_struct;
185 td->ber_decoder = asn_DEF_INTEGER.ber_decoder;
186 td->der_encoder = asn_DEF_INTEGER.der_encoder;
187 td->xer_decoder = asn_DEF_INTEGER.xer_decoder;
188 td->xer_encoder = asn_DEF_INTEGER.xer_encoder;
189 td->uper_decoder = asn_DEF_INTEGER.uper_decoder;
190 if(!td->per_constraints)
191 td->per_constraints = asn_DEF_INTEGER.per_constraints;
192 td->elements = asn_DEF_INTEGER.elements;
193 td->elements_count = asn_DEF_INTEGER.elements_count;
194 td->specifics = asn_DEF_INTEGER.specifics;
195}
196
197void
198CN_IntegerMinMax_free(asn_TYPE_descriptor_t *td,
199 void *struct_ptr, int contents_only) {
200 CN_IntegerMinMax_1_inherit_TYPE_descriptor(td);
201 td->free_struct(td, struct_ptr, contents_only);
202}
203
204int
205CN_IntegerMinMax_print(asn_TYPE_descriptor_t *td, const void *struct_ptr,
206 int ilevel, asn_app_consume_bytes_f *cb, void *app_key) {
207 CN_IntegerMinMax_1_inherit_TYPE_descriptor(td);
208 return td->print_struct(td, struct_ptr, ilevel, cb, app_key);
209}
210
211asn_dec_rval_t
212CN_IntegerMinMax_decode_ber(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td,
213 void **structure, const void *bufptr, size_t size, int tag_mode) {
214 CN_IntegerMinMax_1_inherit_TYPE_descriptor(td);
215 return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, tag_mode);
216}
217
218asn_enc_rval_t
219CN_IntegerMinMax_encode_der(asn_TYPE_descriptor_t *td,
220 void *structure, int tag_mode, ber_tlv_tag_t tag,
221 asn_app_consume_bytes_f *cb, void *app_key) {
222 CN_IntegerMinMax_1_inherit_TYPE_descriptor(td);
223 return td->der_encoder(td, structure, tag_mode, tag, cb, app_key);
224}
225
226asn_dec_rval_t
227CN_IntegerMinMax_decode_xer(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td,
228 void **structure, const char *opt_mname, const void *bufptr, size_t size) {
229 CN_IntegerMinMax_1_inherit_TYPE_descriptor(td);
230 return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, size);
231}
232
233asn_enc_rval_t
234CN_IntegerMinMax_encode_xer(asn_TYPE_descriptor_t *td, void *structure,
235 int ilevel, enum xer_encoder_flags_e flags,
236 asn_app_consume_bytes_f *cb, void *app_key) {
237 CN_IntegerMinMax_1_inherit_TYPE_descriptor(td);
238 return td->xer_encoder(td, structure, ilevel, flags, cb, app_key);
239}
240
241asn_dec_rval_t
242CN_IntegerMinMax_decode_uper(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td,
243 asn_per_constraints_t *constraints, void **structure, asn_per_data_t *per_data) {
244 CN_IntegerMinMax_1_inherit_TYPE_descriptor(td);
245 return td->uper_decoder(opt_codec_ctx, td, constraints, structure, per_data);
246}
247
248
249/*** <<< STAT-DEFS [CN-IntegerMinMax] >>> ***/
250
251static ber_tlv_tag_t asn_DEF_CN_IntegerMinMax_tags_1[] = {
252 (ASN_TAG_CLASS_UNIVERSAL | (2 << 2))
253};
254static asn_per_constraints_t asn_PER_CN_IntegerMinMax_constr_1 = {
255 { APC_UNCONSTRAINED, -1, -1, 0, 0 },
256 { APC_UNCONSTRAINED, -1, -1, 0, 0 }
257};
258asn_TYPE_descriptor_t asn_DEF_CN_IntegerMinMax = {
259 "CN-IntegerMinMax",
260 "CN-IntegerMinMax",
261 CN_IntegerMinMax_free,
262 CN_IntegerMinMax_print,
263 CN_IntegerMinMax_constraint,
264 CN_IntegerMinMax_decode_ber,
265 CN_IntegerMinMax_encode_der,
266 CN_IntegerMinMax_decode_xer,
267 CN_IntegerMinMax_encode_xer,
268 CN_IntegerMinMax_decode_uper,
269 0, /* Use generic outmost tag fetcher */
270 asn_DEF_CN_IntegerMinMax_tags_1,
271 sizeof(asn_DEF_CN_IntegerMinMax_tags_1)
272 /sizeof(asn_DEF_CN_IntegerMinMax_tags_1[0]), /* 1 */
273 asn_DEF_CN_IntegerMinMax_tags_1, /* Same as above */
274 sizeof(asn_DEF_CN_IntegerMinMax_tags_1)
275 /sizeof(asn_DEF_CN_IntegerMinMax_tags_1[0]), /* 1 */
276 &asn_PER_CN_IntegerMinMax_constr_1,
277 0, 0, /* No members */
278 0 /* No specifics */
279};
280
281
282/*** <<< INCLUDES [CN-IntegerMinLow] >>> ***/
283
284#include <INTEGER.h>
285
286/*** <<< TYPE-DECLS [CN-IntegerMinLow] >>> ***/
287
288typedef INTEGER_t CN_IntegerMinLow_t;
289
290/*** <<< FUNC-DECLS [CN-IntegerMinLow] >>> ***/
291
292extern asn_TYPE_descriptor_t asn_DEF_CN_IntegerMinLow;
293asn_struct_free_f CN_IntegerMinLow_free;
294asn_struct_print_f CN_IntegerMinLow_print;
295asn_constr_check_f CN_IntegerMinLow_constraint;
296ber_type_decoder_f CN_IntegerMinLow_decode_ber;
297der_type_encoder_f CN_IntegerMinLow_encode_der;
298xer_type_decoder_f CN_IntegerMinLow_decode_xer;
299xer_type_encoder_f CN_IntegerMinLow_encode_xer;
300per_type_decoder_f CN_IntegerMinLow_decode_uper;
301
302/*** <<< CODE [CN-IntegerMinLow] >>> ***/
303
304int
305CN_IntegerMinLow_constraint(asn_TYPE_descriptor_t *td, const void *sptr,
306 asn_app_consume_bytes_f *app_errlog, void *app_key) {
307 const INTEGER_t *st = (const INTEGER_t *)sptr;
308 long value;
309
310 if(!sptr) {
311 _ASN_ERRLOG(app_errlog, app_key,
312 "%s: value not given (%s:%d)",
313 td->name, __FILE__, __LINE__);
314 return -1;
315 }
316
317 if(asn_INTEGER2long(st, &value)) {
318 _ASN_ERRLOG(app_errlog, app_key,
319 "%s: value too large (%s:%d)",
320 td->name, __FILE__, __LINE__);
321 return -1;
322 }
323
324 if((value <= 1)) {
325 /* Constraint check succeeded */
326 return 0;
327 } else {
328 _ASN_ERRLOG(app_errlog, app_key,
329 "%s: constraint failed (%s:%d)",
330 td->name, __FILE__, __LINE__);
331 return -1;
332 }
333}
334
335/*
336 * This type is implemented using INTEGER,
337 * so here we adjust the DEF accordingly.
338 */
339static void
340CN_IntegerMinLow_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) {
341 td->free_struct = asn_DEF_INTEGER.free_struct;
342 td->print_struct = asn_DEF_INTEGER.print_struct;
343 td->ber_decoder = asn_DEF_INTEGER.ber_decoder;
344 td->der_encoder = asn_DEF_INTEGER.der_encoder;
345 td->xer_decoder = asn_DEF_INTEGER.xer_decoder;
346 td->xer_encoder = asn_DEF_INTEGER.xer_encoder;
347 td->uper_decoder = asn_DEF_INTEGER.uper_decoder;
348 if(!td->per_constraints)
349 td->per_constraints = asn_DEF_INTEGER.per_constraints;
350 td->elements = asn_DEF_INTEGER.elements;
351 td->elements_count = asn_DEF_INTEGER.elements_count;
352 td->specifics = asn_DEF_INTEGER.specifics;
353}
354
355void
356CN_IntegerMinLow_free(asn_TYPE_descriptor_t *td,
357 void *struct_ptr, int contents_only) {
358 CN_IntegerMinLow_1_inherit_TYPE_descriptor(td);
359 td->free_struct(td, struct_ptr, contents_only);
360}
361
362int
363CN_IntegerMinLow_print(asn_TYPE_descriptor_t *td, const void *struct_ptr,
364 int ilevel, asn_app_consume_bytes_f *cb, void *app_key) {
365 CN_IntegerMinLow_1_inherit_TYPE_descriptor(td);
366 return td->print_struct(td, struct_ptr, ilevel, cb, app_key);
367}
368
369asn_dec_rval_t
370CN_IntegerMinLow_decode_ber(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td,
371 void **structure, const void *bufptr, size_t size, int tag_mode) {
372 CN_IntegerMinLow_1_inherit_TYPE_descriptor(td);
373 return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, tag_mode);
374}
375
376asn_enc_rval_t
377CN_IntegerMinLow_encode_der(asn_TYPE_descriptor_t *td,
378 void *structure, int tag_mode, ber_tlv_tag_t tag,
379 asn_app_consume_bytes_f *cb, void *app_key) {
380 CN_IntegerMinLow_1_inherit_TYPE_descriptor(td);
381 return td->der_encoder(td, structure, tag_mode, tag, cb, app_key);
382}
383
384asn_dec_rval_t
385CN_IntegerMinLow_decode_xer(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td,
386 void **structure, const char *opt_mname, const void *bufptr, size_t size) {
387 CN_IntegerMinLow_1_inherit_TYPE_descriptor(td);
388 return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, size);
389}
390
391asn_enc_rval_t
392CN_IntegerMinLow_encode_xer(asn_TYPE_descriptor_t *td, void *structure,
393 int ilevel, enum xer_encoder_flags_e flags,
394 asn_app_consume_bytes_f *cb, void *app_key) {
395 CN_IntegerMinLow_1_inherit_TYPE_descriptor(td);
396 return td->xer_encoder(td, structure, ilevel, flags, cb, app_key);
397}
398
399asn_dec_rval_t
400CN_IntegerMinLow_decode_uper(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td,
401 asn_per_constraints_t *constraints, void **structure, asn_per_data_t *per_data) {
402 CN_IntegerMinLow_1_inherit_TYPE_descriptor(td);
403 return td->uper_decoder(opt_codec_ctx, td, constraints, structure, per_data);
404}
405
406
407/*** <<< STAT-DEFS [CN-IntegerMinLow] >>> ***/
408
409static ber_tlv_tag_t asn_DEF_CN_IntegerMinLow_tags_1[] = {
410 (ASN_TAG_CLASS_UNIVERSAL | (2 << 2))
411};
412static asn_per_constraints_t asn_PER_CN_IntegerMinLow_constr_1 = {
413 { APC_UNCONSTRAINED, -1, -1, 0, 0 } /* (MIN..1) */,
414 { APC_UNCONSTRAINED, -1, -1, 0, 0 }
415};
416asn_TYPE_descriptor_t asn_DEF_CN_IntegerMinLow = {
417 "CN-IntegerMinLow",
418 "CN-IntegerMinLow",
419 CN_IntegerMinLow_free,
420 CN_IntegerMinLow_print,
421 CN_IntegerMinLow_constraint,
422 CN_IntegerMinLow_decode_ber,
423 CN_IntegerMinLow_encode_der,
424 CN_IntegerMinLow_decode_xer,
425 CN_IntegerMinLow_encode_xer,
426 CN_IntegerMinLow_decode_uper,
427 0, /* Use generic outmost tag fetcher */
428 asn_DEF_CN_IntegerMinLow_tags_1,
429 sizeof(asn_DEF_CN_IntegerMinLow_tags_1)
430 /sizeof(asn_DEF_CN_IntegerMinLow_tags_1[0]), /* 1 */
431 asn_DEF_CN_IntegerMinLow_tags_1, /* Same as above */
432 sizeof(asn_DEF_CN_IntegerMinLow_tags_1)
433 /sizeof(asn_DEF_CN_IntegerMinLow_tags_1[0]), /* 1 */
434 &asn_PER_CN_IntegerMinLow_constr_1,
435 0, 0, /* No members */
436 0 /* No specifics */
437};
438
439
440/*** <<< INCLUDES [NO-IntegerMinHigh] >>> ***/
441
442#include <INTEGER.h>
443
444/*** <<< TYPE-DECLS [NO-IntegerMinHigh] >>> ***/
445
446typedef INTEGER_t NO_IntegerMinHigh_t;
447
448/*** <<< FUNC-DECLS [NO-IntegerMinHigh] >>> ***/
449
450extern asn_TYPE_descriptor_t asn_DEF_NO_IntegerMinHigh;
451asn_struct_free_f NO_IntegerMinHigh_free;
452asn_struct_print_f NO_IntegerMinHigh_print;
453asn_constr_check_f NO_IntegerMinHigh_constraint;
454ber_type_decoder_f NO_IntegerMinHigh_decode_ber;
455der_type_encoder_f NO_IntegerMinHigh_encode_der;
456xer_type_decoder_f NO_IntegerMinHigh_decode_xer;
457xer_type_encoder_f NO_IntegerMinHigh_encode_xer;
458per_type_decoder_f NO_IntegerMinHigh_decode_uper;
459
460/*** <<< CODE [NO-IntegerMinHigh] >>> ***/
461
462int
463NO_IntegerMinHigh_constraint(asn_TYPE_descriptor_t *td, const void *sptr,
464 asn_app_consume_bytes_f *app_errlog, void *app_key) {
465 const INTEGER_t *st = (const INTEGER_t *)sptr;
466 long value;
467
468 if(!sptr) {
469 _ASN_ERRLOG(app_errlog, app_key,
470 "%s: value not given (%s:%d)",
471 td->name, __FILE__, __LINE__);
472 return -1;
473 }
474
475 if(asn_INTEGER2long(st, &value)) {
476 _ASN_ERRLOG(app_errlog, app_key,
477 "%s: value too large (%s:%d)",
478 td->name, __FILE__, __LINE__);
479 return -1;
480 }
481
482 if((value <= 3000000000)) {
483 /* Constraint check succeeded */
484 return 0;
485 } else {
486 _ASN_ERRLOG(app_errlog, app_key,
487 "%s: constraint failed (%s:%d)",
488 td->name, __FILE__, __LINE__);
489 return -1;
490 }
491}
492
493/*
494 * This type is implemented using INTEGER,
495 * so here we adjust the DEF accordingly.
496 */
497static void
498NO_IntegerMinHigh_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) {
499 td->free_struct = asn_DEF_INTEGER.free_struct;
500 td->print_struct = asn_DEF_INTEGER.print_struct;
501 td->ber_decoder = asn_DEF_INTEGER.ber_decoder;
502 td->der_encoder = asn_DEF_INTEGER.der_encoder;
503 td->xer_decoder = asn_DEF_INTEGER.xer_decoder;
504 td->xer_encoder = asn_DEF_INTEGER.xer_encoder;
505 td->uper_decoder = asn_DEF_INTEGER.uper_decoder;
506 if(!td->per_constraints)
507 td->per_constraints = asn_DEF_INTEGER.per_constraints;
508 td->elements = asn_DEF_INTEGER.elements;
509 td->elements_count = asn_DEF_INTEGER.elements_count;
510 td->specifics = asn_DEF_INTEGER.specifics;
511}
512
513void
514NO_IntegerMinHigh_free(asn_TYPE_descriptor_t *td,
515 void *struct_ptr, int contents_only) {
516 NO_IntegerMinHigh_1_inherit_TYPE_descriptor(td);
517 td->free_struct(td, struct_ptr, contents_only);
518}
519
520int
521NO_IntegerMinHigh_print(asn_TYPE_descriptor_t *td, const void *struct_ptr,
522 int ilevel, asn_app_consume_bytes_f *cb, void *app_key) {
523 NO_IntegerMinHigh_1_inherit_TYPE_descriptor(td);
524 return td->print_struct(td, struct_ptr, ilevel, cb, app_key);
525}
526
527asn_dec_rval_t
528NO_IntegerMinHigh_decode_ber(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td,
529 void **structure, const void *bufptr, size_t size, int tag_mode) {
530 NO_IntegerMinHigh_1_inherit_TYPE_descriptor(td);
531 return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, tag_mode);
532}
533
534asn_enc_rval_t
535NO_IntegerMinHigh_encode_der(asn_TYPE_descriptor_t *td,
536 void *structure, int tag_mode, ber_tlv_tag_t tag,
537 asn_app_consume_bytes_f *cb, void *app_key) {
538 NO_IntegerMinHigh_1_inherit_TYPE_descriptor(td);
539 return td->der_encoder(td, structure, tag_mode, tag, cb, app_key);
540}
541
542asn_dec_rval_t
543NO_IntegerMinHigh_decode_xer(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td,
544 void **structure, const char *opt_mname, const void *bufptr, size_t size) {
545 NO_IntegerMinHigh_1_inherit_TYPE_descriptor(td);
546 return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, size);
547}
548
549asn_enc_rval_t
550NO_IntegerMinHigh_encode_xer(asn_TYPE_descriptor_t *td, void *structure,
551 int ilevel, enum xer_encoder_flags_e flags,
552 asn_app_consume_bytes_f *cb, void *app_key) {
553 NO_IntegerMinHigh_1_inherit_TYPE_descriptor(td);
554 return td->xer_encoder(td, structure, ilevel, flags, cb, app_key);
555}
556
557asn_dec_rval_t
558NO_IntegerMinHigh_decode_uper(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td,
559 asn_per_constraints_t *constraints, void **structure, asn_per_data_t *per_data) {
560 NO_IntegerMinHigh_1_inherit_TYPE_descriptor(td);
561 return td->uper_decoder(opt_codec_ctx, td, constraints, structure, per_data);
562}
563
564
565/*** <<< STAT-DEFS [NO-IntegerMinHigh] >>> ***/
566
567static ber_tlv_tag_t asn_DEF_NO_IntegerMinHigh_tags_1[] = {
568 (ASN_TAG_CLASS_UNIVERSAL | (2 << 2))
569};
570static asn_per_constraints_t asn_PER_NO_IntegerMinHigh_constr_1 = {
571 { APC_UNCONSTRAINED, -1, -1, 0, 0 } /* (MIN..3000000000) */,
572 { APC_UNCONSTRAINED, -1, -1, 0, 0 }
573};
574asn_TYPE_descriptor_t asn_DEF_NO_IntegerMinHigh = {
575 "NO-IntegerMinHigh",
576 "NO-IntegerMinHigh",
577 NO_IntegerMinHigh_free,
578 NO_IntegerMinHigh_print,
579 NO_IntegerMinHigh_constraint,
580 NO_IntegerMinHigh_decode_ber,
581 NO_IntegerMinHigh_encode_der,
582 NO_IntegerMinHigh_decode_xer,
583 NO_IntegerMinHigh_encode_xer,
584 NO_IntegerMinHigh_decode_uper,
585 0, /* Use generic outmost tag fetcher */
586 asn_DEF_NO_IntegerMinHigh_tags_1,
587 sizeof(asn_DEF_NO_IntegerMinHigh_tags_1)
588 /sizeof(asn_DEF_NO_IntegerMinHigh_tags_1[0]), /* 1 */
589 asn_DEF_NO_IntegerMinHigh_tags_1, /* Same as above */
590 sizeof(asn_DEF_NO_IntegerMinHigh_tags_1)
591 /sizeof(asn_DEF_NO_IntegerMinHigh_tags_1[0]), /* 1 */
592 &asn_PER_NO_IntegerMinHigh_constr_1,
593 0, 0, /* No members */
594 0 /* No specifics */
595};
596
597
598/*** <<< INCLUDES [NO-IntegerLowHigh] >>> ***/
599
600#include <INTEGER.h>
601
602/*** <<< TYPE-DECLS [NO-IntegerLowHigh] >>> ***/
603
604typedef INTEGER_t NO_IntegerLowHigh_t;
605
606/*** <<< FUNC-DECLS [NO-IntegerLowHigh] >>> ***/
607
608extern asn_TYPE_descriptor_t asn_DEF_NO_IntegerLowHigh;
609asn_struct_free_f NO_IntegerLowHigh_free;
610asn_struct_print_f NO_IntegerLowHigh_print;
611asn_constr_check_f NO_IntegerLowHigh_constraint;
612ber_type_decoder_f NO_IntegerLowHigh_decode_ber;
613der_type_encoder_f NO_IntegerLowHigh_encode_der;
614xer_type_decoder_f NO_IntegerLowHigh_decode_xer;
615xer_type_encoder_f NO_IntegerLowHigh_encode_xer;
616per_type_decoder_f NO_IntegerLowHigh_decode_uper;
617
618/*** <<< CODE [NO-IntegerLowHigh] >>> ***/
619
620int
621NO_IntegerLowHigh_constraint(asn_TYPE_descriptor_t *td, const void *sptr,
622 asn_app_consume_bytes_f *app_errlog, void *app_key) {
623 const INTEGER_t *st = (const INTEGER_t *)sptr;
624 long value;
625
626 if(!sptr) {
627 _ASN_ERRLOG(app_errlog, app_key,
628 "%s: value not given (%s:%d)",
629 td->name, __FILE__, __LINE__);
630 return -1;
631 }
632
633 if(asn_INTEGER2long(st, &value)) {
634 _ASN_ERRLOG(app_errlog, app_key,
635 "%s: value too large (%s:%d)",
636 td->name, __FILE__, __LINE__);
637 return -1;
638 }
639
640 if((value >= 1 && value <= 3000000000)) {
641 /* Constraint check succeeded */
642 return 0;
643 } else {
644 _ASN_ERRLOG(app_errlog, app_key,
645 "%s: constraint failed (%s:%d)",
646 td->name, __FILE__, __LINE__);
647 return -1;
648 }
649}
650
651/*
652 * This type is implemented using INTEGER,
653 * so here we adjust the DEF accordingly.
654 */
655static void
656NO_IntegerLowHigh_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) {
657 td->free_struct = asn_DEF_INTEGER.free_struct;
658 td->print_struct = asn_DEF_INTEGER.print_struct;
659 td->ber_decoder = asn_DEF_INTEGER.ber_decoder;
660 td->der_encoder = asn_DEF_INTEGER.der_encoder;
661 td->xer_decoder = asn_DEF_INTEGER.xer_decoder;
662 td->xer_encoder = asn_DEF_INTEGER.xer_encoder;
663 td->uper_decoder = asn_DEF_INTEGER.uper_decoder;
664 if(!td->per_constraints)
665 td->per_constraints = asn_DEF_INTEGER.per_constraints;
666 td->elements = asn_DEF_INTEGER.elements;
667 td->elements_count = asn_DEF_INTEGER.elements_count;
668 td->specifics = asn_DEF_INTEGER.specifics;
669}
670
671void
672NO_IntegerLowHigh_free(asn_TYPE_descriptor_t *td,
673 void *struct_ptr, int contents_only) {
674 NO_IntegerLowHigh_1_inherit_TYPE_descriptor(td);
675 td->free_struct(td, struct_ptr, contents_only);
676}
677
678int
679NO_IntegerLowHigh_print(asn_TYPE_descriptor_t *td, const void *struct_ptr,
680 int ilevel, asn_app_consume_bytes_f *cb, void *app_key) {
681 NO_IntegerLowHigh_1_inherit_TYPE_descriptor(td);
682 return td->print_struct(td, struct_ptr, ilevel, cb, app_key);
683}
684
685asn_dec_rval_t
686NO_IntegerLowHigh_decode_ber(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td,
687 void **structure, const void *bufptr, size_t size, int tag_mode) {
688 NO_IntegerLowHigh_1_inherit_TYPE_descriptor(td);
689 return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, tag_mode);
690}
691
692asn_enc_rval_t
693NO_IntegerLowHigh_encode_der(asn_TYPE_descriptor_t *td,
694 void *structure, int tag_mode, ber_tlv_tag_t tag,
695 asn_app_consume_bytes_f *cb, void *app_key) {
696 NO_IntegerLowHigh_1_inherit_TYPE_descriptor(td);
697 return td->der_encoder(td, structure, tag_mode, tag, cb, app_key);
698}
699
700asn_dec_rval_t
701NO_IntegerLowHigh_decode_xer(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td,
702 void **structure, const char *opt_mname, const void *bufptr, size_t size) {
703 NO_IntegerLowHigh_1_inherit_TYPE_descriptor(td);
704 return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, size);
705}
706
707asn_enc_rval_t
708NO_IntegerLowHigh_encode_xer(asn_TYPE_descriptor_t *td, void *structure,
709 int ilevel, enum xer_encoder_flags_e flags,
710 asn_app_consume_bytes_f *cb, void *app_key) {
711 NO_IntegerLowHigh_1_inherit_TYPE_descriptor(td);
712 return td->xer_encoder(td, structure, ilevel, flags, cb, app_key);
713}
714
715asn_dec_rval_t
716NO_IntegerLowHigh_decode_uper(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td,
717 asn_per_constraints_t *constraints, void **structure, asn_per_data_t *per_data) {
718 NO_IntegerLowHigh_1_inherit_TYPE_descriptor(td);
719 return td->uper_decoder(opt_codec_ctx, td, constraints, structure, per_data);
720}
721
722
723/*** <<< STAT-DEFS [NO-IntegerLowHigh] >>> ***/
724
725static ber_tlv_tag_t asn_DEF_NO_IntegerLowHigh_tags_1[] = {
726 (ASN_TAG_CLASS_UNIVERSAL | (2 << 2))
727};
728static asn_per_constraints_t asn_PER_NO_IntegerLowHigh_constr_1 = {
729 { APC_CONSTRAINED, 32, -1, 1, 3000000000 } /* (1..3000000000) */,
730 { APC_UNCONSTRAINED, -1, -1, 0, 0 }
731};
732asn_TYPE_descriptor_t asn_DEF_NO_IntegerLowHigh = {
733 "NO-IntegerLowHigh",
734 "NO-IntegerLowHigh",
735 NO_IntegerLowHigh_free,
736 NO_IntegerLowHigh_print,
737 NO_IntegerLowHigh_constraint,
738 NO_IntegerLowHigh_decode_ber,
739 NO_IntegerLowHigh_encode_der,
740 NO_IntegerLowHigh_decode_xer,
741 NO_IntegerLowHigh_encode_xer,
742 NO_IntegerLowHigh_decode_uper,
743 0, /* Use generic outmost tag fetcher */
744 asn_DEF_NO_IntegerLowHigh_tags_1,
745 sizeof(asn_DEF_NO_IntegerLowHigh_tags_1)
746 /sizeof(asn_DEF_NO_IntegerLowHigh_tags_1[0]), /* 1 */
747 asn_DEF_NO_IntegerLowHigh_tags_1, /* Same as above */
748 sizeof(asn_DEF_NO_IntegerLowHigh_tags_1)
749 /sizeof(asn_DEF_NO_IntegerLowHigh_tags_1[0]), /* 1 */
750 &asn_PER_NO_IntegerLowHigh_constr_1,
751 0, 0, /* No members */
752 0 /* No specifics */
753};
754
755
756/*** <<< INCLUDES [CN-IntegerLowMax] >>> ***/
757
758#include <INTEGER.h>
759
760/*** <<< TYPE-DECLS [CN-IntegerLowMax] >>> ***/
761
762typedef INTEGER_t CN_IntegerLowMax_t;
763
764/*** <<< FUNC-DECLS [CN-IntegerLowMax] >>> ***/
765
766extern asn_TYPE_descriptor_t asn_DEF_CN_IntegerLowMax;
767asn_struct_free_f CN_IntegerLowMax_free;
768asn_struct_print_f CN_IntegerLowMax_print;
769asn_constr_check_f CN_IntegerLowMax_constraint;
770ber_type_decoder_f CN_IntegerLowMax_decode_ber;
771der_type_encoder_f CN_IntegerLowMax_encode_der;
772xer_type_decoder_f CN_IntegerLowMax_decode_xer;
773xer_type_encoder_f CN_IntegerLowMax_encode_xer;
774per_type_decoder_f CN_IntegerLowMax_decode_uper;
775
776/*** <<< CODE [CN-IntegerLowMax] >>> ***/
777
778int
779CN_IntegerLowMax_constraint(asn_TYPE_descriptor_t *td, const void *sptr,
780 asn_app_consume_bytes_f *app_errlog, void *app_key) {
781 const INTEGER_t *st = (const INTEGER_t *)sptr;
782 long value;
783
784 if(!sptr) {
785 _ASN_ERRLOG(app_errlog, app_key,
786 "%s: value not given (%s:%d)",
787 td->name, __FILE__, __LINE__);
788 return -1;
789 }
790
791 if(asn_INTEGER2long(st, &value)) {
792 _ASN_ERRLOG(app_errlog, app_key,
793 "%s: value too large (%s:%d)",
794 td->name, __FILE__, __LINE__);
795 return -1;
796 }
797
798 if((value >= 1)) {
799 /* Constraint check succeeded */
800 return 0;
801 } else {
802 _ASN_ERRLOG(app_errlog, app_key,
803 "%s: constraint failed (%s:%d)",
804 td->name, __FILE__, __LINE__);
805 return -1;
806 }
807}
808
809/*
810 * This type is implemented using INTEGER,
811 * so here we adjust the DEF accordingly.
812 */
813static void
814CN_IntegerLowMax_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) {
815 td->free_struct = asn_DEF_INTEGER.free_struct;
816 td->print_struct = asn_DEF_INTEGER.print_struct;
817 td->ber_decoder = asn_DEF_INTEGER.ber_decoder;
818 td->der_encoder = asn_DEF_INTEGER.der_encoder;
819 td->xer_decoder = asn_DEF_INTEGER.xer_decoder;
820 td->xer_encoder = asn_DEF_INTEGER.xer_encoder;
821 td->uper_decoder = asn_DEF_INTEGER.uper_decoder;
822 if(!td->per_constraints)
823 td->per_constraints = asn_DEF_INTEGER.per_constraints;
824 td->elements = asn_DEF_INTEGER.elements;
825 td->elements_count = asn_DEF_INTEGER.elements_count;
826 td->specifics = asn_DEF_INTEGER.specifics;
827}
828
829void
830CN_IntegerLowMax_free(asn_TYPE_descriptor_t *td,
831 void *struct_ptr, int contents_only) {
832 CN_IntegerLowMax_1_inherit_TYPE_descriptor(td);
833 td->free_struct(td, struct_ptr, contents_only);
834}
835
836int
837CN_IntegerLowMax_print(asn_TYPE_descriptor_t *td, const void *struct_ptr,
838 int ilevel, asn_app_consume_bytes_f *cb, void *app_key) {
839 CN_IntegerLowMax_1_inherit_TYPE_descriptor(td);
840 return td->print_struct(td, struct_ptr, ilevel, cb, app_key);
841}
842
843asn_dec_rval_t
844CN_IntegerLowMax_decode_ber(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td,
845 void **structure, const void *bufptr, size_t size, int tag_mode) {
846 CN_IntegerLowMax_1_inherit_TYPE_descriptor(td);
847 return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, tag_mode);
848}
849
850asn_enc_rval_t
851CN_IntegerLowMax_encode_der(asn_TYPE_descriptor_t *td,
852 void *structure, int tag_mode, ber_tlv_tag_t tag,
853 asn_app_consume_bytes_f *cb, void *app_key) {
854 CN_IntegerLowMax_1_inherit_TYPE_descriptor(td);
855 return td->der_encoder(td, structure, tag_mode, tag, cb, app_key);
856}
857
858asn_dec_rval_t
859CN_IntegerLowMax_decode_xer(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td,
860 void **structure, const char *opt_mname, const void *bufptr, size_t size) {
861 CN_IntegerLowMax_1_inherit_TYPE_descriptor(td);
862 return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, size);
863}
864
865asn_enc_rval_t
866CN_IntegerLowMax_encode_xer(asn_TYPE_descriptor_t *td, void *structure,
867 int ilevel, enum xer_encoder_flags_e flags,
868 asn_app_consume_bytes_f *cb, void *app_key) {
869 CN_IntegerLowMax_1_inherit_TYPE_descriptor(td);
870 return td->xer_encoder(td, structure, ilevel, flags, cb, app_key);
871}
872
873asn_dec_rval_t
874CN_IntegerLowMax_decode_uper(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td,
875 asn_per_constraints_t *constraints, void **structure, asn_per_data_t *per_data) {
876 CN_IntegerLowMax_1_inherit_TYPE_descriptor(td);
877 return td->uper_decoder(opt_codec_ctx, td, constraints, structure, per_data);
878}
879
880
881/*** <<< STAT-DEFS [CN-IntegerLowMax] >>> ***/
882
883static ber_tlv_tag_t asn_DEF_CN_IntegerLowMax_tags_1[] = {
884 (ASN_TAG_CLASS_UNIVERSAL | (2 << 2))
885};
886static asn_per_constraints_t asn_PER_CN_IntegerLowMax_constr_1 = {
887 { APC_SEMI_CONSTRAINED, -1, -1, 1, 0 } /* (1..MAX) */,
888 { APC_UNCONSTRAINED, -1, -1, 0, 0 }
889};
890asn_TYPE_descriptor_t asn_DEF_CN_IntegerLowMax = {
891 "CN-IntegerLowMax",
892 "CN-IntegerLowMax",
893 CN_IntegerLowMax_free,
894 CN_IntegerLowMax_print,
895 CN_IntegerLowMax_constraint,
896 CN_IntegerLowMax_decode_ber,
897 CN_IntegerLowMax_encode_der,
898 CN_IntegerLowMax_decode_xer,
899 CN_IntegerLowMax_encode_xer,
900 CN_IntegerLowMax_decode_uper,
901 0, /* Use generic outmost tag fetcher */
902 asn_DEF_CN_IntegerLowMax_tags_1,
903 sizeof(asn_DEF_CN_IntegerLowMax_tags_1)
904 /sizeof(asn_DEF_CN_IntegerLowMax_tags_1[0]), /* 1 */
905 asn_DEF_CN_IntegerLowMax_tags_1, /* Same as above */
906 sizeof(asn_DEF_CN_IntegerLowMax_tags_1)
907 /sizeof(asn_DEF_CN_IntegerLowMax_tags_1[0]), /* 1 */
908 &asn_PER_CN_IntegerLowMax_constr_1,
909 0, 0, /* No members */
910 0 /* No specifics */
911};
912
913
914/*** <<< INCLUDES [NO-IntegerHighMax] >>> ***/
915
916#include <INTEGER.h>
917
918/*** <<< TYPE-DECLS [NO-IntegerHighMax] >>> ***/
919
920typedef INTEGER_t NO_IntegerHighMax_t;
921
922/*** <<< FUNC-DECLS [NO-IntegerHighMax] >>> ***/
923
924extern asn_TYPE_descriptor_t asn_DEF_NO_IntegerHighMax;
925asn_struct_free_f NO_IntegerHighMax_free;
926asn_struct_print_f NO_IntegerHighMax_print;
927asn_constr_check_f NO_IntegerHighMax_constraint;
928ber_type_decoder_f NO_IntegerHighMax_decode_ber;
929der_type_encoder_f NO_IntegerHighMax_encode_der;
930xer_type_decoder_f NO_IntegerHighMax_decode_xer;
931xer_type_encoder_f NO_IntegerHighMax_encode_xer;
932per_type_decoder_f NO_IntegerHighMax_decode_uper;
933
934/*** <<< CODE [NO-IntegerHighMax] >>> ***/
935
936int
937NO_IntegerHighMax_constraint(asn_TYPE_descriptor_t *td, const void *sptr,
938 asn_app_consume_bytes_f *app_errlog, void *app_key) {
939 const INTEGER_t *st = (const INTEGER_t *)sptr;
940 long value;
941
942 if(!sptr) {
943 _ASN_ERRLOG(app_errlog, app_key,
944 "%s: value not given (%s:%d)",
945 td->name, __FILE__, __LINE__);
946 return -1;
947 }
948
949 if(asn_INTEGER2long(st, &value)) {
950 _ASN_ERRLOG(app_errlog, app_key,
951 "%s: value too large (%s:%d)",
952 td->name, __FILE__, __LINE__);
953 return -1;
954 }
955
956 if((value >= 3000000000)) {
957 /* Constraint check succeeded */
958 return 0;
959 } else {
960 _ASN_ERRLOG(app_errlog, app_key,
961 "%s: constraint failed (%s:%d)",
962 td->name, __FILE__, __LINE__);
963 return -1;
964 }
965}
966
967/*
968 * This type is implemented using INTEGER,
969 * so here we adjust the DEF accordingly.
970 */
971static void
972NO_IntegerHighMax_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) {
973 td->free_struct = asn_DEF_INTEGER.free_struct;
974 td->print_struct = asn_DEF_INTEGER.print_struct;
975 td->ber_decoder = asn_DEF_INTEGER.ber_decoder;
976 td->der_encoder = asn_DEF_INTEGER.der_encoder;
977 td->xer_decoder = asn_DEF_INTEGER.xer_decoder;
978 td->xer_encoder = asn_DEF_INTEGER.xer_encoder;
979 td->uper_decoder = asn_DEF_INTEGER.uper_decoder;
980 if(!td->per_constraints)
981 td->per_constraints = asn_DEF_INTEGER.per_constraints;
982 td->elements = asn_DEF_INTEGER.elements;
983 td->elements_count = asn_DEF_INTEGER.elements_count;
984 td->specifics = asn_DEF_INTEGER.specifics;
985}
986
987void
988NO_IntegerHighMax_free(asn_TYPE_descriptor_t *td,
989 void *struct_ptr, int contents_only) {
990 NO_IntegerHighMax_1_inherit_TYPE_descriptor(td);
991 td->free_struct(td, struct_ptr, contents_only);
992}
993
994int
995NO_IntegerHighMax_print(asn_TYPE_descriptor_t *td, const void *struct_ptr,
996 int ilevel, asn_app_consume_bytes_f *cb, void *app_key) {
997 NO_IntegerHighMax_1_inherit_TYPE_descriptor(td);
998 return td->print_struct(td, struct_ptr, ilevel, cb, app_key);
999}
1000
1001asn_dec_rval_t
1002NO_IntegerHighMax_decode_ber(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td,
1003 void **structure, const void *bufptr, size_t size, int tag_mode) {
1004 NO_IntegerHighMax_1_inherit_TYPE_descriptor(td);
1005 return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, tag_mode);
1006}
1007
1008asn_enc_rval_t
1009NO_IntegerHighMax_encode_der(asn_TYPE_descriptor_t *td,
1010 void *structure, int tag_mode, ber_tlv_tag_t tag,
1011 asn_app_consume_bytes_f *cb, void *app_key) {
1012 NO_IntegerHighMax_1_inherit_TYPE_descriptor(td);
1013 return td->der_encoder(td, structure, tag_mode, tag, cb, app_key);
1014}
1015
1016asn_dec_rval_t
1017NO_IntegerHighMax_decode_xer(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td,
1018 void **structure, const char *opt_mname, const void *bufptr, size_t size) {
1019 NO_IntegerHighMax_1_inherit_TYPE_descriptor(td);
1020 return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, size);
1021}
1022
1023asn_enc_rval_t
1024NO_IntegerHighMax_encode_xer(asn_TYPE_descriptor_t *td, void *structure,
1025 int ilevel, enum xer_encoder_flags_e flags,
1026 asn_app_consume_bytes_f *cb, void *app_key) {
1027 NO_IntegerHighMax_1_inherit_TYPE_descriptor(td);
1028 return td->xer_encoder(td, structure, ilevel, flags, cb, app_key);
1029}
1030
1031asn_dec_rval_t
1032NO_IntegerHighMax_decode_uper(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td,
1033 asn_per_constraints_t *constraints, void **structure, asn_per_data_t *per_data) {
1034 NO_IntegerHighMax_1_inherit_TYPE_descriptor(td);
1035 return td->uper_decoder(opt_codec_ctx, td, constraints, structure, per_data);
1036}
1037
1038
1039/*** <<< STAT-DEFS [NO-IntegerHighMax] >>> ***/
1040
1041static ber_tlv_tag_t asn_DEF_NO_IntegerHighMax_tags_1[] = {
1042 (ASN_TAG_CLASS_UNIVERSAL | (2 << 2))
1043};
1044static asn_per_constraints_t asn_PER_NO_IntegerHighMax_constr_1 = {
1045 { APC_SEMI_CONSTRAINED, -1, -1, 3000000000, 0 } /* (3000000000..MAX) */,
1046 { APC_UNCONSTRAINED, -1, -1, 0, 0 }
1047};
1048asn_TYPE_descriptor_t asn_DEF_NO_IntegerHighMax = {
1049 "NO-IntegerHighMax",
1050 "NO-IntegerHighMax",
1051 NO_IntegerHighMax_free,
1052 NO_IntegerHighMax_print,
1053 NO_IntegerHighMax_constraint,
1054 NO_IntegerHighMax_decode_ber,
1055 NO_IntegerHighMax_encode_der,
1056 NO_IntegerHighMax_decode_xer,
1057 NO_IntegerHighMax_encode_xer,
1058 NO_IntegerHighMax_decode_uper,
1059 0, /* Use generic outmost tag fetcher */
1060 asn_DEF_NO_IntegerHighMax_tags_1,
1061 sizeof(asn_DEF_NO_IntegerHighMax_tags_1)
1062 /sizeof(asn_DEF_NO_IntegerHighMax_tags_1[0]), /* 1 */
1063 asn_DEF_NO_IntegerHighMax_tags_1, /* Same as above */
1064 sizeof(asn_DEF_NO_IntegerHighMax_tags_1)
1065 /sizeof(asn_DEF_NO_IntegerHighMax_tags_1[0]), /* 1 */
1066 &asn_PER_NO_IntegerHighMax_constr_1,
1067 0, 0, /* No members */
1068 0 /* No specifics */
1069};
1070
1071
1072/*** <<< INCLUDES [NO-IntegerLowestMax] >>> ***/
1073
1074#include <INTEGER.h>
1075
1076/*** <<< TYPE-DECLS [NO-IntegerLowestMax] >>> ***/
1077
1078typedef INTEGER_t NO_IntegerLowestMax_t;
1079
1080/*** <<< FUNC-DECLS [NO-IntegerLowestMax] >>> ***/
1081
1082extern asn_TYPE_descriptor_t asn_DEF_NO_IntegerLowestMax;
1083asn_struct_free_f NO_IntegerLowestMax_free;
1084asn_struct_print_f NO_IntegerLowestMax_print;
1085asn_constr_check_f NO_IntegerLowestMax_constraint;
1086ber_type_decoder_f NO_IntegerLowestMax_decode_ber;
1087der_type_encoder_f NO_IntegerLowestMax_encode_der;
1088xer_type_decoder_f NO_IntegerLowestMax_decode_xer;
1089xer_type_encoder_f NO_IntegerLowestMax_encode_xer;
1090per_type_decoder_f NO_IntegerLowestMax_decode_uper;
1091
1092/*** <<< CODE [NO-IntegerLowestMax] >>> ***/
1093
1094int
1095NO_IntegerLowestMax_constraint(asn_TYPE_descriptor_t *td, const void *sptr,
1096 asn_app_consume_bytes_f *app_errlog, void *app_key) {
1097 const INTEGER_t *st = (const INTEGER_t *)sptr;
1098 long value;
1099
1100 if(!sptr) {
1101 _ASN_ERRLOG(app_errlog, app_key,
1102 "%s: value not given (%s:%d)",
1103 td->name, __FILE__, __LINE__);
1104 return -1;
1105 }
1106
1107 if(asn_INTEGER2long(st, &value)) {
1108 _ASN_ERRLOG(app_errlog, app_key,
1109 "%s: value too large (%s:%d)",
1110 td->name, __FILE__, __LINE__);
1111 return -1;
1112 }
1113
1114 if((value >= -3000000000)) {
1115 /* Constraint check succeeded */
1116 return 0;
1117 } else {
1118 _ASN_ERRLOG(app_errlog, app_key,
1119 "%s: constraint failed (%s:%d)",
1120 td->name, __FILE__, __LINE__);
1121 return -1;
1122 }
1123}
1124
1125/*
1126 * This type is implemented using INTEGER,
1127 * so here we adjust the DEF accordingly.
1128 */
1129static void
1130NO_IntegerLowestMax_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) {
1131 td->free_struct = asn_DEF_INTEGER.free_struct;
1132 td->print_struct = asn_DEF_INTEGER.print_struct;
1133 td->ber_decoder = asn_DEF_INTEGER.ber_decoder;
1134 td->der_encoder = asn_DEF_INTEGER.der_encoder;
1135 td->xer_decoder = asn_DEF_INTEGER.xer_decoder;
1136 td->xer_encoder = asn_DEF_INTEGER.xer_encoder;
1137 td->uper_decoder = asn_DEF_INTEGER.uper_decoder;
1138 if(!td->per_constraints)
1139 td->per_constraints = asn_DEF_INTEGER.per_constraints;
1140 td->elements = asn_DEF_INTEGER.elements;
1141 td->elements_count = asn_DEF_INTEGER.elements_count;
1142 td->specifics = asn_DEF_INTEGER.specifics;
1143}
1144
1145void
1146NO_IntegerLowestMax_free(asn_TYPE_descriptor_t *td,
1147 void *struct_ptr, int contents_only) {
1148 NO_IntegerLowestMax_1_inherit_TYPE_descriptor(td);
1149 td->free_struct(td, struct_ptr, contents_only);
1150}
1151
1152int
1153NO_IntegerLowestMax_print(asn_TYPE_descriptor_t *td, const void *struct_ptr,
1154 int ilevel, asn_app_consume_bytes_f *cb, void *app_key) {
1155 NO_IntegerLowestMax_1_inherit_TYPE_descriptor(td);
1156 return td->print_struct(td, struct_ptr, ilevel, cb, app_key);
1157}
1158
1159asn_dec_rval_t
1160NO_IntegerLowestMax_decode_ber(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td,
1161 void **structure, const void *bufptr, size_t size, int tag_mode) {
1162 NO_IntegerLowestMax_1_inherit_TYPE_descriptor(td);
1163 return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, tag_mode);
1164}
1165
1166asn_enc_rval_t
1167NO_IntegerLowestMax_encode_der(asn_TYPE_descriptor_t *td,
1168 void *structure, int tag_mode, ber_tlv_tag_t tag,
1169 asn_app_consume_bytes_f *cb, void *app_key) {
1170 NO_IntegerLowestMax_1_inherit_TYPE_descriptor(td);
1171 return td->der_encoder(td, structure, tag_mode, tag, cb, app_key);
1172}
1173
1174asn_dec_rval_t
1175NO_IntegerLowestMax_decode_xer(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td,
1176 void **structure, const char *opt_mname, const void *bufptr, size_t size) {
1177 NO_IntegerLowestMax_1_inherit_TYPE_descriptor(td);
1178 return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, size);
1179}
1180
1181asn_enc_rval_t
1182NO_IntegerLowestMax_encode_xer(asn_TYPE_descriptor_t *td, void *structure,
1183 int ilevel, enum xer_encoder_flags_e flags,
1184 asn_app_consume_bytes_f *cb, void *app_key) {
1185 NO_IntegerLowestMax_1_inherit_TYPE_descriptor(td);
1186 return td->xer_encoder(td, structure, ilevel, flags, cb, app_key);
1187}
1188
1189asn_dec_rval_t
1190NO_IntegerLowestMax_decode_uper(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td,
1191 asn_per_constraints_t *constraints, void **structure, asn_per_data_t *per_data) {
1192 NO_IntegerLowestMax_1_inherit_TYPE_descriptor(td);
1193 return td->uper_decoder(opt_codec_ctx, td, constraints, structure, per_data);
1194}
1195
1196
1197/*** <<< STAT-DEFS [NO-IntegerLowestMax] >>> ***/
1198
1199static ber_tlv_tag_t asn_DEF_NO_IntegerLowestMax_tags_1[] = {
1200 (ASN_TAG_CLASS_UNIVERSAL | (2 << 2))
1201};
1202static asn_per_constraints_t asn_PER_NO_IntegerLowestMax_constr_1 = {
1203 { APC_SEMI_CONSTRAINED, -1, -1, -3000000000, 0 } /* (-3000000000..MAX) */,
1204 { APC_UNCONSTRAINED, -1, -1, 0, 0 }
1205};
1206asn_TYPE_descriptor_t asn_DEF_NO_IntegerLowestMax = {
1207 "NO-IntegerLowestMax",
1208 "NO-IntegerLowestMax",
1209 NO_IntegerLowestMax_free,
1210 NO_IntegerLowestMax_print,
1211 NO_IntegerLowestMax_constraint,
1212 NO_IntegerLowestMax_decode_ber,
1213 NO_IntegerLowestMax_encode_der,
1214 NO_IntegerLowestMax_decode_xer,
1215 NO_IntegerLowestMax_encode_xer,
1216 NO_IntegerLowestMax_decode_uper,
1217 0, /* Use generic outmost tag fetcher */
1218 asn_DEF_NO_IntegerLowestMax_tags_1,
1219 sizeof(asn_DEF_NO_IntegerLowestMax_tags_1)
1220 /sizeof(asn_DEF_NO_IntegerLowestMax_tags_1[0]), /* 1 */
1221 asn_DEF_NO_IntegerLowestMax_tags_1, /* Same as above */
1222 sizeof(asn_DEF_NO_IntegerLowestMax_tags_1)
1223 /sizeof(asn_DEF_NO_IntegerLowestMax_tags_1[0]), /* 1 */
1224 &asn_PER_NO_IntegerLowestMax_constr_1,
1225 0, 0, /* No members */
1226 0 /* No specifics */
1227};
1228
1229
1230/*** <<< INCLUDES [NO-IntegerOutRange] >>> ***/
1231
1232#include <INTEGER.h>
1233
1234/*** <<< TYPE-DECLS [NO-IntegerOutRange] >>> ***/
1235
1236typedef INTEGER_t NO_IntegerOutRange_t;
1237
1238/*** <<< FUNC-DECLS [NO-IntegerOutRange] >>> ***/
1239
1240extern asn_TYPE_descriptor_t asn_DEF_NO_IntegerOutRange;
1241asn_struct_free_f NO_IntegerOutRange_free;
1242asn_struct_print_f NO_IntegerOutRange_print;
1243asn_constr_check_f NO_IntegerOutRange_constraint;
1244ber_type_decoder_f NO_IntegerOutRange_decode_ber;
1245der_type_encoder_f NO_IntegerOutRange_encode_der;
1246xer_type_decoder_f NO_IntegerOutRange_decode_xer;
1247xer_type_encoder_f NO_IntegerOutRange_encode_xer;
1248per_type_decoder_f NO_IntegerOutRange_decode_uper;
1249
1250/*** <<< CODE [NO-IntegerOutRange] >>> ***/
1251
1252int
1253NO_IntegerOutRange_constraint(asn_TYPE_descriptor_t *td, const void *sptr,
1254 asn_app_consume_bytes_f *app_errlog, void *app_key) {
1255 const INTEGER_t *st = (const INTEGER_t *)sptr;
1256 long value;
1257
1258 if(!sptr) {
1259 _ASN_ERRLOG(app_errlog, app_key,
1260 "%s: value not given (%s:%d)",
1261 td->name, __FILE__, __LINE__);
1262 return -1;
1263 }
1264
1265 if(asn_INTEGER2long(st, &value)) {
1266 _ASN_ERRLOG(app_errlog, app_key,
1267 "%s: value too large (%s:%d)",
1268 td->name, __FILE__, __LINE__);
1269 return -1;
1270 }
1271
1272 if((value >= 3000000000 && value <= 3000000001)) {
1273 /* Constraint check succeeded */
1274 return 0;
1275 } else {
1276 _ASN_ERRLOG(app_errlog, app_key,
1277 "%s: constraint failed (%s:%d)",
1278 td->name, __FILE__, __LINE__);
1279 return -1;
1280 }
1281}
1282
1283/*
1284 * This type is implemented using INTEGER,
1285 * so here we adjust the DEF accordingly.
1286 */
1287static void
1288NO_IntegerOutRange_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) {
1289 td->free_struct = asn_DEF_INTEGER.free_struct;
1290 td->print_struct = asn_DEF_INTEGER.print_struct;
1291 td->ber_decoder = asn_DEF_INTEGER.ber_decoder;
1292 td->der_encoder = asn_DEF_INTEGER.der_encoder;
1293 td->xer_decoder = asn_DEF_INTEGER.xer_decoder;
1294 td->xer_encoder = asn_DEF_INTEGER.xer_encoder;
1295 td->uper_decoder = asn_DEF_INTEGER.uper_decoder;
1296 if(!td->per_constraints)
1297 td->per_constraints = asn_DEF_INTEGER.per_constraints;
1298 td->elements = asn_DEF_INTEGER.elements;
1299 td->elements_count = asn_DEF_INTEGER.elements_count;
1300 td->specifics = asn_DEF_INTEGER.specifics;
1301}
1302
1303void
1304NO_IntegerOutRange_free(asn_TYPE_descriptor_t *td,
1305 void *struct_ptr, int contents_only) {
1306 NO_IntegerOutRange_1_inherit_TYPE_descriptor(td);
1307 td->free_struct(td, struct_ptr, contents_only);
1308}
1309
1310int
1311NO_IntegerOutRange_print(asn_TYPE_descriptor_t *td, const void *struct_ptr,
1312 int ilevel, asn_app_consume_bytes_f *cb, void *app_key) {
1313 NO_IntegerOutRange_1_inherit_TYPE_descriptor(td);
1314 return td->print_struct(td, struct_ptr, ilevel, cb, app_key);
1315}
1316
1317asn_dec_rval_t
1318NO_IntegerOutRange_decode_ber(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td,
1319 void **structure, const void *bufptr, size_t size, int tag_mode) {
1320 NO_IntegerOutRange_1_inherit_TYPE_descriptor(td);
1321 return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, tag_mode);
1322}
1323
1324asn_enc_rval_t
1325NO_IntegerOutRange_encode_der(asn_TYPE_descriptor_t *td,
1326 void *structure, int tag_mode, ber_tlv_tag_t tag,
1327 asn_app_consume_bytes_f *cb, void *app_key) {
1328 NO_IntegerOutRange_1_inherit_TYPE_descriptor(td);
1329 return td->der_encoder(td, structure, tag_mode, tag, cb, app_key);
1330}
1331
1332asn_dec_rval_t
1333NO_IntegerOutRange_decode_xer(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td,
1334 void **structure, const char *opt_mname, const void *bufptr, size_t size) {
1335 NO_IntegerOutRange_1_inherit_TYPE_descriptor(td);
1336 return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, size);
1337}
1338
1339asn_enc_rval_t
1340NO_IntegerOutRange_encode_xer(asn_TYPE_descriptor_t *td, void *structure,
1341 int ilevel, enum xer_encoder_flags_e flags,
1342 asn_app_consume_bytes_f *cb, void *app_key) {
1343 NO_IntegerOutRange_1_inherit_TYPE_descriptor(td);
1344 return td->xer_encoder(td, structure, ilevel, flags, cb, app_key);
1345}
1346
1347asn_dec_rval_t
1348NO_IntegerOutRange_decode_uper(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td,
1349 asn_per_constraints_t *constraints, void **structure, asn_per_data_t *per_data) {
1350 NO_IntegerOutRange_1_inherit_TYPE_descriptor(td);
1351 return td->uper_decoder(opt_codec_ctx, td, constraints, structure, per_data);
1352}
1353
1354
1355/*** <<< STAT-DEFS [NO-IntegerOutRange] >>> ***/
1356
1357static ber_tlv_tag_t asn_DEF_NO_IntegerOutRange_tags_1[] = {
1358 (ASN_TAG_CLASS_UNIVERSAL | (2 << 2))
1359};
1360static asn_per_constraints_t asn_PER_NO_IntegerOutRange_constr_1 = {
1361 { APC_CONSTRAINED, 1, -1, 3000000000, 3000000001 } /* (3000000000..3000000001) */,
1362 { APC_UNCONSTRAINED, -1, -1, 0, 0 }
1363};
1364asn_TYPE_descriptor_t asn_DEF_NO_IntegerOutRange = {
1365 "NO-IntegerOutRange",
1366 "NO-IntegerOutRange",
1367 NO_IntegerOutRange_free,
1368 NO_IntegerOutRange_print,
1369 NO_IntegerOutRange_constraint,
1370 NO_IntegerOutRange_decode_ber,
1371 NO_IntegerOutRange_encode_der,
1372 NO_IntegerOutRange_decode_xer,
1373 NO_IntegerOutRange_encode_xer,
1374 NO_IntegerOutRange_decode_uper,
1375 0, /* Use generic outmost tag fetcher */
1376 asn_DEF_NO_IntegerOutRange_tags_1,
1377 sizeof(asn_DEF_NO_IntegerOutRange_tags_1)
1378 /sizeof(asn_DEF_NO_IntegerOutRange_tags_1[0]), /* 1 */
1379 asn_DEF_NO_IntegerOutRange_tags_1, /* Same as above */
1380 sizeof(asn_DEF_NO_IntegerOutRange_tags_1)
1381 /sizeof(asn_DEF_NO_IntegerOutRange_tags_1[0]), /* 1 */
1382 &asn_PER_NO_IntegerOutRange_constr_1,
1383 0, 0, /* No members */
1384 0 /* No specifics */
1385};
1386
1387
1388/*** <<< INCLUDES [NO-IntegerOutValue] >>> ***/
1389
1390#include <INTEGER.h>
1391
1392/*** <<< TYPE-DECLS [NO-IntegerOutValue] >>> ***/
1393
1394typedef INTEGER_t NO_IntegerOutValue_t;
1395
1396/*** <<< FUNC-DECLS [NO-IntegerOutValue] >>> ***/
1397
1398extern asn_TYPE_descriptor_t asn_DEF_NO_IntegerOutValue;
1399asn_struct_free_f NO_IntegerOutValue_free;
1400asn_struct_print_f NO_IntegerOutValue_print;
1401asn_constr_check_f NO_IntegerOutValue_constraint;
1402ber_type_decoder_f NO_IntegerOutValue_decode_ber;
1403der_type_encoder_f NO_IntegerOutValue_encode_der;
1404xer_type_decoder_f NO_IntegerOutValue_decode_xer;
1405xer_type_encoder_f NO_IntegerOutValue_encode_xer;
1406per_type_decoder_f NO_IntegerOutValue_decode_uper;
1407
1408/*** <<< CODE [NO-IntegerOutValue] >>> ***/
1409
1410int
1411NO_IntegerOutValue_constraint(asn_TYPE_descriptor_t *td, const void *sptr,
1412 asn_app_consume_bytes_f *app_errlog, void *app_key) {
1413 const INTEGER_t *st = (const INTEGER_t *)sptr;
1414 long value;
1415
1416 if(!sptr) {
1417 _ASN_ERRLOG(app_errlog, app_key,
1418 "%s: value not given (%s:%d)",
1419 td->name, __FILE__, __LINE__);
1420 return -1;
1421 }
1422
1423 if(asn_INTEGER2long(st, &value)) {
1424 _ASN_ERRLOG(app_errlog, app_key,
1425 "%s: value too large (%s:%d)",
1426 td->name, __FILE__, __LINE__);
1427 return -1;
1428 }
1429
1430 if((value == 3000000000)) {
1431 /* Constraint check succeeded */
1432 return 0;
1433 } else {
1434 _ASN_ERRLOG(app_errlog, app_key,
1435 "%s: constraint failed (%s:%d)",
1436 td->name, __FILE__, __LINE__);
1437 return -1;
1438 }
1439}
1440
1441/*
1442 * This type is implemented using INTEGER,
1443 * so here we adjust the DEF accordingly.
1444 */
1445static void
1446NO_IntegerOutValue_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) {
1447 td->free_struct = asn_DEF_INTEGER.free_struct;
1448 td->print_struct = asn_DEF_INTEGER.print_struct;
1449 td->ber_decoder = asn_DEF_INTEGER.ber_decoder;
1450 td->der_encoder = asn_DEF_INTEGER.der_encoder;
1451 td->xer_decoder = asn_DEF_INTEGER.xer_decoder;
1452 td->xer_encoder = asn_DEF_INTEGER.xer_encoder;
1453 td->uper_decoder = asn_DEF_INTEGER.uper_decoder;
1454 if(!td->per_constraints)
1455 td->per_constraints = asn_DEF_INTEGER.per_constraints;
1456 td->elements = asn_DEF_INTEGER.elements;
1457 td->elements_count = asn_DEF_INTEGER.elements_count;
1458 td->specifics = asn_DEF_INTEGER.specifics;
1459}
1460
1461void
1462NO_IntegerOutValue_free(asn_TYPE_descriptor_t *td,
1463 void *struct_ptr, int contents_only) {
1464 NO_IntegerOutValue_1_inherit_TYPE_descriptor(td);
1465 td->free_struct(td, struct_ptr, contents_only);
1466}
1467
1468int
1469NO_IntegerOutValue_print(asn_TYPE_descriptor_t *td, const void *struct_ptr,
1470 int ilevel, asn_app_consume_bytes_f *cb, void *app_key) {
1471 NO_IntegerOutValue_1_inherit_TYPE_descriptor(td);
1472 return td->print_struct(td, struct_ptr, ilevel, cb, app_key);
1473}
1474
1475asn_dec_rval_t
1476NO_IntegerOutValue_decode_ber(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td,
1477 void **structure, const void *bufptr, size_t size, int tag_mode) {
1478 NO_IntegerOutValue_1_inherit_TYPE_descriptor(td);
1479 return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, tag_mode);
1480}
1481
1482asn_enc_rval_t
1483NO_IntegerOutValue_encode_der(asn_TYPE_descriptor_t *td,
1484 void *structure, int tag_mode, ber_tlv_tag_t tag,
1485 asn_app_consume_bytes_f *cb, void *app_key) {
1486 NO_IntegerOutValue_1_inherit_TYPE_descriptor(td);
1487 return td->der_encoder(td, structure, tag_mode, tag, cb, app_key);
1488}
1489
1490asn_dec_rval_t
1491NO_IntegerOutValue_decode_xer(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td,
1492 void **structure, const char *opt_mname, const void *bufptr, size_t size) {
1493 NO_IntegerOutValue_1_inherit_TYPE_descriptor(td);
1494 return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, size);
1495}
1496
1497asn_enc_rval_t
1498NO_IntegerOutValue_encode_xer(asn_TYPE_descriptor_t *td, void *structure,
1499 int ilevel, enum xer_encoder_flags_e flags,
1500 asn_app_consume_bytes_f *cb, void *app_key) {
1501 NO_IntegerOutValue_1_inherit_TYPE_descriptor(td);
1502 return td->xer_encoder(td, structure, ilevel, flags, cb, app_key);
1503}
1504
1505asn_dec_rval_t
1506NO_IntegerOutValue_decode_uper(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td,
1507 asn_per_constraints_t *constraints, void **structure, asn_per_data_t *per_data) {
1508 NO_IntegerOutValue_1_inherit_TYPE_descriptor(td);
1509 return td->uper_decoder(opt_codec_ctx, td, constraints, structure, per_data);
1510}
1511
1512
1513/*** <<< STAT-DEFS [NO-IntegerOutValue] >>> ***/
1514
1515static ber_tlv_tag_t asn_DEF_NO_IntegerOutValue_tags_1[] = {
1516 (ASN_TAG_CLASS_UNIVERSAL | (2 << 2))
1517};
1518static asn_per_constraints_t asn_PER_NO_IntegerOutValue_constr_1 = {
1519 { APC_CONSTRAINED, 0, -1, 3000000000, 3000000000 } /* (3000000000..3000000000) */,
1520 { APC_UNCONSTRAINED, -1, -1, 0, 0 }
1521};
1522asn_TYPE_descriptor_t asn_DEF_NO_IntegerOutValue = {
1523 "NO-IntegerOutValue",
1524 "NO-IntegerOutValue",
1525 NO_IntegerOutValue_free,
1526 NO_IntegerOutValue_print,
1527 NO_IntegerOutValue_constraint,
1528 NO_IntegerOutValue_decode_ber,
1529 NO_IntegerOutValue_encode_der,
1530 NO_IntegerOutValue_decode_xer,
1531 NO_IntegerOutValue_encode_xer,
1532 NO_IntegerOutValue_decode_uper,
1533 0, /* Use generic outmost tag fetcher */
1534 asn_DEF_NO_IntegerOutValue_tags_1,
1535 sizeof(asn_DEF_NO_IntegerOutValue_tags_1)
1536 /sizeof(asn_DEF_NO_IntegerOutValue_tags_1[0]), /* 1 */
1537 asn_DEF_NO_IntegerOutValue_tags_1, /* Same as above */
1538 sizeof(asn_DEF_NO_IntegerOutValue_tags_1)
1539 /sizeof(asn_DEF_NO_IntegerOutValue_tags_1[0]), /* 1 */
1540 &asn_PER_NO_IntegerOutValue_constr_1,
1541 0, 0, /* No members */
1542 0 /* No specifics */
1543};
1544
1545
1546/*** <<< INCLUDES [OK-IntegerInRange1] >>> ***/
1547
1548#include <NativeInteger.h>
1549
1550/*** <<< TYPE-DECLS [OK-IntegerInRange1] >>> ***/
1551
1552typedef long OK_IntegerInRange1_t;
1553
1554/*** <<< FUNC-DECLS [OK-IntegerInRange1] >>> ***/
1555
1556extern asn_TYPE_descriptor_t asn_DEF_OK_IntegerInRange1;
1557asn_struct_free_f OK_IntegerInRange1_free;
1558asn_struct_print_f OK_IntegerInRange1_print;
1559asn_constr_check_f OK_IntegerInRange1_constraint;
1560ber_type_decoder_f OK_IntegerInRange1_decode_ber;
1561der_type_encoder_f OK_IntegerInRange1_encode_der;
1562xer_type_decoder_f OK_IntegerInRange1_decode_xer;
1563xer_type_encoder_f OK_IntegerInRange1_encode_xer;
1564per_type_decoder_f OK_IntegerInRange1_decode_uper;
1565
1566/*** <<< CODE [OK-IntegerInRange1] >>> ***/
1567
1568int
1569OK_IntegerInRange1_constraint(asn_TYPE_descriptor_t *td, const void *sptr,
1570 asn_app_consume_bytes_f *app_errlog, void *app_key) {
1571 long value;
1572
1573 if(!sptr) {
1574 _ASN_ERRLOG(app_errlog, app_key,
1575 "%s: value not given (%s:%d)",
1576 td->name, __FILE__, __LINE__);
1577 return -1;
1578 }
1579
1580 value = *(const long *)sptr;
1581
1582 if((value >= -100 && value <= 100)) {
1583 /* Constraint check succeeded */
1584 return 0;
1585 } else {
1586 _ASN_ERRLOG(app_errlog, app_key,
1587 "%s: constraint failed (%s:%d)",
1588 td->name, __FILE__, __LINE__);
1589 return -1;
1590 }
1591}
1592
1593/*
1594 * This type is implemented using NativeInteger,
1595 * so here we adjust the DEF accordingly.
1596 */
1597static void
1598OK_IntegerInRange1_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) {
1599 td->free_struct = asn_DEF_NativeInteger.free_struct;
1600 td->print_struct = asn_DEF_NativeInteger.print_struct;
1601 td->ber_decoder = asn_DEF_NativeInteger.ber_decoder;
1602 td->der_encoder = asn_DEF_NativeInteger.der_encoder;
1603 td->xer_decoder = asn_DEF_NativeInteger.xer_decoder;
1604 td->xer_encoder = asn_DEF_NativeInteger.xer_encoder;
1605 td->uper_decoder = asn_DEF_NativeInteger.uper_decoder;
1606 if(!td->per_constraints)
1607 td->per_constraints = asn_DEF_NativeInteger.per_constraints;
1608 td->elements = asn_DEF_NativeInteger.elements;
1609 td->elements_count = asn_DEF_NativeInteger.elements_count;
1610 td->specifics = asn_DEF_NativeInteger.specifics;
1611}
1612
1613void
1614OK_IntegerInRange1_free(asn_TYPE_descriptor_t *td,
1615 void *struct_ptr, int contents_only) {
1616 OK_IntegerInRange1_1_inherit_TYPE_descriptor(td);
1617 td->free_struct(td, struct_ptr, contents_only);
1618}
1619
1620int
1621OK_IntegerInRange1_print(asn_TYPE_descriptor_t *td, const void *struct_ptr,
1622 int ilevel, asn_app_consume_bytes_f *cb, void *app_key) {
1623 OK_IntegerInRange1_1_inherit_TYPE_descriptor(td);
1624 return td->print_struct(td, struct_ptr, ilevel, cb, app_key);
1625}
1626
1627asn_dec_rval_t
1628OK_IntegerInRange1_decode_ber(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td,
1629 void **structure, const void *bufptr, size_t size, int tag_mode) {
1630 OK_IntegerInRange1_1_inherit_TYPE_descriptor(td);
1631 return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, tag_mode);
1632}
1633
1634asn_enc_rval_t
1635OK_IntegerInRange1_encode_der(asn_TYPE_descriptor_t *td,
1636 void *structure, int tag_mode, ber_tlv_tag_t tag,
1637 asn_app_consume_bytes_f *cb, void *app_key) {
1638 OK_IntegerInRange1_1_inherit_TYPE_descriptor(td);
1639 return td->der_encoder(td, structure, tag_mode, tag, cb, app_key);
1640}
1641
1642asn_dec_rval_t
1643OK_IntegerInRange1_decode_xer(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td,
1644 void **structure, const char *opt_mname, const void *bufptr, size_t size) {
1645 OK_IntegerInRange1_1_inherit_TYPE_descriptor(td);
1646 return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, size);
1647}
1648
1649asn_enc_rval_t
1650OK_IntegerInRange1_encode_xer(asn_TYPE_descriptor_t *td, void *structure,
1651 int ilevel, enum xer_encoder_flags_e flags,
1652 asn_app_consume_bytes_f *cb, void *app_key) {
1653 OK_IntegerInRange1_1_inherit_TYPE_descriptor(td);
1654 return td->xer_encoder(td, structure, ilevel, flags, cb, app_key);
1655}
1656
1657asn_dec_rval_t
1658OK_IntegerInRange1_decode_uper(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td,
1659 asn_per_constraints_t *constraints, void **structure, asn_per_data_t *per_data) {
1660 OK_IntegerInRange1_1_inherit_TYPE_descriptor(td);
1661 return td->uper_decoder(opt_codec_ctx, td, constraints, structure, per_data);
1662}
1663
1664
1665/*** <<< STAT-DEFS [OK-IntegerInRange1] >>> ***/
1666
1667static ber_tlv_tag_t asn_DEF_OK_IntegerInRange1_tags_1[] = {
1668 (ASN_TAG_CLASS_UNIVERSAL | (2 << 2))
1669};
1670static asn_per_constraints_t asn_PER_OK_IntegerInRange1_constr_1 = {
1671 { APC_CONSTRAINED, 8, 8, -100, 100 } /* (-100..100) */,
1672 { APC_UNCONSTRAINED, -1, -1, 0, 0 }
1673};
1674asn_TYPE_descriptor_t asn_DEF_OK_IntegerInRange1 = {
1675 "OK-IntegerInRange1",
1676 "OK-IntegerInRange1",
1677 OK_IntegerInRange1_free,
1678 OK_IntegerInRange1_print,
1679 OK_IntegerInRange1_constraint,
1680 OK_IntegerInRange1_decode_ber,
1681 OK_IntegerInRange1_encode_der,
1682 OK_IntegerInRange1_decode_xer,
1683 OK_IntegerInRange1_encode_xer,
1684 OK_IntegerInRange1_decode_uper,
1685 0, /* Use generic outmost tag fetcher */
1686 asn_DEF_OK_IntegerInRange1_tags_1,
1687 sizeof(asn_DEF_OK_IntegerInRange1_tags_1)
1688 /sizeof(asn_DEF_OK_IntegerInRange1_tags_1[0]), /* 1 */
1689 asn_DEF_OK_IntegerInRange1_tags_1, /* Same as above */
1690 sizeof(asn_DEF_OK_IntegerInRange1_tags_1)
1691 /sizeof(asn_DEF_OK_IntegerInRange1_tags_1[0]), /* 1 */
1692 &asn_PER_OK_IntegerInRange1_constr_1,
1693 0, 0, /* No members */
1694 0 /* No specifics */
1695};
1696
1697
1698/*** <<< INCLUDES [OK-IntegerInRange2] >>> ***/
1699
1700#include <NativeInteger.h>
1701
1702/*** <<< TYPE-DECLS [OK-IntegerInRange2] >>> ***/
1703
1704typedef long OK_IntegerInRange2_t;
1705
1706/*** <<< FUNC-DECLS [OK-IntegerInRange2] >>> ***/
1707
1708extern asn_TYPE_descriptor_t asn_DEF_OK_IntegerInRange2;
1709asn_struct_free_f OK_IntegerInRange2_free;
1710asn_struct_print_f OK_IntegerInRange2_print;
1711asn_constr_check_f OK_IntegerInRange2_constraint;
1712ber_type_decoder_f OK_IntegerInRange2_decode_ber;
1713der_type_encoder_f OK_IntegerInRange2_encode_der;
1714xer_type_decoder_f OK_IntegerInRange2_decode_xer;
1715xer_type_encoder_f OK_IntegerInRange2_encode_xer;
1716per_type_decoder_f OK_IntegerInRange2_decode_uper;
1717
1718/*** <<< CODE [OK-IntegerInRange2] >>> ***/
1719
1720int
1721OK_IntegerInRange2_constraint(asn_TYPE_descriptor_t *td, const void *sptr,
1722 asn_app_consume_bytes_f *app_errlog, void *app_key) {
1723 long value;
1724
1725 if(!sptr) {
1726 _ASN_ERRLOG(app_errlog, app_key,
1727 "%s: value not given (%s:%d)",
1728 td->name, __FILE__, __LINE__);
1729 return -1;
1730 }
1731
1732 value = *(const long *)sptr;
1733
1734 if(((value == -100) || (value == 100))) {
1735 /* Constraint check succeeded */
1736 return 0;
1737 } else {
1738 _ASN_ERRLOG(app_errlog, app_key,
1739 "%s: constraint failed (%s:%d)",
1740 td->name, __FILE__, __LINE__);
1741 return -1;
1742 }
1743}
1744
1745/*
1746 * This type is implemented using NativeInteger,
1747 * so here we adjust the DEF accordingly.
1748 */
1749static void
1750OK_IntegerInRange2_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) {
1751 td->free_struct = asn_DEF_NativeInteger.free_struct;
1752 td->print_struct = asn_DEF_NativeInteger.print_struct;
1753 td->ber_decoder = asn_DEF_NativeInteger.ber_decoder;
1754 td->der_encoder = asn_DEF_NativeInteger.der_encoder;
1755 td->xer_decoder = asn_DEF_NativeInteger.xer_decoder;
1756 td->xer_encoder = asn_DEF_NativeInteger.xer_encoder;
1757 td->uper_decoder = asn_DEF_NativeInteger.uper_decoder;
1758 if(!td->per_constraints)
1759 td->per_constraints = asn_DEF_NativeInteger.per_constraints;
1760 td->elements = asn_DEF_NativeInteger.elements;
1761 td->elements_count = asn_DEF_NativeInteger.elements_count;
1762 td->specifics = asn_DEF_NativeInteger.specifics;
1763}
1764
1765void
1766OK_IntegerInRange2_free(asn_TYPE_descriptor_t *td,
1767 void *struct_ptr, int contents_only) {
1768 OK_IntegerInRange2_1_inherit_TYPE_descriptor(td);
1769 td->free_struct(td, struct_ptr, contents_only);
1770}
1771
1772int
1773OK_IntegerInRange2_print(asn_TYPE_descriptor_t *td, const void *struct_ptr,
1774 int ilevel, asn_app_consume_bytes_f *cb, void *app_key) {
1775 OK_IntegerInRange2_1_inherit_TYPE_descriptor(td);
1776 return td->print_struct(td, struct_ptr, ilevel, cb, app_key);
1777}
1778
1779asn_dec_rval_t
1780OK_IntegerInRange2_decode_ber(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td,
1781 void **structure, const void *bufptr, size_t size, int tag_mode) {
1782 OK_IntegerInRange2_1_inherit_TYPE_descriptor(td);
1783 return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, tag_mode);
1784}
1785
1786asn_enc_rval_t
1787OK_IntegerInRange2_encode_der(asn_TYPE_descriptor_t *td,
1788 void *structure, int tag_mode, ber_tlv_tag_t tag,
1789 asn_app_consume_bytes_f *cb, void *app_key) {
1790 OK_IntegerInRange2_1_inherit_TYPE_descriptor(td);
1791 return td->der_encoder(td, structure, tag_mode, tag, cb, app_key);
1792}
1793
1794asn_dec_rval_t
1795OK_IntegerInRange2_decode_xer(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td,
1796 void **structure, const char *opt_mname, const void *bufptr, size_t size) {
1797 OK_IntegerInRange2_1_inherit_TYPE_descriptor(td);
1798 return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, size);
1799}
1800
1801asn_enc_rval_t
1802OK_IntegerInRange2_encode_xer(asn_TYPE_descriptor_t *td, void *structure,
1803 int ilevel, enum xer_encoder_flags_e flags,
1804 asn_app_consume_bytes_f *cb, void *app_key) {
1805 OK_IntegerInRange2_1_inherit_TYPE_descriptor(td);
1806 return td->xer_encoder(td, structure, ilevel, flags, cb, app_key);
1807}
1808
1809asn_dec_rval_t
1810OK_IntegerInRange2_decode_uper(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td,
1811 asn_per_constraints_t *constraints, void **structure, asn_per_data_t *per_data) {
1812 OK_IntegerInRange2_1_inherit_TYPE_descriptor(td);
1813 return td->uper_decoder(opt_codec_ctx, td, constraints, structure, per_data);
1814}
1815
1816
1817/*** <<< STAT-DEFS [OK-IntegerInRange2] >>> ***/
1818
1819static ber_tlv_tag_t asn_DEF_OK_IntegerInRange2_tags_1[] = {
1820 (ASN_TAG_CLASS_UNIVERSAL | (2 << 2))
1821};
1822static asn_per_constraints_t asn_PER_OK_IntegerInRange2_constr_1 = {
1823 { APC_CONSTRAINED, 8, 8, -100, 100 } /* (-100..100) */,
1824 { APC_UNCONSTRAINED, -1, -1, 0, 0 }
1825};
1826asn_TYPE_descriptor_t asn_DEF_OK_IntegerInRange2 = {
1827 "OK-IntegerInRange2",
1828 "OK-IntegerInRange2",
1829 OK_IntegerInRange2_free,
1830 OK_IntegerInRange2_print,
1831 OK_IntegerInRange2_constraint,
1832 OK_IntegerInRange2_decode_ber,
1833 OK_IntegerInRange2_encode_der,
1834 OK_IntegerInRange2_decode_xer,
1835 OK_IntegerInRange2_encode_xer,
1836 OK_IntegerInRange2_decode_uper,
1837 0, /* Use generic outmost tag fetcher */
1838 asn_DEF_OK_IntegerInRange2_tags_1,
1839 sizeof(asn_DEF_OK_IntegerInRange2_tags_1)
1840 /sizeof(asn_DEF_OK_IntegerInRange2_tags_1[0]), /* 1 */
1841 asn_DEF_OK_IntegerInRange2_tags_1, /* Same as above */
1842 sizeof(asn_DEF_OK_IntegerInRange2_tags_1)
1843 /sizeof(asn_DEF_OK_IntegerInRange2_tags_1[0]), /* 1 */
1844 &asn_PER_OK_IntegerInRange2_constr_1,
1845 0, 0, /* No members */
1846 0 /* No specifics */
1847};
1848
1849
1850/*** <<< INCLUDES [OK-IntegerInRange3] >>> ***/
1851
1852#include <NativeInteger.h>
1853
1854/*** <<< TYPE-DECLS [OK-IntegerInRange3] >>> ***/
1855
1856typedef long OK_IntegerInRange3_t;
1857
1858/*** <<< FUNC-DECLS [OK-IntegerInRange3] >>> ***/
1859
1860extern asn_TYPE_descriptor_t asn_DEF_OK_IntegerInRange3;
1861asn_struct_free_f OK_IntegerInRange3_free;
1862asn_struct_print_f OK_IntegerInRange3_print;
1863asn_constr_check_f OK_IntegerInRange3_constraint;
1864ber_type_decoder_f OK_IntegerInRange3_decode_ber;
1865der_type_encoder_f OK_IntegerInRange3_encode_der;
1866xer_type_decoder_f OK_IntegerInRange3_decode_xer;
1867xer_type_encoder_f OK_IntegerInRange3_encode_xer;
1868per_type_decoder_f OK_IntegerInRange3_decode_uper;
1869
1870/*** <<< CODE [OK-IntegerInRange3] >>> ***/
1871
1872int
1873OK_IntegerInRange3_constraint(asn_TYPE_descriptor_t *td, const void *sptr,
1874 asn_app_consume_bytes_f *app_errlog, void *app_key) {
1875 long value;
1876
1877 if(!sptr) {
1878 _ASN_ERRLOG(app_errlog, app_key,
1879 "%s: value not given (%s:%d)",
1880 td->name, __FILE__, __LINE__);
1881 return -1;
1882 }
1883
1884 value = *(const long *)sptr;
1885
1886 if((value >= -2147483648 && value <= 2147483647)) {
1887 /* Constraint check succeeded */
1888 return 0;
1889 } else {
1890 _ASN_ERRLOG(app_errlog, app_key,
1891 "%s: constraint failed (%s:%d)",
1892 td->name, __FILE__, __LINE__);
1893 return -1;
1894 }
1895}
1896
1897/*
1898 * This type is implemented using NativeInteger,
1899 * so here we adjust the DEF accordingly.
1900 */
1901static void
1902OK_IntegerInRange3_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) {
1903 td->free_struct = asn_DEF_NativeInteger.free_struct;
1904 td->print_struct = asn_DEF_NativeInteger.print_struct;
1905 td->ber_decoder = asn_DEF_NativeInteger.ber_decoder;
1906 td->der_encoder = asn_DEF_NativeInteger.der_encoder;
1907 td->xer_decoder = asn_DEF_NativeInteger.xer_decoder;
1908 td->xer_encoder = asn_DEF_NativeInteger.xer_encoder;
1909 td->uper_decoder = asn_DEF_NativeInteger.uper_decoder;
1910 if(!td->per_constraints)
1911 td->per_constraints = asn_DEF_NativeInteger.per_constraints;
1912 td->elements = asn_DEF_NativeInteger.elements;
1913 td->elements_count = asn_DEF_NativeInteger.elements_count;
1914 td->specifics = asn_DEF_NativeInteger.specifics;
1915}
1916
1917void
1918OK_IntegerInRange3_free(asn_TYPE_descriptor_t *td,
1919 void *struct_ptr, int contents_only) {
1920 OK_IntegerInRange3_1_inherit_TYPE_descriptor(td);
1921 td->free_struct(td, struct_ptr, contents_only);
1922}
1923
1924int
1925OK_IntegerInRange3_print(asn_TYPE_descriptor_t *td, const void *struct_ptr,
1926 int ilevel, asn_app_consume_bytes_f *cb, void *app_key) {
1927 OK_IntegerInRange3_1_inherit_TYPE_descriptor(td);
1928 return td->print_struct(td, struct_ptr, ilevel, cb, app_key);
1929}
1930
1931asn_dec_rval_t
1932OK_IntegerInRange3_decode_ber(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td,
1933 void **structure, const void *bufptr, size_t size, int tag_mode) {
1934 OK_IntegerInRange3_1_inherit_TYPE_descriptor(td);
1935 return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, tag_mode);
1936}
1937
1938asn_enc_rval_t
1939OK_IntegerInRange3_encode_der(asn_TYPE_descriptor_t *td,
1940 void *structure, int tag_mode, ber_tlv_tag_t tag,
1941 asn_app_consume_bytes_f *cb, void *app_key) {
1942 OK_IntegerInRange3_1_inherit_TYPE_descriptor(td);
1943 return td->der_encoder(td, structure, tag_mode, tag, cb, app_key);
1944}
1945
1946asn_dec_rval_t
1947OK_IntegerInRange3_decode_xer(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td,
1948 void **structure, const char *opt_mname, const void *bufptr, size_t size) {
1949 OK_IntegerInRange3_1_inherit_TYPE_descriptor(td);
1950 return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, size);
1951}
1952
1953asn_enc_rval_t
1954OK_IntegerInRange3_encode_xer(asn_TYPE_descriptor_t *td, void *structure,
1955 int ilevel, enum xer_encoder_flags_e flags,
1956 asn_app_consume_bytes_f *cb, void *app_key) {
1957 OK_IntegerInRange3_1_inherit_TYPE_descriptor(td);
1958 return td->xer_encoder(td, structure, ilevel, flags, cb, app_key);
1959}
1960
1961asn_dec_rval_t
1962OK_IntegerInRange3_decode_uper(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td,
1963 asn_per_constraints_t *constraints, void **structure, asn_per_data_t *per_data) {
1964 OK_IntegerInRange3_1_inherit_TYPE_descriptor(td);
1965 return td->uper_decoder(opt_codec_ctx, td, constraints, structure, per_data);
1966}
1967
1968
1969/*** <<< STAT-DEFS [OK-IntegerInRange3] >>> ***/
1970
1971static ber_tlv_tag_t asn_DEF_OK_IntegerInRange3_tags_1[] = {
1972 (ASN_TAG_CLASS_UNIVERSAL | (2 << 2))
1973};
1974static asn_per_constraints_t asn_PER_OK_IntegerInRange3_constr_1 = {
1975 { APC_CONSTRAINED, 32, -1, -2147483648, 2147483647 } /* (-2147483648..2147483647) */,
1976 { APC_UNCONSTRAINED, -1, -1, 0, 0 }
1977};
1978asn_TYPE_descriptor_t asn_DEF_OK_IntegerInRange3 = {
1979 "OK-IntegerInRange3",
1980 "OK-IntegerInRange3",
1981 OK_IntegerInRange3_free,
1982 OK_IntegerInRange3_print,
1983 OK_IntegerInRange3_constraint,
1984 OK_IntegerInRange3_decode_ber,
1985 OK_IntegerInRange3_encode_der,
1986 OK_IntegerInRange3_decode_xer,
1987 OK_IntegerInRange3_encode_xer,
1988 OK_IntegerInRange3_decode_uper,
1989 0, /* Use generic outmost tag fetcher */
1990 asn_DEF_OK_IntegerInRange3_tags_1,
1991 sizeof(asn_DEF_OK_IntegerInRange3_tags_1)
1992 /sizeof(asn_DEF_OK_IntegerInRange3_tags_1[0]), /* 1 */
1993 asn_DEF_OK_IntegerInRange3_tags_1, /* Same as above */
1994 sizeof(asn_DEF_OK_IntegerInRange3_tags_1)
1995 /sizeof(asn_DEF_OK_IntegerInRange3_tags_1[0]), /* 1 */
1996 &asn_PER_OK_IntegerInRange3_constr_1,
1997 0, 0, /* No members */
1998 0 /* No specifics */
1999};
2000
2001
2002/*** <<< INCLUDES [OK-IntegerInRange4] >>> ***/
2003
2004#include <NativeInteger.h>
2005
2006/*** <<< TYPE-DECLS [OK-IntegerInRange4] >>> ***/
2007
2008typedef long OK_IntegerInRange4_t;
2009
2010/*** <<< FUNC-DECLS [OK-IntegerInRange4] >>> ***/
2011
2012extern asn_TYPE_descriptor_t asn_DEF_OK_IntegerInRange4;
2013asn_struct_free_f OK_IntegerInRange4_free;
2014asn_struct_print_f OK_IntegerInRange4_print;
2015asn_constr_check_f OK_IntegerInRange4_constraint;
2016ber_type_decoder_f OK_IntegerInRange4_decode_ber;
2017der_type_encoder_f OK_IntegerInRange4_encode_der;
2018xer_type_decoder_f OK_IntegerInRange4_decode_xer;
2019xer_type_encoder_f OK_IntegerInRange4_encode_xer;
2020per_type_decoder_f OK_IntegerInRange4_decode_uper;
2021
2022/*** <<< CODE [OK-IntegerInRange4] >>> ***/
2023
2024int
2025OK_IntegerInRange4_constraint(asn_TYPE_descriptor_t *td, const void *sptr,
2026 asn_app_consume_bytes_f *app_errlog, void *app_key) {
2027 long value;
2028
2029 if(!sptr) {
2030 _ASN_ERRLOG(app_errlog, app_key,
2031 "%s: value not given (%s:%d)",
2032 td->name, __FILE__, __LINE__);
2033 return -1;
2034 }
2035
2036 value = *(const long *)sptr;
2037
2038 if(((value == -2147483648) || (value == 2147483647))) {
2039 /* Constraint check succeeded */
2040 return 0;
2041 } else {
2042 _ASN_ERRLOG(app_errlog, app_key,
2043 "%s: constraint failed (%s:%d)",
2044 td->name, __FILE__, __LINE__);
2045 return -1;
2046 }
2047}
2048
2049/*
2050 * This type is implemented using NativeInteger,
2051 * so here we adjust the DEF accordingly.
2052 */
2053static void
2054OK_IntegerInRange4_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) {
2055 td->free_struct = asn_DEF_NativeInteger.free_struct;
2056 td->print_struct = asn_DEF_NativeInteger.print_struct;
2057 td->ber_decoder = asn_DEF_NativeInteger.ber_decoder;
2058 td->der_encoder = asn_DEF_NativeInteger.der_encoder;
2059 td->xer_decoder = asn_DEF_NativeInteger.xer_decoder;
2060 td->xer_encoder = asn_DEF_NativeInteger.xer_encoder;
2061 td->uper_decoder = asn_DEF_NativeInteger.uper_decoder;
2062 if(!td->per_constraints)
2063 td->per_constraints = asn_DEF_NativeInteger.per_constraints;
2064 td->elements = asn_DEF_NativeInteger.elements;
2065 td->elements_count = asn_DEF_NativeInteger.elements_count;
2066 td->specifics = asn_DEF_NativeInteger.specifics;
2067}
2068
2069void
2070OK_IntegerInRange4_free(asn_TYPE_descriptor_t *td,
2071 void *struct_ptr, int contents_only) {
2072 OK_IntegerInRange4_1_inherit_TYPE_descriptor(td);
2073 td->free_struct(td, struct_ptr, contents_only);
2074}
2075
2076int
2077OK_IntegerInRange4_print(asn_TYPE_descriptor_t *td, const void *struct_ptr,
2078 int ilevel, asn_app_consume_bytes_f *cb, void *app_key) {
2079 OK_IntegerInRange4_1_inherit_TYPE_descriptor(td);
2080 return td->print_struct(td, struct_ptr, ilevel, cb, app_key);
2081}
2082
2083asn_dec_rval_t
2084OK_IntegerInRange4_decode_ber(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td,
2085 void **structure, const void *bufptr, size_t size, int tag_mode) {
2086 OK_IntegerInRange4_1_inherit_TYPE_descriptor(td);
2087 return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, tag_mode);
2088}
2089
2090asn_enc_rval_t
2091OK_IntegerInRange4_encode_der(asn_TYPE_descriptor_t *td,
2092 void *structure, int tag_mode, ber_tlv_tag_t tag,
2093 asn_app_consume_bytes_f *cb, void *app_key) {
2094 OK_IntegerInRange4_1_inherit_TYPE_descriptor(td);
2095 return td->der_encoder(td, structure, tag_mode, tag, cb, app_key);
2096}
2097
2098asn_dec_rval_t
2099OK_IntegerInRange4_decode_xer(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td,
2100 void **structure, const char *opt_mname, const void *bufptr, size_t size) {
2101 OK_IntegerInRange4_1_inherit_TYPE_descriptor(td);
2102 return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, size);
2103}
2104
2105asn_enc_rval_t
2106OK_IntegerInRange4_encode_xer(asn_TYPE_descriptor_t *td, void *structure,
2107 int ilevel, enum xer_encoder_flags_e flags,
2108 asn_app_consume_bytes_f *cb, void *app_key) {
2109 OK_IntegerInRange4_1_inherit_TYPE_descriptor(td);
2110 return td->xer_encoder(td, structure, ilevel, flags, cb, app_key);
2111}
2112
2113asn_dec_rval_t
2114OK_IntegerInRange4_decode_uper(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td,
2115 asn_per_constraints_t *constraints, void **structure, asn_per_data_t *per_data) {
2116 OK_IntegerInRange4_1_inherit_TYPE_descriptor(td);
2117 return td->uper_decoder(opt_codec_ctx, td, constraints, structure, per_data);
2118}
2119
2120
2121/*** <<< STAT-DEFS [OK-IntegerInRange4] >>> ***/
2122
2123static ber_tlv_tag_t asn_DEF_OK_IntegerInRange4_tags_1[] = {
2124 (ASN_TAG_CLASS_UNIVERSAL | (2 << 2))
2125};
2126static asn_per_constraints_t asn_PER_OK_IntegerInRange4_constr_1 = {
2127 { APC_CONSTRAINED, 32, -1, -2147483648, 2147483647 } /* (-2147483648..2147483647) */,
2128 { APC_UNCONSTRAINED, -1, -1, 0, 0 }
2129};
2130asn_TYPE_descriptor_t asn_DEF_OK_IntegerInRange4 = {
2131 "OK-IntegerInRange4",
2132 "OK-IntegerInRange4",
2133 OK_IntegerInRange4_free,
2134 OK_IntegerInRange4_print,
2135 OK_IntegerInRange4_constraint,
2136 OK_IntegerInRange4_decode_ber,
2137 OK_IntegerInRange4_encode_der,
2138 OK_IntegerInRange4_decode_xer,
2139 OK_IntegerInRange4_encode_xer,
2140 OK_IntegerInRange4_decode_uper,
2141 0, /* Use generic outmost tag fetcher */
2142 asn_DEF_OK_IntegerInRange4_tags_1,
2143 sizeof(asn_DEF_OK_IntegerInRange4_tags_1)
2144 /sizeof(asn_DEF_OK_IntegerInRange4_tags_1[0]), /* 1 */
2145 asn_DEF_OK_IntegerInRange4_tags_1, /* Same as above */
2146 sizeof(asn_DEF_OK_IntegerInRange4_tags_1)
2147 /sizeof(asn_DEF_OK_IntegerInRange4_tags_1[0]), /* 1 */
2148 &asn_PER_OK_IntegerInRange4_constr_1,
2149 0, 0, /* No members */
2150 0 /* No specifics */
2151};
2152
2153
2154/*** <<< INCLUDES [OK-IntegerInRange5] >>> ***/
2155
2156#include <INTEGER.h>
2157
2158/*** <<< TYPE-DECLS [OK-IntegerInRange5] >>> ***/
2159
2160typedef INTEGER_t OK_IntegerInRange5_t;
2161
2162/*** <<< FUNC-DECLS [OK-IntegerInRange5] >>> ***/
2163
2164extern asn_TYPE_descriptor_t asn_DEF_OK_IntegerInRange5;
2165asn_struct_free_f OK_IntegerInRange5_free;
2166asn_struct_print_f OK_IntegerInRange5_print;
2167asn_constr_check_f OK_IntegerInRange5_constraint;
2168ber_type_decoder_f OK_IntegerInRange5_decode_ber;
2169der_type_encoder_f OK_IntegerInRange5_encode_der;
2170xer_type_decoder_f OK_IntegerInRange5_decode_xer;
2171xer_type_encoder_f OK_IntegerInRange5_encode_xer;
2172per_type_decoder_f OK_IntegerInRange5_decode_uper;
2173
2174/*** <<< CODE [OK-IntegerInRange5] >>> ***/
2175
2176int
2177OK_IntegerInRange5_constraint(asn_TYPE_descriptor_t *td, const void *sptr,
2178 asn_app_consume_bytes_f *app_errlog, void *app_key) {
2179 const INTEGER_t *st = (const INTEGER_t *)sptr;
2180 long value;
2181
2182 if(!sptr) {
2183 _ASN_ERRLOG(app_errlog, app_key,
2184 "%s: value not given (%s:%d)",
2185 td->name, __FILE__, __LINE__);
2186 return -1;
2187 }
2188
2189 if(asn_INTEGER2long(st, &value)) {
2190 _ASN_ERRLOG(app_errlog, app_key,
2191 "%s: value too large (%s:%d)",
2192 td->name, __FILE__, __LINE__);
2193 return -1;
2194 }
2195
2196 if(((value == -2147483648) || (value == 2147483647))) {
2197 /* Constraint check succeeded */
2198 return 0;
2199 } else {
2200 _ASN_ERRLOG(app_errlog, app_key,
2201 "%s: constraint failed (%s:%d)",
2202 td->name, __FILE__, __LINE__);
2203 return -1;
2204 }
2205}
2206
2207/*
2208 * This type is implemented using INTEGER,
2209 * so here we adjust the DEF accordingly.
2210 */
2211static void
2212OK_IntegerInRange5_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) {
2213 td->free_struct = asn_DEF_INTEGER.free_struct;
2214 td->print_struct = asn_DEF_INTEGER.print_struct;
2215 td->ber_decoder = asn_DEF_INTEGER.ber_decoder;
2216 td->der_encoder = asn_DEF_INTEGER.der_encoder;
2217 td->xer_decoder = asn_DEF_INTEGER.xer_decoder;
2218 td->xer_encoder = asn_DEF_INTEGER.xer_encoder;
2219 td->uper_decoder = asn_DEF_INTEGER.uper_decoder;
2220 if(!td->per_constraints)
2221 td->per_constraints = asn_DEF_INTEGER.per_constraints;
2222 td->elements = asn_DEF_INTEGER.elements;
2223 td->elements_count = asn_DEF_INTEGER.elements_count;
2224 td->specifics = asn_DEF_INTEGER.specifics;
2225}
2226
2227void
2228OK_IntegerInRange5_free(asn_TYPE_descriptor_t *td,
2229 void *struct_ptr, int contents_only) {
2230 OK_IntegerInRange5_1_inherit_TYPE_descriptor(td);
2231 td->free_struct(td, struct_ptr, contents_only);
2232}
2233
2234int
2235OK_IntegerInRange5_print(asn_TYPE_descriptor_t *td, const void *struct_ptr,
2236 int ilevel, asn_app_consume_bytes_f *cb, void *app_key) {
2237 OK_IntegerInRange5_1_inherit_TYPE_descriptor(td);
2238 return td->print_struct(td, struct_ptr, ilevel, cb, app_key);
2239}
2240
2241asn_dec_rval_t
2242OK_IntegerInRange5_decode_ber(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td,
2243 void **structure, const void *bufptr, size_t size, int tag_mode) {
2244 OK_IntegerInRange5_1_inherit_TYPE_descriptor(td);
2245 return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, tag_mode);
2246}
2247
2248asn_enc_rval_t
2249OK_IntegerInRange5_encode_der(asn_TYPE_descriptor_t *td,
2250 void *structure, int tag_mode, ber_tlv_tag_t tag,
2251 asn_app_consume_bytes_f *cb, void *app_key) {
2252 OK_IntegerInRange5_1_inherit_TYPE_descriptor(td);
2253 return td->der_encoder(td, structure, tag_mode, tag, cb, app_key);
2254}
2255
2256asn_dec_rval_t
2257OK_IntegerInRange5_decode_xer(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td,
2258 void **structure, const char *opt_mname, const void *bufptr, size_t size) {
2259 OK_IntegerInRange5_1_inherit_TYPE_descriptor(td);
2260 return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, size);
2261}
2262
2263asn_enc_rval_t
2264OK_IntegerInRange5_encode_xer(asn_TYPE_descriptor_t *td, void *structure,
2265 int ilevel, enum xer_encoder_flags_e flags,
2266 asn_app_consume_bytes_f *cb, void *app_key) {
2267 OK_IntegerInRange5_1_inherit_TYPE_descriptor(td);
2268 return td->xer_encoder(td, structure, ilevel, flags, cb, app_key);
2269}
2270
2271asn_dec_rval_t
2272OK_IntegerInRange5_decode_uper(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td,
2273 asn_per_constraints_t *constraints, void **structure, asn_per_data_t *per_data) {
2274 OK_IntegerInRange5_1_inherit_TYPE_descriptor(td);
2275 return td->uper_decoder(opt_codec_ctx, td, constraints, structure, per_data);
2276}
2277
2278
2279/*** <<< STAT-DEFS [OK-IntegerInRange5] >>> ***/
2280
2281static ber_tlv_tag_t asn_DEF_OK_IntegerInRange5_tags_1[] = {
2282 (ASN_TAG_CLASS_UNIVERSAL | (2 << 2))
2283};
2284static asn_per_constraints_t asn_PER_OK_IntegerInRange5_constr_1 = {
2285 { APC_CONSTRAINED | APC_EXTENSIBLE, 32, -1, -2147483648, 2147483647 } /* (-2147483648..2147483647,...) */,
2286 { APC_UNCONSTRAINED, -1, -1, 0, 0 }
2287};
2288asn_TYPE_descriptor_t asn_DEF_OK_IntegerInRange5 = {
2289 "OK-IntegerInRange5",
2290 "OK-IntegerInRange5",
2291 OK_IntegerInRange5_free,
2292 OK_IntegerInRange5_print,
2293 OK_IntegerInRange5_constraint,
2294 OK_IntegerInRange5_decode_ber,
2295 OK_IntegerInRange5_encode_der,
2296 OK_IntegerInRange5_decode_xer,
2297 OK_IntegerInRange5_encode_xer,
2298 OK_IntegerInRange5_decode_uper,
2299 0, /* Use generic outmost tag fetcher */
2300 asn_DEF_OK_IntegerInRange5_tags_1,
2301 sizeof(asn_DEF_OK_IntegerInRange5_tags_1)
2302 /sizeof(asn_DEF_OK_IntegerInRange5_tags_1[0]), /* 1 */
2303 asn_DEF_OK_IntegerInRange5_tags_1, /* Same as above */
2304 sizeof(asn_DEF_OK_IntegerInRange5_tags_1)
2305 /sizeof(asn_DEF_OK_IntegerInRange5_tags_1[0]), /* 1 */
2306 &asn_PER_OK_IntegerInRange5_constr_1,
2307 0, 0, /* No members */
2308 0 /* No specifics */
2309};
2310
2311
2312/*** <<< INCLUDES [NO-IntegerInRange6] >>> ***/
2313
2314#include <INTEGER.h>
2315
2316/*** <<< TYPE-DECLS [NO-IntegerInRange6] >>> ***/
2317
2318typedef INTEGER_t NO_IntegerInRange6_t;
2319
2320/*** <<< FUNC-DECLS [NO-IntegerInRange6] >>> ***/
2321
2322extern asn_TYPE_descriptor_t asn_DEF_NO_IntegerInRange6;
2323asn_struct_free_f NO_IntegerInRange6_free;
2324asn_struct_print_f NO_IntegerInRange6_print;
2325asn_constr_check_f NO_IntegerInRange6_constraint;
2326ber_type_decoder_f NO_IntegerInRange6_decode_ber;
2327der_type_encoder_f NO_IntegerInRange6_encode_der;
2328xer_type_decoder_f NO_IntegerInRange6_decode_xer;
2329xer_type_encoder_f NO_IntegerInRange6_encode_xer;
2330per_type_decoder_f NO_IntegerInRange6_decode_uper;
2331
2332/*** <<< CODE [NO-IntegerInRange6] >>> ***/
2333
2334int
2335NO_IntegerInRange6_constraint(asn_TYPE_descriptor_t *td, const void *sptr,
2336 asn_app_consume_bytes_f *app_errlog, void *app_key) {
2337 const INTEGER_t *st = (const INTEGER_t *)sptr;
2338 long value;
2339
2340 if(!sptr) {
2341 _ASN_ERRLOG(app_errlog, app_key,
2342 "%s: value not given (%s:%d)",
2343 td->name, __FILE__, __LINE__);
2344 return -1;
2345 }
2346
2347 if(asn_INTEGER2long(st, &value)) {
2348 _ASN_ERRLOG(app_errlog, app_key,
2349 "%s: value too large (%s:%d)",
2350 td->name, __FILE__, __LINE__);
2351 return -1;
2352 }
2353
2354 if((value >= 0 && value <= 4294967295)) {
2355 /* Constraint check succeeded */
2356 return 0;
2357 } else {
2358 _ASN_ERRLOG(app_errlog, app_key,
2359 "%s: constraint failed (%s:%d)",
2360 td->name, __FILE__, __LINE__);
2361 return -1;
2362 }
2363}
2364
2365/*
2366 * This type is implemented using INTEGER,
2367 * so here we adjust the DEF accordingly.
2368 */
2369static void
2370NO_IntegerInRange6_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) {
2371 td->free_struct = asn_DEF_INTEGER.free_struct;
2372 td->print_struct = asn_DEF_INTEGER.print_struct;
2373 td->ber_decoder = asn_DEF_INTEGER.ber_decoder;
2374 td->der_encoder = asn_DEF_INTEGER.der_encoder;
2375 td->xer_decoder = asn_DEF_INTEGER.xer_decoder;
2376 td->xer_encoder = asn_DEF_INTEGER.xer_encoder;
2377 td->uper_decoder = asn_DEF_INTEGER.uper_decoder;
2378 if(!td->per_constraints)
2379 td->per_constraints = asn_DEF_INTEGER.per_constraints;
2380 td->elements = asn_DEF_INTEGER.elements;
2381 td->elements_count = asn_DEF_INTEGER.elements_count;
2382 td->specifics = asn_DEF_INTEGER.specifics;
2383}
2384
2385void
2386NO_IntegerInRange6_free(asn_TYPE_descriptor_t *td,
2387 void *struct_ptr, int contents_only) {
2388 NO_IntegerInRange6_1_inherit_TYPE_descriptor(td);
2389 td->free_struct(td, struct_ptr, contents_only);
2390}
2391
2392int
2393NO_IntegerInRange6_print(asn_TYPE_descriptor_t *td, const void *struct_ptr,
2394 int ilevel, asn_app_consume_bytes_f *cb, void *app_key) {
2395 NO_IntegerInRange6_1_inherit_TYPE_descriptor(td);
2396 return td->print_struct(td, struct_ptr, ilevel, cb, app_key);
2397}
2398
2399asn_dec_rval_t
2400NO_IntegerInRange6_decode_ber(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td,
2401 void **structure, const void *bufptr, size_t size, int tag_mode) {
2402 NO_IntegerInRange6_1_inherit_TYPE_descriptor(td);
2403 return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, tag_mode);
2404}
2405
2406asn_enc_rval_t
2407NO_IntegerInRange6_encode_der(asn_TYPE_descriptor_t *td,
2408 void *structure, int tag_mode, ber_tlv_tag_t tag,
2409 asn_app_consume_bytes_f *cb, void *app_key) {
2410 NO_IntegerInRange6_1_inherit_TYPE_descriptor(td);
2411 return td->der_encoder(td, structure, tag_mode, tag, cb, app_key);
2412}
2413
2414asn_dec_rval_t
2415NO_IntegerInRange6_decode_xer(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td,
2416 void **structure, const char *opt_mname, const void *bufptr, size_t size) {
2417 NO_IntegerInRange6_1_inherit_TYPE_descriptor(td);
2418 return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, size);
2419}
2420
2421asn_enc_rval_t
2422NO_IntegerInRange6_encode_xer(asn_TYPE_descriptor_t *td, void *structure,
2423 int ilevel, enum xer_encoder_flags_e flags,
2424 asn_app_consume_bytes_f *cb, void *app_key) {
2425 NO_IntegerInRange6_1_inherit_TYPE_descriptor(td);
2426 return td->xer_encoder(td, structure, ilevel, flags, cb, app_key);
2427}
2428
2429asn_dec_rval_t
2430NO_IntegerInRange6_decode_uper(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td,
2431 asn_per_constraints_t *constraints, void **structure, asn_per_data_t *per_data) {
2432 NO_IntegerInRange6_1_inherit_TYPE_descriptor(td);
2433 return td->uper_decoder(opt_codec_ctx, td, constraints, structure, per_data);
2434}
2435
2436
2437/*** <<< STAT-DEFS [NO-IntegerInRange6] >>> ***/
2438
2439static ber_tlv_tag_t asn_DEF_NO_IntegerInRange6_tags_1[] = {
2440 (ASN_TAG_CLASS_UNIVERSAL | (2 << 2))
2441};
2442static asn_per_constraints_t asn_PER_NO_IntegerInRange6_constr_1 = {
2443 { APC_CONSTRAINED, 32, -1, 0, 4294967295 } /* (0..4294967295) */,
2444 { APC_UNCONSTRAINED, -1, -1, 0, 0 }
2445};
2446asn_TYPE_descriptor_t asn_DEF_NO_IntegerInRange6 = {
2447 "NO-IntegerInRange6",
2448 "NO-IntegerInRange6",
2449 NO_IntegerInRange6_free,
2450 NO_IntegerInRange6_print,
2451 NO_IntegerInRange6_constraint,
2452 NO_IntegerInRange6_decode_ber,
2453 NO_IntegerInRange6_encode_der,
2454 NO_IntegerInRange6_decode_xer,
2455 NO_IntegerInRange6_encode_xer,
2456 NO_IntegerInRange6_decode_uper,
2457 0, /* Use generic outmost tag fetcher */
2458 asn_DEF_NO_IntegerInRange6_tags_1,
2459 sizeof(asn_DEF_NO_IntegerInRange6_tags_1)
2460 /sizeof(asn_DEF_NO_IntegerInRange6_tags_1[0]), /* 1 */
2461 asn_DEF_NO_IntegerInRange6_tags_1, /* Same as above */
2462 sizeof(asn_DEF_NO_IntegerInRange6_tags_1)
2463 /sizeof(asn_DEF_NO_IntegerInRange6_tags_1[0]), /* 1 */
2464 &asn_PER_NO_IntegerInRange6_constr_1,
2465 0, 0, /* No members */
2466 0 /* No specifics */
2467};
2468
2469
2470/*** <<< INCLUDES [CN-IntegerEnumerated1] >>> ***/
2471
2472#include <INTEGER.h>
2473
2474/*** <<< DEPS [CN-IntegerEnumerated1] >>> ***/
2475
2476typedef enum CN_IntegerEnumerated1 {
2477 CN_IntegerEnumerated1_a = 1,
2478 CN_IntegerEnumerated1_b = 2
Lev Walkin171487e2006-03-21 07:25:18 +00002479} e_CN_IntegerEnumerated1;
Lev Walkin59b176e2005-11-26 11:25:14 +00002480
2481/*** <<< TYPE-DECLS [CN-IntegerEnumerated1] >>> ***/
2482
2483typedef INTEGER_t CN_IntegerEnumerated1_t;
2484
2485/*** <<< FUNC-DECLS [CN-IntegerEnumerated1] >>> ***/
2486
2487extern asn_TYPE_descriptor_t asn_DEF_CN_IntegerEnumerated1;
2488asn_struct_free_f CN_IntegerEnumerated1_free;
2489asn_struct_print_f CN_IntegerEnumerated1_print;
2490asn_constr_check_f CN_IntegerEnumerated1_constraint;
2491ber_type_decoder_f CN_IntegerEnumerated1_decode_ber;
2492der_type_encoder_f CN_IntegerEnumerated1_encode_der;
2493xer_type_decoder_f CN_IntegerEnumerated1_decode_xer;
2494xer_type_encoder_f CN_IntegerEnumerated1_encode_xer;
2495per_type_decoder_f CN_IntegerEnumerated1_decode_uper;
2496
2497/*** <<< CODE [CN-IntegerEnumerated1] >>> ***/
2498
2499int
2500CN_IntegerEnumerated1_constraint(asn_TYPE_descriptor_t *td, const void *sptr,
2501 asn_app_consume_bytes_f *app_errlog, void *app_key) {
2502 /* Replace with underlying type checker */
2503 td->check_constraints = asn_DEF_INTEGER.check_constraints;
2504 return td->check_constraints(td, sptr, app_errlog, app_key);
2505}
2506
2507/*
2508 * This type is implemented using INTEGER,
2509 * so here we adjust the DEF accordingly.
2510 */
2511static void
2512CN_IntegerEnumerated1_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) {
2513 td->free_struct = asn_DEF_INTEGER.free_struct;
2514 td->print_struct = asn_DEF_INTEGER.print_struct;
2515 td->ber_decoder = asn_DEF_INTEGER.ber_decoder;
2516 td->der_encoder = asn_DEF_INTEGER.der_encoder;
2517 td->xer_decoder = asn_DEF_INTEGER.xer_decoder;
2518 td->xer_encoder = asn_DEF_INTEGER.xer_encoder;
2519 td->uper_decoder = asn_DEF_INTEGER.uper_decoder;
2520 if(!td->per_constraints)
2521 td->per_constraints = asn_DEF_INTEGER.per_constraints;
2522 td->elements = asn_DEF_INTEGER.elements;
2523 td->elements_count = asn_DEF_INTEGER.elements_count;
2524 td->specifics = asn_DEF_INTEGER.specifics;
2525}
2526
2527void
2528CN_IntegerEnumerated1_free(asn_TYPE_descriptor_t *td,
2529 void *struct_ptr, int contents_only) {
2530 CN_IntegerEnumerated1_1_inherit_TYPE_descriptor(td);
2531 td->free_struct(td, struct_ptr, contents_only);
2532}
2533
2534int
2535CN_IntegerEnumerated1_print(asn_TYPE_descriptor_t *td, const void *struct_ptr,
2536 int ilevel, asn_app_consume_bytes_f *cb, void *app_key) {
2537 CN_IntegerEnumerated1_1_inherit_TYPE_descriptor(td);
2538 return td->print_struct(td, struct_ptr, ilevel, cb, app_key);
2539}
2540
2541asn_dec_rval_t
2542CN_IntegerEnumerated1_decode_ber(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td,
2543 void **structure, const void *bufptr, size_t size, int tag_mode) {
2544 CN_IntegerEnumerated1_1_inherit_TYPE_descriptor(td);
2545 return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, tag_mode);
2546}
2547
2548asn_enc_rval_t
2549CN_IntegerEnumerated1_encode_der(asn_TYPE_descriptor_t *td,
2550 void *structure, int tag_mode, ber_tlv_tag_t tag,
2551 asn_app_consume_bytes_f *cb, void *app_key) {
2552 CN_IntegerEnumerated1_1_inherit_TYPE_descriptor(td);
2553 return td->der_encoder(td, structure, tag_mode, tag, cb, app_key);
2554}
2555
2556asn_dec_rval_t
2557CN_IntegerEnumerated1_decode_xer(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td,
2558 void **structure, const char *opt_mname, const void *bufptr, size_t size) {
2559 CN_IntegerEnumerated1_1_inherit_TYPE_descriptor(td);
2560 return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, size);
2561}
2562
2563asn_enc_rval_t
2564CN_IntegerEnumerated1_encode_xer(asn_TYPE_descriptor_t *td, void *structure,
2565 int ilevel, enum xer_encoder_flags_e flags,
2566 asn_app_consume_bytes_f *cb, void *app_key) {
2567 CN_IntegerEnumerated1_1_inherit_TYPE_descriptor(td);
2568 return td->xer_encoder(td, structure, ilevel, flags, cb, app_key);
2569}
2570
2571asn_dec_rval_t
2572CN_IntegerEnumerated1_decode_uper(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td,
2573 asn_per_constraints_t *constraints, void **structure, asn_per_data_t *per_data) {
2574 CN_IntegerEnumerated1_1_inherit_TYPE_descriptor(td);
2575 return td->uper_decoder(opt_codec_ctx, td, constraints, structure, per_data);
2576}
2577
2578
2579/*** <<< STAT-DEFS [CN-IntegerEnumerated1] >>> ***/
2580
2581static ber_tlv_tag_t asn_DEF_CN_IntegerEnumerated1_tags_1[] = {
2582 (ASN_TAG_CLASS_UNIVERSAL | (2 << 2))
2583};
2584asn_TYPE_descriptor_t asn_DEF_CN_IntegerEnumerated1 = {
2585 "CN-IntegerEnumerated1",
2586 "CN-IntegerEnumerated1",
2587 CN_IntegerEnumerated1_free,
2588 CN_IntegerEnumerated1_print,
2589 CN_IntegerEnumerated1_constraint,
2590 CN_IntegerEnumerated1_decode_ber,
2591 CN_IntegerEnumerated1_encode_der,
2592 CN_IntegerEnumerated1_decode_xer,
2593 CN_IntegerEnumerated1_encode_xer,
2594 CN_IntegerEnumerated1_decode_uper,
2595 0, /* Use generic outmost tag fetcher */
2596 asn_DEF_CN_IntegerEnumerated1_tags_1,
2597 sizeof(asn_DEF_CN_IntegerEnumerated1_tags_1)
2598 /sizeof(asn_DEF_CN_IntegerEnumerated1_tags_1[0]), /* 1 */
2599 asn_DEF_CN_IntegerEnumerated1_tags_1, /* Same as above */
2600 sizeof(asn_DEF_CN_IntegerEnumerated1_tags_1)
2601 /sizeof(asn_DEF_CN_IntegerEnumerated1_tags_1[0]), /* 1 */
2602 0, /* No PER visible constraints */
2603 0, 0, /* Defined elsewhere */
2604 0 /* No specifics */
2605};
2606
2607
2608/*** <<< INCLUDES [NO-IntegerEnumerated2] >>> ***/
2609
2610#include <INTEGER.h>
2611
2612/*** <<< DEPS [NO-IntegerEnumerated2] >>> ***/
2613
2614typedef enum NO_IntegerEnumerated2 {
2615 NO_IntegerEnumerated2_a = 1,
2616 NO_IntegerEnumerated2_b = 3000000000
Lev Walkin171487e2006-03-21 07:25:18 +00002617} e_NO_IntegerEnumerated2;
Lev Walkin59b176e2005-11-26 11:25:14 +00002618
2619/*** <<< TYPE-DECLS [NO-IntegerEnumerated2] >>> ***/
2620
2621typedef INTEGER_t NO_IntegerEnumerated2_t;
2622
2623/*** <<< FUNC-DECLS [NO-IntegerEnumerated2] >>> ***/
2624
2625extern asn_TYPE_descriptor_t asn_DEF_NO_IntegerEnumerated2;
2626asn_struct_free_f NO_IntegerEnumerated2_free;
2627asn_struct_print_f NO_IntegerEnumerated2_print;
2628asn_constr_check_f NO_IntegerEnumerated2_constraint;
2629ber_type_decoder_f NO_IntegerEnumerated2_decode_ber;
2630der_type_encoder_f NO_IntegerEnumerated2_encode_der;
2631xer_type_decoder_f NO_IntegerEnumerated2_decode_xer;
2632xer_type_encoder_f NO_IntegerEnumerated2_encode_xer;
2633per_type_decoder_f NO_IntegerEnumerated2_decode_uper;
2634
2635/*** <<< CODE [NO-IntegerEnumerated2] >>> ***/
2636
2637int
2638NO_IntegerEnumerated2_constraint(asn_TYPE_descriptor_t *td, const void *sptr,
2639 asn_app_consume_bytes_f *app_errlog, void *app_key) {
2640 /* Replace with underlying type checker */
2641 td->check_constraints = asn_DEF_INTEGER.check_constraints;
2642 return td->check_constraints(td, sptr, app_errlog, app_key);
2643}
2644
2645/*
2646 * This type is implemented using INTEGER,
2647 * so here we adjust the DEF accordingly.
2648 */
2649static void
2650NO_IntegerEnumerated2_1_inherit_TYPE_descriptor(asn_TYPE_descriptor_t *td) {
2651 td->free_struct = asn_DEF_INTEGER.free_struct;
2652 td->print_struct = asn_DEF_INTEGER.print_struct;
2653 td->ber_decoder = asn_DEF_INTEGER.ber_decoder;
2654 td->der_encoder = asn_DEF_INTEGER.der_encoder;
2655 td->xer_decoder = asn_DEF_INTEGER.xer_decoder;
2656 td->xer_encoder = asn_DEF_INTEGER.xer_encoder;
2657 td->uper_decoder = asn_DEF_INTEGER.uper_decoder;
2658 if(!td->per_constraints)
2659 td->per_constraints = asn_DEF_INTEGER.per_constraints;
2660 td->elements = asn_DEF_INTEGER.elements;
2661 td->elements_count = asn_DEF_INTEGER.elements_count;
2662 td->specifics = asn_DEF_INTEGER.specifics;
2663}
2664
2665void
2666NO_IntegerEnumerated2_free(asn_TYPE_descriptor_t *td,
2667 void *struct_ptr, int contents_only) {
2668 NO_IntegerEnumerated2_1_inherit_TYPE_descriptor(td);
2669 td->free_struct(td, struct_ptr, contents_only);
2670}
2671
2672int
2673NO_IntegerEnumerated2_print(asn_TYPE_descriptor_t *td, const void *struct_ptr,
2674 int ilevel, asn_app_consume_bytes_f *cb, void *app_key) {
2675 NO_IntegerEnumerated2_1_inherit_TYPE_descriptor(td);
2676 return td->print_struct(td, struct_ptr, ilevel, cb, app_key);
2677}
2678
2679asn_dec_rval_t
2680NO_IntegerEnumerated2_decode_ber(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td,
2681 void **structure, const void *bufptr, size_t size, int tag_mode) {
2682 NO_IntegerEnumerated2_1_inherit_TYPE_descriptor(td);
2683 return td->ber_decoder(opt_codec_ctx, td, structure, bufptr, size, tag_mode);
2684}
2685
2686asn_enc_rval_t
2687NO_IntegerEnumerated2_encode_der(asn_TYPE_descriptor_t *td,
2688 void *structure, int tag_mode, ber_tlv_tag_t tag,
2689 asn_app_consume_bytes_f *cb, void *app_key) {
2690 NO_IntegerEnumerated2_1_inherit_TYPE_descriptor(td);
2691 return td->der_encoder(td, structure, tag_mode, tag, cb, app_key);
2692}
2693
2694asn_dec_rval_t
2695NO_IntegerEnumerated2_decode_xer(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td,
2696 void **structure, const char *opt_mname, const void *bufptr, size_t size) {
2697 NO_IntegerEnumerated2_1_inherit_TYPE_descriptor(td);
2698 return td->xer_decoder(opt_codec_ctx, td, structure, opt_mname, bufptr, size);
2699}
2700
2701asn_enc_rval_t
2702NO_IntegerEnumerated2_encode_xer(asn_TYPE_descriptor_t *td, void *structure,
2703 int ilevel, enum xer_encoder_flags_e flags,
2704 asn_app_consume_bytes_f *cb, void *app_key) {
2705 NO_IntegerEnumerated2_1_inherit_TYPE_descriptor(td);
2706 return td->xer_encoder(td, structure, ilevel, flags, cb, app_key);
2707}
2708
2709asn_dec_rval_t
2710NO_IntegerEnumerated2_decode_uper(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td,
2711 asn_per_constraints_t *constraints, void **structure, asn_per_data_t *per_data) {
2712 NO_IntegerEnumerated2_1_inherit_TYPE_descriptor(td);
2713 return td->uper_decoder(opt_codec_ctx, td, constraints, structure, per_data);
2714}
2715
2716
2717/*** <<< STAT-DEFS [NO-IntegerEnumerated2] >>> ***/
2718
2719static ber_tlv_tag_t asn_DEF_NO_IntegerEnumerated2_tags_1[] = {
2720 (ASN_TAG_CLASS_UNIVERSAL | (2 << 2))
2721};
2722asn_TYPE_descriptor_t asn_DEF_NO_IntegerEnumerated2 = {
2723 "NO-IntegerEnumerated2",
2724 "NO-IntegerEnumerated2",
2725 NO_IntegerEnumerated2_free,
2726 NO_IntegerEnumerated2_print,
2727 NO_IntegerEnumerated2_constraint,
2728 NO_IntegerEnumerated2_decode_ber,
2729 NO_IntegerEnumerated2_encode_der,
2730 NO_IntegerEnumerated2_decode_xer,
2731 NO_IntegerEnumerated2_encode_xer,
2732 NO_IntegerEnumerated2_decode_uper,
2733 0, /* Use generic outmost tag fetcher */
2734 asn_DEF_NO_IntegerEnumerated2_tags_1,
2735 sizeof(asn_DEF_NO_IntegerEnumerated2_tags_1)
2736 /sizeof(asn_DEF_NO_IntegerEnumerated2_tags_1[0]), /* 1 */
2737 asn_DEF_NO_IntegerEnumerated2_tags_1, /* Same as above */
2738 sizeof(asn_DEF_NO_IntegerEnumerated2_tags_1)
2739 /sizeof(asn_DEF_NO_IntegerEnumerated2_tags_1[0]), /* 1 */
2740 0, /* No PER visible constraints */
2741 0, 0, /* Defined elsewhere */
2742 0 /* No specifics */
2743};
2744