OLD | NEW |
(Empty) | |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. |
| 4 |
| 5 #ifndef WEBKIT_BROWSER_FILEAPI_SANDBOX_ISOLATED_ORIGIN_DATABASE_H_ |
| 6 #define WEBKIT_BROWSER_FILEAPI_SANDBOX_ISOLATED_ORIGIN_DATABASE_H_ |
| 7 |
| 8 #include "webkit/browser/fileapi/sandbox_origin_database_interface.h" |
| 9 |
| 10 namespace fileapi { |
| 11 |
| 12 class WEBKIT_STORAGE_EXPORT_PRIVATE SandboxIsolatedOriginDatabase |
| 13 : public SandboxOriginDatabaseInterface { |
| 14 public: |
| 15 explicit SandboxIsolatedOriginDatabase( |
| 16 const std::string& origin, |
| 17 const base::FilePath& file_system_directory); |
| 18 virtual ~SandboxIsolatedOriginDatabase(); |
| 19 |
| 20 // SandboxOriginDatabaseInterface overrides. |
| 21 virtual bool HasOriginPath(const std::string& origin) OVERRIDE; |
| 22 virtual bool GetPathForOrigin(const std::string& origin, |
| 23 base::FilePath* directory) OVERRIDE; |
| 24 virtual bool RemovePathForOrigin(const std::string& origin) OVERRIDE; |
| 25 virtual bool ListAllOrigins(std::vector<OriginRecord>* origins) OVERRIDE; |
| 26 virtual void DropDatabase() OVERRIDE; |
| 27 |
| 28 private: |
| 29 void MigrateDatabaseIfNeeded(); |
| 30 |
| 31 bool migration_checked_; |
| 32 const std::string origin_; |
| 33 const base::FilePath file_system_directory_; |
| 34 |
| 35 DISALLOW_COPY_AND_ASSIGN(SandboxIsolatedOriginDatabase); |
| 36 }; |
| 37 |
| 38 } // namespace fileapi |
| 39 |
| 40 #endif // WEBKIT_BROWSER_FILEAPI_SANDBOX_ISOLATED_ORIGIN_DATABASE_H_ |
OLD | NEW |