KFileMetaData

extractionresult.cpp
1 /*
2  SPDX-FileCopyrightText: 2013 Vishesh Handa <[email protected]>
3 
4  SPDX-License-Identifier: LGPL-2.1-only OR LGPL-3.0-only OR LicenseRef-KDE-Accepted-LGPL
5 */
6 
7 #include "extractionresult.h"
8 
9 using namespace KFileMetaData;
10 
11 class KFileMetaData::ExtractionResultPrivate
12 {
13 public:
14  QString url;
18 };
19 
20 ExtractionResult::ExtractionResult(const QString& url, const QString& mimetype, const Flags& flags)
21  : d(new ExtractionResultPrivate)
22 {
23  d->url = url;
24  d->mimetype = mimetype;
25  d->flags = flags;
26 }
27 
29  : d(new ExtractionResultPrivate(*rhs.d))
30 {
31 }
32 
33 ExtractionResult::~ExtractionResult() = default;
34 
36 {
37  return d->url;
38 }
39 
41 {
42  return d->mimetype;
43 }
44 
46 {
47  return d->flags;
48 }
49 
51 {
52  d->images = images;
53 }
54 
57 {
58  return d->images;
59 }
60 
The ExtractionResult class is where all the data extracted by the indexer is saved....
QString inputMimetype() const
The input mimetype.
ExtractionResult(const QString &url, const QString &mimetype=QString(), const Flags &flags=Flags{ExtractPlainText|ExtractMetaData})
Create an ExtractionResult which can be passed be to Extractors.
QString inputUrl() const
The input url which the plugins will use to locate the file.
QMap< EmbeddedImageData::ImageType, QByteArray > imageData() const
Return embedded image data.
KIOCORE_EXPORT MimetypeJob * mimetype(const QUrl &url, JobFlags flags=DefaultFlags)
Flags inputFlags() const
The flags which the extraction plugin should considering following when extracting metadata from the ...
void addImageData(QMap< EmbeddedImageData::ImageType, QByteArray > &&images)
This function is called by the plugins.
This file is part of the KDE documentation.
Documentation copyright © 1996-2023 The KDE developers.
Generated on Wed Nov 29 2023 03:48:30 by doxygen 1.8.17 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.