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

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

Issue 16155009: Update webkit/ to use scoped_refptr<T>::get() rather than implicit "operator T*" (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 6 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 | « webkit/dom_storage/dom_storage_area.cc ('k') | webkit/dom_storage/dom_storage_cached_area.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_CACHED_AREA_H_ 5 #ifndef WEBKIT_DOM_STORAGE_DOM_STORAGE_CACHED_AREA_H_
6 #define WEBKIT_DOM_STORAGE_DOM_STORAGE_CACHED_AREA_H_ 6 #define WEBKIT_DOM_STORAGE_DOM_STORAGE_CACHED_AREA_H_
7 7
8 #include <map> 8 #include <map>
9 9
10 #include "base/memory/ref_counted.h" 10 #include "base/memory/ref_counted.h"
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after
50 size_t MemoryBytesUsedByCache() const; 50 size_t MemoryBytesUsedByCache() const;
51 51
52 private: 52 private:
53 friend class DomStorageCachedAreaTest; 53 friend class DomStorageCachedAreaTest;
54 friend class base::RefCounted<DomStorageCachedArea>; 54 friend class base::RefCounted<DomStorageCachedArea>;
55 ~DomStorageCachedArea(); 55 ~DomStorageCachedArea();
56 56
57 // Primes the cache, loading all values for the area. 57 // Primes the cache, loading all values for the area.
58 void Prime(int connection_id); 58 void Prime(int connection_id);
59 void PrimeIfNeeded(int connection_id) { 59 void PrimeIfNeeded(int connection_id) {
60 if (!map_) 60 if (!map_.get())
61 Prime(connection_id); 61 Prime(connection_id);
62 } 62 }
63 63
64 // Resets the object back to its newly constructed state. 64 // Resets the object back to its newly constructed state.
65 void Reset(); 65 void Reset();
66 66
67 // Async completion callbacks for proxied operations. 67 // Async completion callbacks for proxied operations.
68 // These are used to maintain cache consistency by preventing 68 // These are used to maintain cache consistency by preventing
69 // mutation events from other processes from overwriting local 69 // mutation events from other processes from overwriting local
70 // changes made after the mutation. 70 // changes made after the mutation.
(...skipping 12 matching lines...) Expand all
83 int64 namespace_id_; 83 int64 namespace_id_;
84 GURL origin_; 84 GURL origin_;
85 scoped_refptr<DomStorageMap> map_; 85 scoped_refptr<DomStorageMap> map_;
86 scoped_refptr<DomStorageProxy> proxy_; 86 scoped_refptr<DomStorageProxy> proxy_;
87 base::WeakPtrFactory<DomStorageCachedArea> weak_factory_; 87 base::WeakPtrFactory<DomStorageCachedArea> weak_factory_;
88 }; 88 };
89 89
90 } // namespace dom_storage 90 } // namespace dom_storage
91 91
92 #endif // WEBKIT_DOM_STORAGE_DOM_STORAGE_CACHED_AREA_H_ 92 #endif // WEBKIT_DOM_STORAGE_DOM_STORAGE_CACHED_AREA_H_
OLDNEW
« no previous file with comments | « webkit/dom_storage/dom_storage_area.cc ('k') | webkit/dom_storage/dom_storage_cached_area.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698