OLD | NEW |
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2013 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 #include "content/browser/indexed_db/indexed_db_factory_impl.h" | 5 #include "content/browser/indexed_db/indexed_db_factory_impl.h" |
6 | 6 |
7 #include <utility> | 7 #include <utility> |
8 #include <vector> | 8 #include <vector> |
9 | 9 |
10 #include "base/logging.h" | 10 #include "base/logging.h" |
11 #include "base/strings/utf_string_conversions.h" | 11 #include "base/strings/utf_string_conversions.h" |
12 #include "base/time/time.h" | 12 #include "base/time/time.h" |
13 #include "content/browser/indexed_db/indexed_db_backing_store.h" | 13 #include "content/browser/indexed_db/indexed_db_backing_store.h" |
14 #include "content/browser/indexed_db/indexed_db_context_impl.h" | 14 #include "content/browser/indexed_db/indexed_db_context_impl.h" |
15 #include "content/browser/indexed_db/indexed_db_database_error.h" | 15 #include "content/browser/indexed_db/indexed_db_database_error.h" |
16 #include "content/browser/indexed_db/indexed_db_tracing.h" | 16 #include "content/browser/indexed_db/indexed_db_tracing.h" |
17 #include "content/browser/indexed_db/indexed_db_transaction_coordinator.h" | 17 #include "content/browser/indexed_db/indexed_db_transaction_coordinator.h" |
18 #include "storage/common/database/database_identifier.h" | 18 #include "storage/common/database/database_identifier.h" |
19 #include "third_party/WebKit/public/platform/WebIDBDatabaseException.h" | 19 #include "third_party/WebKit/public/platform/modules/indexeddb/WebIDBDatabaseExc
eption.h" |
20 #include "third_party/leveldatabase/env_chromium.h" | 20 #include "third_party/leveldatabase/env_chromium.h" |
21 | 21 |
22 using base::ASCIIToUTF16; | 22 using base::ASCIIToUTF16; |
23 | 23 |
24 namespace content { | 24 namespace content { |
25 | 25 |
26 const int64 kBackingStoreGracePeriodMs = 2000; | 26 const int64 kBackingStoreGracePeriodMs = 2000; |
27 | 27 |
28 IndexedDBFactoryImpl::IndexedDBFactoryImpl(IndexedDBContextImpl* context) | 28 IndexedDBFactoryImpl::IndexedDBFactoryImpl(IndexedDBContextImpl* context) |
29 : context_(context) { | 29 : context_(context) { |
(...skipping 464 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
494 size_t count(0); | 494 size_t count(0); |
495 | 495 |
496 OriginDBs range = GetOpenDatabasesForOrigin(origin_url); | 496 OriginDBs range = GetOpenDatabasesForOrigin(origin_url); |
497 for (OriginDBMapIterator it = range.first; it != range.second; ++it) | 497 for (OriginDBMapIterator it = range.first; it != range.second; ++it) |
498 count += it->second->ConnectionCount(); | 498 count += it->second->ConnectionCount(); |
499 | 499 |
500 return count; | 500 return count; |
501 } | 501 } |
502 | 502 |
503 } // namespace content | 503 } // namespace content |
OLD | NEW |