System.Net.WebSockets.xml 18 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282
  1. <?xml version="1.0" encoding="utf-8"?>
  2. <doc>
  3. <assembly>
  4. <name>System.Net.WebSockets</name>
  5. </assembly>
  6. <members>
  7. <member name="T:System.Net.WebSockets.WebSocket">
  8. <summary>在 WebSocket 升级完成后, WebSocket 类允许应用程序发送并接收数据。</summary>
  9. </member>
  10. <member name="M:System.Net.WebSockets.WebSocket.#ctor">
  11. <summary>创建 <see cref="T:System.Net.WebSockets.WebSocket" /> 类的实例。</summary>
  12. </member>
  13. <member name="M:System.Net.WebSockets.WebSocket.Abort">
  14. <summary>中止 WebSocket 连接并取消任何挂起的 IO 操作。</summary>
  15. </member>
  16. <member name="M:System.Net.WebSockets.WebSocket.CloseAsync(System.Net.WebSockets.WebSocketCloseStatus,System.String,System.Threading.CancellationToken)">
  17. <summary>使用在 WebSocket 协议规范 章节 7 中定义的关闭握手关闭 WebSocket 连接以作为异步操作。</summary>
  18. <returns>返回 <see cref="T:System.Threading.Tasks.Task" />。表示异步操作的任务对象。</returns>
  19. <param name="closeStatus">指示关闭 WebSocket 连接的原因。</param>
  20. <param name="statusDescription">指定一个可读的解释为连接关闭的原因。</param>
  21. <param name="cancellationToken">标记可用于传播取消操作的通知。</param>
  22. </member>
  23. <member name="M:System.Net.WebSockets.WebSocket.CloseOutputAsync(System.Net.WebSockets.WebSocketCloseStatus,System.String,System.Threading.CancellationToken)">
  24. <summary>在 WebSocket 协议规范的第 7 节 定义中指示或完成关闭握手。</summary>
  25. <returns>返回 <see cref="T:System.Threading.Tasks.Task" />。表示异步操作的任务对象。</returns>
  26. <param name="closeStatus">指示关闭 WebSocket 连接的原因。</param>
  27. <param name="statusDescription">允许应用程序指定一个可读的解释为连接关闭的原因。</param>
  28. <param name="cancellationToken">标记可用于传播取消操作的通知。</param>
  29. </member>
  30. <member name="P:System.Net.WebSockets.WebSocket.CloseStatus">
  31. <summary>指示远程终结点初始关闭握手的原因。</summary>
  32. <returns>返回 <see cref="T:System.Net.WebSockets.WebSocketCloseStatus" />。</returns>
  33. </member>
  34. <member name="P:System.Net.WebSockets.WebSocket.CloseStatusDescription">
  35. <summary>允许该远程终结点描述连接已关闭的原因。</summary>
  36. <returns>返回 <see cref="T:System.String" />。</returns>
  37. </member>
  38. <member name="M:System.Net.WebSockets.WebSocket.Dispose">
  39. <summary>用于清理 ASP.NET 和自我托管实现的非托管资源。</summary>
  40. </member>
  41. <member name="M:System.Net.WebSockets.WebSocket.ReceiveAsync(System.ArraySegment{System.Byte},System.Threading.CancellationToken)">
  42. <summary>从 WebSocket 连接异步接受数据。</summary>
  43. <returns>返回 <see cref="T:System.Threading.Tasks.Task`1" />。表示异步操作的任务对象。任务对象上的 <see cref="P:System.Threading.Tasks.Task`1.Result" /> 属性将返回包含已接收数据的 <see cref="T:System.Byte" /> 数组。</returns>
  44. <param name="buffer">引用应用程序缓冲区,其为接收的数据的存储位置。</param>
  45. <param name="cancellationToken">传播有关应取消操作的通知。</param>
  46. </member>
  47. <member name="M:System.Net.WebSockets.WebSocket.SendAsync(System.ArraySegment{System.Byte},System.Net.WebSockets.WebSocketMessageType,System.Boolean,System.Threading.CancellationToken)">
  48. <summary>发送 WebSocket 上连接异步的数据。</summary>
  49. <returns>返回 <see cref="T:System.Threading.Tasks.Task" />。表示异步操作的任务对象。</returns>
  50. <param name="buffer">要通过连接发送的缓冲区。</param>
  51. <param name="messageType">指示应用是否发送二进制或文本消息。</param>
  52. <param name="endOfMessage">指示在“缓冲区”的数据是否实消息的最后一部分。</param>
  53. <param name="cancellationToken">传播有关应取消操作的通知的标记。</param>
  54. </member>
  55. <member name="P:System.Net.WebSockets.WebSocket.State">
  56. <summary>返回 WebSocket 连接的当前状态。</summary>
  57. <returns>返回 <see cref="T:System.Net.WebSockets.WebSocketState" />。</returns>
  58. </member>
  59. <member name="P:System.Net.WebSockets.WebSocket.SubProtocol">
  60. <summary>在打开握手期间协商的子协议。</summary>
  61. <returns>返回 <see cref="T:System.String" />。</returns>
  62. </member>
  63. <member name="T:System.Net.WebSockets.WebSocketCloseStatus">
  64. <summary>表示在 WebSocket 协议规范的 section 11.7 中定义的著名 WebSocket 关闭代码。</summary>
  65. </member>
  66. <member name="F:System.Net.WebSockets.WebSocketCloseStatus.Empty">
  67. <summary>未指定错误。</summary>
  68. </member>
  69. <member name="F:System.Net.WebSockets.WebSocketCloseStatus.EndpointUnavailable">
  70. <summary>(1001)表示终结点正被移除。无法连接到服务器或客户端。</summary>
  71. </member>
  72. <member name="F:System.Net.WebSockets.WebSocketCloseStatus.InternalServerError">
  73. <summary>由于服务器的错误,连接将由服务器关闭。</summary>
  74. </member>
  75. <member name="F:System.Net.WebSockets.WebSocketCloseStatus.InvalidMessageType">
  76. <summary>(1003)因为无法接受已接收到的数据类型,客户端或服务器将停止连接。</summary>
  77. </member>
  78. <member name="F:System.Net.WebSockets.WebSocketCloseStatus.InvalidPayloadData">
  79. <summary>(1007)因为已接收到的数据类型与该消息类型不一致,客户端或服务器将停止连接。</summary>
  80. </member>
  81. <member name="F:System.Net.WebSockets.WebSocketCloseStatus.MandatoryExtension">
  82. <summary>(1010)因为服务器应协调扩展,客户端将停止连接。</summary>
  83. </member>
  84. <member name="F:System.Net.WebSockets.WebSocketCloseStatus.MessageTooBig">
  85. <summary>(1004)保留供将来使用。</summary>
  86. </member>
  87. <member name="F:System.Net.WebSockets.WebSocketCloseStatus.NormalClosure">
  88. <summary>(1000) 该请求中履行之后,该连接关闭。</summary>
  89. </member>
  90. <member name="F:System.Net.WebSockets.WebSocketCloseStatus.PolicyViolation">
  91. <summary>(1008)因为终结点接收了违反其策略的消息,连接将关闭。</summary>
  92. </member>
  93. <member name="F:System.Net.WebSockets.WebSocketCloseStatus.ProtocolError">
  94. <summary>(1002)由于协议错误,客户端或服务器将停止该连接。</summary>
  95. </member>
  96. <member name="T:System.Net.WebSockets.WebSocketError">
  97. <summary>包含可能的 WebSocket 错误列表。</summary>
  98. </member>
  99. <member name="F:System.Net.WebSockets.WebSocketError.ConnectionClosedPrematurely">
  100. <summary>指示连接意外终止。</summary>
  101. </member>
  102. <member name="F:System.Net.WebSockets.WebSocketError.Faulted">
  103. <summary>指示常规错误。</summary>
  104. </member>
  105. <member name="F:System.Net.WebSockets.WebSocketError.HeaderError">
  106. <summary>指示在打开握手时分析 HTTP 头时发生一个错误。</summary>
  107. </member>
  108. <member name="F:System.Net.WebSockets.WebSocketError.InvalidMessageType">
  109. <summary>指示接收带有未知操作码的一个 WebSocket 帧。</summary>
  110. </member>
  111. <member name="F:System.Net.WebSockets.WebSocketError.InvalidState">
  112. <summary>指示 WebSocket 对于特定操作是无效状态(例如关闭或放弃)。</summary>
  113. </member>
  114. <member name="F:System.Net.WebSockets.WebSocketError.NativeError">
  115. <summary>指示发生未知本地错误。</summary>
  116. </member>
  117. <member name="F:System.Net.WebSockets.WebSocketError.NotAWebSocket">
  118. <summary>指示传入请求不是一个合法的 websocket 请求。</summary>
  119. </member>
  120. <member name="F:System.Net.WebSockets.WebSocketError.Success">
  121. <summary>指示异常不存在本地错误信息。</summary>
  122. </member>
  123. <member name="F:System.Net.WebSockets.WebSocketError.UnsupportedProtocol">
  124. <summary>指示该客户端请求一个不受支持的 WebSocket subprotocol。</summary>
  125. </member>
  126. <member name="F:System.Net.WebSockets.WebSocketError.UnsupportedVersion">
  127. <summary>指示客户端请求 WebSocket 协议的不受支持的版本。</summary>
  128. </member>
  129. <member name="T:System.Net.WebSockets.WebSocketException">
  130. <summary>表示异常,其在 WebSocket 连接上执行操作时发生。</summary>
  131. </member>
  132. <member name="M:System.Net.WebSockets.WebSocketException.#ctor(System.Int32)">
  133. <summary>创建 <see cref="T:System.Net.WebSockets.WebSocketException" /> 类的实例。</summary>
  134. <param name="nativeError">异常的本机错误代码。</param>
  135. </member>
  136. <member name="M:System.Net.WebSockets.WebSocketException.#ctor(System.Int32,System.Exception)">
  137. <summary>创建 <see cref="T:System.Net.WebSockets.WebSocketException" /> 类的实例。</summary>
  138. <param name="nativeError">异常的本机错误代码。</param>
  139. <param name="innerException">指示引发当前异常的上一个异常。</param>
  140. </member>
  141. <member name="M:System.Net.WebSockets.WebSocketException.#ctor(System.Int32,System.String)">
  142. <summary>创建 <see cref="T:System.Net.WebSockets.WebSocketException" /> 类的实例。</summary>
  143. <param name="nativeError">异常的本机错误代码。</param>
  144. <param name="message">关于错误的说明。</param>
  145. </member>
  146. <member name="M:System.Net.WebSockets.WebSocketException.#ctor(System.Net.WebSockets.WebSocketError)">
  147. <summary>创建 <see cref="T:System.Net.WebSockets.WebSocketException" /> 类的实例。</summary>
  148. <param name="error">WebSocketError 枚举中的错误。</param>
  149. </member>
  150. <member name="M:System.Net.WebSockets.WebSocketException.#ctor(System.Net.WebSockets.WebSocketError,System.Exception)">
  151. <summary>创建 <see cref="T:System.Net.WebSockets.WebSocketException" /> 类的实例。</summary>
  152. <param name="error">WebSocketError 枚举中的错误。</param>
  153. <param name="innerException">指示引发当前异常的上一个异常。</param>
  154. </member>
  155. <member name="M:System.Net.WebSockets.WebSocketException.#ctor(System.Net.WebSockets.WebSocketError,System.Int32)">
  156. <summary>创建 <see cref="T:System.Net.WebSockets.WebSocketException" /> 类的实例。</summary>
  157. <param name="error">WebSocketError 枚举中的错误。</param>
  158. <param name="nativeError">异常的本机错误代码。</param>
  159. </member>
  160. <member name="M:System.Net.WebSockets.WebSocketException.#ctor(System.Net.WebSockets.WebSocketError,System.Int32,System.Exception)">
  161. <summary>创建 <see cref="T:System.Net.WebSockets.WebSocketException" /> 类的实例。</summary>
  162. <param name="error">WebSocketError 枚举中的错误。</param>
  163. <param name="nativeError">异常的本机错误代码。</param>
  164. <param name="innerException">指示引发当前异常的上一个异常。</param>
  165. </member>
  166. <member name="M:System.Net.WebSockets.WebSocketException.#ctor(System.Net.WebSockets.WebSocketError,System.Int32,System.String)">
  167. <summary>创建 <see cref="T:System.Net.WebSockets.WebSocketException" /> 类的实例。</summary>
  168. <param name="error">WebSocketError 枚举中的错误。</param>
  169. <param name="nativeError">异常的本机错误代码。</param>
  170. <param name="message">关于错误的说明。</param>
  171. </member>
  172. <member name="M:System.Net.WebSockets.WebSocketException.#ctor(System.Net.WebSockets.WebSocketError,System.Int32,System.String,System.Exception)">
  173. <summary>创建 <see cref="T:System.Net.WebSockets.WebSocketException" /> 类的实例。</summary>
  174. <param name="error">WebSocketError 枚举中的错误。</param>
  175. <param name="nativeError">异常的本机错误代码。</param>
  176. <param name="message">关于错误的说明。</param>
  177. <param name="innerException">指示引发当前异常的上一个异常。</param>
  178. </member>
  179. <member name="M:System.Net.WebSockets.WebSocketException.#ctor(System.Net.WebSockets.WebSocketError,System.String)">
  180. <summary>创建 <see cref="T:System.Net.WebSockets.WebSocketException" /> 类的实例。</summary>
  181. <param name="error">WebSocketError 枚举中的错误。</param>
  182. <param name="message">关于错误的说明。</param>
  183. </member>
  184. <member name="M:System.Net.WebSockets.WebSocketException.#ctor(System.Net.WebSockets.WebSocketError,System.String,System.Exception)">
  185. <summary>创建 <see cref="T:System.Net.WebSockets.WebSocketException" /> 类的实例。</summary>
  186. <param name="error">WebSocketError 枚举中的错误。</param>
  187. <param name="message">关于错误的说明。</param>
  188. <param name="innerException">指示引发当前异常的上一个异常。</param>
  189. </member>
  190. <member name="M:System.Net.WebSockets.WebSocketException.#ctor(System.String)">
  191. <summary>创建 <see cref="T:System.Net.WebSockets.WebSocketException" /> 类的实例。</summary>
  192. <param name="message">关于错误的说明。</param>
  193. </member>
  194. <member name="M:System.Net.WebSockets.WebSocketException.#ctor(System.String,System.Exception)">
  195. <summary>创建 <see cref="T:System.Net.WebSockets.WebSocketException" /> 类的实例。</summary>
  196. <param name="message">关于错误的说明。</param>
  197. <param name="innerException">指示引发当前异常的上一个异常。</param>
  198. </member>
  199. <member name="P:System.Net.WebSockets.WebSocketException.ErrorCode">
  200. <summary>发生的异常的本机错误代码。</summary>
  201. <returns>返回 <see cref="T:System.Int32" />。</returns>
  202. </member>
  203. <member name="P:System.Net.WebSockets.WebSocketException.WebSocketErrorCode">
  204. <summary>返回指示发生错误的类型的 WebSocketError。</summary>
  205. <returns>返回 <see cref="T:System.Net.WebSockets.WebSocketError" />。</returns>
  206. </member>
  207. <member name="T:System.Net.WebSockets.WebSocketMessageType">
  208. <summary>指示消息类型:</summary>
  209. </member>
  210. <member name="F:System.Net.WebSockets.WebSocketMessageType.Binary">
  211. <summary>消息采用二进制格式。</summary>
  212. </member>
  213. <member name="F:System.Net.WebSockets.WebSocketMessageType.Close">
  214. <summary>因为收到关闭的消息,接受已完成。</summary>
  215. </member>
  216. <member name="F:System.Net.WebSockets.WebSocketMessageType.Text">
  217. <summary>该消息是明文形式。</summary>
  218. </member>
  219. <member name="T:System.Net.WebSockets.WebSocketReceiveResult">
  220. <summary>表示 WebSocket 上执行的单个 ReceiveAsync 操作的结果的此类实例。</summary>
  221. </member>
  222. <member name="M:System.Net.WebSockets.WebSocketReceiveResult.#ctor(System.Int32,System.Net.WebSockets.WebSocketMessageType,System.Boolean)">
  223. <summary>创建 <see cref="T:System.Net.WebSockets.WebSocketReceiveResult" /> 类的实例。</summary>
  224. <param name="count">接收到的字节数。</param>
  225. <param name="messageType">接收消息的类型。</param>
  226. <param name="endOfMessage">指示是否是一个最终消息。</param>
  227. </member>
  228. <member name="M:System.Net.WebSockets.WebSocketReceiveResult.#ctor(System.Int32,System.Net.WebSockets.WebSocketMessageType,System.Boolean,System.Nullable{System.Net.WebSockets.WebSocketCloseStatus},System.String)">
  229. <summary>创建 <see cref="T:System.Net.WebSockets.WebSocketReceiveResult" /> 类的实例。</summary>
  230. <param name="count">接收到的字节数。</param>
  231. <param name="messageType">接收消息的类型。</param>
  232. <param name="endOfMessage">指示是否是一个最终消息。</param>
  233. <param name="closeStatus">指示 <see cref="T:System.Net.WebSockets.WebSocketCloseStatus" /> 连接的状态。</param>
  234. <param name="closeStatusDescription">
  235. <paramref name="closeStatus" /> 的说明。</param>
  236. </member>
  237. <member name="P:System.Net.WebSockets.WebSocketReceiveResult.CloseStatus">
  238. <summary>指示远程终结点初始关闭握手的原因。</summary>
  239. <returns>返回 <see cref="T:System.Net.WebSockets.WebSocketCloseStatus" />。</returns>
  240. </member>
  241. <member name="P:System.Net.WebSockets.WebSocketReceiveResult.CloseStatusDescription">
  242. <summary>返回描述关闭握手由远程终结点启动的原因的可选说明。</summary>
  243. <returns>返回 <see cref="T:System.String" />。</returns>
  244. </member>
  245. <member name="P:System.Net.WebSockets.WebSocketReceiveResult.Count">
  246. <summary>指示 WebSocket 接收的字节数。</summary>
  247. <returns>返回 <see cref="T:System.Int32" />。</returns>
  248. </member>
  249. <member name="P:System.Net.WebSockets.WebSocketReceiveResult.EndOfMessage">
  250. <summary>指示则消息是否被完全接收。</summary>
  251. <returns>返回 <see cref="T:System.Boolean" />。</returns>
  252. </member>
  253. <member name="P:System.Net.WebSockets.WebSocketReceiveResult.MessageType">
  254. <summary>指示当前消息是否为 UTF-8 消息或二进制消息。</summary>
  255. <returns>返回 <see cref="T:System.Net.WebSockets.WebSocketMessageType" />。</returns>
  256. </member>
  257. <member name="T:System.Net.WebSockets.WebSocketState">
  258. <summary> 定义 WebSockets 事例可能性的不同状态。</summary>
  259. </member>
  260. <member name="F:System.Net.WebSockets.WebSocketState.Aborted">
  261. <summary>保留供将来使用。</summary>
  262. </member>
  263. <member name="F:System.Net.WebSockets.WebSocketState.Closed">
  264. <summary>指示正常完成 WebSocket 关闭握手。</summary>
  265. </member>
  266. <member name="F:System.Net.WebSockets.WebSocketState.CloseReceived">
  267. <summary>自该远程终结点接收的关闭消息。</summary>
  268. </member>
  269. <member name="F:System.Net.WebSockets.WebSocketState.CloseSent">
  270. <summary>向远程终结点发送了关闭消息。</summary>
  271. </member>
  272. <member name="F:System.Net.WebSockets.WebSocketState.Connecting">
  273. <summary>连接到远程终结点处的链接。</summary>
  274. </member>
  275. <member name="F:System.Net.WebSockets.WebSocketState.None">
  276. <summary>保留供将来使用。</summary>
  277. </member>
  278. <member name="F:System.Net.WebSockets.WebSocketState.Open">
  279. <summary>在 HTTP 握手完成之后的初始状态。</summary>
  280. </member>
  281. </members>
  282. </doc>