OLD | NEW |
(Empty) | |
| 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 |
| 3 // found in the LICENSE file. |
| 4 |
| 5 #ifndef WEBKIT_DOM_STORAGE_LOCAL_STORAGE_DATABASE_ADAPTER_H_ |
| 6 #define WEBKIT_DOM_STORAGE_LOCAL_STORAGE_DATABASE_ADAPTER_H_ |
| 7 #pragma once |
| 8 |
| 9 #include "base/memory/scoped_ptr.h" |
| 10 #include "webkit/dom_storage/dom_storage_database_adapter.h" |
| 11 |
| 12 namespace dom_storage { |
| 13 |
| 14 class DomStorageDatabase; |
| 15 |
| 16 class LocalStorageDatabaseAdapter : public DomStorageDatabaseAdapter { |
| 17 public: |
| 18 explicit LocalStorageDatabaseAdapter(DomStorageDatabase* db); |
| 19 virtual ~LocalStorageDatabaseAdapter(); |
| 20 virtual void ReadAllValues(ValuesMap* result) OVERRIDE; |
| 21 virtual bool CommitChanges(bool clear_all_first, |
| 22 const ValuesMap& changes) OVERRIDE; |
| 23 virtual void DeleteFiles() OVERRIDE; |
| 24 virtual void Reset() OVERRIDE; |
| 25 private: |
| 26 scoped_ptr<DomStorageDatabase> db_; |
| 27 |
| 28 DISALLOW_COPY_AND_ASSIGN(LocalStorageDatabaseAdapter); |
| 29 }; |
| 30 |
| 31 } // namespace dom_storage |
| 32 |
| 33 #endif // WEBKIT_DOM_STORAGE_LOCAL_STORAGE_DATABASE_ADAPTER_H_ |
OLD | NEW |