| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2008 Apple Inc. All Rights Reserved. | 2 * Copyright (C) 2008 Apple Inc. All Rights Reserved. |
| 3 * | 3 * |
| 4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
| 5 * modification, are permitted provided that the following conditions | 5 * modification, are permitted provided that the following conditions |
| 6 * are met: | 6 * are met: |
| 7 * 1. Redistributions of source code must retain the above copyright | 7 * 1. Redistributions of source code must retain the above copyright |
| 8 * notice, this list of conditions and the following disclaimer. | 8 * notice, this list of conditions and the following disclaimer. |
| 9 * 2. Redistributions in binary form must reproduce the above copyright | 9 * 2. Redistributions in binary form must reproduce the above copyright |
| 10 * notice, this list of conditions and the following disclaimer in the | 10 * notice, this list of conditions and the following disclaimer in the |
| (...skipping 10 matching lines...) Expand all Loading... |
| 21 * OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT | 21 * OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT |
| 22 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE | 22 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE |
| 23 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | 23 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
| 24 */ | 24 */ |
| 25 | 25 |
| 26 #ifndef StorageNamespace_h | 26 #ifndef StorageNamespace_h |
| 27 #define StorageNamespace_h | 27 #define StorageNamespace_h |
| 28 | 28 |
| 29 #include "modules/ModulesExport.h" | 29 #include "modules/ModulesExport.h" |
| 30 #include "platform/heap/Handle.h" | 30 #include "platform/heap/Handle.h" |
| 31 #include "wtf/OwnPtr.h" | 31 #include <memory> |
| 32 #include "wtf/PassOwnPtr.h" | |
| 33 | 32 |
| 34 namespace blink { | 33 namespace blink { |
| 35 | 34 |
| 36 class WebStorageNamespace; | 35 class WebStorageNamespace; |
| 37 class SecurityOrigin; | 36 class SecurityOrigin; |
| 38 class StorageArea; | 37 class StorageArea; |
| 39 | 38 |
| 40 class MODULES_EXPORT StorageNamespace { | 39 class MODULES_EXPORT StorageNamespace { |
| 41 USING_FAST_MALLOC(StorageNamespace); | 40 USING_FAST_MALLOC(StorageNamespace); |
| 42 public: | 41 public: |
| 43 explicit StorageNamespace(PassOwnPtr<WebStorageNamespace>); | 42 explicit StorageNamespace(std::unique_ptr<WebStorageNamespace>); |
| 44 ~StorageNamespace(); | 43 ~StorageNamespace(); |
| 45 | 44 |
| 46 static StorageArea* localStorageArea(SecurityOrigin*); | 45 static StorageArea* localStorageArea(SecurityOrigin*); |
| 47 | 46 |
| 48 StorageArea* storageArea(SecurityOrigin*); | 47 StorageArea* storageArea(SecurityOrigin*); |
| 49 bool isSameNamespace(const WebStorageNamespace& sessionNamespace) const; | 48 bool isSameNamespace(const WebStorageNamespace& sessionNamespace) const; |
| 50 | 49 |
| 51 private: | 50 private: |
| 52 OwnPtr<WebStorageNamespace> m_webStorageNamespace; | 51 std::unique_ptr<WebStorageNamespace> m_webStorageNamespace; |
| 53 }; | 52 }; |
| 54 | 53 |
| 55 } // namespace blink | 54 } // namespace blink |
| 56 | 55 |
| 57 #endif // StorageNamespace_h | 56 #endif // StorageNamespace_h |
| OLD | NEW |