当前位置: 首页>>代码示例>>C++>>正文


C++ xmpp_display_elems函数代码示例

本文整理汇总了C++中xmpp_display_elems函数的典型用法代码示例。如果您正苦于以下问题:C++ xmpp_display_elems函数的具体用法?C++ xmpp_display_elems怎么用?C++ xmpp_display_elems使用的例子?那么, 这里精选的函数代码示例或许可以为您提供帮助。


在下文中一共展示了xmpp_display_elems函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。

示例1: xmpp_gtalk_transport_p2p_cand

static void
xmpp_gtalk_transport_p2p_cand(proto_tree* tree, tvbuff_t* tvb, packet_info* pinfo, xmpp_element_t* element) {
    proto_item *cand_item;
    proto_tree *cand_tree;

    xmpp_attr_info attrs_info[] = {
        {"xmlns", hf_xmpp_xmlns, FALSE, FALSE, NULL, NULL},
        {"name", -1, FALSE, TRUE, NULL, NULL},
        {"generation", -1, FALSE, FALSE, NULL, NULL},
        {"network", -1, FALSE, FALSE, NULL, NULL},
        {"component", -1, FALSE, FALSE, NULL, NULL},
        {"type", -1, FALSE, FALSE, NULL, NULL},
        {"protocol", -1, FALSE, TRUE, NULL, NULL},
        {"preference", -1, FALSE, FALSE, NULL, NULL},
        {"password", -1, FALSE, FALSE, NULL, NULL},
        {"username", -1, FALSE, FALSE, NULL, NULL},
        {"port", -1, FALSE, TRUE, NULL, NULL},
        {"address", -1, FALSE, TRUE, NULL, NULL}
    };

    cand_item = proto_tree_add_text(tree, tvb, element->offset, element->length, "CANDIDATE");
    cand_tree = proto_item_add_subtree(cand_item, ett_xmpp_gtalk_transport_p2p_cand);

    xmpp_display_attrs(cand_tree, element, pinfo, tvb, attrs_info, array_length(attrs_info));
    xmpp_display_elems(cand_tree, element, pinfo, tvb, NULL, 0);

}
开发者ID:drower,项目名称:wireshark-1.10.0,代码行数:27,代码来源:packet-xmpp-gtalk.c

示例2: xmpp_conf_endpoint

static void
xmpp_conf_endpoint(proto_tree *tree, tvbuff_t *tvb, packet_info *pinfo, xmpp_element_t *element)
{
    proto_tree *endpoint_tree;

    xmpp_attr_info attrs_info [] = {
        {"entity", NULL, FALSE, TRUE, NULL, NULL},
        {"state", NULL, FALSE, TRUE, NULL, NULL},
        {"display-text", NULL, FALSE, TRUE, NULL, NULL},
        {"status", NULL, FALSE, TRUE, NULL, NULL},
        {"joining-method", NULL, FALSE, TRUE, NULL, NULL},
        {"disconnection-method", NULL, FALSE, TRUE, NULL, NULL},
    };

    xmpp_elem_info elems_info [] = {
        /*{NAME,"referred",...,ONE},*/
        /*{NAME,"joining-info",...,ONE},*/
        /*{NAME,"disconnection-info",...,ONE},*/
        {NAME,"media", xmpp_conf_media, ONE},
        /*{NAME,"call-info",...,ONE},*/

    };

    endpoint_tree = proto_tree_add_subtree(tree, tvb, element->offset, element->length, ett_xmpp_conf_endpoint, NULL, "ENDPOINT");

    xmpp_change_elem_to_attrib("display-text", "display-text", element, xmpp_transform_func_cdata);
    xmpp_change_elem_to_attrib("status", "status", element, xmpp_transform_func_cdata);
    xmpp_change_elem_to_attrib("joining-method", "joining-method", element, xmpp_transform_func_cdata);
    xmpp_change_elem_to_attrib("disconnection-method", "disconnection-method", element, xmpp_transform_func_cdata);


    xmpp_display_attrs(endpoint_tree, element, pinfo, tvb, attrs_info, array_length(attrs_info));
    xmpp_display_elems(endpoint_tree, element, pinfo, tvb, elems_info, array_length(elems_info));
}
开发者ID:danielwhite84,项目名称:wireshark,代码行数:34,代码来源:packet-xmpp-conference.c

