| 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 CONTENT_PUBLIC_BROWSER_INDEXED_DB_CONTEXT_H_ | 5 #ifndef CONTENT_PUBLIC_BROWSER_INDEXED_DB_CONTEXT_H_ |
| 6 #define CONTENT_PUBLIC_BROWSER_INDEXED_DB_CONTEXT_H_ | 6 #define CONTENT_PUBLIC_BROWSER_INDEXED_DB_CONTEXT_H_ |
| 7 | 7 |
| 8 #include <stdint.h> | 8 #include <stdint.h> |
| 9 | 9 |
| 10 #include <string> | 10 #include <string> |
| (...skipping 26 matching lines...) Expand all Loading... |
| 37 | 37 |
| 38 // Copies the indexed db files from this context to another. The | 38 // Copies the indexed db files from this context to another. The |
| 39 // indexed db directory in the destination context needs to be empty. | 39 // indexed db directory in the destination context needs to be empty. |
| 40 virtual void CopyOriginData(const GURL& origin_url, | 40 virtual void CopyOriginData(const GURL& origin_url, |
| 41 IndexedDBContext* dest_context) = 0; | 41 IndexedDBContext* dest_context) = 0; |
| 42 | 42 |
| 43 // Get the file name of the local storage file for the given origin. | 43 // Get the file name of the local storage file for the given origin. |
| 44 virtual base::FilePath GetFilePathForTesting( | 44 virtual base::FilePath GetFilePathForTesting( |
| 45 const GURL& origin_url) const = 0; | 45 const GURL& origin_url) const = 0; |
| 46 | 46 |
| 47 // Set the task runner for tests if browser main loop is not initialized. | 47 // Forget the origins/sizes read from disk. |
| 48 virtual void SetTaskRunnerForTesting( | 48 virtual void ResetCachesForTesting() = 0; |
| 49 base::SequencedTaskRunner* task_runner) = 0; | |
| 50 | 49 |
| 51 protected: | 50 protected: |
| 52 friend class base::RefCountedThreadSafe<IndexedDBContext>; | 51 friend class base::RefCountedThreadSafe<IndexedDBContext>; |
| 53 virtual ~IndexedDBContext() {} | 52 virtual ~IndexedDBContext() {} |
| 54 }; | 53 }; |
| 55 | 54 |
| 56 } // namespace content | 55 } // namespace content |
| 57 | 56 |
| 58 #endif // CONTENT_PUBLIC_BROWSER_INDEXED_DB_CONTEXT_H_ | 57 #endif // CONTENT_PUBLIC_BROWSER_INDEXED_DB_CONTEXT_H_ |
| OLD | NEW |