mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-04-07 11:05:33 +08:00
refs #452, integrated METAR reader in CWebDataServices
* renamed files without "_" * added flags * integrated URL into global reader settings * added new parameter for connectVatsimDataSignals * removed unused setting in settings / network.h
This commit is contained in:
committed by
Mathew Sutcliffe
parent
3923336da8
commit
24432a56c7
@@ -17,13 +17,19 @@ namespace BlackCore
|
||||
m_protocolIcaoReader("http"), m_serverIcaoReader("ubuntu12"), m_baseUrlIcaoReader("vatrep/public"),
|
||||
m_protocolModelReader("http"), m_serverModelReader("ubuntu12"), m_baseUrlModelReader("vatrep/public"),
|
||||
m_bookingsUrl("http://vatbook.euroutepro.com/xml2.php"),
|
||||
m_metarUrl("http://metar.vatsim.net/metar.php"),
|
||||
m_vatsimDataFileUrls({ "http://info.vroute.net/vatsim-data.txt" })
|
||||
{ }
|
||||
|
||||
QString CGlobalReaderSettings::urlVatsimMetars() const
|
||||
{
|
||||
return m_metarUrl + "?id=all";
|
||||
}
|
||||
|
||||
const CGlobalReaderSettings &CGlobalReaderSettings::instance()
|
||||
{
|
||||
static const CGlobalReaderSettings rs;
|
||||
return rs;
|
||||
}
|
||||
}
|
||||
}
|
||||
} // ns
|
||||
} // ns
|
||||
|
||||
@@ -42,12 +42,18 @@ namespace BlackCore
|
||||
//! Model Reader server
|
||||
const QString &baseUrlModelReader() const { return m_baseUrlModelReader; }
|
||||
|
||||
//! URL to read bookings
|
||||
//! URL to read VATSIM bookings
|
||||
const QString &bookingsUrl() const { return m_bookingsUrl; }
|
||||
|
||||
//! VATSIM data file URLs
|
||||
const QStringList &vatsimDataFileUrls() const { return m_vatsimDataFileUrls; }
|
||||
|
||||
//! VATSIM METAR URL
|
||||
const QString &baseUrlVatsimMetars() const { return m_metarUrl; }
|
||||
|
||||
//! VATSIM METAR URL (with query string)
|
||||
QString urlVatsimMetars() const;
|
||||
|
||||
//! Singleton
|
||||
static const CGlobalReaderSettings &instance();
|
||||
|
||||
@@ -65,6 +71,7 @@ namespace BlackCore
|
||||
QString m_serverModelReader;
|
||||
QString m_baseUrlModelReader;
|
||||
QString m_bookingsUrl;
|
||||
QString m_metarUrl;
|
||||
QStringList m_vatsimDataFileUrls;
|
||||
};
|
||||
}
|
||||
|
||||
@@ -57,16 +57,6 @@ namespace BlackCore
|
||||
}
|
||||
};
|
||||
|
||||
//! Booking service URL
|
||||
struct BookingService : public CSettingTrait<QString>
|
||||
{
|
||||
//! \copydoc BlackCore::CSetting::key
|
||||
static const char *key() { return "network/bookingservice"; }
|
||||
|
||||
//! \copydoc BlackCore::CSetting::defaultValue
|
||||
static const QString &defaultValue() { static const QString dv("http://vatbook.euroutepro.com/xml2.php"); return dv; }
|
||||
};
|
||||
|
||||
//! DBus server address
|
||||
struct DBusServerAddress : public CSettingTrait<QString>
|
||||
{
|
||||
@@ -76,8 +66,8 @@ namespace BlackCore
|
||||
//! \copydoc BlackCore::CSetting::defaultValue
|
||||
static const QString &defaultValue() { static const QString dv("session"); return dv; }
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
} // ns
|
||||
} // ns
|
||||
} // ns
|
||||
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user