hyperledger/iroha
Iroha - A simple, decentralized ledger http://iroha.tech
shared_model::proto::ProtoCommonObjectsFactory< Validator > Class Template Reference

#include "proto_common_objects_factory.hpp"

Inheritance diagram for shared_model::proto::ProtoCommonObjectsFactory< Validator >:
Inheritance graph
Collaboration diagram for shared_model::proto::ProtoCommonObjectsFactory< Validator >:
Collaboration graph

Public Member Functions

 ProtoCommonObjectsFactory (std::shared_ptr< validation::ValidatorsConfig > config)
 
FactoryResult< std::unique_ptr< interface::Peer > > createPeer (const interface::types::AddressType &address, const interface::types::PubkeyType &public_key) override
 
FactoryResult< std::unique_ptr< interface::Account > > createAccount (const interface::types::AccountIdType &account_id, const interface::types::DomainIdType &domain_id, interface::types::QuorumType quorum, const interface::types::JsonType &jsonData) override
 
FactoryResult< std::unique_ptr< interface::AccountAsset > > createAccountAsset (const interface::types::AccountIdType &account_id, const interface::types::AssetIdType &asset_id, const interface::Amount &balance) override
 
FactoryResult< std::unique_ptr< interface::Asset > > createAsset (const interface::types::AssetIdType &asset_id, const interface::types::DomainIdType &domain_id, interface::types::PrecisionType precision) override
 
FactoryResult< std::unique_ptr< interface::Domain > > createDomain (const interface::types::DomainIdType &domain_id, const interface::types::RoleIdType &default_role) override
 
FactoryResult< std::unique_ptr< interface::Signature > > createSignature (const interface::types::PubkeyType &key, const interface::Signature::SignedType &signed_data) override
 
- Public Member Functions inherited from shared_model::interface::CommonObjectsFactory
virtual ~CommonObjectsFactory ()=default
 

Additional Inherited Members

- Public Types inherited from shared_model::interface::CommonObjectsFactory
template<typename T >
using FactoryResult = iroha::expected::Result< T, std::string >
 

Detailed Description

template<typename Validator>
class shared_model::proto::ProtoCommonObjectsFactory< Validator >

ProtoCommonObjectsFactory constructs protobuf-based objects. It performs stateless validation with provided validator

Template Parameters
Validator

Constructor & Destructor Documentation

template<typename Validator >
shared_model::proto::ProtoCommonObjectsFactory< Validator >::ProtoCommonObjectsFactory ( std::shared_ptr< validation::ValidatorsConfig config)
inline

Member Function Documentation

template<typename Validator >
FactoryResult<std::unique_ptr<interface::Account> > shared_model::proto::ProtoCommonObjectsFactory< Validator >::createAccount ( const interface::types::AccountIdType account_id,
const interface::types::DomainIdType domain_id,
interface::types::QuorumType  quorum,
const interface::types::JsonType jsonData 
)
inlineoverridevirtual

Create account instance

Implements shared_model::interface::CommonObjectsFactory.

template<typename Validator >
FactoryResult<std::unique_ptr<interface::AccountAsset> > shared_model::proto::ProtoCommonObjectsFactory< Validator >::createAccountAsset ( const interface::types::AccountIdType account_id,
const interface::types::AssetIdType asset_id,
const interface::Amount balance 
)
inlineoverridevirtual

Create account asset instance

Implements shared_model::interface::CommonObjectsFactory.

Here is the call graph for this function:

template<typename Validator >
FactoryResult<std::unique_ptr<interface::Asset> > shared_model::proto::ProtoCommonObjectsFactory< Validator >::createAsset ( const interface::types::AssetIdType asset_id,
const interface::types::DomainIdType domain_id,
interface::types::PrecisionType  precision 
)
inlineoverridevirtual

Create asset instance

Implements shared_model::interface::CommonObjectsFactory.

template<typename Validator >
FactoryResult<std::unique_ptr<interface::Domain> > shared_model::proto::ProtoCommonObjectsFactory< Validator >::createDomain ( const interface::types::DomainIdType domain_id,
const interface::types::RoleIdType default_role 
)
inlineoverridevirtual

Create domain instance

Implements shared_model::interface::CommonObjectsFactory.

template<typename Validator >
FactoryResult<std::unique_ptr<interface::Peer> > shared_model::proto::ProtoCommonObjectsFactory< Validator >::createPeer ( const interface::types::AddressType address,
const interface::types::PubkeyType public_key 
)
inlineoverridevirtual

Create peer instance

Implements shared_model::interface::CommonObjectsFactory.

Here is the call graph for this function:

template<typename Validator >
FactoryResult<std::unique_ptr<interface::Signature> > shared_model::proto::ProtoCommonObjectsFactory< Validator >::createSignature ( const interface::types::PubkeyType key,
const interface::Signature::SignedType signed_data 
)
inlineoverridevirtual

Create signature instance

Implements shared_model::interface::CommonObjectsFactory.

Here is the call graph for this function:


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