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

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

Issue 938643002: Preserve original int64 time stamp in ResourceResponse. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: use long long Created 5 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 160 matching lines...) Expand 10 before | Expand all | Expand 10 after
171 171
172 const KURL& originalURLViaServiceWorker() const { return m_originalURLViaSer viceWorker; } 172 const KURL& originalURLViaServiceWorker() const { return m_originalURLViaSer viceWorker; }
173 void setOriginalURLViaServiceWorker(const KURL& url) { m_originalURLViaServi ceWorker = url; }; 173 void setOriginalURLViaServiceWorker(const KURL& url) { m_originalURLViaServi ceWorker = url; };
174 174
175 bool isMultipartPayload() const { return m_isMultipartPayload; } 175 bool isMultipartPayload() const { return m_isMultipartPayload; }
176 void setIsMultipartPayload(bool value) { m_isMultipartPayload = value; } 176 void setIsMultipartPayload(bool value) { m_isMultipartPayload = value; }
177 177
178 double responseTime() const { return m_responseTime; } 178 double responseTime() const { return m_responseTime; }
179 void setResponseTime(double responseTime) { m_responseTime = responseTime; } 179 void setResponseTime(double responseTime) { m_responseTime = responseTime; }
180 180
181 int64 originalResponseTime() const { return m_originalResponseTime; }
182 void setOriginalResponseTime(int64 originalResponseTime) { m_originalRespons eTime = originalResponseTime; }
183
181 const AtomicString& remoteIPAddress() const { return m_remoteIPAddress; } 184 const AtomicString& remoteIPAddress() const { return m_remoteIPAddress; }
182 void setRemoteIPAddress(const AtomicString& value) { m_remoteIPAddress = val ue; } 185 void setRemoteIPAddress(const AtomicString& value) { m_remoteIPAddress = val ue; }
183 186
184 unsigned short remotePort() const { return m_remotePort; } 187 unsigned short remotePort() const { return m_remotePort; }
185 void setRemotePort(unsigned short value) { m_remotePort = value; } 188 void setRemotePort(unsigned short value) { m_remotePort = value; }
186 189
187 const String& downloadedFilePath() const { return m_downloadedFilePath; } 190 const String& downloadedFilePath() const { return m_downloadedFilePath; }
188 void setDownloadedFilePath(const String&); 191 void setDownloadedFilePath(const String&);
189 192
190 // Extra data associated with this response. 193 // Extra data associated with this response.
(...skipping 84 matching lines...) Expand 10 before | Expand all | Expand 10 after
275 WebServiceWorkerResponseType m_serviceWorkerResponseType; 278 WebServiceWorkerResponseType m_serviceWorkerResponseType;
276 279
277 // The original URL of the response which was fetched by the ServiceWorker. 280 // The original URL of the response which was fetched by the ServiceWorker.
278 // This may be empty if the response was created inside the ServiceWorker. 281 // This may be empty if the response was created inside the ServiceWorker.
279 KURL m_originalURLViaServiceWorker; 282 KURL m_originalURLViaServiceWorker;
280 283
281 // The time at which the response headers were received. For cached 284 // The time at which the response headers were received. For cached
282 // responses, this time could be "far" in the past. 285 // responses, this time could be "far" in the past.
283 double m_responseTime; 286 double m_responseTime;
284 287
288 // The conversion to the double value in |m_responseTime| is lossy.
289 // This preserves the original response time stamp.
290 int64 m_originalResponseTime;
291
285 // Remote IP address of the socket which fetched this resource. 292 // Remote IP address of the socket which fetched this resource.
286 AtomicString m_remoteIPAddress; 293 AtomicString m_remoteIPAddress;
287 294
288 // Remote port number of the socket which fetched this resource. 295 // Remote port number of the socket which fetched this resource.
289 unsigned short m_remotePort; 296 unsigned short m_remotePort;
290 297
291 // The downloaded file path if the load streamed to a file. 298 // The downloaded file path if the load streamed to a file.
292 String m_downloadedFilePath; 299 String m_downloadedFilePath;
293 300
294 // The handle to the downloaded file to ensure the underlying file will not 301 // The handle to the downloaded file to ensure the underlying file will not
(...skipping 28 matching lines...) Expand all
323 bool m_isMultipartPayload; 330 bool m_isMultipartPayload;
324 bool m_wasFetchedViaSPDY; 331 bool m_wasFetchedViaSPDY;
325 bool m_wasNpnNegotiated; 332 bool m_wasNpnNegotiated;
326 bool m_wasAlternateProtocolAvailable; 333 bool m_wasAlternateProtocolAvailable;
327 bool m_wasFetchedViaProxy; 334 bool m_wasFetchedViaProxy;
328 bool m_wasFetchedViaServiceWorker; 335 bool m_wasFetchedViaServiceWorker;
329 bool m_wasFallbackRequiredByServiceWorker; 336 bool m_wasFallbackRequiredByServiceWorker;
330 WebServiceWorkerResponseType m_serviceWorkerResponseType; 337 WebServiceWorkerResponseType m_serviceWorkerResponseType;
331 KURL m_originalURLViaServiceWorker; 338 KURL m_originalURLViaServiceWorker;
332 double m_responseTime; 339 double m_responseTime;
340 int64 m_originalResponseTime;
333 String m_remoteIPAddress; 341 String m_remoteIPAddress;
334 unsigned short m_remotePort; 342 unsigned short m_remotePort;
335 String m_downloadedFilePath; 343 String m_downloadedFilePath;
336 RefPtr<BlobDataHandle> m_downloadedFileHandle; 344 RefPtr<BlobDataHandle> m_downloadedFileHandle;
337 }; 345 };
338 346
339 } // namespace blink 347 } // namespace blink
340 348
341 #endif // ResourceResponse_h 349 #endif // ResourceResponse_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698