public static String getIP() {
			String ipstr = null;
			try {
				Enumeration<NetworkInterface> e = NetworkInterface.getNetworkInterfaces();// 返回所有网络接口的一个枚举实例

				while (e.hasMoreElements()) {
					NetworkInterface network = e.nextElement();// 获得当前网络接口
					if (network != null && network.isUp()) {

						String name = network.getName();

						//System.out.println("name " + name);

						List<InterfaceAddress> en = network.getInterfaceAddresses();

						Iterator<InterfaceAddress> it = en.iterator();
						while (it.hasNext()) {
							InterfaceAddress inter = it.next();
							String ip = inter.getAddress().getHostAddress();
							String hostName = inter.getAddress().getHostName();
							
							
							if ( !determineIpAddress(ip)) {
								System.out.println("hostName "+hostName);
								System.out.println("--InetAddress " + ip);
								System.out.println("--Broadcast " + inter.getBroadcast());

								ipstr = ip;
								break;

							}

						}

						if (ipstr != null) {
							break;
						}

					}
				}
			} catch (SocketException e) {
				e.printStackTrace();
			}
			return ipstr;
		}