OpenTTD Source  12.0-beta2
FileList Class Reference

List of file information. More...

#include <fios.h>

Inheritance diagram for FileList:
ConsoleFileList

Public Member Functions

void BuildFileList (AbstractFileType abstract_filetype, SaveLoadOperation fop)
 Construct a file list with the given kind of files, for the stated purpose. More...
 
const FiosItemFindItem (const char *file)
 Find file information of a file by its name from the file list. More...
 

Detailed Description

List of file information.

Definition at line 96 of file fios.h.

Member Function Documentation

◆ BuildFileList()

void FileList::BuildFileList ( AbstractFileType  abstract_filetype,
SaveLoadOperation  fop 
)

Construct a file list with the given kind of files, for the stated purpose.

Parameters
abstract_filetypeKind of files to collect.
fopPurpose of the collection, either SLO_LOAD or SLO_SAVE.

Definition at line 72 of file fios.cpp.

References FiosGetHeightmapList(), FiosGetSavegameList(), FiosGetScenarioList(), FT_HEIGHTMAP, FT_NONE, FT_SAVEGAME, FT_SCENARIO, SLO_LOAD, and SLO_SAVE.

Referenced by ConsoleFileList::ValidateFileList().

◆ FindItem()

const FiosItem * FileList::FindItem ( const char *  file)

Find file information of a file by its name from the file list.

Parameters
fileThe filename to return information about. Can be the actual name or a numbered entry into the filename list.
Returns
The information on the file, or nullptr if the file is not available.

Definition at line 104 of file fios.cpp.

References IsInsideMM().


The documentation for this class was generated from the following files: