Struct mdns_sd::ServiceDaemon [−][src]
pub struct ServiceDaemon { /* fields omitted */ }Expand description
A daemon thread for mDNS
This struct provides a handle and an API to the daemon. It is cloneable.
Implementations
Creates a new daemon.
The daemon (re)uses the default mDNS port 5353. To keep it simple, we don’t ask callers to set the port.
Starts browsing for a specific service type.
Returns a channel Receiver to receive events about the service.
When a new instance is found, the daemon automatically tries to resolve, i.e. finding more details, i.e. SRV records and TXT records.
Stops searching for a specific service type.
When returns error, it means we failed to send the request to the daemon as the channel closed. Retry probably won’t help. The caller should just note down the error and move on.
Registers a service provided by this host.
Unregisters a service. This is a graceful shutdown of a service.
Returns a channel receiver that is used to receive the status code of the unregister.
When returns error, it means we failed to send the request to the daemon as the channel closed. Retry probably won’t help. The caller should just note down the error and move on.
Trait Implementations
Auto Trait Implementations
impl RefUnwindSafe for ServiceDaemon
impl Send for ServiceDaemon
impl Sync for ServiceDaemon
impl Unpin for ServiceDaemon
impl UnwindSafe for ServiceDaemon
Blanket Implementations
Mutably borrows from an owned value. Read more