该效果仅客户端在完成首次连接,且为被动断开时有效。
[ObsoleteAttribute("此配置已被弃用,请使用UseTcpReconnection代替", true)]
public static ReconnectionPlugin<ITcpClient> UseReconnection(
this IPluginManager pluginManager,
int tryCount = 10,
bool printLog = false,
int sleepTime = 1000,
Action<ITcpClient> successCallback = null
)
<ExtensionAttribute>
<ObsoleteAttribute("此配置已被弃用,请使用UseTcpReconnection代替", true)>
Public Shared Function UseReconnection (
pluginManager As IPluginManager,
Optional tryCount As Integer = 10,
Optional printLog As Boolean = false,
Optional sleepTime As Integer = 1000,
Optional successCallback As Action(Of ITcpClient) = Nothing
) As ReconnectionPlugin(Of ITcpClient)
[<ExtensionAttribute>]
[<ObsoleteAttribute("此配置已被弃用,请使用UseTcpReconnection代替", true)>]
static member UseReconnection :
pluginManager : IPluginManager *
?tryCount : int *
?printLog : bool *
?sleepTime : int *
?successCallback : Action<ITcpClient>
(* Defaults:
let _tryCount = defaultArg tryCount 10
let _printLog = defaultArg printLog false
let _sleepTime = defaultArg sleepTime 1000
let _successCallback = defaultArg successCallback null
*)
-> ReconnectionPlugin<ITcpClient>
[缺少 "M:TouchSocket.Sockets.SocketPluginManagerExtension.UseReconnection(TouchSocket.Core.IPluginManager,System.Int32,System.Boolean,System.Int32,System.Action{TouchSocket.Sockets.ITcpClient})" 的 <param name="pluginManager"/> 文档]
[缺少 "M:TouchSocket.Sockets.SocketPluginManagerExtension.UseReconnection(TouchSocket.Core.IPluginManager,System.Int32,System.Boolean,System.Int32,System.Action{TouchSocket.Sockets.ITcpClient})" 的 <returns> 文档]