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

Side by Side Diff: net/url_request/url_request_job.h

Issue 13609002: fix a problem that android cannot download files with basic authentication (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 8 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef NET_URL_REQUEST_URL_REQUEST_JOB_H_ 5 #ifndef NET_URL_REQUEST_URL_REQUEST_JOB_H_
6 #define NET_URL_REQUEST_URL_REQUEST_JOB_H_ 6 #define NET_URL_REQUEST_URL_REQUEST_JOB_H_
7 7
8 #include <string> 8 #include <string>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 139 matching lines...) Expand 10 before | Expand all | Expand 10 after
150 // location. This may be used to implement protocol-specific restrictions. 150 // location. This may be used to implement protocol-specific restrictions.
151 // If this function returns false, then the URLRequest will fail 151 // If this function returns false, then the URLRequest will fail
152 // reporting ERR_UNSAFE_REDIRECT. 152 // reporting ERR_UNSAFE_REDIRECT.
153 virtual bool IsSafeRedirect(const GURL& location); 153 virtual bool IsSafeRedirect(const GURL& location);
154 154
155 // Called to determine if this response is asking for authentication. Only 155 // Called to determine if this response is asking for authentication. Only
156 // makes sense for some types of requests. The caller is responsible for 156 // makes sense for some types of requests. The caller is responsible for
157 // obtaining the credentials passing them to SetAuth. 157 // obtaining the credentials passing them to SetAuth.
158 virtual bool NeedsAuth(); 158 virtual bool NeedsAuth();
159 159
160 // Determine whether the request has authentication credentials. This call
161 // will return true of SetAuth() is called without any subsequent CancelAuth()
162 // calls.
163 virtual bool HasAuth() const OVERRIDE;
164
160 // Fills the authentication info with the server's response. 165 // Fills the authentication info with the server's response.
161 virtual void GetAuthChallengeInfo( 166 virtual void GetAuthChallengeInfo(
162 scoped_refptr<AuthChallengeInfo>* auth_info); 167 scoped_refptr<AuthChallengeInfo>* auth_info);
163 168
164 // Resend the request with authentication credentials. 169 // Resend the request with authentication credentials.
165 virtual void SetAuth(const AuthCredentials& credentials); 170 virtual void SetAuth(const AuthCredentials& credentials);
166 171
167 // Display the error page without asking for credentials again. 172 // Display the error page without asking for credentials again.
168 virtual void CancelAuth(); 173 virtual void CancelAuth();
169 174
(...skipping 222 matching lines...) Expand 10 before | Expand all | Expand 10 after
392 NetworkDelegate* network_delegate_; 397 NetworkDelegate* network_delegate_;
393 398
394 base::WeakPtrFactory<URLRequestJob> weak_factory_; 399 base::WeakPtrFactory<URLRequestJob> weak_factory_;
395 400
396 DISALLOW_COPY_AND_ASSIGN(URLRequestJob); 401 DISALLOW_COPY_AND_ASSIGN(URLRequestJob);
397 }; 402 };
398 403
399 } // namespace net 404 } // namespace net
400 405
401 #endif // NET_URL_REQUEST_URL_REQUEST_JOB_H_ 406 #endif // NET_URL_REQUEST_URL_REQUEST_JOB_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698