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

Side by Side Diff: third_party/WebKit/Source/modules/background_fetch/BackgroundFetchFailEvent.cpp

Issue 2744873002: Implement the Request/Response bits of Background Fetch (Closed)
Patch Set: comments 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 2017 The Chromium Authors. All rights reserved. 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 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 #include "modules/background_fetch/BackgroundFetchFailEvent.h" 5 #include "modules/background_fetch/BackgroundFetchFailEvent.h"
6 6
7 #include "modules/EventModulesNames.h" 7 #include "modules/EventModulesNames.h"
8 #include "modules/background_fetch/BackgroundFetchFailEventInit.h" 8 #include "modules/background_fetch/BackgroundFetchFailEventInit.h"
9 #include "modules/background_fetch/BackgroundFetchSettledRequest.h"
9 10
10 namespace blink { 11 namespace blink {
11 12
12 BackgroundFetchFailEvent::BackgroundFetchFailEvent( 13 BackgroundFetchFailEvent::BackgroundFetchFailEvent(
13 const AtomicString& type, 14 const AtomicString& type,
14 const BackgroundFetchFailEventInit& init) 15 const BackgroundFetchFailEventInit& init)
15 : BackgroundFetchEvent(type, init) {} 16 : BackgroundFetchEvent(type, init), m_failedFetches(init.failedFetches()) {}
16 17
17 BackgroundFetchFailEvent::~BackgroundFetchFailEvent() = default; 18 BackgroundFetchFailEvent::~BackgroundFetchFailEvent() = default;
18 19
20 HeapVector<Member<BackgroundFetchSettledRequest>>
21 BackgroundFetchFailEvent::failedFetches() const {
22 return m_failedFetches;
23 }
24
19 const AtomicString& BackgroundFetchFailEvent::interfaceName() const { 25 const AtomicString& BackgroundFetchFailEvent::interfaceName() const {
20 return EventNames::BackgroundFetchFailEvent; 26 return EventNames::BackgroundFetchFailEvent;
21 } 27 }
22 28
29 DEFINE_TRACE(BackgroundFetchFailEvent) {
30 visitor->trace(m_failedFetches);
31 BackgroundFetchEvent::trace(visitor);
32 }
33
23 } // namespace blink 34 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698