| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 #ifndef FetchRequestData_h | 5 #ifndef FetchRequestData_h |
| 6 #define FetchRequestData_h | 6 #define FetchRequestData_h |
| 7 | 7 |
| 8 #include "platform/heap/Handle.h" | 8 #include "platform/heap/Handle.h" |
| 9 #include "platform/weborigin/KURL.h" | 9 #include "platform/weborigin/KURL.h" |
| 10 #include "platform/weborigin/Referrer.h" | 10 #include "platform/weborigin/Referrer.h" |
| 11 #include "wtf/PassOwnPtr.h" | 11 #include "wtf/PassOwnPtr.h" |
| 12 #include "wtf/PassRefPtr.h" | 12 #include "wtf/PassRefPtr.h" |
| 13 #include "wtf/RefCounted.h" | 13 #include "wtf/RefCounted.h" |
| 14 #include "wtf/text/AtomicString.h" | 14 #include "wtf/text/AtomicString.h" |
| 15 #include "wtf/text/WTFString.h" | 15 #include "wtf/text/WTFString.h" |
| 16 | 16 |
| 17 namespace blink { | 17 namespace blink { |
| 18 class WebServiceWorkerRequest; | 18 class WebServiceWorkerRequest; |
| 19 } | 19 } |
| 20 | 20 |
| 21 namespace blink { | 21 namespace blink { |
| 22 | 22 |
| 23 class BlobDataHandle; |
| 23 class ExecutionContext; | 24 class ExecutionContext; |
| 24 class FetchHeaderList; | 25 class FetchHeaderList; |
| 25 struct ResourceLoaderOptions; | 26 struct ResourceLoaderOptions; |
| 26 class ResourceRequest; | 27 class ResourceRequest; |
| 27 class SecurityOrigin; | 28 class SecurityOrigin; |
| 28 struct ThreadableLoaderOptions; | 29 struct ThreadableLoaderOptions; |
| 29 | 30 |
| 30 class FetchRequestData FINAL : public RefCountedWillBeGarbageCollectedFinalized<
FetchRequestData> { | 31 class FetchRequestData FINAL : public RefCountedWillBeGarbageCollectedFinalized<
FetchRequestData> { |
| 31 WTF_MAKE_NONCOPYABLE(FetchRequestData); | 32 WTF_MAKE_NONCOPYABLE(FetchRequestData); |
| 32 public: | 33 public: |
| (...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 78 PassRefPtr<SecurityOrigin> origin() { return m_origin; } | 79 PassRefPtr<SecurityOrigin> origin() { return m_origin; } |
| 79 bool sameOriginDataURLFlag() { return m_sameOriginDataURLFlag; } | 80 bool sameOriginDataURLFlag() { return m_sameOriginDataURLFlag; } |
| 80 const Referrer& referrer() const { return m_referrer; } | 81 const Referrer& referrer() const { return m_referrer; } |
| 81 void setMode(Mode mode) { m_mode = mode; } | 82 void setMode(Mode mode) { m_mode = mode; } |
| 82 Mode mode() const { return m_mode; } | 83 Mode mode() const { return m_mode; } |
| 83 void setCredentials(Credentials credentials) { m_credentials = credentials;
} | 84 void setCredentials(Credentials credentials) { m_credentials = credentials;
} |
| 84 Credentials credentials() const { return m_credentials; } | 85 Credentials credentials() const { return m_credentials; } |
| 85 void setResponseTainting(Tainting tainting) { m_responseTainting = tainting;
} | 86 void setResponseTainting(Tainting tainting) { m_responseTainting = tainting;
} |
| 86 Tainting tainting() const { return m_responseTainting; } | 87 Tainting tainting() const { return m_responseTainting; } |
| 87 FetchHeaderList* headerList() { return m_headerList.get(); } | 88 FetchHeaderList* headerList() { return m_headerList.get(); } |
| 89 PassRefPtr<BlobDataHandle> blobDataHandle() const { return m_blobDataHandle;
} |
| 88 | 90 |
| 89 void trace(Visitor*); | 91 void trace(Visitor*); |
| 90 | 92 |
| 91 private: | 93 private: |
| 92 FetchRequestData(); | 94 FetchRequestData(); |
| 93 | 95 |
| 94 static PassRefPtrWillBeRawPtr<FetchRequestData> create(); | 96 static PassRefPtrWillBeRawPtr<FetchRequestData> create(); |
| 95 | 97 |
| 96 AtomicString m_method; | 98 AtomicString m_method; |
| 97 KURL m_url; | 99 KURL m_url; |
| 98 RefPtrWillBeMember<FetchHeaderList> m_headerList; | 100 RefPtrWillBeMember<FetchHeaderList> m_headerList; |
| 101 RefPtr<BlobDataHandle> m_blobDataHandle; |
| 99 bool m_unsafeRequestFlag; | 102 bool m_unsafeRequestFlag; |
| 100 // FIXME: Support body. | |
| 101 // FIXME: Support m_skipServiceWorkerFlag; | 103 // FIXME: Support m_skipServiceWorkerFlag; |
| 102 Context m_context; | 104 Context m_context; |
| 103 RefPtr<SecurityOrigin> m_origin; | 105 RefPtr<SecurityOrigin> m_origin; |
| 104 // FIXME: Support m_forceOriginHeaderFlag; | 106 // FIXME: Support m_forceOriginHeaderFlag; |
| 105 bool m_sameOriginDataURLFlag; | 107 bool m_sameOriginDataURLFlag; |
| 106 Referrer m_referrer; | 108 Referrer m_referrer; |
| 107 // FIXME: Support m_authenticationFlag; | 109 // FIXME: Support m_authenticationFlag; |
| 108 // FIXME: Support m_synchronousFlag; | 110 // FIXME: Support m_synchronousFlag; |
| 109 Mode m_mode; | 111 Mode m_mode; |
| 110 Credentials m_credentials; | 112 Credentials m_credentials; |
| 111 // FIXME: Support m_useURLCredentialsFlag; | 113 // FIXME: Support m_useURLCredentialsFlag; |
| 112 // FIXME: Support m_manualRedirectFlag; | 114 // FIXME: Support m_manualRedirectFlag; |
| 113 // FIXME: Support m_redirectCount; | 115 // FIXME: Support m_redirectCount; |
| 114 Tainting m_responseTainting; | 116 Tainting m_responseTainting; |
| 115 }; | 117 }; |
| 116 | 118 |
| 117 } // namespace blink | 119 } // namespace blink |
| 118 | 120 |
| 119 #endif // FetchRequestData_h | 121 #endif // FetchRequestData_h |
| OLD | NEW |