KDECore
kservice.h
Go to the documentation of this file.
58class KDECORE_EXPORT KService : public KSycocaEntry // TODO KDE5: inherit kshared, but move KSycocaEntry to Private
637 static KDE_DEPRECATED T *createInstance(ServiceIterator begin, ServiceIterator end, QObject *parent = 0,
static T * createInstance(const QString &keyword, const QString &libname, QObject *parent=0, const QVariantList &args=QVariantList(), int *error=0)
This template allows to load the specified library and ask the factory to create an instance of the g...
Definition klibloader.h:202
static QString errorString(int componentLoadingError)
Converts a numerical error code into a human-readable error message.
Definition klibloader.cpp:142
If you develop a library that is to be loaded dynamically at runtime, then you should return a pointe...
Definition kpluginfactory.h:233
This class can be used to dynamically load a plugin library at runtime.
Definition kpluginloader.h:80
KPluginFactory * factory()
Used to obtain the factory object of the plugin.
Definition kpluginloader.cpp:185
Definition kservice_p.h:30
A service type is, well, a type of service, where a service is an application or plugin.
Definition kservicetype.h:44
T * createInstance(QWidget *parentWidget, QObject *parent, const QVariantList &args=QVariantList(), QString *error=0) const
This template allows to load the library for the specified service and ask the factory to create an i...
Definition kservice.h:567
static T * createInstance(const KService::Ptr &service, QObject *parent=0, const QVariantList &args=QVariantList(), QString *error=0)
Definition kservice.h:591
QString desktopEntryName() const
Returns the filename of the service desktop entry without any extension.
Definition kservice.cpp:889
bool substituteUid() const
Checks whether the service runs with a different user id.
Definition kservice.cpp:665
QString desktopEntryPath() const
Returns the path to the location where the service desktop entry is stored.
Definition kservice.cpp:883
bool terminal() const
Checks whethe the service should be run in a terminal.
Definition kservice.cpp:875
QString terminalOptions() const
Returns any options associated with the terminal the service runs in, if it requires a terminal.
Definition kservice.cpp:869
KService(const QString &name, const QString &exec, const QString &icon)
Construct a temporary service with a given name, exec-line and icon.
Definition kservice.cpp:373
QString username() const
Returns the user name, if the service runs with a different user id.
Definition kservice.cpp:670
static T * createInstance(ServiceIterator begin, ServiceIterator end, QObject *parent, const QStringList &args, int *error=0)
Definition kservice.h:660
static T * createInstance(const KService::Ptr &service, QObject *parent, const QStringList &args, int *error=0)
Definition kservice.h:604
QVector< ServiceTypeAndPreference > & _k_accessServiceTypes()
Definition kservice.cpp:989
QString pluginKeyword() const
The keyword to be used when constructing the plugin using KPluginFactory.
Definition kservice.cpp:733
T * createInstance(QObject *parent=0, const QVariantList &args=QVariantList(), QString *error=0) const
This template allows to load the library for the specified service and ask the factory to create an i...
Definition kservice.h:547
static T * createInstance(ServiceIterator begin, ServiceIterator end, QObject *parent=0, const QVariantList &args=QVariantList(), QString *error=0)
This template allows to create a component from a list of services, usually coming from a trader quer...
Definition kservice.h:637
bool isApplication() const
Services are either applications (executables) or dlopened libraries (plugins).
Definition kservice.cpp:832
QVariant property(const QString &name) const
Returns the requested property.
Definition ksycocaentry.cpp:169
Definition kaboutdata.h:33
QDataStream & operator>>(QDataStream &s, KDateTime::Spec &spec)
Read a KDateTime::Spec object into spec from in, in binary format.
Definition kdatetime.cpp:274
QString i18n(const char *text)
Returns a localized version of a string.
Definition klocalizedstring.h:630
#define T
ServiceTypeAndPreference(int pref, const QString &servType)
Definition kservice.h:689
ServiceTypeAndPreference()
Definition kservice.h:687
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.14.0 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.14.0 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.