protected void HandleTADiscoveryState(Node n, ConnectionState newstate)
{
ImmutableList<Discovery> discs = _ta_discovery;
if(newstate == ConnectionState.Joining ||
newstate == ConnectionState.SeekingConnections) {
foreach(Discovery disc in discs) {
disc.BeginFindingTAs();
}
} else if(newstate == ConnectionState.Leaving ||
newstate == ConnectionState.Disconnected)
{
foreach(Discovery disc in discs) {
disc.Stop();
}
} else {
foreach(Discovery disc in discs) {
disc.EndFindingTAs();
}
}
}