sqlitevacuum.h
1/* This file is part of the KDE project
2 Copyright (C) 2006 Jaroslaw Staniek <js@iidea.pl>
3
4 This library is free software; you can redistribute it and/or
5 modify it under the terms of the GNU Library General Public
6 License as published by the Free Software Foundation; either
7 version 2 of the License, or (at your option) any later version.
8
9 This library is distributed in the hope that it will be useful,
10 but WITHOUT ANY WARRANTY; without even the implied warranty of
11 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 Library General Public License for more details.
13
14 You should have received a copy of the GNU Library General Public License
15 along with this library; see the file COPYING.LIB. If not, write to
16 the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
17 * Boston, MA 02110-1301, USA.
18*/
19
20#ifndef SQLITE_VACUUM_H
21#define SQLITE_VACUUM_H
22
23#include <tqobject.h>
24#include <tqstring.h>
25
26#include <kexiutils/tristate.h>
27
28class TQProcess;
29class KTempFile;
30class KProgressDialog;
31
33
45class SQLiteVacuum : public TQObject
46{
47 TQ_OBJECT
48
49 public:
50 SQLiteVacuum(const TQString& filePath);
52
56 tristate run();
57
58 public slots:
59 void readFromStdout();
60 void processExited();
61 void cancelClicked();
62
63 protected:
64 TQString m_filePath;
65 TQProcess *m_process;
66 KProgressDialog* m_dlg;
67 int m_percent;
68 tristate m_result;
69};
70
71#endif
Helper class performing interactive compacting (VACUUM) of the SQLite database.
tristate run()
3-state logical type with three values: true, false and cancelled and convenient operators.
Definition tristate.h:100