Lines Matching refs:Zone
108 // "[host]:port" or "[ipv6-host%zone]:port" into host or
109 // ipv6-host%zone and port. A literal address or host name for IPv6
111 // "[ipv6-host]:http" or "[ipv6-host%zone]:80".
178 func splitHostZone(s string) (host, zone string) {
179 // The IPv6 scoped addressing zone identifier starts after the
182 host, zone = s[:i], s[i+1:]
230 return &TCPAddr{IP: ip.IP, Port: portnum, Zone: ip.Zone}
232 return &UDPAddr{IP: ip.IP, Port: portnum, Zone: ip.Zone}
234 return &IPAddr{IP: ip.IP, Zone: ip.Zone}
247 var zone string
248 if ip, zone = parseIPv6(host, true); ip != nil {
249 return addrList{inetaddr(IPAddr{IP: ip, Zone: zone})}, nil
266 func zoneToString(zone int) string {
267 if zone == 0 {
270 if ifi, err := InterfaceByIndex(zone); err == nil {
273 return uitoa(uint(zone))
276 func zoneToInt(zone string) int {
277 if zone == "" {
280 if ifi, err := InterfaceByName(zone); err == nil {
283 n, _, _ := dtoi(zone, 0)