KDECore
kjobtrackerinterface.h
Go to the documentation of this file.
00001 /* This file is part of the KDE project 00002 Copyright (C) 2007 Kevin Ottens <ervin@kde.org> 00003 00004 This library is free software; you can redistribute it and/or 00005 modify it under the terms of the GNU Library General Public 00006 License version 2 as published by the Free Software Foundation. 00007 00008 This library is distributed in the hope that it will be useful, 00009 but WITHOUT ANY WARRANTY; without even the implied warranty of 00010 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 00011 Library General Public License for more details. 00012 00013 You should have received a copy of the GNU Library General Public License 00014 along with this library; see the file COPYING.LIB. If not, write to 00015 the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, 00016 Boston, MA 02110-1301, USA. 00017 00018 */ 00019 00020 #ifndef KJOBTRACKERINTERFACE_H 00021 #define KJOBTRACKERINTERFACE_H 00022 00023 #include <kdecore_export.h> 00024 #include <kjob.h> 00025 00026 #include <QtCore/QObject> 00027 #include <QtCore/QPair> 00028 00032 class KDECORE_EXPORT KJobTrackerInterface : public QObject 00033 { 00034 Q_OBJECT 00035 00036 public: 00042 KJobTrackerInterface(QObject *parent=0); 00043 00047 virtual ~KJobTrackerInterface(); 00048 00049 public Q_SLOTS: 00055 virtual void registerJob(KJob *job); 00056 00062 virtual void unregisterJob(KJob *job); 00063 00064 protected Q_SLOTS: 00071 virtual void finished(KJob *job); 00072 00078 virtual void suspended(KJob *job); 00079 00085 virtual void resumed(KJob *job); 00086 00100 virtual void description(KJob *job, const QString &title, 00101 const QPair<QString, QString> &field1, 00102 const QPair<QString, QString> &field2); 00103 00112 virtual void infoMessage(KJob *job, const QString &plain, const QString &rich); 00113 00121 virtual void warning(KJob *job, const QString &plain, const QString &rich); 00122 00132 virtual void totalAmount(KJob *job, KJob::Unit unit, qulonglong amount); 00133 00143 virtual void processedAmount(KJob *job, KJob::Unit unit, qulonglong amount); 00144 00152 virtual void percent(KJob *job, unsigned long percent); 00153 00160 virtual void speed(KJob *job, unsigned long value); 00161 00162 private: 00163 class Private; 00164 Private *const d; 00165 }; 00166 00167 #endif
KDE 4.6 API Reference