1 | /* |
2 | This file is part of the KDE Baloo Project |
3 | SPDX-FileCopyrightText: 2013 Vishesh Handa <me@vhanda.in> |
4 | |
5 | SPDX-License-Identifier: LGPL-2.1-only OR LGPL-3.0-only OR LicenseRef-KDE-Accepted-LGPL |
6 | */ |
7 | |
8 | #ifndef BASICINDEXINGJOB_H |
9 | #define BASICINDEXINGJOB_H |
10 | |
11 | #include "document.h" |
12 | |
13 | namespace Baloo { |
14 | |
15 | class BasicIndexingJob |
16 | { |
17 | public: |
18 | enum IndexingLevel { |
19 | NoLevel, |
20 | MarkForContentIndexing, |
21 | }; |
22 | |
23 | BasicIndexingJob(const QString& filePath, const QString& mimetype, |
24 | IndexingLevel level = MarkForContentIndexing); |
25 | ~BasicIndexingJob(); |
26 | |
27 | bool index(); |
28 | |
29 | Document document() { return m_doc; } |
30 | |
31 | private: |
32 | QString m_filePath; |
33 | QString m_mimetype; |
34 | IndexingLevel m_indexingLevel; |
35 | |
36 | Document m_doc; |
37 | |
38 | friend class BasicIndexingJobTest; |
39 | }; |
40 | |
41 | } |
42 | |
43 | #endif // BASICINDEXINGJOB_H |
44 | |