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

Unified Diff: Source/modules/serviceworkers/FetchManager.h

Issue 318393002: Initial implementation of ServiceWorkerGlobalScope.fetch() (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: incoroporated dominicc's comment Created 6 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « Source/modules/modules.gypi ('k') | Source/modules/serviceworkers/FetchManager.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/modules/serviceworkers/FetchManager.h
diff --git a/Source/modules/serviceworkers/FetchManager.h b/Source/modules/serviceworkers/FetchManager.h
new file mode 100644
index 0000000000000000000000000000000000000000..eadbc97ca2ff94c562512a878e4cf1c3058ce861
--- /dev/null
+++ b/Source/modules/serviceworkers/FetchManager.h
@@ -0,0 +1,36 @@
+// Copyright 2014 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef FetchManager_h
+#define FetchManager_h
+
+#include "bindings/v8/ScriptPromise.h"
+#include "wtf/HashSet.h"
+#include "wtf/OwnPtr.h"
+
+namespace WebCore {
+
+class ExecutionContext;
+class ScriptState;
+class ResourceRequest;
+
+class FetchManager {
+public:
+ FetchManager(ExecutionContext*);
+ ~FetchManager();
+ ScriptPromise fetch(ScriptState*, PassOwnPtr<ResourceRequest>);
+
+private:
+ class Loader;
+
+ // Removes loader from |m_loaders|.
+ void onLoaderFinished(Loader*);
+
+ ExecutionContext* m_executionContext;
+ HashSet<OwnPtr<Loader> > m_loaders;
+};
+
+} // namespace WebCore
+
+#endif // FetchManager_h
« no previous file with comments | « Source/modules/modules.gypi ('k') | Source/modules/serviceworkers/FetchManager.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698