InetAddress[] curentAddresses = _topology.getInetAddresses();
Set<InetAddress> current = new HashSet<InetAddress>(curentAddresses.length);
for (InetAddress address : curentAddresses) {
current.add(address);
if (!_knownAddresses.contains(address)) {
final NetworkTopologyEvent event = new NetworkTopologyEventImpl(_mmDNS, address);
_mmDNS.inetAddressAdded(event);
}
}
for (InetAddress address : _knownAddresses) {
if (!current.contains(address)) {
final NetworkTopologyEvent event = new NetworkTopologyEventImpl(_mmDNS, address);
_mmDNS.inetAddressRemoved(event);
}
}
_knownAddresses = current;
} catch (Exception e) {