Index: Source/core/workers/WorkerScriptLoader.h |
diff --git a/Source/core/workers/WorkerScriptLoader.h b/Source/core/workers/WorkerScriptLoader.h |
index 91a68d1176f4445be3a9e22ee3962c4321fb68c6..4890d26ed8e74bf1b60f89836c56883281f74f1e 100644 |
--- a/Source/core/workers/WorkerScriptLoader.h |
+++ b/Source/core/workers/WorkerScriptLoader.h |
@@ -40,66 +40,66 @@ |
namespace blink { |
- class ResourceRequest; |
- class ResourceResponse; |
- class ExecutionContext; |
- class TextResourceDecoder; |
- class WorkerScriptLoaderClient; |
- |
- class WorkerScriptLoader final : public RefCounted<WorkerScriptLoader>, public ThreadableLoaderClient { |
- WTF_MAKE_FAST_ALLOCATED; |
- public: |
- static PassRefPtr<WorkerScriptLoader> create() |
- { |
- return adoptRef(new WorkerScriptLoader()); |
- } |
- |
- void loadSynchronously(ExecutionContext&, const KURL&, CrossOriginRequestPolicy); |
- void loadAsynchronously(ExecutionContext&, const KURL&, CrossOriginRequestPolicy, WorkerScriptLoaderClient*); |
- |
- void notifyError(); |
- |
- // This will immediately lead to notifyFinished() if loadAsynchronously |
- // is in progress. |
- void cancel(); |
- |
- void setClient(WorkerScriptLoaderClient* client) { m_client = client; } |
- |
- String script(); |
- const KURL& url() const { return m_url; } |
- const KURL& responseURL() const; |
- bool failed() const { return m_failed; } |
- unsigned long identifier() const { return m_identifier; } |
- |
- virtual void didReceiveResponse(unsigned long /*identifier*/, const ResourceResponse&) override; |
- virtual void didReceiveData(const char* data, unsigned dataLength) override; |
- virtual void didFinishLoading(unsigned long identifier, double) override; |
- virtual void didFail(const ResourceError&) override; |
- virtual void didFailRedirectCheck() override; |
- |
- void setRequestContext(blink::WebURLRequest::RequestContext requestContext) { m_requestContext = requestContext; } |
- |
- private: |
- friend class WTF::RefCounted<WorkerScriptLoader>; |
- |
- WorkerScriptLoader(); |
- virtual ~WorkerScriptLoader(); |
- |
- PassOwnPtr<ResourceRequest> createResourceRequest(); |
- void notifyFinished(); |
- |
- WorkerScriptLoaderClient* m_client; |
- RefPtr<ThreadableLoader> m_threadableLoader; |
- String m_responseEncoding; |
- OwnPtr<TextResourceDecoder> m_decoder; |
- StringBuilder m_script; |
- KURL m_url; |
- KURL m_responseURL; |
- bool m_failed; |
- unsigned long m_identifier; |
- bool m_finishing; |
- blink::WebURLRequest::RequestContext m_requestContext; |
- }; |
+class ResourceRequest; |
+class ResourceResponse; |
+class ExecutionContext; |
+class TextResourceDecoder; |
+class WorkerScriptLoaderClient; |
+ |
+class WorkerScriptLoader final : public RefCounted<WorkerScriptLoader>, public ThreadableLoaderClient { |
+ WTF_MAKE_FAST_ALLOCATED; |
+public: |
+ static PassRefPtr<WorkerScriptLoader> create() |
+ { |
+ return adoptRef(new WorkerScriptLoader()); |
+ } |
+ |
+ void loadSynchronously(ExecutionContext&, const KURL&, CrossOriginRequestPolicy); |
+ void loadAsynchronously(ExecutionContext&, const KURL&, CrossOriginRequestPolicy, WorkerScriptLoaderClient*); |
+ |
+ void notifyError(); |
+ |
+ // This will immediately lead to notifyFinished() if loadAsynchronously |
+ // is in progress. |
+ void cancel(); |
+ |
+ void setClient(WorkerScriptLoaderClient* client) { m_client = client; } |
+ |
+ String script(); |
+ const KURL& url() const { return m_url; } |
+ const KURL& responseURL() const; |
+ bool failed() const { return m_failed; } |
+ unsigned long identifier() const { return m_identifier; } |
+ |
+ virtual void didReceiveResponse(unsigned long /*identifier*/, const ResourceResponse&) override; |
+ virtual void didReceiveData(const char* data, unsigned dataLength) override; |
+ virtual void didFinishLoading(unsigned long identifier, double) override; |
+ virtual void didFail(const ResourceError&) override; |
+ virtual void didFailRedirectCheck() override; |
+ |
+ void setRequestContext(WebURLRequest::RequestContext requestContext) { m_requestContext = requestContext; } |
+ |
+private: |
+ friend class WTF::RefCounted<WorkerScriptLoader>; |
+ |
+ WorkerScriptLoader(); |
+ virtual ~WorkerScriptLoader(); |
+ |
+ PassOwnPtr<ResourceRequest> createResourceRequest(); |
+ void notifyFinished(); |
+ |
+ WorkerScriptLoaderClient* m_client; |
+ RefPtr<ThreadableLoader> m_threadableLoader; |
+ String m_responseEncoding; |
+ OwnPtr<TextResourceDecoder> m_decoder; |
+ StringBuilder m_script; |
+ KURL m_url; |
+ KURL m_responseURL; |
+ bool m_failed; |
+ unsigned long m_identifier; |
+ bool m_finishing; |
+ WebURLRequest::RequestContext m_requestContext; |
+}; |
} // namespace blink |