FileSystemEntity class abstract
A reference to an entity on the file system, such as a file or directory.
FileSystemEntity is an abstract class, with subclasses File,
Directory, and Link. Most of the methods in this class are abstract and
are implemented in the subclasses.
- Implementers
Constructors
Properties
- fs → FileSystem
-
The file system for this entity.
no setter
- hashCode → int
-
The hash code for this object.
no setterinherited
- isAbsolute → bool
-
Returns a
boolindicating whether this object's path is absolute.no setter - parent → Directory
-
The directory containing
this.no setter - path → String
-
The path of the entity.
no setter
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
delete(
{bool recursive = false}) → Future< FileSystemEntity> - Deletes this FileSystemEntity.
-
exists(
) → Future< bool> - Checks whether the file system entity with this path exists.
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
rename(
String newPath) → Future< FileSystemEntity> - Renames this file system entity.
-
stat(
) → Future< FileStat> -
Calls the operating system's
stat()function on the path of this FileSystemEntity. -
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited
Static Methods
-
isDirectory(
String path) → Future< bool> -
Checks if
type(path)returnsFileSystemEntityType.directory. -
isFile(
String path) → Future< bool> -
Checks if
type(path)returnsFileSystemEntityType.file. -
isLink(
String path) → Future< bool> -
Checks if
type(path, followLinks: false)returnsFileSystemEntityType.link. -
type(
String path, {bool followLinks = true}) → Future< FileSystemEntityType> - Finds the type of file system object that a path points to.