BSD:
AFL 3.0:
Mar 2004: Initial release
Feb 2007: Now using mutating paths
Kris, Chris Sauls (Win95 file support)
- struct FileSystem ¶#
-
Models an OS-specific file-system. Included here are methods to
manipulate the current working directory, and to convert a path
to its absolute form.
- FilePath toAbsolute(FilePath target, char[] prefix = null) [static, deprecated] ¶#
-
Convert the provided path to an absolute path, using the
current working directory where prefix is not provided.
If the given path is already an absolute path, return it
intact.
Returns the provided path, adjusted as necessary
see FilePath.absolute
- char[] toAbsolute(char[] path, char[] prefix = null) [static, deprecated] ¶#
-
Convert the provided path to an absolute path, using the
current working directory where prefix is not provided.
If the given path is already an absolute path, return it
intact.
Returns the provided path, adjusted as necessary
see FilePath.absolute
- bool equals(char[] path1, char[] path2, char[] prefix = null) [static, deprecated] ¶#
-
Compare to paths for absolute equality. The given prefix
is prepended to the paths where they are not already in
absolute format (start with a '/'). Where prefix is not
provided, the current working directory will be used
Returns true if the paths are equivalent, false otherwise
see FilePath.equals
- void exception(char[] msg) [private, static] ¶#
-
- void setDirectory(char[] path) [static, deprecated] ¶#
-
Set the current working directory
see Environment.cwd()
- char[] getDirectory() [static, deprecated] ¶#
-
Return the current working directory
see Environment.cwd()
- char[][] roots() [static] ¶#
-
List the set of root devices (C:, D: etc)
- long freeSpace(char[] folder, bool superuser = false) [static] ¶#
-
Request how much free space in bytes is available on the
disk/mountpoint where folder resides.
If a quota limit exists for this area, that will be taken
into account unless superuser is set to true.
If a user has exceeded the quota, a negative number can
be returned.
Note that the difference between total available space
and free space will not equal the combined size of the
contents on the file system, since the numbers for the
functions here are calculated from the used blocks,
including those spent on metadata and file nodes.
If actual used space is wanted one should use the
statistics functionality of tango.io.vfs.
See also: totalSpace()
0.99.9
- ulong totalSpace(char[] folder, bool superuser = false) [static] ¶#
-
Request how large in bytes the
disk/mountpoint where folder resides is.
If a quota limit exists for this area, then
that quota can be what will be returned unless superuser
is set to true. On Posix systems this distinction is not
made though.
NOTE Access to this information when _superuser is
set to true may only be available if the program is
run in superuser mode.
See also: freeSpace()
0.99.9