Kagome
Polkadot Runtime Engine in C++17
block_announce_observer.hpp
Go to the documentation of this file.
1 
6 #ifndef KAGOME_BLOCK_ANNOUNCE_OBSERVER_HPP
7 #define KAGOME_BLOCK_ANNOUNCE_OBSERVER_HPP
8 
9 #include <libp2p/peer/peer_id.hpp>
10 
12 #include "network/types/status.hpp"
13 
14 namespace kagome::network {
19  virtual ~BlockAnnounceObserver() = default;
20 
25  virtual void onRemoteStatus(const libp2p::peer::PeerId &peer_id,
26  const Status &remote_status) = 0;
27 
32  virtual void onBlockAnnounce(const libp2p::peer::PeerId &peer_id,
33  const BlockAnnounce &announce) = 0;
34 
39  virtual void onSynchronized() = 0;
40  };
41 } // namespace kagome::network
42 
43 #endif // KAGOME_BLOCK_ANNOUNCE_OBSERVER_HPP
virtual void onBlockAnnounce(const libp2p::peer::PeerId &peer_id, const BlockAnnounce &announce)=0
libp2p::peer::PeerId PeerId
virtual void onRemoteStatus(const libp2p::peer::PeerId &peer_id, const Status &remote_status)=0