KDECore
kpluginloader.cpp
Go to the documentation of this file.
119 kDebug(kLibraryDebugArea()) << "library" << libname << "not found under 'module' but under 'lib'";
133KPluginLoader::KPluginLoader(const QString &plugin, const KComponentData &componentdata, QObject *parent)
134 : QPluginLoader(findLibraryInternal(plugin, componentdata), parent), d_ptr(new KPluginLoaderPrivate(plugin))
150KPluginLoader::KPluginLoader(const KService &service, const KComponentData &componentdata, QObject *parent)
151: QPluginLoader(findLibraryInternal(service.library(), componentdata), parent), d_ptr(new KPluginLoaderPrivate(service.library()))
209 kDebug(kLibraryDebugArea()) << "Expected a KPluginFactory, got a" << obj->metaObject()->className();
236 d->verificationData = (KDEPluginVerificationData *) lib.resolve("kde_plugin_verification_data");
239 || ((d->verificationData->KDEVersion & 0xFFFF00) > (KDE_VERSION & 0xFFFF00)) // newer minor version
240 || (KDE_VERSION_MAJOR << 16 != (d->verificationData->KDEVersion & 0xFF0000))) // different major version
242 d->errorString = i18n("The plugin '%1' uses an incompatible KDE library (%2).", d->name, QString::fromLatin1(d->verificationData->KDEVersionString));
247 kDebug(kLibraryDebugArea()) << "The plugin" << d->name << "doesn't contain a kde_plugin_verification_data structure";
KStandardDirs * dirs() const
Returns the application standard dirs object.
Definition kcomponentdata.cpp:193
const KAboutData * aboutData() const
Returns the about data of this component.
Definition kcomponentdata.cpp:215
Thin wrapper around QLibrary; you should rarely use this directly, see KPluginLoader for higher-level...
Definition klibrary.h:39
If you develop a library that is to be loaded dynamically at runtime, then you should return a pointe...
Definition kpluginfactory.h:233
KPluginFactory * factory()
Used to obtain the factory object of the plugin.
Definition kpluginloader.cpp:185
KPluginLoader(const QString &plugin, const KComponentData &componentdata=KGlobal::mainComponent(), QObject *parent=0)
Used this constructor to load a plugin with a given library name.
Definition kpluginloader.cpp:133
Represent a service, like an application or plugin bound to one or several mimetypes (or servicetypes...
Definition kservice.h:59
QString findResource(const char *type, const QString &filename) const
Tries to find a resource in the following order:
Definition kstandarddirs.cpp:458
QString findLibraryInternal(const QString &name, const KComponentData &cData)
Definition kpluginloader.cpp:83
QString i18n(const char *text)
Returns a localized version of a string.
Definition klocalizedstring.h:630
QString findLibraryInternal(const QString &name, const KComponentData &cData)
Definition kpluginloader.cpp:83
Definition kexportplugin.h:33
@ PluginVerificationDataVersion
Definition kexportplugin.h:34
This file is part of the KDE documentation.
Documentation copyright © 1996-2025 The KDE developers.
Generated on Tue Mar 25 2025 00:00:00 by doxygen 1.13.2 written by Dimitri van Heesch, © 1997-2006
Documentation copyright © 1996-2025 The KDE developers.
Generated on Tue Mar 25 2025 00:00:00 by doxygen 1.13.2 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.