KFileMetaData

propertyinfo.h
1 /*
2  This file is part of the KFileMetaData project
3  SPDX-FileCopyrightText: 2014 Vishesh Handa <[email protected]>
4 
5  SPDX-License-Identifier: LGPL-2.1-only OR LGPL-3.0-only OR LicenseRef-KDE-Accepted-LGPL
6 */
7 
8 #ifndef _KFILEMETADATA_PROPERTYINFO_H
9 #define _KFILEMETADATA_PROPERTYINFO_H
10 
11 #include <QString>
12 #include <QVariant>
13 #include "properties.h"
14 #include "kfilemetadata_export.h"
15 
16 namespace KFileMetaData {
17 
26 class KFILEMETADATA_EXPORT PropertyInfo
27 {
28 public:
29  PropertyInfo();
31  PropertyInfo(const PropertyInfo& pi);
32  ~PropertyInfo();
33 
34  PropertyInfo& operator=(const PropertyInfo& rhs);
35  bool operator==(const PropertyInfo& rhs) const;
36 
40  Property::Property property() const;
41 
45  QString name() const;
46 
50  QString displayName() const;
51 
56  QVariant::Type valueType() const;
57 
66  bool shouldBeIndexed() const;
67 
72  static PropertyInfo fromName(const QString& name);
73 
79  QString formatAsDisplayString(const QVariant& value) const;
80 
81 private:
82  class Private;
83  Private* d;
84 };
85 
86 } // namespace
87 Q_DECLARE_METATYPE(KFileMetaData::PropertyInfo)
88 
89 
90 #endif // _KFILEMETADATA_PROPERTYINFO_H
The PropertyInfo class can be used to obtain extra information about any property.
Definition: propertyinfo.h:26
Property
The Property enum contains all files property types that KFileMetaData manipulates.
Definition: properties.h:25
<KFileMetaData/Properties>
This file is part of the KDE documentation.
Documentation copyright © 1996-2020 The KDE developers.
Generated on Mon Aug 3 2020 22:53:34 by doxygen 1.8.11 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.