Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 /* | 1 /* |
| 2 * Copyright (C) 2003, 2006 Apple Computer, Inc. All rights reserved. | 2 * Copyright (C) 2003, 2006 Apple Computer, Inc. All rights reserved. |
| 3 * Copyright (C) 2006 Samuel Weinig <sam.weinig@gmail.com> | 3 * Copyright (C) 2006 Samuel Weinig <sam.weinig@gmail.com> |
| 4 * Copyright (C) 2009, 2012 Google Inc. All rights reserved. | 4 * Copyright (C) 2009, 2012 Google Inc. All rights reserved. |
| 5 * | 5 * |
| 6 * Redistribution and use in source and binary forms, with or without | 6 * Redistribution and use in source and binary forms, with or without |
| 7 * modification, are permitted provided that the following conditions | 7 * modification, are permitted provided that the following conditions |
| 8 * are met: | 8 * are met: |
| 9 * 1. Redistributions of source code must retain the above copyright | 9 * 1. Redistributions of source code must retain the above copyright |
| 10 * notice, this list of conditions and the following disclaimer. | 10 * notice, this list of conditions and the following disclaimer. |
| (...skipping 75 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 86 ResourceRequest(const String& urlString) | 86 ResourceRequest(const String& urlString) |
| 87 { | 87 { |
| 88 initialize(KURL(ParsedURLString, urlString), UseProtocolCachePolicy); | 88 initialize(KURL(ParsedURLString, urlString), UseProtocolCachePolicy); |
| 89 } | 89 } |
| 90 | 90 |
| 91 ResourceRequest(const KURL& url) | 91 ResourceRequest(const KURL& url) |
| 92 { | 92 { |
| 93 initialize(url, UseProtocolCachePolicy); | 93 initialize(url, UseProtocolCachePolicy); |
| 94 } | 94 } |
| 95 | 95 |
| 96 ResourceRequest(const KURL& url, const Referrer& referrer, ResourceRequestCa chePolicy cachePolicy = UseProtocolCachePolicy) | 96 ResourceRequest(const KURL& url, const Referrer& referrer, ResourceRequestCa chePolicy cachePolicy = UseProtocolCachePolicy) |
|
ppi
2014/06/19 18:25:42
Should we add a specialized constructor like this
| |
| 97 { | 97 { |
| 98 initialize(url, cachePolicy); | 98 initialize(url, cachePolicy); |
| 99 setHTTPReferrer(referrer); | 99 setHTTPReferrer(referrer); |
| 100 } | 100 } |
| 101 | 101 |
| 102 static PassOwnPtr<ResourceRequest> adopt(PassOwnPtr<CrossThreadResourceReque stData>); | 102 static PassOwnPtr<ResourceRequest> adopt(PassOwnPtr<CrossThreadResourceReque stData>); |
| 103 | 103 |
| 104 // Gets a copy of the data suitable for passing to another thread. | 104 // Gets a copy of the data suitable for passing to another thread. |
| 105 PassOwnPtr<CrossThreadResourceRequestData> copyData() const; | 105 PassOwnPtr<CrossThreadResourceRequestData> copyData() const; |
| 106 | 106 |
| 107 // Initializes the TargetType and the ResourceLoadPriority for the main | |
| 108 // resource. | |
| 109 void initializeForMainResource(bool isMainFrame); | |
| 110 | |
| 107 bool isNull() const; | 111 bool isNull() const; |
| 108 bool isEmpty() const; | 112 bool isEmpty() const; |
| 109 | 113 |
| 110 const KURL& url() const; | 114 const KURL& url() const; |
| 111 void setURL(const KURL& url); | 115 void setURL(const KURL& url); |
| 112 | 116 |
| 113 void removeCredentials(); | 117 void removeCredentials(); |
| 114 | 118 |
| 115 ResourceRequestCachePolicy cachePolicy() const; | 119 ResourceRequestCachePolicy cachePolicy() const; |
| 116 void setCachePolicy(ResourceRequestCachePolicy cachePolicy); | 120 void setCachePolicy(ResourceRequestCachePolicy cachePolicy); |
| (...skipping 154 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 271 int m_appCacheHostID; | 275 int m_appCacheHostID; |
| 272 ResourceRequest::TargetType m_targetType; | 276 ResourceRequest::TargetType m_targetType; |
| 273 ReferrerPolicy m_referrerPolicy; | 277 ReferrerPolicy m_referrerPolicy; |
| 274 }; | 278 }; |
| 275 | 279 |
| 276 unsigned initializeMaximumHTTPConnectionCountPerHost(); | 280 unsigned initializeMaximumHTTPConnectionCountPerHost(); |
| 277 | 281 |
| 278 } // namespace WebCore | 282 } // namespace WebCore |
| 279 | 283 |
| 280 #endif // ResourceRequest_h | 284 #endif // ResourceRequest_h |
| OLD | NEW |