Akonadi

itemcreatehandler.h
1/***************************************************************************
2 * SPDX-FileCopyrightText: 2007 Robert Zwerus <arzie@dds.nl> *
3 * *
4 * SPDX-License-Identifier: LGPL-2.0-or-later *
5 ***************************************************************************/
6
7#pragma once
8
9#include "entities.h"
10#include "handler.h"
11
12namespace Akonadi
13{
14namespace Server
15{
16/**
17 @ingroup akonadi_server_handler
18
19 Handler for the X-AKAPPEND command.
20
21 This command is used to append an item with multiple parts.
22
23 */
25{
26public:
27 ItemCreateHandler(AkonadiServer &akonadi);
28 ~ItemCreateHandler() override = default;
29
30 bool parseStream() override;
31
32private:
33 bool buildPimItem(const Protocol::CreateItemCommand &cmd, PimItem &item, Collection &parentCollection);
34
35 bool insertItem(const Protocol::CreateItemCommand &cmd, PimItem &item, const Collection &parentCollection);
36
37 bool mergeItem(const Protocol::CreateItemCommand &cmd, PimItem &newItem, PimItem &currentItem, const Collection &parentCollection);
38
39 bool sendResponse(const PimItem &item, Protocol::CreateItemCommand::MergeModes mergeModes);
40
41 bool notify(const PimItem &item, bool seen, const Collection &collection);
42 bool notify(const PimItem &item, const Collection &collection, const QSet<QByteArray> &changedParts);
43
44 void recoverFromMultipleMergeCandidates(const PimItem::List &items, const Collection &collection);
45};
46
47} // namespace Server
48} // namespace Akonadi
Represents a collection of PIM items.
Definition collection.h:62
The handler interfaces describes an entity capable of handling an AkonadiIMAP command.
Definition handler.h:32
Handler for the X-AKAPPEND command.
bool parseStream() override
Parse and handle the IMAP message using the streaming parser.
Helper integration between Akonadi and Qt.
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Sun Feb 25 2024 18:38:51 by doxygen 1.10.0 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.