Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var DefaultConfig = &Config{ ForceUnicastResponses: false, MinTTL: 300, BrowsePeriod: 60 * time.Second, CachePurgePeriod: 300 * time.Second, RetryPeriod: 250 * time.Millisecond, Transport: nil, Clock: clock.Realtime(), BindIPAddressV4: net.IPv4zero, BindIPAddressV6: net.IPv6zero, }
DefaultConfig represents the defaut mDNS config
Functions ¶
This section is empty.
Types ¶
type Client ¶
type Client struct { Config // contains filtered or unexported fields }
Client represents a mDNS client
type Config ¶
type Config struct { ForceUnicastResponses bool // whether to force unicast according to RFC 6762, section 18.12. BindIPAddressV4 net.IP // IPv4 interface to bind to BindIPAddressV6 net.IP // IPv6 interface to bind to MinTTL uint32 // minimum TTL to keep records for, overriding mDNS response BrowseServices []string // List of services to scan and keep updated BrowsePeriod time.Duration // How often scan the list of services CachePurgePeriod time.Duration // How often clean the cache for stale records RetryPeriod time.Duration // How often retry mDNS queries Transport transport // Network transport. Defaults to UDP. Useful for testing Clock clock.Clock // Time reference. Defaults to system time. Useful for testing }
Config contains the configuration of the mDNS client
func (*Config) ApplyDefaults ¶
ApplyDefaults fills the missing fields with sane default values
Click to show internal directories.
Click to hide internal directories.