hostfile

package
v1.0.12 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 15, 2020 License: MIT Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Hostfile added in v1.0.0

type Hostfile struct {
	// contains filtered or unexported fields
}

Hostfile represents the host file manager client

func NewClient added in v1.0.0

func NewClient() (*Hostfile, error)

NewClient returns a new Hostfile manager client

func (*Hostfile) AddHost added in v1.0.0

func (h *Hostfile) AddHost(ip, hostname string) error

AddHost adds a new host / ip entry into the hosts file

func (*Hostfile) RemoveHost added in v1.0.0

func (h *Hostfile) RemoveHost(hostname string) error

RemoveHost removes a given hostname from the hosts file

type HostfileInterface added in v1.0.0

type HostfileInterface interface {
	AddHost(ip, hostname string) error
	RemoveHost(hostname string) error
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL