/* * Generated by asn1c-0.9.29 (http://lionet.info/asn1c) * From ASN.1 module "PEDefinitions" * found in "../../../asn1/PEDefinitions.asn" * `asn1c -fcompound-names -no-gen-example` */ #include "FileManagement.h" static int memb_filePath_constraint_2(const asn_TYPE_descriptor_t *td, const void *sptr, asn_app_constraint_failed_f *ctfailcb, void *app_key) { const OCTET_STRING_t *st = (const OCTET_STRING_t *)sptr; size_t size; if(!sptr) { ASN__CTFAIL(app_key, td, sptr, "%s: value not given (%s:%d)", td->name, __FILE__, __LINE__); return -1; } size = st->size; if((size <= 8)) { /* Constraint check succeeded */ return 0; } else { ASN__CTFAIL(app_key, td, sptr, "%s: constraint failed (%s:%d)", td->name, __FILE__, __LINE__); return -1; } } static asn_oer_constraints_t asn_OER_memb_filePath_constr_3 CC_NOTUSED = { { 0, 0 }, -1 /* (SIZE(0..8)) */}; static asn_per_constraints_t asn_PER_memb_filePath_constr_3 CC_NOTUSED = { { APC_UNCONSTRAINED, -1, -1, 0, 0 }, { APC_CONSTRAINED, 4, 4, 0, 8 } /* (SIZE(0..8)) */, 0, 0 /* No PER value map */ }; static asn_oer_constraints_t asn_OER_type_Member_constr_2 CC_NOTUSED = { { 0, 0 }, -1}; static asn_per_constraints_t asn_PER_type_Member_constr_2 CC_NOTUSED = { { APC_CONSTRAINED | APC_EXTENSIBLE, 2, 2, 0, 3 } /* (0..3,...) */, { APC_UNCONSTRAINED, -1, -1, 0, 0 }, 0, 0 /* No PER value map */ }; static asn_oer_constraints_t asn_OER_type_FileManagement_constr_1 CC_NOTUSED = { { 0, 0 }, -1 /* (SIZE(1..MAX)) */}; asn_per_constraints_t asn_PER_type_FileManagement_constr_1 CC_NOTUSED = { { APC_UNCONSTRAINED, -1, -1, 0, 0 }, { APC_SEMI_CONSTRAINED, -1, -1, 1, 0 } /* (SIZE(1..MAX)) */, 0, 0 /* No PER value map */ }; static asn_TYPE_member_t asn_MBR_Member_2[] = { { ATF_NOFLAGS, 0, offsetof(struct FileManagement__Member, choice.filePath), (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ &asn_DEF_OCTET_STRING, 0, { &asn_OER_memb_filePath_constr_3, &asn_PER_memb_filePath_constr_3, memb_filePath_constraint_2 }, 0, 0, /* No default value */ "filePath" }, { ATF_NOFLAGS, 0, offsetof(struct FileManagement__Member, choice.createFCP), (ASN_TAG_CLASS_APPLICATION | (2 << 2)), -1, /* IMPLICIT tag at current level */ &asn_DEF_Fcp, 0, { 0, 0, 0 }, 0, 0, /* No default value */ "createFCP" }, { ATF_NOFLAGS, 0, offsetof(struct FileManagement__Member, choice.fillFileOffset), (ASN_TAG_CLASS_UNIVERSAL | (2 << 2)), 0, &asn_DEF_UInt16, 0, { 0, 0, 0 }, 0, 0, /* No default value */ "fillFileOffset" }, { ATF_NOFLAGS, 0, offsetof(struct FileManagement__Member, choice.fillFileContent), (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ &asn_DEF_OCTET_STRING, 0, { 0, 0, 0 }, 0, 0, /* No default value */ "fillFileContent" }, }; static const unsigned asn_MAP_Member_to_canonical_2[] = { 2, 1, 0, 3 }; static const unsigned asn_MAP_Member_from_canonical_2[] = { 2, 1, 0, 3 }; static const asn_TYPE_tag2member_t asn_MAP_Member_tag2el_2[] = { { (ASN_TAG_CLASS_UNIVERSAL | (2 << 2)), 2, 0, 0 }, /* fillFileOffset */ { (ASN_TAG_CLASS_APPLICATION | (2 << 2)), 1, 0, 0 }, /* createFCP */ { (ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, 0 }, /* filePath */ { (ASN_TAG_CLASS_CONTEXT | (1 << 2)), 3, 0, 0 } /* fillFileContent */ }; static asn_CHOICE_specifics_t asn_SPC_Member_specs_2 = { sizeof(struct FileManagement__Member), offsetof(struct FileManagement__Member, _asn_ctx), offsetof(struct FileManagement__Member, present), sizeof(((struct FileManagement__Member *)0)->present), asn_MAP_Member_tag2el_2, 4, /* Count of tags in the map */ asn_MAP_Member_to_canonical_2, asn_MAP_Member_from_canonical_2, 4 /* Extensions start */ }; static /* Use -fall-defs-global to expose */ asn_TYPE_descriptor_t asn_DEF_Member_2 = { "CHOICE", "CHOICE", &asn_OP_CHOICE, 0, /* No effective tags (pointer) */ 0, /* No effective tags (count) */ 0, /* No tags (pointer) */ 0, /* No tags (count) */ { &asn_OER_type_Member_constr_2, &asn_PER_type_Member_constr_2, CHOICE_constraint }, asn_MBR_Member_2, 4, /* Elements count */ &asn_SPC_Member_specs_2 /* Additional specs */ }; asn_TYPE_member_t asn_MBR_FileManagement_1[] = { { ATF_POINTER, 0, 0, -1 /* Ambiguous tag (CHOICE?) */, 0, &asn_DEF_Member_2, 0, { 0, 0, 0 }, 0, 0, /* No default value */ "" }, }; static const ber_tlv_tag_t asn_DEF_FileManagement_tags_1[] = { (ASN_TAG_CLASS_UNIVERSAL | (16 << 2)) }; asn_SET_OF_specifics_t asn_SPC_FileManagement_specs_1 = { sizeof(struct FileManagement), offsetof(struct FileManagement, _asn_ctx), 2, /* XER encoding is XMLValueList */ }; asn_TYPE_descriptor_t asn_DEF_FileManagement = { "FileManagement", "FileManagement", &asn_OP_SEQUENCE_OF, asn_DEF_FileManagement_tags_1, sizeof(asn_DEF_FileManagement_tags_1) /sizeof(asn_DEF_FileManagement_tags_1[0]), /* 1 */ asn_DEF_FileManagement_tags_1, /* Same as above */ sizeof(asn_DEF_FileManagement_tags_1) /sizeof(asn_DEF_FileManagement_tags_1[0]), /* 1 */ { &asn_OER_type_FileManagement_constr_1, &asn_PER_type_FileManagement_constr_1, SEQUENCE_OF_constraint }, asn_MBR_FileManagement_1, 1, /* Single element */ &asn_SPC_FileManagement_specs_1 /* Additional specs */ };