func Interface(iface string) *Module {
	m := newWithSubscriber(func() *netlink.Subscription {
		return netlink.ByName(iface)
	})
	l.Label(m, iface)
	return m
}
Interface constructs an instance of the netinfo module
restricted to the specified interface.
package netinfo  
import (
	"barista.run/bar"
	"barista.run/base/value"
	"barista.run/base/watchers/netlink"
	l "barista.run/logging"
	"barista.run/outputs"
)
type State struct {
	netlink.Link
}
func (s State) Connecting() bool {
	return s.State == netlink.Dormant
}
func (s State) Connected() bool {
	return s.State == netlink.Up
}
func (s State) Enabled() bool {
	return s.State > netlink.NotPresent
}
func (s State) Unknown() bool {
	return s.State == netlink.Unknown
}
func (s State) Gone() bool {
	return s.State == netlink.Gone
}
type Module struct {
	subscriber func() *netlink.Subscription
	outputFunc value.Value  
}
func newWithSubscriber(subscriber func() *netlink.Subscription) *Module {
	m := &Module{subscriber: subscriber}
	l.Register(m, "outputFunc")
	m.Output(func(s State) bar.Output {
		if s.Connected() {
			return outputs.Text(s.Name)
		}
		return nil
	})
	return m
}
func New() *Module {
	m := newWithSubscriber(netlink.Any)
	l.Label(m, "*")
	return m
}