Viewing version 2.1.0. Open the latest package page.

path_provider_platform_interface

2.1.0

A common platform interface for the path_provider plugin.

Download archive

Readme

path_provider_platform_interface

A common platform interface for the path_provider plugin.

This interface allows platform-specific implementations of the path_provider plugin, as well as the plugin itself, to ensure they are supporting the same interface.

Usage

To implement a new platform-specific implementation of path_provider, extend PathProviderPlatform with an implementation that performs the platform-specific behavior, and when you register your plugin, set the default PathProviderPlatform by calling PathProviderPlatform.instance = MyPlatformPathProvider().

Note on breaking changes

Strongly prefer non-breaking changes (such as adding a method to the interface) over breaking changes for this package.

See https://flutter.dev/go/platform-interface-breaking-changes for a discussion on why a less-clean interface is preferable to a breaking change.

Changelog

2.1.0

  • Adds getApplicationCachePath() for storing app-specific cache files.
  • Updates minimum supported SDK version to Flutter 3.3/Dart 2.18.
  • Aligns Dart and Flutter SDK constraints.

2.0.6

  • Updates links for the merge of flutter/plugins into flutter/packages.
  • Updates minimum Flutter version to 3.0.

2.0.5

  • Updates imports for prefer_relative_imports.
  • Updates minimum Flutter version to 2.10.

2.0.4

  • Minor fixes for new analysis options.
  • Removes unnecessary imports.

2.0.3

  • Removes dependency on meta.

2.0.2

  • Update to use the verify method introduced in plugin_platform_interface 2.1.0.

2.0.1

  • Update platform_plugin_interface version requirement.

2.0.0

  • Migrate to null safety.

1.0.5

  • Update Flutter SDK constraint.

1.0.4

  • Remove unused test dependency.

1.0.3

  • Increase upper range of package:platform constraint to allow 3.X versions.

1.0.2

  • Update lower bound of dart dependency to 2.1.0.

1.0.1

  • Rename enum to StorageDirectory for backwards compatibility.

1.0.0

  • Initial release.

Installing

export PUB_HOSTED_URL=https://pub.mirror.p-hatan.ir
flutter pub add 'path_provider_platform_interface:2.1.0'
pubspec.yaml
name: path_provider_platform_interface
description: A common platform interface for the path_provider plugin.
repository: https://github.com/flutter/packages/tree/main/packages/path_provider/path_provider_platform_interface
issue_tracker: https://github.com/flutter/flutter/issues?q=is%3Aissue+is%3Aopen+label%3A%22p%3A+path_provider%22
# NOTE: We strongly prefer non-breaking changes, even at the expense of a
# less-clean API. See https://flutter.dev/go/platform-interface-breaking-changes
version: 2.1.0

environment:
  sdk: ">=2.18.0 <4.0.0"
  flutter: ">=3.3.0"

dependencies:
  flutter:
    sdk: flutter
  platform: ^3.0.0
  plugin_platform_interface: ^2.1.0

dev_dependencies:
  flutter_test:
    sdk: flutter

Version history

VersionPublishedArchiveSHA-256
1.0.0Cached · Upstream SHA-256 matchedDownload1c91cf3b…c12c39
1.0.1Cached · Upstream SHA-256 matchedDownload67561348…f12520
1.0.2Cached · Upstream SHA-256 matchedDownloadf034a281…f113d3
1.0.3Cached · Upstream SHA-256 matchedDownload573cd8a8…8a2bd6
1.0.4Cached · Upstream SHA-256 matchedDownloade06b2d36…bf5354
2.0.0-nullsafetyCached · Upstream SHA-256 matchedDownload93519ed7…0a6558
2.0.0Cached · Upstream SHA-256 matchedDownload2e14fc47…89fa51
2.0.1Cached · Upstream SHA-256 matchedDownloadc2af5a8a…b8a397
2.0.2Cached · Upstream SHA-256 matchedDownloadc3251695…7ace9e
2.0.3Cached · Upstream SHA-256 matchedDownload3dc0d51b…878882
2.0.4Cached · Upstream SHA-256 matchedDownload27dc7a22…da931d
2.0.5Cached · Upstream SHA-256 matchedDownloadf0abc8eb…b08e76
2.0.6Cached · Upstream SHA-256 matchedDownload57585299…3165ec
2.1.0Cached · Upstream SHA-256 matchedDownloadbced5679…f9eb84
2.1.1Cached · Upstream SHA-256 matchedDownload94b1e0dd…63265c
2.1.2Cached · Upstream SHA-256 matchedDownload88f5779f…6c2334
2.1.3Cached · Upstream SHA-256 matchedDownload48483877…7c9dda

Dependencies

flutter { "sdk": "flutter" }

platform "^3.0.0"

plugin_platform_interface "^2.1.0"