Scorum
Public Member Functions | Public Attributes | List of all members
scorum::protocol::sign_state Struct Reference

#include <sign_state.hpp>

Public Member Functions

bool signed_by (const public_key_type &k)
 
bool check_authority (const std::string &id)
 
bool check_authority (const authority &au, uint32_t depth=0)
 
bool remove_unused_signatures ()
 
 sign_state (const flat_set< public_key_type > &sigs, const authority_getter &a, const flat_set< public_key_type > &keys)
 

Public Attributes

const authority_getterget_active
 
const flat_set< public_key_type > & available_keys
 
flat_map< public_key_type, bool > provided_signatures
 
flat_set< std::string > approved_by
 
uint32_t max_recursion = SCORUM_MAX_SIG_CHECK_DEPTH
 

Detailed Description

Definition at line 11 of file sign_state.hpp.

Constructor & Destructor Documentation

◆ sign_state()

scorum::protocol::sign_state::sign_state ( const flat_set< public_key_type > &  sigs,
const authority_getter a,
const flat_set< public_key_type > &  keys 
)

Definition at line 77 of file sign_state.cpp.

Member Function Documentation

◆ check_authority() [1/2]

bool scorum::protocol::sign_state::check_authority ( const authority au,
uint32_t  depth = 0 
)

Checks to see if we have signatures of the active authorites of the accounts specified in authority or the keys specified.

Definition at line 27 of file sign_state.cpp.

◆ check_authority() [2/2]

bool scorum::protocol::sign_state::check_authority ( const std::string &  id)

Definition at line 20 of file sign_state.cpp.

◆ remove_unused_signatures()

bool scorum::protocol::sign_state::remove_unused_signatures ( )

Definition at line 64 of file sign_state.cpp.

◆ signed_by()

bool scorum::protocol::sign_state::signed_by ( const public_key_type k)

returns true if we have a signature for this key or can produce a signature for this key, else returns false.

Definition at line 7 of file sign_state.cpp.

Member Data Documentation

◆ approved_by

flat_set<std::string> scorum::protocol::sign_state::approved_by

Definition at line 33 of file sign_state.hpp.

◆ available_keys

const flat_set<public_key_type>& scorum::protocol::sign_state::available_keys

Definition at line 30 of file sign_state.hpp.

◆ get_active

const authority_getter& scorum::protocol::sign_state::get_active

Definition at line 29 of file sign_state.hpp.

◆ max_recursion

uint32_t scorum::protocol::sign_state::max_recursion = SCORUM_MAX_SIG_CHECK_DEPTH

Definition at line 34 of file sign_state.hpp.

◆ provided_signatures

flat_map<public_key_type, bool> scorum::protocol::sign_state::provided_signatures

Definition at line 32 of file sign_state.hpp.


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