@Ignore @Test public void isReachableTest() { assertEquals(true, isReachable("127.0.0.1")); System.out.println(isReachable("192.168.1.101")); System.out.println(isReachable(getIPFromURL("https: }
public static Boolean isReachable(final String ipAddress) { try { return InetAddress.getByName(ipAddress).isReachable(10000); } catch (IOException e) { _log.error(ExceptionUtils.errorInfo(e)); return null; } }
IpUtils { public static Boolean isReachable(final String ipAddress) { try { return InetAddress.getByName(ipAddress).isReachable(10000); } catch (IOException e) { _log.error(ExceptionUtils.errorInfo(e)); return null; } } }
IpUtils { public static Boolean isReachable(final String ipAddress) { try { return InetAddress.getByName(ipAddress).isReachable(10000); } catch (IOException e) { _log.error(ExceptionUtils.errorInfo(e)); return null; } } private  IpUtils(); }
IpUtils { public static Boolean isReachable(final String ipAddress) { try { return InetAddress.getByName(ipAddress).isReachable(10000); } catch (IOException e) { _log.error(ExceptionUtils.errorInfo(e)); return null; } } private  IpUtils(); static boolean checkValid(final String ip); static boolean checkValid2(final String ip); static boolean checkValidV6(final String ip); static String removeTail32(String ip); static String extractDomain(String url); static String getTailFromURL(String url); static long ip2long(String ipAddress); static String long2ip(Long ipAddress); static Integer ip2int(String ipAddress); static Boolean checkIPRange(final String ipAddress, final String range); static String getIPFromURL(String url); static Boolean isReachable(final String ipAddress); static boolean ping(final String ipAddress); static List<String> getCurrentEnvironmentNetworkIps(); }
IpUtils { public static Boolean isReachable(final String ipAddress) { try { return InetAddress.getByName(ipAddress).isReachable(10000); } catch (IOException e) { _log.error(ExceptionUtils.errorInfo(e)); return null; } } private  IpUtils(); static boolean checkValid(final String ip); static boolean checkValid2(final String ip); static boolean checkValidV6(final String ip); static String removeTail32(String ip); static String extractDomain(String url); static String getTailFromURL(String url); static long ip2long(String ipAddress); static String long2ip(Long ipAddress); static Integer ip2int(String ipAddress); static Boolean checkIPRange(final String ipAddress, final String range); static String getIPFromURL(String url); static Boolean isReachable(final String ipAddress); static boolean ping(final String ipAddress); static List<String> getCurrentEnvironmentNetworkIps();  }