00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020 #ifndef koTarStore_h
00021 #define koTarStore_h
00022
00023 #include "KoStoreBase.h"
00024
00025 #include <QByteArray>
00026
00027 class KTar;
00028 class KArchiveDirectory;
00029 class KUrl;
00030
00031 class KoTarStore : public KoStoreBase
00032 {
00033 public:
00034 KoTarStore( const QString & _filename, Mode _mode, const QByteArray & appIdentification );
00035 KoTarStore( QIODevice *dev, Mode mode, const QByteArray & appIdentification );
00041 KoTarStore( QWidget* window, const KUrl& url, const QString & _filename, Mode _mode, const QByteArray & appIdentification );
00042 ~KoTarStore();
00043 protected:
00044 virtual bool init( Mode _mode );
00045 virtual bool openWrite( const QString& name );
00046 virtual bool openRead( const QString& name );
00047 virtual bool closeWrite();
00048 virtual bool closeRead() { return true; }
00049 virtual bool enterRelativeDirectory( const QString& dirName );
00050 virtual bool enterAbsoluteDirectory( const QString& path );
00051 virtual bool fileExists( const QString& absPath ) const;
00052
00053 static QByteArray completeMagic( const QByteArray& appMimetype );
00054
00056 KTar * m_pTar;
00057
00060 const KArchiveDirectory* m_currentDir;
00061
00063 QByteArray m_byteArray;
00064
00065 };
00066
00067 #endif