Ace_Decoder_Protocol_ID_Get()

Abstract

Gets a unique ID for a specified protocol name.

Syntax

Ace_Decoder_Protocol_ID_Get (import_ptr, protocol_name)
Argument Type Description
import_ptr AceT_Import_Handle * Context information.
protocol_name const char * Protocol name.

Return Type

int

Protocol ID.

ace_client_api.h

Example

/* Make sure that the tcp has payload before adding a next protocol */
if (!port_name_ptr || tcp_info.tcp_payload_len == 0)
	{
	*next_protocol_id = ACEC_DECODER_PROTOCOL_UNKNOWN;
	}
else
	{
	/* port_name_ptr exists. */
	*next_protocol_id = Ace_Decoder_Protocol_ID_Get (import_ptr,
		port_name_ptr->short_name);
	if (*next_protocol_id == ACEC_DECODER_PROTOCOL_UNKNOWN)
		{
		*next_protocol_id = Ace_Decoder_Protocol_Add (import_ptr,
			port_name_ptr->short_name, port_name_ptr->short_name);
		}
	}

本站文档由 北京智网畅联科技有限公司 整理、翻译并提供 · Documentation compiled and provided by Beijing ZNetLink Technology Co., Ltd.

交流群 · QQ Group:OPNET/智网妙算网络仿真交流群(群号 486383494)

原文档 © 2017 Riverbed Technology · 本站为公益翻译,由 AI 辅助完成,请仔细甄别

Original documentation © 2017 Riverbed Technology. Community translation, AI-assisted. Contact: jiazequn@znetlink.com