aboutsummaryrefslogtreecommitdiff
path: root/cc/key_manager.h
diff options
context:
space:
mode:
authorBartosz Przydatek <przydatek@google.com>2017-03-28 15:03:13 +0000
committerThai Duong <thaidn@google.com>2017-03-29 11:50:40 -0700
commit94925e322e9312f04330a23b060c6b483a1e9142 (patch)
treec41a4a3247a449361e55570b462dafb5324adfa5 /cc/key_manager.h
parenta631bebb8fb118e50ba0c58e6e6f6b86c2e5261f (diff)
downloadtink-94925e322e9312f04330a23b060c6b483a1e9142.tar.gz
Adding aux structures for primitive generation.
Change-Id: I51033bf71a0683b22717aa578042fa5d1f951e8e ORIGINAL_AUTHOR=Bartosz Przydatek <przydatek@google.com> GitOrigin-RevId: bd617b00f44a3c07b3de511f6dc6bb115d46fa01
Diffstat (limited to 'cc/key_manager.h')
-rw-r--r--cc/key_manager.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/cc/key_manager.h b/cc/key_manager.h
index 90c5aeb3b..1e65868ca 100644
--- a/cc/key_manager.h
+++ b/cc/key_manager.h
@@ -42,6 +42,10 @@ namespace tink {
template<class P>
class KeyManager {
public:
+ // Constructs an instance of P for the given 'key_data'.
+ virtual util::StatusOr<std::unique_ptr<P>>
+ GetPrimitive(const google::cloud::crypto::tink::KeyData& key_data) const = 0;
+
// Constructs an instance of P for the given 'key'.
virtual util::StatusOr<std::unique_ptr<P>>
GetPrimitive(const google::protobuf::MessageLite& key) const = 0;