hyperledger/iroha
Iroha - A simple, decentralized ledger http://iroha.tech
peer_communication_service_impl.hpp
Go to the documentation of this file.
1 
6 #ifndef IROHA_PEER_COMMUNICATION_SERVICE_IMPL_HPP
7 #define IROHA_PEER_COMMUNICATION_SERVICE_IMPL_HPP
8 
10 
11 #include "logger/logger_fwd.hpp"
12 
13 namespace iroha {
14  namespace simulator {
15  class VerifiedProposalCreator;
16  } // namespace simulator
17 
18  namespace synchronizer {
19  class Synchronizer;
20  } // namespace synchronizer
21 
22  namespace network {
23  class OrderingGate;
24 
26  public:
28  std::shared_ptr<OrderingGate> ordering_gate,
29  std::shared_ptr<synchronizer::Synchronizer> synchronizer,
30  std::shared_ptr<simulator::VerifiedProposalCreator> proposal_creator,
31  logger::LoggerPtr log);
32 
33  void propagate_batch(
34  std::shared_ptr<shared_model::interface::TransactionBatch> batch)
35  const override;
36 
37  rxcpp::observable<OrderingEvent> onProposal() const override;
38 
39  rxcpp::observable<simulator::VerifiedProposalCreatorEvent>
40  onVerifiedProposal() const override;
41 
42  rxcpp::observable<synchronizer::SynchronizationEvent> onSynchronization()
43  const override;
44 
45  private:
46  std::shared_ptr<OrderingGate> ordering_gate_;
47  std::shared_ptr<synchronizer::Synchronizer> synchronizer_;
48  std::shared_ptr<simulator::VerifiedProposalCreator> proposal_creator_;
49  logger::LoggerPtr log_;
50  };
51  } // namespace network
52 } // namespace iroha
53 
54 #endif // IROHA_PEER_COMMUNICATION_SERVICE_IMPL_HPP
Definition: peer_communication_service.hpp:27
Definition: peer_communication_service_impl.hpp:25
std::shared_ptr< Logger > LoggerPtr
Definition: logger_fwd.hpp:22
Definition: block_query.hpp:16