6 #ifndef SWIFT_CORE_CONTEXT_CONTEXTNETWORK_IMPL_H
7 #define SWIFT_CORE_CONTEXT_CONTEXTNETWORK_IMPL_H
12 #include <QMetaObject>
59 class CAircraftSituation;
66 class CAirspaceMonitor;
113 bool rendered)
override;
115 bool rendered)
override;
117 bool enabled)
override;
121 bool *setForOnGroundPosition)
override;
122 virtual void updateMarkAllAsNotRendered()
override;
129 const QString &modelString)
override;
131 getLatestAirspaceAircraftSnapshot()
const override;
135 int minValues = 1,
int sufficientValues = 2)
const override;
138 virtual QList<QMetaObject::Connection> connectRemoteAircraftProviderSignals(
150 virtual void clearClients()
override;
157 bool skipEqualValues =
true)
override;
163 bool supportGndFlag)
override;
167 virtual QMetaObject::Connection
191 bool enabledForRendering)
override;
205 bool enableFastPositonUpdates)
override;
209 bool supportGndFlag)
override;
212 virtual void enableReverseLookupMessages(swift::misc::simulation::ReverseLookupLogging enable)
override;
217 bool enabledForRendering)
override;
220 virtual int reInitializeAllAircraft()
override;
233 const QString &modelString)
override;
242 virtual int getAircraftInRangeCount()
const override;
263 virtual swift::misc::simulation::ReverseLookupLogging isReverseLookupMessagesEnabled()
const override;
274 virtual int getRemoteAircraftSupportingPartsCount()
const override;
277 virtual bool isAircraftPartsHistoryEnabled()
const override;
284 virtual void enableAircraftPartsHistory(
bool enabled)
override;
287 virtual int aircraftSituationsAdded()
const override;
290 virtual int aircraftPartsAdded()
const override;
299 virtual QString getNetworkStatistics(
bool reset,
const QString &separator)
override;
302 virtual bool setNetworkStatisticsEnable(
bool enabled)
override;
310 virtual QStringList getNetworkPresetValues()
const override;
328 bool isPendingConnection()
const;
352 {
".altos callsign|? offsetvalue",
"set altitude offset value (testing), ?=all" });
354 {
".addtimeos offsetvalue",
"add (delta) time offset (testing), e.g. 50ms" });
356 {
".watchdog on|off",
"enable/disable network watchdog (testing)" });
367 getAtcStationsOnline(
bool recalculateDistance)
const override;
386 bool sendLivery,
const QString &extraModelString,
bool sendModelString,
400 virtual bool isConnected()
const override;
431 virtual void requestAircraftDataUpdates()
override;
434 virtual void requestAtisUpdates()
override;
443 virtual void testCreateDummyOnlineAtcStations(
int number)
override;
448 bool incremental)
override;
471 QTimer *m_requestAircraftDataTimer =
473 QTimer *m_requestAtisTimer =
nullptr;
474 QTimer *m_staggeredMatchingTimer =
nullptr;
475 int m_simulatorConnected = 0;
481 std::chrono::milliseconds(1000), 4 };
484 std::chrono::milliseconds(1000), 4 };
486 QQueue<swift::misc::simulation::CSimulatedAircraft> m_readyForModelMatching;
515 void emitReadyForMatching();
525 void xCtxSimulatorRenderRestrictionsChanged(
526 bool restricted,
bool enabled,
int maxAircraft,
531 void xCtxSimulatorStatusChanged(
int status);
534 bool canUseFsd()
const;
537 bool canUseAirspaceMonitor()
const;
Keeps track of other entities in the airspace: aircraft, ATC stations, etc. Central instance of data ...
ContextMode
How to handle a given context.
The class providing facades (the contexts) for all DBus relevant operations.
void gracefulShutdown()
Clean up (will be connected to signal QCoreApplication::aboutToQuit)
bool parseCommandLine(const QString &commandLine, const swift::misc::CIdentifier &originator)
Parse command line in all contexts.
Network context implementation.
fsd::CFSDClient * fsdClient() const
Network library.
CAirspaceMonitor * airspace() const
Airspace.
static void registerHelp()
Register help.
void changedAircraftInRange()
Aircraft list has been changed.
void changedAtcStationsOnline()
ATC station (online) list has been changed.
std::function< void(const swift::misc::network::CRawFsdMessage &)> RawFsdMessageReceivedSlot
Raw FSD message receiver functor.
void changedAtcStationsOnlineDigest()
Digest signal changedAtcStationsOnline()
void changedAircraftInRangeDigest()
Digest signal changedAircraftInRange()
FSD client Todo: Send (interim) data updates automatically Todo Check ':' in FSD messages....
Receive 1..n signals, collect them over time, and resend afer n milliseconds.
Value object encapsulating information identifying a component of a modular distributed swift process...
Specialized value object compliant map for variants, based on indexes.
static void registerCommand(const CommandHtmlHelp &command)
Register a command.
static bool registered(const QString &helpContext)
Help already registered.
Streamable status message, e.g.
Status messages, e.g. from Core -> GUI.
Value object encapsulating information of aircraft's parts.
Value object encapsulating a list of aircraft parts.
Value object encapsulating a list of aircraft parts.
Value object encapsulating information of an aircraft's situation.
GndElevationInfo
Where did we get elevation from?
List of aircraft situations.
Value object encapsulating information of airport ICAO data.
Value object encapsulating information about an ATC station.
Value object for a list of ATC stations.
Value object encapsulating information of a callsign.
Value object for a set of callsigns.
Value object for a flight plan.
Plane of same elevation, can be a single point or larger area (e.g. airport)
Value object encapsulating a list of voice rooms.
Value object encapsulating information about a connection status.
Value object encapsulating information about login mode.
Value object encapsulating information of a server.
Value object encapsulating a list of servers.
Value object encapsulating information of a text message.
Value object encapsulating a list of text messages.
Value object encapsulating information of a user.
Value object encapsulating a list of voice rooms.
Direct in memory access to client (network client) data.
Physical unit length (length)
static const CLength & null()
NULL PQ.
Aircraft model (used by another pilot, my models on disk)
Current situation in the skies analyzed.
Comprehensive information of an aircraft.
Value object encapsulating a list of aircraft.
Simple hardcoded info about the corresponding simulator.
Direct thread safe in memory access to remote aircraft.
Direct in memory access to elevation data.
#define SWIFT_CORE_CONTEXTNETWORK_INTERFACENAME
DBus interface for context.
Backend services of the swift project, like dealing with the network or the simulators.
Free functions in swift::misc.
Milliseconds minimum/maximum/mean.
#define SWIFT_CORE_EXPORT
Export a class or function from the library.