diff options
author | tfarina@chromium.org <tfarina@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-12-11 10:18:59 +0000 |
---|---|---|
committer | tfarina@chromium.org <tfarina@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-12-11 10:18:59 +0000 |
commit | 9acd869ec5621373757a6959310f39e1f5ec3f3d (patch) | |
tree | 43b9beab430d066670b7515579e20c755d9a0d4d /chrome | |
parent | 3f45597ed0041c49a627fd5e2be55ff6d5570022 (diff) | |
download | chromium_src-9acd869ec5621373757a6959310f39e1f5ec3f3d.zip chromium_src-9acd869ec5621373757a6959310f39e1f5ec3f3d.tar.gz chromium_src-9acd869ec5621373757a6959310f39e1f5ec3f3d.tar.bz2 |
net: Remove typedef net::URLRequestJob URLRequestJob;
BUG=64263
TEST=compiled locally, trybots
Review URL: http://codereview.chromium.org/5607004
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@68935 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome')
37 files changed, 99 insertions, 90 deletions
diff --git a/chrome/browser/appcache/view_appcache_internals_job_factory.cc b/chrome/browser/appcache/view_appcache_internals_job_factory.cc index 685be40..99ef75f 100644 --- a/chrome/browser/appcache/view_appcache_internals_job_factory.cc +++ b/chrome/browser/appcache/view_appcache_internals_job_factory.cc @@ -18,7 +18,7 @@ bool ViewAppCacheInternalsJobFactory::IsSupportedURL(const GURL& url) { } // static. -URLRequestJob* ViewAppCacheInternalsJobFactory::CreateJobForRequest( +net::URLRequestJob* ViewAppCacheInternalsJobFactory::CreateJobForRequest( net::URLRequest* request) { URLRequestContext* context = request->context(); ChromeURLRequestContext* chrome_request_context = diff --git a/chrome/browser/automation/url_request_automation_job.cc b/chrome/browser/automation/url_request_automation_job.cc index 874d600..12fd431 100644 --- a/chrome/browser/automation/url_request_automation_job.cc +++ b/chrome/browser/automation/url_request_automation_job.cc @@ -51,7 +51,7 @@ URLRequestAutomationJob::URLRequestAutomationJob( int request_id, AutomationResourceMessageFilter* filter, bool is_pending) - : URLRequestJob(request), + : net::URLRequestJob(request), id_(0), tab_(tab), message_filter_(filter), @@ -90,8 +90,9 @@ bool URLRequestAutomationJob::EnsureProtocolFactoryRegistered() { return true; } -URLRequestJob* URLRequestAutomationJob::Factory(net::URLRequest* request, - const std::string& scheme) { +net::URLRequestJob* URLRequestAutomationJob::Factory( + net::URLRequest* request, + const std::string& scheme) { bool scheme_is_http = request->url().SchemeIs("http"); bool scheme_is_https = request->url().SchemeIs("https"); @@ -127,7 +128,7 @@ URLRequestJob* URLRequestAutomationJob::Factory(net::URLRequest* request, return NULL; } -// URLRequestJob Implementation. +// net::URLRequestJob Implementation. void URLRequestAutomationJob::Start() { if (!is_pending()) { // Start reading asynchronously so that all error reporting and data @@ -152,7 +153,7 @@ void URLRequestAutomationJob::Kill() { } } DisconnectFromMessageFilter(); - URLRequestJob::Kill(); + net::URLRequestJob::Kill(); } bool URLRequestAutomationJob::ReadRawData( diff --git a/chrome/browser/automation/url_request_automation_job.h b/chrome/browser/automation/url_request_automation_job.h index 9928fd3..0c930ba 100644 --- a/chrome/browser/automation/url_request_automation_job.h +++ b/chrome/browser/automation/url_request_automation_job.h @@ -24,7 +24,7 @@ class Message; struct AutomationURLResponse; } -// URLRequestJob implementation that loads the resources using +// net::URLRequestJob implementation that loads the resources using // automation. class URLRequestAutomationJob : public net::URLRequestJob { public: @@ -37,7 +37,7 @@ class URLRequestAutomationJob : public net::URLRequestJob { static net::URLRequest::ProtocolFactory Factory; - // URLRequestJob methods. + // net::URLRequestJob methods. virtual void Start(); virtual void Kill(); virtual bool GetMimeType(std::string* mime_type) const; @@ -73,7 +73,7 @@ class URLRequestAutomationJob : public net::URLRequestJob { AutomationResourceMessageFilter* new_filter); protected: - // Protected URLRequestJob override. + // Protected net::URLRequestJob override. virtual bool ReadRawData(net::IOBuffer* buf, int buf_size, int* bytes_read); void StartAsync(); diff --git a/chrome/browser/chrome_plugin_host.cc b/chrome/browser/chrome_plugin_host.cc index 3dfedc8..9248036 100644 --- a/chrome/browser/chrome_plugin_host.cc +++ b/chrome/browser/chrome_plugin_host.cc @@ -56,7 +56,7 @@ using base::TimeDelta; class PluginRequestInterceptor : public PluginHelper, public net::URLRequest::Interceptor { public: - static URLRequestJob* UninterceptedProtocolHandler( + static net::URLRequestJob* UninterceptedProtocolHandler( net::URLRequest* request, const std::string& scheme) { // This will get called if a plugin failed to intercept a request for a // protocol it has registered. In that case, we return NULL and the request @@ -97,7 +97,7 @@ class PluginRequestInterceptor } // net::URLRequest::Interceptor - virtual URLRequestJob* MaybeIntercept(net::URLRequest* request) { + virtual net::URLRequestJob* MaybeIntercept(net::URLRequest* request) { // TODO(darin): This DCHECK fails in the unit tests because our interceptor // is being persisted across unit tests. As a result, each time we get // poked on a different thread, but never from more than one thread at a diff --git a/chrome/browser/chromeos/gview_request_interceptor.cc b/chrome/browser/chromeos/gview_request_interceptor.cc index c2e0e4b..69f97b2a 100644 --- a/chrome/browser/chromeos/gview_request_interceptor.cc +++ b/chrome/browser/chromeos/gview_request_interceptor.cc @@ -43,14 +43,14 @@ GViewRequestInterceptor::~GViewRequestInterceptor() { net::URLRequest::UnregisterRequestInterceptor(this); } -URLRequestJob* GViewRequestInterceptor::MaybeIntercept( +net::URLRequestJob* GViewRequestInterceptor::MaybeIntercept( net::URLRequest* request) { // Don't attempt to intercept here as we want to wait until the mime // type is fully determined. return NULL; } -URLRequestJob* GViewRequestInterceptor::MaybeInterceptResponse( +net::URLRequestJob* GViewRequestInterceptor::MaybeInterceptResponse( net::URLRequest* request) { // Do not intercept this request if it is a download. if (request->load_flags() & net::LOAD_IS_DOWNLOAD) { diff --git a/chrome/browser/chromeos/gview_request_interceptor.h b/chrome/browser/chromeos/gview_request_interceptor.h index cd8dfde..a8b8250 100644 --- a/chrome/browser/chromeos/gview_request_interceptor.h +++ b/chrome/browser/chromeos/gview_request_interceptor.h @@ -27,7 +27,7 @@ class GViewRequestInterceptor : public net::URLRequest::Interceptor { virtual net::URLRequestJob* MaybeIntercept(net::URLRequest* request); // Determines if the requested document can be viewed by the Google - // Document Viewer. If it can, returns a URLRequestJob that + // Document Viewer. If it can, returns a net::URLRequestJob that // redirects the browser to the view URL. virtual net::URLRequestJob* MaybeInterceptResponse(net::URLRequest* request); diff --git a/chrome/browser/chromeos/gview_request_interceptor_unittest.cc b/chrome/browser/chromeos/gview_request_interceptor_unittest.cc index 1f3b7be..ac72746 100644 --- a/chrome/browser/chromeos/gview_request_interceptor_unittest.cc +++ b/chrome/browser/chromeos/gview_request_interceptor_unittest.cc @@ -28,7 +28,7 @@ class GViewURLRequestTestJob : public URLRequestTestJob { // created -- the first is for the viewable document URL, and the // second is for the rediected URL. In order to test the // interceptor, the mime type of the first request must be one of - // the supported viewable mime types. So when the URLRequestJob + // the supported viewable mime types. So when the net::URLRequestJob // is a request for one of the test URLs that point to viewable // content, return an appropraite mime type. Otherwise, return // "text/html". @@ -60,8 +60,8 @@ class GViewRequestInterceptorTest : public testing::Test { message_loop_.RunAllPending(); } - static URLRequestJob* Factory(net::URLRequest* request, - const std::string& scheme) { + static net::URLRequestJob* Factory(net::URLRequest* request, + const std::string& scheme) { return new GViewURLRequestTestJob(request); } diff --git a/chrome/browser/chromeos/login/account_screen_browsertest.cc b/chrome/browser/chromeos/login/account_screen_browsertest.cc index 1e8840d..0e3a2d7 100644 --- a/chrome/browser/chromeos/login/account_screen_browsertest.cc +++ b/chrome/browser/chromeos/login/account_screen_browsertest.cc @@ -62,8 +62,8 @@ static void QuitUIMessageLoop() { static bool inspector_called = false; // had to use global flag as // InspectorHook() doesn't have context. -static URLRequestJob* InspectorHook(net::URLRequest* request, - const std::string& scheme) { +static net::URLRequestJob* InspectorHook(net::URLRequest* request, + const std::string& scheme) { VLOG(1) << "Intercepted: " << request->url() << ", scheme: " << scheme; // Expect that the parameters are the same as new_account.html gave us. diff --git a/chrome/browser/chromeos/login/registration_screen.cc b/chrome/browser/chromeos/login/registration_screen.cc index 9a93706..dbc2e68 100644 --- a/chrome/browser/chromeos/login/registration_screen.cc +++ b/chrome/browser/chromeos/login/registration_screen.cc @@ -142,8 +142,8 @@ void RegistrationScreen::CloseScreen(ScreenObserver::ExitCodes code) { } // static -URLRequestJob* RegistrationScreen::Factory(net::URLRequest* request, - const std::string& scheme) { +net::URLRequestJob* RegistrationScreen::Factory(net::URLRequest* request, + const std::string& scheme) { VLOG(1) << "Handling url: " << request->url().spec().c_str(); return new URLRequestAboutJob(request); } diff --git a/chrome/browser/dom_ui/chrome_url_data_manager.cc b/chrome/browser/dom_ui/chrome_url_data_manager.cc index 6153458..adfb744 100644 --- a/chrome/browser/dom_ui/chrome_url_data_manager.cc +++ b/chrome/browser/dom_ui/chrome_url_data_manager.cc @@ -34,15 +34,15 @@ #include "net/url_request/url_request_file_job.h" #include "net/url_request/url_request_job.h" -// URLRequestChromeJob is a URLRequestJob that manages running chrome-internal -// resource requests asynchronously. +// URLRequestChromeJob is a net::URLRequestJob that manages running +// chrome-internal resource requests asynchronously. // It hands off URL requests to ChromeURLDataManager, which asynchronously // calls back once the data is available. class URLRequestChromeJob : public net::URLRequestJob { public: explicit URLRequestChromeJob(net::URLRequest* request); - // URLRequestJob implementation. + // net::URLRequestJob implementation. virtual void Start(); virtual void Kill(); virtual bool ReadRawData(net::IOBuffer* buf, int buf_size, int *bytes_read); @@ -60,7 +60,7 @@ class URLRequestChromeJob : public net::URLRequestJob { virtual ~URLRequestChromeJob(); // Helper for Start(), to let us start asynchronously. - // (This pattern is shared by most URLRequestJob implementations.) + // (This pattern is shared by most net::URLRequestJob implementations.) void StartAsync(); // Do the actual copy from data_ (the data we're serving) into |buf|. @@ -82,7 +82,7 @@ class URLRequestChromeJob : public net::URLRequestJob { DISALLOW_COPY_AND_ASSIGN(URLRequestChromeJob); }; -// URLRequestChromeFileJob is a URLRequestJob that acts like a file:// URL +// URLRequestChromeFileJob is a net::URLRequestJob that acts like a file:// URL class URLRequestChromeFileJob : public URLRequestFileJob { public: URLRequestChromeFileJob(net::URLRequest* request, const FilePath& path); @@ -322,8 +322,8 @@ void ChromeURLDataManager::DataSource::SetFontAndTextDirection( base::i18n::IsRTL() ? "rtl" : "ltr"); } -URLRequestJob* ChromeURLDataManager::Factory(net::URLRequest* request, - const std::string& scheme) { +net::URLRequestJob* ChromeURLDataManager::Factory(net::URLRequest* request, + const std::string& scheme) { // Try first with a file handler FilePath path; if (ChromeURLDataManager::URLToFilePath(request->url(), &path)) @@ -346,7 +346,7 @@ URLRequestJob* ChromeURLDataManager::Factory(net::URLRequest* request, } URLRequestChromeJob::URLRequestChromeJob(net::URLRequest* request) - : URLRequestJob(request), + : net::URLRequestJob(request), data_offset_(0), pending_buf_size_(0) { } diff --git a/chrome/browser/dom_ui/mediaplayer_ui.cc b/chrome/browser/dom_ui/mediaplayer_ui.cc index 3119e534..f69ebcd 100644 --- a/chrome/browser/dom_ui/mediaplayer_ui.cc +++ b/chrome/browser/dom_ui/mediaplayer_ui.cc @@ -543,7 +543,7 @@ void MediaPlayer::PopupMediaPlayer(Browser* creator) { mediaplayer_browser_->window()->Show(); } -URLRequestJob* MediaPlayer::MaybeIntercept(net::URLRequest* request) { +net::URLRequestJob* MediaPlayer::MaybeIntercept(net::URLRequest* request) { // Don't attempt to intercept here as we want to wait until the mime // type is fully determined. return NULL; @@ -557,7 +557,7 @@ static const char* const supported_mime_type_list[] = { "audio/mp3" }; -URLRequestJob* MediaPlayer::MaybeInterceptResponse( +net::URLRequestJob* MediaPlayer::MaybeInterceptResponse( net::URLRequest* request) { // Do not intercept this request if it is a download. if (request->load_flags() & net::LOAD_IS_DOWNLOAD) { diff --git a/chrome/browser/dom_ui/mediaplayer_ui.h b/chrome/browser/dom_ui/mediaplayer_ui.h index ec198b2..c7168ee 100644 --- a/chrome/browser/dom_ui/mediaplayer_ui.h +++ b/chrome/browser/dom_ui/mediaplayer_ui.h @@ -78,7 +78,7 @@ class MediaPlayer : public NotificationObserver, virtual net::URLRequestJob* MaybeIntercept(net::URLRequest* request); // Determines if the requested document can be viewed by the - // MediaPlayer. If it can, returns a URLRequestJob that + // MediaPlayer. If it can, returns a net::URLRequestJob that // redirects the browser to the view URL. // Implementation of net::URLRequest::Interceptor. virtual net::URLRequestJob* MaybeInterceptResponse(net::URLRequest* request); diff --git a/chrome/browser/extensions/autoupdate_interceptor.cc b/chrome/browser/extensions/autoupdate_interceptor.cc index b50000c..e919189 100644 --- a/chrome/browser/extensions/autoupdate_interceptor.cc +++ b/chrome/browser/extensions/autoupdate_interceptor.cc @@ -33,7 +33,8 @@ AutoUpdateInterceptor::~AutoUpdateInterceptor() { net::URLRequest::UnregisterRequestInterceptor(this); } -URLRequestJob* AutoUpdateInterceptor::MaybeIntercept(net::URLRequest* request) { +net::URLRequestJob* AutoUpdateInterceptor::MaybeIntercept( + net::URLRequest* request) { EXPECT_TRUE(BrowserThread::CurrentlyOn(BrowserThread::IO)); if (request->url().scheme() != "http" || request->url().host() != "localhost") { diff --git a/chrome/browser/extensions/extension_protocols.cc b/chrome/browser/extensions/extension_protocols.cc index cc20413..47adedd 100644 --- a/chrome/browser/extensions/extension_protocols.cc +++ b/chrome/browser/extensions/extension_protocols.cc @@ -144,8 +144,9 @@ bool AllowExtensionResourceLoad(net::URLRequest* request, // Factory registered with net::URLRequest to create URLRequestJobs for // extension:// URLs. -static URLRequestJob* CreateExtensionURLRequestJob(net::URLRequest* request, - const std::string& scheme) { +static net::URLRequestJob* CreateExtensionURLRequestJob( + net::URLRequest* request, + const std::string& scheme) { ChromeURLRequestContext* context = static_cast<ChromeURLRequestContext*>(request->context()); @@ -203,8 +204,9 @@ static URLRequestJob* CreateExtensionURLRequestJob(net::URLRequest* request, // Factory registered with net::URLRequest to create URLRequestJobs for // chrome-user-script:/ URLs. -static URLRequestJob* CreateUserScriptURLRequestJob(net::URLRequest* request, - const std::string& scheme) { +static net::URLRequestJob* CreateUserScriptURLRequestJob( + net::URLRequest* request, + const std::string& scheme) { ChromeURLRequestContext* context = static_cast<ChromeURLRequestContext*>(request->context()); diff --git a/chrome/browser/extensions/user_script_listener_unittest.cc b/chrome/browser/extensions/user_script_listener_unittest.cc index 57153b7..1564fe9 100644 --- a/chrome/browser/extensions/user_script_listener_unittest.cc +++ b/chrome/browser/extensions/user_script_listener_unittest.cc @@ -93,8 +93,8 @@ ResourceDispatcherHostRequestInfo* CreateRequestInfo(int request_id) { 0, false, false, false, -1, -1); } -// A simple test URLRequestJob. We don't care what it does, only that whether it -// starts and finishes. +// A simple test net::URLRequestJob. We don't care what it does, only that +// whether it starts and finishes. class SimpleTestJob : public URLRequestTestJob { public: explicit SimpleTestJob(net::URLRequest* request) @@ -136,7 +136,7 @@ class UserScriptListenerTest } // net::URLRequest::Interceptor - virtual URLRequestJob* MaybeIntercept(net::URLRequest* request) { + virtual net::URLRequestJob* MaybeIntercept(net::URLRequest* request) { return new SimpleTestJob(request); } diff --git a/chrome/browser/net/blob_url_request_job_factory.cc b/chrome/browser/net/blob_url_request_job_factory.cc index 798c21b..2aaebc7 100644 --- a/chrome/browser/net/blob_url_request_job_factory.cc +++ b/chrome/browser/net/blob_url_request_job_factory.cc @@ -15,8 +15,8 @@ namespace { -URLRequestJob* BlobURLRequestJobFactory(net::URLRequest* request, - const std::string& scheme) { +net::URLRequestJob* BlobURLRequestJobFactory(net::URLRequest* request, + const std::string& scheme) { scoped_refptr<webkit_blob::BlobData> data; ResourceDispatcherHostRequestInfo* info = ResourceDispatcherHost::InfoForRequest(request); diff --git a/chrome/browser/net/metadata_url_request.cc b/chrome/browser/net/metadata_url_request.cc index 0f69d6d..375e664 100644 --- a/chrome/browser/net/metadata_url_request.cc +++ b/chrome/browser/net/metadata_url_request.cc @@ -21,10 +21,10 @@ class MetadataRequestHandler : public net::URLRequestJob { public: explicit MetadataRequestHandler(net::URLRequest* request); - static URLRequestJob* Factory(net::URLRequest* request, - const std::string& scheme); + static net::URLRequestJob* Factory(net::URLRequest* request, + const std::string& scheme); - // URLRequestJob implementation. + // net::URLRequestJob implementation. virtual void Start(); virtual void Kill(); virtual bool ReadRawData(net::IOBuffer* buf, int buf_size, int *bytes_read); @@ -41,7 +41,7 @@ class MetadataRequestHandler : public net::URLRequestJob { }; MetadataRequestHandler::MetadataRequestHandler(net::URLRequest* request) - : URLRequestJob(request), + : net::URLRequestJob(request), data_offset_(0) { parsed = false; } @@ -49,7 +49,7 @@ MetadataRequestHandler::MetadataRequestHandler(net::URLRequest* request) MetadataRequestHandler::~MetadataRequestHandler() { } -URLRequestJob* MetadataRequestHandler::Factory(net::URLRequest* request, +net::URLRequestJob* MetadataRequestHandler::Factory(net::URLRequest* request, const std::string& scheme) { return new MetadataRequestHandler(request); } diff --git a/chrome/browser/net/url_request_failed_dns_job.cc b/chrome/browser/net/url_request_failed_dns_job.cc index 7b6a16b..7137468 100644 --- a/chrome/browser/net/url_request_failed_dns_job.cc +++ b/chrome/browser/net/url_request_failed_dns_job.cc @@ -15,7 +15,7 @@ const char URLRequestFailedDnsJob::kTestUrl[] = "http://url.handled.by.fake.dns/"; URLRequestFailedDnsJob::URLRequestFailedDnsJob(net::URLRequest* request) - : URLRequestJob(request), + : net::URLRequestJob(request), ALLOW_THIS_IN_INITIALIZER_LIST(method_factory_(this)) {} URLRequestFailedDnsJob::~URLRequestFailedDnsJob() {} @@ -35,7 +35,7 @@ void URLRequestFailedDnsJob::AddUrlHandler() { } /*static */ -URLRequestJob* URLRequestFailedDnsJob::Factory(net::URLRequest* request, +net::URLRequestJob* URLRequestFailedDnsJob::Factory(net::URLRequest* request, const std::string& scheme) { return new URLRequestFailedDnsJob(request); } diff --git a/chrome/browser/net/url_request_mock_http_job.cc b/chrome/browser/net/url_request_mock_http_job.cc index 22fe5bf..f9feb1a3 100644 --- a/chrome/browser/net/url_request_mock_http_job.cc +++ b/chrome/browser/net/url_request_mock_http_job.cc @@ -21,8 +21,8 @@ static const FilePath::CharType kMockHeaderFileSuffix[] = FilePath URLRequestMockHTTPJob::base_path_; /* static */ -URLRequestJob* URLRequestMockHTTPJob::Factory(net::URLRequest* request, - const std::string& scheme) { +net::URLRequestJob* URLRequestMockHTTPJob::Factory(net::URLRequest* request, + const std::string& scheme) { return new URLRequestMockHTTPJob(request, GetOnDiskPath(base_path_, request, scheme)); } @@ -82,7 +82,7 @@ bool URLRequestMockHTTPJob::IsRedirectResponse(GURL* location, int* http_status_code) { // Override the URLRequestFileJob implementation to invoke the default one // based on HttpResponseInfo. - return URLRequestJob::IsRedirectResponse(location, http_status_code); + return net::URLRequestJob::IsRedirectResponse(location, http_status_code); } // Private const version. diff --git a/chrome/browser/net/url_request_mock_http_job.h b/chrome/browser/net/url_request_mock_http_job.h index d2c0e0b..eabb0e1 100644 --- a/chrome/browser/net/url_request_mock_http_job.h +++ b/chrome/browser/net/url_request_mock_http_job.h @@ -1,8 +1,8 @@ -// Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. +// Copyright (c) 2010 The Chromium Authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. // -// A URLRequestJob class that pulls the content and http headers from disk. +// A net::URLRequestJob class that pulls the content and http headers from disk. #ifndef CHROME_BROWSER_NET_URL_REQUEST_MOCK_HTTP_JOB_H_ #define CHROME_BROWSER_NET_URL_REQUEST_MOCK_HTTP_JOB_H_ diff --git a/chrome/browser/net/url_request_mock_link_doctor_job.cc b/chrome/browser/net/url_request_mock_link_doctor_job.cc index 66d7e3f..e11978e 100644 --- a/chrome/browser/net/url_request_mock_link_doctor_job.cc +++ b/chrome/browser/net/url_request_mock_link_doctor_job.cc @@ -22,8 +22,9 @@ FilePath GetMockFilePath() { } // namespace /* static */ -URLRequestJob* URLRequestMockLinkDoctorJob::Factory(net::URLRequest* request, - const std::string& scheme) { +net::URLRequestJob* URLRequestMockLinkDoctorJob::Factory( + net::URLRequest* request, + const std::string& scheme) { return new URLRequestMockLinkDoctorJob(request); } diff --git a/chrome/browser/net/url_request_mock_link_doctor_job.h b/chrome/browser/net/url_request_mock_link_doctor_job.h index 19a02f4..3c3af31 100644 --- a/chrome/browser/net/url_request_mock_link_doctor_job.h +++ b/chrome/browser/net/url_request_mock_link_doctor_job.h @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. // -// A URLRequestJob class that substitutes LinkDoctor requests. +// A net::URLRequestJob class that substitutes LinkDoctor requests. #ifndef CHROME_BROWSER_NET_URL_REQUEST_MOCK_LINK_DOCTOR_JOB_H_ #define CHROME_BROWSER_NET_URL_REQUEST_MOCK_LINK_DOCTOR_JOB_H_ diff --git a/chrome/browser/net/url_request_mock_net_error_job.cc b/chrome/browser/net/url_request_mock_net_error_job.cc index 51094d6..a06dbd3 100644 --- a/chrome/browser/net/url_request_mock_net_error_job.cc +++ b/chrome/browser/net/url_request_mock_net_error_job.cc @@ -57,8 +57,9 @@ void URLRequestMockNetErrorJob::RemoveMockedURL(const GURL& url) { } // static -URLRequestJob* URLRequestMockNetErrorJob::Factory(net::URLRequest* request, - const std::string& scheme) { +net::URLRequestJob* URLRequestMockNetErrorJob::Factory( + net::URLRequest* request, + const std::string& scheme) { GURL url = request->url(); URLMockInfoMap::const_iterator iter = url_mock_info_map_.find(url); diff --git a/chrome/browser/net/url_request_mock_net_error_job.h b/chrome/browser/net/url_request_mock_net_error_job.h index 3416bd9..33b1fc0 100644 --- a/chrome/browser/net/url_request_mock_net_error_job.h +++ b/chrome/browser/net/url_request_mock_net_error_job.h @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// A URLRequestJob class that simulates network errors (including https +// A net::URLRequestJob class that simulates network errors (including https // related). // It is based on URLRequestMockHttpJob. diff --git a/chrome/browser/net/url_request_slow_download_job.cc b/chrome/browser/net/url_request_slow_download_job.cc index 7158e7c..b5d7de1 100644 --- a/chrome/browser/net/url_request_slow_download_job.cc +++ b/chrome/browser/net/url_request_slow_download_job.cc @@ -45,7 +45,7 @@ void URLRequestSlowDownloadJob::AddUrlHandler() { } /*static */ -URLRequestJob* URLRequestSlowDownloadJob::Factory( +net::URLRequestJob* URLRequestSlowDownloadJob::Factory( net::URLRequest* request, const std::string& scheme) { URLRequestSlowDownloadJob* job = new URLRequestSlowDownloadJob(request); @@ -65,7 +65,7 @@ void URLRequestSlowDownloadJob::FinishPendingRequests() { } URLRequestSlowDownloadJob::URLRequestSlowDownloadJob(net::URLRequest* request) - : URLRequestJob(request), + : net::URLRequestJob(request), first_download_size_remaining_(kFirstDownloadSize), should_finish_download_(false), should_send_second_chunk_(false), diff --git a/chrome/browser/net/url_request_slow_download_job.h b/chrome/browser/net/url_request_slow_download_job.h index 2d8502c..ca4a23d 100644 --- a/chrome/browser/net/url_request_slow_download_job.h +++ b/chrome/browser/net/url_request_slow_download_job.h @@ -1,4 +1,4 @@ -// Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. +// Copyright (c) 2010 The Chromium Authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. // This class simulates a slow download. This used in a UI test to test the @@ -15,7 +15,7 @@ #include "base/task.h" #include "net/url_request/url_request_job.h" -class URLRequestSlowDownloadJob : public URLRequestJob { +class URLRequestSlowDownloadJob : public net::URLRequestJob { public: explicit URLRequestSlowDownloadJob(net::URLRequest* request); @@ -23,7 +23,7 @@ class URLRequestSlowDownloadJob : public URLRequestJob { // send the second chunk. void CheckDoneStatus(); - // URLRequestJob methods + // net::URLRequestJob methods virtual void Start(); virtual bool GetMimeType(std::string* mime_type) const; virtual void GetResponseInfo(net::HttpResponseInfo* info); diff --git a/chrome/browser/net/url_request_slow_http_job.cc b/chrome/browser/net/url_request_slow_http_job.cc index 12065ab..967ea1e 100644 --- a/chrome/browser/net/url_request_slow_http_job.cc +++ b/chrome/browser/net/url_request_slow_http_job.cc @@ -19,8 +19,8 @@ const int URLRequestSlowHTTPJob::kDelayMs = 1000; using base::TimeDelta; /* static */ -URLRequestJob* URLRequestSlowHTTPJob::Factory(net::URLRequest* request, - const std::string& scheme) { +net::URLRequestJob* URLRequestSlowHTTPJob::Factory(net::URLRequest* request, + const std::string& scheme) { return new URLRequestSlowHTTPJob(request, GetOnDiskPath(base_path_, request, scheme)); } diff --git a/chrome/browser/net/view_blob_internals_job_factory.cc b/chrome/browser/net/view_blob_internals_job_factory.cc index 4fdbefc..ad2349f 100644 --- a/chrome/browser/net/view_blob_internals_job_factory.cc +++ b/chrome/browser/net/view_blob_internals_job_factory.cc @@ -18,7 +18,7 @@ bool ViewBlobInternalsJobFactory::IsSupportedURL(const GURL& url) { } // static. -URLRequestJob* ViewBlobInternalsJobFactory::CreateJobForRequest( +net::URLRequestJob* ViewBlobInternalsJobFactory::CreateJobForRequest( net::URLRequest* request) { webkit_blob::BlobStorageController* blob_storage_controller = static_cast<ChromeURLRequestContext*>(request->context())-> diff --git a/chrome/browser/net/view_http_cache_job_factory.cc b/chrome/browser/net/view_http_cache_job_factory.cc index 8703877..839130d 100644 --- a/chrome/browser/net/view_http_cache_job_factory.cc +++ b/chrome/browser/net/view_http_cache_job_factory.cc @@ -19,7 +19,10 @@ namespace { class ViewHttpCacheJob : public net::URLRequestJob { public: explicit ViewHttpCacheJob(net::URLRequest* request) - : URLRequestJob(request), data_offset_(0), cancel_(false), busy_(false), + : net::URLRequestJob(request), + data_offset_(0), + cancel_(false), + busy_(false), ALLOW_THIS_IN_INITIALIZER_LIST( callback_(this, &ViewHttpCacheJob::OnIOComplete)) {} @@ -75,7 +78,7 @@ void ViewHttpCacheJob::Kill() { // is safe. cancel_ = true; if (!busy_) - URLRequestJob::Kill(); + net::URLRequestJob::Kill(); } bool ViewHttpCacheJob::GetMimeType(std::string* mime_type) const { @@ -108,7 +111,7 @@ void ViewHttpCacheJob::OnIOComplete(int result) { Release(); // Acquired on Start(). if (cancel_) - return URLRequestJob::Kill(); + return net::URLRequestJob::Kill(); // Notify that the headers are complete. NotifyHeadersComplete(); @@ -123,7 +126,7 @@ bool ViewHttpCacheJobFactory::IsSupportedURL(const GURL& url) { } // Static. -URLRequestJob* ViewHttpCacheJobFactory::CreateJobForRequest( +net::URLRequestJob* ViewHttpCacheJobFactory::CreateJobForRequest( net::URLRequest* request) { return new ViewHttpCacheJob(request); } diff --git a/chrome/browser/policy/device_management_service_browsertest.cc b/chrome/browser/policy/device_management_service_browsertest.cc index f4c3f7b..1b5496c 100644 --- a/chrome/browser/policy/device_management_service_browsertest.cc +++ b/chrome/browser/policy/device_management_service_browsertest.cc @@ -58,7 +58,7 @@ class CannedResponseInterceptor : public net::URLRequest::Interceptor { private: // net::URLRequest::Interceptor overrides. - virtual URLRequestJob* MaybeIntercept(net::URLRequest* request) { + virtual net::URLRequestJob* MaybeIntercept(net::URLRequest* request) { if (request->url().GetOrigin() == service_url_.GetOrigin() && request->url().path() == service_url_.path()) { return new URLRequestTestJob(request, diff --git a/chrome/browser/printing/print_dialog_cloud_uitest.cc b/chrome/browser/printing/print_dialog_cloud_uitest.cc index e4c8804..40824de 100644 --- a/chrome/browser/printing/print_dialog_cloud_uitest.cc +++ b/chrome/browser/printing/print_dialog_cloud_uitest.cc @@ -57,7 +57,7 @@ class TestData { friend struct DefaultSingletonTraits<TestData>; }; -// A simple test URLRequestJob. We don't care what it does, only that +// A simple test net::URLRequestJob. We don't care what it does, only that // whether it starts and finishes. class SimpleTestJob : public URLRequestTestJob { public: @@ -208,8 +208,8 @@ class PrintDialogCloudTest : public InProcessBrowserTest { AutoQuitDelegate delegate_; }; -URLRequestJob* PrintDialogCloudTest::Factory(net::URLRequest* request, - const std::string& scheme) { +net::URLRequestJob* PrintDialogCloudTest::Factory(net::URLRequest* request, + const std::string& scheme) { if (TestController::GetInstance()->use_delegate()) request->set_delegate(TestController::GetInstance()->delegate()); if (request && diff --git a/chrome/browser/renderer_host/resource_dispatcher_host_request_info.h b/chrome/browser/renderer_host/resource_dispatcher_host_request_info.h index ead2239..5c92a45 100644 --- a/chrome/browser/renderer_host/resource_dispatcher_host_request_info.h +++ b/chrome/browser/renderer_host/resource_dispatcher_host_request_info.h @@ -168,7 +168,7 @@ class ResourceDispatcherHostRequestInfo : public net::URLRequest::UserData { int host_render_view_id() const { return host_render_view_id_; } // We hold a reference to the requested blob data to ensure it doesn't - // get finally released prior to the URLRequestJob being started. + // get finally released prior to the net::URLRequestJob being started. webkit_blob::BlobData* requested_blob_data() const { return requested_blob_data_.get(); } diff --git a/chrome/browser/renderer_host/resource_dispatcher_host_unittest.cc b/chrome/browser/renderer_host/resource_dispatcher_host_unittest.cc index 228c83e..7240608 100644 --- a/chrome/browser/renderer_host/resource_dispatcher_host_unittest.cc +++ b/chrome/browser/renderer_host/resource_dispatcher_host_unittest.cc @@ -255,9 +255,9 @@ class ResourceDispatcherHostTest : public testing::Test, scheme_, &ResourceDispatcherHostTest::Factory); } - // Our own URLRequestJob factory. - static URLRequestJob* Factory(net::URLRequest* request, - const std::string& scheme) { + // Our own net::URLRequestJob factory. + static net::URLRequestJob* Factory(net::URLRequest* request, + const std::string& scheme) { if (test_fixture_->response_headers_.empty()) { return new URLRequestTestJob(request); } else { diff --git a/chrome/browser/renderer_host/resource_queue_unittest.cc b/chrome/browser/renderer_host/resource_queue_unittest.cc index fa466f1..3339701 100644 --- a/chrome/browser/renderer_host/resource_queue_unittest.cc +++ b/chrome/browser/renderer_host/resource_queue_unittest.cc @@ -164,7 +164,7 @@ class ResourceQueueTest : public testing::Test, virtual void OnResponseStarted(net::URLRequest* request) { response_started_count_++; // We're not going to do anything more with the request. Cancel it now - // to avoid leaking URLRequestJob. + // to avoid leaking net::URLRequestJob. request->Cancel(); } diff --git a/chrome/browser/task_manager/task_manager.cc b/chrome/browser/task_manager/task_manager.cc index 1cb3c59..38531d8 100644 --- a/chrome/browser/task_manager/task_manager.cc +++ b/chrome/browser/task_manager/task_manager.cc @@ -865,26 +865,26 @@ void TaskManagerModel::BytesRead(BytesReadParam param) { } -// In order to retrieve the network usage, we register for URLRequestJob +// In order to retrieve the network usage, we register for net::URLRequestJob // notifications. Every time we get notified some bytes were read we bump a // counter of read bytes for the associated resource. When the timer ticks, // we'll compute the actual network usage (see the Refresh method). -void TaskManagerModel::OnJobAdded(URLRequestJob* job) { +void TaskManagerModel::OnJobAdded(net::URLRequestJob* job) { } -void TaskManagerModel::OnJobRemoved(URLRequestJob* job) { +void TaskManagerModel::OnJobRemoved(net::URLRequestJob* job) { } -void TaskManagerModel::OnJobDone(URLRequestJob* job, +void TaskManagerModel::OnJobDone(net::URLRequestJob* job, const URLRequestStatus& status) { } -void TaskManagerModel::OnJobRedirect(URLRequestJob* job, +void TaskManagerModel::OnJobRedirect(net::URLRequestJob* job, const GURL& location, int status_code) { } -void TaskManagerModel::OnBytesRead(URLRequestJob* job, const char* buf, +void TaskManagerModel::OnBytesRead(net::URLRequestJob* job, const char* buf, int byte_count) { int render_process_host_child_id = -1, routing_id = -1; ResourceDispatcherHost::RenderViewForRequest(job->request(), diff --git a/chrome/common/net/url_request_intercept_job.cc b/chrome/common/net/url_request_intercept_job.cc index eb3b74f..04e9dd3 100644 --- a/chrome/common/net/url_request_intercept_job.cc +++ b/chrome/common/net/url_request_intercept_job.cc @@ -29,7 +29,7 @@ using base::TimeDelta; URLRequestInterceptJob::URLRequestInterceptJob(net::URLRequest* request, ChromePluginLib* plugin, ScopableCPRequest* cprequest) - : URLRequestJob(request), + : net::URLRequestJob(request), cprequest_(cprequest), plugin_(plugin), read_buffer_(NULL), @@ -67,7 +67,7 @@ void URLRequestInterceptJob::Kill() { CPERR_CANCELLED); DetachPlugin(); } - URLRequestJob::Kill(); + net::URLRequestJob::Kill(); method_factory_.RevokeAll(); } diff --git a/chrome/common/net/url_request_intercept_job.h b/chrome/common/net/url_request_intercept_job.h index 1d84e42..581b30a 100644 --- a/chrome/common/net/url_request_intercept_job.h +++ b/chrome/common/net/url_request_intercept_job.h @@ -37,7 +37,7 @@ class URLRequestInterceptJob : public net::URLRequestJob, void OnStartCompleted(int result); void OnReadCompleted(int bytes_read); - // URLRequestJob + // net::URLRequestJob virtual void Start(); virtual void Kill(); virtual bool GetMimeType(std::string* mime_type) const; |