Rebex
Products Downloads Buy Support Contact
Show / Hide Table of Contents

Ftp.PutFileAsync Method

Namespace: Rebex.Net
Assembly: Rebex.Ftp.dll (version 7.0.9147)

PutFileAsync(Stream, String, Object)

Begins asynchronous PutFile operation. Uploads the content of the data stream to the file on the server, overriding it if it already exists.

Declaration
public Task<long> PutFileAsync(Stream sourceStream, string remotePath, object state = null)
Parameters
Type Name Description
Stream sourceStream

The source data stream.

String remotePath

The path of the remote file. This cannot be a directory.

Object state

An optional user-provided object that identifies this particular asynchronous operation.

Returns
Type Description
Task<Int64>

Number of bytes transferred.

Implements
IFtp.PutFileAsync(Stream, String, Object)
Remarks

Represents FTP STOR command.

PutFileAsync(String, String, Object)

Begins asynchronous PutFile operation. Uploads the content of the local file to the file on the server, overriding it if it already exists.

Declaration
public Task<long> PutFileAsync(string localPath, string remotePath, object state = null)
Parameters
Type Name Description
String localPath

The path of the local file.

String remotePath

The path of the remote file. This cannot be a directory.

Object state

An optional user-provided object that identifies this particular asynchronous operation.

Returns
Type Description
Task<Int64>

Number of bytes transferred.

Implements
IFtp.PutFileAsync(String, String, Object)
Remarks

Represents FTP STOR command.

PutFileAsync(Stream, String, Int64, Int64, Object)

Begins asynchronous PutFile operation. Uploads the content of the data stream to the file on the server.

Declaration
public Task<long> PutFileAsync(Stream sourceStream, string remotePath, long remoteOffset, long length, object state = null)
Parameters
Type Name Description
Stream sourceStream

The source data stream.

String remotePath

The path of the remote file. This cannot be a directory.

Int64 remoteOffset

The starting offset of the remote file.

Int64 length

Number of bytes to transfer or -1 to transfer the whole stream.

Object state

An optional user-provided object that identifies this particular asynchronous operation.

Returns
Type Description
Task<Int64>

Number of bytes transferred.

Implements
IFtp.PutFileAsync(Stream, String, Int64, Int64, Object)
Remarks

Represents FTP STOR command.

PutFileAsync(String, String, Int64, Int64, Int64, Object)

Begins asynchronous PutFile operation. Uploads the content of the local file to the file on the server.

Declaration
public Task<long> PutFileAsync(string localPath, string remotePath, long localOffset, long remoteOffset, long length, object state = null)
Parameters
Type Name Description
String localPath

The path of the local file.

String remotePath

The path of the remote file. This cannot be a directory.

Int64 localOffset

The starting offset in the local file.

Int64 remoteOffset

The starting offset of the remote file.

Int64 length

Number of bytes to transfer or -1 to transfer the whole stream.

Object state

An optional user-provided object that identifies this particular asynchronous operation.

Returns
Type Description
Task<Int64>

Number of bytes transferred.

Implements
IFtp.PutFileAsync(String, String, Int64, Int64, Int64, Object)
Remarks

Represents FTP STOR command.

In This Article
  • PutFileAsync(Stream, String, Object)
  • PutFileAsync(String, String, Object)
  • PutFileAsync(Stream, String, Int64, Int64, Object)
  • PutFileAsync(String, String, Int64, Int64, Int64, Object)
© REBEX ČR s.r.o. Back to top
Privacy policy
Manage cookies