SafPlatform class abstract
The interface that platform implementations of saf v2 must implement.
- Inheritance
-
- Object
- PlatformInterface
- SafPlatform
Constructors
Properties
- hashCode → int
-
The hash code for this object.
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
child(
String dirUri, List< String> names) → Future<SafDocumentFile?> -
closeFileDescriptor(
int fd) → Future< void> -
copyTo(
String uri, String destDirUri, {SafProgressCallback? onProgress}) → Future< SafDocumentFile> -
copyToLocalFile(
String srcUri, String destPath, {SafProgressCallback? onProgress}) → Future< void> -
delete(
String uri) → Future< void> -
exists(
String uri) → Future< bool> -
Whether a document exists at
uri. Default implementation is sugar over stat. -
list(
String dirUri) → Future< List< SafDocumentFile> > -
mkdirp(
String dirUri, List< String> names) → Future<SafDocumentFile> -
moveTo(
String uri, String destDirUri, {SafProgressCallback? onProgress}) → Future< SafDocumentFile> -
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
openFileDescriptor(
String uri, String mode) → Future< SafOpenFd> -
pasteLocalFile(
String srcPath, String destDirUri, String name, String mime, {bool overwrite = false, SafProgressCallback? onProgress}) → Future< SafDocumentFile> -
persistedPermissions(
) → Future< List< SafPersistedPermission> > -
pickDirectory(
{String? initialUri, bool writePermission = true, bool persistablePermission = true}) → Future< SafDocumentFile?> -
pickFile(
{String? initialUri, List< String> ? mimeTypes, bool persistablePermission = false}) → Future<SafDocumentFile?> -
pickFiles(
{String? initialUri, List< String> ? mimeTypes, bool persistablePermission = false}) → Future<List< SafDocumentFile> > -
readFileBytes(
String uri, {int? start, int? count}) → Future< Uint8List> -
readFileStream(
String uri, {int? start, int bufferSize = 4194304}) → Future< Stream< Uint8List> > -
releasePersistedPermission(
String uri) → Future< void> -
rename(
String uri, String newName) → Future< SafDocumentFile> -
stat(
String uri) → Future< SafDocumentFile?> -
thumbnail(
String uri, int width, int height, int quality) → Future< Uint8List?> -
toString(
) → String -
A string representation of this object.
inherited
-
walk(
String dirUri) → Stream< SafWalkEntry> -
writeFileBytes(
String dirUri, String name, String mime, Uint8List data, {bool overwrite = false, bool append = false}) → Future< SafDocumentFile> -
writeFileStream(
String dirUri, String name, String mime, Stream< List< source, {bool overwrite = false, bool append = false}) → Future<int> >SafDocumentFile>
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited
Static Properties
- instance ↔ SafPlatform
-
The default instance of SafPlatform to use.
getter/setter pair