upload static method
upload local file in filepath to dropboxpath.
filepath is local file path. dropboxpath should start with /. callback for monitoring progress : (uploadedBytes, totalBytes) { } (can be null)
Implementation
static Future upload(String filepath, String dropboxpath,
[DropboxProgressCallback? callback]) async {
final fileSize = File(filepath).lengthSync();
final key = ++_callbackInt;
_callbackMap[key] = _CallbackInfo(fileSize, callback);
final ret = await _channel.invokeMethod('upload',
{'filepath': filepath, 'dropboxpath': dropboxpath, 'key': key});
_callbackMap.remove(key);
return ret;
}