mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-04-13 07:35:41 +08:00
committed by
Lars Toenning
parent
5e5b3f830d
commit
7691e42a5b
@@ -148,8 +148,8 @@ namespace BlackMisc::Simulation
|
||||
//! Force mode as string
|
||||
QString getForceModeAsString() const { return forceToString(this->getForceMode()); }
|
||||
|
||||
//! Reverse lookup
|
||||
//! @{
|
||||
//! Reverse lookup
|
||||
bool isReverseLookupModelString() const;
|
||||
bool isReverseLookupSwiftLiveryIds() const;
|
||||
void resetReverseLookup();
|
||||
@@ -158,32 +158,32 @@ namespace BlackMisc::Simulation
|
||||
//! DB data?
|
||||
bool isDbDataOnly() const { return this->getMatchingMode().testFlag(ExcludeNoDbData); }
|
||||
|
||||
//! Get matching files
|
||||
//! @{
|
||||
//! Get matching files
|
||||
const QString &getMsReverseLookupFile() const { return m_msReverseLookupFile; }
|
||||
const QString &getMsMatchingStageFile() const { return m_msMatchingStageFile; }
|
||||
//! @}
|
||||
|
||||
//! Set matching files
|
||||
//! @{
|
||||
//! Set matching files
|
||||
void setMsReverseLookupFile(const QString &file) { m_msReverseLookupFile = file; }
|
||||
void setMsMatchingStageFile(const QString &file) { m_msMatchingStageFile = file; }
|
||||
//! @}
|
||||
|
||||
//! Is matching script enabled
|
||||
//! @{
|
||||
//! Is matching script enabled
|
||||
bool isMsReverseLookupEnabled() const { return m_msReverseEnabled; }
|
||||
bool isMsMatchingStageEnabled() const { return m_msMatchingEnabled; }
|
||||
//! @}
|
||||
|
||||
//! Run the scripts
|
||||
//! @{
|
||||
//! Run the scripts
|
||||
bool doRunMsReverseLookupScript() const;
|
||||
bool doRunMsMatchingStageScript() const;
|
||||
//! @}
|
||||
|
||||
//! Is matching script enabled
|
||||
//! @{
|
||||
//! Is matching script enabled
|
||||
void setMsReverseLookupEnabled(bool enabled) { m_msReverseEnabled = enabled; }
|
||||
void setMsMatchingStageEnabled(bool enabled) { m_msMatchingEnabled = enabled; }
|
||||
//! @}
|
||||
|
||||
@@ -23,8 +23,8 @@ namespace BlackMisc::Simulation
|
||||
//! Set models
|
||||
virtual void setModels(const CAircraftModelList &models) = 0;
|
||||
|
||||
//! Ctor, dtor, copy operators (CLANG warnings)
|
||||
//! @{
|
||||
//! Ctor, dtor, copy operators (CLANG warnings)
|
||||
IModelsSetable() {}
|
||||
virtual ~IModelsSetable() {}
|
||||
IModelsSetable(const IModelsSetable &) = default;
|
||||
@@ -39,8 +39,8 @@ namespace BlackMisc::Simulation
|
||||
//! Update models
|
||||
virtual int updateModels(const CAircraftModelList &models) = 0;
|
||||
|
||||
//! Ctor, dtor, copy operators (CLANG warnings)
|
||||
//! @{
|
||||
//! Ctor, dtor, copy operators (CLANG warnings)
|
||||
IModelsUpdatable() {}
|
||||
virtual ~IModelsUpdatable() {}
|
||||
IModelsUpdatable(const IModelsUpdatable &) = default;
|
||||
@@ -55,8 +55,8 @@ namespace BlackMisc::Simulation
|
||||
//! Set models
|
||||
virtual void setModelsForSimulator(const CAircraftModelList &models, const CSimulatorInfo &simulator) = 0;
|
||||
|
||||
//! Ctor, dtor, copy operators (CLANG warnings)
|
||||
//! @{
|
||||
//! Ctor, dtor, copy operators (CLANG warnings)
|
||||
IModelsForSimulatorSetable() {}
|
||||
virtual ~IModelsForSimulatorSetable() {}
|
||||
IModelsForSimulatorSetable(const IModelsForSimulatorSetable &) = default;
|
||||
@@ -71,8 +71,8 @@ namespace BlackMisc::Simulation
|
||||
//! Set models
|
||||
virtual int updateModelsForSimulator(const CAircraftModelList &models, const CSimulatorInfo &simulator) = 0;
|
||||
|
||||
//! Ctor, dtor, copy operators (CLANG warnings)
|
||||
//! @{
|
||||
//! Ctor, dtor, copy operators (CLANG warnings)
|
||||
IModelsForSimulatorUpdatable() {}
|
||||
virtual ~IModelsForSimulatorUpdatable() {}
|
||||
IModelsForSimulatorUpdatable(const IModelsForSimulatorUpdatable &) = default;
|
||||
@@ -87,8 +87,8 @@ namespace BlackMisc::Simulation
|
||||
//! Simulator
|
||||
virtual BlackMisc::Simulation::CSimulatorInfo getSelectedSimulator() const = 0;
|
||||
|
||||
//! Ctor, dtor, copy operators (CLANG warnings)
|
||||
//! @{
|
||||
//! Ctor, dtor, copy operators (CLANG warnings)
|
||||
ISimulatorSelectable() {}
|
||||
virtual ~ISimulatorSelectable() {}
|
||||
ISimulatorSelectable(const ISimulatorSelectable &) = default;
|
||||
|
||||
@@ -221,8 +221,8 @@ namespace BlackMisc
|
||||
//! Find color liveries
|
||||
CAircraftModelList findColorLiveries() const;
|
||||
|
||||
//! Find models with the closest color distance
|
||||
//! @{
|
||||
//! Find models with the closest color distance
|
||||
CAircraftModelList findClosestColorDistance(const CRgbColor &fuselage, const CRgbColor &tail) const;
|
||||
CAircraftModelList findClosestFuselageColorDistance(const CRgbColor &color) const;
|
||||
//! @}
|
||||
@@ -266,22 +266,22 @@ namespace BlackMisc
|
||||
//! All models NOT of the FS (FSX, P3D, FS9) family
|
||||
CAircraftModelList findNonFsFamilyModels() const;
|
||||
|
||||
//! With/without DB key
|
||||
//! @{
|
||||
//! With/without DB key
|
||||
CAircraftModelList findWithValidDbKey() const;
|
||||
CAircraftModelList findWithoutValidDbKey() const;
|
||||
CAircraftModelList findWithoutValidDbKey(int maxElements) const;
|
||||
//! @}
|
||||
|
||||
//! Some finders for NON DB models, mostly for matching script results
|
||||
//! @{
|
||||
//! Some finders for NON DB models, mostly for matching script results
|
||||
CAircraftModelList findNonDbModelsForAirline(const QString &airline) const;
|
||||
CAircraftModelList findNonDbModelsForAircraft(const QString &airline) const;
|
||||
CAircraftModelList findNonDbModelsForModelString(const QString &modelString) const;
|
||||
//! @}
|
||||
|
||||
//! All included/excluded models
|
||||
//! @{
|
||||
//! All included/excluded models
|
||||
CAircraftModelList findAllIncludedModels() const;
|
||||
CAircraftModelList findAllIncludedModels(int maxElements) const;
|
||||
CAircraftModelList findAllExcludedModels() const;
|
||||
@@ -546,16 +546,16 @@ namespace BlackMisc
|
||||
//! A HTML summary of the data in the list
|
||||
QString htmlStatistics(bool aircraftStats, bool airlineStats) const;
|
||||
|
||||
//! Save/load invalid models
|
||||
//! @{
|
||||
//! Save/load invalid models
|
||||
CStatusMessage saveInvalidModels() const;
|
||||
CStatusMessage loadInvalidModels();
|
||||
static const QString &invalidModelFileAndPath();
|
||||
static bool hasInvalidModelFile();
|
||||
//! @}
|
||||
|
||||
//! Add as valid or invalid model (mutual exclusive)
|
||||
//! @{
|
||||
//! Add as valid or invalid model (mutual exclusive)
|
||||
static void addAsValidOrInvalidModel(const CAircraftModel &model, bool valid, CAircraftModelList &validModels, CAircraftModelList &invalidModels);
|
||||
static void addAsValidOrInvalidModels(const CAircraftModelList &models, bool valid, CAircraftModelList &validModels, CAircraftModelList &invalidModels);
|
||||
//! @}
|
||||
|
||||
@@ -125,11 +125,9 @@ namespace BlackMisc::Simulation
|
||||
//! Supported simulator
|
||||
bool supportsSimulator(const CSimulatorInfo &simulator) const { return m_simulator == simulator; }
|
||||
|
||||
//! Interface implementations
|
||||
//! @{
|
||||
// Interface implementations
|
||||
virtual void setModels(const CAircraftModelList &models) override;
|
||||
virtual int updateModels(const CAircraftModelList &models) override;
|
||||
//! @}
|
||||
|
||||
signals:
|
||||
//! Disk loading started
|
||||
|
||||
@@ -32,8 +32,8 @@ namespace BlackMisc::Simulation
|
||||
//! Singleton
|
||||
static CMultiAircraftModelLoaderProvider &multiModelLoaderInstance();
|
||||
|
||||
//! Simulator specific loaders
|
||||
//! @{
|
||||
//! Simulator specific loaders
|
||||
IAircraftModelLoader *modelLoaderFsx() const { return m_loaderFsx; }
|
||||
IAircraftModelLoader *modelLoaderP3D() const { return m_loaderP3D; }
|
||||
IAircraftModelLoader *modelLoaderXP() const { return m_loaderXP; }
|
||||
|
||||
@@ -62,8 +62,8 @@ namespace BlackMisc::Simulation
|
||||
class BLACKMISC_EXPORT CAutoPublishData
|
||||
{
|
||||
public:
|
||||
//! Insert values we might want to update in the DB
|
||||
//! @{
|
||||
//! Insert values we might want to update in the DB
|
||||
void insert(const QString &modelString, const PhysicalQuantities::CLength &cg);
|
||||
void insert(const QString &modelString, const CSimulatorInfo &simulator);
|
||||
//! @}
|
||||
@@ -80,8 +80,8 @@ namespace BlackMisc::Simulation
|
||||
//! Read from database JSON
|
||||
int fromDatabaseJson(const QString &jsonData, bool clear = true);
|
||||
|
||||
//! Write to file
|
||||
//! @{
|
||||
//! Write to file
|
||||
bool writeJsonToFile() const;
|
||||
bool writeJsonToFile(const QString &pathAndFile) const;
|
||||
//! @}
|
||||
|
||||
@@ -37,8 +37,8 @@ namespace BlackMisc
|
||||
//! Used categories
|
||||
void setCategories(const Aviation::CAircraftCategoryList &categories);
|
||||
|
||||
//! Specialized categories
|
||||
//! @{
|
||||
//! Specialized categories
|
||||
const Aviation::CAircraftCategoryList &gliderCategories() const { return m_gliders; }
|
||||
const Aviation::CAircraftCategoryList &militaryWingCategories() const { return m_militaryWingAircraft; }
|
||||
const Aviation::CAircraftCategoryList &militaryRotorCategories() const { return m_militaryRotorAircraft; }
|
||||
|
||||
@@ -295,8 +295,8 @@ namespace BlackMisc::Simulation::Data
|
||||
//! Emit cacheChanged() utility function (allows breakpoint)
|
||||
void emitCacheChanged(const CSimulatorInfo &simulator);
|
||||
|
||||
//! Cache synchronized flag
|
||||
//! @{
|
||||
//! Cache synchronized flag
|
||||
std::atomic_bool m_syncFsx { false };
|
||||
std::atomic_bool m_syncP3D { false };
|
||||
std::atomic_bool m_syncFS9 { false };
|
||||
@@ -454,8 +454,8 @@ namespace BlackMisc::Simulation::Data
|
||||
public IModelsForSimulatorUpdatable
|
||||
{
|
||||
public:
|
||||
//! Look like IMultiSimulatorModelCaches interface
|
||||
//! @{
|
||||
//! Look like IMultiSimulatorModelCaches interface
|
||||
CAircraftModelList getCachedModels(const CSimulatorInfo &simulator) const { return CCentralMultiSimulatorModelCachesProvider::modelCachesInstance().getCachedModels(simulator); }
|
||||
int getCachedModelsCount(const CSimulatorInfo &simulator) const { return CCentralMultiSimulatorModelCachesProvider::modelCachesInstance().getCachedModelsCount(simulator); }
|
||||
QString getCacheCountAndTimestamp(const CSimulatorInfo &simulator) const { return CCentralMultiSimulatorModelCachesProvider::modelCachesInstance().getCacheCountAndTimestamp(simulator); }
|
||||
@@ -507,8 +507,8 @@ namespace BlackMisc::Simulation::Data
|
||||
public IModelsForSimulatorUpdatable
|
||||
{
|
||||
public:
|
||||
//! Look like IMultiSimulatorModelCaches interface
|
||||
//! @{
|
||||
//! Look like IMultiSimulatorModelCaches interface
|
||||
CAircraftModelList getCachedModels(const CSimulatorInfo &simulator) const { return CCentralMultiSimulatorModelSetCachesProvider::modelCachesInstance().getCachedModels(simulator); }
|
||||
int getCachedModelsCount(const CSimulatorInfo &simulator) const { return CCentralMultiSimulatorModelSetCachesProvider::modelCachesInstance().getCachedModelsCount(simulator); }
|
||||
QString getCacheCountAndTimestamp(const CSimulatorInfo &simulator) const { return CCentralMultiSimulatorModelCachesProvider::modelCachesInstance().getCacheCountAndTimestamp(simulator); }
|
||||
|
||||
@@ -124,8 +124,8 @@ namespace BlackMisc::Simulation
|
||||
//! Object from JSON
|
||||
static CDistributor fromDatabaseJson(const QJsonObject &json, const QString &prefix = QString());
|
||||
|
||||
//! Hardcoded keys for standard models
|
||||
//! @{
|
||||
//! Hardcoded keys for standard models
|
||||
static const QString &standardFSX();
|
||||
static const QString &standardP3D();
|
||||
static const QString &standardFS9();
|
||||
|
||||
@@ -131,8 +131,8 @@ namespace BlackMisc::Simulation::FsCommon
|
||||
static const QString &airFileFilter();
|
||||
|
||||
private:
|
||||
//! Utility functions
|
||||
//! @{
|
||||
//! Utility functions
|
||||
static QSet<QString> findP3dConfigFiles(const QString &configFile, const QString &versionHint = "v5");
|
||||
//! @}
|
||||
|
||||
|
||||
@@ -170,8 +170,8 @@ namespace BlackMisc
|
||||
//! Reset values
|
||||
void reset();
|
||||
|
||||
//! Implicit conversion
|
||||
//! @{
|
||||
//! Implicit conversion
|
||||
operator const Aviation::CAircraftSituation &() const { return m_interpolatedSituation; }
|
||||
operator const Aviation::CAircraftParts &() const { return m_interpolatedParts; }
|
||||
//! @}
|
||||
@@ -340,8 +340,8 @@ namespace BlackMisc
|
||||
//! Return NULL parts and log
|
||||
const BlackMisc::Aviation::CAircraftParts &logAndReturnNullParts(const QString &info, bool log);
|
||||
|
||||
//! Derived class
|
||||
//! @{
|
||||
//! Derived class
|
||||
Derived *derived() { return static_cast<Derived *>(this); }
|
||||
const Derived *derived() const { return static_cast<const Derived *>(this); }
|
||||
//! @}
|
||||
|
||||
@@ -42,8 +42,8 @@ namespace BlackMisc
|
||||
class BLACKMISC_EXPORT CInterpolant : public IInterpolant
|
||||
{
|
||||
public:
|
||||
//! Constructor
|
||||
//! @{
|
||||
//! Constructor
|
||||
CInterpolant() {}
|
||||
CInterpolant(const Aviation::CAircraftSituation &oldSituation);
|
||||
CInterpolant(const Aviation::CAircraftSituation &oldSituation, const CInterpolatorPbh &pbh);
|
||||
|
||||
@@ -23,15 +23,15 @@ namespace BlackMisc::Simulation
|
||||
class BLACKMISC_EXPORT CInterpolatorPbh
|
||||
{
|
||||
public:
|
||||
//! Constructor
|
||||
//! @{
|
||||
//! Constructor
|
||||
CInterpolatorPbh() {}
|
||||
CInterpolatorPbh(const Aviation::CAircraftSituation &older, const Aviation::CAircraftSituation &newer) : m_oldSituation(older), m_newSituation(newer) {}
|
||||
CInterpolatorPbh(double time, const Aviation::CAircraftSituation &older, const Aviation::CAircraftSituation &newer) : m_simulationTimeFraction(time), m_oldSituation(older), m_newSituation(newer) {}
|
||||
//! @}
|
||||
|
||||
//! Getter
|
||||
//! @{
|
||||
//! Getter
|
||||
Aviation::CHeading getHeading() const;
|
||||
PhysicalQuantities::CAngle getPitch() const;
|
||||
PhysicalQuantities::CAngle getBank() const;
|
||||
|
||||
@@ -43,12 +43,10 @@ namespace BlackMisc::Simulation
|
||||
static const PosArray &zeroPosArray();
|
||||
|
||||
//! 3 coordinates for spline interpolation
|
||||
//! @{
|
||||
std::array<double, 3> x, y, z, a, gnd, t, dx, dy, dz, da, dgnd;
|
||||
|
||||
//! Array size
|
||||
int size() const { return static_cast<int>(x.size()); }
|
||||
//! @}
|
||||
};
|
||||
|
||||
//! Cubic function that performs the actual interpolation
|
||||
|
||||
@@ -27,8 +27,8 @@ namespace BlackMisc::Simulation
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
//! MSNetworkValues properties
|
||||
//! @{
|
||||
//! MSNetworkValues properties
|
||||
Q_PROPERTY(QString callsign READ getCallsign WRITE setCallsign NOTIFY callsignChanged)
|
||||
Q_PROPERTY(QString callsignAsSet READ getCallsignAsSet)
|
||||
Q_PROPERTY(QString flightNumber READ getFlightNumber)
|
||||
@@ -93,16 +93,16 @@ namespace BlackMisc::Simulation
|
||||
//! Ctor
|
||||
MSInOutValues(const MSInOutValues &sv);
|
||||
|
||||
//! Callsign values
|
||||
//! @{
|
||||
//! Callsign values
|
||||
const QString &getCallsign() const { return m_callsign; }
|
||||
const QString &getCallsignAsSet() const { return m_callsignAsSet; }
|
||||
const QString &getFlightNumber() const { return m_flightNumber; }
|
||||
void setCallsign(const QString &callsign);
|
||||
//! @}
|
||||
|
||||
//! Values found in DB?
|
||||
//! @{
|
||||
//! Values found in DB?
|
||||
bool isFoundDbAircraftIcao() const { return m_dbAircraftIcaoId >= 0; }
|
||||
bool isFoundDbAirlineIcao() const { return m_dbAirlineIcaoId >= 0; }
|
||||
bool isFoundDbLivery() const { return m_dbLiveryId >= 0; }
|
||||
@@ -117,8 +117,8 @@ namespace BlackMisc::Simulation
|
||||
void setDbModelId(int id);
|
||||
//! @}
|
||||
|
||||
//! Livery, airline, aircraft, model string
|
||||
//! @{
|
||||
//! Livery, airline, aircraft, model string
|
||||
const QString &getAircraftIcao() const { return m_aircraftIcao; }
|
||||
const QString &getAircraftFamily() const { return m_aircraftFamily; }
|
||||
const QString &getAirlineIcao() const { return m_airlineIcao; }
|
||||
@@ -137,20 +137,20 @@ namespace BlackMisc::Simulation
|
||||
bool hasAircraftFamily() const { return !m_aircraftFamily.isEmpty(); }
|
||||
//! @}
|
||||
|
||||
//! Log. message
|
||||
//! @{
|
||||
//! Log. message
|
||||
const QString &getLogMessage() const { return m_logMessage; }
|
||||
void setLogMessage(const QString &msg);
|
||||
//! @}
|
||||
|
||||
//! Modified flag
|
||||
//! @{
|
||||
//! Modified flag
|
||||
bool isModified() const { return m_modified; }
|
||||
void setModified(bool modified);
|
||||
//! @}
|
||||
|
||||
//! Request re-run
|
||||
//! @{
|
||||
//! Request re-run
|
||||
bool isRerun() const { return m_rerun; }
|
||||
void setRerun(bool rerun);
|
||||
//! @}
|
||||
@@ -158,8 +158,8 @@ namespace BlackMisc::Simulation
|
||||
//! Changed values such as modified values
|
||||
void evaluateChanges(const BlackMisc::Aviation::CAircraftIcaoCode &aircraft, const BlackMisc::Aviation::CAirlineIcaoCode &airline);
|
||||
|
||||
//! Changed values
|
||||
//! @{
|
||||
//! Changed values
|
||||
bool hasModifiedAircraftIcaoDesignator() const { return m_modifiedAircraftDesignator; }
|
||||
bool hasModifiedAirlineIcaoDesignator() const { return m_modifiedAirlineDesignator; }
|
||||
bool hasModifiedAircraftFamily() const { return m_modifiedAircraftFamily; }
|
||||
@@ -178,8 +178,8 @@ namespace BlackMisc::Simulation
|
||||
//! Callsign changed
|
||||
void callsignChanged();
|
||||
|
||||
//! Livery, airline, aircraft, or model changed
|
||||
//! @{
|
||||
//! Livery, airline, aircraft, or model changed
|
||||
void aircraftIcaoChanged();
|
||||
void airlineIcaoChanged();
|
||||
void virtualAirlineIcaoChanged();
|
||||
@@ -188,8 +188,8 @@ namespace BlackMisc::Simulation
|
||||
void combinedTypeChanged();
|
||||
//! @}
|
||||
|
||||
//! DB id changed
|
||||
//! @{
|
||||
//! DB id changed
|
||||
void dbAircraftIcaoIdChanged();
|
||||
void dbAirlineIcaoIdChanged();
|
||||
void dbLiveryIdChanged();
|
||||
@@ -233,8 +233,8 @@ namespace BlackMisc::Simulation
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
//! MSModelSet properties
|
||||
//! @{
|
||||
//! MSModelSet properties
|
||||
Q_PROPERTY(QString simulator READ getSimulator WRITE setSimulator NOTIFY simulatorChanged)
|
||||
Q_PROPERTY(bool available READ isAvailable WRITE setAvailable NOTIFY availabilityChanged)
|
||||
Q_PROPERTY(int inputAircraftAndAirlineCount READ getInputAircraftAndAirlineCount WRITE setInputAircraftAndAirlineCount NOTIFY inputAircraftAndAirlineCountChanged)
|
||||
@@ -257,20 +257,20 @@ namespace BlackMisc::Simulation
|
||||
//! Set callsign
|
||||
void setSimulator(const QString &simulator);
|
||||
|
||||
//! Availablity flag
|
||||
//! @{
|
||||
//! Availablity flag
|
||||
bool isAvailable() const { return m_available; }
|
||||
void setAvailable(bool available);
|
||||
//! @}
|
||||
|
||||
//! Input aircraft/airline available flag
|
||||
//! @{
|
||||
//! Input aircraft/airline available flag
|
||||
int getInputAircraftAndAirlineCount() const { return m_inputAircraftAndAirlineCount; }
|
||||
void setInputAircraftAndAirlineCount(int count);
|
||||
//! @}
|
||||
|
||||
//! Model set functions as properties
|
||||
//! @{
|
||||
//! Model set functions as properties
|
||||
int getModelSetSize() const { return m_modelSet.size(); }
|
||||
int countDifferentAirlines() const { return m_modelSet.countDifferentAirlines(); }
|
||||
int countVtolAircraft() const { return m_modelSet.countVtolAircraft(); }
|
||||
@@ -280,8 +280,8 @@ namespace BlackMisc::Simulation
|
||||
int countModelsWithAirlineLivery() const { return m_modelSet.countModelsWithAirlineLivery(); }
|
||||
//! @}
|
||||
|
||||
//! Invokable model set functions as properties
|
||||
//! @{
|
||||
//! Invokable model set functions as properties
|
||||
Q_INVOKABLE bool containsModelString(const QString &modelString) const { return m_modelSet.containsModelString(modelString, Qt::CaseInsensitive); }
|
||||
Q_INVOKABLE bool containsDbKey(int dbKey) const { return m_modelSet.containsDbKey(dbKey); }
|
||||
Q_INVOKABLE bool containsCombinedType(const QString &ct) const { return m_modelSet.containsCombinedType(ct); }
|
||||
|
||||
@@ -204,9 +204,9 @@ namespace BlackMisc
|
||||
//! \threadsafe
|
||||
virtual bool updateCGAndModelString(const Aviation::CCallsign &callsign, const PhysicalQuantities::CLength &cg, const QString &modelString) = 0;
|
||||
|
||||
//! @{
|
||||
//! CG values from DB
|
||||
//! \threadsafe
|
||||
//! @{
|
||||
virtual PhysicalQuantities::CLength getCGFromDB(const Aviation::CCallsign &callsign) const = 0;
|
||||
virtual PhysicalQuantities::CLength getCGFromDB(const QString &modelString) const = 0;
|
||||
virtual void rememberCGFromDB(const PhysicalQuantities::CLength &cgFromDB, const Aviation::CCallsign &callsign) = 0;
|
||||
@@ -302,8 +302,7 @@ namespace BlackMisc::Simulation
|
||||
//! Constructor
|
||||
CRemoteAircraftProvider(QObject *parent);
|
||||
|
||||
//! \ingroup remoteaircraftprovider
|
||||
//! @{
|
||||
// remoteaircraftprovider
|
||||
virtual CSimulatedAircraftList getAircraftInRange() const override;
|
||||
virtual Aviation::CCallsignSet getAircraftInRangeCallsigns() const override;
|
||||
virtual CSimulatedAircraft getAircraftInRangeForCallsign(const Aviation::CCallsign &callsign) const override;
|
||||
@@ -356,20 +355,15 @@ namespace BlackMisc::Simulation
|
||||
std::function<void(const Aviation::CCallsign &)> removedAircraftSlot,
|
||||
std::function<void(const CAirspaceAircraftSnapshot &)> aircraftSnapshotSlot
|
||||
) override;
|
||||
//! @}
|
||||
|
||||
//! \ingroup remoteaircraftprovider
|
||||
//! \ingroup reverselookup
|
||||
//! @{
|
||||
virtual void enableReverseLookupMessages(ReverseLookupLogging enable) override;
|
||||
virtual ReverseLookupLogging isReverseLookupMessagesEnabled() const override;
|
||||
virtual BlackMisc::CStatusMessageList getReverseLookupMessages(const BlackMisc::Aviation::CCallsign &callsign) const override;
|
||||
//! @}
|
||||
|
||||
//! @{
|
||||
//! Reverse lookup messages
|
||||
//! \threadsafe
|
||||
//! \ingroup reverselookup
|
||||
//! @{
|
||||
void addReverseLookupMessages(const Aviation::CCallsign &callsign, const CStatusMessageList &messages);
|
||||
void addReverseLookupMessage(const Aviation::CCallsign &callsign, const CStatusMessage &message);
|
||||
void addReverseLookupMessage(
|
||||
@@ -452,10 +446,10 @@ namespace BlackMisc::Simulation
|
||||
//! \threadsafe
|
||||
virtual Aviation::CAircraftSituation storeAircraftSituation(const Aviation::CAircraftSituation &situation, bool allowTestAltitudeOffset = true);
|
||||
|
||||
//! @{
|
||||
//! Store an aircraft part
|
||||
//! \remark latest parts are kept first
|
||||
//! \threadsafe
|
||||
//! @{
|
||||
void storeAircraftParts(const Aviation::CCallsign &callsign, const Aviation::CAircraftParts &parts, bool removeOutdated);
|
||||
void storeAircraftParts(const Aviation::CCallsign &callsign, const QJsonObject &jsonObject, qint64 currentOffsetMs);
|
||||
//! @}
|
||||
|
||||
@@ -33,17 +33,17 @@ namespace BlackMisc::Simulation
|
||||
//! Constructor
|
||||
CRemoteAircraftProviderDummy(QObject *parent = nullptr);
|
||||
|
||||
//! For testing, add new situation and fire signals
|
||||
//! @{
|
||||
//! For testing, add new situation and fire signals
|
||||
void insertNewSituation(const Aviation::CAircraftSituation &situation);
|
||||
void insertNewSituations(const Aviation::CAircraftSituationList &situations);
|
||||
void insertNewAircraftParts(const Aviation::CCallsign &callsign, const Aviation::CAircraftParts &parts, bool removeOutdatedParts);
|
||||
void insertNewAircraftParts(const Aviation::CCallsign &callsign, const Aviation::CAircraftPartsList &partsList, bool removeOutdatedParts);
|
||||
//! @}
|
||||
|
||||
//! @{
|
||||
//! Members not implenented or fully implenented by CRemoteAircraftProvider
|
||||
//! \ingroup remoteaircraftprovider
|
||||
//! @{
|
||||
virtual QObject *asQObject() override { return this; }
|
||||
virtual CAirspaceAircraftSnapshot getLatestAirspaceAircraftSnapshot() const override;
|
||||
//! @}
|
||||
|
||||
@@ -503,8 +503,8 @@ namespace BlackMisc::Simulation::Settings
|
||||
CSetting<Settings::TSimulatorXP> m_simSettingsXP { this, &CMultiSimulatorSettings::onXPSettingsChanged }; //!< XP settings
|
||||
CSetting<Settings::TSimulatorFG> m_simSettingsFG { this, &CMultiSimulatorSettings::onFGSettingsChanged }; //!< FG settings
|
||||
|
||||
//! Settings changed, this will only detect if settings are changed elsewhere
|
||||
//! @{
|
||||
//! Settings changed, this will only detect if settings are changed elsewhere
|
||||
void onFsxSettingsChanged();
|
||||
void onFs9SettingsChanged();
|
||||
void onP3DSettingsChanged();
|
||||
|
||||
@@ -163,8 +163,8 @@ namespace BlackMisc::Simulation::Settings
|
||||
}
|
||||
|
||||
protected:
|
||||
//! The JSON members
|
||||
//! @{
|
||||
//! The JSON members
|
||||
static constexpr char JsonDBusServerAddress[] = "dbusserveradress";
|
||||
static constexpr char JsonDrawingLabels[] = "drawinglabels";
|
||||
static constexpr char JsonLabelColor[] = "labelcolor";
|
||||
|
||||
@@ -161,9 +161,9 @@ namespace BlackMisc::Simulation
|
||||
//! Ctor
|
||||
ISimulationEnvironmentProvider(const CSimulatorPluginInfo &pluginInfo, const Settings::CSimulatorSettings &settings, bool supportElevation, bool supportCG);
|
||||
|
||||
//! @{
|
||||
//! Provider enabled
|
||||
//! \threadsafe
|
||||
//! @{
|
||||
bool isCgProviderEnabled() const;
|
||||
bool isElevationProviderEnabled() const;
|
||||
void setCgProviderEnabled(bool enabled);
|
||||
|
||||
@@ -203,8 +203,8 @@ namespace BlackMisc::Simulation
|
||||
//! From database JSON
|
||||
static CSimulatorInfo fromDatabaseJson(const QJsonObject &json, const QString &prefix);
|
||||
|
||||
//! Const simulator info objects
|
||||
//! @{
|
||||
//! Const simulator info objects
|
||||
static const CSimulatorInfo &fg() { static const CSimulatorInfo s(FG); return s; }
|
||||
static const CSimulatorInfo &fsx() { static const CSimulatorInfo s(FSX); return s; }
|
||||
static const CSimulatorInfo &p3d() { static const CSimulatorInfo s(P3D); return s; }
|
||||
|
||||
@@ -249,8 +249,8 @@ namespace BlackMisc::Simulation::XPlane::QtFreeUtils
|
||||
template <typename I>
|
||||
struct Utf8Iterator
|
||||
{
|
||||
//! STL compatibility
|
||||
//! @{
|
||||
//! STL compatibility
|
||||
using value_type = typename std::iterator_traits<I>::value_type;
|
||||
using difference_type = typename std::iterator_traits<I>::difference_type;
|
||||
using reference = typename std::iterator_traits<I>::reference;
|
||||
@@ -264,8 +264,8 @@ namespace BlackMisc::Simulation::XPlane::QtFreeUtils
|
||||
//! Constructor
|
||||
Utf8Iterator(I base, I end) : base(base), end(end) {}
|
||||
|
||||
//! Equality
|
||||
//! @{
|
||||
//! Equality
|
||||
friend bool operator ==(Utf8Iterator a, Utf8Iterator b) { return a.base == b.base; }
|
||||
friend bool operator !=(Utf8Iterator a, Utf8Iterator b) { return a.base != b.base; }
|
||||
friend bool operator ==(Utf8Iterator a, I b) { return a.base == b; }
|
||||
|
||||
Reference in New Issue
Block a user