1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 #ifndef COMPONENTS_GOOGLE_GOOGLE_URL_TRACKER_CLIENT_H_
6 #define COMPONENTS_GOOGLE_GOOGLE_URL_TRACKER_CLIENT_H_
8 #include "base/macros.h"
11 class GoogleURLTracker
;
15 class URLRequestContextGetter
;
18 // Interface by which GoogleURLTracker communicates with its embedder.
19 class GoogleURLTrackerClient
{
21 GoogleURLTrackerClient();
22 virtual ~GoogleURLTrackerClient();
24 // Sets the GoogleURLTracker that is associated with this client.
25 void set_google_url_tracker(GoogleURLTracker
* google_url_tracker
) {
26 google_url_tracker_
= google_url_tracker
;
29 // Returns whether background networking is enabled.
30 virtual bool IsBackgroundNetworkingEnabled() = 0;
32 // Returns the PrefService that the GoogleURLTracker should use.
33 virtual PrefService
* GetPrefs() = 0;
35 // Returns the URL request context information that the GoogleURLTracker
37 virtual net::URLRequestContextGetter
* GetRequestContext() = 0;
40 GoogleURLTracker
* google_url_tracker() { return google_url_tracker_
; }
43 GoogleURLTracker
* google_url_tracker_
;
45 DISALLOW_COPY_AND_ASSIGN(GoogleURLTrackerClient
);
48 #endif // COMPONENTS_GOOGLE_GOOGLE_URL_TRACKER_CLIENT_H_