![]() |
Pathfinder
v3.0
The definitive Hacknet programmable modding system
|
Inheritance diagram for Pathfinder.GameFilesystem.Directory:Public Member Functions | |
| Directory (Folder obj, IFileObject parent) | |
| File | FindFile (string name) |
| Finds a File within the Directory based on its name. More... | |
| Directory | FindDirectory (string name) |
| Finds a Directory within the Directory based on its name. More... | |
| Directory | SearchForDirectory (string path, bool ignoreRootSymbol, bool nullOut=false) |
| Searchs for a Directory's path as far as possible. More... | |
| Directory | SearchForDirectory (string path) |
| Searchs for a Directory's path as far as possible. More... | |
| File | SearchForFile (string path, bool ignoreRootSymbol) |
| Searchs for a File's path as far as possible. More... | |
| File | SearchForFile (string path) |
| Searchs for a File's path as far as possible. More... | |
| File | GetFile (int index) |
| Gets a File based on its Index. More... | |
| Directory | GetDirectory (int index) |
| Gets a Directory based on its Index. More... | |
| File | CreateFile (string name, string data=null) |
| Creates a new File based on the name and data. More... | |
| File | CreateFile (string name, Executable.IInterface exeInterface) |
| Creates a File based on the name and the Executable.IInterface generated file data. More... | |
| File | CreateExecutableFile (string name, string exeId) |
| Creates an executable File based on the name and the file data string id. More... | |
| File | CreateExecutableFile (string name, int vanillaIndex) |
| Creates a vanilla executable File based on the name and the vanilla data index. More... | |
| File | CreateRandomFile (string name=null, string data=null) |
| Creates a random File based either on the name or data. (if neither are null then same as CreateFile) More... | |
| File | CreateRandomFile (uint nameIndex, uint? dataIndex=null) |
| Creates a random File based on the nameIndex and dataIndex. More... | |
| Directory | CreateDirectory (string name) |
| Creates a new Directory based on the name. More... | |
| bool | RemoveFile (string name) |
| Removes a File in the Directory by its name. More... | |
| bool | RemoveFile (File f) |
| Removes a File in the Directory. More... | |
| bool | RemoveDirectory (string name) |
| Removes a Directory in the Directory by its name. More... | |
| bool | RemoveDirectory (Directory d) |
| Removes a Directory in the Directory. More... | |
| File | MoveFile (File f, Directory newDir) |
| Moves a File to a new Directory. More... | |
| Directory | MoveDirectory (Directory d, Directory newDir) |
| Moves a Directory to a new Directory. More... | |
| Directory | MoveTo (Directory to) |
| Moves the Directory to a new Directory. More... | |
| bool | Contains (File f) |
| Determines whether the specified File is contained within the Directory. More... | |
| bool | Contains (Directory d) |
| Determines whether the specified Directory is contained within the Directory. More... | |
| bool | ContainsFile (string name=null, string data=null) |
| Determines whether a File with the specified name and/or data is contained within the Directory More... | |
| bool | ContainsDirectory (string name, int? folderCount, int? fileCount=null) |
| bool | ContainsDirectory (string name) |
| IEnumerator< IFileObject > | GetEnumerator () |
Public Attributes | |
| sealed override Filesystem | Root => Parent.Root |
| Gets the root Filesystem the Directory is within. More... | |
| sealed override FileType | Type => FileType.Directory |
| Returns FileType.Directory More... | |
| Directory | ParentDirectory => (Directory)Parent |
| Casts the Parent FileObject to a Directory More... | |
| IFileObject | this[string name] => (IFileObject)FindFile(name) ?? FindDirectory(name) |
| Gets the first T:Pathfinder.GameFilesystem.IFileObject that contains the specified name, searching through files first. More... | |
| List< File > | Files => Object.files.Select(f => new File(f, this)).ToList() |
| Retrieves a list of Files contained within the Directory. More... | |
| List< Directory > | Directories => Object.folders.Select(f => new Directory(f, this)).ToList() |
| Retrieves a list of Directories contained within the Directory. More... | |
| int | FileCount => Object.files.Count |
| Retrieves the amount of Files within the Directory. More... | |
| int | DirectoryCount => Object.folders.Count |
| Retrieves the amount of Directories within the Directory. More... | |
Properties | |
| sealed override string | Name [get, set] |
| Gets or sets the directory name. More... | |
| override string | Path [get, set] |
| Gets or sets the directory's path, both renames and modifies the directory's location. More... | |
| sealed override int | Index [get, set] |
| Gets the index inside its parent's respective list More... | |
| Pathfinder.GameFilesystem.Directory.Directory | ( | Folder | obj, |
| IFileObject | parent | ||
| ) |
| bool Pathfinder.GameFilesystem.Directory.Contains | ( | File | f | ) |
| bool Pathfinder.GameFilesystem.Directory.Contains | ( | Directory | d | ) |
| bool Pathfinder.GameFilesystem.Directory.ContainsDirectory | ( | string | name, |
| int? | folderCount, | ||
| int? | fileCount = null |
||
| ) |
| bool Pathfinder.GameFilesystem.Directory.ContainsDirectory | ( | string | name | ) |
| bool Pathfinder.GameFilesystem.Directory.ContainsFile | ( | string | name = null, |
| string | data = null |
||
| ) |
| Directory Pathfinder.GameFilesystem.Directory.CreateDirectory | ( | string | name | ) |
| File Pathfinder.GameFilesystem.Directory.CreateExecutableFile | ( | string | name, |
| string | exeId | ||
| ) |
| File Pathfinder.GameFilesystem.Directory.CreateExecutableFile | ( | string | name, |
| int | vanillaIndex | ||
| ) |
| File Pathfinder.GameFilesystem.Directory.CreateFile | ( | string | name, |
| string | data = null |
||
| ) |
| File Pathfinder.GameFilesystem.Directory.CreateFile | ( | string | name, |
| Executable.IInterface | exeInterface | ||
| ) |
| name | The name to assign to the File. |
| exeInterface | The Executable.IInterface whose file data is to be generated. |
| File Pathfinder.GameFilesystem.Directory.CreateRandomFile | ( | string | name = null, |
| string | data = null |
||
| ) |
| File Pathfinder.GameFilesystem.Directory.CreateRandomFile | ( | uint | nameIndex, |
| uint? | dataIndex = null |
||
| ) |
| nameIndex | The FileEntry filenames index. (which will max out at the largest index) |
| dataIndex | The FileEntry fileData index, or nameIndex if null. (which will max out at the largest index) |
| Directory Pathfinder.GameFilesystem.Directory.FindDirectory | ( | string | name | ) |
null if not found.| name | The name to find. |
| File Pathfinder.GameFilesystem.Directory.FindFile | ( | string | name | ) |
null if not found.| name | The name to find. |
| Directory Pathfinder.GameFilesystem.Directory.GetDirectory | ( | int | index | ) |
| IEnumerator<IFileObject> Pathfinder.GameFilesystem.Directory.GetEnumerator | ( | ) |
| File Pathfinder.GameFilesystem.Directory.GetFile | ( | int | index | ) |
| bool Pathfinder.GameFilesystem.Directory.RemoveDirectory | ( | string | name | ) |
true, if Directory was found and removed, false otherwise.| name | The name to find. |
| bool Pathfinder.GameFilesystem.Directory.RemoveDirectory | ( | Directory | d | ) |
| bool Pathfinder.GameFilesystem.Directory.RemoveFile | ( | string | name | ) |
true, if File was found and removed, false otherwise.| name | The name to find. |
| bool Pathfinder.GameFilesystem.Directory.RemoveFile | ( | File | f | ) |
| Directory Pathfinder.GameFilesystem.Directory.SearchForDirectory | ( | string | path, |
| bool | ignoreRootSymbol, | ||
| bool | nullOut = false |
||
| ) |
null if nullOut is true.| path | The path to search by. |
| ignoreRootSymbol | If set to true ignores the root (/) symbol at the start. |
| nullOut | If set to true then nulls out on failure, otherwise returns furthest depth |
| Directory Pathfinder.GameFilesystem.Directory.SearchForDirectory | ( | string | path | ) |
| File Pathfinder.GameFilesystem.Directory.SearchForFile | ( | string | path, |
| bool | ignoreRootSymbol | ||
| ) |
null if not found.| path | The path to search by. |
| ignoreRootSymbol | If set to true ignores the root (/) symbol at the start. |
| File Pathfinder.GameFilesystem.Directory.SearchForFile | ( | string | path | ) |
null if not found.| path | The path to search by. |
| List<Directory> Pathfinder.GameFilesystem.Directory.Directories => Object.folders.Select(f => new Directory(f, this)).ToList() |
The directories.
| int Pathfinder.GameFilesystem.Directory.DirectoryCount => Object.folders.Count |
| int Pathfinder.GameFilesystem.Directory.FileCount => Object.files.Count |
| List<File> Pathfinder.GameFilesystem.Directory.Files => Object.files.Select(f => new File(f, this)).ToList() |
The Parent as Directory
| sealed override Filesystem Pathfinder.GameFilesystem.Directory.Root => Parent.Root |
| IFileObject Pathfinder.GameFilesystem.Directory.this[string name] => (IFileObject)FindFile(name) ?? FindDirectory(name) |
| name | Name. |
| sealed override FileType Pathfinder.GameFilesystem.Directory.Type => FileType.Directory |
|
getset |
The folder index in the parent or -1 if root directory.
|
getset |
The name of the directory.
|
getset |
The directory's path.