From fe27ec31e11bf640416c39c4e00c7520437de9d0 Mon Sep 17 00:00:00 2001 From: Gert Driesen Date: Sun, 22 Jan 2017 19:53:56 +0100 Subject: [PATCH] Added BeginRead/EndRead to ISftpSession and SftpSession. Draft of read-ahead implementation for DownloadFile and BeginDownloadFile overloads of SftpClient. --- .../Renci.SshNet.NET35.csproj | 8 +- src/Renci.SshNet/Renci.SshNet.csproj | 2 + src/Renci.SshNet/Sftp/ISftpSession.cs | 27 +++ src/Renci.SshNet/Sftp/SftpFileReader.cs | 163 ++++++++++++++++++ src/Renci.SshNet/Sftp/SftpReadAsyncResult.cs | 12 ++ src/Renci.SshNet/Sftp/SftpSession.cs | 64 ++++++- src/Renci.SshNet/SftpClient.cs | 34 ++-- 7 files changed, 288 insertions(+), 22 deletions(-) create mode 100644 src/Renci.SshNet/Sftp/SftpFileReader.cs create mode 100644 src/Renci.SshNet/Sftp/SftpReadAsyncResult.cs diff --git a/src/Renci.SshNet.NET35/Renci.SshNet.NET35.csproj b/src/Renci.SshNet.NET35/Renci.SshNet.NET35.csproj index 3d399f39..d4b838ec 100644 --- a/src/Renci.SshNet.NET35/Renci.SshNet.NET35.csproj +++ b/src/Renci.SshNet.NET35/Renci.SshNet.NET35.csproj @@ -861,6 +861,9 @@ Sftp\SftpFileAttributes.cs + + Sftp\SftpFileReader.cs + Sftp\SftpFileStream.cs @@ -876,6 +879,9 @@ Sftp\SftpMessageTypes.cs + + Sftp\SftpReadAsyncResult.cs + Sftp\SftpSession.cs @@ -921,7 +927,7 @@ - +