2020-08-25 16:05:56 +02:00
|
|
|
/* === This file is part of Calamares - <https://calamares.io> ===
|
2014-07-16 16:09:53 +02:00
|
|
|
*
|
2020-08-20 22:42:19 +02:00
|
|
|
* SPDX-FileCopyrightText: 2014 Teo Mrnjavac <teo@kde.org>
|
|
|
|
* SPDX-License-Identifier: GPL-3.0-or-later
|
2014-07-16 16:09:53 +02:00
|
|
|
*
|
2020-08-25 16:05:56 +02:00
|
|
|
* Calamares is Free Software: see the License-Identifier above.
|
2014-07-16 16:09:53 +02:00
|
|
|
*
|
|
|
|
*/
|
|
|
|
|
|
|
|
#ifndef CALAMARES_PYTHONJOBMODULE_H
|
|
|
|
#define CALAMARES_PYTHONJOBMODULE_H
|
|
|
|
|
2020-02-17 11:32:28 +01:00
|
|
|
#include "DllMacro.h"
|
2020-03-31 22:56:42 +02:00
|
|
|
#include "modulesystem/Module.h"
|
2014-07-16 16:09:53 +02:00
|
|
|
|
2018-06-18 16:56:10 +02:00
|
|
|
namespace Calamares
|
|
|
|
{
|
2014-07-16 16:09:53 +02:00
|
|
|
|
2020-02-17 16:52:45 +01:00
|
|
|
class UIDLLEXPORT PythonJobModule : public Module
|
2014-07-16 16:09:53 +02:00
|
|
|
{
|
|
|
|
public:
|
|
|
|
Type type() const override;
|
|
|
|
Interface interface() const override;
|
|
|
|
|
|
|
|
void loadSelf() override;
|
2017-11-03 15:10:37 +01:00
|
|
|
JobList jobs() const override;
|
2014-07-16 16:09:53 +02:00
|
|
|
|
|
|
|
protected:
|
2020-08-11 22:12:16 +02:00
|
|
|
void initFrom( const ModuleSystem::Descriptor& moduleDescriptor ) override;
|
2014-07-16 16:09:53 +02:00
|
|
|
|
|
|
|
private:
|
|
|
|
explicit PythonJobModule();
|
2020-09-22 22:49:30 +02:00
|
|
|
~PythonJobModule() override;
|
2014-07-16 16:09:53 +02:00
|
|
|
|
|
|
|
QString m_scriptFileName;
|
|
|
|
QString m_workingPath;
|
2014-07-22 16:54:34 +02:00
|
|
|
job_ptr m_job;
|
2020-03-31 22:44:02 +02:00
|
|
|
|
|
|
|
friend Module* Calamares::moduleFromDescriptor( const ModuleSystem::Descriptor& moduleDescriptor,
|
|
|
|
const QString& instanceId,
|
|
|
|
const QString& configFileName,
|
|
|
|
const QString& moduleDirectory );
|
2014-07-16 16:09:53 +02:00
|
|
|
};
|
|
|
|
|
2019-06-27 15:15:47 +02:00
|
|
|
} // namespace Calamares
|
2014-07-16 16:09:53 +02:00
|
|
|
|
2019-06-27 15:15:47 +02:00
|
|
|
#endif // CALAMARES_PYTHONJOBMODULE_H
|