|
OpenTTD Source 20260421-master-gc2fbc6fdeb
|
List of file information. More...
#include <fios.h>
Public Member Functions | |
| void | BuildFileList (AbstractFileType abstract_filetype, SaveLoadOperation fop, bool show_dirs) |
| Construct a file list with the given kind of files, for the stated purpose. | |
| const FiosItem * | FindItem (std::string_view file) |
| Find file information of a file by its name from the file list. | |
| void FileList::BuildFileList | ( | AbstractFileType | abstract_filetype, |
| SaveLoadOperation | fop, | ||
| bool | show_dirs ) |
Construct a file list with the given kind of files, for the stated purpose.
| abstract_filetype | Kind of files to collect. |
| fop | Purpose of the collection, either SaveLoadOperation::Load or SaveLoadOperation::Save. |
| show_dirs | Whether to show directories. |
Definition at line 57 of file fios.cpp.
References FiosGetHeightmapList(), FiosGetSavegameList(), FiosGetScenarioList(), FiosGetTownDataList(), Heightmap, Load, None, Save, Savegame, Scenario, and TownData.
Referenced by ConsoleFileList::ValidateFileList().
| const FiosItem * FileList::FindItem | ( | std::string_view | file | ) |
Find file information of a file by its name from the file list.
| file | The filename to return information about. Can be the actual name or a numbered entry into the filename list. |
nullptr if the file is not available. Definition at line 93 of file fios.cpp.
References StringConsumer::AnyBytesLeft(), EncodedString::GetDecodedString(), IsInsideMM(), and StringConsumer::TryReadIntegerBase().