Index: Source/modules/fetch/FetchResponseData.h |
diff --git a/Source/modules/fetch/FetchResponseData.h b/Source/modules/fetch/FetchResponseData.h |
index 463cef4947136d55f7ece5cdeb7ff6e7a41d555e..dd3ec415d55e41c0b015b04ddaa9e2641da77505 100644 |
--- a/Source/modules/fetch/FetchResponseData.h |
+++ b/Source/modules/fetch/FetchResponseData.h |
@@ -15,7 +15,9 @@ |
namespace blink { |
class BlobDataHandle; |
-class BodyStreamBuffer; |
+class BodyStreamBuffer2; |
+class ExecutionContext; |
+class FetchDataConsumerHandle; |
class FetchHeaderList; |
class WebServiceWorkerResponse; |
@@ -31,39 +33,37 @@ public: |
static FetchResponseData* create(); |
static FetchResponseData* createNetworkErrorResponse(); |
- static FetchResponseData* createWithBuffer(BodyStreamBuffer*); |
+ static FetchResponseData* createWithBuffer(BodyStreamBuffer2*); |
FetchResponseData* createBasicFilteredResponse(); |
FetchResponseData* createCORSFilteredResponse(); |
FetchResponseData* createOpaqueFilteredResponse(); |
- FetchResponseData* clone(); |
+ FetchResponseData* clone(ExecutionContext*); |
Type type() const { return m_type; } |
const KURL& url() const { return m_url; } |
unsigned short status() const { return m_status; } |
AtomicString statusMessage() const { return m_statusMessage; } |
FetchHeaderList* headerList() const { return m_headerList.get(); } |
- PassRefPtr<BlobDataHandle> blobDataHandle() const { return m_blobDataHandle; } |
- BodyStreamBuffer* buffer() const { return m_buffer; } |
+ BodyStreamBuffer2* buffer() const { return m_buffer; } |
String mimeType() const; |
- PassRefPtr<BlobDataHandle> internalBlobDataHandle() const; |
- BodyStreamBuffer* internalBuffer() const; |
+ BodyStreamBuffer2* internalBuffer() const; |
String internalMIMEType() const; |
void setURL(const KURL& url) { m_url = url; } |
void setStatus(unsigned short status) { m_status = status; } |
void setStatusMessage(AtomicString statusMessage) { m_statusMessage = statusMessage; } |
- void setBlobDataHandle(PassRefPtr<BlobDataHandle>); |
void setMIMEType(const String& type) { m_mimeType = type; } |
- // If the type is Default, replaces |m_buffer| and sets |m_blobDataHandle| |
- // to nullptr. If the type is Basic or CORS, replaces |m_buffer| and sets |
- // |m_blobDataHandle| to nullptr, and does the same operation to |
- // |m_internalResponse|. If the type is Error or Opaque, does nothing. |
- void replaceBodyStreamBuffer(BodyStreamBuffer*); |
+ // If the type is Default, replaces |m_buffer|. |
+ // If the type is Basic or CORS, replaces |m_buffer| and |
+ // |m_internalResponse->m_buffer|. |
+ // If the type is Error or Opaque, does nothing. |
+ void replaceBodyStreamBuffer(BodyStreamBuffer2*); |
- void populateWebServiceWorkerResponse(WebServiceWorkerResponse&); |
+ // Does not call response.setBlobDataHandle(). |
+ void populateWebServiceWorkerResponse(WebServiceWorkerResponse& /* response */); |
DECLARE_TRACE(); |
@@ -78,7 +78,7 @@ private: |
Member<FetchHeaderList> m_headerList; |
RefPtr<BlobDataHandle> m_blobDataHandle; |
Member<FetchResponseData> m_internalResponse; |
- Member<BodyStreamBuffer> m_buffer; |
+ Member<BodyStreamBuffer2> m_buffer; |
String m_mimeType; |
}; |