mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-04-27 02:55:44 +08:00
Comments / order of methods
* Reordered methods a bit * Fixed Doxygen * Removed unwanted comments
This commit is contained in:
@@ -122,9 +122,7 @@ namespace BlackCore
|
|||||||
virtual bool isConnected() const;
|
virtual bool isConnected() const;
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
* \brief Set own aircraft
|
* \copydoc IContextNetwork::setOwnAircraft()
|
||||||
* \param aircraft my own aircraft
|
|
||||||
* \return
|
|
||||||
*/
|
*/
|
||||||
virtual BlackMisc::CStatusMessageList setOwnAircraft(const BlackMisc::Aviation::CAircraft &aircraft);
|
virtual BlackMisc::CStatusMessageList setOwnAircraft(const BlackMisc::Aviation::CAircraft &aircraft);
|
||||||
|
|
||||||
@@ -172,12 +170,12 @@ namespace BlackCore
|
|||||||
virtual BlackMisc::Voice::CVoiceRoomList getSelectedVoiceRooms() const;
|
virtual BlackMisc::Voice::CVoiceRoomList getSelectedVoiceRooms() const;
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
* \brief Get all users
|
* \copydoc IContextNetwork::getUsers()
|
||||||
*/
|
*/
|
||||||
virtual BlackMisc::Network::CUserList getUsers() const;
|
virtual BlackMisc::Network::CUserList getUsers() const;
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
* \brief All users with callsign, e.g. for voice room resolution
|
* \copydoc IContextNetwork::getUsersForCallsigns
|
||||||
*/
|
*/
|
||||||
virtual BlackMisc::Network::CUserList getUsersForCallsigns(const BlackMisc::Aviation::CCallsignList &callsigns) const;
|
virtual BlackMisc::Network::CUserList getUsersForCallsigns(const BlackMisc::Aviation::CCallsignList &callsigns) const;
|
||||||
|
|
||||||
|
|||||||
@@ -44,126 +44,6 @@ namespace BlackCore
|
|||||||
"textMessagesReceived", this, SIGNAL(textMessagesReceived(BlackMisc::Network::CTextMessageList)));
|
"textMessagesReceived", this, SIGNAL(textMessagesReceived(BlackMisc::Network::CTextMessageList)));
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
|
||||||
* Relay to DBus
|
|
||||||
*/
|
|
||||||
void IContextNetwork::readAtcBookingsFromSource() const
|
|
||||||
{
|
|
||||||
this->m_dBusInterface->callDBus(QLatin1Literal("readAtcBookingsFromSource"));
|
|
||||||
}
|
|
||||||
|
|
||||||
/*
|
|
||||||
* Relay to DBus
|
|
||||||
*/
|
|
||||||
const BlackMisc::Aviation::CAtcStationList IContextNetwork::getAtcStationsOnline() const
|
|
||||||
{
|
|
||||||
return this->m_dBusInterface->callDBusRet<BlackMisc::Aviation::CAtcStationList>(QLatin1Literal("getAtcStationsOnline"));
|
|
||||||
}
|
|
||||||
|
|
||||||
/*
|
|
||||||
* Relay to DBus
|
|
||||||
*/
|
|
||||||
const BlackMisc::Aviation::CAtcStationList IContextNetwork::getAtcStationsBooked() const
|
|
||||||
{
|
|
||||||
return this->m_dBusInterface->callDBusRet<BlackMisc::Aviation::CAtcStationList>(QLatin1Literal("getAtcStationsBooked"));
|
|
||||||
}
|
|
||||||
|
|
||||||
/*
|
|
||||||
* Relay to DBus
|
|
||||||
*/
|
|
||||||
const BlackMisc::Aviation::CAircraftList IContextNetwork::getAircraftsInRange() const
|
|
||||||
{
|
|
||||||
return this->m_dBusInterface->callDBusRet<BlackMisc::Aviation::CAircraftList>(QLatin1Literal("getAircraftsInRange"));
|
|
||||||
}
|
|
||||||
|
|
||||||
/*
|
|
||||||
* Relay to DBus
|
|
||||||
*/
|
|
||||||
BlackMisc::Aviation::CAircraft IContextNetwork::getOwnAircraft() const
|
|
||||||
{
|
|
||||||
return this->m_dBusInterface->callDBusRet<BlackMisc::Aviation::CAircraft>(QLatin1Literal("getOwnAircraft"));
|
|
||||||
}
|
|
||||||
|
|
||||||
/*
|
|
||||||
* Relay to DBus
|
|
||||||
*/
|
|
||||||
BlackMisc::CStatusMessageList IContextNetwork::connectToNetwork()
|
|
||||||
{
|
|
||||||
return this->m_dBusInterface->callDBusRet<BlackMisc::CStatusMessageList>(QLatin1Literal("connectToNetwork"));
|
|
||||||
}
|
|
||||||
|
|
||||||
/*
|
|
||||||
* Relay to DBus
|
|
||||||
*/
|
|
||||||
BlackMisc::CStatusMessageList IContextNetwork::disconnectFromNetwork()
|
|
||||||
{
|
|
||||||
return this->m_dBusInterface->callDBusRet<BlackMisc::CStatusMessageList>(QLatin1Literal("disconnectFromNetwork"));
|
|
||||||
}
|
|
||||||
|
|
||||||
/*
|
|
||||||
* Relay to DBus
|
|
||||||
*/
|
|
||||||
bool IContextNetwork::isConnected() const
|
|
||||||
{
|
|
||||||
return this->m_dBusInterface->callDBusRet<bool>(QLatin1Literal("isConnected"));
|
|
||||||
}
|
|
||||||
|
|
||||||
/*
|
|
||||||
* Relay to DBus
|
|
||||||
*/
|
|
||||||
BlackMisc::CStatusMessageList IContextNetwork::setOwnAircraft(const BlackMisc::Aviation::CAircraft &aircraft)
|
|
||||||
{
|
|
||||||
return this->m_dBusInterface->callDBusRet<BlackMisc::CStatusMessageList>(QLatin1Literal("setOwnAircraft"), aircraft);
|
|
||||||
}
|
|
||||||
|
|
||||||
/*
|
|
||||||
* Relay to DBus
|
|
||||||
*/
|
|
||||||
void IContextNetwork::updateOwnPosition(const BlackMisc::Geo::CCoordinateGeodetic &position, const BlackMisc::Aviation::CAltitude &altitude)
|
|
||||||
{
|
|
||||||
this->m_dBusInterface->callDBus(QLatin1Literal("updateOwnPosition"), position, altitude);
|
|
||||||
}
|
|
||||||
|
|
||||||
/*
|
|
||||||
* Relay to DBus
|
|
||||||
*/
|
|
||||||
void IContextNetwork::updateOwnSituation(const BlackMisc::Aviation::CAircraftSituation &situation)
|
|
||||||
{
|
|
||||||
this->m_dBusInterface->callDBus(QLatin1Literal("updateOwnSituation"), situation);
|
|
||||||
}
|
|
||||||
|
|
||||||
/*
|
|
||||||
* Relay to DBus
|
|
||||||
*/
|
|
||||||
void IContextNetwork::updateOwnCockpit(const BlackMisc::Aviation::CComSystem &com1, const BlackMisc::Aviation::CComSystem &com2, const BlackMisc::Aviation::CTransponder &transponder)
|
|
||||||
{
|
|
||||||
this->m_dBusInterface->callDBus(QLatin1Literal("updateOwnCockpit"), com1, com2, transponder);
|
|
||||||
}
|
|
||||||
|
|
||||||
/*
|
|
||||||
* Relay to DBus
|
|
||||||
*/
|
|
||||||
void IContextNetwork::sendTextMessages(const BlackMisc::Network::CTextMessageList &textMessages)
|
|
||||||
{
|
|
||||||
this->m_dBusInterface->callDBus(QLatin1Literal("sendTextMessages"), textMessages);
|
|
||||||
}
|
|
||||||
|
|
||||||
/*
|
|
||||||
* Relay to DBus
|
|
||||||
*/
|
|
||||||
BlackMisc::Aviation::CInformationMessage IContextNetwork::getMetar(const QString &airportIcaoCode)
|
|
||||||
{
|
|
||||||
return this->m_dBusInterface->callDBusRet<BlackMisc::Aviation::CInformationMessage>(QLatin1Literal("getMetar"), airportIcaoCode);
|
|
||||||
}
|
|
||||||
|
|
||||||
/*
|
|
||||||
* Relay to DBus
|
|
||||||
*/
|
|
||||||
BlackMisc::Voice::CVoiceRoomList IContextNetwork::getSelectedVoiceRooms() const
|
|
||||||
{
|
|
||||||
return this->m_dBusInterface->callDBusRet<BlackMisc::Voice::CVoiceRoomList>(QLatin1Literal("getSelectedVoiceRooms"));
|
|
||||||
}
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Logging
|
* Logging
|
||||||
*/
|
*/
|
||||||
@@ -181,4 +61,89 @@ namespace BlackCore
|
|||||||
qDebug() << " LOG: " << method << m1 << m2 << m3 << m4;
|
qDebug() << " LOG: " << method << m1 << m2 << m3 << m4;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void IContextNetwork::readAtcBookingsFromSource() const
|
||||||
|
{
|
||||||
|
this->m_dBusInterface->callDBus(QLatin1Literal("readAtcBookingsFromSource"));
|
||||||
|
}
|
||||||
|
|
||||||
|
const BlackMisc::Aviation::CAtcStationList IContextNetwork::getAtcStationsOnline() const
|
||||||
|
{
|
||||||
|
return this->m_dBusInterface->callDBusRet<BlackMisc::Aviation::CAtcStationList>(QLatin1Literal("getAtcStationsOnline"));
|
||||||
|
}
|
||||||
|
|
||||||
|
const BlackMisc::Aviation::CAtcStationList IContextNetwork::getAtcStationsBooked() const
|
||||||
|
{
|
||||||
|
return this->m_dBusInterface->callDBusRet<BlackMisc::Aviation::CAtcStationList>(QLatin1Literal("getAtcStationsBooked"));
|
||||||
|
}
|
||||||
|
|
||||||
|
const BlackMisc::Aviation::CAircraftList IContextNetwork::getAircraftsInRange() const
|
||||||
|
{
|
||||||
|
return this->m_dBusInterface->callDBusRet<BlackMisc::Aviation::CAircraftList>(QLatin1Literal("getAircraftsInRange"));
|
||||||
|
}
|
||||||
|
|
||||||
|
BlackMisc::Network::CUserList IContextNetwork::getUsers() const
|
||||||
|
{
|
||||||
|
return this->m_dBusInterface->callDBusRet<BlackMisc::Network::CUserList>(QLatin1Literal("getUsers"));
|
||||||
|
}
|
||||||
|
|
||||||
|
BlackMisc::Network::CUserList IContextNetwork::getUsersForCallsigns(const BlackMisc::Aviation::CCallsignList &callsigns) const
|
||||||
|
{
|
||||||
|
return this->m_dBusInterface->callDBusRet<BlackMisc::Network::CUserList>(QLatin1Literal("getUsersForCallsigns"), callsigns);
|
||||||
|
}
|
||||||
|
|
||||||
|
BlackMisc::Voice::CVoiceRoomList IContextNetwork::getSelectedVoiceRooms() const
|
||||||
|
{
|
||||||
|
return this->m_dBusInterface->callDBusRet<BlackMisc::Voice::CVoiceRoomList>(QLatin1Literal("getSelectedVoiceRooms"));
|
||||||
|
}
|
||||||
|
|
||||||
|
BlackMisc::Aviation::CAircraft IContextNetwork::getOwnAircraft() const
|
||||||
|
{
|
||||||
|
return this->m_dBusInterface->callDBusRet<BlackMisc::Aviation::CAircraft>(QLatin1Literal("getOwnAircraft"));
|
||||||
|
}
|
||||||
|
|
||||||
|
BlackMisc::CStatusMessageList IContextNetwork::connectToNetwork()
|
||||||
|
{
|
||||||
|
return this->m_dBusInterface->callDBusRet<BlackMisc::CStatusMessageList>(QLatin1Literal("connectToNetwork"));
|
||||||
|
}
|
||||||
|
|
||||||
|
BlackMisc::CStatusMessageList IContextNetwork::disconnectFromNetwork()
|
||||||
|
{
|
||||||
|
return this->m_dBusInterface->callDBusRet<BlackMisc::CStatusMessageList>(QLatin1Literal("disconnectFromNetwork"));
|
||||||
|
}
|
||||||
|
|
||||||
|
bool IContextNetwork::isConnected() const
|
||||||
|
{
|
||||||
|
return this->m_dBusInterface->callDBusRet<bool>(QLatin1Literal("isConnected"));
|
||||||
|
}
|
||||||
|
|
||||||
|
BlackMisc::CStatusMessageList IContextNetwork::setOwnAircraft(const BlackMisc::Aviation::CAircraft &aircraft)
|
||||||
|
{
|
||||||
|
return this->m_dBusInterface->callDBusRet<BlackMisc::CStatusMessageList>(QLatin1Literal("setOwnAircraft"), aircraft);
|
||||||
|
}
|
||||||
|
|
||||||
|
void IContextNetwork::updateOwnPosition(const BlackMisc::Geo::CCoordinateGeodetic &position, const BlackMisc::Aviation::CAltitude &altitude)
|
||||||
|
{
|
||||||
|
this->m_dBusInterface->callDBus(QLatin1Literal("updateOwnPosition"), position, altitude);
|
||||||
|
}
|
||||||
|
|
||||||
|
void IContextNetwork::updateOwnSituation(const BlackMisc::Aviation::CAircraftSituation &situation)
|
||||||
|
{
|
||||||
|
this->m_dBusInterface->callDBus(QLatin1Literal("updateOwnSituation"), situation);
|
||||||
|
}
|
||||||
|
|
||||||
|
void IContextNetwork::updateOwnCockpit(const BlackMisc::Aviation::CComSystem &com1, const BlackMisc::Aviation::CComSystem &com2, const BlackMisc::Aviation::CTransponder &transponder)
|
||||||
|
{
|
||||||
|
this->m_dBusInterface->callDBus(QLatin1Literal("updateOwnCockpit"), com1, com2, transponder);
|
||||||
|
}
|
||||||
|
|
||||||
|
void IContextNetwork::sendTextMessages(const BlackMisc::Network::CTextMessageList &textMessages)
|
||||||
|
{
|
||||||
|
this->m_dBusInterface->callDBus(QLatin1Literal("sendTextMessages"), textMessages);
|
||||||
|
}
|
||||||
|
|
||||||
|
BlackMisc::Aviation::CInformationMessage IContextNetwork::getMetar(const QString &airportIcaoCode)
|
||||||
|
{
|
||||||
|
return this->m_dBusInterface->callDBusRet<BlackMisc::Aviation::CInformationMessage>(QLatin1Literal("getMetar"), airportIcaoCode);
|
||||||
|
}
|
||||||
|
|
||||||
} // namespace
|
} // namespace
|
||||||
|
|||||||
@@ -10,6 +10,7 @@
|
|||||||
#include "blackmisc/statusmessage.h"
|
#include "blackmisc/statusmessage.h"
|
||||||
#include "blackmisc/statusmessagelist.h"
|
#include "blackmisc/statusmessagelist.h"
|
||||||
#include "blackmisc/nwtextmessagelist.h"
|
#include "blackmisc/nwtextmessagelist.h"
|
||||||
|
#include "blackmisc/nwuserlist.h"
|
||||||
#include "blackmisc/genericdbusinterface.h"
|
#include "blackmisc/genericdbusinterface.h"
|
||||||
#include "blackcore/network_vatlib.h"
|
#include "blackcore/network_vatlib.h"
|
||||||
#include "blackmisc/vvoiceroomlist.h"
|
#include "blackmisc/vvoiceroomlist.h"
|
||||||
@@ -139,15 +140,14 @@ namespace BlackCore
|
|||||||
|
|
||||||
/*!
|
/*!
|
||||||
* \brief Connection status changed
|
* \brief Connection status changed
|
||||||
* \param from
|
* \param from old status
|
||||||
* \param to
|
* \param to new status
|
||||||
|
* \remarks If I use the enum, adaptor / interface are not created correctly
|
||||||
*/
|
*/
|
||||||
// If I use the enum, adaptor / interface are not created correctly
|
|
||||||
void connectionStatusChanged(uint from, uint to);
|
void connectionStatusChanged(uint from, uint to);
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
* \brief Text messages (also private chat messages)
|
* \brief Text messages (also private chat messages)
|
||||||
* \param textMessage
|
|
||||||
*/
|
*/
|
||||||
void textMessagesReceived(const BlackMisc::Network::CTextMessageList &textMessages);
|
void textMessagesReceived(const BlackMisc::Network::CTextMessageList &textMessages);
|
||||||
|
|
||||||
@@ -160,94 +160,89 @@ namespace BlackCore
|
|||||||
virtual void readAtcBookingsFromSource() const;
|
virtual void readAtcBookingsFromSource() const;
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
* \brief The "central" ATC list with online ATC controllers
|
* \brief The ATC list with online ATC controllers
|
||||||
* \return
|
* \remarks If I make this &getAtcStations XML is not generated correctly
|
||||||
*/
|
*/
|
||||||
// If I make this &getAtcStations XML is not generated correctly
|
|
||||||
virtual const BlackMisc::Aviation::CAtcStationList getAtcStationsOnline() const;
|
virtual const BlackMisc::Aviation::CAtcStationList getAtcStationsOnline() const;
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
* \brief ATC list, with booked controllers
|
* \brief ATC list, with booked controllers
|
||||||
* \return
|
|
||||||
*/
|
*/
|
||||||
virtual const BlackMisc::Aviation::CAtcStationList getAtcStationsBooked() const;
|
virtual const BlackMisc::Aviation::CAtcStationList getAtcStationsBooked() const;
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
* \brief Aircraft list
|
* \brief Aircraft list
|
||||||
* \return
|
|
||||||
*/
|
*/
|
||||||
virtual const BlackMisc::Aviation::CAircraftList getAircraftsInRange() const;
|
virtual const BlackMisc::Aviation::CAircraftList getAircraftsInRange() const;
|
||||||
|
|
||||||
|
/*!
|
||||||
|
* \brief Get all users
|
||||||
|
*/
|
||||||
|
virtual BlackMisc::Network::CUserList getUsers() const;
|
||||||
|
|
||||||
|
/*!
|
||||||
|
* \brief All users with callsign, e.g. for voice room resolution
|
||||||
|
*/
|
||||||
|
virtual BlackMisc::Network::CUserList getUsersForCallsigns(const BlackMisc::Aviation::CCallsignList &callsigns) const;
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
* \brief Get own aircraft
|
* \brief Get own aircraft
|
||||||
* \return
|
|
||||||
*/
|
*/
|
||||||
virtual BlackMisc::Aviation::CAircraft getOwnAircraft() const;
|
virtual BlackMisc::Aviation::CAircraft getOwnAircraft() const;
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
* \brief Connect to Network
|
* \brief Connect to Network
|
||||||
* \return
|
* \return messages gererated during connecting
|
||||||
*/
|
*/
|
||||||
virtual BlackMisc::CStatusMessageList connectToNetwork();
|
virtual BlackMisc::CStatusMessageList connectToNetwork();
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
* \brief Disconnect from network
|
* \brief Disconnect from network
|
||||||
* \return
|
* \return messages gererated during disconnecting
|
||||||
*/
|
*/
|
||||||
virtual BlackMisc::CStatusMessageList disconnectFromNetwork();
|
virtual BlackMisc::CStatusMessageList disconnectFromNetwork();
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
* \brief Network connected?
|
* \brief Network connected?
|
||||||
* \return
|
|
||||||
*/
|
*/
|
||||||
virtual bool isConnected() const;
|
virtual bool isConnected() const;
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
* Set own aircraft
|
* Set own aircraft
|
||||||
* \param aircraft
|
* \param aircraft
|
||||||
* \return
|
* \return message list, as aircraft can only be set prior connecting
|
||||||
*/
|
*/
|
||||||
virtual BlackMisc::CStatusMessageList setOwnAircraft(const BlackMisc::Aviation::CAircraft &aircraft);
|
virtual BlackMisc::CStatusMessageList setOwnAircraft(const BlackMisc::Aviation::CAircraft &aircraft);
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
* \brief Own position, be aware height is terrain height
|
* \brief Own position, be aware height is terrain height
|
||||||
* \param Position
|
|
||||||
* \param altitude
|
|
||||||
* \return
|
|
||||||
*/
|
*/
|
||||||
virtual void updateOwnPosition(const BlackMisc::Geo::CCoordinateGeodetic &position, const BlackMisc::Aviation::CAltitude &altitude);
|
virtual void updateOwnPosition(const BlackMisc::Geo::CCoordinateGeodetic &position, const BlackMisc::Aviation::CAltitude &altitude);
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
* \brief Complete situation update
|
* \brief Complete situation update
|
||||||
* \param Situation
|
|
||||||
* \return
|
|
||||||
*/
|
*/
|
||||||
virtual void updateOwnSituation(const BlackMisc::Aviation::CAircraftSituation &situation);
|
virtual void updateOwnSituation(const BlackMisc::Aviation::CAircraftSituation &situation);
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
* \brief Update own cockpit
|
* \brief Update own cockpit
|
||||||
* \param com1
|
|
||||||
* \param com2
|
|
||||||
* \param transponder
|
|
||||||
*/
|
*/
|
||||||
virtual void updateOwnCockpit(const BlackMisc::Aviation::CComSystem &com1, const BlackMisc::Aviation::CComSystem &com2, const BlackMisc::Aviation::CTransponder &transponder);
|
virtual void updateOwnCockpit(const BlackMisc::Aviation::CComSystem &com1, const BlackMisc::Aviation::CComSystem &com2, const BlackMisc::Aviation::CTransponder &transponder);
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
* \brief Text messages (radio and private chat messages)
|
* \brief Text messages (radio and private chat messages)
|
||||||
* \param textMessage
|
|
||||||
*/
|
*/
|
||||||
virtual void sendTextMessages(const BlackMisc::Network::CTextMessageList &textMessages);
|
virtual void sendTextMessages(const BlackMisc::Network::CTextMessageList &textMessages);
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
* \brief Get METAR, if not available request it
|
* \brief Get METAR, if not available request it
|
||||||
* \param airportIcaoCode
|
* \param airportIcaoCode such as EDDF, KLAX
|
||||||
* \return
|
* \return
|
||||||
*/
|
*/
|
||||||
virtual BlackMisc::Aviation::CInformationMessage getMetar(const QString &airportIcaoCode);
|
virtual BlackMisc::Aviation::CInformationMessage getMetar(const QString &airportIcaoCode);
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
* \brief Use the selected COM1/2 frequencies, and get the corresponding voice room for it
|
* \brief Use the selected COM1/2 frequencies, and get the corresponding voice room for it
|
||||||
* \return
|
|
||||||
*/
|
*/
|
||||||
virtual BlackMisc::Voice::CVoiceRoomList getSelectedVoiceRooms() const;
|
virtual BlackMisc::Voice::CVoiceRoomList getSelectedVoiceRooms() const;
|
||||||
};
|
};
|
||||||
|
|||||||
Reference in New Issue
Block a user