This method may not be used to delete directories.
Package
Type Methods
Value Type π
The π class has many class methods which allow you to work with the file system.
See the π class for reading and writing.
Type Methods
π
π πβοΈ π path π‘ Β π§π§πΈβ
This method creates a directory at the given path. If the directory already exists an error is returned.
π«
π πβοΈ π« path π‘ Β π§π§πΈβ
This method deletes the file at the given path.
π₯
π πβοΈ π₯ path π‘ Β π§π§πΈβ
This method deletes an empty directory at the given path. If you need to delete a whole directory hierarchy use π£.
π£
π πβοΈ π£ path π‘ Β π§π§πΈβ
This method deletes an directory with its content. The method recursively descends the directory hierarchy and deletes every file or directory it finds. Once finished, it deletes the directory itself.
π
π πβοΈ π originalFile π‘ destination π‘ Β π§π§πΈβ
This method creates a symbolic link to another.
π
π πβοΈ π path π‘ β‘οΈ π
Determines whether a file exists and the given path and if it is readable.
π
π πβοΈ π path π‘ β‘οΈ π
Determines whether a file exists and the given path and if it is writeable.
π
π πβοΈ π path π‘ β‘οΈ π
Determines whether a file exists and the given path and if it is executable.
π
π πβοΈ π path π‘ β‘οΈ π’Β π§π§πΈβ
Determines the size of a file at a given path. If the file cannot be found or any other error occurs the method returns -1.
β
π πβοΈ β path π‘ β‘οΈ π‘Β π§π§πΈβ
Returns an absolute pathname derived from path
that resolves to the same directory entry, whose resolution does not involve .
, ..
, or symbolic links. On failure an error is returned.