• Skip to content
  • Skip to link menu
KDE API Reference
  • KDE API Reference
  • kdepim API Reference
  • KDE Home
  • Contact Us
 

messageviewer

  • sources
  • kde-4.14
  • kdepim
  • messageviewer
  • viewer
  • memento
verifydetachedbodypartmemento.h
Go to the documentation of this file.
1 /*
2  Copyright (c) 2014-2015 Montel Laurent <montel@kde.org>
3 
4  This program is free software; you can redistribute it and/or modify it
5  under the terms of the GNU General Public License, version 2, as
6  published by the Free Software Foundation.
7 
8  This program is distributed in the hope that it will be useful, but
9  WITHOUT ANY WARRANTY; without even the implied warranty of
10  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
11  General Public License for more details.
12 
13  You should have received a copy of the GNU General Public License along
14  with this program; if not, write to the Free Software Foundation, Inc.,
15  51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
16 */
17 
18 #ifndef VERIFYDETACHEDBODYPARTMEMENTO_H
19 #define VERIFYDETACHEDBODYPARTMEMENTO_H
20 
21 #include "cryptobodypartmemento.h"
22 #include <gpgme++/verificationresult.h>
23 #include <gpgme++/decryptionresult.h>
24 #include <gpgme++/key.h>
25 
26 #include <QObject>
27 #include <QString>
28 #include <QPointer>
29 
30 #include "interfaces/bodypart.h"
31 #include "viewer/viewer.h"
32 
33 namespace Kleo {
34 class VerifyDetachedJob;
35 class KeyListJob;
36 }
37 
38 class QStringList;
39 
40 namespace MessageViewer {
41 
42 class VerifyDetachedBodyPartMemento
43  : public CryptoBodyPartMemento
44 {
45  Q_OBJECT
46 public:
47  VerifyDetachedBodyPartMemento( Kleo::VerifyDetachedJob * job,
48  Kleo::KeyListJob * klj,
49  const QByteArray & signature,
50  const QByteArray & plainText );
51  ~VerifyDetachedBodyPartMemento();
52 
53  bool start();
54  void exec();
55 
56  const GpgME::VerificationResult & verifyResult() const { return m_vr; }
57  const GpgME::Key & signingKey() const { return m_key; }
58 
59 private slots:
60  void slotResult( const GpgME::VerificationResult & vr );
61  void slotKeyListJobDone();
62  void slotNextKey( const GpgME::Key & );
63 
64 private:
65  void saveResult( const GpgME::VerificationResult & );
66  bool canStartKeyListJob() const;
67  QStringList keyListPattern() const;
68  bool startKeyListJob();
69 private:
70  // input:
71  const QByteArray m_signature;
72  const QByteArray m_plainText;
73  QPointer<Kleo::VerifyDetachedJob> m_job;
74  QPointer<Kleo::KeyListJob> m_keylistjob;
75  // output:
76  GpgME::VerificationResult m_vr;
77  GpgME::Key m_key;
78 };
79 
80 }
81 
82 #endif // VERIFYDETACHEDBODYPARTMEMENTO_H
MessageViewer::VerifyDetachedBodyPartMemento::verifyResult
const GpgME::VerificationResult & verifyResult() const
Definition: verifydetachedbodypartmemento.h:56
viewer.h
MessageViewer::VerifyDetachedBodyPartMemento
Definition: verifydetachedbodypartmemento.h:42
QByteArray
MessageViewer::VerifyDetachedBodyPartMemento::signingKey
const GpgME::Key & signingKey() const
Definition: verifydetachedbodypartmemento.h:57
QPointer< Kleo::VerifyDetachedJob >
MessageViewer::VerifyDetachedBodyPartMemento::exec
void exec()
Definition: verifydetachedbodypartmemento.cpp:74
MessageViewer::VerifyDetachedBodyPartMemento::VerifyDetachedBodyPartMemento
VerifyDetachedBodyPartMemento(Kleo::VerifyDetachedJob *job, Kleo::KeyListJob *klj, const QByteArray &signature, const QByteArray &plainText)
Definition: verifydetachedbodypartmemento.cpp:36
bodypart.h
QStringList
MessageViewer::VerifyDetachedBodyPartMemento::start
bool start()
Definition: verifydetachedbodypartmemento.cpp:56
cryptobodypartmemento.h
MessageViewer::CryptoBodyPartMemento
Definition: cryptobodypartmemento.h:33
MessageViewer::VerifyDetachedBodyPartMemento::~VerifyDetachedBodyPartMemento
~VerifyDetachedBodyPartMemento()
Definition: verifydetachedbodypartmemento.cpp:49
This file is part of the KDE documentation.
Documentation copyright © 1996-2020 The KDE developers.
Generated on Mon Jun 22 2020 13:32:45 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.

messageviewer

Skip menu "messageviewer"
  • Main Page
  • Namespace List
  • Namespace Members
  • Alphabetical List
  • Class List
  • Class Hierarchy
  • Class Members
  • File List
  • File Members
  • Related Pages

kdepim API Reference

Skip menu "kdepim API Reference"
  • akonadi_next
  • akregator
  • blogilo
  • calendarsupport
  • console
  •   kabcclient
  •   konsolekalendar
  • kaddressbook
  • kalarm
  •   lib
  • kdgantt2
  • kjots
  • kleopatra
  • kmail
  • knode
  • knotes
  • kontact
  • korgac
  • korganizer
  • ktimetracker
  • libkdepim
  • libkleo
  • libkpgp
  • mailcommon
  • messagelist
  • messageviewer
  • pimprint

Search



Report problems with this website to our bug tracking system.
Contact the specific authors with questions and comments about the page contents.

KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal