public static Boolean isIPv6LiteralAddress(String IPAddress) {

    Matcher matcher = IPAddressUtil.VALID_IPV6_PATTERN.matcher(IPAddress);
    return matcher.matches();
  }
Class IPAddressUtil This is utility class for checking whether ip address is versions i.e. IPv4
or IPv6 address


@since GemFire version 7.0.1
geode-pulse/src/main/java/org/apache/geode/tools/pulse/internal/util/IPAddressUtil.java