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

Side by Side Diff: third_party/WebKit/Source/platform/network/ResourceResponse.h

Issue 1710733002: Move multipart resource handling to core/fetch (2/2) (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@multipart-cleanup
Patch Set: rebase Created 4 years, 10 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 /* 1 /*
2 * Copyright (C) 2006, 2008 Apple Inc. All rights reserved. 2 * Copyright (C) 2006, 2008 Apple Inc. All rights reserved.
3 * Copyright (C) 2009 Google Inc. All rights reserved. 3 * Copyright (C) 2009 Google Inc. All rights reserved.
4 * 4 *
5 * Redistribution and use in source and binary forms, with or without 5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions 6 * modification, are permitted provided that the following conditions
7 * are met: 7 * are met:
8 * 1. Redistributions of source code must retain the above copyright 8 * 1. Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * 2. Redistributions in binary form must reproduce the above copyright 10 * 2. Redistributions in binary form must reproduce the above copyright
(...skipping 199 matching lines...) Expand 10 before | Expand all | Expand 10 after
210 210
211 WebServiceWorkerResponseType serviceWorkerResponseType() const { return m_se rviceWorkerResponseType; } 211 WebServiceWorkerResponseType serviceWorkerResponseType() const { return m_se rviceWorkerResponseType; }
212 void setServiceWorkerResponseType(WebServiceWorkerResponseType value) { m_se rviceWorkerResponseType = value; } 212 void setServiceWorkerResponseType(WebServiceWorkerResponseType value) { m_se rviceWorkerResponseType = value; }
213 213
214 const KURL& originalURLViaServiceWorker() const { return m_originalURLViaSer viceWorker; } 214 const KURL& originalURLViaServiceWorker() const { return m_originalURLViaSer viceWorker; }
215 void setOriginalURLViaServiceWorker(const KURL& url) { m_originalURLViaServi ceWorker = url; } 215 void setOriginalURLViaServiceWorker(const KURL& url) { m_originalURLViaServi ceWorker = url; }
216 216
217 bool isMultipartPayload() const { return m_isMultipartPayload; } 217 bool isMultipartPayload() const { return m_isMultipartPayload; }
218 void setIsMultipartPayload(bool value) { m_isMultipartPayload = value; } 218 void setIsMultipartPayload(bool value) { m_isMultipartPayload = value; }
219 219
220 const Vector<char>& multipartBoundary() const { return m_multipartBoundary; }
221 void setMultipartBoundary(const char* bytes, size_t size)
222 {
223 m_multipartBoundary.clear();
224 m_multipartBoundary.append(bytes, size);
225 }
226
220 int64_t responseTime() const { return m_responseTime; } 227 int64_t responseTime() const { return m_responseTime; }
221 void setResponseTime(int64_t responseTime) { m_responseTime = responseTime; } 228 void setResponseTime(int64_t responseTime) { m_responseTime = responseTime; }
222 229
223 const AtomicString& remoteIPAddress() const { return m_remoteIPAddress; } 230 const AtomicString& remoteIPAddress() const { return m_remoteIPAddress; }
224 void setRemoteIPAddress(const AtomicString& value) { m_remoteIPAddress = val ue; } 231 void setRemoteIPAddress(const AtomicString& value) { m_remoteIPAddress = val ue; }
225 232
226 unsigned short remotePort() const { return m_remotePort; } 233 unsigned short remotePort() const { return m_remotePort; }
227 void setRemotePort(unsigned short value) { m_remotePort = value; } 234 void setRemotePort(unsigned short value) { m_remotePort = value; }
228 235
229 const String& downloadedFilePath() const { return m_downloadedFilePath; } 236 const String& downloadedFilePath() const { return m_downloadedFilePath; }
(...skipping 68 matching lines...) Expand 10 before | Expand all | Expand 10 after
298 HTTPVersion m_httpVersion; 305 HTTPVersion m_httpVersion;
299 306
300 // The id of the appcache this response was retrieved from, or zero if 307 // The id of the appcache this response was retrieved from, or zero if
301 // the response was not retrieved from an appcache. 308 // the response was not retrieved from an appcache.
302 long long m_appCacheID; 309 long long m_appCacheID;
303 310
304 // The manifest url of the appcache this response was retrieved from, if any . 311 // The manifest url of the appcache this response was retrieved from, if any .
305 // Note: only valid for main resource responses. 312 // Note: only valid for main resource responses.
306 KURL m_appCacheManifestURL; 313 KURL m_appCacheManifestURL;
307 314
315 // The multipart boundary of this response.
316 Vector<char> m_multipartBoundary;
317
308 // Set to true if this is part of a multipart response. 318 // Set to true if this is part of a multipart response.
309 bool m_isMultipartPayload; 319 bool m_isMultipartPayload;
310 320
311 // Was the resource fetched over SPDY. See http://dev.chromium.org/spdy 321 // Was the resource fetched over SPDY. See http://dev.chromium.org/spdy
312 bool m_wasFetchedViaSPDY; 322 bool m_wasFetchedViaSPDY;
313 323
314 // Was the resource fetched over a channel which used TLS/Next-Protocol-Nego tiation (also SPDY related). 324 // Was the resource fetched over a channel which used TLS/Next-Protocol-Nego tiation (also SPDY related).
315 bool m_wasNpnNegotiated; 325 bool m_wasNpnNegotiated;
316 326
317 // Was the resource fetched over a channel which specified "Alternate-Protoc ol" 327 // Was the resource fetched over a channel which specified "Alternate-Protoc ol"
(...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after
372 OwnPtr<CrossThreadHTTPHeaderMapData> m_httpHeaders; 382 OwnPtr<CrossThreadHTTPHeaderMapData> m_httpHeaders;
373 time_t m_lastModifiedDate; 383 time_t m_lastModifiedDate;
374 RefPtr<ResourceLoadTiming> m_resourceLoadTiming; 384 RefPtr<ResourceLoadTiming> m_resourceLoadTiming;
375 CString m_securityInfo; 385 CString m_securityInfo;
376 bool m_hasMajorCertificateErrors; 386 bool m_hasMajorCertificateErrors;
377 ResourceResponse::SecurityStyle m_securityStyle; 387 ResourceResponse::SecurityStyle m_securityStyle;
378 ResourceResponse::SecurityDetails m_securityDetails; 388 ResourceResponse::SecurityDetails m_securityDetails;
379 ResourceResponse::HTTPVersion m_httpVersion; 389 ResourceResponse::HTTPVersion m_httpVersion;
380 long long m_appCacheID; 390 long long m_appCacheID;
381 KURL m_appCacheManifestURL; 391 KURL m_appCacheManifestURL;
392 Vector<char> m_multipartBoundary;
382 bool m_isMultipartPayload; 393 bool m_isMultipartPayload;
383 bool m_wasFetchedViaSPDY; 394 bool m_wasFetchedViaSPDY;
384 bool m_wasNpnNegotiated; 395 bool m_wasNpnNegotiated;
385 bool m_wasAlternateProtocolAvailable; 396 bool m_wasAlternateProtocolAvailable;
386 bool m_wasFetchedViaProxy; 397 bool m_wasFetchedViaProxy;
387 bool m_wasFetchedViaServiceWorker; 398 bool m_wasFetchedViaServiceWorker;
388 bool m_wasFallbackRequiredByServiceWorker; 399 bool m_wasFallbackRequiredByServiceWorker;
389 WebServiceWorkerResponseType m_serviceWorkerResponseType; 400 WebServiceWorkerResponseType m_serviceWorkerResponseType;
390 KURL m_originalURLViaServiceWorker; 401 KURL m_originalURLViaServiceWorker;
391 int64_t m_responseTime; 402 int64_t m_responseTime;
392 String m_remoteIPAddress; 403 String m_remoteIPAddress;
393 unsigned short m_remotePort; 404 unsigned short m_remotePort;
394 String m_downloadedFilePath; 405 String m_downloadedFilePath;
395 RefPtr<BlobDataHandle> m_downloadedFileHandle; 406 RefPtr<BlobDataHandle> m_downloadedFileHandle;
396 }; 407 };
397 408
398 } // namespace blink 409 } // namespace blink
399 410
400 #endif // ResourceResponse_h 411 #endif // ResourceResponse_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698