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

Side by Side Diff: net/url_request/url_request_test_job.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 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) 2006-2008 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2006-2008 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_TEST_JOB_H_ 5 #ifndef NET_URL_REQUEST_URL_REQUEST_TEST_JOB_H_
6 #define NET_URL_REQUEST_URL_REQUEST_TEST_JOB_H_ 6 #define NET_URL_REQUEST_URL_REQUEST_TEST_JOB_H_
7 #pragma once 7 #pragma once
8 8
9 #include <string> 9 #include <string>
10 10
(...skipping 15 matching lines...) Expand all
26 // Optionally, you can also construct test jobs to return a headers and data 26 // Optionally, you can also construct test jobs to return a headers and data
27 // provided to the contstructor in response to any request url. 27 // provided to the contstructor in response to any request url.
28 // 28 //
29 // When a job is created, it gets put on a queue of pending test jobs. To 29 // When a job is created, it gets put on a queue of pending test jobs. To
30 // process jobs on this queue, use ProcessOnePendingMessage, which will process 30 // process jobs on this queue, use ProcessOnePendingMessage, which will process
31 // one step of the next job. If the job is incomplete, it will be added to the 31 // one step of the next job. If the job is incomplete, it will be added to the
32 // end of the queue. 32 // end of the queue.
33 // 33 //
34 // Optionally, you can also construct test jobs that advance automatically 34 // Optionally, you can also construct test jobs that advance automatically
35 // without having to call ProcessOnePendingMessage. 35 // without having to call ProcessOnePendingMessage.
36 class URLRequestTestJob : public URLRequestJob { 36 class URLRequestTestJob : public net::URLRequestJob {
37 public: 37 public:
38 // Constructs a job to return one of the canned responses depending on the 38 // Constructs a job to return one of the canned responses depending on the
39 // request url, with auto advance disabled. 39 // request url, with auto advance disabled.
40 explicit URLRequestTestJob(URLRequest* request); 40 explicit URLRequestTestJob(URLRequest* request);
41 41
42 // Constructs a job to return one of the canned responses depending on the 42 // Constructs a job to return one of the canned responses depending on the
43 // request url, optionally with auto advance enabled. 43 // request url, optionally with auto advance enabled.
44 explicit URLRequestTestJob(URLRequest* request, bool auto_advance); 44 explicit URLRequestTestJob(URLRequest* request, bool auto_advance);
45 45
46 // Constructs a job to return the given response regardless of the request 46 // Constructs a job to return the given response regardless of the request
(...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after
128 128
129 // current offset within response_data_ 129 // current offset within response_data_
130 int offset_; 130 int offset_;
131 131
132 // Holds the buffer for an asynchronous ReadRawData call 132 // Holds the buffer for an asynchronous ReadRawData call
133 net::IOBuffer* async_buf_; 133 net::IOBuffer* async_buf_;
134 int async_buf_size_; 134 int async_buf_size_;
135 }; 135 };
136 136
137 #endif // NET_URL_REQUEST_URL_REQUEST_TEST_JOB_H_ 137 #endif // NET_URL_REQUEST_URL_REQUEST_TEST_JOB_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698