UnregisterService.hpp Example File
pushCollector/10.0/pushCollector/src/service/UnregisterService.hpp
#ifndef UNREGISTERSERVICE_HPP
#define UNREGISTERSERVICE_HPP
#include "ConfigurationService.hpp"
#include "../dao/UserDAO.hpp"
#include <QtCore/QObject>
#include <QtNetwork/QNetworkReply>
class UnregisterService : public QObject
{
Q_OBJECT
public:
UnregisterService(QObject *parent = 0);
User getCurrentlyRegisteredUser();
void removeUser();
void unsubscribeFromPushInitiator(const User& user);
Q_SIGNALS:
void piDeregistrationCompleted(int code, const QString& description);
private Q_SLOTS:
void httpFinished();
void onSslErrors(QNetworkReply * reply, const QList<QSslError> & errors);
private:
ConfigurationService m_configurationService;
QNetworkAccessManager m_accessManager;
UserDAO m_userDAO;
QNetworkReply *m_reply;
User m_currentUser;
};
#endif