OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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_SYNC_PROFILE_SYNC_SERVICE_H_ | 5 #ifndef CHROME_BROWSER_SYNC_PROFILE_SYNC_SERVICE_H_ |
6 #define CHROME_BROWSER_SYNC_PROFILE_SYNC_SERVICE_H_ | 6 #define CHROME_BROWSER_SYNC_PROFILE_SYNC_SERVICE_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 #include <string> | 9 #include <string> |
10 | 10 |
(...skipping 256 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
267 } | 267 } |
268 | 268 |
269 bool observed_passphrase_required() const { | 269 bool observed_passphrase_required() const { |
270 return observed_passphrase_required_; | 270 return observed_passphrase_required_; |
271 } | 271 } |
272 | 272 |
273 bool passphrase_required_for_decryption() const { | 273 bool passphrase_required_for_decryption() const { |
274 return passphrase_required_for_decryption_; | 274 return passphrase_required_for_decryption_; |
275 } | 275 } |
276 | 276 |
277 // A timestamp marking the last time the service observed a transition from | |
278 // the SYNCING state to the READY state. Note that this does not reflect the | |
279 // last time we polled the server to see if there were any changes; the | |
280 // timestamp is only snapped when syncing takes place and we download or | |
281 // upload some bookmark entity. | |
282 const base::Time& last_synced_time() const { return last_synced_time_; } | |
283 | |
284 // Returns a user-friendly string form of last synced time (in minutes). | 277 // Returns a user-friendly string form of last synced time (in minutes). |
285 virtual string16 GetLastSyncedTimeString() const; | 278 virtual string16 GetLastSyncedTimeString() const; |
286 | 279 |
287 // Returns the authenticated username of the sync user, or empty if none | 280 // Returns the authenticated username of the sync user, or empty if none |
288 // exists. It will only exist if the authentication service provider (e.g | 281 // exists. It will only exist if the authentication service provider (e.g |
289 // GAIA) has confirmed the username is authentic. | 282 // GAIA) has confirmed the username is authentic. |
290 virtual string16 GetAuthenticatedUsername() const; | 283 virtual string16 GetAuthenticatedUsername() const; |
291 | 284 |
292 const std::string& last_attempted_user_email() const { | 285 const std::string& last_attempted_user_email() const { |
293 return last_attempted_user_email_; | 286 return last_attempted_user_email_; |
(...skipping 341 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
635 base::OneShotTimer<ProfileSyncService> clear_server_data_timer_; | 628 base::OneShotTimer<ProfileSyncService> clear_server_data_timer_; |
636 | 629 |
637 // The set of encrypted types. This is updated whenever datatypes are | 630 // The set of encrypted types. This is updated whenever datatypes are |
638 // encrypted through the OnEncryptionComplete callback of SyncFrontend. | 631 // encrypted through the OnEncryptionComplete callback of SyncFrontend. |
639 syncable::ModelTypeSet encrypted_types_; | 632 syncable::ModelTypeSet encrypted_types_; |
640 | 633 |
641 DISALLOW_COPY_AND_ASSIGN(ProfileSyncService); | 634 DISALLOW_COPY_AND_ASSIGN(ProfileSyncService); |
642 }; | 635 }; |
643 | 636 |
644 #endif // CHROME_BROWSER_SYNC_PROFILE_SYNC_SERVICE_H_ | 637 #endif // CHROME_BROWSER_SYNC_PROFILE_SYNC_SERVICE_H_ |
OLD | NEW |