hyperledger/iroha
Iroha - A simple, decentralized ledger http://iroha.tech
channel_provider.hpp
Go to the documentation of this file.
1 
6 #ifndef IROHA_CHANNEL_PROVIDER_HPP
7 #define IROHA_CHANNEL_PROVIDER_HPP
8 
9 #include <memory>
10 #include <string>
11 
12 #include <grpc++/grpc++.h>
13 #include "common/result.hpp"
14 
15 namespace shared_model {
16  namespace interface {
17  class Peer;
18  }
19 } // namespace shared_model
20 
21 namespace iroha {
22  namespace network {
23 
25  public:
26  virtual ~ChannelProvider() = default;
27 
35  virtual iroha::expected::Result<std::shared_ptr<grpc::Channel>,
36  std::string>
37  getChannel(const std::string &service_full_name,
38  const shared_model::interface::Peer &peer) = 0;
39  };
40 
41  } // namespace network
42 } // namespace iroha
43 
44 #endif
Definition: peer.hpp:20
Definition: block_query.hpp:14
Definition: channel_provider.hpp:24
Definition: command_executor.hpp:12