net.tomp2p.peers
Interface PeerMapChangeListener

All Known Implementing Classes:
Replication

public interface PeerMapChangeListener

This interface can be added to the map, to get notified of peer insertion or removal. This is useful for replication.

Author:
Thomas Bocek

Method Summary
 void peerInserted(PeerAddress peerAddress)
          This method is called if a peer is added to the map
 void peerRemoved(PeerAddress peerAddress)
          This method is called if a peer is removed from the map
 void peerUpdated(PeerAddress peerAddress)
          This method is called if a peer is updated.
 

Method Detail

peerInserted

void peerInserted(PeerAddress peerAddress)
This method is called if a peer is added to the map

Parameters:
peerAddress - The peer that has been added.

peerRemoved

void peerRemoved(PeerAddress peerAddress)
This method is called if a peer is removed from the map

Parameters:
peerAddress - The peer that has been removed and add to the cache.

peerUpdated

void peerUpdated(PeerAddress peerAddress)
This method is called if a peer is updated.

Parameters:
peerAddress - The peer can change its IP and some statistical data


Copyright © 2013. All Rights Reserved.