Messagelib

keycachememento.h
1 /*
2  SPDX-FileCopyrightText: 2023 Daniel Vr├ítil <dvratil@kde.org>
3 
4  SPDX-License-Identifier: GPL-2.0-or-later
5 */
6 
7 #pragma once
8 
9 #include "cryptobodypartmemento.h"
10 #include <Libkleo/KeyCache>
11 
12 #include <QString>
13 
14 namespace MimeTreeParser
15 {
16 class KeyCacheMemento : public CryptoBodyPartMemento
17 {
18  Q_OBJECT
19 public:
20  explicit KeyCacheMemento(const std::shared_ptr<Kleo::KeyCache> &keyCache, GpgME::Protocol protocol);
21  ~KeyCacheMemento() override;
22 
23  [[nodiscard]] bool start() override;
24  void exec() override;
25 
26  std::shared_ptr<const Kleo::KeyCache> keyCache() const
27  {
28  return m_keyCache;
29  }
30 
31 private Q_SLOTS:
32  void slotKeyCacheInitialized();
33 
34 private:
35  std::shared_ptr<Kleo::KeyCache> m_keyCache;
36  const GpgME::Protocol m_protocol;
37 };
38 
39 } // namespace MimeTreeParser
Q_OBJECTQ_OBJECT
Q_SLOTSQ_SLOTS
Q_SCRIPTABLE Q_NOREPLY void start()
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Thu Feb 15 2024 03:55:20 by doxygen 1.8.17 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.