/* * Copyright 2009 Rob Scheepmaker #include class QUrl; namespace Plasma { class Applet; class AccessAppletJobPrivate; /** * @class AccessAppletJob plasma/accessappletjob.h * * @short This class is used for asynchronously accessing an applet published on a remote system. * After calling AccessManager::accessApplet, monitor this job to track when the remote applet * is ready to be used, and to obtain the service when finished. */ class PLASMA_EXPORT AccessAppletJob : public KJob { Q_OBJECT public: ~AccessAppletJob(); Applet *applet() const; protected: /** * Default constructor * * @param location the location of the service * @param parent the parent object for this service */ AccessAppletJob(const QUrl &location, QObject *parent = 0); void start(); private: AccessAppletJob(); Q_PRIVATE_SLOT(d, void slotPackageDownloaded(Plasma::ServiceJob*)) Q_PRIVATE_SLOT(d, void slotStart()) Q_PRIVATE_SLOT(d, void slotServiceReady(Plasma::Service*)) Q_PRIVATE_SLOT(d, void slotTimeout()) AccessAppletJobPrivate * const d; friend class AccessManager; friend class AccessManagerPrivate; friend class AccessAppletJobPrivate; }; } // namespace Plasma #endif // PLASMA_ACCESSAPPLETJOB_H