summaryrefslogblamecommitdiffstats
path: root/src/httpxmldownloader.cpp
blob: bebcfd0ca2955b52d5f6402cac836af2e7185ccd (plain) (tree)
1
2
3
4
5
6
7
8



                              
                                        
                                              
 
 





                                                                                                  

 

                                                                           
 

#include "httpxmldownloader.h"
#include <QDebug>

HttpXmlDownloader::HttpXmlDownloader() {
	nam = new QNetworkAccessManager(this);
}

QNetworkReply* HttpXmlDownloader::makeRequest(const QString& xmlurl, const QString& locationIds) {
	QUrl url(xmlurl);
	if (!locationIds.isEmpty()) {
		url.addQueryItem("locations", locationIds);
	}
	return nam->get(QNetworkRequest(url));
}

void HttpXmlDownloader::connectSlot(QObject* obj, const char* slot) {
	QObject::connect(nam, SIGNAL(finished(QNetworkReply*)), obj, slot);
}