Documentation ¶
Index ¶
Constants ¶
View Source
const (
ProbeInterval = 5 * time.Minute
)
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Database ¶
type Database interface { // GetUndiscoveredHosts returns IP addresses whose physical location is still // undiscovered or staled more than expiration. GetUndiscoveredHosts(expiration time.Duration) ([]net.IP, error) // UpdateHostLocation updates the physical location of a host, whose MAC and IP // addresses are matched with mac and ip, to the port identified by swDPID and // portNum. updated will be true if its location has been actually updated. UpdateHostLocation(mac net.HardwareAddr, ip net.IP, swDPID uint64, portNum uint16) (updated bool, err error) // ResetHostLocationsByPort sets NULL to the host locations that belong to the // port specified by swDPID and portNum. ResetHostLocationsByPort(swDPID uint64, portNum uint16) error // ResetHostLocationsByDevice sets NULL to the host locations that belong to the // device specified by swDPID. ResetHostLocationsByDevice(swDPID uint64) error }
Click to show internal directories.
Click to hide internal directories.