Akonadi

changenotification.h
1/*
2 SPDX-FileCopyrightText: 2016 Daniel Vrátil <dvratil@kde.org>
3
4 SPDX-License-Identifier: LGPL-2.0-or-later
5*/
6
7#pragma once
8
9#include <QDateTime>
10#include <QList>
11#include <QSharedDataPointer>
12#include <QSharedPointer>
13
14#include "akonadicore_export.h"
15
16namespace Akonadi
17{
18namespace Protocol
19{
20class ChangeNotification;
21using ChangeNotificationPtr = QSharedPointer<ChangeNotification>;
22}
23
24class ChangeNotificationPrivate;
25
26/**
27 * Emitted by Monitor::debugNotification() signal.
28 *
29 * This is purely for debugging purposes and should never be used in regular
30 * applications.
31 *
32 * @since 5.4
33 */
34class AKONADICORE_EXPORT ChangeNotification
35{
36public:
37 enum Type {
38 Items,
40 Tag,
41 Relation,
42 Subscription,
43 };
44
45 explicit ChangeNotification();
48
49 ChangeNotification &operator=(const ChangeNotification &other);
50
51 [[nodiscard]] bool isValid() const;
52
53 [[nodiscard]] QDateTime timestamp() const;
54 void setTimestamp(const QDateTime &timestamp);
55
56 [[nodiscard]] QList<QByteArray> listeners() const;
57 void setListeners(const QList<QByteArray> &listeners);
58
59 [[nodiscard]] Type type() const;
60 void setType(Type type);
61
62 [[nodiscard]] Protocol::ChangeNotificationPtr notification() const;
63 void setNotification(const Protocol::ChangeNotificationPtr &ntf);
64
65private:
67};
68
69}
Emitted by Monitor::debugNotification() signal.
Represents a collection of PIM items.
Definition collection.h:62
An Akonadi Tag.
Definition tag.h:26
Helper integration between Akonadi and Qt.
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Mon Nov 18 2024 12:08:29 by doxygen 1.12.0 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.