hyperion.ng/libsrc/webserver/CgiHandler.h

35 lines
654 B
C
Raw Normal View History

#ifndef CGIHANDLER_H
#define CGIHANDLER_H
#include <QObject>
#include <QString>
#include <QStringList>
#include <utils/Logger.h>
#include "QtHttpReply.h"
#include "QtHttpRequest.h"
class CgiHandler : public QObject {
Q_OBJECT
public:
CgiHandler (QObject * parent = NULL);
2018-12-27 23:11:32 +01:00
void setBaseUrl(const QString& url);
void exec(const QStringList & args,QtHttpRequest * request, QtHttpReply * reply);
2018-12-27 23:11:32 +01:00
// cgi commands
void cmd_cfg_jsonserver();
void cmd_runscript ();
2018-12-27 23:11:32 +01:00
private:
QtHttpReply * _reply;
QtHttpRequest * _request;
QStringList _args;
2018-12-27 23:11:32 +01:00
QString _baseUrl;
Logger * _log;
};
#endif // CGIHANDLER_H