| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef NET_DNS_MDNS_CLIENT_H_ | 5 #ifndef NET_DNS_MDNS_CLIENT_H_ |
| 6 #define NET_DNS_MDNS_CLIENT_H_ | 6 #define NET_DNS_MDNS_CLIENT_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 #include <vector> | 9 #include <vector> |
| 10 | 10 |
| 11 #include "base/callback.h" | 11 #include "base/callback.h" |
| 12 #include "net/base/ip_endpoint.h" | 12 #include "net/base/ip_endpoint.h" |
| 13 #include "net/dns/dns_query.h" | 13 #include "net/dns/dns_query.h" |
| 14 #include "net/dns/dns_response.h" | 14 #include "net/dns/dns_response.h" |
| 15 #include "net/dns/record_parsed.h" | 15 #include "net/dns/record_parsed.h" |
| 16 | 16 |
| 17 template <typename T> |
| 18 class ScopedVector; |
| 19 |
| 17 namespace net { | 20 namespace net { |
| 18 | 21 |
| 19 class DatagramServerSocket; | 22 class DatagramServerSocket; |
| 20 class RecordParsed; | 23 class RecordParsed; |
| 21 | 24 |
| 22 // Represents a one-time record lookup. A transaction takes one | 25 // Represents a one-time record lookup. A transaction takes one |
| 23 // associated callback (see |MDnsClient::CreateTransaction|) and calls it | 26 // associated callback (see |MDnsClient::CreateTransaction|) and calls it |
| 24 // whenever a matching record has been found, either from the cache or | 27 // whenever a matching record has been found, either from the cache or |
| 25 // by querying the network (it may choose to query either or both based on its | 28 // by querying the network (it may choose to query either or both based on its |
| 26 // creation flags, see MDnsTransactionFlags). Network-based transactions will | 29 // creation flags, see MDnsTransactionFlags). Network-based transactions will |
| (...skipping 151 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 178 // Create sockets, binds socket to MDns endpoint, and sets multicast interface | 181 // Create sockets, binds socket to MDns endpoint, and sets multicast interface |
| 179 // and joins multicast group on for |interface_index|. | 182 // and joins multicast group on for |interface_index|. |
| 180 // Returns NULL if failed. | 183 // Returns NULL if failed. |
| 181 NET_EXPORT scoped_ptr<DatagramServerSocket> CreateAndBindMDnsSocket( | 184 NET_EXPORT scoped_ptr<DatagramServerSocket> CreateAndBindMDnsSocket( |
| 182 AddressFamily address_family, | 185 AddressFamily address_family, |
| 183 uint32 interface_index); | 186 uint32 interface_index); |
| 184 | 187 |
| 185 } // namespace net | 188 } // namespace net |
| 186 | 189 |
| 187 #endif // NET_DNS_MDNS_CLIENT_H_ | 190 #endif // NET_DNS_MDNS_CLIENT_H_ |
| OLD | NEW |