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

Side by Side Diff: third_party/WebKit/Source/modules/fetch/FetchResponseData.h

Issue 1746483002: Revert of Pipe response_time from FetchManager to CacheStorage and ServiceWorkerURLRequestJob. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 9 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 unified diff | Download patch
OLDNEW
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 FetchResponseData_h 5 #ifndef FetchResponseData_h
6 #define FetchResponseData_h 6 #define FetchResponseData_h
7 7
8 #include "modules/ModulesExport.h" 8 #include "modules/ModulesExport.h"
9 #include "platform/heap/Handle.h" 9 #include "platform/heap/Handle.h"
10 #include "platform/weborigin/KURL.h" 10 #include "platform/weborigin/KURL.h"
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
43 43
44 Type type() const { return m_type; } 44 Type type() const { return m_type; }
45 const KURL& url() const { return m_url; } 45 const KURL& url() const { return m_url; }
46 unsigned short status() const { return m_status; } 46 unsigned short status() const { return m_status; }
47 AtomicString statusMessage() const { return m_statusMessage; } 47 AtomicString statusMessage() const { return m_statusMessage; }
48 FetchHeaderList* headerList() const { return m_headerList.get(); } 48 FetchHeaderList* headerList() const { return m_headerList.get(); }
49 BodyStreamBuffer* buffer() const { return m_buffer; } 49 BodyStreamBuffer* buffer() const { return m_buffer; }
50 String mimeType() const; 50 String mimeType() const;
51 BodyStreamBuffer* internalBuffer() const; 51 BodyStreamBuffer* internalBuffer() const;
52 String internalMIMEType() const; 52 String internalMIMEType() const;
53 int64_t responseTime() const { return m_responseTime; }
54 53
55 void setURL(const KURL& url) { m_url = url; } 54 void setURL(const KURL& url) { m_url = url; }
56 void setStatus(unsigned short status) { m_status = status; } 55 void setStatus(unsigned short status) { m_status = status; }
57 void setStatusMessage(AtomicString statusMessage) { m_statusMessage = status Message; } 56 void setStatusMessage(AtomicString statusMessage) { m_statusMessage = status Message; }
58 void setMIMEType(const String& type) { m_mimeType = type; } 57 void setMIMEType(const String& type) { m_mimeType = type; }
59 void setResponseTime(int64_t responseTime) { m_responseTime = responseTime; }
60 58
61 // If the type is Default, replaces |m_buffer|. 59 // If the type is Default, replaces |m_buffer|.
62 // If the type is Basic or CORS, replaces |m_buffer| and 60 // If the type is Basic or CORS, replaces |m_buffer| and
63 // |m_internalResponse->m_buffer|. 61 // |m_internalResponse->m_buffer|.
64 // If the type is Error or Opaque, does nothing. 62 // If the type is Error or Opaque, does nothing.
65 void replaceBodyStreamBuffer(BodyStreamBuffer*); 63 void replaceBodyStreamBuffer(BodyStreamBuffer*);
66 64
67 // Does not call response.setBlobDataHandle(). 65 // Does not call response.setBlobDataHandle().
68 void populateWebServiceWorkerResponse(WebServiceWorkerResponse& /* response */); 66 void populateWebServiceWorkerResponse(WebServiceWorkerResponse& /* response */);
69 67
70 DECLARE_TRACE(); 68 DECLARE_TRACE();
71 69
72 private: 70 private:
73 FetchResponseData(Type, unsigned short, AtomicString); 71 FetchResponseData(Type, unsigned short, AtomicString);
74 72
75 Type m_type; 73 Type m_type;
76 OwnPtr<TerminationReason> m_terminationReason; 74 OwnPtr<TerminationReason> m_terminationReason;
77 KURL m_url; 75 KURL m_url;
78 unsigned short m_status; 76 unsigned short m_status;
79 AtomicString m_statusMessage; 77 AtomicString m_statusMessage;
80 Member<FetchHeaderList> m_headerList; 78 Member<FetchHeaderList> m_headerList;
81 Member<FetchResponseData> m_internalResponse; 79 Member<FetchResponseData> m_internalResponse;
82 Member<BodyStreamBuffer> m_buffer; 80 Member<BodyStreamBuffer> m_buffer;
83 String m_mimeType; 81 String m_mimeType;
84 int64_t m_responseTime;
85 }; 82 };
86 83
87 } // namespace blink 84 } // namespace blink
88 85
89 #endif // FetchResponseData_h 86 #endif // FetchResponseData_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698