6 #ifndef SWIFT_MISC_SIMULATION_FSCOMMON_VPILOTRULESREADER_H
7 #define SWIFT_MISC_SIMULATION_FSCOMMON_VPILOTRULESREADER_H
10 #include <QReadWriteLock>
12 #include <QStringList>
24 namespace simulation::fscommon
41 QStringList getFiles()
const;
45 bool hasFiles()
const;
49 void addFilename(
const QString &fileName);
53 void addDirectory(
const QString &directory);
57 int countFilesLoaded()
const;
73 int getModelsCount()
const;
77 int countRulesLoaded()
const;
81 void gracefulShutdown();
84 static const QString &standardMappingsDirectory();
93 bool read(
bool convertToModels);
102 void ps_readInBackgroundFinished();
105 void ps_onVPilotCacheChanged();
112 QStringList m_fileList;
113 QStringList m_fileListWithProblems;
114 int m_loadedFiles = 0;
116 bool m_asyncLoadInProgress =
false;
117 bool m_shutdown =
false;
119 this, &CVPilotRulesReader::ps_onVPilotCacheChanged
121 mutable QReadWriteLock m_lockData;
Class template for accessing a specific value in the CDataCache.
Class for doing some arbitrary parcel of work in its own thread.
Value object encapsulating a list of aircraft models.
Value object reading a set of vPilot rules.
void readFinished(bool success)
Rules read.
Free functions in swift::misc.
#define SWIFT_MISC_EXPORT
Export a class or function from the library.