ASAPCabinetFE
 
Loading...
Searching...
No Matches
table_loader.h
Go to the documentation of this file.
1
14#ifndef TABLE_LOADER_H
15#define TABLE_LOADER_H // Header guard to prevent multiple inclusions
16
17#include "itable_loader.h" // Interface for table loading
19#include "core/ui/loading_progress.h" // Structure for tracking loading progress
20#include "config/settings.h" // For Settings class
21#include <vector> // For std::vector
22#include <string> // For std::string
23#include <map> // For std::map
24#include <filesystem> // For std::filesystem namespace alias (fs) to handle file paths
25
26namespace fs = std::filesystem; // Namespace alias for std::filesystem to simplify file path operations
27
39class TableLoader : public ITableLoader {
40public:
46 TableLoader() = default;
47
60 std::vector<TableData> loadTableList(const Settings& settings, LoadingProgress* progress = nullptr) override;
61
70 const std::map<char, int>& getLetterIndex() const override { return letterIndex; }
71
72private:
73 std::map<char, int> letterIndex;
86 void sortTables(std::vector<TableData>& tables, const std::string& sortBy, LoadingProgress* progress);
87};
88
89#endif // TABLE_LOADER_H
Interface for loading table data.
Definition itable_loader.h:15
Implements table loading and indexing for ASAPCabinetFE.
Definition table_loader.h:39
TableLoader()=default
Constructs a TableLoader instance.
const std::map< char, int > & getLetterIndex() const override
Retrieves the letter-based index for table navigation.
Definition table_loader.h:70
std::vector< TableData > loadTableList(const Settings &settings, LoadingProgress *progress=nullptr) override
Loads the list of table data based on application settings.
Definition table_loader.cpp:32
Defines the LoadingProgress struct for tracking loading state in ASAPCabinetFE.
Tracks the loading progress state for ASAPCabinetFE.
Definition loading_progress.h:33
Definition settings.h:12
Defines the TableOverrideManager class for handling per-table JSON overrides in ASAPCabinetFE.