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

Side by Side Diff: third_party/WebKit/public/platform/WebURLRequest.h

Issue 1987413002: Add link preload as=document support Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: crash fix Created 4 years, 3 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 | « third_party/WebKit/Source/platform/network/ResourceRequest.cpp ('k') | no next file » | 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) 2009 Google Inc. All rights reserved. 2 * Copyright (C) 2009 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 are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * 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 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 83 matching lines...) Expand 10 before | Expand all | Expand 10 after
94 RequestContextWorker, 94 RequestContextWorker,
95 RequestContextXMLHttpRequest, 95 RequestContextXMLHttpRequest,
96 RequestContextXSLT 96 RequestContextXSLT
97 }; 97 };
98 98
99 // Corresponds to Fetch's "context frame type": http://fetch.spec.whatwg.org /#concept-request-context-frame-type 99 // Corresponds to Fetch's "context frame type": http://fetch.spec.whatwg.org /#concept-request-context-frame-type
100 enum FrameType { 100 enum FrameType {
101 FrameTypeAuxiliary, 101 FrameTypeAuxiliary,
102 FrameTypeNested, 102 FrameTypeNested,
103 FrameTypeNone, 103 FrameTypeNone,
104 FrameTypeTopLevel 104 FrameTypeTopLevel,
105 FrameTypePreload
105 }; 106 };
106 107
107 enum FetchRequestMode { 108 enum FetchRequestMode {
108 FetchRequestModeSameOrigin, 109 FetchRequestModeSameOrigin,
109 FetchRequestModeNoCORS, 110 FetchRequestModeNoCORS,
110 FetchRequestModeCORS, 111 FetchRequestModeCORS,
111 FetchRequestModeCORSWithForcedPreflight, 112 FetchRequestModeCORSWithForcedPreflight,
112 FetchRequestModeNavigate 113 FetchRequestModeNavigate
113 }; 114 };
114 115
(...skipping 159 matching lines...) Expand 10 before | Expand all | Expand 10 after
274 BLINK_PLATFORM_EXPORT void setFetchCredentialsMode(FetchCredentialsMode); 275 BLINK_PLATFORM_EXPORT void setFetchCredentialsMode(FetchCredentialsMode);
275 276
276 // The redirect mode which is used in Fetch API. 277 // The redirect mode which is used in Fetch API.
277 BLINK_PLATFORM_EXPORT FetchRedirectMode getFetchRedirectMode() const; 278 BLINK_PLATFORM_EXPORT FetchRedirectMode getFetchRedirectMode() const;
278 BLINK_PLATFORM_EXPORT void setFetchRedirectMode(FetchRedirectMode); 279 BLINK_PLATFORM_EXPORT void setFetchRedirectMode(FetchRedirectMode);
279 280
280 // The LoFi state which determines whether to request a Lo-Fi version of the resource. 281 // The LoFi state which determines whether to request a Lo-Fi version of the resource.
281 BLINK_PLATFORM_EXPORT LoFiState getLoFiState() const; 282 BLINK_PLATFORM_EXPORT LoFiState getLoFiState() const;
282 BLINK_PLATFORM_EXPORT void setLoFiState(LoFiState); 283 BLINK_PLATFORM_EXPORT void setLoFiState(LoFiState);
283 284
285 // Is the request triggered by a link preload?
286 BLINK_PLATFORM_EXPORT bool linkPreload() const;
287
284 // Extra data associated with the underlying resource request. Resource 288 // Extra data associated with the underlying resource request. Resource
285 // requests can be copied. If non-null, each copy of a resource requests 289 // requests can be copied. If non-null, each copy of a resource requests
286 // holds a pointer to the extra data, and the extra data pointer will be 290 // holds a pointer to the extra data, and the extra data pointer will be
287 // deleted when the last resource request is destroyed. Setting the extra 291 // deleted when the last resource request is destroyed. Setting the extra
288 // data pointer will cause the underlying resource request to be 292 // data pointer will cause the underlying resource request to be
289 // dissociated from any existing non-null extra data pointer. 293 // dissociated from any existing non-null extra data pointer.
290 BLINK_PLATFORM_EXPORT ExtraData* getExtraData() const; 294 BLINK_PLATFORM_EXPORT ExtraData* getExtraData() const;
291 BLINK_PLATFORM_EXPORT void setExtraData(ExtraData*); 295 BLINK_PLATFORM_EXPORT void setExtraData(ExtraData*);
292 296
293 BLINK_PLATFORM_EXPORT Priority getPriority() const; 297 BLINK_PLATFORM_EXPORT Priority getPriority() const;
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
331 // instance it contains. 335 // instance it contains.
332 std::unique_ptr<ResourceRequestContainer> m_ownedResourceRequest; 336 std::unique_ptr<ResourceRequestContainer> m_ownedResourceRequest;
333 337
334 // Should never be null. 338 // Should never be null.
335 ResourceRequest* m_resourceRequest; 339 ResourceRequest* m_resourceRequest;
336 }; 340 };
337 341
338 } // namespace blink 342 } // namespace blink
339 343
340 #endif 344 #endif
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/platform/network/ResourceRequest.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698