示例3: xmpp_jingle_content_description_rtp

/*XEP-0167: Jingle RTP Sessions urn:xmpp:jingle:apps:rtp:1*/
static void
xmpp_jingle_content_description_rtp(proto_tree* tree, tvbuff_t* tvb, packet_info* pinfo, xmpp_element_t* element)
{
    proto_item *desc_item;
    proto_tree *desc_tree;

    xmpp_attr_info attrs_info[] = {
        {"xmlns", hf_xmpp_xmlns, TRUE, TRUE, NULL, NULL},
        {"media", hf_xmpp_jingle_content_description_media, TRUE, TRUE, NULL, NULL},
        {"ssrc", hf_xmpp_jingle_content_description_ssrc , FALSE, TRUE, NULL, NULL}
    };

    xmpp_elem_info elems_info[] = {
        {NAME, "payload-type", xmpp_jingle_cont_desc_rtp_payload, MANY},
        {NAME, "bandwidth", xmpp_jingle_cont_desc_rtp_bandwidth, ONE},
        {NAME, "encryption", xmpp_jingle_cont_desc_rtp_enc, ONE},
        {NAME, "rtp-hdrext", xmpp_jingle_cont_desc_rtp_hdrext, MANY},
        {NAME, "zrtp-hash", xmpp_jingle_cont_desc_rtp_enc_zrtp_hash, MANY}/*IMHO it shouldn't appear in description*/

    };

    desc_item = proto_tree_add_item(tree, hf_xmpp_jingle_content_description, tvb, element->offset, element->length, ENC_BIG_ENDIAN);
    desc_tree = proto_item_add_subtree(desc_item, ett_xmpp_jingle_content_description);

    xmpp_display_attrs(desc_tree, element, pinfo, tvb, attrs_info, array_length(attrs_info));

    xmpp_display_elems(desc_tree, element, pinfo, tvb, elems_info, array_length(elems_info));
}
开发者ID:dogphilly,项目名称:wireshark,代码行数:29,代码来源:packet-xmpp-jingle.c

示例4: xmpp_gtalk_session_cand

static void
xmpp_gtalk_session_cand(proto_tree* tree, tvbuff_t* tvb, packet_info* pinfo, xmpp_element_t* element)
{
    proto_tree *cand_tree;

    xmpp_attr_info attrs_info[] = {
        {"name", NULL, TRUE, TRUE, NULL, NULL},
        {"address", NULL, TRUE, FALSE, NULL, NULL},
        {"port", NULL, TRUE, FALSE, NULL, NULL},
        {"preference", NULL, TRUE, FALSE, NULL, NULL},
        {"type", NULL, TRUE, TRUE, NULL, NULL},
        {"protocol", NULL, TRUE, TRUE, NULL, NULL},
        {"network", NULL, TRUE, FALSE, NULL, NULL},
        {"username", NULL, TRUE, FALSE, NULL, NULL},
        {"password", NULL, TRUE, FALSE, NULL, NULL},
        {"generation", NULL, TRUE, FALSE, NULL, NULL},
        {"foundation", NULL, FALSE, FALSE, NULL, NULL},
        {"component", NULL, FALSE, FALSE, NULL, NULL}
    };

    cand_tree = proto_tree_add_subtree(tree, tvb, element->offset, element->length, ett_xmpp_gtalk_session_cand, NULL, "CANDIDATE");

    xmpp_display_attrs(cand_tree, element, pinfo, tvb, attrs_info, array_length(attrs_info));
    xmpp_display_elems(cand_tree, element, pinfo, tvb, NULL, 0);
}
开发者ID:ARK1988,项目名称:wireshark,代码行数:25,代码来源:packet-xmpp-gtalk.c

