FileEncryption.EncryptAsync Method
Namespace: Rebex.Security
Assembly: Rebex.Security.dll (version 7.0.9119)
EncryptAsync(String, String, Object)
Begins asynchronous Encrypt operation. Encrypts a source file into a target file.
Declaration
public Task EncryptAsync(string sourceFile, string targetFile, object state = null)
Parameters
Type | Name | Description |
---|---|---|
String | sourceFile | The file to encrypt. |
String | targetFile | The name of the encrypted file. This cannot be a directory. |
Object | state | An optional user-provided object that identifies this particular asynchronous operation. |
Returns
Type | Description |
---|---|
Task |
EncryptAsync(Stream, Stream, Object)
Begins asynchronous Encrypt operation. Encrypts data from a source stream into a target stream.
Declaration
public Task EncryptAsync(Stream sourceStream, Stream targetStream, object state = null)
Parameters
Type | Name | Description |
---|---|---|
Stream | sourceStream | Readable stream with input data. |
Stream | targetStream | Writable stream that will receive the encrypted data. |
Object | state | An optional user-provided object that identifies this particular asynchronous operation. |
Returns
Type | Description |
---|---|
Task |