misc/quazip/JlCompress.h
changeset 5752 ea95ee97c805
equal deleted inserted replaced
5750:6bbf7aee2cdf 5752:ea95ee97c805
       
     1 #ifndef JLCOMPRESSFOLDER_H_
       
     2 #define JLCOMPRESSFOLDER_H_
       
     3 
       
     4 #include "quazip.h"
       
     5 #include "quazipfile.h"
       
     6 #include "quazipfileinfo.h"
       
     7 #include <QString>
       
     8 #include <QDir>
       
     9 #include <QFileInfo>
       
    10 #include <QFile>
       
    11 
       
    12 class QUAZIP_EXPORT JlCompress {
       
    13 private:
       
    14     static bool compressFile(QuaZip* zip, QString fileName, QString fileDest);
       
    15     static bool compressSubDir(QuaZip* parentZip, QString dir, QString parentDir, bool recursive = true);
       
    16     static bool extractFile(QuaZip* zip, QString fileName, QString fileDest);
       
    17 
       
    18     static bool removeFile(QStringList listFile);
       
    19 
       
    20 public:
       
    21     static bool compressFile(QString fileCompressed, QString file);
       
    22     static bool compressFiles(QString fileCompressed, QStringList files);
       
    23     static bool compressDir(QString fileCompressed, QString dir = QString(), bool recursive = true);
       
    24 
       
    25 public:
       
    26     static QString extractFile(QString fileCompressed, QString file, QString fileDest = QString());
       
    27     static QStringList extractFiles(QString fileCompressed, QStringList files, QString dir = QString());
       
    28     static QStringList extractDir(QString fileCompressed, QString dir = QString());
       
    29     static QStringList getFileList(QString fileCompressed);
       
    30 };
       
    31 
       
    32 #endif /* JLCOMPRESSFOLDER_H_ */