示例5: xmpp_jingle_cont_trans_s5b

/*XEP-0260: Jingle SOCKS5 Bytestreams Transport Method urn:xmpp:jingle:transports:s5b:1*/
static void
xmpp_jingle_cont_trans_s5b(proto_tree *tree, tvbuff_t *tvb, packet_info *pinfo, xmpp_element_t *element)
{
    proto_item *trans_item;
    proto_tree *trans_tree;

    xmpp_attr_info attrs_info[] = {
        {"xmlns", hf_xmpp_xmlns, FALSE, TRUE, NULL, NULL},
        {"mode", -1, FALSE, TRUE, NULL, NULL},
        {"sid", -1, FALSE, TRUE, NULL, NULL},
    };

    xmpp_elem_info elems_info [] = {
        {NAME, "candidate", xmpp_jingle_cont_trans_s5b_candidate, MANY},
        {NAME, "activated", xmpp_jingle_cont_trans_s5b_activated, ONE},
        {NAME, "candidate-used", xmpp_jingle_cont_trans_s5b_cand_used, ONE},
        {NAME, "candidate-error", xmpp_jingle_cont_trans_s5b_cand_error, ONE},
        {NAME, "proxy-error", xmpp_jingle_cont_trans_s5b_proxy_error, ONE},
    };

    trans_item = proto_tree_add_item(tree, hf_xmpp_jingle_cont_trans, tvb, element->offset, element->length, ENC_BIG_ENDIAN);
    trans_tree = proto_item_add_subtree(trans_item, ett_xmpp_jingle_cont_trans);

    xmpp_display_attrs(trans_tree, element, pinfo, tvb, attrs_info, array_length(attrs_info));
    xmpp_display_elems(trans_tree, element, pinfo, tvb, elems_info, array_length(elems_info));
}
开发者ID:dogphilly,项目名称:wireshark,代码行数:27,代码来源:packet-xmpp-jingle.c

示例6: xmpp_jingle_file_transfer_file

static void
xmpp_jingle_file_transfer_file(proto_tree* tree, tvbuff_t* tvb, packet_info* pinfo, xmpp_element_t* element)
{
    proto_item *file_item;
    proto_tree *file_tree;

    xmpp_attr_info attrs_info[] = {
        {"name", -1, FALSE, TRUE, NULL, NULL},
        {"size", -1, FALSE, TRUE, NULL, NULL},
        {"date", -1, FALSE, TRUE, NULL, NULL}
    };

    xmpp_elem_info elems_info[] = {
        {NAME, "hashes", xmpp_hashes, ONE}
    };

    file_item = proto_tree_add_text(tree, tvb, element->offset, element->length, "FILE");
    file_tree = proto_item_add_subtree(file_item, ett_xmpp_jingle_file_transfer_file);

    xmpp_change_elem_to_attrib("name", "name", element, xmpp_transform_func_cdata);
    xmpp_change_elem_to_attrib("size", "size", element, xmpp_transform_func_cdata);
    xmpp_change_elem_to_attrib("date", "date", element, xmpp_transform_func_cdata);

    xmpp_display_attrs(file_tree, element, pinfo, tvb, attrs_info, array_length(attrs_info));
    xmpp_display_elems(file_tree, element, pinfo, tvb, elems_info, array_length(elems_info));
}
开发者ID:dogphilly,项目名称:wireshark,代码行数:26,代码来源:packet-xmpp-jingle.c

示例7: xmpp_jingle_cont_trans_raw_candidate

