aboutsummaryrefslogtreecommitdiffstats
path: root/include/gpg/result_analyse/SignResultAnalyse.h
diff options
context:
space:
mode:
authorSaturneric <[email protected]>2021-06-08 15:18:34 +0000
committerSaturneric <[email protected]>2021-06-08 15:18:34 +0000
commit2df942ceef5ba2dbcc36b0ce820f791900e1e94c (patch)
treed2a4464caef7c55d6ddd95f114382ab2b6b7c1f8 /include/gpg/result_analyse/SignResultAnalyse.h
parentAdd encryption and signature function. (diff)
downloadGpgFrontend-2df942ceef5ba2dbcc36b0ce820f791900e1e94c.tar.gz
GpgFrontend-2df942ceef5ba2dbcc36b0ce820f791900e1e94c.zip
Add Some file.
Diffstat (limited to '')
-rw-r--r--include/gpg/result_analyse/SignResultAnalyse.h31
1 files changed, 31 insertions, 0 deletions
diff --git a/include/gpg/result_analyse/SignResultAnalyse.h b/include/gpg/result_analyse/SignResultAnalyse.h
new file mode 100644
index 00000000..933089bf
--- /dev/null
+++ b/include/gpg/result_analyse/SignResultAnalyse.h
@@ -0,0 +1,31 @@
+//
+// Created by eric on 2021/6/8.
+//
+
+#ifndef GPGFRONTEND_SIGNRESULTANALYSE_H
+#define GPGFRONTEND_SIGNRESULTANALYSE_H
+
+#include "GpgFrontend.h"
+
+class SignResultAnalyse {
+public:
+ SignResultAnalyse(gpgme_sign_result_t result);
+
+ [[nodiscard]] const QString &getResultReport() const;
+
+ [[nodiscard]] int getStatus() const;
+
+private:
+ QString resultText;
+ QTextStream stream{&resultText};
+
+ int status = 1;
+
+ void setStatus(int mStatus) {
+ if(mStatus < status) status = mStatus;
+ }
+
+
+};
+
+#endif //GPGFRONTEND_SIGNRESULTANALYSE_H