| OLD | NEW |
| 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 13 matching lines...) Expand all Loading... |
| 24 * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, | 24 * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, |
| 25 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY | 25 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY |
| 26 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT | 26 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT |
| 27 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE | 27 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE |
| 28 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | 28 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
| 29 */ | 29 */ |
| 30 | 30 |
| 31 #ifndef WebURLRequest_h | 31 #ifndef WebURLRequest_h |
| 32 #define WebURLRequest_h | 32 #define WebURLRequest_h |
| 33 | 33 |
| 34 #include "WebAddressSpace.h" |
| 34 #include "WebCommon.h" | 35 #include "WebCommon.h" |
| 35 #include "WebHTTPBody.h" | 36 #include "WebHTTPBody.h" |
| 36 #include "WebReferrerPolicy.h" | 37 #include "WebReferrerPolicy.h" |
| 37 | 38 |
| 38 namespace blink { | 39 namespace blink { |
| 39 | 40 |
| 40 class ResourceRequest; | 41 class ResourceRequest; |
| 41 class WebHTTPBody; | 42 class WebHTTPBody; |
| 42 class WebHTTPHeaderVisitor; | 43 class WebHTTPHeaderVisitor; |
| 43 class WebSecurityOrigin; | 44 class WebSecurityOrigin; |
| (...skipping 13 matching lines...) Expand all Loading... |
| 57 | 58 |
| 58 enum Priority { | 59 enum Priority { |
| 59 PriorityUnresolved = -1, | 60 PriorityUnresolved = -1, |
| 60 PriorityVeryLow, | 61 PriorityVeryLow, |
| 61 PriorityLow, | 62 PriorityLow, |
| 62 PriorityMedium, | 63 PriorityMedium, |
| 63 PriorityHigh, | 64 PriorityHigh, |
| 64 PriorityVeryHigh, | 65 PriorityVeryHigh, |
| 65 }; | 66 }; |
| 66 | 67 |
| 67 // The ordering is important, as it's used to determine whether preflights a
re required, | |
| 68 // as per https://mikewest.github.io/cors-rfc1918/#framework | |
| 69 enum AddressSpace { | |
| 70 AddressSpaceLocal = 0, // loopback, link local | |
| 71 AddressSpacePrivate, // Reserved by RFC1918 | |
| 72 AddressSpacePublic // Everything else | |
| 73 }; | |
| 74 | |
| 75 // Corresponds to Fetch's "context": http://fetch.spec.whatwg.org/#concept-r
equest-context | 68 // Corresponds to Fetch's "context": http://fetch.spec.whatwg.org/#concept-r
equest-context |
| 76 enum RequestContext { | 69 enum RequestContext { |
| 77 RequestContextUnspecified = 0, | 70 RequestContextUnspecified = 0, |
| 78 RequestContextAudio, | 71 RequestContextAudio, |
| 79 RequestContextBeacon, | 72 RequestContextBeacon, |
| 80 RequestContextCSPReport, | 73 RequestContextCSPReport, |
| 81 RequestContextDownload, | 74 RequestContextDownload, |
| 82 RequestContextEmbed, | 75 RequestContextEmbed, |
| 83 RequestContextEventSource, | 76 RequestContextEventSource, |
| 84 RequestContextFavicon, | 77 RequestContextFavicon, |
| (...skipping 241 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 326 protected: | 319 protected: |
| 327 BLINK_PLATFORM_EXPORT void assign(WebURLRequestPrivate*); | 320 BLINK_PLATFORM_EXPORT void assign(WebURLRequestPrivate*); |
| 328 | 321 |
| 329 private: | 322 private: |
| 330 WebURLRequestPrivate* m_private; | 323 WebURLRequestPrivate* m_private; |
| 331 }; | 324 }; |
| 332 | 325 |
| 333 } // namespace blink | 326 } // namespace blink |
| 334 | 327 |
| 335 #endif | 328 #endif |
| OLD | NEW |