pick_or_save 0.0.2 copy "pick_or_save: ^0.0.2" to clipboard
pick_or_save: ^0.0.2 copied to clipboard

outdated

A Flutter file picking and saving package that enables you to pick or save a single file and multiple files.

pub package

Package description #

A Flutter file picking and saving package that enables you to pick or save a single file and multiple files.

Features #

  • Works on Android 5.0 (API level 21) or later.
  • Pick single file or multiple files.
  • Saves single file while allowing user to choose location and name.
  • Saves multiple file while allowing user to choose location or directory for saving all files.
  • Saves file from either file path or file data.
  • Filter extensions when picking a document.
  • Could limit picking a file from the local device only.

Getting started #

  • In pubspec.yaml, add this dependency:
pick_or_save: 
  • Add this package to your project:
import 'package:pick_or_save/pick_or_save.dart';

Basic Usage #

Picking single file #

List<String>? result = await PickOrSave().filePicker(
  params: FilePickerParams(),
);
String filePath = result[0];

Picking multiple files #

List<String>? filesPaths = await PickOrSave().filePicker(
  params: FilePickerParams(filePickingType: FilePickingType.multiple),
);

Saving single file #

List<String>? result = await PickOrSave().fileSaver(
  params: FileSaverParams(
    sourceFilesPaths: [filePath],
    filesNames: ["file.png"],
  ),
);
String savedFilePath = result[0];

Saving multiple files #

List<String>? savedFilesPaths = await PickOrSave().fileSaver(
  params: FileSaverParams(
    sourceFilesPaths: [file1Path, file2Path],
    filesNames: ["file 1.png, file 2.png"],
  ),
);
Saving single file Saving multiple files
WhatsApp Image 2022-09-19 at 1 34 02 PM WhatsApp Image 2022-09-19 at 1 33 04 PM
35
likes
0
pub points
86%
popularity

Publisher

verified publisherdeepanshuchaudhary.com

A Flutter file picking and saving package that enables you to pick or save a single file and multiple files.

Repository (GitHub)
View/report issues

License

unknown (license)

Dependencies

flutter, plugin_platform_interface

More

Packages that depend on pick_or_save