either the ip, or domain-name of the network-address.
"192.168.100.1" (ipv4)"[::ffff:192.168.100.1]" (ipv4 in ipv6 representation)"example.com" (a hostname)"0.0.0.0" (an address that portrays "all self-host nicknames".
this is only acceptable for a server/listening. it is not for a client to connect to.)"192.168.100.1/24" (an ipv4 CIDR)"192.168.100.1:8000" (an ipv4 with a port number)"[::ffff:192.168.100.1]:8000" (an ipv6 with a port number)"http://example.com" (an http url. a host name is not a url! but the url does contain the host name)"localhost" (it is only defined on windows, and may only work in browsers.
use "0.0.0.0", or "127.0.0.1" instead for local loopback)a 2-byte number (1-65534) that dictates the destination or source port on a specific host.
use the special 0 empherial port to let your os assign any general purpose temporary port to you,
that is guaranteed to be available.
also, I think the 0xFFFF (65535) port is reserved.
specifies whether this address is an ipv4 or an ipv6 address.
if an ip is in essence an ipv4, but dressed up like an ipv6, such as "::ffff:192.168.100.1",
then the ip-family should be set to 4 rather than 6.
a net address is an ip-address and port-number pair, that specifies where a packet is being sent or received from.