Versions in this module Expand all Collapse all v0 v0.1.0 Dec 3, 2023 Changes in this version + const EventAlive + const EventByeBye + const EventUpdate + const SSDPAll + const UPNPRootDevice + func RawSearch(ctx context.Context, httpu HTTPUClientCtx, searchTarget string, numSends int) ([]*http.Response, error) + func SSDPRawSearch(httpu HTTPUClient, searchTarget string, maxWaitSeconds int, numSends int) ([]*http.Response, error) + func SSDPRawSearchCtx(ctx context.Context, httpu HTTPUClient, searchTarget string, ...) ([]*http.Response, error) + type Entry struct + BootID int32 + CacheExpiry time.Time + ConfigID int32 + Host string + LastUpdate time.Time + Location url.URL + NT string + RemoteAddr string + SearchPort uint16 + Server string + USN string + type EventType int8 + func (et EventType) String() string + type HTTPUClient interface + Do func(req *http.Request, timeout time.Duration, numSends int) ([]*http.Response, error) + type HTTPUClientCtx interface + DoWithContext func(req *http.Request, numSends int) ([]*http.Response, error) + type Registry struct + func NewRegistry() *Registry + func NewServerAndRegistry() (*httpu.Server, *Registry) + func (reg *Registry) AddListener(c chan<- Update) + func (reg *Registry) GetService(serviceURN string) []*Entry + func (reg *Registry) RemoveListener(c chan<- Update) + func (reg *Registry) ServeMessage(r *http.Request) + type Update struct + Entry *Entry + EventType EventType + USN string