summaryrefslogtreecommitdiff
path: root/lang/cpp/src/data.h
diff options
context:
space:
mode:
Diffstat (limited to 'lang/cpp/src/data.h')
-rw-r--r--lang/cpp/src/data.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/lang/cpp/src/data.h b/lang/cpp/src/data.h
index 50bdf62..cc7906f 100644
--- a/lang/cpp/src/data.h
+++ b/lang/cpp/src/data.h
@@ -24,6 +24,7 @@
#define __GPGMEPP_DATA_H__
#include "global.h"
+#include "key.h"
#include <sys/types.h> // for size_t, off_t
#include <cstdio> // FILE
@@ -109,6 +110,10 @@ public:
ssize_t write(const void *buffer, size_t length);
off_t seek(off_t offset, int whence);
+ /** Try to parse the data to a key object using the
+ * Protocol proto. Returns an empty list on error.*/
+ std::vector<Key> toKeys(const Protocol proto = Protocol::OpenPGP) const;
+
class Private;
Private *impl()
{