Viewing version 3.1.0. Open the latest package page.

file_picker_platform_interface

3.1.0

A common platform interface for the file_picker plugin, defining the shared API surface and data contracts across platforms.

Download archive

Readme

file_picker_platform_interface

A common platform interface for the file_picker plugin.

This package defines the interface that all platform implementation packages for file_picker (such as android_file_picker, file_picker_darwin, windows_file_picker, file_picker_linux, file_picker_web) must implement.

Usage

To implement a new platform plugin for file_picker, extend FilePickerPlatform and register your implementation:

class FilePickerCustomPlatform extends FilePickerPlatform {
  static void registerWith() {
    FilePickerPlatform.instance = FilePickerCustomPlatform();
  }

  // Implement methods...
}
Changelog

3.1.0

  • Added PlatformFile.extension, restoring the pre-12.0 convenience getter that was dropped during the federated rewrite. Returns the file extension of name without the leading dot, or null if there is none.

3.0.1

  • Improved package description, added example, and added missing API documentation.

3.0.0

  • Unified platform interface release for federated file_picker architecture.

2.0.0

  • Deprecates interface in favor of standalone file_picker for all platforms.

1.3.1

  • Removes allowCompression from interface as it should only be used from file_picker (Android & iOS).

1.3.0

  • Adds allowCompression parameter.

1.2.0

  • Adds FilePickerStatus.

1.1.0

  • Implements getDirectoryPath().

1.0.0

  • Implements getFiles().

0.0.3

  • Removes getFilePath().

0.0.2

  • Updates methods from File Picker interface.

0.0.1

  • Added File Picker platform interface.

Installing

export PUB_HOSTED_URL=https://pub.mirror.p-hatan.com
flutter pub add 'file_picker_platform_interface:3.1.0'
pubspec.yaml
name: file_picker_platform_interface
description: A common platform interface for the file_picker plugin, defining the shared API surface and data contracts across platforms.
version: 3.1.0
homepage: https://github.com/miguelpruivo/flutter_file_picker/tree/master/packages/file_picker_platform_interface
repository: https://github.com/miguelpruivo/flutter_file_picker/tree/master/packages/file_picker_platform_interface
topics:
  - file-picker
  - platform-interface

resolution: workspace

environment:
  sdk: ">=3.10.0 <4.0.0"
  flutter: ">=3.38.0"

dependencies:
  flutter:
    sdk: flutter
  plugin_platform_interface: ^2.1.8
  cross_file: ^0.3.5+4
  path: ^1.9.1

dev_dependencies:
  flutter_test:
    sdk: flutter
  flutter_lints: ^6.0.0

Version history

VersionPublishedArchiveSHA-256
0.0.1Cached · Upstream SHA-256 matchedDownload36693dad…826808
0.0.1+1Cached · Upstream SHA-256 matchedDownloadc1fe6630…0af199
0.0.2Cached · Upstream SHA-256 matchedDownload90dd6269…46fd22
0.0.3Cached · Upstream SHA-256 matchedDownload4e9f9473…5f9506
1.0.0Cached · Upstream SHA-256 matchedDownload1ebbcf61…0913d5
1.1.0Cached · Upstream SHA-256 matchedDownload946955a1…b4c937
1.2.0Cached · Upstream SHA-256 matchedDownloadff068bf7…e59ecb
1.3.0Cached · Upstream SHA-256 matchedDownload00fd05bc…37203e
1.3.1Cached · Upstream SHA-256 matchedDownloadfdd0f666…2abf0e
2.0.0Cached · Upstream SHA-256 matchedDownload70593271…538566
3.0.0Cached · Upstream SHA-256 matchedDownloadbfa1bfc6…2f94f4
3.0.1Cached · Upstream SHA-256 matchedDownload9e7a7e01…bef90c
3.1.0Cached · Upstream SHA-256 matchedDownloadb1ddd790…4c86bd
3.2.0Cached · Upstream SHA-256 matchedDownload11ef1b5c…916fc1
3.3.0Cached · Upstream SHA-256 matchedDownloadd35d8cb6…e5afd8
3.4.0Cached · Upstream SHA-256 matchedDownload0355558f…d0e9ca
4.0.0Cached · Upstream SHA-256 matchedDownloadbbdc085a…107ba5
4.1.0Cached · Upstream SHA-256 matchedDownloada78bd8ec…de7160
4.2.0Cached · Upstream SHA-256 matchedDownload336e7168…97cf20

Dependencies

cross_file "^0.3.5+4"

flutter { "sdk": "flutter" }

path "^1.9.1"

plugin_platform_interface "^2.1.8"