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

Side by Side Diff: third_party/WebKit/Source/core/fetch/FetchRequest.h

Issue 1987013002: Add UMA to track time between preload discovery and reference (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@preload_timing_uma
Patch Set: update histograms.xml to be a bit clearer Created 4 years, 6 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
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/fetch/FetchRequest.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2012 Google, Inc. All rights reserved. 2 * Copyright (C) 2012 Google, Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 1. Redistributions of source code must retain the above copyright 7 * 1. Redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer. 8 * notice, this list of conditions and the following disclaimer.
9 * 2. Redistributions in binary form must reproduce the above copyright 9 * 2. Redistributions in binary form must reproduce the above copyright
10 * notice, this list of conditions and the following disclaimer in the 10 * notice, this list of conditions and the following disclaimer in the
(...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after
78 78
79 DeferOption defer() const { return m_defer; } 79 DeferOption defer() const { return m_defer; }
80 void setDefer(DeferOption defer) { m_defer = defer; } 80 void setDefer(DeferOption defer) { m_defer = defer; }
81 81
82 ResourceWidth getResourceWidth() const { return m_resourceWidth; } 82 ResourceWidth getResourceWidth() const { return m_resourceWidth; }
83 void setResourceWidth(ResourceWidth); 83 void setResourceWidth(ResourceWidth);
84 84
85 ClientHintsPreferences& clientHintsPreferences() { return m_clientHintPrefer ences; } 85 ClientHintsPreferences& clientHintsPreferences() { return m_clientHintPrefer ences; }
86 86
87 bool forPreload() const { return m_forPreload; } 87 bool forPreload() const { return m_forPreload; }
88 void setForPreload(bool forPreload) { m_forPreload = forPreload; } 88 void setForPreload(bool forPreload, double discoveryTime = 0);
89
90 double preloadDiscoveryTime() { return m_preloadDiscoveryTime; }
89 91
90 bool isLinkPreload() { return m_linkPreload; } 92 bool isLinkPreload() { return m_linkPreload; }
91 void setLinkPreload(bool isLinkPreload) { m_linkPreload = isLinkPreload; } 93 void setLinkPreload(bool isLinkPreload) { m_linkPreload = isLinkPreload; }
92 94
93 void setContentSecurityCheck(ContentSecurityPolicyDisposition contentSecurit yPolicyOption) { m_options.contentSecurityPolicyOption = contentSecurityPolicyOp tion; } 95 void setContentSecurityCheck(ContentSecurityPolicyDisposition contentSecurit yPolicyOption) { m_options.contentSecurityPolicyOption = contentSecurityPolicyOp tion; }
94 void setCrossOriginAccessControl(SecurityOrigin*, CrossOriginAttributeValue) ; 96 void setCrossOriginAccessControl(SecurityOrigin*, CrossOriginAttributeValue) ;
95 OriginRestriction getOriginRestriction() const { return m_originRestriction; } 97 OriginRestriction getOriginRestriction() const { return m_originRestriction; }
96 void setOriginRestriction(OriginRestriction restriction) { m_originRestricti on = restriction; } 98 void setOriginRestriction(OriginRestriction restriction) { m_originRestricti on = restriction; }
97 const IntegrityMetadataSet& integrityMetadata() const { return m_integrityMe tadata; } 99 const IntegrityMetadataSet& integrityMetadata() const { return m_integrityMe tadata; }
98 void setIntegrityMetadata(const IntegrityMetadataSet& metadata) { m_integrit yMetadata = metadata; } 100 void setIntegrityMetadata(const IntegrityMetadataSet& metadata) { m_integrit yMetadata = metadata; }
99 101
100 private: 102 private:
101 ResourceRequest m_resourceRequest; 103 ResourceRequest m_resourceRequest;
102 String m_charset; 104 String m_charset;
103 ResourceLoaderOptions m_options; 105 ResourceLoaderOptions m_options;
104 ResourceLoadPriority m_priority; 106 ResourceLoadPriority m_priority;
105 bool m_forPreload; 107 bool m_forPreload;
106 bool m_linkPreload; 108 bool m_linkPreload;
109 double m_preloadDiscoveryTime;
107 DeferOption m_defer; 110 DeferOption m_defer;
108 OriginRestriction m_originRestriction; 111 OriginRestriction m_originRestriction;
109 ResourceWidth m_resourceWidth; 112 ResourceWidth m_resourceWidth;
110 ClientHintsPreferences m_clientHintPreferences; 113 ClientHintsPreferences m_clientHintPreferences;
111 IntegrityMetadataSet m_integrityMetadata; 114 IntegrityMetadataSet m_integrityMetadata;
112 }; 115 };
113 116
114 } // namespace blink 117 } // namespace blink
115 118
116 #endif 119 #endif
OLDNEW
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/fetch/FetchRequest.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698