Class VFSBase
Virtual file system base abstract class.
Inherited Members
Namespace: Cosmos.System.FileSystem.VFS
Assembly: Cosmos.System2.dll
Syntax
public abstract class VFSBase
Properties
| Improve this Doc View SourceAltDirectorySeparatorChar
Get the alt. directory separator char.
Declaration
public static char AltDirectorySeparatorChar { get; }
Property Value
Type | Description |
---|---|
System.Char |
DirectorySeparatorChar
Get the directory separator char.
Declaration
public static char DirectorySeparatorChar { get; }
Property Value
Type | Description |
---|---|
System.Char |
VolumeSeparatorChar
Get the volume separator char.
Declaration
public static char VolumeSeparatorChar { get; }
Property Value
Type | Description |
---|---|
System.Char |
Methods
| Improve this Doc View SourceCreateDirectory(String)
Create directory.
Declaration
public abstract DirectoryEntry CreateDirectory(string aPath)
Parameters
Type | Name | Description |
---|---|---|
System.String | aPath | A path to the directory. |
Returns
Type | Description |
---|---|
DirectoryEntry | DirectoryEntry value. |
CreateFile(String)
Create File.
Declaration
public abstract DirectoryEntry CreateFile(string aPath)
Parameters
Type | Name | Description |
---|---|---|
System.String | aPath | A path to the file. |
Returns
Type | Description |
---|---|
DirectoryEntry | DirectoryEntry value. |
DeleteDirectory(DirectoryEntry)
Delete directory.
Declaration
public abstract bool DeleteDirectory(DirectoryEntry aPath)
Parameters
Type | Name | Description |
---|---|---|
DirectoryEntry | aPath | A path to the directory. |
Returns
Type | Description |
---|---|
System.Boolean | bool value. |
DeleteFile(DirectoryEntry)
Delete File.
Declaration
public abstract bool DeleteFile(DirectoryEntry aPath)
Parameters
Type | Name | Description |
---|---|---|
DirectoryEntry | aPath | A path to the file. |
Returns
Type | Description |
---|---|
System.Boolean | bool value. |
GetAvailableFreeSpace(String)
Get avilable free space in the partition.
Declaration
public abstract long GetAvailableFreeSpace(string aDriveId)
Parameters
Type | Name | Description |
---|---|---|
System.String | aDriveId | A drive id. |
Returns
Type | Description |
---|---|
System.Int64 | long value. |
GetDirectory(String)
Get directory.
Declaration
public abstract DirectoryEntry GetDirectory(string aPath)
Parameters
Type | Name | Description |
---|---|---|
System.String | aPath | A path to the directory. |
Returns
Type | Description |
---|---|
DirectoryEntry | DirectoryEntry value. |
GetDirectoryListing(DirectoryEntry)
Get directory listing.
Declaration
public abstract List<DirectoryEntry> GetDirectoryListing(DirectoryEntry aEntry)
Parameters
Type | Name | Description |
---|---|---|
DirectoryEntry | aEntry | A entry. |
Returns
Type | Description |
---|---|
System.Collections.Generic.List<DirectoryEntry> | DirectoryEntry list value. |
GetDirectoryListing(String)
Get directory listing.
Declaration
public abstract List<DirectoryEntry> GetDirectoryListing(string aPath)
Parameters
Type | Name | Description |
---|---|---|
System.String | aPath | A path to the entry. |
Returns
Type | Description |
---|---|
System.Collections.Generic.List<DirectoryEntry> | DirectoryEntry list value. |
GetDisks()
Gets all of the disks
Declaration
public abstract List<Disk> GetDisks()
Returns
Type | Description |
---|---|
System.Collections.Generic.List<Disk> | All of the disks on the system |
GetFile(String)
Get file.
Declaration
public abstract DirectoryEntry GetFile(string aPath)
Parameters
Type | Name | Description |
---|---|---|
System.String | aPath | A path to the file. |
Returns
Type | Description |
---|---|
DirectoryEntry | DirectoryEntry value. |
GetFileAttributes(String)
Gets the attributes for a File / Directory.
Declaration
public abstract FileAttributes GetFileAttributes(string aPath)
Parameters
Type | Name | Description |
---|---|---|
System.String | aPath | The path of the File / Directory. |
Returns
Type | Description |
---|---|
System.IO.FileAttributes | FileAttributes value. |
GetFileSystemLabel(String)
Get file system label.
Declaration
public abstract string GetFileSystemLabel(string aDriveId)
Parameters
Type | Name | Description |
---|---|---|
System.String | aDriveId | A drive id. |
Returns
Type | Description |
---|---|
System.String | string value. |
GetFileSystemType(String)
Get file system type.
Declaration
public abstract string GetFileSystemType(string aDriveId)
Parameters
Type | Name | Description |
---|---|---|
System.String | aDriveId | A drive id. |
Returns
Type | Description |
---|---|
System.String | string value. |
GetNextFilesystemLetter()
Gets the next available file system letter.
Declaration
public abstract string GetNextFilesystemLetter()
Returns
Type | Description |
---|---|
System.String | Example: 0 or c |
GetTotalFreeSpace(String)
Get total free space in the partition.
Declaration
public abstract long GetTotalFreeSpace(string aDriveId)
Parameters
Type | Name | Description |
---|---|---|
System.String | aDriveId | A drive id. |
Returns
Type | Description |
---|---|
System.Int64 | long value. |
GetTotalSize(String)
Get the total size of the partition.
Declaration
public abstract long GetTotalSize(string aDriveId)
Parameters
Type | Name | Description |
---|---|---|
System.String | aDriveId | A drive id. |
Returns
Type | Description |
---|---|
System.Int64 | long value. |
GetVolume(String)
Get volume.
Declaration
public abstract DirectoryEntry GetVolume(string aVolume)
Parameters
Type | Name | Description |
---|---|---|
System.String | aVolume | A volume root path. |
Returns
Type | Description |
---|---|
DirectoryEntry | DirectoryEntry value. |
GetVolumes()
Get list of directory entrys for all volumes.
Declaration
public abstract List<DirectoryEntry> GetVolumes()
Returns
Type | Description |
---|---|
System.Collections.Generic.List<DirectoryEntry> | DirectoryEntry list value. |
Initialize(Boolean)
Initializes the VFSBase system.
Declaration
public abstract void Initialize(bool aShowInfo)
Parameters
Type | Name | Description |
---|---|---|
System.Boolean | aShowInfo |
IsValidDriveId(String)
Check if drive id is valid.
Declaration
public abstract bool IsValidDriveId(string driveId)
Parameters
Type | Name | Description |
---|---|---|
System.String | driveId | Drive id to check. |
Returns
Type | Description |
---|---|
System.Boolean | bool value. |
SetFileAttributes(String, FileAttributes)
Sets the attributes for a File / Directory.
Declaration
public abstract void SetFileAttributes(string aPath, FileAttributes fileAttributes)
Parameters
Type | Name | Description |
---|---|---|
System.String | aPath | The path of the File / Directory. |
System.IO.FileAttributes | fileAttributes | The attributes of the File / Directory. |
SetFileSystemLabel(String, String)
Set file system type.
Declaration
public abstract void SetFileSystemLabel(string aDriveId, string aLabel)
Parameters
Type | Name | Description |
---|---|---|
System.String | aDriveId | A drive id. |
System.String | aLabel | A label to be set. |