[This is preliminary documentation and is subject to change.]
When overridden in derived class, called when the user presses the Disconnect button in the FTP connections toolbar. This toolbar is only shown if Connect is passed to LogProc(LogKind, String).
Namespace: Tools.TotalCommanderTAssembly: Tools.TotalCommander (in Tools.TotalCommander.dll) Version: 1.5.3.38916 (1.5.3.38916)
Syntax
| C# |
|---|
[MethodNotSupportedAttribute] public virtual bool Disconnect( string DisconnectRoot ) |
| Visual Basic |
|---|
<MethodNotSupportedAttribute> _ Public Overridable Function Disconnect ( _ DisconnectRoot As String _ ) As Boolean |
| Visual C++ |
|---|
[MethodNotSupportedAttribute] public: virtual bool Disconnect( String^ DisconnectRoot ) |
| F# |
|---|
[<MethodNotSupportedAttribute>] abstract Disconnect : DisconnectRoot:string -> bool [<MethodNotSupportedAttribute>] override Disconnect : DisconnectRoot:string -> bool |
| JScript |
|---|
public function Disconnect( DisconnectRoot : String ) : boolean |
Parameters
- DisconnectRoot
- Type: System..::..String
This is the root dir which was passed to LogProc(LogKind, String) when connecting. It allows the plugin to have serveral open connections to different file systems (e.g. ftp servers). Should be either \ (for a single possible connection) or \Servername (e.g. when having multiple open connections).
Return Value
Return true if the connection was closed (or never open), false if it couldn't be closed.
Remarks
To get calls to this function, the plugin MUST call LogProc(LogKind, String) with the parameter Connect. The parameter LogString MUST start with "CONNECT", followed by one whitespace and the root of the file system which has been connected. This file system root will be passed to Disconnect(String) when the user presses the Disconnect button, so the plugin knows which connection to close.
Do NOT call LogProc(LogKind, String) with Connect if your plugin does not require connect/disconnect!
ExamplesFTP requires connect/disconnect. Connect can be done automatically when the user enters a subdir, disconnect when the user clicks the Disconnect button.Access to local file systems (e.g. Linux EXT2) does not require connect/disconnect, so don't call LogProc(LogKind, String) with the parameter Connect.
Remarks
When most-derived method implementation is marked with MethodNotSupportedAttribute, it means that the most derived plugin implementation does not support operation provided by the method.
| Do not thow any other exceptions. Such exception will be passed to Total Commander which cannot handle it. |
Exceptions
| Exception | Condition |
|---|---|
| System..::..NotSupportedException | The actual implementation is marked with MethodNotSupportedAttribute which means that the plugin doesnot support operation provided by the method. |