ZipArchive.DeleteAsync Method
Namespace: Rebex.IO.Compression
Assembly: Rebex.Zip.dll (version 7.0.9119)
DeleteAsync(String, TraversalMode, ArchiveSaveAction, Object)
Begins asynchronous Delete operation. Deletes files and/or directories within the ZIP archive.
Declaration
public Task<ArchiveOperationResult> DeleteAsync(string archivePathOrMask, TraversalMode mode, ArchiveSaveAction action, object state = null)
Parameters
Type | Name | Description |
---|---|---|
String | archivePathOrMask | Path (with or without a mask) to an archive item(s). |
Traversal |
mode | Traversal mode. |
Archive |
action | Save action. |
Object | state | An optional user-provided object that identifies this particular asynchronous operation. |
Returns
Type | Description |
---|---|
Task<Archive |
Operation result. |
Exceptions
Type | Condition |
---|---|
Argument |
The specified path is null. |
Argument |
The specified path is empty. -or- Illegal use of wildcards in path. -or- Ambiguous usage of path and mode. |
Argument |
The |
Invalid |
Archive is not opened for writing. |
Object |
Archive was already disposed. |
IOException | An I/O error occurred. |
Zip |
Cannot perform the requested operation, or the operation was canceled
(see Problem |
DeleteAsync(FileSet, ArchiveSaveAction, Object)
Begins asynchronous Delete operation. Deletes files and/or directories within the ZIP archive.
Declaration
public Task<ArchiveOperationResult> DeleteAsync(FileSet set, ArchiveSaveAction action, object state = null)
Parameters
Type | Name | Description |
---|---|---|
File |
set | A filtering set which specifies external (local) files and directories to be deleted. |
Archive |
action | Save action. |
Object | state | An optional user-provided object that identifies this particular asynchronous operation. |
Returns
Type | Description |
---|---|
Task<Archive |
Operation result. |
Exceptions
Type | Condition |
---|---|
Argument |
|
Argument |
Base path of the set contains invalid characters. |
Invalid |
Archive is not opened for writing. |
Object |
Archive was already disposed. |
IOException | An I/O error occurred. |
Zip |
Cannot perform the requested operation, or the operation was canceled
(see Problem |