static void
xmpp_jingle_cont_trans_raw_candidate(proto_tree* tree, tvbuff_t* tvb, packet_info* pinfo, xmpp_element_t* element)
{
    proto_item *cand_item;
    proto_tree *cand_tree;

    const gchar *type_enums[] = {"host", "prflx", "relay", "srflx"};
    xmpp_array_t *type_enums_array = xmpp_ep_init_array_t(type_enums,array_length(type_enums));

    xmpp_attr_info attrs_info[] = {
        {"xmlns", hf_xmpp_xmlns, FALSE, FALSE, NULL, NULL},
        {"component", -1, TRUE, FALSE, NULL, NULL},
        {"generation", -1, TRUE, FALSE, NULL, NULL},
        {"id", -1, TRUE, FALSE, NULL, NULL},
        {"ip", -1, TRUE, TRUE, NULL, NULL},
        {"port", -1, TRUE, TRUE, NULL, NULL},
        {"type", -1, TRUE, TRUE, xmpp_val_enum_list, type_enums_array}
    };

    cand_item = proto_tree_add_item(tree, hf_xmpp_jingle_cont_trans_cand, tvb, element->offset, element->length, ENC_BIG_ENDIAN);
    cand_tree = proto_item_add_subtree(cand_item, ett_xmpp_jingle_cont_trans_cand);

    xmpp_display_attrs(cand_tree, element, pinfo, tvb, attrs_info, array_length(attrs_info));
    xmpp_display_elems(cand_tree, element, pinfo, tvb, NULL, 0);
}
开发者ID:dogphilly,项目名称:wireshark,代码行数:25,代码来源:packet-xmpp-jingle.c

示例8: xmpp_conference_info

void
xmpp_conference_info(proto_tree *tree, tvbuff_t *tvb, packet_info *pinfo, xmpp_element_t *element)
{
    proto_item *cinfo_item;
    proto_tree *cinfo_tree;

    static const gchar *state_enums[] = {"full", "partial", "deleted"};
    xmpp_array_t *state_array = xmpp_ep_init_array_t(state_enums, array_length(state_enums));

    xmpp_attr_info attrs_info [] = {
        {"xmlns", &hf_xmpp_xmlns, TRUE, TRUE, NULL, NULL},
        {"entity", NULL, TRUE, TRUE, NULL, NULL},
        {"state", NULL, FALSE, TRUE, xmpp_val_enum_list, state_array},
        {"version", NULL, FALSE, TRUE, NULL, NULL},
        {"sid", &hf_xmpp_conf_info_sid, FALSE, TRUE, NULL, NULL}
    };

    xmpp_elem_info elems_info [] = {
        {NAME, "conference-description", xmpp_conf_desc, ONE},
        {NAME, "conference-state", xmpp_conf_state, ONE},
        /*{NAME, "host-info", xmpp_conf_host_info, ONE},*/
        {NAME, "users", xmpp_conf_users, ONE},
        /*{NAME, "sidebars-by-ref", xmpp_conf_sidebars_by_ref, ONE},*/
        /*{NAME, "sidebars-by-val", xmpp_conf_sidebars_by_val, ONE},*/
    };

    col_append_str(pinfo->cinfo, COL_INFO, "CONFERENC-INFO ");

    cinfo_item = proto_tree_add_item(tree, hf_xmpp_conf_info, tvb, element->offset, element->length,
        ENC_BIG_ENDIAN);
    cinfo_tree = proto_item_add_subtree(cinfo_item, ett_xmpp_conf_info);

    xmpp_display_attrs(cinfo_tree, element, pinfo, tvb, attrs_info, array_length(attrs_info));
    xmpp_display_elems(cinfo_tree, element, pinfo, tvb, elems_info, array_length(elems_info));
}
开发者ID:danielwhite84,项目名称:wireshark,代码行数:35,代码来源:packet-xmpp-conference.c

示例9: xmpp_conf_desc

