点击或拖拽改变大小

WebSocketSession 类

websocket 的会话客户端
继承层次
SystemObject
  HslCommunication.Core.NetPipeSession
    HslCommunication.WebSocketWebSocketSession

命名空间:  HslCommunication.WebSocket
程序集:  HslCommunication (在 HslCommunication.dll 中) 版本:12.0.0.0 (12.0.0.0)
语法
public class WebSocketSession : PipeSession

WebSocketSession 类型公开以下成员。

构造函数
  名称说明
公共方法WebSocketSession
实例化一个默认的对象
Top
属性
  名称说明
公共属性Communication
当前的会话的管道信息
Pipeline information for the current session
(继承自 PipeSession。)
公共属性HeartTime
获取心跳验证的时间点
Get the time point of heartbeat verification
(继承自 PipeSession。)
公共属性IsQASession
当前的会话是否是问答客户端,如果是问答客户端的话,数据的推送是无效的。
公共属性OnlineTime
获取当前的客户端的上线时间
Get the online time of the current client
(继承自 PipeSession。)
公共属性Remote
远程的客户端的ip及端口信息
公共属性SessionID
获取或设置当前会话的ID信息,某些特殊的会话需要用到该字段
Obtain or set the ID information of the current session, which is required for some special sessions
(继承自 PipeSession。)
公共属性Tag
当前会话绑定的自定义的对象内容
The content of the custom object bound to the current session
(继承自 PipeSession。)
公共属性Topics
当前客户端订阅的所有的Topic信息
公共属性Url
客户端请求的url信息,可能携带一些参数信息
Top
方法
  名称说明
公共方法AddTopic
动态增加一个订阅的信息
公共方法Close
关闭当前的会话状态
Close the current session state
(继承自 PipeSession。)
公共方法Equals (继承自 Object。)
受保护的方法Finalize (继承自 Object。)
公共方法GetHashCode (继承自 Object。)
公共方法GetType (继承自 Object。)
公共方法IsClientSubscribe
检查当前的连接对象是否在
受保护的方法MemberwiseClone (继承自 Object。)
公共方法RemoveTopic
动态移除一个订阅的信息
公共方法ToString (重写 PipeSessionToString.)
Top
扩展方法
  名称说明
公共扩展器方法ToJsonString
获取当前对象的JSON格式表示的字符串。
Gets the string represented by the JSON format of the current object.
(由 HslExtension 定义。)
Top
参见