Class DirectoryEntry
A generic file system directory entry.
Inheritance
System.Object
DirectoryEntry
Inherited Members
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: Cosmos.System.FileSystem.Listing
Assembly: Cosmos.System2.dll
Syntax
public abstract class DirectoryEntry
Constructors
| Improve this Doc View SourceDirectoryEntry(FileSystem, DirectoryEntry, String, String, Int64, DirectoryEntryTypeEnum)
Initializes a new instance of the Directory
Declaration
protected DirectoryEntry(FileSystem aFileSystem, DirectoryEntry aParent, string aFullPath, string aName, long aSize, DirectoryEntryTypeEnum aEntryType)
Parameters
Type | Name | Description |
---|---|---|
File |
aFileSystem | The file system that contains the directory entry. |
Directory |
aParent | The parent directory entry or null if the current entry is the root. |
System. |
aFullPath | The full path to the entry. |
System. |
aName | The entry name. |
System. |
aSize | The size of the entry. |
Directory |
aEntryType | The ype of the entry. |
Exceptions
Type | Condition |
---|---|
System. |
Thrown if aFileSystem is null. |
System. |
Thrown if aFullPath / aName is null. |
Fields
| Improve this Doc View SourcemEntryType
Entry type.
Declaration
public readonly DirectoryEntryTypeEnum mEntryType
Field Value
Type | Description |
---|---|
Directory |
mFileSystem
Declaration
protected readonly FileSystem mFileSystem
Field Value
Type | Description |
---|---|
File |
mFullPath
Entry full path.
Declaration
public string mFullPath
Field Value
Type | Description |
---|---|
System. |
mName
Entry name.
Declaration
public string mName
Field Value
Type | Description |
---|---|
System. |
mParent
Entry parent.
Declaration
public readonly DirectoryEntry mParent
Field Value
Type | Description |
---|---|
Directory |
mSize
Entry size.
Declaration
public long mSize
Field Value
Type | Description |
---|---|
System. |
Methods
| Improve this Doc View SourceGetFileStream()
Get file stream.
Declaration
public abstract Stream GetFileStream()
Returns
Type | Description |
---|---|
System. |
Stream value. |
GetUsedSpace()
Get used space.
Declaration
public abstract long GetUsedSpace()
Returns
Type | Description |
---|---|
System. |
long value. |
SetName(String)
Set entry name.
Declaration
public abstract void SetName(string aName)
Parameters
Type | Name | Description |
---|---|---|
System. |
aName | A name to be set. |
SetSize(Int64)
Set entry size.
Declaration
public abstract void SetSize(long aSize)
Parameters
Type | Name | Description |
---|---|---|
System. |
aSize | A size to be set. |