22 #ifndef KIO_JOBCLASSES_H
23 #define KIO_JOBCLASSES_H
25 #include <QtCore/QObject>
26 #include <QtCore/QLinkedList>
27 #include <QtCore/QStringList>
69 Q_DECLARE_FLAGS(JobFlags,
JobFlag)
70 Q_DECLARE_OPERATORS_FOR_FLAGS(JobFlags)
112 JobUiDelegate *ui()
const;
120 virtual bool doKill();
126 virtual bool doSuspend();
132 virtual bool doResume();
165 int method = -1)
const;
177 #ifndef KDE_NO_DEPRECATED
178 KDE_DEPRECATED
void showErrorDialog(
QWidget *parent = 0 );
188 bool isInteractive()
const;
199 void setParentJob(
Job* parentJob );
206 Job* parentJob()
const;
275 void canceled(
KJob *job );
293 virtual bool addSubjob(
KJob *job );
302 virtual bool removeSubjob(
KJob *job );
311 Q_PRIVATE_SLOT(d_func(),
void slotSpeed(
KJob *job,
unsigned long speed ))
312 Q_DECLARE_PRIVATE(
Job)
315 class SimpleJobPrivate;
333 virtual bool doSuspend();
339 virtual bool doResume();
345 virtual bool doKill();
352 const KUrl& url()
const;
358 virtual void putOnHold();
363 static void removeOnHold();
370 bool isRedirectionHandlingEnabled()
const;
380 void setRedirectionHandlingEnabled(
bool handle);
388 void slotError(
int ,
const QString & );
395 virtual void slotFinished( );
401 virtual void slotWarning(
const QString & );
418 void storeSSLSessionFromJob(
const KUrl &m_redirectionURL);
426 Q_PRIVATE_SLOT(d_func(),
void slotConnected())
427 Q_PRIVATE_SLOT(d_func(),
void slotProcessedSize(
KIO::filesize_t data_size ))
428 Q_PRIVATE_SLOT(d_func(),
void slotSpeed(
unsigned long speed ))
429 Q_PRIVATE_SLOT(d_func(),
void slotTotalSize(
KIO::filesize_t data_size ))
430 Q_PRIVATE_SLOT(d_func(),
void _k_slotSlaveInfoMessage(
const QString&))
435 class StatJobPrivate;
459 void setSide(StatSide side);
468 #ifndef KDE_NO_DEPRECATED
469 KDE_DEPRECATED
void setSide(
bool source );
481 void setDetails(
short int details );
489 const UDSEntry & statResult()
const;
533 void permanentRedirection(
KIO::Job *job,
const KUrl &fromUrl,
const KUrl &toUrl );
536 virtual void slotFinished();
542 Q_PRIVATE_SLOT(d_func(),
void slotStatEntry(
const KIO::UDSEntry & entry ))
543 Q_PRIVATE_SLOT(d_func(),
void slotRedirection(
const KUrl &url))
547 class FileCopyJobPrivate;
548 class TransferJobPrivate;
574 bool isErrorPage()
const;
582 void setAsyncDataEnabled(
bool enabled);
599 #ifndef KDE_NO_DEPRECATED
600 KDE_DEPRECATED
void setReportDataSent(
bool enabled);
610 #ifndef KDE_NO_DEPRECATED
611 KDE_DEPRECATED
bool reportDataSent()
const;
633 virtual void slotResult(
KJob *job );
638 virtual bool doResume();
681 void permanentRedirection(
KIO::Job *job,
const KUrl &fromUrl,
const KUrl &toUrl );
701 virtual void slotRedirection(
const KUrl &url);
702 virtual void slotFinished();
703 virtual void slotData(
const QByteArray &data);
704 virtual void slotDataReq();
705 virtual void slotMimetype(
const QString &mimetype );
711 Q_PRIVATE_SLOT(d_func(),
void slotErrorPage())
713 Q_PRIVATE_SLOT(d_func(),
void slotPostRedirection())
714 Q_PRIVATE_SLOT(d_func(),
void slotNeedSubUrlData())
716 Q_PRIVATE_SLOT(d_func(),
void slotDataReqFromDevice())
721 friend class FileCopyJobPrivate;
724 class StoredTransferJobPrivate;
765 Q_PRIVATE_SLOT(d_func(),
void slotStoredData(
KIO::Job *job,
const QByteArray &data ))
771 class MultiGetJobPrivate;
791 void get(
long id,
const KUrl &url,
const MetaData &metaData);
816 void result(
long id);
819 virtual void slotRedirection(
const KUrl &url);
820 virtual void slotFinished();
821 virtual void slotData(
const QByteArray &data);
822 virtual void slotMimetype(
const QString &mimetype );
830 class MimetypeJobPrivate;
844 virtual void slotFinished( );
887 KUrl destUrl()
const;
910 virtual void slotResult(
KJob *job );
916 Q_PRIVATE_SLOT(d_func(),
void slotStart())
919 Q_PRIVATE_SLOT(d_func(),
void slotMimetype(
KIO::Job*,
const QString& type ))
920 Q_PRIVATE_SLOT(d_func(),
void slotProcessedSize(
KJob *job, qulonglong size ))
921 Q_PRIVATE_SLOT(d_func(),
void slotTotalSize(
KJob *job, qulonglong size ))
922 Q_PRIVATE_SLOT(d_func(),
void slotPercent(
KJob *job,
unsigned long pct ))
928 class ListJobPrivate;
947 const KUrl& redirectionUrl()
const;
952 void setUnrestricted(
bool unrestricted);
992 void permanentRedirection(
KIO::Job *job,
const KUrl &fromUrl,
const KUrl &toUrl );
995 virtual void slotFinished( );
997 virtual void slotResult(
KJob *job );
1004 Q_PRIVATE_SLOT(d_func(),
void slotRedirection(
const KUrl &url ))
1010 class SpecialJobPrivate;
When set, automatically overwrite the destination if it exists already.
qulonglong filesize_t
64-bit file size
Universal Directory Service.
A ListJob is allows you to get the get the content of a directory.
MimetypeJob * mimetype(const KUrl &url, JobFlags flags=DefaultFlags)
Find mimetype for one file or directory.
Hide progress information dialog, i.e.
StoredTransferJob is a TransferJob (for downloading or uploading data) that also stores a QByteArray ...
A KIO job that retrieves information about a file or directory.
JobFlag
Flags for the job properties.
StatJob * mostLocalUrl(const KUrl &url, JobFlags flags=DefaultFlags)
Tries to map a local URL for the given URL, using a KIO job.
A class that sends a special command to an ioslave.
Show the progress info GUI, no Resume and no Overwrite.
When set, automatically append to the destination file if it exists already.
SimpleJob * setModificationTime(const KUrl &url, const QDateTime &mtime)
Changes the modification time on a file or directory.
The FileCopyJob copies data from one place to another.
The base class for all jobs.
A MimetypeJob is a TransferJob that allows you to get the mime type of an URL.
The transfer job pumps data into and/or out of a Slave.
The MultiGetJob is a TransferJob that allows you to get several files from a single server...
QStringList list(const QString &fileClass)
Returns a list of directories associated with this file-class.
A simple job (one url and one command).