9#include <karchive_export.h>
10#include <kcompressiondevice.h>
14#if KARCHIVE_ENABLE_DEPRECATED_SINCE(5, 85)
43 KFilterDev(
const QString &fileName);
50 KARCHIVE_DEPRECATED_VERSION(5, 85,
"Use KCompressionDevice::compressionTypeForMimeType(const QString &)")
51 static CompressionType compressionTypeForMimeType(const QString &mimetype);
53#if KARCHIVE_ENABLE_DEPRECATED_SINCE(5, 0)
93 KARCHIVE_DEPRECATED_VERSION(5, 0,
"See API docs")
94 static
KCompressionDevice *deviceForFile(const QString &fileName, const QString &mimetype = QString(),
bool forceFilter = false)
97 if (mimetype.isEmpty()) {
98 device =
new KFilterDev(fileName);
102 if (device->
compressionType() == KCompressionDevice::None && forceFilter) {
111#if KARCHIVE_ENABLE_DEPRECATED_SINCE(5, 0)
138 KARCHIVE_DEPRECATED_VERSION(5, 0,
"See API docs")
139 static
KCompressionDevice *device(QIODevice *inDevice, const QString &mimetype,
bool autoDeleteInDevice = true)
141 if (inDevice ==
nullptr) {
144 CompressionType type = compressionTypeForMimeType(mimetype);
A class for reading and writing compressed data onto a device (e.g.
Definition kcompressiondevice.h:31
CompressionType compressionType() const
The compression actually used by this device.
This is the base class for compression filters such as gzip and bzip2.
Definition kfilterbase.h:27