WebSocketReceiveResult 类

定义

此类的实例表示在 WebSocket 上执行单个 ReceiveAsync 操作所得到的结果。An instance of this class represents the result of performing a single ReceiveAsync operation on a WebSocket.

public ref class WebSocketReceiveResult
public class WebSocketReceiveResult
type WebSocketReceiveResult = class
Public Class WebSocketReceiveResult
继承
WebSocketReceiveResult

构造函数

WebSocketReceiveResult(Int32, WebSocketMessageType, Boolean)

创建 WebSocketReceiveResult 类的实例。Creates an instance of the WebSocketReceiveResult class.

WebSocketReceiveResult(Int32, WebSocketMessageType, Boolean, Nullable<WebSocketCloseStatus>, String)

创建 WebSocketReceiveResult 类的实例。Creates an instance of the WebSocketReceiveResult class.

属性

CloseStatus

指示远程终结点启动关闭握手的原因。Indicates the reason why the remote endpoint initiated the close handshake.

CloseStatusDescription

返回描述关闭握手由远程终结点启动的原因的可选说明。Returns the optional description that describes why the close handshake has been initiated by the remote endpoint.

Count

指示 WebSocket 接收的字节数。Indicates the number of bytes that the WebSocket received.

EndOfMessage

指示是否已完整收到该消息。Indicates whether the message has been received completely.

MessageType

指示当前消息是 UTF-8 消息还是二进制消息。Indicates whether the current message is a UTF-8 message or a binary message.

方法

Equals(Object)

确定指定对象是否等于当前对象。Determines whether the specified object is equal to the current object.

(继承自 Object)
GetHashCode()

作为默认哈希函数。Serves as the default hash function.

(继承自 Object)
GetType()

获取当前实例的 TypeGets the Type of the current instance.

(继承自 Object)
MemberwiseClone()

创建当前 Object 的浅表副本。Creates a shallow copy of the current Object.

(继承自 Object)
ToString()

返回表示当前对象的字符串。Returns a string that represents the current object.

(继承自 Object)

适用于