KIO
KIO::TransferJob Class Reference
#include <jobclasses.h>

Detailed Description
The transfer job pumps data into and/or out of a Slave.Data is sent to the slave on request of the slave ( dataReq). If data coming from the slave can not be handled, the reading of data from the slave should be suspended.
Definition at line 508 of file jobclasses.h.
Signals | |
| void | data (KIO::Job *job, const QByteArray &data) |
| void | dataReq (KIO::Job *job, QByteArray &data) |
| void | redirection (KIO::Job *job, const KUrl &url) |
| void | permanentRedirection (KIO::Job *job, const KUrl &fromUrl, const KUrl &toUrl) |
| void | mimetype (KIO::Job *job, const QString &type) |
| void | canResume (KIO::Job *job, KIO::filesize_t offset) |
Public Member Functions | |
| ~TransferJob () | |
| void | setModificationTime (const QDateTime &mtime) |
| bool | isErrorPage () const |
| void | setAsyncDataEnabled (bool enabled) |
| void | sendAsyncData (const QByteArray &data) |
| void | setReportDataSent (bool enabled) |
| bool | reportDataSent () const |
| QString | mimetype () const |
Protected Slots | |
| virtual void | slotRedirection (const KUrl &url) |
| virtual void | slotFinished () |
| virtual void | slotData (const QByteArray &data) |
| virtual void | slotDataReq () |
| virtual void | slotMimetype (const QString &mimetype) |
| virtual void | slotMetaData (const KIO::MetaData &_metaData) |
Protected Member Functions | |
| virtual void | slotResult (KJob *job) |
| virtual bool | doResume () |
| TransferJob (TransferJobPrivate &dd) | |
Friends | |
| class | FileCopyJobPrivate |
Constructor & Destructor Documentation
| TransferJob::TransferJob | ( | TransferJobPrivate & | dd | ) | [protected] |
Member Function Documentation
| void TransferJob::setModificationTime | ( | const QDateTime & | mtime | ) |
| bool TransferJob::isErrorPage | ( | ) | const |
| void TransferJob::setAsyncDataEnabled | ( | bool | enabled | ) |
Enable the async data mode.
When async data is enabled, data should be provided to the job by calling sendAsyncData() instead of returning data in the dataReq() signal.
| void TransferJob::sendAsyncData | ( | const QByteArray & | data | ) |
| void TransferJob::setReportDataSent | ( | bool | enabled | ) |
| bool TransferJob::reportDataSent | ( | ) | const |
| QString TransferJob::mimetype | ( | ) | const |
| void TransferJob::slotResult | ( | KJob * | job | ) | [protected, virtual] |
Called when m_subJob finishes.
- Parameters:
-
job the job that finished
Reimplemented from KCompositeJob.
| bool TransferJob::doResume | ( | ) | [protected, virtual] |
| void KIO::TransferJob::data | ( | KIO::Job * | job, | |
| const QByteArray & | data | |||
| ) | [signal] |
Data from the slave has arrived.
- Parameters:
-
job the job that emitted this signal data data received from the slave.
| void KIO::TransferJob::dataReq | ( | KIO::Job * | job, | |
| QByteArray & | data | |||
| ) | [signal] |
Request for data.
Please note, that you shouldn't put too large chunks of data in it as this requires copies within the frame work, so you should rather split the data you want to pass here in reasonable chunks (about 1MB maximum)
- Parameters:
-
job the job that emitted this signal data buffer to fill with data to send to the slave. An empty buffer indicates end of data. (EOD)
Signals a redirection.
Use to update the URL shown to the user. The redirection itself is handled internally.
- Parameters:
-
job the job that emitted this signal url the new URL
| void KIO::TransferJob::permanentRedirection | ( | KIO::Job * | job, | |
| const KUrl & | fromUrl, | |||
| const KUrl & | toUrl | |||
| ) | [signal] |
Signals a permanent redirection.
The redirection itself is handled internally.
- Parameters:
-
job the job that emitted this signal fromUrl the original URL toUrl the new URL
Mimetype determined.
- Parameters:
-
job the job that emitted this signal type the mime type
| void KIO::TransferJob::canResume | ( | KIO::Job * | job, | |
| KIO::filesize_t | offset | |||
| ) | [signal] |
| void TransferJob::slotRedirection | ( | const KUrl & | url | ) | [protected, virtual, slot] |
| void TransferJob::slotFinished | ( | ) | [protected, virtual, slot] |
Called when the slave marks the job as finished.
Reimplemented from KIO::SimpleJob.
Reimplemented in KIO::DavJob, KIO::MultiGetJob, and KIO::MimetypeJob.
| void TransferJob::slotData | ( | const QByteArray & | data | ) | [protected, virtual, slot] |
| void TransferJob::slotDataReq | ( | ) | [protected, virtual, slot] |
| void TransferJob::slotMimetype | ( | const QString & | mimetype | ) | [protected, virtual, slot] |
| void TransferJob::slotMetaData | ( | const KIO::MetaData & | _metaData | ) | [protected, virtual, slot] |
MetaData from the slave is received.
- Parameters:
-
_metaData the meta data
- See also:
- metaData()
Reimplemented from KIO::SimpleJob.
Friends And Related Function Documentation
friend class FileCopyJobPrivate [friend] |
Definition at line 658 of file jobclasses.h.
The documentation for this class was generated from the following files:
KDE 4.0 API Reference