FileSystemProvider class

The filesystem provider defines what the editor needs to read, write, discover, and to manage files and folders. It allows extensions to serve files from remote places, like ftp-servers, and to seamlessly integrate those into the editor.

  • Note 1: The filesystem provider API works with {@link Uriuris} and assumes hierarchical paths, e.g. foo:/my/path is a child of foo:/my/ and a parent of foo:/my/path/deeper.
  • Note 2: There is an activation event onFileSystem:<scheme> that fires when a file or folder is being accessed.
  • Note 3: The word 'file' is often used to denote all {@link FileTypekinds} of files, e.g. folders, symbolic links, and regular files.
Available extensions
Annotations
  • @JS()
  • @staticInterop
  • @anonymous

Constructors

FileSystemProvider.new({Event<List<FileChangeEvent>>? onDidChangeFile, Disposable watch(Uri, dynamic)?, Object stat(Uri)?, FutureOr<List<(String, FileType)>> readDirectory(Uri)?, FutureOr<void> createDirectory(Uri)?, FutureOr<Uint8List> readFile(Uri)?, FutureOr<void> writeFile(Uri, Uint8List, dynamic)?, FutureOr<void> delete(Uri, dynamic)?, FutureOr<void> rename(Uri, Uri, dynamic)?, FutureOr<void> copy(Uri, Uri, dynamic)?})
factory

Properties

copy FutureOr<void> Function(Uri, Uri, dynamic)

Available on FileSystemProvider, provided by the FileSystemProvider$Typings extension

getter/setter pair
createDirectory FutureOr<void> Function(Uri)

Available on FileSystemProvider, provided by the FileSystemProvider$Typings extension

getter/setter pair
delete FutureOr<void> Function(Uri, dynamic)

Available on FileSystemProvider, provided by the FileSystemProvider$Typings extension

getter/setter pair
hashCode int
The hash code for this object.
no setterinherited
onDidChangeFile Event<List<FileChangeEvent>>

Available on FileSystemProvider, provided by the FileSystemProvider$Typings extension

An event to signal that a resource has been created, changed, or deleted. This event should fire for resources that are being {@link FileSystemProvider.watchwatched} by clients of this provider.
no setter
readDirectory FutureOr<List<(String, FileType)>> Function(Uri)

Available on FileSystemProvider, provided by the FileSystemProvider$Typings extension

getter/setter pair
readFile FutureOr<Uint8List> Function(Uri)

Available on FileSystemProvider, provided by the FileSystemProvider$Typings extension

getter/setter pair
rename FutureOr<void> Function(Uri, Uri, dynamic)

Available on FileSystemProvider, provided by the FileSystemProvider$Typings extension

getter/setter pair
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
stat Object Function(Uri)

Available on FileSystemProvider, provided by the FileSystemProvider$Typings extension

getter/setter pair
watch Disposable Function(Uri, dynamic)

Available on FileSystemProvider, provided by the FileSystemProvider$Typings extension

getter/setter pair
writeFile FutureOr<void> Function(Uri, Uint8List, dynamic)

Available on FileSystemProvider, provided by the FileSystemProvider$Typings extension

getter/setter pair

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited