I have a program where an external component passes me a string which contains an IP address. I then need to turn it into a URI. For IPv4 this is easy; I prepend https:// and append /. However, for IPv6 I need to also surround it in brackets [].I have a program where an external component pa