import java.net.*; import java.io.BufferedReader; import java.io.InputStreamReader; import java.io.I
代码说明:
import java.net.*; import java.io.BufferedReader; import java.io.InputStreamReader; import java.io.IOException; public class NetTool { InetAddress myIPaddress = null; InetAddress myServer = null; public static void main(String args[]) throws Exception{ NetTool mytool; mytool = new NetTool(); System.out.println("Your host IP is: " + mytool.getMyIP()); System.out.println("The Server IP is :" + mytool.getServerIP()); System.out.println("Your Mac Address is: " + mytool.getMACAddress()); } //取得
下载说明:请别用迅雷下载,失败请重下,重下不扣分!