hyperledger/iroha
Iroha - A simple, decentralized ledger http://iroha.tech
iroha::ametsuchi::QueryExecutorBase Class Referenceabstract

#include "query_executor_base.hpp"

Inheritance diagram for iroha::ametsuchi::QueryExecutorBase:
Inheritance graph
Collaboration diagram for iroha::ametsuchi::QueryExecutorBase:
Collaboration graph

Public Member Functions

 QueryExecutorBase (std::shared_ptr< shared_model::interface::QueryResponseFactory > response_factory, std::shared_ptr< SpecificQueryExecutor > specific_query_executor, logger::LoggerPtr log)
 
QueryExecutorResult validateAndExecute (const shared_model::interface::Query &query, const bool validate_signatories) override
 
bool validate (const shared_model::interface::BlocksQuery &query, const bool validate_signatories) override
 
virtual bool validateSignatures (const shared_model::interface::Query &query)=0
 
virtual bool validateSignatures (const shared_model::interface::BlocksQuery &query)=0
 
- Public Member Functions inherited from iroha::ametsuchi::QueryExecutor
virtual ~QueryExecutor ()=default
 

Protected Attributes

std::shared_ptr< SpecificQueryExecutorspecific_query_executor_
 
std::shared_ptr< shared_model::interface::QueryResponseFactoryquery_response_factory_
 
logger::LoggerPtr log_
 

Constructor & Destructor Documentation

◆ QueryExecutorBase()

iroha::ametsuchi::QueryExecutorBase::QueryExecutorBase ( std::shared_ptr< shared_model::interface::QueryResponseFactory response_factory,
std::shared_ptr< SpecificQueryExecutor specific_query_executor,
logger::LoggerPtr  log 
)

Member Function Documentation

◆ validate()

bool iroha::ametsuchi::QueryExecutorBase::validate ( const shared_model::interface::BlocksQuery query,
const bool  validate_signatories 
)
overridevirtual

Perform BlocksQuery validation

Parameters
queryto validate
validate_signatories- if signatories should be validated
Returns
true if valid, false otherwise

Implements iroha::ametsuchi::QueryExecutor.

Here is the call graph for this function:

◆ validateAndExecute()

QueryExecutorResult iroha::ametsuchi::QueryExecutorBase::validateAndExecute ( const shared_model::interface::Query query,
const bool  validate_signatories 
)
overridevirtual

Execute and validate query.

Parameters
queryto validate and execute
validate_signatories- if signatories should be validated
Returns
pointer to query response

Implements iroha::ametsuchi::QueryExecutor.

Here is the call graph for this function:

◆ validateSignatures() [1/2]

virtual bool iroha::ametsuchi::QueryExecutorBase::validateSignatures ( const shared_model::interface::Query query)
pure virtual

Implemented in iroha::ametsuchi::PostgresQueryExecutor, and iroha::ametsuchi::RocksDbQueryExecutor.

Here is the caller graph for this function:

◆ validateSignatures() [2/2]

virtual bool iroha::ametsuchi::QueryExecutorBase::validateSignatures ( const shared_model::interface::BlocksQuery query)
pure virtual

Member Data Documentation

◆ log_

logger::LoggerPtr iroha::ametsuchi::QueryExecutorBase::log_
protected

◆ query_response_factory_

std::shared_ptr<shared_model::interface::QueryResponseFactory> iroha::ametsuchi::QueryExecutorBase::query_response_factory_
protected

◆ specific_query_executor_

std::shared_ptr<SpecificQueryExecutor> iroha::ametsuchi::QueryExecutorBase::specific_query_executor_
protected

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