import 'package:file_picker/file_picker.dart'; class FilePickerResult { const FilePickerResult(this.files); /// Picked files. final List files; } /// Abstract file picker as a service to implement dependency injection. abstract class FilePickerService { Future getDirectoryPath({ String? title, }) async => throw UnimplementedError('getDirectoryPath() has not been implemented.'); Future pickFiles({ String? dialogTitle, String? initialDirectory, FileType type = FileType.any, List? allowedExtensions, Function(FilePickerStatus)? onFileLoading, bool allowCompression = true, bool allowMultiple = false, bool withData = false, bool withReadStream = false, bool lockParentWindow = false, }) async => throw UnimplementedError('pickFiles() has not been implemented.'); }