| |
| /*** <<< INCLUDES [CN-IntegerUnlimited] >>> ***/ |
| |
| #include <INTEGER.h> |
| |
| /*** <<< TYPE-DECLS [CN-IntegerUnlimited] >>> ***/ |
| |
| typedef INTEGER_t CN_IntegerUnlimited_t; |
| |
| /*** <<< FUNC-DECLS [CN-IntegerUnlimited] >>> ***/ |
| |
| extern asn_TYPE_descriptor_t asn_DEF_CN_IntegerUnlimited; |
| asn_struct_free_f CN_IntegerUnlimited_free; |
| asn_struct_print_f CN_IntegerUnlimited_print; |
| asn_constr_check_f CN_IntegerUnlimited_constraint; |
| ber_type_decoder_f CN_IntegerUnlimited_decode_ber; |
| der_type_encoder_f CN_IntegerUnlimited_encode_der; |
| xer_type_decoder_f CN_IntegerUnlimited_decode_xer; |
| xer_type_encoder_f CN_IntegerUnlimited_encode_xer; |
| |
| /*** <<< CODE [CN-IntegerUnlimited] >>> ***/ |
| |
| /* |
| * This type is implemented using INTEGER, |
| * so here we adjust the DEF accordingly. |
| */ |
| |
| /*** <<< STAT-DEFS [CN-IntegerUnlimited] >>> ***/ |
| |
| static const ber_tlv_tag_t asn_DEF_CN_IntegerUnlimited_tags_1[] = { |
| (ASN_TAG_CLASS_UNIVERSAL | (2 << 2)) |
| }; |
| asn_TYPE_descriptor_t asn_DEF_CN_IntegerUnlimited = { |
| "CN-IntegerUnlimited", |
| "CN-IntegerUnlimited", |
| INTEGER_free, |
| INTEGER_print, |
| INTEGER_constraint, |
| INTEGER_decode_ber, |
| INTEGER_encode_der, |
| INTEGER_decode_xer, |
| INTEGER_encode_xer, |
| 0, 0, /* No OER support, use "-gen-OER" to enable */ |
| 0, 0, /* No PER support, use "-gen-PER" to enable */ |
| 0, /* Use generic outmost tag fetcher */ |
| asn_DEF_CN_IntegerUnlimited_tags_1, |
| sizeof(asn_DEF_CN_IntegerUnlimited_tags_1) |
| /sizeof(asn_DEF_CN_IntegerUnlimited_tags_1[0]), /* 1 */ |
| asn_DEF_CN_IntegerUnlimited_tags_1, /* Same as above */ |
| sizeof(asn_DEF_CN_IntegerUnlimited_tags_1) |
| /sizeof(asn_DEF_CN_IntegerUnlimited_tags_1[0]), /* 1 */ |
| 0, /* No OER visible constraints */ |
| 0, /* No PER visible constraints */ |
| 0, 0, /* No members */ |
| 0 /* No specifics */ |
| }; |
| |
| |
| /*** <<< INCLUDES [CN-IntegerMinMax] >>> ***/ |
| |
| #include <INTEGER.h> |
| |
| /*** <<< TYPE-DECLS [CN-IntegerMinMax] >>> ***/ |
| |
| typedef INTEGER_t CN_IntegerMinMax_t; |
| |
| /*** <<< FUNC-DECLS [CN-IntegerMinMax] >>> ***/ |
| |
| extern asn_TYPE_descriptor_t asn_DEF_CN_IntegerMinMax; |
| asn_struct_free_f CN_IntegerMinMax_free; |
| asn_struct_print_f CN_IntegerMinMax_print; |
| asn_constr_check_f CN_IntegerMinMax_constraint; |
| ber_type_decoder_f CN_IntegerMinMax_decode_ber; |
| der_type_encoder_f CN_IntegerMinMax_encode_der; |
| xer_type_decoder_f CN_IntegerMinMax_decode_xer; |
| xer_type_encoder_f CN_IntegerMinMax_encode_xer; |
| |
| /*** <<< CODE [CN-IntegerMinMax] >>> ***/ |
| |
| int |
| CN_IntegerMinMax_constraint(asn_TYPE_descriptor_t *td, const void *sptr, |
| asn_app_constraint_failed_f *ctfailcb, void *app_key) { |
| const INTEGER_t *st = (const INTEGER_t *)sptr; |
| |
| if(!sptr) { |
| ASN__CTFAIL(app_key, td, sptr, |
| "%s: value not given (%s:%d)", |
| td->name, __FILE__, __LINE__); |
| return -1; |
| } |
| |
| |
| if(1 /* No applicable constraints whatsoever */) { |
| (void)st; /* Unused variable */ |
| /* Nothing is here. See below */ |
| } |
| |
| /* Replace with underlying type checker */ |
| td->check_constraints = asn_DEF_INTEGER.check_constraints; |
| return td->check_constraints(td, sptr, ctfailcb, app_key); |
| } |
| |
| /* |
| * This type is implemented using INTEGER, |
| * so here we adjust the DEF accordingly. |
| */ |
| |
| /*** <<< STAT-DEFS [CN-IntegerMinMax] >>> ***/ |
| |
| static const ber_tlv_tag_t asn_DEF_CN_IntegerMinMax_tags_1[] = { |
| (ASN_TAG_CLASS_UNIVERSAL | (2 << 2)) |
| }; |
| asn_TYPE_descriptor_t asn_DEF_CN_IntegerMinMax = { |
| "CN-IntegerMinMax", |
| "CN-IntegerMinMax", |
| INTEGER_free, |
| INTEGER_print, |
| CN_IntegerMinMax_constraint, |
| INTEGER_decode_ber, |
| INTEGER_encode_der, |
| INTEGER_decode_xer, |
| INTEGER_encode_xer, |
| 0, 0, /* No OER support, use "-gen-OER" to enable */ |
| 0, 0, /* No PER support, use "-gen-PER" to enable */ |
| 0, /* Use generic outmost tag fetcher */ |
| asn_DEF_CN_IntegerMinMax_tags_1, |
| sizeof(asn_DEF_CN_IntegerMinMax_tags_1) |
| /sizeof(asn_DEF_CN_IntegerMinMax_tags_1[0]), /* 1 */ |
| asn_DEF_CN_IntegerMinMax_tags_1, /* Same as above */ |
| sizeof(asn_DEF_CN_IntegerMinMax_tags_1) |
| /sizeof(asn_DEF_CN_IntegerMinMax_tags_1[0]), /* 1 */ |
| 0, /* No OER visible constraints */ |
| 0, /* No PER visible constraints */ |
| 0, 0, /* No members */ |
| 0 /* No specifics */ |
| }; |
| |
| |
| /*** <<< INCLUDES [CN-IntegerMinLow] >>> ***/ |
| |
| #include <INTEGER.h> |
| |
| /*** <<< TYPE-DECLS [CN-IntegerMinLow] >>> ***/ |
| |
| typedef INTEGER_t CN_IntegerMinLow_t; |
| |
| /*** <<< FUNC-DECLS [CN-IntegerMinLow] >>> ***/ |
| |
| extern asn_TYPE_descriptor_t asn_DEF_CN_IntegerMinLow; |
| asn_struct_free_f CN_IntegerMinLow_free; |
| asn_struct_print_f CN_IntegerMinLow_print; |
| asn_constr_check_f CN_IntegerMinLow_constraint; |
| ber_type_decoder_f CN_IntegerMinLow_decode_ber; |
| der_type_encoder_f CN_IntegerMinLow_encode_der; |
| xer_type_decoder_f CN_IntegerMinLow_decode_xer; |
| xer_type_encoder_f CN_IntegerMinLow_encode_xer; |
| |
| /*** <<< CODE [CN-IntegerMinLow] >>> ***/ |
| |
| int |
| CN_IntegerMinLow_constraint(asn_TYPE_descriptor_t *td, const void *sptr, |
| asn_app_constraint_failed_f *ctfailcb, void *app_key) { |
| const INTEGER_t *st = (const INTEGER_t *)sptr; |
| long value; |
| |
| if(!sptr) { |
| ASN__CTFAIL(app_key, td, sptr, |
| "%s: value not given (%s:%d)", |
| td->name, __FILE__, __LINE__); |
| return -1; |
| } |
| |
| if(asn_INTEGER2long(st, &value)) { |
| ASN__CTFAIL(app_key, td, sptr, |
| "%s: value too large (%s:%d)", |
| td->name, __FILE__, __LINE__); |
| return -1; |
| } |
| |
| if((value <= 1)) { |
| /* Constraint check succeeded */ |
| return 0; |
| } else { |
| ASN__CTFAIL(app_key, td, sptr, |
| "%s: constraint failed (%s:%d)", |
| td->name, __FILE__, __LINE__); |
| return -1; |
| } |
| } |
| |
| /* |
| * This type is implemented using INTEGER, |
| * so here we adjust the DEF accordingly. |
| */ |
| |
| /*** <<< STAT-DEFS [CN-IntegerMinLow] >>> ***/ |
| |
| static const ber_tlv_tag_t asn_DEF_CN_IntegerMinLow_tags_1[] = { |
| (ASN_TAG_CLASS_UNIVERSAL | (2 << 2)) |
| }; |
| asn_TYPE_descriptor_t asn_DEF_CN_IntegerMinLow = { |
| "CN-IntegerMinLow", |
| "CN-IntegerMinLow", |
| INTEGER_free, |
| INTEGER_print, |
| CN_IntegerMinLow_constraint, |
| INTEGER_decode_ber, |
| INTEGER_encode_der, |
| INTEGER_decode_xer, |
| INTEGER_encode_xer, |
| 0, 0, /* No OER support, use "-gen-OER" to enable */ |
| 0, 0, /* No PER support, use "-gen-PER" to enable */ |
| 0, /* Use generic outmost tag fetcher */ |
| asn_DEF_CN_IntegerMinLow_tags_1, |
| sizeof(asn_DEF_CN_IntegerMinLow_tags_1) |
| /sizeof(asn_DEF_CN_IntegerMinLow_tags_1[0]), /* 1 */ |
| asn_DEF_CN_IntegerMinLow_tags_1, /* Same as above */ |
| sizeof(asn_DEF_CN_IntegerMinLow_tags_1) |
| /sizeof(asn_DEF_CN_IntegerMinLow_tags_1[0]), /* 1 */ |
| 0, /* No OER visible constraints */ |
| 0, /* No PER visible constraints */ |
| 0, 0, /* No members */ |
| 0 /* No specifics */ |
| }; |
| |
| |
| /*** <<< INCLUDES [NO-IntegerMinHigh] >>> ***/ |
| |
| #include <INTEGER.h> |
| |
| /*** <<< TYPE-DECLS [NO-IntegerMinHigh] >>> ***/ |
| |
| typedef INTEGER_t NO_IntegerMinHigh_t; |
| |
| /*** <<< FUNC-DECLS [NO-IntegerMinHigh] >>> ***/ |
| |
| extern asn_TYPE_descriptor_t asn_DEF_NO_IntegerMinHigh; |
| asn_struct_free_f NO_IntegerMinHigh_free; |
| asn_struct_print_f NO_IntegerMinHigh_print; |
| asn_constr_check_f NO_IntegerMinHigh_constraint; |
| ber_type_decoder_f NO_IntegerMinHigh_decode_ber; |
| der_type_encoder_f NO_IntegerMinHigh_encode_der; |
| xer_type_decoder_f NO_IntegerMinHigh_decode_xer; |
| xer_type_encoder_f NO_IntegerMinHigh_encode_xer; |
| |
| /*** <<< CODE [NO-IntegerMinHigh] >>> ***/ |
| |
| int |
| NO_IntegerMinHigh_constraint(asn_TYPE_descriptor_t *td, const void *sptr, |
| asn_app_constraint_failed_f *ctfailcb, void *app_key) { |
| const INTEGER_t *st = (const INTEGER_t *)sptr; |
| long value; |
| |
| if(!sptr) { |
| ASN__CTFAIL(app_key, td, sptr, |
| "%s: value not given (%s:%d)", |
| td->name, __FILE__, __LINE__); |
| return -1; |
| } |
| |
| if(asn_INTEGER2long(st, &value)) { |
| ASN__CTFAIL(app_key, td, sptr, |
| "%s: value too large (%s:%d)", |
| td->name, __FILE__, __LINE__); |
| return -1; |
| } |
| |
| if((value <= 3000000000)) { |
| /* Constraint check succeeded */ |
| return 0; |
| } else { |
| ASN__CTFAIL(app_key, td, sptr, |
| "%s: constraint failed (%s:%d)", |
| td->name, __FILE__, __LINE__); |
| return -1; |
| } |
| } |
| |
| /* |
| * This type is implemented using INTEGER, |
| * so here we adjust the DEF accordingly. |
| */ |
| |
| /*** <<< STAT-DEFS [NO-IntegerMinHigh] >>> ***/ |
| |
| static const ber_tlv_tag_t asn_DEF_NO_IntegerMinHigh_tags_1[] = { |
| (ASN_TAG_CLASS_UNIVERSAL | (2 << 2)) |
| }; |
| asn_TYPE_descriptor_t asn_DEF_NO_IntegerMinHigh = { |
| "NO-IntegerMinHigh", |
| "NO-IntegerMinHigh", |
| INTEGER_free, |
| INTEGER_print, |
| NO_IntegerMinHigh_constraint, |
| INTEGER_decode_ber, |
| INTEGER_encode_der, |
| INTEGER_decode_xer, |
| INTEGER_encode_xer, |
| 0, 0, /* No OER support, use "-gen-OER" to enable */ |
| 0, 0, /* No PER support, use "-gen-PER" to enable */ |
| 0, /* Use generic outmost tag fetcher */ |
| asn_DEF_NO_IntegerMinHigh_tags_1, |
| sizeof(asn_DEF_NO_IntegerMinHigh_tags_1) |
| /sizeof(asn_DEF_NO_IntegerMinHigh_tags_1[0]), /* 1 */ |
| asn_DEF_NO_IntegerMinHigh_tags_1, /* Same as above */ |
| sizeof(asn_DEF_NO_IntegerMinHigh_tags_1) |
| /sizeof(asn_DEF_NO_IntegerMinHigh_tags_1[0]), /* 1 */ |
| 0, /* No OER visible constraints */ |
| 0, /* No PER visible constraints */ |
| 0, 0, /* No members */ |
| 0 /* No specifics */ |
| }; |
| |
| |
| /*** <<< INCLUDES [NO-IntegerLowHigh] >>> ***/ |
| |
| #include <NativeInteger.h> |
| |
| /*** <<< TYPE-DECLS [NO-IntegerLowHigh] >>> ***/ |
| |
| typedef unsigned long NO_IntegerLowHigh_t; |
| |
| /*** <<< FUNC-DECLS [NO-IntegerLowHigh] >>> ***/ |
| |
| extern asn_TYPE_descriptor_t asn_DEF_NO_IntegerLowHigh; |
| asn_struct_free_f NO_IntegerLowHigh_free; |
| asn_struct_print_f NO_IntegerLowHigh_print; |
| asn_constr_check_f NO_IntegerLowHigh_constraint; |
| ber_type_decoder_f NO_IntegerLowHigh_decode_ber; |
| der_type_encoder_f NO_IntegerLowHigh_encode_der; |
| xer_type_decoder_f NO_IntegerLowHigh_decode_xer; |
| xer_type_encoder_f NO_IntegerLowHigh_encode_xer; |
| |
| /*** <<< CODE [NO-IntegerLowHigh] >>> ***/ |
| |
| int |
| NO_IntegerLowHigh_constraint(asn_TYPE_descriptor_t *td, const void *sptr, |
| asn_app_constraint_failed_f *ctfailcb, void *app_key) { |
| unsigned long value; |
| |
| if(!sptr) { |
| ASN__CTFAIL(app_key, td, sptr, |
| "%s: value not given (%s:%d)", |
| td->name, __FILE__, __LINE__); |
| return -1; |
| } |
| |
| value = *(const unsigned long *)sptr; |
| |
| if((value >= 1 && value <= 3000000000)) { |
| /* Constraint check succeeded */ |
| return 0; |
| } else { |
| ASN__CTFAIL(app_key, td, sptr, |
| "%s: constraint failed (%s:%d)", |
| td->name, __FILE__, __LINE__); |
| return -1; |
| } |
| } |
| |
| /* |
| * This type is implemented using NativeInteger, |
| * so here we adjust the DEF accordingly. |
| */ |
| |
| /*** <<< STAT-DEFS [NO-IntegerLowHigh] >>> ***/ |
| |
| static const asn_INTEGER_specifics_t asn_SPC_NO_IntegerLowHigh_specs_1 = { |
| 0, 0, 0, 0, 0, |
| 0, /* Native long size */ |
| 1 /* Unsigned representation */ |
| }; |
| static const ber_tlv_tag_t asn_DEF_NO_IntegerLowHigh_tags_1[] = { |
| (ASN_TAG_CLASS_UNIVERSAL | (2 << 2)) |
| }; |
| asn_TYPE_descriptor_t asn_DEF_NO_IntegerLowHigh = { |
| "NO-IntegerLowHigh", |
| "NO-IntegerLowHigh", |
| NativeInteger_free, |
| NativeInteger_print, |
| NO_IntegerLowHigh_constraint, |
| NativeInteger_decode_ber, |
| NativeInteger_encode_der, |
| NativeInteger_decode_xer, |
| NativeInteger_encode_xer, |
| 0, 0, /* No OER support, use "-gen-OER" to enable */ |
| 0, 0, /* No PER support, use "-gen-PER" to enable */ |
| 0, /* Use generic outmost tag fetcher */ |
| asn_DEF_NO_IntegerLowHigh_tags_1, |
| sizeof(asn_DEF_NO_IntegerLowHigh_tags_1) |
| /sizeof(asn_DEF_NO_IntegerLowHigh_tags_1[0]), /* 1 */ |
| asn_DEF_NO_IntegerLowHigh_tags_1, /* Same as above */ |
| sizeof(asn_DEF_NO_IntegerLowHigh_tags_1) |
| /sizeof(asn_DEF_NO_IntegerLowHigh_tags_1[0]), /* 1 */ |
| 0, /* No OER visible constraints */ |
| 0, /* No PER visible constraints */ |
| 0, 0, /* No members */ |
| &asn_SPC_NO_IntegerLowHigh_specs_1 /* Additional specs */ |
| }; |
| |
| |
| /*** <<< INCLUDES [CN-IntegerLowMax] >>> ***/ |
| |
| #include <INTEGER.h> |
| |
| /*** <<< TYPE-DECLS [CN-IntegerLowMax] >>> ***/ |
| |
| typedef INTEGER_t CN_IntegerLowMax_t; |
| |
| /*** <<< FUNC-DECLS [CN-IntegerLowMax] >>> ***/ |
| |
| extern asn_TYPE_descriptor_t asn_DEF_CN_IntegerLowMax; |
| asn_struct_free_f CN_IntegerLowMax_free; |
| asn_struct_print_f CN_IntegerLowMax_print; |
| asn_constr_check_f CN_IntegerLowMax_constraint; |
| ber_type_decoder_f CN_IntegerLowMax_decode_ber; |
| der_type_encoder_f CN_IntegerLowMax_encode_der; |
| xer_type_decoder_f CN_IntegerLowMax_decode_xer; |
| xer_type_encoder_f CN_IntegerLowMax_encode_xer; |
| |
| /*** <<< CODE [CN-IntegerLowMax] >>> ***/ |
| |
| int |
| CN_IntegerLowMax_constraint(asn_TYPE_descriptor_t *td, const void *sptr, |
| asn_app_constraint_failed_f *ctfailcb, void *app_key) { |
| const INTEGER_t *st = (const INTEGER_t *)sptr; |
| long value; |
| |
| if(!sptr) { |
| ASN__CTFAIL(app_key, td, sptr, |
| "%s: value not given (%s:%d)", |
| td->name, __FILE__, __LINE__); |
| return -1; |
| } |
| |
| if(asn_INTEGER2long(st, &value)) { |
| ASN__CTFAIL(app_key, td, sptr, |
| "%s: value too large (%s:%d)", |
| td->name, __FILE__, __LINE__); |
| return -1; |
| } |
| |
| if((value >= 1)) { |
| /* Constraint check succeeded */ |
| return 0; |
| } else { |
| ASN__CTFAIL(app_key, td, sptr, |
| "%s: constraint failed (%s:%d)", |
| td->name, __FILE__, __LINE__); |
| return -1; |
| } |
| } |
| |
| /* |
| * This type is implemented using INTEGER, |
| * so here we adjust the DEF accordingly. |
| */ |
| |
| /*** <<< STAT-DEFS [CN-IntegerLowMax] >>> ***/ |
| |
| static const ber_tlv_tag_t asn_DEF_CN_IntegerLowMax_tags_1[] = { |
| (ASN_TAG_CLASS_UNIVERSAL | (2 << 2)) |
| }; |
| asn_TYPE_descriptor_t asn_DEF_CN_IntegerLowMax = { |
| "CN-IntegerLowMax", |
| "CN-IntegerLowMax", |
| INTEGER_free, |
| INTEGER_print, |
| CN_IntegerLowMax_constraint, |
| INTEGER_decode_ber, |
| INTEGER_encode_der, |
| INTEGER_decode_xer, |
| INTEGER_encode_xer, |
| 0, 0, /* No OER support, use "-gen-OER" to enable */ |
| 0, 0, /* No PER support, use "-gen-PER" to enable */ |
| 0, /* Use generic outmost tag fetcher */ |
| asn_DEF_CN_IntegerLowMax_tags_1, |
| sizeof(asn_DEF_CN_IntegerLowMax_tags_1) |
| /sizeof(asn_DEF_CN_IntegerLowMax_tags_1[0]), /* 1 */ |
| asn_DEF_CN_IntegerLowMax_tags_1, /* Same as above */ |
| sizeof(asn_DEF_CN_IntegerLowMax_tags_1) |
| /sizeof(asn_DEF_CN_IntegerLowMax_tags_1[0]), /* 1 */ |
| 0, /* No OER visible constraints */ |
| 0, /* No PER visible constraints */ |
| 0, 0, /* No members */ |
| 0 /* No specifics */ |
| }; |
| |
| |
| /*** <<< INCLUDES [NO-IntegerHighMax] >>> ***/ |
| |
| #include <INTEGER.h> |
| |
| /*** <<< TYPE-DECLS [NO-IntegerHighMax] >>> ***/ |
| |
| typedef INTEGER_t NO_IntegerHighMax_t; |
| |
| /*** <<< FUNC-DECLS [NO-IntegerHighMax] >>> ***/ |
| |
| extern asn_TYPE_descriptor_t asn_DEF_NO_IntegerHighMax; |
| asn_struct_free_f NO_IntegerHighMax_free; |
| asn_struct_print_f NO_IntegerHighMax_print; |
| asn_constr_check_f NO_IntegerHighMax_constraint; |
| ber_type_decoder_f NO_IntegerHighMax_decode_ber; |
| der_type_encoder_f NO_IntegerHighMax_encode_der; |
| xer_type_decoder_f NO_IntegerHighMax_decode_xer; |
| xer_type_encoder_f NO_IntegerHighMax_encode_xer; |
| |
| /*** <<< CODE [NO-IntegerHighMax] >>> ***/ |
| |
| int |
| NO_IntegerHighMax_constraint(asn_TYPE_descriptor_t *td, const void *sptr, |
| asn_app_constraint_failed_f *ctfailcb, void *app_key) { |
| const INTEGER_t *st = (const INTEGER_t *)sptr; |
| long value; |
| |
| if(!sptr) { |
| ASN__CTFAIL(app_key, td, sptr, |
| "%s: value not given (%s:%d)", |
| td->name, __FILE__, __LINE__); |
| return -1; |
| } |
| |
| if(asn_INTEGER2long(st, &value)) { |
| ASN__CTFAIL(app_key, td, sptr, |
| "%s: value too large (%s:%d)", |
| td->name, __FILE__, __LINE__); |
| return -1; |
| } |
| |
| if((value >= 3000000000)) { |
| /* Constraint check succeeded */ |
| return 0; |
| } else { |
| ASN__CTFAIL(app_key, td, sptr, |
| "%s: constraint failed (%s:%d)", |
| td->name, __FILE__, __LINE__); |
| return -1; |
| } |
| } |
| |
| /* |
| * This type is implemented using INTEGER, |
| * so here we adjust the DEF accordingly. |
| */ |
| |
| /*** <<< STAT-DEFS [NO-IntegerHighMax] >>> ***/ |
| |
| static const ber_tlv_tag_t asn_DEF_NO_IntegerHighMax_tags_1[] = { |
| (ASN_TAG_CLASS_UNIVERSAL | (2 << 2)) |
| }; |
| asn_TYPE_descriptor_t asn_DEF_NO_IntegerHighMax = { |
| "NO-IntegerHighMax", |
| "NO-IntegerHighMax", |
| INTEGER_free, |
| INTEGER_print, |
| NO_IntegerHighMax_constraint, |
| INTEGER_decode_ber, |
| INTEGER_encode_der, |
| INTEGER_decode_xer, |
| INTEGER_encode_xer, |
| 0, 0, /* No OER support, use "-gen-OER" to enable */ |
| 0, 0, /* No PER support, use "-gen-PER" to enable */ |
| 0, /* Use generic outmost tag fetcher */ |
| asn_DEF_NO_IntegerHighMax_tags_1, |
| sizeof(asn_DEF_NO_IntegerHighMax_tags_1) |
| /sizeof(asn_DEF_NO_IntegerHighMax_tags_1[0]), /* 1 */ |
| asn_DEF_NO_IntegerHighMax_tags_1, /* Same as above */ |
| sizeof(asn_DEF_NO_IntegerHighMax_tags_1) |
| /sizeof(asn_DEF_NO_IntegerHighMax_tags_1[0]), /* 1 */ |
| 0, /* No OER visible constraints */ |
| 0, /* No PER visible constraints */ |
| 0, 0, /* No members */ |
| 0 /* No specifics */ |
| }; |
| |
| |
| /*** <<< INCLUDES [NO-IntegerLowestMax] >>> ***/ |
| |
| #include <INTEGER.h> |
| |
| /*** <<< TYPE-DECLS [NO-IntegerLowestMax] >>> ***/ |
| |
| typedef INTEGER_t NO_IntegerLowestMax_t; |
| |
| /*** <<< FUNC-DECLS [NO-IntegerLowestMax] >>> ***/ |
| |
| extern asn_TYPE_descriptor_t asn_DEF_NO_IntegerLowestMax; |
| asn_struct_free_f NO_IntegerLowestMax_free; |
| asn_struct_print_f NO_IntegerLowestMax_print; |
| asn_constr_check_f NO_IntegerLowestMax_constraint; |
| ber_type_decoder_f NO_IntegerLowestMax_decode_ber; |
| der_type_encoder_f NO_IntegerLowestMax_encode_der; |
| xer_type_decoder_f NO_IntegerLowestMax_decode_xer; |
| xer_type_encoder_f NO_IntegerLowestMax_encode_xer; |
| |
| /*** <<< CODE [NO-IntegerLowestMax] >>> ***/ |
| |
| int |
| NO_IntegerLowestMax_constraint(asn_TYPE_descriptor_t *td, const void *sptr, |
| asn_app_constraint_failed_f *ctfailcb, void *app_key) { |
| const INTEGER_t *st = (const INTEGER_t *)sptr; |
| long value; |
| |
| if(!sptr) { |
| ASN__CTFAIL(app_key, td, sptr, |
| "%s: value not given (%s:%d)", |
| td->name, __FILE__, __LINE__); |
| return -1; |
| } |
| |
| if(asn_INTEGER2long(st, &value)) { |
| ASN__CTFAIL(app_key, td, sptr, |
| "%s: value too large (%s:%d)", |
| td->name, __FILE__, __LINE__); |
| return -1; |
| } |
| |
| if((value >= -3000000000)) { |
| /* Constraint check succeeded */ |
| return 0; |
| } else { |
| ASN__CTFAIL(app_key, td, sptr, |
| "%s: constraint failed (%s:%d)", |
| td->name, __FILE__, __LINE__); |
| return -1; |
| } |
| } |
| |
| /* |
| * This type is implemented using INTEGER, |
| * so here we adjust the DEF accordingly. |
| */ |
| |
| /*** <<< STAT-DEFS [NO-IntegerLowestMax] >>> ***/ |
| |
| static const ber_tlv_tag_t asn_DEF_NO_IntegerLowestMax_tags_1[] = { |
| (ASN_TAG_CLASS_UNIVERSAL | (2 << 2)) |
| }; |
| asn_TYPE_descriptor_t asn_DEF_NO_IntegerLowestMax = { |
| "NO-IntegerLowestMax", |
| "NO-IntegerLowestMax", |
| INTEGER_free, |
| INTEGER_print, |
| NO_IntegerLowestMax_constraint, |
| INTEGER_decode_ber, |
| INTEGER_encode_der, |
| INTEGER_decode_xer, |
| INTEGER_encode_xer, |
| 0, 0, /* No OER support, use "-gen-OER" to enable */ |
| 0, 0, /* No PER support, use "-gen-PER" to enable */ |
| 0, /* Use generic outmost tag fetcher */ |
| asn_DEF_NO_IntegerLowestMax_tags_1, |
| sizeof(asn_DEF_NO_IntegerLowestMax_tags_1) |
| /sizeof(asn_DEF_NO_IntegerLowestMax_tags_1[0]), /* 1 */ |
| asn_DEF_NO_IntegerLowestMax_tags_1, /* Same as above */ |
| sizeof(asn_DEF_NO_IntegerLowestMax_tags_1) |
| /sizeof(asn_DEF_NO_IntegerLowestMax_tags_1[0]), /* 1 */ |
| 0, /* No OER visible constraints */ |
| 0, /* No PER visible constraints */ |
| 0, 0, /* No members */ |
| 0 /* No specifics */ |
| }; |
| |
| |
| /*** <<< INCLUDES [NO-IntegerOutRange] >>> ***/ |
| |
| #include <NativeInteger.h> |
| |
| /*** <<< TYPE-DECLS [NO-IntegerOutRange] >>> ***/ |
| |
| typedef unsigned long NO_IntegerOutRange_t; |
| |
| /*** <<< FUNC-DECLS [NO-IntegerOutRange] >>> ***/ |
| |
| extern asn_TYPE_descriptor_t asn_DEF_NO_IntegerOutRange; |
| asn_struct_free_f NO_IntegerOutRange_free; |
| asn_struct_print_f NO_IntegerOutRange_print; |
| asn_constr_check_f NO_IntegerOutRange_constraint; |
| ber_type_decoder_f NO_IntegerOutRange_decode_ber; |
| der_type_encoder_f NO_IntegerOutRange_encode_der; |
| xer_type_decoder_f NO_IntegerOutRange_decode_xer; |
| xer_type_encoder_f NO_IntegerOutRange_encode_xer; |
| |
| /*** <<< CODE [NO-IntegerOutRange] >>> ***/ |
| |
| int |
| NO_IntegerOutRange_constraint(asn_TYPE_descriptor_t *td, const void *sptr, |
| asn_app_constraint_failed_f *ctfailcb, void *app_key) { |
| unsigned long value; |
| |
| if(!sptr) { |
| ASN__CTFAIL(app_key, td, sptr, |
| "%s: value not given (%s:%d)", |
| td->name, __FILE__, __LINE__); |
| return -1; |
| } |
| |
| value = *(const unsigned long *)sptr; |
| |
| if((value >= 3000000000 && value <= 3000000001)) { |
| /* Constraint check succeeded */ |
| return 0; |
| } else { |
| ASN__CTFAIL(app_key, td, sptr, |
| "%s: constraint failed (%s:%d)", |
| td->name, __FILE__, __LINE__); |
| return -1; |
| } |
| } |
| |
| /* |
| * This type is implemented using NativeInteger, |
| * so here we adjust the DEF accordingly. |
| */ |
| |
| /*** <<< STAT-DEFS [NO-IntegerOutRange] >>> ***/ |
| |
| static const asn_INTEGER_specifics_t asn_SPC_NO_IntegerOutRange_specs_1 = { |
| 0, 0, 0, 0, 0, |
| 0, /* Native long size */ |
| 1 /* Unsigned representation */ |
| }; |
| static const ber_tlv_tag_t asn_DEF_NO_IntegerOutRange_tags_1[] = { |
| (ASN_TAG_CLASS_UNIVERSAL | (2 << 2)) |
| }; |
| asn_TYPE_descriptor_t asn_DEF_NO_IntegerOutRange = { |
| "NO-IntegerOutRange", |
| "NO-IntegerOutRange", |
| NativeInteger_free, |
| NativeInteger_print, |
| NO_IntegerOutRange_constraint, |
| NativeInteger_decode_ber, |
| NativeInteger_encode_der, |
| NativeInteger_decode_xer, |
| NativeInteger_encode_xer, |
| 0, 0, /* No OER support, use "-gen-OER" to enable */ |
| 0, 0, /* No PER support, use "-gen-PER" to enable */ |
| 0, /* Use generic outmost tag fetcher */ |
| asn_DEF_NO_IntegerOutRange_tags_1, |
| sizeof(asn_DEF_NO_IntegerOutRange_tags_1) |
| /sizeof(asn_DEF_NO_IntegerOutRange_tags_1[0]), /* 1 */ |
| asn_DEF_NO_IntegerOutRange_tags_1, /* Same as above */ |
| sizeof(asn_DEF_NO_IntegerOutRange_tags_1) |
| /sizeof(asn_DEF_NO_IntegerOutRange_tags_1[0]), /* 1 */ |
| 0, /* No OER visible constraints */ |
| 0, /* No PER visible constraints */ |
| 0, 0, /* No members */ |
| &asn_SPC_NO_IntegerOutRange_specs_1 /* Additional specs */ |
| }; |
| |
| |
| /*** <<< INCLUDES [NO-IntegerOutValue] >>> ***/ |
| |
| #include <NativeInteger.h> |
| |
| /*** <<< TYPE-DECLS [NO-IntegerOutValue] >>> ***/ |
| |
| typedef unsigned long NO_IntegerOutValue_t; |
| |
| /*** <<< FUNC-DECLS [NO-IntegerOutValue] >>> ***/ |
| |
| extern asn_TYPE_descriptor_t asn_DEF_NO_IntegerOutValue; |
| asn_struct_free_f NO_IntegerOutValue_free; |
| asn_struct_print_f NO_IntegerOutValue_print; |
| asn_constr_check_f NO_IntegerOutValue_constraint; |
| ber_type_decoder_f NO_IntegerOutValue_decode_ber; |
| der_type_encoder_f NO_IntegerOutValue_encode_der; |
| xer_type_decoder_f NO_IntegerOutValue_decode_xer; |
| xer_type_encoder_f NO_IntegerOutValue_encode_xer; |
| |
| /*** <<< CODE [NO-IntegerOutValue] >>> ***/ |
| |
| int |
| NO_IntegerOutValue_constraint(asn_TYPE_descriptor_t *td, const void *sptr, |
| asn_app_constraint_failed_f *ctfailcb, void *app_key) { |
| unsigned long value; |
| |
| if(!sptr) { |
| ASN__CTFAIL(app_key, td, sptr, |
| "%s: value not given (%s:%d)", |
| td->name, __FILE__, __LINE__); |
| return -1; |
| } |
| |
| value = *(const unsigned long *)sptr; |
| |
| if((value == 3000000000)) { |
| /* Constraint check succeeded */ |
| return 0; |
| } else { |
| ASN__CTFAIL(app_key, td, sptr, |
| "%s: constraint failed (%s:%d)", |
| td->name, __FILE__, __LINE__); |
| return -1; |
| } |
| } |
| |
| /* |
| * This type is implemented using NativeInteger, |
| * so here we adjust the DEF accordingly. |
| */ |
| |
| /*** <<< STAT-DEFS [NO-IntegerOutValue] >>> ***/ |
| |
| static const asn_INTEGER_specifics_t asn_SPC_NO_IntegerOutValue_specs_1 = { |
| 0, 0, 0, 0, 0, |
| 0, /* Native long size */ |
| 1 /* Unsigned representation */ |
| }; |
| static const ber_tlv_tag_t asn_DEF_NO_IntegerOutValue_tags_1[] = { |
| (ASN_TAG_CLASS_UNIVERSAL | (2 << 2)) |
| }; |
| asn_TYPE_descriptor_t asn_DEF_NO_IntegerOutValue = { |
| "NO-IntegerOutValue", |
| "NO-IntegerOutValue", |
| NativeInteger_free, |
| NativeInteger_print, |
| NO_IntegerOutValue_constraint, |
| NativeInteger_decode_ber, |
| NativeInteger_encode_der, |
| NativeInteger_decode_xer, |
| NativeInteger_encode_xer, |
| 0, 0, /* No OER support, use "-gen-OER" to enable */ |
| 0, 0, /* No PER support, use "-gen-PER" to enable */ |
| 0, /* Use generic outmost tag fetcher */ |
| asn_DEF_NO_IntegerOutValue_tags_1, |
| sizeof(asn_DEF_NO_IntegerOutValue_tags_1) |
| /sizeof(asn_DEF_NO_IntegerOutValue_tags_1[0]), /* 1 */ |
| asn_DEF_NO_IntegerOutValue_tags_1, /* Same as above */ |
| sizeof(asn_DEF_NO_IntegerOutValue_tags_1) |
| /sizeof(asn_DEF_NO_IntegerOutValue_tags_1[0]), /* 1 */ |
| 0, /* No OER visible constraints */ |
| 0, /* No PER visible constraints */ |
| 0, 0, /* No members */ |
| &asn_SPC_NO_IntegerOutValue_specs_1 /* Additional specs */ |
| }; |
| |
| |
| /*** <<< INCLUDES [OK-IntegerInRange1] >>> ***/ |
| |
| #include <NativeInteger.h> |
| |
| /*** <<< TYPE-DECLS [OK-IntegerInRange1] >>> ***/ |
| |
| typedef long OK_IntegerInRange1_t; |
| |
| /*** <<< FUNC-DECLS [OK-IntegerInRange1] >>> ***/ |
| |
| extern asn_TYPE_descriptor_t asn_DEF_OK_IntegerInRange1; |
| asn_struct_free_f OK_IntegerInRange1_free; |
| asn_struct_print_f OK_IntegerInRange1_print; |
| asn_constr_check_f OK_IntegerInRange1_constraint; |
| ber_type_decoder_f OK_IntegerInRange1_decode_ber; |
| der_type_encoder_f OK_IntegerInRange1_encode_der; |
| xer_type_decoder_f OK_IntegerInRange1_decode_xer; |
| xer_type_encoder_f OK_IntegerInRange1_encode_xer; |
| |
| /*** <<< CODE [OK-IntegerInRange1] >>> ***/ |
| |
| int |
| OK_IntegerInRange1_constraint(asn_TYPE_descriptor_t *td, const void *sptr, |
| asn_app_constraint_failed_f *ctfailcb, void *app_key) { |
| long value; |
| |
| if(!sptr) { |
| ASN__CTFAIL(app_key, td, sptr, |
| "%s: value not given (%s:%d)", |
| td->name, __FILE__, __LINE__); |
| return -1; |
| } |
| |
| value = *(const long *)sptr; |
| |
| if((value >= -100 && value <= 100)) { |
| /* Constraint check succeeded */ |
| return 0; |
| } else { |
| ASN__CTFAIL(app_key, td, sptr, |
| "%s: constraint failed (%s:%d)", |
| td->name, __FILE__, __LINE__); |
| return -1; |
| } |
| } |
| |
| /* |
| * This type is implemented using NativeInteger, |
| * so here we adjust the DEF accordingly. |
| */ |
| |
| /*** <<< STAT-DEFS [OK-IntegerInRange1] >>> ***/ |
| |
| static const ber_tlv_tag_t asn_DEF_OK_IntegerInRange1_tags_1[] = { |
| (ASN_TAG_CLASS_UNIVERSAL | (2 << 2)) |
| }; |
| asn_TYPE_descriptor_t asn_DEF_OK_IntegerInRange1 = { |
| "OK-IntegerInRange1", |
| "OK-IntegerInRange1", |
| NativeInteger_free, |
| NativeInteger_print, |
| OK_IntegerInRange1_constraint, |
| NativeInteger_decode_ber, |
| NativeInteger_encode_der, |
| NativeInteger_decode_xer, |
| NativeInteger_encode_xer, |
| 0, 0, /* No OER support, use "-gen-OER" to enable */ |
| 0, 0, /* No PER support, use "-gen-PER" to enable */ |
| 0, /* Use generic outmost tag fetcher */ |
| asn_DEF_OK_IntegerInRange1_tags_1, |
| sizeof(asn_DEF_OK_IntegerInRange1_tags_1) |
| /sizeof(asn_DEF_OK_IntegerInRange1_tags_1[0]), /* 1 */ |
| asn_DEF_OK_IntegerInRange1_tags_1, /* Same as above */ |
| sizeof(asn_DEF_OK_IntegerInRange1_tags_1) |
| /sizeof(asn_DEF_OK_IntegerInRange1_tags_1[0]), /* 1 */ |
| 0, /* No OER visible constraints */ |
| 0, /* No PER visible constraints */ |
| 0, 0, /* No members */ |
| 0 /* No specifics */ |
| }; |
| |
| |
| /*** <<< INCLUDES [OK-IntegerInRange2] >>> ***/ |
| |
| #include <NativeInteger.h> |
| |
| /*** <<< TYPE-DECLS [OK-IntegerInRange2] >>> ***/ |
| |
| typedef long OK_IntegerInRange2_t; |
| |
| /*** <<< FUNC-DECLS [OK-IntegerInRange2] >>> ***/ |
| |
| extern asn_TYPE_descriptor_t asn_DEF_OK_IntegerInRange2; |
| asn_struct_free_f OK_IntegerInRange2_free; |
| asn_struct_print_f OK_IntegerInRange2_print; |
| asn_constr_check_f OK_IntegerInRange2_constraint; |
| ber_type_decoder_f OK_IntegerInRange2_decode_ber; |
| der_type_encoder_f OK_IntegerInRange2_encode_der; |
| xer_type_decoder_f OK_IntegerInRange2_decode_xer; |
| xer_type_encoder_f OK_IntegerInRange2_encode_xer; |
| |
| /*** <<< CODE [OK-IntegerInRange2] >>> ***/ |
| |
| int |
| OK_IntegerInRange2_constraint(asn_TYPE_descriptor_t *td, const void *sptr, |
| asn_app_constraint_failed_f *ctfailcb, void *app_key) { |
| long value; |
| |
| if(!sptr) { |
| ASN__CTFAIL(app_key, td, sptr, |
| "%s: value not given (%s:%d)", |
| td->name, __FILE__, __LINE__); |
| return -1; |
| } |
| |
| value = *(const long *)sptr; |
| |
| if(((value == -100) || (value == 100))) { |
| /* Constraint check succeeded */ |
| return 0; |
| } else { |
| ASN__CTFAIL(app_key, td, sptr, |
| "%s: constraint failed (%s:%d)", |
| td->name, __FILE__, __LINE__); |
| return -1; |
| } |
| } |
| |
| /* |
| * This type is implemented using NativeInteger, |
| * so here we adjust the DEF accordingly. |
| */ |
| |
| /*** <<< STAT-DEFS [OK-IntegerInRange2] >>> ***/ |
| |
| static const ber_tlv_tag_t asn_DEF_OK_IntegerInRange2_tags_1[] = { |
| (ASN_TAG_CLASS_UNIVERSAL | (2 << 2)) |
| }; |
| asn_TYPE_descriptor_t asn_DEF_OK_IntegerInRange2 = { |
| "OK-IntegerInRange2", |
| "OK-IntegerInRange2", |
| NativeInteger_free, |
| NativeInteger_print, |
| OK_IntegerInRange2_constraint, |
| NativeInteger_decode_ber, |
| NativeInteger_encode_der, |
| NativeInteger_decode_xer, |
| NativeInteger_encode_xer, |
| 0, 0, /* No OER support, use "-gen-OER" to enable */ |
| 0, 0, /* No PER support, use "-gen-PER" to enable */ |
| 0, /* Use generic outmost tag fetcher */ |
| asn_DEF_OK_IntegerInRange2_tags_1, |
| sizeof(asn_DEF_OK_IntegerInRange2_tags_1) |
| /sizeof(asn_DEF_OK_IntegerInRange2_tags_1[0]), /* 1 */ |
| asn_DEF_OK_IntegerInRange2_tags_1, /* Same as above */ |
| sizeof(asn_DEF_OK_IntegerInRange2_tags_1) |
| /sizeof(asn_DEF_OK_IntegerInRange2_tags_1[0]), /* 1 */ |
| 0, /* No OER visible constraints */ |
| 0, /* No PER visible constraints */ |
| 0, 0, /* No members */ |
| 0 /* No specifics */ |
| }; |
| |
| |
| /*** <<< INCLUDES [OK-IntegerInRange3] >>> ***/ |
| |
| #include <NativeInteger.h> |
| |
| /*** <<< TYPE-DECLS [OK-IntegerInRange3] >>> ***/ |
| |
| typedef long OK_IntegerInRange3_t; |
| |
| /*** <<< FUNC-DECLS [OK-IntegerInRange3] >>> ***/ |
| |
| extern asn_TYPE_descriptor_t asn_DEF_OK_IntegerInRange3; |
| asn_struct_free_f OK_IntegerInRange3_free; |
| asn_struct_print_f OK_IntegerInRange3_print; |
| asn_constr_check_f OK_IntegerInRange3_constraint; |
| ber_type_decoder_f OK_IntegerInRange3_decode_ber; |
| der_type_encoder_f OK_IntegerInRange3_encode_der; |
| xer_type_decoder_f OK_IntegerInRange3_decode_xer; |
| xer_type_encoder_f OK_IntegerInRange3_encode_xer; |
| |
| /*** <<< CODE [OK-IntegerInRange3] >>> ***/ |
| |
| int |
| OK_IntegerInRange3_constraint(asn_TYPE_descriptor_t *td, const void *sptr, |
| asn_app_constraint_failed_f *ctfailcb, void *app_key) { |
| long value; |
| |
| if(!sptr) { |
| ASN__CTFAIL(app_key, td, sptr, |
| "%s: value not given (%s:%d)", |
| td->name, __FILE__, __LINE__); |
| return -1; |
| } |
| |
| value = *(const long *)sptr; |
| |
| if((value >= (-2147483647L - 1) && value <= 2147483647)) { |
| /* Constraint check succeeded */ |
| return 0; |
| } else { |
| ASN__CTFAIL(app_key, td, sptr, |
| "%s: constraint failed (%s:%d)", |
| td->name, __FILE__, __LINE__); |
| return -1; |
| } |
| } |
| |
| /* |
| * This type is implemented using NativeInteger, |
| * so here we adjust the DEF accordingly. |
| */ |
| |
| /*** <<< STAT-DEFS [OK-IntegerInRange3] >>> ***/ |
| |
| static const ber_tlv_tag_t asn_DEF_OK_IntegerInRange3_tags_1[] = { |
| (ASN_TAG_CLASS_UNIVERSAL | (2 << 2)) |
| }; |
| asn_TYPE_descriptor_t asn_DEF_OK_IntegerInRange3 = { |
| "OK-IntegerInRange3", |
| "OK-IntegerInRange3", |
| NativeInteger_free, |
| NativeInteger_print, |
| OK_IntegerInRange3_constraint, |
| NativeInteger_decode_ber, |
| NativeInteger_encode_der, |
| NativeInteger_decode_xer, |
| NativeInteger_encode_xer, |
| 0, 0, /* No OER support, use "-gen-OER" to enable */ |
| 0, 0, /* No PER support, use "-gen-PER" to enable */ |
| 0, /* Use generic outmost tag fetcher */ |
| asn_DEF_OK_IntegerInRange3_tags_1, |
| sizeof(asn_DEF_OK_IntegerInRange3_tags_1) |
| /sizeof(asn_DEF_OK_IntegerInRange3_tags_1[0]), /* 1 */ |
| asn_DEF_OK_IntegerInRange3_tags_1, /* Same as above */ |
| sizeof(asn_DEF_OK_IntegerInRange3_tags_1) |
| /sizeof(asn_DEF_OK_IntegerInRange3_tags_1[0]), /* 1 */ |
| 0, /* No OER visible constraints */ |
| 0, /* No PER visible constraints */ |
| 0, 0, /* No members */ |
| 0 /* No specifics */ |
| }; |
| |
| |
| /*** <<< INCLUDES [OK-IntegerInRange4] >>> ***/ |
| |
| #include <NativeInteger.h> |
| |
| /*** <<< TYPE-DECLS [OK-IntegerInRange4] >>> ***/ |
| |
| typedef long OK_IntegerInRange4_t; |
| |
| /*** <<< FUNC-DECLS [OK-IntegerInRange4] >>> ***/ |
| |
| extern asn_TYPE_descriptor_t asn_DEF_OK_IntegerInRange4; |
| asn_struct_free_f OK_IntegerInRange4_free; |
| asn_struct_print_f OK_IntegerInRange4_print; |
| asn_constr_check_f OK_IntegerInRange4_constraint; |
| ber_type_decoder_f OK_IntegerInRange4_decode_ber; |
| der_type_encoder_f OK_IntegerInRange4_encode_der; |
| xer_type_decoder_f OK_IntegerInRange4_decode_xer; |
| xer_type_encoder_f OK_IntegerInRange4_encode_xer; |
| |
| /*** <<< CODE [OK-IntegerInRange4] >>> ***/ |
| |
| int |
| OK_IntegerInRange4_constraint(asn_TYPE_descriptor_t *td, const void *sptr, |
| asn_app_constraint_failed_f *ctfailcb, void *app_key) { |
| long value; |
| |
| if(!sptr) { |
| ASN__CTFAIL(app_key, td, sptr, |
| "%s: value not given (%s:%d)", |
| td->name, __FILE__, __LINE__); |
| return -1; |
| } |
| |
| value = *(const long *)sptr; |
| |
| if(((value == (-2147483647L - 1)) || (value == 2147483647))) { |
| /* Constraint check succeeded */ |
| return 0; |
| } else { |
| ASN__CTFAIL(app_key, td, sptr, |
| "%s: constraint failed (%s:%d)", |
| td->name, __FILE__, __LINE__); |
| return -1; |
| } |
| } |
| |
| /* |
| * This type is implemented using NativeInteger, |
| * so here we adjust the DEF accordingly. |
| */ |
| |
| /*** <<< STAT-DEFS [OK-IntegerInRange4] >>> ***/ |
| |
| static const ber_tlv_tag_t asn_DEF_OK_IntegerInRange4_tags_1[] = { |
| (ASN_TAG_CLASS_UNIVERSAL | (2 << 2)) |
| }; |
| asn_TYPE_descriptor_t asn_DEF_OK_IntegerInRange4 = { |
| "OK-IntegerInRange4", |
| "OK-IntegerInRange4", |
| NativeInteger_free, |
| NativeInteger_print, |
| OK_IntegerInRange4_constraint, |
| NativeInteger_decode_ber, |
| NativeInteger_encode_der, |
| NativeInteger_decode_xer, |
| NativeInteger_encode_xer, |
| 0, 0, /* No OER support, use "-gen-OER" to enable */ |
| 0, 0, /* No PER support, use "-gen-PER" to enable */ |
| 0, /* Use generic outmost tag fetcher */ |
| asn_DEF_OK_IntegerInRange4_tags_1, |
| sizeof(asn_DEF_OK_IntegerInRange4_tags_1) |
| /sizeof(asn_DEF_OK_IntegerInRange4_tags_1[0]), /* 1 */ |
| asn_DEF_OK_IntegerInRange4_tags_1, /* Same as above */ |
| sizeof(asn_DEF_OK_IntegerInRange4_tags_1) |
| /sizeof(asn_DEF_OK_IntegerInRange4_tags_1[0]), /* 1 */ |
| 0, /* No OER visible constraints */ |
| 0, /* No PER visible constraints */ |
| 0, 0, /* No members */ |
| 0 /* No specifics */ |
| }; |
| |
| |
| /*** <<< INCLUDES [OK-IntegerInRange5] >>> ***/ |
| |
| #include <INTEGER.h> |
| |
| /*** <<< TYPE-DECLS [OK-IntegerInRange5] >>> ***/ |
| |
| typedef INTEGER_t OK_IntegerInRange5_t; |
| |
| /*** <<< FUNC-DECLS [OK-IntegerInRange5] >>> ***/ |
| |
| extern asn_TYPE_descriptor_t asn_DEF_OK_IntegerInRange5; |
| asn_struct_free_f OK_IntegerInRange5_free; |
| asn_struct_print_f OK_IntegerInRange5_print; |
| asn_constr_check_f OK_IntegerInRange5_constraint; |
| ber_type_decoder_f OK_IntegerInRange5_decode_ber; |
| der_type_encoder_f OK_IntegerInRange5_encode_der; |
| xer_type_decoder_f OK_IntegerInRange5_decode_xer; |
| xer_type_encoder_f OK_IntegerInRange5_encode_xer; |
| |
| /*** <<< CODE [OK-IntegerInRange5] >>> ***/ |
| |
| int |
| OK_IntegerInRange5_constraint(asn_TYPE_descriptor_t *td, const void *sptr, |
| asn_app_constraint_failed_f *ctfailcb, void *app_key) { |
| const INTEGER_t *st = (const INTEGER_t *)sptr; |
| long value; |
| |
| if(!sptr) { |
| ASN__CTFAIL(app_key, td, sptr, |
| "%s: value not given (%s:%d)", |
| td->name, __FILE__, __LINE__); |
| return -1; |
| } |
| |
| if(asn_INTEGER2long(st, &value)) { |
| ASN__CTFAIL(app_key, td, sptr, |
| "%s: value too large (%s:%d)", |
| td->name, __FILE__, __LINE__); |
| return -1; |
| } |
| |
| if(((value == (-2147483647L - 1)) || (value == 2147483647))) { |
| /* Constraint check succeeded */ |
| return 0; |
| } else { |
| ASN__CTFAIL(app_key, td, sptr, |
| "%s: constraint failed (%s:%d)", |
| td->name, __FILE__, __LINE__); |
| return -1; |
| } |
| } |
| |
| /* |
| * This type is implemented using INTEGER, |
| * so here we adjust the DEF accordingly. |
| */ |
| |
| /*** <<< STAT-DEFS [OK-IntegerInRange5] >>> ***/ |
| |
| static const ber_tlv_tag_t asn_DEF_OK_IntegerInRange5_tags_1[] = { |
| (ASN_TAG_CLASS_UNIVERSAL | (2 << 2)) |
| }; |
| asn_TYPE_descriptor_t asn_DEF_OK_IntegerInRange5 = { |
| "OK-IntegerInRange5", |
| "OK-IntegerInRange5", |
| INTEGER_free, |
| INTEGER_print, |
| OK_IntegerInRange5_constraint, |
| INTEGER_decode_ber, |
| INTEGER_encode_der, |
| INTEGER_decode_xer, |
| INTEGER_encode_xer, |
| 0, 0, /* No OER support, use "-gen-OER" to enable */ |
| 0, 0, /* No PER support, use "-gen-PER" to enable */ |
| 0, /* Use generic outmost tag fetcher */ |
| asn_DEF_OK_IntegerInRange5_tags_1, |
| sizeof(asn_DEF_OK_IntegerInRange5_tags_1) |
| /sizeof(asn_DEF_OK_IntegerInRange5_tags_1[0]), /* 1 */ |
| asn_DEF_OK_IntegerInRange5_tags_1, /* Same as above */ |
| sizeof(asn_DEF_OK_IntegerInRange5_tags_1) |
| /sizeof(asn_DEF_OK_IntegerInRange5_tags_1[0]), /* 1 */ |
| 0, /* No OER visible constraints */ |
| 0, /* No PER visible constraints */ |
| 0, 0, /* No members */ |
| 0 /* No specifics */ |
| }; |
| |
| |
| /*** <<< INCLUDES [NO-IntegerInRange6] >>> ***/ |
| |
| #include <NativeInteger.h> |
| |
| /*** <<< TYPE-DECLS [NO-IntegerInRange6] >>> ***/ |
| |
| typedef unsigned long NO_IntegerInRange6_t; |
| |
| /*** <<< FUNC-DECLS [NO-IntegerInRange6] >>> ***/ |
| |
| extern asn_TYPE_descriptor_t asn_DEF_NO_IntegerInRange6; |
| asn_struct_free_f NO_IntegerInRange6_free; |
| asn_struct_print_f NO_IntegerInRange6_print; |
| asn_constr_check_f NO_IntegerInRange6_constraint; |
| ber_type_decoder_f NO_IntegerInRange6_decode_ber; |
| der_type_encoder_f NO_IntegerInRange6_encode_der; |
| xer_type_decoder_f NO_IntegerInRange6_decode_xer; |
| xer_type_encoder_f NO_IntegerInRange6_encode_xer; |
| |
| /*** <<< CODE [NO-IntegerInRange6] >>> ***/ |
| |
| int |
| NO_IntegerInRange6_constraint(asn_TYPE_descriptor_t *td, const void *sptr, |
| asn_app_constraint_failed_f *ctfailcb, void *app_key) { |
| |
| if(!sptr) { |
| ASN__CTFAIL(app_key, td, sptr, |
| "%s: value not given (%s:%d)", |
| td->name, __FILE__, __LINE__); |
| return -1; |
| } |
| |
| |
| /* Constraint check succeeded */ |
| return 0; |
| } |
| |
| /* |
| * This type is implemented using NativeInteger, |
| * so here we adjust the DEF accordingly. |
| */ |
| |
| /*** <<< STAT-DEFS [NO-IntegerInRange6] >>> ***/ |
| |
| static const asn_INTEGER_specifics_t asn_SPC_NO_IntegerInRange6_specs_1 = { |
| 0, 0, 0, 0, 0, |
| 0, /* Native long size */ |
| 1 /* Unsigned representation */ |
| }; |
| static const ber_tlv_tag_t asn_DEF_NO_IntegerInRange6_tags_1[] = { |
| (ASN_TAG_CLASS_UNIVERSAL | (2 << 2)) |
| }; |
| asn_TYPE_descriptor_t asn_DEF_NO_IntegerInRange6 = { |
| "NO-IntegerInRange6", |
| "NO-IntegerInRange6", |
| NativeInteger_free, |
| NativeInteger_print, |
| NO_IntegerInRange6_constraint, |
| NativeInteger_decode_ber, |
| NativeInteger_encode_der, |
| NativeInteger_decode_xer, |
| NativeInteger_encode_xer, |
| 0, 0, /* No OER support, use "-gen-OER" to enable */ |
| 0, 0, /* No PER support, use "-gen-PER" to enable */ |
| 0, /* Use generic outmost tag fetcher */ |
| asn_DEF_NO_IntegerInRange6_tags_1, |
| sizeof(asn_DEF_NO_IntegerInRange6_tags_1) |
| /sizeof(asn_DEF_NO_IntegerInRange6_tags_1[0]), /* 1 */ |
| asn_DEF_NO_IntegerInRange6_tags_1, /* Same as above */ |
| sizeof(asn_DEF_NO_IntegerInRange6_tags_1) |
| /sizeof(asn_DEF_NO_IntegerInRange6_tags_1[0]), /* 1 */ |
| 0, /* No OER visible constraints */ |
| 0, /* No PER visible constraints */ |
| 0, 0, /* No members */ |
| &asn_SPC_NO_IntegerInRange6_specs_1 /* Additional specs */ |
| }; |
| |
| |
| /*** <<< INCLUDES [CN-IntegerEnumerated1] >>> ***/ |
| |
| #include <INTEGER.h> |
| |
| /*** <<< DEPS [CN-IntegerEnumerated1] >>> ***/ |
| |
| typedef enum CN_IntegerEnumerated1 { |
| CN_IntegerEnumerated1_a = 1, |
| CN_IntegerEnumerated1_b = 2 |
| } e_CN_IntegerEnumerated1; |
| |
| /*** <<< TYPE-DECLS [CN-IntegerEnumerated1] >>> ***/ |
| |
| typedef INTEGER_t CN_IntegerEnumerated1_t; |
| |
| /*** <<< FUNC-DECLS [CN-IntegerEnumerated1] >>> ***/ |
| |
| extern asn_TYPE_descriptor_t asn_DEF_CN_IntegerEnumerated1; |
| asn_struct_free_f CN_IntegerEnumerated1_free; |
| asn_struct_print_f CN_IntegerEnumerated1_print; |
| asn_constr_check_f CN_IntegerEnumerated1_constraint; |
| ber_type_decoder_f CN_IntegerEnumerated1_decode_ber; |
| der_type_encoder_f CN_IntegerEnumerated1_encode_der; |
| xer_type_decoder_f CN_IntegerEnumerated1_decode_xer; |
| xer_type_encoder_f CN_IntegerEnumerated1_encode_xer; |
| |
| /*** <<< CODE [CN-IntegerEnumerated1] >>> ***/ |
| |
| /* |
| * This type is implemented using INTEGER, |
| * so here we adjust the DEF accordingly. |
| */ |
| |
| /*** <<< STAT-DEFS [CN-IntegerEnumerated1] >>> ***/ |
| |
| static const ber_tlv_tag_t asn_DEF_CN_IntegerEnumerated1_tags_1[] = { |
| (ASN_TAG_CLASS_UNIVERSAL | (2 << 2)) |
| }; |
| asn_TYPE_descriptor_t asn_DEF_CN_IntegerEnumerated1 = { |
| "CN-IntegerEnumerated1", |
| "CN-IntegerEnumerated1", |
| INTEGER_free, |
| INTEGER_print, |
| INTEGER_constraint, |
| INTEGER_decode_ber, |
| INTEGER_encode_der, |
| INTEGER_decode_xer, |
| INTEGER_encode_xer, |
| 0, 0, /* No OER support, use "-gen-OER" to enable */ |
| 0, 0, /* No PER support, use "-gen-PER" to enable */ |
| 0, /* Use generic outmost tag fetcher */ |
| asn_DEF_CN_IntegerEnumerated1_tags_1, |
| sizeof(asn_DEF_CN_IntegerEnumerated1_tags_1) |
| /sizeof(asn_DEF_CN_IntegerEnumerated1_tags_1[0]), /* 1 */ |
| asn_DEF_CN_IntegerEnumerated1_tags_1, /* Same as above */ |
| sizeof(asn_DEF_CN_IntegerEnumerated1_tags_1) |
| /sizeof(asn_DEF_CN_IntegerEnumerated1_tags_1[0]), /* 1 */ |
| 0, /* No OER visible constraints */ |
| 0, /* No PER visible constraints */ |
| 0, 0, /* Defined elsewhere */ |
| 0 /* No specifics */ |
| }; |
| |
| |
| /*** <<< INCLUDES [NO-IntegerEnumerated2] >>> ***/ |
| |
| #include <INTEGER.h> |
| |
| /*** <<< DEPS [NO-IntegerEnumerated2] >>> ***/ |
| |
| typedef enum NO_IntegerEnumerated2 { |
| NO_IntegerEnumerated2_a = 1, |
| NO_IntegerEnumerated2_b = 3000000000 |
| } e_NO_IntegerEnumerated2; |
| |
| /*** <<< TYPE-DECLS [NO-IntegerEnumerated2] >>> ***/ |
| |
| typedef INTEGER_t NO_IntegerEnumerated2_t; |
| |
| /*** <<< FUNC-DECLS [NO-IntegerEnumerated2] >>> ***/ |
| |
| extern asn_TYPE_descriptor_t asn_DEF_NO_IntegerEnumerated2; |
| asn_struct_free_f NO_IntegerEnumerated2_free; |
| asn_struct_print_f NO_IntegerEnumerated2_print; |
| asn_constr_check_f NO_IntegerEnumerated2_constraint; |
| ber_type_decoder_f NO_IntegerEnumerated2_decode_ber; |
| der_type_encoder_f NO_IntegerEnumerated2_encode_der; |
| xer_type_decoder_f NO_IntegerEnumerated2_decode_xer; |
| xer_type_encoder_f NO_IntegerEnumerated2_encode_xer; |
| |
| /*** <<< CODE [NO-IntegerEnumerated2] >>> ***/ |
| |
| /* |
| * This type is implemented using INTEGER, |
| * so here we adjust the DEF accordingly. |
| */ |
| |
| /*** <<< STAT-DEFS [NO-IntegerEnumerated2] >>> ***/ |
| |
| static const ber_tlv_tag_t asn_DEF_NO_IntegerEnumerated2_tags_1[] = { |
| (ASN_TAG_CLASS_UNIVERSAL | (2 << 2)) |
| }; |
| asn_TYPE_descriptor_t asn_DEF_NO_IntegerEnumerated2 = { |
| "NO-IntegerEnumerated2", |
| "NO-IntegerEnumerated2", |
| INTEGER_free, |
| INTEGER_print, |
| INTEGER_constraint, |
| INTEGER_decode_ber, |
| INTEGER_encode_der, |
| INTEGER_decode_xer, |
| INTEGER_encode_xer, |
| 0, 0, /* No OER support, use "-gen-OER" to enable */ |
| 0, 0, /* No PER support, use "-gen-PER" to enable */ |
| 0, /* Use generic outmost tag fetcher */ |
| asn_DEF_NO_IntegerEnumerated2_tags_1, |
| sizeof(asn_DEF_NO_IntegerEnumerated2_tags_1) |
| /sizeof(asn_DEF_NO_IntegerEnumerated2_tags_1[0]), /* 1 */ |
| asn_DEF_NO_IntegerEnumerated2_tags_1, /* Same as above */ |
| sizeof(asn_DEF_NO_IntegerEnumerated2_tags_1) |
| /sizeof(asn_DEF_NO_IntegerEnumerated2_tags_1[0]), /* 1 */ |
| 0, /* No OER visible constraints */ |
| 0, /* No PER visible constraints */ |
| 0, 0, /* Defined elsewhere */ |
| 0 /* No specifics */ |
| }; |
| |