点击或拖拽改变大小

INetMessage 方法

INetMessage 类型公开以下成员。

方法
  名称说明
公共方法CheckHeadBytesLegal
检查头子节的合法性
Check the legitimacy of the head subsection
公共方法CheckMessageMatch
检查发送的接收的报文是否是匹配的,如果匹配,则返回 1, 如果不匹配且直接返回错误,则返回 0,如果不匹配继续接收,直到匹配或是超时,则返回 -1
If the packet is matched, 1 is returned. If the packet is not matched and an error is returned, 0 is returned. If the packet is not matched, -1 is returned until the packet is matched or times out
公共方法CheckReceiveDataComplete
当消息头报文的长度定义为-1的时候,则使用动态的长度信息,可以使用本方法来判断一个消息是否处于完整的状态。
If the length of the message header is defined as -1, this method can be used to determine whether a message is in the complete state by using dynamic length information.
公共方法GetContentLengthByHeadBytes
从当前的头子节文件中提取出接下来需要接收的数据长度
Extract the length of the data to be received from the current header file
公共方法GetHeadBytesIdentity
获取头子节里的消息标识
Get the message ID in the header subsection
公共方法PependedUselesByteLength
在接收头报文的时候,返回前置无效的报文头字节长度,默认为0,不处理
When receiving a header message, return the header byte length of the invalid header, the default is 0, and no processing is performed.
Top
参见