ssdp

package
v1.9.0 Latest Latest
Warning

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

Go to latest
Published: Nov 29, 2026 License: BSD-3-Clause Imports: 14 Imported by: 24 modules, 20 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

View Source
const (
	AddrString    = "239.255.255.250:1900"
	AddrString6LL = "[ff02::c]:1900"
	AddrString6SL = "[ff05::c]:1900"
)

Variables

View Source
var AddrString2NetAdd map[string]*net.UDPAddr = make(map[string]*net.UDPAddr, 3)
View Source
var NetAddr *net.UDPAddr
View Source
var NetAddr6LL *net.UDPAddr
View Source
var NetAddr6SL *net.UDPAddr

Functions

func ReadRequest

func ReadRequest(b *bufio.Reader) (req *http.Request, err error)

Types

type Server

type Server struct {
	Interface      net.Interface
	AddrString     string
	NetAddr        *net.UDPAddr
	Server         string
	Services       []string
	Devices        []string
	IPFilter       func(net.IP) bool
	Location       func(net.IP) string
	UUID           string
	NotifyInterval time.Duration
	// InterfaceAddrs returns the addresses of Interface. Defaults to
	// net.Interface.Addrs, which fails on platforms that restrict netlink
	// access, such as Android 11+ (https://github.com/golang/go/issues/40569).
	InterfaceAddrs func(net.Interface) ([]net.Addr, error)

	Logger *slog.Logger
	// contains filtered or unexported fields
}

func (*Server) Close

func (me *Server) Close()

func (*Server) Init

func (me *Server) Init() (err error)

func (*Server) Serve

func (me *Server) Serve() (err error)

Jump to

Keyboard shortcuts

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