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

Side by Side Diff: content/test/net/url_request_abort_on_end_job.h

Issue 10855209: Refactoring: ProtocolHandler::MaybeCreateJob takes NetworkDelegate as argument (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Latest merge Created 8 years, 3 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 // This class simulates what wininet does when a dns lookup fails. 4 // This class simulates what wininet does when a dns lookup fails.
5 5
6 #ifndef CONTENT_TEST_NET_URL_REQUEST_ABORT_ON_END_JOB_H_ 6 #ifndef CONTENT_TEST_NET_URL_REQUEST_ABORT_ON_END_JOB_H_
7 #define CONTENT_TEST_NET_URL_REQUEST_ABORT_ON_END_JOB_H_ 7 #define CONTENT_TEST_NET_URL_REQUEST_ABORT_ON_END_JOB_H_
8 8
9 #include <string> 9 #include <string>
10 10
(...skipping 11 matching lines...) Expand all
22 22
23 // net::URLRequestJob 23 // net::URLRequestJob
24 virtual void Start() OVERRIDE; 24 virtual void Start() OVERRIDE;
25 virtual bool GetMimeType(std::string* mime_type) const OVERRIDE; 25 virtual bool GetMimeType(std::string* mime_type) const OVERRIDE;
26 virtual void GetResponseInfo(net::HttpResponseInfo* info) OVERRIDE; 26 virtual void GetResponseInfo(net::HttpResponseInfo* info) OVERRIDE;
27 virtual bool ReadRawData(net::IOBuffer* buf, 27 virtual bool ReadRawData(net::IOBuffer* buf,
28 int buf_size, 28 int buf_size,
29 int* bytes_read) OVERRIDE; 29 int* bytes_read) OVERRIDE;
30 30
31 static net::URLRequestJob* Factory(net::URLRequest* request, 31 static net::URLRequestJob* Factory(net::URLRequest* request,
32 net::NetworkDelegate* network_delegate,
32 const std::string& scheme); 33 const std::string& scheme);
33 34
34 static void AddUrlHandler(); 35 static void AddUrlHandler();
35 36
36 private: 37 private:
37 explicit URLRequestAbortOnEndJob(net::URLRequest* request); 38 URLRequestAbortOnEndJob(net::URLRequest* request,
39 net::NetworkDelegate* network_delegate);
38 virtual ~URLRequestAbortOnEndJob(); 40 virtual ~URLRequestAbortOnEndJob();
39 41
40 void GetResponseInfoConst(net::HttpResponseInfo* info) const; 42 void GetResponseInfoConst(net::HttpResponseInfo* info) const;
41 void StartAsync(); 43 void StartAsync();
42 44
43 bool sent_data_; 45 bool sent_data_;
44 46
45 base::WeakPtrFactory<URLRequestAbortOnEndJob> weak_factory_; 47 base::WeakPtrFactory<URLRequestAbortOnEndJob> weak_factory_;
46 48
47 DISALLOW_COPY_AND_ASSIGN(URLRequestAbortOnEndJob); 49 DISALLOW_COPY_AND_ASSIGN(URLRequestAbortOnEndJob);
48 }; 50 };
49 51
50 #endif // CONTENT_TEST_NET_URL_REQUEST_ABORT_ON_END_JOB_H_ 52 #endif // CONTENT_TEST_NET_URL_REQUEST_ABORT_ON_END_JOB_H_
OLDNEW
« no previous file with comments | « content/browser/tcmalloc_internals_request_job.cc ('k') | content/test/net/url_request_abort_on_end_job.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698