| 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 WEBKIT_DOM_STORAGE_DOM_STORAGE_CONTEXT_H_ | 5 #ifndef WEBKIT_DOM_STORAGE_DOM_STORAGE_CONTEXT_H_ |
| 6 #define WEBKIT_DOM_STORAGE_DOM_STORAGE_CONTEXT_H_ | 6 #define WEBKIT_DOM_STORAGE_DOM_STORAGE_CONTEXT_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include <map> | 9 #include <map> |
| 10 #include <vector> | 10 #include <vector> |
| (...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 78 const NullableString16& old_value, // may be null on initial insert | 78 const NullableString16& old_value, // may be null on initial insert |
| 79 const GURL& page_url) = 0; | 79 const GURL& page_url) = 0; |
| 80 virtual void OnDomStorageItemRemoved( | 80 virtual void OnDomStorageItemRemoved( |
| 81 const DomStorageArea* area, | 81 const DomStorageArea* area, |
| 82 const string16& key, | 82 const string16& key, |
| 83 const string16& old_value, | 83 const string16& old_value, |
| 84 const GURL& page_url) = 0; | 84 const GURL& page_url) = 0; |
| 85 virtual void OnDomStorageAreaCleared( | 85 virtual void OnDomStorageAreaCleared( |
| 86 const DomStorageArea* area, | 86 const DomStorageArea* area, |
| 87 const GURL& page_url) = 0; | 87 const GURL& page_url) = 0; |
| 88 |
| 89 protected: |
| 88 virtual ~EventObserver() {} | 90 virtual ~EventObserver() {} |
| 89 }; | 91 }; |
| 90 | 92 |
| 91 DomStorageContext( | 93 DomStorageContext( |
| 92 const FilePath& localstorage_directory, // empty for incognito profiles | 94 const FilePath& localstorage_directory, // empty for incognito profiles |
| 93 const FilePath& sessionstorage_directory, // empty for incognito profiles | 95 const FilePath& sessionstorage_directory, // empty for incognito profiles |
| 94 quota::SpecialStoragePolicy* special_storage_policy, | 96 quota::SpecialStoragePolicy* special_storage_policy, |
| 95 DomStorageTaskRunner* task_runner); | 97 DomStorageTaskRunner* task_runner); |
| 96 | 98 |
| 97 // Returns the directory path for localStorage, or an empty directory, if | 99 // Returns the directory path for localStorage, or an empty directory, if |
| (...skipping 94 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 192 | 194 |
| 193 bool is_shutdown_; | 195 bool is_shutdown_; |
| 194 bool clear_local_state_; | 196 bool clear_local_state_; |
| 195 bool save_session_state_; | 197 bool save_session_state_; |
| 196 scoped_refptr<quota::SpecialStoragePolicy> special_storage_policy_; | 198 scoped_refptr<quota::SpecialStoragePolicy> special_storage_policy_; |
| 197 }; | 199 }; |
| 198 | 200 |
| 199 } // namespace dom_storage | 201 } // namespace dom_storage |
| 200 | 202 |
| 201 #endif // WEBKIT_DOM_STORAGE_DOM_STORAGE_CONTEXT_H_ | 203 #endif // WEBKIT_DOM_STORAGE_DOM_STORAGE_CONTEXT_H_ |
| OLD | NEW |