class ServiceInstancePublisher

Defined at line 7152 of file fidling/gen/sdk/fidl/fuchsia.net.mdns/fuchsia.net.mdns/hlcpp/fuchsia/net/mdns/cpp/fidl.h

Discoverable protocol for publishing service instances.

Public Members

static const char[] Name_

Public Methods

void ~ServiceInstancePublisher ()
void PublishServiceInstance (::std::string service, ::std::string instance, ::fuchsia::net::mdns::ServiceInstancePublicationOptions options, ::fidl::InterfaceHandle< ::fuchsia::net::mdns::ServiceInstancePublicationResponder> publication_responder, PublishServiceInstanceCallback callback)

Publishes a service instance. `publication_responder` is consulted via its

`OnPublication` method for initial announcements and to answer queries.

The service is published until the `publication_responder` channel closes. In

addition to announcements and queries for the service type, all queries

for subtypes are answered subject to filtering through the responder.

+ request `service` name of the type of service to be published. For example, cast uses

'_googlecast._tcp.'.

+ request `instance` name of the instance to be published. This is often a descriptive name

such as `Office Printer` or a name containing a large random number.

+ request `options` options to be applied to the publication.

+ request `publication_responder` client end of the `ServiceInstancePublicationResponder`

channel consulted when formulating service instance announcements and query responses.

* error reason the requested operation failed.

If a service with the same service and instance names is already published, the

old publication will be terminated, and the responder channel for the old

publication will be closed.