xlsxzipreader_p.h 723 B

123456789101112131415161718192021222324252627282930313233343536373839
  1. // xlsxzipreader_p.h
  2. #ifndef QXLSX_XLSXZIPREADER_P_H
  3. #define QXLSX_XLSXZIPREADER_P_H
  4. #include <QScopedPointer>
  5. #include <QStringList>
  6. #include <QIODevice>
  7. #include "xlsxglobal.h"
  8. #if QT_VERSION >= 0x050600
  9. #include <QVector>
  10. #endif
  11. class QZipReader;
  12. QT_BEGIN_NAMESPACE_XLSX
  13. class ZipReader
  14. {
  15. public:
  16. explicit ZipReader(const QString &fileName);
  17. explicit ZipReader(QIODevice *device);
  18. ~ZipReader();
  19. bool exists() const;
  20. QStringList filePaths() const;
  21. QByteArray fileData(const QString &fileName) const;
  22. private:
  23. Q_DISABLE_COPY(ZipReader)
  24. void init();
  25. QScopedPointer<QZipReader> m_reader;
  26. QStringList m_filePaths;
  27. };
  28. QT_END_NAMESPACE_XLSX
  29. #endif // QXLSX_XLSXZIPREADER_P_H