1 #ifndef LOTW_USERS_HPP_ 2 #define LOTW_USERS_HPP_ 3 4 #include <boost/core/noncopyable.hpp> 5 #include <QObject> 6 #include "pimpl_h.hpp" 7 8 class QString; 9 class QDate; 10 class QNetworkAccessManager; 11 12 // 13 // LotWUsers - Lookup Logbook of the World users 14 // 15 class LotWUsers final 16 : public QObject 17 { 18 Q_OBJECT 19 20 public: 21 explicit LotWUsers (QNetworkAccessManager *, QObject * parent = 0); 22 ~LotWUsers (); 23 24 void set_local_file_path (QString const&); 25 26 Q_SLOT void load (QString const& url, bool fetch = true, bool force_download = false); 27 Q_SLOT void set_age_constraint (qint64 uploaded_since_days); 28 29 // returns true if the specified call sign 'call' has uploaded their 30 // log to LotW in the last 'age_constraint_days' days 31 bool user (QString const& call) const; 32 33 Q_SIGNAL void LotW_users_error (QString const& reason) const; 34 Q_SIGNAL void load_finished () const; 35 36 private: 37 class impl; 38 pimpl<impl> m_; 39 }; 40 41 #endif 42