on_file_operation_result Event
Signifies the completion of a file transfer operation.
Syntax
class SFTPClientFileOperationResultEventParams(object): @property def operation() -> int: ... @property def remote_path() -> str: ... @property def local_path() -> str: ... @property def error_code() -> int: ... @property def comment() -> str: ... @property def cancel() -> bool: ... @cancel.setter def cancel(value) -> None: ... # In class SFTPClient: @property def on_file_operation_result() -> Callable[[SFTPClientFileOperationResultEventParams], None]: ... @on_file_operation_result.setter def on_file_operation_result(event_hook: Callable[[SFTPClientFileOperationResultEventParams], None]) -> None: ...
Remarks
This event is fired each time the class completes a file transfer within a multi-file call. Operation defines the operation performed on the file, RemotePath specifies the name and path to the remote file, and LocalPath specifies the name and path to the local file.
ErrorCode and Comment return the code and textual description of the error, if it was encountered.
Set Cancel to True to cancel the multi-file operation.
Supported operations:
csfoDownloadFile | 0 | Download file |
csfoUploadFile | 1 | Upload file |
csfoDeleteFile | 2 | Delete file |
csfoMakeDir | 3 | Make directory |