| 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 WEBKIT_APPCACHE_APPCACHE_STORAGE_IMPL_H_ | 5 #ifndef WEBKIT_APPCACHE_APPCACHE_STORAGE_IMPL_H_ |
| 6 #define WEBKIT_APPCACHE_APPCACHE_STORAGE_IMPL_H_ | 6 #define WEBKIT_APPCACHE_APPCACHE_STORAGE_IMPL_H_ |
| 7 | 7 |
| 8 #include <deque> | 8 #include <deque> |
| 9 #include <map> | 9 #include <map> |
| 10 #include <set> | |
| 11 #include <vector> | 10 #include <vector> |
| 12 | 11 |
| 13 #include "base/file_path.h" | 12 #include "base/file_path.h" |
| 14 #include "base/message_loop_proxy.h" | 13 #include "base/message_loop_proxy.h" |
| 15 #include "base/task.h" | 14 #include "base/task.h" |
| 16 #include "webkit/appcache/appcache_database.h" | 15 #include "webkit/appcache/appcache_database.h" |
| 17 #include "webkit/appcache/appcache_disk_cache.h" | 16 #include "webkit/appcache/appcache_disk_cache.h" |
| 18 #include "webkit/appcache/appcache_storage.h" | 17 #include "webkit/appcache/appcache_storage.h" |
| 19 | 18 |
| 20 namespace appcache { | 19 namespace appcache { |
| (...skipping 123 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 144 | 143 |
| 145 // Set if we discover a fatal error like a corrupt sql database or | 144 // Set if we discover a fatal error like a corrupt sql database or |
| 146 // disk cache and cannot continue. | 145 // disk cache and cannot continue. |
| 147 bool is_disabled_; | 146 bool is_disabled_; |
| 148 | 147 |
| 149 // TODO(michaeln): use a disk_cache per group (manifest or group_id). | 148 // TODO(michaeln): use a disk_cache per group (manifest or group_id). |
| 150 scoped_ptr<AppCacheDiskCache> disk_cache_; | 149 scoped_ptr<AppCacheDiskCache> disk_cache_; |
| 151 | 150 |
| 152 // Used to short-circuit certain operations without having to schedule | 151 // Used to short-circuit certain operations without having to schedule |
| 153 // any tasks on the background database thread. | 152 // any tasks on the background database thread. |
| 154 std::set<GURL> origins_with_groups_; | |
| 155 std::deque<Task*> pending_simple_tasks_; | 153 std::deque<Task*> pending_simple_tasks_; |
| 156 ScopedRunnableMethodFactory<AppCacheStorageImpl> method_factory_; | 154 ScopedRunnableMethodFactory<AppCacheStorageImpl> method_factory_; |
| 157 | 155 |
| 158 FRIEND_TEST_ALL_PREFIXES(ChromeAppCacheServiceTest, KeepOnDestruction); | 156 FRIEND_TEST_ALL_PREFIXES(ChromeAppCacheServiceTest, KeepOnDestruction); |
| 159 FRIEND_TEST_ALL_PREFIXES(ChromeAppCacheServiceTest, RemoveOnDestruction); | 157 FRIEND_TEST_ALL_PREFIXES(ChromeAppCacheServiceTest, RemoveOnDestruction); |
| 160 }; | 158 }; |
| 161 | 159 |
| 162 } // namespace appcache | 160 } // namespace appcache |
| 163 | 161 |
| 164 #endif // WEBKIT_APPCACHE_APPCACHE_STORAGE_IMPL_H_ | 162 #endif // WEBKIT_APPCACHE_APPCACHE_STORAGE_IMPL_H_ |
| OLD | NEW |