OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 CHROME_BROWSER_CHROMEOS_POLICY_DEVICE_STATUS_COLLECTOR_H_ | 5 #ifndef CHROME_BROWSER_CHROMEOS_POLICY_DEVICE_STATUS_COLLECTOR_H_ |
6 #define CHROME_BROWSER_CHROMEOS_POLICY_DEVICE_STATUS_COLLECTOR_H_ | 6 #define CHROME_BROWSER_CHROMEOS_POLICY_DEVICE_STATUS_COLLECTOR_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
(...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
56 DeviceStatusCollector( | 56 DeviceStatusCollector( |
57 PrefService* local_state, | 57 PrefService* local_state, |
58 chromeos::system::StatisticsProvider* provider, | 58 chromeos::system::StatisticsProvider* provider, |
59 LocationUpdateRequester* location_update_requester); | 59 LocationUpdateRequester* location_update_requester); |
60 virtual ~DeviceStatusCollector(); | 60 virtual ~DeviceStatusCollector(); |
61 | 61 |
62 void GetStatus(enterprise_management::DeviceStatusReportRequest* request); | 62 void GetStatus(enterprise_management::DeviceStatusReportRequest* request); |
63 | 63 |
64 // CloudPolicyClient::StatusProvider: | 64 // CloudPolicyClient::StatusProvider: |
65 virtual bool GetDeviceStatus( | 65 virtual bool GetDeviceStatus( |
66 enterprise_management::DeviceStatusReportRequest* status) OVERRIDE; | 66 enterprise_management::DeviceStatusReportRequest* status) override; |
67 virtual bool GetSessionStatus( | 67 virtual bool GetSessionStatus( |
68 enterprise_management::SessionStatusReportRequest* status) OVERRIDE; | 68 enterprise_management::SessionStatusReportRequest* status) override; |
69 virtual void OnSubmittedSuccessfully() OVERRIDE; | 69 virtual void OnSubmittedSuccessfully() override; |
70 | 70 |
71 static void RegisterPrefs(PrefRegistrySimple* registry); | 71 static void RegisterPrefs(PrefRegistrySimple* registry); |
72 | 72 |
73 // How often, in seconds, to poll to see if the user is idle. | 73 // How often, in seconds, to poll to see if the user is idle. |
74 static const unsigned int kIdlePollIntervalSeconds = 30; | 74 static const unsigned int kIdlePollIntervalSeconds = 30; |
75 | 75 |
76 protected: | 76 protected: |
77 // Check whether the user has been idle for a certain period of time. | 77 // Check whether the user has been idle for a certain period of time. |
78 virtual void CheckIdleState(); | 78 virtual void CheckIdleState(); |
79 | 79 |
(...skipping 114 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
194 users_subscription_; | 194 users_subscription_; |
195 | 195 |
196 base::WeakPtrFactory<DeviceStatusCollector> weak_factory_; | 196 base::WeakPtrFactory<DeviceStatusCollector> weak_factory_; |
197 | 197 |
198 DISALLOW_COPY_AND_ASSIGN(DeviceStatusCollector); | 198 DISALLOW_COPY_AND_ASSIGN(DeviceStatusCollector); |
199 }; | 199 }; |
200 | 200 |
201 } // namespace policy | 201 } // namespace policy |
202 | 202 |
203 #endif // CHROME_BROWSER_CHROMEOS_POLICY_DEVICE_STATUS_COLLECTOR_H_ | 203 #endif // CHROME_BROWSER_CHROMEOS_POLICY_DEVICE_STATUS_COLLECTOR_H_ |
OLD | NEW |