• 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
  • job
kleojobexecutor.h
Go to the documentation of this file.
1 /*
2  Copyright (c) 2008 Volker Krause <vkrause@kde.org>
3 
4  This program is free software; you can redistribute it and/or modify
5  it under the terms of the GNU General Public License as published by
6  the Free Software Foundation; either version 2 of the License, or
7  (at your option) any later version.
8 
9  This program is distributed in the hope that it will be useful,
10  but WITHOUT ANY WARRANTY; without even the implied warranty of
11  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12  GNU General Public License for more details.
13 
14  You should have received a copy of the GNU General Public License
15  along with this program; if not, write to the Free Software
16  Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
17 */
18 
19 #ifndef _MESSAGEVIEWER_KLEOJOBEXECUTOR_H
20 #define _MESSAGEVIEWER_KLEOJOBEXECUTOR_H
21 
22 #include <gpgme++/decryptionresult.h>
23 #include <gpgme++/importresult.h>
24 #include <gpgme++/verificationresult.h>
25 
26 #include <QtCore/QObject>
27 
28 #include <utility>
29 
30 class QEventLoop;
31 
32 namespace Kleo {
33 class DecryptVerifyJob;
34 class ImportJob;
35 class VerifyDetachedJob;
36 class VerifyOpaqueJob;
37 }
38 
39 namespace MessageViewer {
40 
44 class KleoJobExecutor : public QObject
45 {
46  Q_OBJECT
47 public:
48  explicit KleoJobExecutor( QObject *parent = 0 );
49 
50  GpgME::VerificationResult exec( Kleo::VerifyDetachedJob* job,
51  const QByteArray &signature,
52  const QByteArray &signedData );
53  GpgME::VerificationResult exec( Kleo::VerifyOpaqueJob* job,
54  const QByteArray &signedData,
55  QByteArray &plainText );
56  std::pair<GpgME::DecryptionResult,GpgME::VerificationResult> exec( Kleo::DecryptVerifyJob *job,
57  const QByteArray &cipherText,
58  QByteArray &plainText );
59  GpgME::ImportResult exec( Kleo::ImportJob* job, const QByteArray &certData );
60 
61  GpgME::Error auditLogError() const { return mAuditLogError; }
62  QString auditLogAsHtml() const;
63 
64 private slots:
65  void verificationResult( const GpgME::VerificationResult &result );
66  void verificationResult( const GpgME::VerificationResult &result, const QByteArray &plainText );
67  void decryptResult( const GpgME::DecryptionResult & decryptionresult,
68  const GpgME::VerificationResult & verificationresult,
69  const QByteArray & plainText );
70  void importResult( const GpgME::ImportResult &result );
71 
72 private:
73  QEventLoop *mEventLoop;
74  GpgME::VerificationResult mVerificationResult;
75  GpgME::DecryptionResult mDecryptResult;
76  GpgME::ImportResult mImportResult;
77  QByteArray mData;
78  GpgME::Error mAuditLogError;
79  QString mAuditLog;
80 };
81 
82 }
83 
84 #endif
QEventLoop
QByteArray
MessageViewer::KleoJobExecutor::auditLogAsHtml
QString auditLogAsHtml() const
Definition: kleojobexecutor.cpp:158
MessageViewer::KleoJobExecutor::exec
GpgME::VerificationResult exec(Kleo::VerifyDetachedJob *job, const QByteArray &signature, const QByteArray &signedData)
Definition: kleojobexecutor.cpp:47
QObject
MessageViewer::KleoJobExecutor::KleoJobExecutor
KleoJobExecutor(QObject *parent=0)
Definition: kleojobexecutor.cpp:40
QString
MessageViewer::KleoJobExecutor
Helper class for synchronous execution of Kleo crypto jobs.
Definition: kleojobexecutor.h:44
MessageViewer::KleoJobExecutor::auditLogError
GpgME::Error auditLogError() const
Definition: kleojobexecutor.h:61
QObject::parent
QObject * parent() const
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