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

Side by Side Diff: third_party/WebKit/Source/modules/serviceworkers/ForeignFetchRespondWithObserver.h

Issue 2715663002: ServiceWorker: Factor out FetchEvent related logics from RespondWithObserver. (Closed)
Patch Set: ServiceWorker: Factor out FetchEvent related logics from RespondWithObserver. Created 3 years, 9 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 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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 ForeignFetchRespondWithObserver_h 5 #ifndef ForeignFetchRespondWithObserver_h
6 #define ForeignFetchRespondWithObserver_h 6 #define ForeignFetchRespondWithObserver_h
7 7
8 #include "modules/serviceworkers/RespondWithObserver.h" 8 #include "modules/serviceworkers/FetchRespondWithObserver.h"
9 9
10 namespace blink { 10 namespace blink {
11 11
12 // This class observes the service worker's handling of a ForeignFetchEvent and 12 // This class observes the service worker's handling of a ForeignFetchEvent and
13 // notifies the client. 13 // notifies the client.
14 class MODULES_EXPORT ForeignFetchRespondWithObserver final 14 class MODULES_EXPORT ForeignFetchRespondWithObserver final
15 : public RespondWithObserver { 15 : public FetchRespondWithObserver {
16 public: 16 public:
17 static ForeignFetchRespondWithObserver* create( 17 static ForeignFetchRespondWithObserver* create(
18 ExecutionContext*, 18 ExecutionContext*,
19 int eventID, 19 int eventID,
20 const KURL& requestURL, 20 const KURL& requestURL,
21 WebURLRequest::FetchRequestMode, 21 WebURLRequest::FetchRequestMode,
22 WebURLRequest::FetchRedirectMode, 22 WebURLRequest::FetchRedirectMode,
23 WebURLRequest::FrameType, 23 WebURLRequest::FrameType,
24 WebURLRequest::RequestContext, 24 WebURLRequest::RequestContext,
25 PassRefPtr<SecurityOrigin>, 25 PassRefPtr<SecurityOrigin>,
26 WaitUntilObserver*); 26 WaitUntilObserver*);
27 27
28 void responseWasFulfilled(const ScriptValue&) override; 28 void onResponseFulfilled(const ScriptValue&) override;
29 29
30 private: 30 private:
31 ForeignFetchRespondWithObserver(ExecutionContext*, 31 ForeignFetchRespondWithObserver(ExecutionContext*,
32 int eventID, 32 int eventID,
33 const KURL& requestURL, 33 const KURL& requestURL,
34 WebURLRequest::FetchRequestMode, 34 WebURLRequest::FetchRequestMode,
35 WebURLRequest::FetchRedirectMode, 35 WebURLRequest::FetchRedirectMode,
36 WebURLRequest::FrameType, 36 WebURLRequest::FrameType,
37 WebURLRequest::RequestContext, 37 WebURLRequest::RequestContext,
38 PassRefPtr<SecurityOrigin>, 38 PassRefPtr<SecurityOrigin>,
39 WaitUntilObserver*); 39 WaitUntilObserver*);
40 40
41 RefPtr<SecurityOrigin> m_requestOrigin; 41 RefPtr<SecurityOrigin> m_requestOrigin;
42 }; 42 };
43 43
44 } // namespace blink 44 } // namespace blink
45 45
46 #endif // ForeignFetchRespondWithObserver_h 46 #endif // ForeignFetchRespondWithObserver_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698