Remove KActionCollection::setComponentData: this does not work on a KActionCollection...
[kdepim.git] / messagecomposer / signencryptjob.h
blobf4b04c9bf2e6f60f23dbee566def01244d366c9e
1 /*
2 Copyright (C) 2009 Klaralvdalens Datakonsult AB, a KDAB Group company, info@kdab.net
3 Copyright (c) 2009 Leo Franchi <lfranchi@kde.org>
5 This library is free software; you can redistribute it and/or modify it
6 under the terms of the GNU Library General Public License as published by
7 the Free Software Foundation; either version 2 of the License, or (at your
8 option) any later version.
10 This library is distributed in the hope that it will be useful, but WITHOUT
11 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
12 FITNESS FOR A PARTICULAR PURPOSE. See the GNU Library General Public
13 License for more details.
15 You should have received a copy of the GNU Library General Public License
16 along with this library; see the file COPYING.LIB. If not, write to the
17 Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
18 02110-1301, USA.
21 #ifndef MESSAGECOMPOSER_SIGNENCRYPTJOB_H
22 #define MESSAGECOMPOSER_SIGNENCRYPTJOB_H
24 #include "abstractencryptjob.h"
25 #include "contentjobbase.h"
26 #include "infopart.h"
27 #include "messagecomposer_export.h"
28 #include "kleo/enum.h"
30 #include <gpgme++/key.h>
31 #include <vector>
33 namespace KMime {
34 class Content;
38 namespace GpgME {
39 class Error;
43 namespace Message {
45 class SignEncryptJobPrivate;
47 /**
48 Signs and encrypt the contents of a message.
49 Used when doing inline pgp sign+encrypt
51 class MESSAGECOMPOSER_EXPORT SignEncryptJob : public ContentJobBase, public AbstractEncryptJob
53 Q_OBJECT
55 public:
56 SignEncryptJob( QObject *parent = 0 );
57 virtual ~SignEncryptJob();
59 void setContent( KMime::Content* content );
60 void setCryptoMessageFormat( Kleo::CryptoMessageFormat format);
61 void setSigningKeys( std::vector<GpgME::Key>& signers );
63 void setEncryptionKeys( std::vector<GpgME::Key> keys );
64 void setRecipients( QStringList rec );
66 std::vector<GpgME::Key> encryptionKeys();
67 QStringList recipients();
69 KMime::Content* origContent();
71 protected Q_SLOTS:
72 //virtual void doStart();
73 virtual void process();
75 private:
76 Q_DECLARE_PRIVATE( SignEncryptJob )
81 #endif