📄 mid.c
字号:
/* * Generated by asn1c-0.9.16 (http://lionet.info/asn1c) * From ASN.1 module "MEDIA-GATEWAY-CONTROL" * found in "h248_2.asn" */#include <asn_internal.h>#include "MId.h"static intmemb_mtpAddress_1_constraint(asn_TYPE_descriptor_t *td, const void *sptr, asn_app_consume_bytes_f *app_errlog, void *app_key) { const OCTET_STRING_t *st = (const OCTET_STRING_t *)sptr; size_t size; if(!sptr) { _ASN_ERRLOG(app_errlog, app_key, "%s: value not given (%s:%d)", td->name, __FILE__, __LINE__); return -1; } size = st->size; if((size >= 2 && size <= 4)) { /* Constraint check succeeded */ return 0; } else { _ASN_ERRLOG(app_errlog, app_key, "%s: constraint failed (%s:%d)", td->name, __FILE__, __LINE__); return -1; }}static asn_TYPE_member_t asn_MBR_MId_1[] = { { ATF_NOFLAGS, 0, offsetof(struct MId, choice.ip4Address), (ASN_TAG_CLASS_CONTEXT | (0 << 2)), -1, /* IMPLICIT tag at current level */ (void *)&asn_DEF_IP4Address, 0, /* Defer constraints checking to the member type */ "ip4Address" }, { ATF_NOFLAGS, 0, offsetof(struct MId, choice.ip6Address), (ASN_TAG_CLASS_CONTEXT | (1 << 2)), -1, /* IMPLICIT tag at current level */ (void *)&asn_DEF_IP6Address, 0, /* Defer constraints checking to the member type */ "ip6Address" }, { ATF_NOFLAGS, 0, offsetof(struct MId, choice.domainName), (ASN_TAG_CLASS_CONTEXT | (2 << 2)), -1, /* IMPLICIT tag at current level */ (void *)&asn_DEF_DomainName, 0, /* Defer constraints checking to the member type */ "domainName" }, { ATF_NOFLAGS, 0, offsetof(struct MId, choice.deviceName), (ASN_TAG_CLASS_CONTEXT | (3 << 2)), -1, /* IMPLICIT tag at current level */ (void *)&asn_DEF_PathName, 0, /* Defer constraints checking to the member type */ "deviceName" }, { ATF_NOFLAGS, 0, offsetof(struct MId, choice.mtpAddress), (ASN_TAG_CLASS_CONTEXT | (4 << 2)), -1, /* IMPLICIT tag at current level */ (void *)&asn_DEF_OCTET_STRING, memb_mtpAddress_1_constraint, "mtpAddress" },};static asn_TYPE_tag2member_t asn_MAP_MId_1_tag2el[] = { { (ASN_TAG_CLASS_CONTEXT | (0 << 2)), 0, 0, 0 }, /* ip4Address at 37 */ { (ASN_TAG_CLASS_CONTEXT | (1 << 2)), 1, 0, 0 }, /* ip6Address at 38 */ { (ASN_TAG_CLASS_CONTEXT | (2 << 2)), 2, 0, 0 }, /* domainName at 39 */ { (ASN_TAG_CLASS_CONTEXT | (3 << 2)), 3, 0, 0 }, /* deviceName at 40 */ { (ASN_TAG_CLASS_CONTEXT | (4 << 2)), 4, 0, 0 } /* mtpAddress at 41 */};static asn_CHOICE_specifics_t asn_SPC_MId_1_specs = { sizeof(struct MId), offsetof(struct MId, _asn_ctx), offsetof(struct MId, present), sizeof(((struct MId *)0)->present), asn_MAP_MId_1_tag2el, 5, /* Count of tags in the map */ 1 /* Whether extensible */};asn_TYPE_descriptor_t asn_DEF_MId = { "MId", "MId", CHOICE_free, CHOICE_print, CHOICE_constraint, CHOICE_decode_ber, CHOICE_encode_der, CHOICE_decode_xer, CHOICE_encode_xer, CHOICE_outmost_tag, 0, /* No effective tags (pointer) */ 0, /* No effective tags (count) */ 0, /* No tags (pointer) */ 0, /* No tags (count) */ asn_MBR_MId_1, 5, /* Elements count */ &asn_SPC_MId_1_specs /* Additional specs */};
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -