Documentation ¶
Overview ¶
Package hosts provides address lookups from local hostfile (usually /etc/hosts).
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Hostsfile ¶
type Hostsfile struct {
// contains filtered or unexported fields
}
Hostsfile represents a file containing hosts
func NewHostsfile ¶
NewHostsfile returns a new Hostsfile object
type Hostsfiles ¶
type Hostsfiles struct {
// contains filtered or unexported fields
}
Hostsfile represents a file containing hosts
func NewHostsfiles ¶
func NewHostsfiles(directory string, config *Config) (*Hostsfiles, error)
func (*Hostsfiles) FindHosts ¶
func (h *Hostsfiles) FindHosts(name string) (addrs []net.IP, err error)
func (*Hostsfiles) FindReverse ¶
func (h *Hostsfiles) FindReverse(name string) (host string, err error)
Click to show internal directories.
Click to hide internal directories.