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

kgpg

  • sources
  • kde-4.14
  • kdeutils
  • kgpg
  • transactions
kgpggeneratekey.h
Go to the documentation of this file.
1 /*
2  * Copyright (C) 2008,2009,2012,2013 Rolf Eike Beer <kde@opensource.sf-tec.de>
3  */
4 
5 /***************************************************************************
6  * *
7  * This program is free software; you can redistribute it and/or modify *
8  * it under the terms of the GNU General Public License as published by *
9  * the Free Software Foundation; either version 2 of the License, or *
10  * (at your option) any later version. *
11  * *
12  ***************************************************************************/
13 
14 #ifndef KGPGGENERATEKEY_H
15 #define KGPGGENERATEKEY_H
16 
17 #include "kgpgtransaction.h"
18 
19 #include "core/kgpgkey.h"
20 
21 #include <QObject>
22 
23 class QString;
24 
28 class KGpgGenerateKey: public KGpgTransaction {
29  Q_OBJECT
30 
31  Q_DISABLE_COPY(KGpgGenerateKey)
32  KGpgGenerateKey(); // = delete C++0x
33 public:
34  enum ts_generatekey {
35  TS_INVALID_NAME = TS_COMMON_END + 1
36  };
37 
50  KGpgGenerateKey(QObject *parent, const QString &name, const QString &email, const QString &comment,
51  const KgpgCore::KgpgKeyAlgo &algorithm, const uint size, const unsigned int expire = 0,
52  const char expireunit = 'd', const KgpgCore::KgpgSubKeyType capabilities = 0);
53  virtual ~KGpgGenerateKey();
54 
55  QString getName() const;
56  QString getEmail() const;
57 
61  QString getFingerprint() const;
62 
69  QString gpgErrorMessage() const;
70 
71 protected:
72  virtual bool preStart();
73  virtual void postStart();
74  virtual bool nextLine(const QString &line);
75  virtual void finish();
76  virtual void newPassphraseEntered();
77 
78 private:
79  const QString m_name;
80  const QString m_email;
81  const QString m_comment;
82  const KgpgCore::KgpgKeyAlgo m_algorithm;
83  const KgpgCore::KgpgSubKeyType m_capabilities;
84  const unsigned int m_size;
85  const unsigned int m_expire;
86  const unsigned int m_expireunit;
87  QString m_fingerprint;
88  QString m_errorOutput;
89 };
90 
91 #endif // KGPGGENERATEKEY_H
KGpgGenerateKey::getFingerprint
QString getFingerprint() const
return the fingerprint of the generated key
Definition: kgpggeneratekey.cpp:255
kgpgtransaction.h
KGpgGenerateKey::getEmail
QString getEmail() const
Definition: kgpggeneratekey.cpp:249
KGpgGenerateKey::nextLine
virtual bool nextLine(const QString &line)
Called for every line the gpg process writes.
Definition: kgpggeneratekey.cpp:149
kgpgkey.h
KGpgGenerateKey::ts_generatekey
ts_generatekey
Definition: kgpggeneratekey.h:34
QObject::name
const char * name() const
QObject
KGpgGenerateKey::newPassphraseEntered
virtual void newPassphraseEntered()
called when the user entered a new passphrase
Definition: kgpggeneratekey.cpp:236
KGpgGenerateKey
generate a new key pair
Definition: kgpggeneratekey.h:28
KGpgGenerateKey::finish
virtual void finish()
Called when the gpg process finishes.
Definition: kgpggeneratekey.cpp:201
KGpgGenerateKey::gpgErrorMessage
QString gpgErrorMessage() const
get error output of GnuPG
Definition: kgpggeneratekey.cpp:261
KGpgGenerateKey::postStart
virtual void postStart()
Called when the gpg process is up and running.
Definition: kgpggeneratekey.cpp:70
QString
KGpgGenerateKey::getName
QString getName() const
Definition: kgpggeneratekey.cpp:243
KGpgGenerateKey::~KGpgGenerateKey
virtual ~KGpgGenerateKey()
Definition: kgpggeneratekey.cpp:48
KGpgTransaction::TS_COMMON_END
placeholder for return values of derived classes
Definition: kgpgtransaction.h:66
KGpgTransaction
Process one GnuPG operation.
Definition: kgpgtransaction.h:44
QObject::parent
QObject * parent() const
KGpgGenerateKey::TS_INVALID_NAME
the owners name is not accepted by GnuPG
Definition: kgpggeneratekey.h:35
KGpgGenerateKey::preStart
virtual bool preStart()
Called before the gpg process is started.
Definition: kgpggeneratekey.cpp:53
This file is part of the KDE documentation.
Documentation copyright © 1996-2020 The KDE developers.
Generated on Mon Jun 22 2020 13:42:08 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.

kgpg

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

kdeutils API Reference

Skip menu "kdeutils API Reference"
  • ark
  • filelight
  • kcalc
  • kcharselect
  • kdf
  • kfloppy
  • kgpg
  • ktimer
  • kwallet
  • sweeper

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