Beispiel #1
0
 public void ApplySettings(SettingInfoBase settings)
 {
     if (settings.Get <int>(SftpSettingInfo.ServerOs) != 0)
     {
         _client.ServerOs = (RemoteServerOs)(settings.Get <int>(SftpSettingInfo.ServerOs) - 1);
     }
 }
Beispiel #2
0
        public void ApplySettings(SettingInfoBase settings)
        {
            ComponentPro.Net.Ftp client = (ComponentPro.Net.Ftp)_client;

            client.Config.KeepAliveDuringIdleInterval = settings.Get <int>(SettingInfo.KeepAlive);
            client.TransferMode                       = settings.Get <bool>(FtpSettingInfo.Compress) ? FtpTransferMode.ZlibCompressed : FtpTransferMode.Stream;
            client.Config.SendAbortCommand            = settings.Get <OptionValue>(FtpSettingInfo.SendAborCommand);
            client.Config.SendTelnetInterruptSignal   = settings.Get <bool>(FtpSettingInfo.SendAbortSignals);
            client.ChangeDirectoryBeforeFileOperation = settings.Get <bool>(FtpSettingInfo.ChangeDirBeforeTransfer);
            client.ChangeDirectoryBeforeListing       = settings.Get <bool>(FtpSettingInfo.ChangeDirBeforeListing);
            client.Config.SmartPathResolving          = settings.Get <bool>(FtpSettingInfo.SmartPath);
        }
Beispiel #3
0
 void IClientPlugin.AuthenticatePost()
 {
     if (_loginSettings.Get <bool>(FtpLoginInfo.ClearCommandChannel) && _loginSettings.Get <FtpSecurityMode>(FtpLoginInfo.SecurityMode) != FtpSecurityMode.None)
     {
         ((ComponentPro.Net.Ftp)_client).ClearCommandChannel();
     }
 }
Beispiel #4
0
 public void Connect()
 {
     _client.ConnectAsync(_loginSettings.Get <string>(LoginInfo.ServerName), _loginSettings.Get <int>(LoginInfo.ServerPort));
 }