I'm working on a Java application that runs on both Windows and Mac. It communicates with various different servers but needs to behave differently depending whether it is using WiFi or a wired connection.
Is there anyway to work out which it is using?
I've looked at using
NetworkInterface.getNetworkInterfaces() but that doesn't tell me which
NetworkInterface is being used and whether it is WiFi or not.