Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(205)

Side by Side Diff: webkit/dom_storage/dom_storage_session.h

Issue 10831116: Move SessionStorageNamespace entirely into NavigationController and support StoragePartitions. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: merged ToT Created 8 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « ui/views/controls/webview/webview.cc ('k') | webkit/dom_storage/dom_storage_session.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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_SESSION_H_ 5 #ifndef WEBKIT_DOM_STORAGE_DOM_STORAGE_SESSION_H_
6 #define WEBKIT_DOM_STORAGE_DOM_STORAGE_SESSION_H_ 6 #define WEBKIT_DOM_STORAGE_DOM_STORAGE_SESSION_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "base/basictypes.h" 10 #include "base/basictypes.h"
(...skipping 16 matching lines...) Expand all
27 // Constructs a |DomStorageSession| and assigns |persistent_namespace_id| 27 // Constructs a |DomStorageSession| and assigns |persistent_namespace_id|
28 // to it. Allocates a new non-persistent ID. 28 // to it. Allocates a new non-persistent ID.
29 DomStorageSession(DomStorageContext* context, 29 DomStorageSession(DomStorageContext* context,
30 const std::string& persistent_namespace_id); 30 const std::string& persistent_namespace_id);
31 31
32 int64 namespace_id() const { return namespace_id_; } 32 int64 namespace_id() const { return namespace_id_; }
33 const std::string& persistent_namespace_id() const { 33 const std::string& persistent_namespace_id() const {
34 return persistent_namespace_id_; 34 return persistent_namespace_id_;
35 } 35 }
36 void SetShouldPersist(bool should_persist); 36 void SetShouldPersist(bool should_persist);
37 bool IsFromContext(DomStorageContext* context);
37 DomStorageSession* Clone(); 38 DomStorageSession* Clone();
38 39
39 // Constructs a |DomStorageSession| by cloning 40 // Constructs a |DomStorageSession| by cloning
40 // |namespace_id_to_clone|. Allocates new IDs for it. 41 // |namespace_id_to_clone|. Allocates new IDs for it.
41 static DomStorageSession* CloneFrom(DomStorageContext* context, 42 static DomStorageSession* CloneFrom(DomStorageContext* context,
42 int64 namepace_id_to_clone); 43 int64 namepace_id_to_clone);
43 44
44 private: 45 private:
45 friend class base::RefCountedThreadSafe<DomStorageSession>; 46 friend class base::RefCountedThreadSafe<DomStorageSession>;
46 47
47 DomStorageSession(DomStorageContext* context, 48 DomStorageSession(DomStorageContext* context,
48 int64 namespace_id, 49 int64 namespace_id,
49 const std::string& persistent_namespace_id); 50 const std::string& persistent_namespace_id);
50 ~DomStorageSession(); 51 ~DomStorageSession();
51 52
52 scoped_refptr<DomStorageContext> context_; 53 scoped_refptr<DomStorageContext> context_;
53 int64 namespace_id_; 54 int64 namespace_id_;
54 std::string persistent_namespace_id_; 55 std::string persistent_namespace_id_;
55 bool should_persist_; 56 bool should_persist_;
56 57
57 DISALLOW_IMPLICIT_CONSTRUCTORS(DomStorageSession); 58 DISALLOW_IMPLICIT_CONSTRUCTORS(DomStorageSession);
58 }; 59 };
59 60
60 } // namespace dom_storage 61 } // namespace dom_storage
61 62
62 #endif // WEBKIT_DOM_STORAGE_DOM_STORAGE_SESSION_H_ 63 #endif // WEBKIT_DOM_STORAGE_DOM_STORAGE_SESSION_H_
OLDNEW
« no previous file with comments | « ui/views/controls/webview/webview.cc ('k') | webkit/dom_storage/dom_storage_session.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698