class Owner

Defined at line 52 of file ../../src/connectivity/network/mdns/service/agents/mdns_agent.h

Public Methods

zx::time now ()

Gets the current time.

void PostTaskForTime (MdnsAgent * agent, fit::closure task, zx::time target_time)

Posts a task to be executed at the specified time. Scheduled tasks posted

by agents that have since been removed are not executed.

void SendQuestion (std::shared_ptr<DnsQuestion> question, ReplyAddress reply_address)

Sends a question to the multicast address.

void SendResource (std::shared_ptr<DnsResource> resource, MdnsResourceSection section, const ReplyAddress & reply_address)

Sends a resource to the specified address. The default |reply_address|

|kV4MulticastReply| sends the resource to the V4 or V6

multicast address.

void SendAddresses (MdnsResourceSection section, const ReplyAddress & reply_address)

Sends address resources to the specified address. The default

|reply_address| |kV4MulticastReply| sends the addresses to the V4 or V6

multicast address.

void Renew (const DnsResource & resource, Media media, IpVersions ip_versions)

Registers the resource for renewal. See |MdnsAgent::Renew| below.

void Query (DnsType type, const DnsName & name, Media media, IpVersions ip_versions, zx::time initial_query_time, zx::duration interval, uint32_t interval_multiplier, uint32_t max_queries, bool request_unicast_response)

Registers the resource for repeated queries. See |MdnsAgent::Request| below.

void RemoveAgent (std::shared_ptr<MdnsAgent> agent)

Removes the specified agent.

void MaybeSendMessages ()

Flushes sent questions and resources by sending the appropriate messages.

uint64_t DeferMessages ()

Defers sending messages until |UndeferMessages| is called. Returns a sequence

number that must be passed to |UndeferMessages| to undefer the messages.

Deferral ends regardless 500 ms after it has begun. The sequence number that is

returned is initially 1 and increments each time the deferral count drops to

zero or deferral times out. This method will never return 0.

void UndeferMessages (uint64_t sequence_number)

Ends message deferral initiated by |DeferMessages|. |sequence_number| should be

the value returned by the corresponding |DeferMessages| call. If |sequence_number|

doesn't match the current sequence number, the call is equivalent to calling

|MaybeSendMessages|. |DeferMessages| never returns 0, so calling this method with

a |sequence_number| of 0 is equivalent to calling |MaybeSendMessages|.

void AddLocalServiceInstance (const ServiceInstance & instance, bool from_proxy)

Notifies all agents of the addition of a local service instance.|from_proxy| indicates

whether the instance is published by the local host (false) or a local proxy host (true).

void ChangeLocalServiceInstance (const ServiceInstance & instance, bool from_proxy)

Notifies all agents of a change to a previously-added local service instance.|from_proxy|

indicates whether the instance is published by the local host (false) or a local proxy host

(true).

std::vector<HostAddress> LocalHostAddresses ()

Returns the addresses for the local host.

void ~Owner ()

Defined at line 54 of file ../../src/connectivity/network/mdns/service/agents/mdns_agent.h