Kagome
Polkadot Runtime Engine in C++17
kagome::runtime::SessionKeysApiImpl Class Referencefinal

#include <session_keys_api.hpp>

Inheritance diagram for kagome::runtime::SessionKeysApiImpl:
Collaboration diagram for kagome::runtime::SessionKeysApiImpl:

Public Member Functions

 SessionKeysApiImpl (std::shared_ptr< Executor > executor)
 
outcome::result< common::Buffergenerate_session_keys (const primitives::BlockHash &block_hash, std::optional< common::Buffer > seed) override
 Generate a set of session keys with optionally using the given seed. The keys should be stored within the keystore exposed via runtime externalities. More...
 
outcome::result< std::vector< std::pair< crypto::KeyTypeId, common::Buffer > > > decode_session_keys (const primitives::BlockHash &block_hash, common::BufferConstRef encoded) const override
 Decode the given public session keys. More...
 
- Public Member Functions inherited from kagome::runtime::SessionKeysApi
virtual ~SessionKeysApi ()=default
 

Private Attributes

std::shared_ptr< Executorexecutor_
 

Detailed Description

Definition at line 15 of file session_keys_api.hpp.

Constructor & Destructor Documentation

kagome::runtime::SessionKeysApiImpl::SessionKeysApiImpl ( std::shared_ptr< Executor executor)
explicit

Definition at line 12 of file session_keys_api.cpp.

Member Function Documentation

outcome::result< std::vector< std::pair< crypto::KeyTypeId, common::Buffer > > > kagome::runtime::SessionKeysApiImpl::decode_session_keys ( const primitives::BlockHash block_hash,
common::BufferConstRef  encoded 
) const
overridevirtual

Decode the given public session keys.

Returns
the list of public raw public keys + key type.

Implements kagome::runtime::SessionKeysApi.

Definition at line 25 of file session_keys_api.cpp.

outcome::result< common::Buffer > kagome::runtime::SessionKeysApiImpl::generate_session_keys ( const primitives::BlockHash block_hash,
std::optional< common::Buffer seed 
)
overridevirtual

Generate a set of session keys with optionally using the given seed. The keys should be stored within the keystore exposed via runtime externalities.

Parameters
seed- optional seed, which needs to be a valid utf8 string.
Returns
the concatenated SCALE encoded public keys.

Implements kagome::runtime::SessionKeysApi.

Definition at line 17 of file session_keys_api.cpp.

Member Data Documentation

std::shared_ptr<Executor> kagome::runtime::SessionKeysApiImpl::executor_
private

Definition at line 28 of file session_keys_api.hpp.


The documentation for this class was generated from the following files: