go/src/net/interface.go

var errInvalidInterface

var errInvalidInterfaceIndex

var errInvalidInterfaceName

var errNoSuchInterface

var errNoSuchMulticastInterface

type Interface

type Flags

const FlagUp

const FlagBroadcast

const FlagLoopback

const FlagPointToPoint

const FlagMulticast

const FlagRunning

var flagNames

func (f Flags) String() string {}

// Addrs returns a list of unicast interface addresses for a specific
// interface.
func (ifi *Interface) Addrs() ([]Addr, error) {}

// MulticastAddrs returns a list of multicast, joined group addresses
// for a specific interface.
func (ifi *Interface) MulticastAddrs() ([]Addr, error) {}

// Interfaces returns a list of the system's network interfaces.
func Interfaces() ([]Interface, error) {}

// InterfaceAddrs returns a list of the system's unicast interface
// addresses.
//
// The returned list does not identify the associated interface; use
// Interfaces and [Interface.Addrs] for more detail.
func InterfaceAddrs() ([]Addr, error) {}

// InterfaceByIndex returns the interface specified by index.
//
// On Solaris, it returns one of the logical network interfaces
// sharing the logical data link; for more precision use
// [InterfaceByName].
func InterfaceByIndex(index int) (*Interface, error) {}

func interfaceByIndex(ift []Interface, index int) (*Interface, error) {}

// InterfaceByName returns the interface specified by name.
func InterfaceByName(name string) (*Interface, error) {}

type ipv6ZoneCache

var zoneCache

// update refreshes the network interface information if the cache was last
// updated more than 1 minute ago, or if force is set. It reports whether the
// cache was updated.
func (zc *ipv6ZoneCache) update(ift []Interface, force bool) (updated bool) {}

func (zc *ipv6ZoneCache) name(index int) string {}

func (zc *ipv6ZoneCache) index(name string) int {}