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

Side by Side Diff: Source/modules/serviceworkers/ServiceWorkerScriptCachedMetadataHandler.h

Issue 1228833004: Oilpan: Move CachedMetadataHandler to Oilpan heap on Oilpan-enabled world. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Move #if directives. Created 5 years, 5 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
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 ServiceWorkerScriptCachedMetadataHandler_h 5 #ifndef ServiceWorkerScriptCachedMetadataHandler_h
6 #define ServiceWorkerScriptCachedMetadataHandler_h 6 #define ServiceWorkerScriptCachedMetadataHandler_h
7 7
8 #include "core/fetch/CachedMetadataHandler.h" 8 #include "core/fetch/CachedMetadataHandler.h"
9 #include "platform/weborigin/KURL.h" 9 #include "platform/weborigin/KURL.h"
10 #include "wtf/PassOwnPtr.h" 10 #include "wtf/PassOwnPtr.h"
11 #include "wtf/Vector.h" 11 #include "wtf/Vector.h"
12 12
13 namespace blink { 13 namespace blink {
14 14
15 class WorkerGlobalScope; 15 class WorkerGlobalScope;
16 class CachedMetadata; 16 class CachedMetadata;
17 17
18 class ServiceWorkerScriptCachedMetadataHandler : public CachedMetadataHandler { 18 class ServiceWorkerScriptCachedMetadataHandler : public CachedMetadataHandler {
19 public: 19 public:
20 static PassOwnPtr<ServiceWorkerScriptCachedMetadataHandler> create(WorkerGlo balScope* workerGlobalScope, const KURL& scriptURL, const Vector<char>* metaData ) 20 static PassOwnPtrWillBeRawPtr<ServiceWorkerScriptCachedMetadataHandler> crea te(WorkerGlobalScope* workerGlobalScope, const KURL& scriptURL, const Vector<cha r>* metaData)
21 { 21 {
22 return adoptPtr(new ServiceWorkerScriptCachedMetadataHandler(workerGloba lScope, scriptURL, metaData)); 22 return adoptPtrWillBeNoop(new ServiceWorkerScriptCachedMetadataHandler(w orkerGlobalScope, scriptURL, metaData));
23 } 23 }
24 ~ServiceWorkerScriptCachedMetadataHandler() override; 24 ~ServiceWorkerScriptCachedMetadataHandler() override;
25 DECLARE_VIRTUAL_TRACE();
25 void setCachedMetadata(unsigned dataTypeID, const char*, size_t, CacheType) override; 26 void setCachedMetadata(unsigned dataTypeID, const char*, size_t, CacheType) override;
26 void clearCachedMetadata(CacheType) override; 27 void clearCachedMetadata(CacheType) override;
27 CachedMetadata* cachedMetadata(unsigned dataTypeID) const override; 28 CachedMetadata* cachedMetadata(unsigned dataTypeID) const override;
28 String encoding() const override; 29 String encoding() const override;
29 30
30 private: 31 private:
31 ServiceWorkerScriptCachedMetadataHandler(WorkerGlobalScope*, const KURL& scr iptURL, const Vector<char>* metaData); 32 ServiceWorkerScriptCachedMetadataHandler(WorkerGlobalScope*, const KURL& scr iptURL, const Vector<char>* metaData);
32 33
33 WorkerGlobalScope* m_workerGlobalScope; 34 RawPtrWillBeMember<WorkerGlobalScope> m_workerGlobalScope;
34 KURL m_scriptURL; 35 KURL m_scriptURL;
35 RefPtr<CachedMetadata> m_cachedMetadata; 36 RefPtr<CachedMetadata> m_cachedMetadata;
36 }; 37 };
37 38
38 } // namespace blink 39 } // namespace blink
39 40
40 #endif // ServiceWorkerScriptCachedMetadataHandler_h 41 #endif // ServiceWorkerScriptCachedMetadataHandler_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698