After introducing UdpHostCache we now have two sources of Pong packets: PacketProcessor, which processes the TCP Gnutella traffic, and UdpHostCache, which processes the UDP traffic. It was logical to take the piece of code that extracts node information out of pongs and flow incoming pongs to it.
NodeCache used to have a member function processPong(), which is now a member of PongHandler. In this way we remove the dependencies of NodeCache and avoid making it more dependant on other parts of Calitko. PongHandler will extract all the known GGEP extensions from a pong packet, and will update NodeCache, UdpHostCache, or both.
PingHandler builds a pong packet with which to respond to an incoming pong. UdpHostCache asks PingHandler for the pong, whereas PacketProcessor’s receivedPing() signal is connected to PingHandler's processPing() slot, which builds a pong packet and calls PacketProcessor::sendPacket().
Committed in revision 15.
