Developer Resources
DriveInfo
Overview
The DriveInfo class provides information about drives and/or volumes mounted on a system.
Methods
- DriveInfo.getAvailableSpace
- Gets the amount of available space on the volume for a user
- DriveInfo.getDrives
- Retrieves information about all drives on the system
- DriveInfo.getFreeSpace
- Gets the amount of free space on the volume
- DriveInfo.getName
- Gets the name of the volume
- DriveInfo.getTotalSize
- Gets the total size of a volume
DriveInfo.getAvailableSpace
- function DriveInfo.getAvailableSpace() : Number
Returns
The amount of space available to the current user, in bytes.
Description
The getAvailableSpace() method returns the number of bytes available on the volume to the current user. This can differ from the total amount of space available if a quota system is active.
DriveInfo.getDrives
- static function DriveInfo.getDrives() : Array(DriveInfo)
Returns
An array of DriveInfo objects
Description
Calling DriveInfo.getDrives() returns an array of DriveInfo objects which represent all available mounted volumes on the system.
DriveInfo.getFreeSpace
- function DriveInfo.getFreeSpace() : Number
Returns
The amount of free space, in bytes.
Description
The getFreeSpace() method returns the number of free bytes on the volume.
DriveInfo.getName
- function DriveInfo.getName() : String
Returns
A string containing the volume name
Description
The getName() method returns the name of the volume. The exact format of this string depends on the platform under which the program is running. For example, on WIN32 systems, a volume name can be "C:\", "D:\", etc.
DriveInfo.getTotalSize
- function DriveInfo.getTotalSize() : Number
Returns
The total size of a volume, in bytes.
Description
The getTotalSize() method returns the total storage capacity of a volume.