1 <?xml version="1.0" encoding="utf-8"?><doc>
3 <name>System.IO.FileSystem.DriveInfo</name>
6 <member name="T:System.IO.DriveType">
7 <summary>Defines constants for drive types, including CDRom, Fixed, Network, NoRootDirectory, Ram, Removable, and Unknown.</summary>
9 <member name="F:System.IO.DriveType.CDRom">
10 <summary>The drive is an optical disc device, such as a CD or DVD-ROM.</summary>
13 <member name="F:System.IO.DriveType.Fixed">
14 <summary>The drive is a fixed disk.</summary>
17 <member name="F:System.IO.DriveType.Network">
18 <summary>The drive is a network drive.</summary>
21 <member name="F:System.IO.DriveType.NoRootDirectory">
22 <summary>The drive does not have a root directory.</summary>
25 <member name="F:System.IO.DriveType.Ram">
26 <summary>The drive is a RAM disk.</summary>
29 <member name="F:System.IO.DriveType.Removable">
30 <summary>The drive is a removable storage device, such as a floppy disk drive or a USB flash drive.</summary>
33 <member name="F:System.IO.DriveType.Unknown">
34 <summary>The type of drive is unknown.</summary>
37 <member name="T:System.IO.DriveNotFoundException">
38 <summary>The exception that is thrown when trying to access a drive or share that is not available.</summary>
40 <member name="M:System.IO.DriveNotFoundException.#ctor">
41 <summary>Initializes a new instance of the <see cref="T:System.IO.DriveNotFoundException"></see> class with its message string set to a system-supplied message and its HRESULT set to COR_E_DIRECTORYNOTFOUND.</summary>
43 <member name="M:System.IO.DriveNotFoundException.#ctor(System.String)">
44 <summary>Initializes a new instance of the <see cref="T:System.IO.DriveNotFoundException"></see> class with the specified message string and the HRESULT set to COR_E_DIRECTORYNOTFOUND.</summary>
45 <param name="message">A <see cref="T:System.String"></see> object that describes the error. The caller of this constructor is required to ensure that this string has been localized for the current system culture.</param>
47 <member name="M:System.IO.DriveNotFoundException.#ctor(System.Runtime.Serialization.SerializationInfo,System.Runtime.Serialization.StreamingContext)">
48 <summary>Initializes a new instance of the <see cref="T:System.IO.DriveNotFoundException"></see> class with the specified serialization and context information.</summary>
49 <param name="info">A <see cref="T:System.Runtime.Serialization.SerializationInfo"></see> object that contains the serialized object data about the exception being thrown.</param>
50 <param name="context">A <see cref="T:System.Runtime.Serialization.StreamingContext"></see> object that contains contextual information about the source or destination of the exception being thrown.</param>
52 <member name="M:System.IO.DriveNotFoundException.#ctor(System.String,System.Exception)">
53 <summary>Initializes a new instance of the <see cref="T:System.IO.DriveNotFoundException"></see> class with the specified error message and a reference to the inner exception that is the cause of this exception.</summary>
54 <param name="message">The error message that explains the reason for the exception.</param>
55 <param name="innerException">The exception that is the cause of the current exception. If the innerException parameter is not <see langword="null"></see>, the current exception is raised in a <see langword="catch"></see> block that handles the inner exception.</param>
57 <member name="T:System.IO.DriveInfo">
58 <summary>Provides access to information on a drive.</summary>
60 <member name="M:System.IO.DriveInfo.#ctor(System.String)">
61 <summary>Provides access to information on the specified drive.</summary>
62 <param name="driveName">A valid drive path or drive letter. This can be either uppercase or lowercase, &#39;a&#39; to &#39;z&#39;. A null value is not valid.</param>
63 <exception cref="T:System.ArgumentNullException">The drive letter cannot be <see langword="null"></see>.</exception>
64 <exception cref="T:System.ArgumentException">The first letter of <paramref name="driveName">driveName</paramref> is not an uppercase or lowercase letter from &#39;a&#39; to &#39;z&#39;.
66 <paramref name="driveName">driveName</paramref> does not refer to a valid drive.</exception>
68 <member name="P:System.IO.DriveInfo.AvailableFreeSpace">
69 <summary>Indicates the amount of available free space on a drive, in bytes.</summary>
70 <returns>The amount of free space available on the drive, in bytes.</returns>
71 <exception cref="T:System.UnauthorizedAccessException">Access to the drive information is denied.</exception>
72 <exception cref="T:System.IO.IOException">An I/O error occurred (for example, a disk error or a drive was not ready).</exception>
74 <member name="P:System.IO.DriveInfo.DriveFormat">
75 <summary>Gets the name of the file system, such as NTFS or FAT32.</summary>
76 <returns>The name of the file system on the specified drive.</returns>
77 <exception cref="T:System.UnauthorizedAccessException">Access to the drive information is denied.</exception>
78 <exception cref="T:System.IO.DriveNotFoundException">The drive does not exist or is not mapped.</exception>
79 <exception cref="T:System.IO.IOException">An I/O error occurred (for example, a disk error or a drive was not ready).</exception>
81 <member name="P:System.IO.DriveInfo.DriveType">
82 <summary>Gets the drive type, such as CD-ROM, removable, network, or fixed.</summary>
83 <returns>One of the enumeration values that specifies a drive type.</returns>
85 <member name="M:System.IO.DriveInfo.GetDrives">
86 <summary>Retrieves the drive names of all logical drives on a computer.</summary>
87 <returns>An array of type <see cref="T:System.IO.DriveInfo"></see> that represents the logical drives on a computer.</returns>
88 <exception cref="T:System.IO.IOException">An I/O error occurred (for example, a disk error or a drive was not ready).</exception>
89 <exception cref="T:System.UnauthorizedAccessException">The caller does not have the required permission.</exception>
91 <member name="P:System.IO.DriveInfo.IsReady">
92 <summary>Gets a value that indicates whether a drive is ready.</summary>
93 <returns><see langword="true"></see> if the drive is ready; <see langword="false"></see> if the drive is not ready.</returns>
95 <member name="P:System.IO.DriveInfo.Name">
96 <summary>Gets the name of a drive, such as C:\.</summary>
97 <returns>The name of the drive.</returns>
99 <member name="P:System.IO.DriveInfo.RootDirectory">
100 <summary>Gets the root directory of a drive.</summary>
101 <returns>An object that contains the root directory of the drive.</returns>
103 <member name="M:System.IO.DriveInfo.ToString">
104 <summary>Returns a drive name as a string.</summary>
105 <returns>The name of the drive.</returns>
107 <member name="P:System.IO.DriveInfo.TotalFreeSpace">
108 <summary>Gets the total amount of free space available on a drive, in bytes.</summary>
109 <returns>The total free space available on a drive, in bytes.</returns>
110 <exception cref="T:System.UnauthorizedAccessException">Access to the drive information is denied.</exception>
111 <exception cref="T:System.IO.DriveNotFoundException">The drive is not mapped or does not exist.</exception>
112 <exception cref="T:System.IO.IOException">An I/O error occurred (for example, a disk error or a drive was not ready).</exception>
114 <member name="P:System.IO.DriveInfo.TotalSize">
115 <summary>Gets the total size of storage space on a drive, in bytes.</summary>
116 <returns>The total size of the drive, in bytes.</returns>
117 <exception cref="T:System.UnauthorizedAccessException">Access to the drive information is denied.</exception>
118 <exception cref="T:System.IO.DriveNotFoundException">The drive is not mapped or does not exist.</exception>
119 <exception cref="T:System.IO.IOException">An I/O error occurred (for example, a disk error or a drive was not ready).</exception>
121 <member name="P:System.IO.DriveInfo.VolumeLabel">
122 <summary>Gets or sets the volume label of a drive.</summary>
123 <returns>The volume label.</returns>
124 <exception cref="T:System.IO.IOException">An I/O error occurred (for example, a disk error or a drive was not ready).</exception>
125 <exception cref="T:System.IO.DriveNotFoundException">The drive is not mapped or does not exist.</exception>
126 <exception cref="T:System.Security.SecurityException">The caller does not have the required permission.</exception>
127 <exception cref="T:System.UnauthorizedAccessException">The volume label is being set on a network or CD-ROM drive.
129 Access to the drive information is denied.</exception>
131 <member name="M:System.IO.DriveInfo.System#Runtime#Serialization#ISerializable#GetObjectData(System.Runtime.Serialization.SerializationInfo,System.Runtime.Serialization.StreamingContext)">
132 <summary>Populates a <see cref="T:System.Runtime.Serialization.SerializationInfo"></see> object with the data needed to serialize the target object.</summary>
133 <param name="info">The object to populate with data.</param>
134 <param name="context">The destination (see <see cref="T:System.Runtime.Serialization.StreamingContext"></see>) for this serialization.</param>