|
OpenTTD Source
14.0-beta3
|
File list storage for the console, for caching the last 'ls' command. More...
Public Member Functions | |
| ConsoleFileList (AbstractFileType abstract_filetype, bool show_dirs) | |
| void | InvalidateFileList () |
| Declare the file storage cache as being invalid, also clears all stored files. | |
| void | ValidateFileList (bool force_reload=false) |
| (Re-)validate the file storage cache. More... | |
Public Member Functions inherited from FileList | |
| void | BuildFileList (AbstractFileType abstract_filetype, SaveLoadOperation fop, bool show_dirs) |
| Construct a file list with the given kind of files, for the stated purpose. More... | |
| const FiosItem * | FindItem (const std::string_view file) |
| Find file information of a file by its name from the file list. More... | |
Data Fields | |
| AbstractFileType | abstract_filetype |
| The abstract file type to list. | |
| bool | show_dirs |
| Whether to show directories in the file list. | |
| bool | file_list_valid = false |
| If set, the file list is valid. | |
File list storage for the console, for caching the last 'ls' command.
Definition at line 57 of file console_cmds.cpp.
|
inline |
(Re-)validate the file storage cache.
Only makes a change if the storage was invalid, or if force_reload.
| force_reload | Always reload the file storage cache. |
Definition at line 74 of file console_cmds.cpp.
References FileList::BuildFileList(), file_list_valid, and SLO_LOAD.