Wire Sysio Wire Sysion 1.0.0
Loading...
Searching...
No Matches
sysio::chain::protocol_feature_activation Struct Reference

#include <protocol_feature_activation.hpp>

Inheritance diagram for sysio::chain::protocol_feature_activation:
Collaboration diagram for sysio::chain::protocol_feature_activation:

Public Member Functions

 protocol_feature_activation ()=default
 
 protocol_feature_activation (const vector< digest_type > &pf)
 
 protocol_feature_activation (vector< digest_type > &&pf)
 
 protocol_feature_activation (const protocol_feature_activation &)=default
 
 protocol_feature_activation (protocol_feature_activation &&)=default
 
protocol_feature_activationoperator= (protocol_feature_activation &&)=default
 
protocol_feature_activationoperator= (const protocol_feature_activation &)=default
 
void reflector_init ()
 

Static Public Member Functions

static constexpr uint16_t extension_id ()
 
static constexpr bool enforce_unique ()
 

Public Attributes

vector< digest_typeprotocol_features
 

Detailed Description

Definition at line 7 of file protocol_feature_activation.hpp.

Constructor & Destructor Documentation

◆ protocol_feature_activation() [1/5]

sysio::chain::protocol_feature_activation::protocol_feature_activation ( )
default

◆ protocol_feature_activation() [2/5]

sysio::chain::protocol_feature_activation::protocol_feature_activation ( const vector< digest_type > & pf)
inline

Definition at line 13 of file protocol_feature_activation.hpp.

◆ protocol_feature_activation() [3/5]

sysio::chain::protocol_feature_activation::protocol_feature_activation ( vector< digest_type > && pf)
inline

Definition at line 17 of file protocol_feature_activation.hpp.

18 :protocol_features( std::move(pf) )
19 {}

◆ protocol_feature_activation() [4/5]

sysio::chain::protocol_feature_activation::protocol_feature_activation ( const protocol_feature_activation & )
default

◆ protocol_feature_activation() [5/5]

sysio::chain::protocol_feature_activation::protocol_feature_activation ( protocol_feature_activation && )
default

Member Function Documentation

◆ enforce_unique()

static constexpr bool sysio::chain::protocol_feature_activation::enforce_unique ( )
inlinestaticconstexpr

Definition at line 9 of file protocol_feature_activation.hpp.

9{ return true; }

◆ extension_id()

static constexpr uint16_t sysio::chain::protocol_feature_activation::extension_id ( )
inlinestaticconstexpr

Definition at line 8 of file protocol_feature_activation.hpp.

8{ return 0; }
Here is the caller graph for this function:

◆ operator=() [1/2]

protocol_feature_activation & sysio::chain::protocol_feature_activation::operator= ( const protocol_feature_activation & )
default

◆ operator=() [2/2]

protocol_feature_activation & sysio::chain::protocol_feature_activation::operator= ( protocol_feature_activation && )
default

◆ reflector_init()

void sysio::chain::protocol_feature_activation::reflector_init ( )

Definition at line 8 of file protocol_feature_activation.cpp.

8 {
10 "protocol_feature_activation expects FC to support reflector_init" );
11
12
13 SYS_ASSERT( protocol_features.size() > 0, ill_formed_protocol_feature_activation,
14 "Protocol feature activation extension must have at least one protocol feature digest",
15 );
16
17 set<digest_type> s;
18
19 for( const auto& d : protocol_features ) {
20 auto res = s.insert( d );
21 SYS_ASSERT( res.second, ill_formed_protocol_feature_activation,
22 "Protocol feature digest ${d} was repeated in the protocol feature activation extension",
23 ("d", d)
24 );
25 }
26 }
#define SYS_ASSERT(expr, exc_type, FORMAT,...)
Definition exceptions.hpp:7
constexpr bool has_feature_reflector_init_on_unpacked_reflected_types
Definition raw.hpp:440
char * s

Member Data Documentation

◆ protocol_features

vector<digest_type> sysio::chain::protocol_feature_activation::protocol_features

Definition at line 29 of file protocol_feature_activation.hpp.


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