7#ifndef KPACKAGE_PACKAGESTRUCTURE_H
8#define KPACKAGE_PACKAGESTRUCTURE_H
12#include <KPluginFactory>
14#include <kpackage/package.h>
15#include <kpackage/package_export.h>
19class PackageStructurePrivate;
46 explicit PackageStructure(QObject *parent =
nullptr,
const QVariantList &args = QVariantList());
80 virtual KJob *
install(
Package *package,
const QString &archivePath,
const QString &packageRoot);
96 virtual KJob *
update(
Package *package,
const QString &archivePath,
const QString &packageRoot);
110 PackageStructurePrivate *d;
119#define K_EXPORT_KPACKAGE_PACKAGE_WITH_JSON(classname, jsonFile) K_PLUGIN_FACTORY_WITH_JSON(factory, jsonFile, registerPlugin<classname>();)
This class is used to define the filesystem structure of a package type.
Definition packagestructure.h:42
virtual KJob * uninstall(Package *package, const QString &packageRoot)
Uninstalls a package matching this package structure.
virtual void initPackage(Package *package)
Called when a the PackageStructure should initialize a Package with the initial structure.
virtual KJob * install(Package *package, const QString &archivePath, const QString &packageRoot)
Installs a package matching this package structure.
virtual void pathChanged(Package *package)
Called whenever the path changes so that subclasses may take package specific actions.
virtual KJob * update(Package *package, const QString &archivePath, const QString &packageRoot)
Updates a package matching this package structure.
object representing an installed package
Definition package.h:67