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

Unified Diff: net/url_request/url_request_job_tracker.h

Issue 5298008: net: Add namespace net to URLRequest and URLRequestJob classes. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: some chromeos fixes Created 10 years, 1 month 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 side-by-side diff with in-line comments
Download patch
Index: net/url_request/url_request_job_tracker.h
diff --git a/net/url_request/url_request_job_tracker.h b/net/url_request/url_request_job_tracker.h
index 8b554b97a8b5acbedfbb490f4af8349390eda6d7..cd0bd86e6b2a912707b2955d5554d7e79604f0de 100644
--- a/net/url_request/url_request_job_tracker.h
+++ b/net/url_request/url_request_job_tracker.h
@@ -11,7 +11,10 @@
#include "base/observer_list.h"
#include "net/url_request/url_request_status.h"
+namespace net {
class URLRequestJob;
+} // namespace net
+
class GURL;
// This class maintains a list of active URLRequestJobs for debugging purposes.
@@ -23,25 +26,25 @@ class GURL;
//
class URLRequestJobTracker {
public:
- typedef std::vector<URLRequestJob*> JobList;
+ typedef std::vector<net::URLRequestJob*> JobList;
typedef JobList::const_iterator JobIterator;
// The observer's methods are called on the thread that called AddObserver.
class JobObserver {
public:
// Called after the given job has been added to the list
- virtual void OnJobAdded(URLRequestJob* job) = 0;
+ virtual void OnJobAdded(net::URLRequestJob* job) = 0;
// Called after the given job has been removed from the list
- virtual void OnJobRemoved(URLRequestJob* job) = 0;
+ virtual void OnJobRemoved(net::URLRequestJob* job) = 0;
// Called when the given job has completed, before notifying the request
- virtual void OnJobDone(URLRequestJob* job,
+ virtual void OnJobDone(net::URLRequestJob* job,
const URLRequestStatus& status) = 0;
// Called when the given job is about to follow a redirect to the given
// new URL. The redirect type is given in status_code
- virtual void OnJobRedirect(URLRequestJob* job, const GURL& location,
+ virtual void OnJobRedirect(net::URLRequestJob* job, const GURL& location,
int status_code) = 0;
// Called when a new chunk of unfiltered bytes has been read for
@@ -49,7 +52,7 @@ class URLRequestJobTracker {
// read event only. |buf| is a pointer to the data buffer that
// contains those bytes. The data in |buf| is only valid for the
// duration of the OnBytesRead callback.
- virtual void OnBytesRead(URLRequestJob* job, const char* buf,
+ virtual void OnBytesRead(net::URLRequestJob* job, const char* buf,
int byte_count) = 0;
virtual ~JobObserver() {}
@@ -70,16 +73,16 @@ class URLRequestJobTracker {
// adds or removes the job from the active list, should be called by the
// job constructor and destructor. Note: don't use "AddJob" since that
// is #defined by windows.h :(
- void AddNewJob(URLRequestJob* job);
- void RemoveJob(URLRequestJob* job);
+ void AddNewJob(net::URLRequestJob* job);
+ void RemoveJob(net::URLRequestJob* job);
// Job status change notifications
- void OnJobDone(URLRequestJob* job, const URLRequestStatus& status);
- void OnJobRedirect(URLRequestJob* job, const GURL& location,
+ void OnJobDone(net::URLRequestJob* job, const URLRequestStatus& status);
+ void OnJobRedirect(net::URLRequestJob* job, const GURL& location,
int status_code);
// Bytes read notifications.
- void OnBytesRead(URLRequestJob* job, const char* buf, int byte_count);
+ void OnBytesRead(net::URLRequestJob* job, const char* buf, int byte_count);
// allows iteration over all active jobs
JobIterator begin() const {

Powered by Google App Engine
This is Rietveld 408576698