ssdp

package
v0.0.0-...-cfeb3e9 Latest Latest
Warning

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

Go to latest
Published: Mar 27, 2023 License: GPL-3.0 Imports: 12 Imported by: 1

Documentation

Index

Constants

View Source
const (
	MulticastAddrPort string = "239.255.255.250:1900"
)

Variables

This section is empty.

Functions

func IsIPDenyError

func IsIPDenyError(err error) bool

func IsInterfaceError

func IsInterfaceError(err error) bool

func IsRequestError

func IsRequestError(err error) bool

func IsSSDPError

func IsSSDPError(err error) bool

func NewIPDenyError

func NewIPDenyError(ip net.IP) error

func NewIPNotAllowError

func NewIPNotAllowError(ip net.IP) error

func NewSSDPServer

func NewSSDPServer(ctx context.Context, ifaces []*net.Interface, uuids []string) (*ssdpServer, error)

Types

type ErrorHandler

type ErrorHandler func(error)

type IPDenyError

type IPDenyError struct {
	IP       net.IP
	FromDeny bool
}

func (*IPDenyError) Error

func (e *IPDenyError) Error() string

type InfoHandler

type InfoHandler func(string)

type InterfaceError

type InterfaceError struct {
	Iface *net.Interface
	Err   error
}

func (*InterfaceError) Error

func (e *InterfaceError) Error() (s string)

type RequestError

type RequestError struct {
	Src *net.UDPAddr
	Err error
}

func (*RequestError) Error

func (e *RequestError) Error() string

type SSDPError

type SSDPError struct {
	Err error
}

func (*SSDPError) Error

func (e *SSDPError) Error() string

type SSDPServer

type SSDPServer interface {
	Init(ifaces []*net.Interface) error
	ListenAndServe() error
	SetUUIDs([]string)
	Close()
}

Jump to

Keyboard shortcuts

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