PEPeerTransportFactory.registerExtensionHandler(
protocol_name,
new PEPeerTransportExtensionHandler()
{
public List
handleExtension(
PEPeerControl manager,
Map details )
{
PeerManagerImpl peer_manager = PeerManagerImpl.getPeerManager( manager);
Peer[] peers = handler.handleExtension(
peer_manager,
details );
return( peer_manager.mapForeignPeers( peers ));
}
});