sftpUpload method
Uploads a file using SFTP.
await client.sftpUpload(
path: filePath,
toPath: ".",
callback: (progress) {
print(progress); // read upload progress
},
);
Implementation
Future<String?> sftpUpload({
required String path,
required String toPath,
Callback? callback,
}) async {
uploadCallback = callback;
var result = await _channel.invokeMethod('sftpUpload', {
"id": id,
"path": path,
"toPath": toPath,
});
return result;
}