static void
xmpp_conf_desc(proto_tree *tree, tvbuff_t *tvb, packet_info *pinfo, xmpp_element_t *element)
{
    proto_item *desc_item;
    proto_tree *desc_tree;

    xmpp_attr_info attrs_info [] = {
        {"subject", NULL, FALSE, TRUE, NULL, NULL},
        {"display-text", NULL, FALSE, FALSE, NULL, NULL},
        {"free-text", NULL, FALSE, FALSE, NULL, NULL},
        {"max-user-count", NULL, FALSE, FALSE, NULL, NULL},
    };

/*
    xmpp_elem_info elems_info [] = {
        {NAME, "keywords", xmpp_conf_desc_keywords, ONE},
        {NAME, "conf-uris", xmpp_conf_desc_conf_uris, ONE},
        {NAME, "service-uris", xmpp_conf_desc_serv_uris, ONE},
        {NAME, "available-media", xmpp_conf_desc_avil_media, ONE},
    };
*/

    desc_item = proto_tree_add_text(tree, tvb, element->offset, element->length, "CONFERENCE DESCRIPTION");
    desc_tree = proto_item_add_subtree(desc_item, ett_xmpp_conf_desc);

    xmpp_change_elem_to_attrib("subject", "subject", element, xmpp_transform_func_cdata);
    xmpp_change_elem_to_attrib("display-text", "display-text", element, xmpp_transform_func_cdata);
    xmpp_change_elem_to_attrib("free-text", "free-text", element, xmpp_transform_func_cdata);
    xmpp_change_elem_to_attrib("maximum-user-count", "max-user-count", element, xmpp_transform_func_cdata);

    xmpp_display_attrs(desc_tree, element, pinfo, tvb, attrs_info, array_length(attrs_info));
    xmpp_display_elems(desc_tree, element, pinfo, tvb, NULL,0);
}
开发者ID:danielwhite84,项目名称:wireshark,代码行数:33,代码来源:packet-xmpp-conference.c

示例10: xmpp_gtalk_session

void
xmpp_gtalk_session(proto_tree* tree, tvbuff_t* tvb, packet_info* pinfo, xmpp_element_t* element)
{
    proto_item *session_item;
    proto_tree *session_tree;

    xmpp_attr_info attrs_info [] = {
        {"xmlns", hf_xmpp_xmlns, TRUE, FALSE, NULL, NULL},
        {"type", hf_xmpp_gtalk_session_type, TRUE, TRUE, NULL, NULL},
        {"initiator", -1, FALSE, TRUE, NULL, NULL},
        {"id", -1, TRUE, TRUE, NULL, NULL}
    };

    xmpp_elem_info elems_info [] = {
        {NAME,"description", xmpp_gtalk_session_desc, ONE},
        {NAME, "candidate", xmpp_gtalk_session_cand, MANY},
        {NAME, "reason", xmpp_gtalk_session_reason, ONE},
        {NAME_AND_ATTR, xmpp_name_attr_struct("transport", "xmlns", "http://www.google.com/transport/p2p"), xmpp_gtalk_transport_p2p, ONE},
        {NAME, "conference-info", xmpp_conferece_info_advert, ONE}
    };

    xmpp_attr_t *attr_type = xmpp_get_attr(element, "type");

    col_append_fstr(pinfo->cinfo, COL_INFO, "GTALK-SESSION(%s) ", attr_type?attr_type->value:"");

    session_item = proto_tree_add_item(tree, hf_xmpp_gtalk_session, tvb, element->offset, element->length, ENC_BIG_ENDIAN);
    session_tree = proto_item_add_subtree(session_item, ett_xmpp_gtalk_session);

    xmpp_display_attrs(session_tree, element, pinfo, tvb, attrs_info, array_length(attrs_info));

    xmpp_display_elems(session_tree, element, pinfo, tvb, elems_info, array_length(elems_info));
}
开发者ID:drower,项目名称:wireshark-1.10.0,代码行数:32,代码来源:packet-xmpp-gtalk.c

示例11: xmpp_conf_media

