mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-04-02 15:15:50 +08:00
* this implementation is used by airspace monitor * also used by dummy provider (advantage, unit tests test the real provider) * some functions adjusted
53 lines
2.2 KiB
C++
53 lines
2.2 KiB
C++
/* Copyright (C) 2015
|
|
* swift project Community / Contributors
|
|
*
|
|
* This file is part of swift project. It is subject to the license terms in the LICENSE file found in the top-level
|
|
* directory of this distribution and at http://www.swift-project.org/license.html. No part of swift project,
|
|
* including this file, may be copied, modified, propagated, or distributed except according to the terms
|
|
* contained in the LICENSE file.
|
|
*/
|
|
|
|
//! \file
|
|
|
|
#ifndef BLACKMISC_SIMULATION_REMOTEAIRCRAFTPROVIDERDUMMY_H
|
|
#define BLACKMISC_SIMULATION_REMOTEAIRCRAFTPROVIDERDUMMY_H
|
|
|
|
#include "blackmisc/simulation/airspaceaircraftsnapshot.h"
|
|
#include "blackmisc/simulation/remoteaircraftprovider.h"
|
|
#include "blackmisc/simulation/simulatedaircraftlist.h"
|
|
#include "blackmisc/aviation/aircraftpartslist.h"
|
|
#include "blackmisc/aviation/aircraftsituationlist.h"
|
|
#include "blackmisc/aviation/callsignset.h"
|
|
#include "blackmisc/blackmiscexport.h"
|
|
|
|
namespace BlackMisc
|
|
{
|
|
namespace Simulation
|
|
{
|
|
//! Dummy implementation for testing purpose
|
|
class BLACKMISC_EXPORT CRemoteAircraftProviderDummy : public CRemoteAircraftProvider
|
|
{
|
|
public:
|
|
//! Constructor
|
|
CRemoteAircraftProviderDummy(QObject *parent = nullptr);
|
|
|
|
//! 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;
|
|
//! @}
|
|
};
|
|
} // namespace
|
|
} // namespace
|
|
|
|
#endif // guard
|