FlutterMediaScanner class

Constructors

FlutterMediaScanner()

Properties

hashCode int
The hash code for this object. [...]
read-only, inherited
runtimeType Type
A representation of the runtime type of the object.
read-only, inherited

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a non-existent method or property is accessed. [...]
inherited
toString() String
Returns a string representation of this object.
inherited

Operators

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

Static Methods

scan(String path) Future
path is the file path Here is an example: File originalFile = File("path/to/file"); List bytes = await originalFile.readAsBytes(); save your file to your desired path File file = File("desired/path"); await file.writeAsBytes(bytes); refresh the file system so the file can show in the gallery, await FlutterMediaScanner.scan(file.path);