GpgFrontend Project
A Free, Powerful, Easy-to-Use, Compact, Cross-Platform, and Installation-Free OpenPGP(pgp) Crypto Tool.
GpgKeyGetter.h
1 
29 #pragma once
30 
31 #include "core/function/basic/GpgFunctionObject.h"
32 #include "core/typedef/GpgTypedef.h"
33 
34 namespace GpgFrontend {
35 
40 class GPGFRONTEND_CORE_EXPORT GpgKeyGetter
41  : public SingletonFunctionObject<GpgKeyGetter> {
42  public:
48  explicit GpgKeyGetter(int channel = kGpgFrontendDefaultChannel);
49 
55 
62  auto GetKey(const QString& key_id, bool use_cache = true) -> GpgKey;
63 
70  auto GetKeys(const KeyIdArgsListPtr& key_ids) -> KeyListPtr;
71 
78  auto GetPubkey(const QString& key_id, bool use_cache = true) -> GpgKey;
79 
85  auto FetchKey() -> KeyLinkListPtr;
86 
91  auto FlushKeyCache() -> bool;
92 
99  auto GetKeysCopy(const KeyListPtr& keys) -> KeyListPtr;
100 
107  auto GetKeysCopy(const KeyLinkListPtr& keys) -> KeyLinkListPtr;
108 
109  private:
110  class Impl;
111  SecureUniquePtr<Impl> p_;
112 };
113 } // namespace GpgFrontend
Definition: GpgKeyGetter.cpp:42
Definition: GpgKeyGetter.h:41
~GpgKeyGetter()
Destroy the Gpg Key Getter object.
Definition: GpgKey.h:40
Definition: GpgFunctionObject.h:58
Definition: app.cpp:39