Imported existing sources
This commit is contained in:
12
fileserverapplication.cpp
Normal file
12
fileserverapplication.cpp
Normal file
@@ -0,0 +1,12 @@
|
||||
#include "fileserverapplication.h"
|
||||
|
||||
FileserverApplication::FileserverApplication(const QJsonObject &config, QObject *parent) :
|
||||
WebApplication(parent)
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
void FileserverApplication::start()
|
||||
{
|
||||
|
||||
}
|
15
fileserverapplication.h
Normal file
15
fileserverapplication.h
Normal file
@@ -0,0 +1,15 @@
|
||||
#pragma once
|
||||
|
||||
#include "webapplication.h"
|
||||
|
||||
class QJsonObject;
|
||||
|
||||
class FileserverApplication : public WebApplication
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
FileserverApplication(const QJsonObject &config, QObject *parent = Q_NULLPTR);
|
||||
|
||||
void start() Q_DECL_OVERRIDE;
|
||||
};
|
19
fileserverplugin.cpp
Normal file
19
fileserverplugin.cpp
Normal file
@@ -0,0 +1,19 @@
|
||||
#include "fileserverplugin.h"
|
||||
|
||||
#include "fileserverapplication.h"
|
||||
|
||||
FileserverPlugin::FileserverPlugin(QObject *parent) :
|
||||
WebPlugin(parent)
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
QString FileserverPlugin::pluginName() const
|
||||
{
|
||||
return QStringLiteral("fileserver");
|
||||
}
|
||||
|
||||
WebApplication *FileserverPlugin::createApplication(const QJsonObject &config) const
|
||||
{
|
||||
return new FileserverApplication(config);
|
||||
}
|
16
fileserverplugin.h
Normal file
16
fileserverplugin.h
Normal file
@@ -0,0 +1,16 @@
|
||||
#pragma once
|
||||
|
||||
#include "webplugin.h"
|
||||
|
||||
class FileserverPlugin : public WebPlugin
|
||||
{
|
||||
Q_OBJECT
|
||||
Q_PLUGIN_METADATA(IID "dbsoftware.webserver.plugin/1.0" FILE "fileserverplugin.json")
|
||||
Q_INTERFACES(WebPlugin)
|
||||
|
||||
public:
|
||||
FileserverPlugin(QObject *parent = Q_NULLPTR);
|
||||
|
||||
QString pluginName() const Q_DECL_OVERRIDE;
|
||||
WebApplication *createApplication(const QJsonObject &config) const Q_DECL_OVERRIDE;
|
||||
};
|
0
fileserverplugin.json
Normal file
0
fileserverplugin.json
Normal file
19
fileserverplugin.pro
Normal file
19
fileserverplugin.pro
Normal file
@@ -0,0 +1,19 @@
|
||||
QT += core network
|
||||
|
||||
DBLIBS += webserverlib
|
||||
|
||||
HEADERS += fileserverplugin.h \
|
||||
fileserverapplication.h
|
||||
|
||||
SOURCES += fileserverplugin.cpp \
|
||||
fileserverapplication.cpp
|
||||
|
||||
FORMS +=
|
||||
|
||||
RESOURCES +=
|
||||
|
||||
TRANSLATIONS +=
|
||||
|
||||
OTHER_FILES += fileserverplugin.json
|
||||
|
||||
include(../plugin.pri)
|
Reference in New Issue
Block a user