#ifndef DORICJSLOADERMANAGER_H
#define DORICJSLOADERMANAGER_H
#include <QDebug>
#include "DoricExport.h"
#include "DoricInterfaceLoader.h"
class DORIC_EXPORT DoricJSLoaderManager {
private:
static DoricJSLoaderManager *local_instance;
DoricJSLoaderManager();
~DoricJSLoaderManager() { qDebug() << "DoricJSLoaderManager destructor"; }
public:
static DoricJSLoaderManager *getInstance() {
static DoricJSLoaderManager instance;
return &instance;
}
QSet<DoricInterfaceLoader *> jsLoaders;
void addJSLoader(DoricInterfaceLoader *jsLoader);
QSet<DoricInterfaceLoader *> *getJSLoaders();
std::shared_ptr<DoricAsyncResult> request(QString source);
};
#endif // DORICJSLOADERMANAGER_H