Akonadi

core/agenttype.cpp
1/*
2 SPDX-FileCopyrightText: 2008 Tobias Koenig <tokoe@kde.org>
3
4 SPDX-License-Identifier: LGPL-2.0-or-later
5*/
6
7#include "agenttype.h"
8#include "agenttype_p.h"
9
10#include <QIcon>
11
12using namespace Akonadi;
13
14AgentType::AgentType()
15 : d(new AgentTypePrivate)
16{
17}
18
19AgentType::AgentType(const AgentType &other)
20 : d(other.d)
21{
22}
23
27
29{
30 return !d->mIdentifier.isEmpty();
31}
32
34{
35 return d->mIdentifier;
36}
37
39{
40 return d->mName;
41}
42
44{
45 return d->mDescription;
46}
47
49{
50 return d->mIconName;
51}
52
54{
55 return QIcon::fromTheme(d->mIconName);
56}
57
59{
60 return d->mMimeTypes;
61}
62
64{
65 return d->mCapabilities;
66}
67
69{
70 return d->mCustomProperties;
71}
72
74{
75 if (this != &other) {
76 d = other.d;
77 }
78
79 return *this;
80}
81
82bool AgentType::operator==(const AgentType &other) const
83{
84 return (d->mIdentifier == other.d->mIdentifier);
85}
A representation of an agent type.
QStringList mimeTypes() const
Returns the list of supported mime types of the agent type.
QString iconName() const
Returns the name of the icon of the agent type.
QIcon icon() const
Returns the icon of the agent type.
bool operator==(const AgentType &other) const
bool isValid() const
Returns whether the agent type is valid.
QString identifier() const
Returns the unique identifier of the agent type.
QString description() const
Returns the description of the agent type.
QStringList capabilities() const
Returns the list of supported capabilities of the agent type.
QString name() const
Returns the i18n'ed name of the agent type.
AgentType & operator=(const AgentType &other)
QVariantMap customProperties() const
Returns a Map of custom properties of the agent type.
~AgentType()
Destroys the agent type.
Helper integration between Akonadi and Qt.
QIcon fromTheme(const QString &name)
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Tue Mar 26 2024 11:13:38 by doxygen 1.10.0 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.