Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(333)

Unified Diff: net/dns/dns_util.h

Issue 1908543002: DNS: Retain stale entries in HostCache and return when requested (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase, make all members of Entry private Created 4 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | net/dns/dns_util.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/dns/dns_util.h
diff --git a/net/dns/dns_util.h b/net/dns/dns_util.h
index 1acbd668cdcd7670ed60ba13159ccc5cb79758e7..470242c0cedc11992558c76989d1445ba1e0f8fe 100644
--- a/net/dns/dns_util.h
+++ b/net/dns/dns_util.h
@@ -14,6 +14,8 @@
namespace net {
+class AddressList;
+
// DNSDomainFromDot - convert a domain string to DNS format. From DJB's
// public domain DNS library.
//
@@ -40,6 +42,25 @@ base::TimeDelta GetTimeDeltaForConnectionTypeFromFieldTrialOrDefault(
NetworkChangeNotifier::ConnectionType connection_type);
#endif // !defined(OS_NACL)
+// How similar or different two AddressLists are (see values for details).
+// Used in histograms; do not modify existing values.
+enum AddressListDeltaType {
+ // Both lists contain the same addresses in the same order.
+ DELTA_IDENTICAL = 0,
+ // Both lists contain the same addresses in a different order.
+ DELTA_REORDERED = 1,
+ // The two lists have at least one address in common, but not all of them.
+ DELTA_OVERLAP = 2,
+ // The two lists have no addresses in common.
+ DELTA_DISJOINT = 3,
+ MAX_DELTA_TYPE
+};
+
+// Compares two AddressLists to see how similar or different their addresses
+// are. (See |AddressListDeltaType| for details of exactly what's checked.)
+AddressListDeltaType FindAddressListDeltaType(const AddressList& a,
+ const AddressList& b);
+
} // namespace net
#endif // NET_DNS_DNS_UTIL_H_
« no previous file with comments | « no previous file | net/dns/dns_util.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698