OLD | NEW |
---|---|
(Empty) | |
1 // Copyright 2017 The Chromium Authors. All rights reserved. | |
2 // Use of this source code is governed by a BSD-style license that can be | |
3 // found in the LICENSE file. | |
4 | |
5 #ifndef PaymentRequestRespondWithObserver_h | |
6 #define PaymentRequestRespondWithObserver_h | |
7 | |
8 #include "modules/ModulesExport.h" | |
9 #include "modules/serviceworkers/RespondWithObserver.h" | |
10 #include "public/platform/modules/serviceworker/WebServiceWorkerResponseError.h" | |
11 | |
12 namespace blink { | |
13 | |
14 class ExecutionContext; | |
15 class ScriptValue; | |
16 class WaitUntilObserver; | |
17 | |
18 // This class observes the service worker's handling of a PaymentReqestEvent and | |
nhiroki
2017/03/08 02:28:16
s/PaymentReqestEvent/PaymentRequestEvent/
zino
2017/03/10 17:57:52
Done.
| |
19 // notifies the client. | |
20 class MODULES_EXPORT PaymentRequestRespondWithObserver | |
shimazu
2017/03/08 01:39:25
I feel this class could be placed under modules/pa
nhiroki
2017/03/08 02:28:16
final?
zino
2017/03/10 17:57:52
Done.
| |
21 : public RespondWithObserver { | |
22 public: | |
23 virtual ~PaymentRequestRespondWithObserver(); | |
24 | |
25 static PaymentRequestRespondWithObserver* create(ExecutionContext*, | |
26 int eventID, | |
27 WaitUntilObserver*); | |
28 | |
29 void didDispatchEvent(DispatchEventResult dispatchResult) override; | |
30 void responseWasRejected(WebServiceWorkerResponseError) override; | |
31 void responseWasFulfilled(const ScriptValue&) override; | |
32 | |
33 DECLARE_VIRTUAL_TRACE(); | |
34 | |
35 protected: | |
nhiroki
2017/03/08 02:28:16
private?
zino
2017/03/10 17:57:52
Done.
| |
36 PaymentRequestRespondWithObserver(ExecutionContext*, | |
37 int eventID, | |
38 WaitUntilObserver*); | |
39 }; | |
40 | |
41 } // namespace blink | |
42 | |
43 #endif // PaymentRequestRespondWithObserver_h | |
OLD | NEW |