FileSystemInfo

FileSystemInfo


The FileSystemInfo interface is used to access both FileInfo and DirectoryInfo objects using the same code. This allows for similar properties and methods to be used on both files and directories with a single routine.


Public:

Types:

NameDescription
 FileAttributes Flags used to indicate properties of a file or directory.  

Properties:

NameDescription
 Attributes (get) Returns the attributes for the FileSystemInfo entry.  
 Attributes (let) Sets the attributes for the FileSystemInfo entry.  
 CreationTime (get) Returns the time the FileSystemInfo entry was created in local time.  
 CreationTime (let) Sets the time the FileSystemInfo entry was created in local time.  
 CreationTime (set) Sets the time the FileSystemInfo entry was created in local time.  
 CreationTimeUtc (get) Returns the time the FileSystemInfo entry was created in UTC time.  
 CreationTimeUtc (let) Sets the time the FileSystemInfo entry was created in UTC time.  
 CreationTimeUtc (set) Sets the time the FileSystemInfo entry was created in UTC time.  
 Exists (get) Returns if the FileSystemInfo entry exists.  
 Extension (get) Returns the extension portion of the name.  
 FullName (get) Returns the full name of the entry.  
 LastAccessTime (get) Returns the time the FileSystemInfo entry was last accessed in local time.  
 LastAccessTime (let) Sets the time the FileSystemInfo entry was last accessed in local time.  
 LastAccessTime (set) Sets the time the FileSystemInfo entry was last accessed in local time.  
 LastAccessTimeUtc (get) Returns the time the FileSystemInfo entry was last accessed in UTC time.  
 LastAccessTimeUtc (let) Sets the time the FileSystemInfo entry was last accessed in UTC time.  
 LastAccessTimeUtc (set) Sets the time the FileSystemInfo entry was last accessed in UTC time.  
 LastWriteTime (get) Returns the time the FileSystemInfo entry was last written to in local time.  
 LastWriteTime (let) Sets the time the FileSystemInfo entry was last written to in local time.  
 LastWriteTime (set) Sets the time the FileSystemInfo entry was last written to in local time.  
 LastWriteTimeUtc (get) Returns the time the FileSystemInfo entry was last written to in UTC time.  
 LastWriteTimeUtc (let) Sets the time the FileSystemInfo entry was last written to in UTC time.  
 LastWriteTimeUtc (set) Sets the time the FileSystemInfo entry was last written to in UTC time.  
 Name (get) Returns the name of the entry.  

Methods:

NameDescription
 Delete Deletes the entry from disk.  
 Equals Tests for equality with the passed in value.  
 GetHashCode Returns a pseudo-unique number used to represent this instance.  
 Refresh Reloads the entry with the most current information.  
 ToString Returns a string representation of this instance.  

See Also

Project CorLib Overview

Class FileSystemInfo Overview