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

Side by Side Diff: chromeos/geolocation/simple_geolocation_provider.h

Issue 1819173002: SimpleGeolocation should support sending WiFi AP data. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Update after review. Created 4 years, 9 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 unified diff | Download patch
« no previous file with comments | « chromeos/chromeos.gyp ('k') | chromeos/geolocation/simple_geolocation_provider.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 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 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 CHROMEOS_GEOLOCATION_SIMPLE_GEOLOCATION_PROVIDER_H_ 5 #ifndef CHROMEOS_GEOLOCATION_SIMPLE_GEOLOCATION_PROVIDER_H_
6 #define CHROMEOS_GEOLOCATION_SIMPLE_GEOLOCATION_PROVIDER_H_ 6 #define CHROMEOS_GEOLOCATION_SIMPLE_GEOLOCATION_PROVIDER_H_
7 7
8 #include "base/macros.h" 8 #include "base/macros.h"
9 #include "base/memory/ref_counted.h" 9 #include "base/memory/ref_counted.h"
10 #include "base/memory/scoped_vector.h" 10 #include "base/memory/scoped_vector.h"
(...skipping 15 matching lines...) Expand all
26 // 26 //
27 // Note: this should probably be a singleton to monitor requests rate. 27 // Note: this should probably be a singleton to monitor requests rate.
28 // But as it is used only diring ChromeOS Out-of-Box, it can be owned by 28 // But as it is used only diring ChromeOS Out-of-Box, it can be owned by
29 // WizardController for now. 29 // WizardController for now.
30 class CHROMEOS_EXPORT SimpleGeolocationProvider { 30 class CHROMEOS_EXPORT SimpleGeolocationProvider {
31 public: 31 public:
32 SimpleGeolocationProvider(net::URLRequestContextGetter* url_context_getter, 32 SimpleGeolocationProvider(net::URLRequestContextGetter* url_context_getter,
33 const GURL& url); 33 const GURL& url);
34 virtual ~SimpleGeolocationProvider(); 34 virtual ~SimpleGeolocationProvider();
35 35
36 // Initiates new request (See SimpleGeolocationRequest for parameters 36 // Initiates new request. If |send_wifi_access_points|, WiFi AP information
37 // description.) 37 // will be added to the request. See SimpleGeolocationRequest for the
38 // description of the other parameters.
38 void RequestGeolocation(base::TimeDelta timeout, 39 void RequestGeolocation(base::TimeDelta timeout,
40 bool send_wifi_access_points,
39 SimpleGeolocationRequest::ResponseCallback callback); 41 SimpleGeolocationRequest::ResponseCallback callback);
40 42
41 // Returns default geolocation service URL. 43 // Returns default geolocation service URL.
42 static GURL DefaultGeolocationProviderURL(); 44 static GURL DefaultGeolocationProviderURL();
43 45
44 private: 46 private:
45 friend class TestGeolocationAPIURLFetcherCallback; 47 friend class TestGeolocationAPIURLFetcherCallback;
46 48
47 // Geolocation response callback. Deletes request from requests_. 49 // Geolocation response callback. Deletes request from requests_.
48 void OnGeolocationResponse( 50 void OnGeolocationResponse(
(...skipping 15 matching lines...) Expand all
64 66
65 // Creation and destruction should happen on the same thread. 67 // Creation and destruction should happen on the same thread.
66 base::ThreadChecker thread_checker_; 68 base::ThreadChecker thread_checker_;
67 69
68 DISALLOW_COPY_AND_ASSIGN(SimpleGeolocationProvider); 70 DISALLOW_COPY_AND_ASSIGN(SimpleGeolocationProvider);
69 }; 71 };
70 72
71 } // namespace chromeos 73 } // namespace chromeos
72 74
73 #endif // CHROMEOS_GEOLOCATION_SIMPLE_GEOLOCATION_PROVIDER_H_ 75 #endif // CHROMEOS_GEOLOCATION_SIMPLE_GEOLOCATION_PROVIDER_H_
OLDNEW
« no previous file with comments | « chromeos/chromeos.gyp ('k') | chromeos/geolocation/simple_geolocation_provider.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698