-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathrestapi.h
26 lines (21 loc) · 861 Bytes
/
restapi.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
//-----------------------------------------------------------------------------------------------------------
// Emby Explorer (Qt) (w) 2024-2025 by Jan Buchholz
// Simple REST API
//-----------------------------------------------------------------------------------------------------------
#pragma once
#include <QNetworkAccessManager>
#include <QNetworkRequestFactory>
#include <QRestAccessManager>
#include <qnetworkreply.h>
#include "globals.h"
class RestApi : public QObject {
Q_OBJECT
public:
explicit RestApi(QObject *parent = nullptr);
~RestApi();
QByteArray makeRestCallGET(restParameters para, QNetworkReply::NetworkError *e);
QByteArray makeRestCallPOST(restParameters para, QNetworkReply::NetworkError *e);
private:
QNetworkAccessManager *netManager;
QNetworkRequestFactory *netFactory;
};