| 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 COMPONENTS_HISTORY_CORE_BROWSER_HISTORY_BACKEND_H_ | 5 #ifndef COMPONENTS_HISTORY_CORE_BROWSER_HISTORY_BACKEND_H_ |
| 6 #define COMPONENTS_HISTORY_CORE_BROWSER_HISTORY_BACKEND_H_ | 6 #define COMPONENTS_HISTORY_CORE_BROWSER_HISTORY_BACKEND_H_ |
| 7 | 7 |
| 8 #include <stddef.h> | 8 #include <stddef.h> |
| 9 #include <stdint.h> | 9 #include <stdint.h> |
| 10 | 10 |
| (...skipping 854 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 865 // Used to determine if a URL is bookmarked; may be null. | 865 // Used to determine if a URL is bookmarked; may be null. |
| 866 std::unique_ptr<HistoryBackendClient> backend_client_; | 866 std::unique_ptr<HistoryBackendClient> backend_client_; |
| 867 | 867 |
| 868 scoped_refptr<base::SequencedTaskRunner> task_runner_; | 868 scoped_refptr<base::SequencedTaskRunner> task_runner_; |
| 869 | 869 |
| 870 // Used to allow embedder code to stash random data by key. Those object will | 870 // Used to allow embedder code to stash random data by key. Those object will |
| 871 // be deleted before closing the databases (hence the member variable instead | 871 // be deleted before closing the databases (hence the member variable instead |
| 872 // of inheritance from base::SupportsUserData). | 872 // of inheritance from base::SupportsUserData). |
| 873 std::unique_ptr<HistoryBackendHelper> supports_user_data_helper_; | 873 std::unique_ptr<HistoryBackendHelper> supports_user_data_helper_; |
| 874 | 874 |
| 875 // Used to manage syncing of the typed urls datatype. This will be null before | |
| 876 // Init is called. | |
| 877 std::unique_ptr<TypedUrlSyncableService> typed_url_syncable_service_; | |
| 878 | |
| 879 // Listens for the system being under memory pressure. | 875 // Listens for the system being under memory pressure. |
| 880 std::unique_ptr<base::MemoryPressureListener> memory_pressure_listener_; | 876 std::unique_ptr<base::MemoryPressureListener> memory_pressure_listener_; |
| 881 | 877 |
| 882 // Contains diagnostic information about the sql database that is non-empty | 878 // Contains diagnostic information about the sql database that is non-empty |
| 883 // when a catastrophic error occurs. | 879 // when a catastrophic error occurs. |
| 884 std::string db_diagnostics_; | 880 std::string db_diagnostics_; |
| 885 | 881 |
| 886 // Map from host to index in the TopHosts list. It is updated only by | 882 // Map from host to index in the TopHosts list. It is updated only by |
| 887 // TopHosts(), so it's usually stale. | 883 // TopHosts(), so it's usually stale. |
| 888 mutable base::hash_map<std::string, int> host_ranks_; | 884 mutable base::hash_map<std::string, int> host_ranks_; |
| 889 | 885 |
| 890 // List of observers | 886 // List of observers |
| 891 base::ObserverList<HistoryBackendObserver> observers_; | 887 base::ObserverList<HistoryBackendObserver> observers_; |
| 892 | 888 |
| 889 // Used to manage syncing of the typed urls datatype. This will be null before |
| 890 // Init is called. Defined after observers_ because it unregisters itself as |
| 891 // observer during destruction. |
| 892 std::unique_ptr<TypedUrlSyncableService> typed_url_syncable_service_; |
| 893 |
| 893 DISALLOW_COPY_AND_ASSIGN(HistoryBackend); | 894 DISALLOW_COPY_AND_ASSIGN(HistoryBackend); |
| 894 }; | 895 }; |
| 895 | 896 |
| 896 } // namespace history | 897 } // namespace history |
| 897 | 898 |
| 898 #endif // COMPONENTS_HISTORY_CORE_BROWSER_HISTORY_BACKEND_H_ | 899 #endif // COMPONENTS_HISTORY_CORE_BROWSER_HISTORY_BACKEND_H_ |
| OLD | NEW |