Akonadi
12 #include <private/tristate_p.h>
15 #include <QReadWriteLock>
26 class CollectionTreeCache :
public AkThread
35 explicit Node(
const Collection &query);
39 void appendChild(
Node *child);
40 void removeChild(
Node *child);
42 Node *parent =
nullptr;
47 Collection collection;
51 explicit CollectionTreeCache();
52 ~CollectionTreeCache()
override;
55 retrieveCollections(
const Scope &scope,
int depth,
int ancestorDepth,
const QString &resource =
QString(), CommandContext *context =
nullptr)
const;
58 void collectionAdded(
const Collection &col);
59 void collectionChanged(
const Collection &col);
60 void collectionMoved(
const Collection &col);
61 void collectionRemoved(
const Collection &col);
69 template<
typename Predicate>
Node *findNode(
Node *root, Predicate pred)
const;
76 Node *mRoot =
nullptr;
82 template<
typename Predicate> CollectionTreeCache::Node *CollectionTreeCache::findNode(
Node *root, Predicate pred)
const
87 toVisit.
reserve(mNodeLookup.size() / 4);
94 for (
auto child : std::as_const(node->children)) {
void prepend(const T &value)
bool isEmpty() const const
const QList< QKeySequence > & quit()
Helper integration between Akonadi and Qt.
This file is part of the KDE documentation.
Documentation copyright © 1996-2022 The KDE developers.
Generated on Sat Jul 2 2022 06:41:47 by
doxygen 1.8.17 written
by
Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.