获取本机IP地址
public static void main(String[] args)throws Exception {
String localhost = InetAddress.getLocalHost().getHostAddress();
System.out.println(localhost);
}
public static void main(String[] args)throws Exception {
String localhost = InetAddress.getLocalHost().getHostAddress();
System.out.println(localhost);
}
本文标题:获取本机IP地址
本文链接:https://www.haomeiwen.com/subject/fsefbktx.html
网友评论