hyperledger/iroha
Iroha - A simple, decentralized ledger http://iroha.tech
tx_executor.hpp
Go to the documentation of this file.
1 
6 #ifndef IROHA_AMETSUCHI_TX_EXECUTOR_HPP
7 #define IROHA_AMETSUCHI_TX_EXECUTOR_HPP
8 
10 #include "common/result.hpp"
11 
12 namespace shared_model {
13  namespace interface {
14  class Command;
15  class Transaction;
16  } // namespace interface
17 } // namespace shared_model
18 
19 namespace iroha {
20  namespace ametsuchi {
21 
24  size_t command_index;
25  };
26 
28  public:
29  explicit TransactionExecutor(
30  std::shared_ptr<CommandExecutor> command_executor);
31 
32  iroha::expected::Result<void, TxExecutionError> execute(
33  const shared_model::interface::Transaction &transaction,
34  bool do_validation) const;
35 
36  private:
37  std::shared_ptr<CommandExecutor> command_executor_;
38  };
39 
40  } // namespace ametsuchi
41 } // namespace iroha
42 
43 #endif // IROHA_AMETSUCHI_TX_EXECUTOR_HPP
Definition: tx_executor.hpp:22
Definition: block_query.hpp:14
Definition: command_executor.hpp:25
WsvCommandResult execute(soci::statement &st, Function &&error)
Definition: postgres_wsv_command.cpp:23
CommandError command_error
Definition: tx_executor.hpp:23
Definition: command_executor.hpp:12
Definition: transaction.hpp:23
Definition: tx_executor.hpp:27
size_t command_index
Definition: tx_executor.hpp:24