static void
xmpp_conf_media(proto_tree *tree, tvbuff_t *tvb, packet_info *pinfo, xmpp_element_t *element)
{
    proto_tree *media_tree;

    xmpp_attr_info attrs_info[] = {
        {"id", NULL, TRUE, TRUE, NULL, NULL},
        {"display-text", NULL, FALSE, TRUE, NULL, NULL},
        {"type", NULL, FALSE, TRUE, NULL, NULL},
        {"label", NULL, FALSE, TRUE, NULL, NULL},
        {"src-id", NULL, FALSE, TRUE, NULL, NULL},
        {"status", NULL, FALSE, TRUE, NULL, NULL},
    };

    media_tree = proto_tree_add_subtree(tree, tvb, element->offset, element->length, ett_xmpp_conf_media, NULL, "MEDIA");

    xmpp_change_elem_to_attrib("display-text", "display-text", element, xmpp_transform_func_cdata);
    xmpp_change_elem_to_attrib("type", "type", element, xmpp_transform_func_cdata);
    xmpp_change_elem_to_attrib("label", "label", element, xmpp_transform_func_cdata);
    xmpp_change_elem_to_attrib("src-id", "src-id", element, xmpp_transform_func_cdata);
    xmpp_change_elem_to_attrib("status", "status", element, xmpp_transform_func_cdata);

    xmpp_display_attrs(media_tree, element, pinfo, tvb, attrs_info, array_length(attrs_info));
    xmpp_display_elems(media_tree, element, pinfo, tvb, NULL, 0);
}
开发者ID:danielwhite84,项目名称:wireshark,代码行数:25,代码来源:packet-xmpp-conference.c

示例12: xmpp_gtalk_mail_mailbox

void
xmpp_gtalk_mail_mailbox(proto_tree* tree, tvbuff_t* tvb, packet_info* pinfo, xmpp_element_t* element)
{
    proto_item *mail_item;
    proto_tree *mail_tree;

    xmpp_attr_info attrs_info [] = {
        {"xmlns", hf_xmpp_xmlns, FALSE, TRUE, NULL, NULL},
        {"result-time", -1, FALSE, TRUE, NULL, NULL},
        {"total-matched", -1, FALSE, TRUE, NULL, NULL},
        {"total-estimate", -1, FALSE, TRUE, NULL, NULL},
        {"url", -1, FALSE, TRUE, NULL, NULL}
    };

    xmpp_elem_info elems_info [] = {
        {NAME,"mail-thread-info", xmpp_gtalk_mail_mail_info, MANY}
    };

    col_append_fstr(pinfo->cinfo, COL_INFO, "MAILBOX ");

    mail_item = proto_tree_add_item(tree, hf_xmpp_gtalk_mail_mailbox, tvb, element->offset, element->length, ENC_BIG_ENDIAN);
    mail_tree = proto_item_add_subtree(mail_item, ett_xmpp_gtalk_mail_mailbox);

    xmpp_display_attrs(mail_tree, element, pinfo, tvb, attrs_info, array_length(attrs_info));
    xmpp_display_elems(mail_tree, element, pinfo, tvb, elems_info, array_length(elems_info));
}
开发者ID:drower,项目名称:wireshark-1.10.0,代码行数:26,代码来源:packet-xmpp-gtalk.c

示例13: xmpp_gtalk_jingleinfo_relay

static void
xmpp_gtalk_jingleinfo_relay(proto_tree* tree, tvbuff_t* tvb, packet_info* pinfo, xmpp_element_t* element)
{
    proto_item *relay_item;
    proto_tree *relay_tree;

    xmpp_attr_info attrs_info[] = {
        {"token", -1, FALSE, FALSE, NULL, NULL}
    };

    xmpp_elem_info elems_info [] = {
        {NAME, "server", xmpp_gtalk_jingleinfo_relay_serv, ONE}
    };

    xmpp_element_t *token;

    relay_item = proto_tree_add_text(tree, tvb, element->offset, element->length, "RELAY");
    relay_tree = proto_item_add_subtree(relay_item, ett_xmpp_gtalk_jingleinfo_relay);

    if((token  = xmpp_steal_element_by_name(element, "token"))!=NULL)
    {
        xmpp_attr_t *fake_token = xmpp_ep_init_attr_t(token->data?token->data->value:"", token->offset, token->length);
        g_hash_table_insert(element->attrs, (gpointer)"token", fake_token);
    }

    xmpp_display_attrs(relay_tree, element, pinfo, tvb, attrs_info, array_length(attrs_info));
    xmpp_display_elems(relay_tree, element, pinfo, tvb, elems_info, array_length(elems_info));
}
开发者ID:drower,项目名称:wireshark-1.10.0,代码行数:28,代码来源:packet-xmpp-gtalk.c

