Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ModAlias ¶
ModAlias abstracts a MODALIAS identifier string
func ParseModAlias ¶
ParseModAlias parses a MODALIAS identifier
type UDevMonitor ¶
type UDevMonitor struct { Fd int Address syscall.SockaddrNetlink }
UDevMonitor is a UDev netlink socket
func NewMonitor ¶
func NewMonitor() (mon *UDevMonitor, err error)
NewMonitor creates and connects a new monitor
func (*UDevMonitor) Connect ¶
func (mon *UDevMonitor) Connect() (err error)
Connect connects the monitoring socket
func (*UDevMonitor) Monitor ¶
func (mon *UDevMonitor) Monitor(notify chan *UEvent) (shutdown chan bool)
Monitor starts udev event monitoring. Events are sent on the notify channel, and the watch can be terminated by sending true on the returned shutdown channel
func (*UDevMonitor) Process ¶
func (mon *UDevMonitor) Process(notify chan *UEvent)
Process processes one packet from the socket, and sends the event on the notify channel
Click to show internal directories.
Click to hide internal directories.