diff options
Diffstat (limited to 'chromium/third_party/WebKit/Source/modules/serviceworkers/FetchManager.h')
-rw-r--r-- | chromium/third_party/WebKit/Source/modules/serviceworkers/FetchManager.h | 36 |
1 files changed, 36 insertions, 0 deletions
diff --git a/chromium/third_party/WebKit/Source/modules/serviceworkers/FetchManager.h b/chromium/third_party/WebKit/Source/modules/serviceworkers/FetchManager.h new file mode 100644 index 00000000000..eadbc97ca2f --- /dev/null +++ b/chromium/third_party/WebKit/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 |