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

Unified Diff: net/base/network_change_notifier.h

Issue 10689015: [net] Adds AddressTrackerLinux which keeps track of interface addresses using rtnetlink. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Added NET_EXPORT_PRIVATE for tests. Created 8 years, 5 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 | « net/base/address_tracker_linux_unittest.cc ('k') | net/base/network_change_notifier.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/base/network_change_notifier.h
diff --git a/net/base/network_change_notifier.h b/net/base/network_change_notifier.h
index 8420a8f5477c7d03e4cccb6e1c555b179630fb67..03bcbf30f5da313788571823ca473f4c775a3f84 100644
--- a/net/base/network_change_notifier.h
+++ b/net/base/network_change_notifier.h
@@ -16,6 +16,10 @@ class NetworkChangeNotifierFactory;
namespace internal {
class DnsConfigWatcher;
+
+#if defined(OS_LINUX)
+class AddressTrackerLinux;
+#endif
}
// NetworkChangeNotifier monitors the system for network changes, and notifies
@@ -124,6 +128,11 @@ class NET_EXPORT NetworkChangeNotifier {
// attempt to a particular remote site will be successful.
static ConnectionType GetConnectionType();
+#if defined(OS_LINUX)
+ // Returns the AddressTrackerLinux if present.
+ static const internal::AddressTrackerLinux* GetAddressTracker();
+#endif
+
// Convenience method to determine if the user is offline.
// Returns true if there is currently no internet connection.
//
@@ -173,6 +182,12 @@ class NET_EXPORT NetworkChangeNotifier {
NetworkChangeNotifier();
+#if defined(OS_LINUX)
+ // Returns the AddressTrackerLinux if present.
+ virtual const internal::AddressTrackerLinux*
+ GetAddressTrackerInternal() const;
+#endif
+
// Broadcasts a notification to all registered observers. Note that this
// happens asynchronously, even for observers on the current thread, even in
// tests.
« no previous file with comments | « net/base/address_tracker_linux_unittest.cc ('k') | net/base/network_change_notifier.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698