示例14: xmpp_conf_user

static void
xmpp_conf_user(proto_tree *tree, tvbuff_t *tvb, packet_info *pinfo, xmpp_element_t *element)
{
    proto_tree *user_tree;

    xmpp_attr_info attrs_info [] = {
        {"entity", NULL, FALSE, TRUE, NULL, NULL},
        {"state", NULL, FALSE, TRUE, NULL, NULL},
        {"display-text", NULL, FALSE, TRUE, NULL, NULL},
        {"cascaded-focus", NULL, FALSE, TRUE, NULL, NULL}
    };

    xmpp_elem_info elems_info [] = {
        /*{NAME, "associated-aors", xmpp_conf_assoc_aors, ONE},*/
        /*{NAME, "roles", xmpp_conf_roles, ONE},*/
        /*{NAME, "languages", xmpp_conf_langs, ONE},*/
        {NAME, "endpoint", xmpp_conf_endpoint, MANY},
    };

    user_tree = proto_tree_add_subtree(tree, tvb, element->offset, element->length, ett_xmpp_conf_user, NULL, "USERS");

    xmpp_change_elem_to_attrib("display-text", "display-text", element, xmpp_transform_func_cdata);
    xmpp_change_elem_to_attrib("cascaded-focus", "cascaded-focus", element, xmpp_transform_func_cdata);

    xmpp_display_attrs(user_tree, element, pinfo, tvb, attrs_info, array_length(attrs_info));
    xmpp_display_elems(user_tree, element, pinfo, tvb, elems_info, array_length(elems_info));
}
开发者ID:danielwhite84,项目名称:wireshark,代码行数:27,代码来源:packet-xmpp-conference.c

示例15: xmpp_x_data

/*jabber:x:data*/
void
xmpp_x_data(proto_tree* tree, tvbuff_t* tvb, packet_info* pinfo, xmpp_element_t* element)
{
    proto_item *x_item;
    proto_tree *x_tree;

    static const gchar *type_enums[] = {"cancel", "form", "result", "submit"};
    xmpp_array_t *type_array = xmpp_ep_init_array_t(type_enums, array_length(type_enums));

    xmpp_attr_info attrs_info[] = {
        {"xmlns", hf_xmpp_xmlns, TRUE, FALSE, NULL, NULL},
        {"type", -1, TRUE, TRUE, xmpp_val_enum_list, type_array},
        {"TITLE", -1, FALSE, TRUE, NULL, NULL}
    };

    xmpp_elem_info elems_info[] = {
        {NAME, "instructions", xmpp_x_data_instr, MANY},
        {NAME, "field", xmpp_x_data_field, MANY},
    };
    /*TODO reported, item*/

    x_item = proto_tree_add_item(tree, hf_xmpp_x_data, tvb, element->offset, element->length, ENC_BIG_ENDIAN);
    x_tree = proto_item_add_subtree(x_item, ett_xmpp_x_data);

    xmpp_change_elem_to_attrib("title", "TITLE", element, xmpp_transform_func_cdata);

    xmpp_display_attrs(x_tree, element, pinfo, tvb, attrs_info, array_length(attrs_info));
    xmpp_display_elems(x_tree, element, pinfo, tvb, elems_info, array_length(elems_info));
}
开发者ID:P1sec,项目名称:LTE_monitor_c2xx,代码行数:30,代码来源:packet-xmpp-other.c


注:本文中的xmpp_display_elems函数示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。