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

Side by Side Diff: net/base/mock_host_resolver.h

Issue 848006: Generalize the net module's LoadLog facility from a passive container, to an event stream (NetLog). (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Split up RequestTracker into ConnectJobTracker+RequestTracker+RequestTrackerBase, address comments Created 10 years, 9 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
« no previous file with comments | « net/base/mapped_host_resolver_unittest.cc ('k') | net/base/mock_host_resolver.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 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_BASE_MOCK_HOST_RESOLVER_H_ 5 #ifndef NET_BASE_MOCK_HOST_RESOLVER_H_
6 #define NET_BASE_MOCK_HOST_RESOLVER_H_ 6 #define NET_BASE_MOCK_HOST_RESOLVER_H_
7 7
8 #include <list> 8 #include <list>
9 9
10 #include "base/waitable_event.h" 10 #include "base/waitable_event.h"
(...skipping 25 matching lines...) Expand all
36 // re-map one hostname to another as well. 36 // re-map one hostname to another as well.
37 37
38 // Base class shared by MockHostResolver and MockCachingHostResolver. 38 // Base class shared by MockHostResolver and MockCachingHostResolver.
39 class MockHostResolverBase : public HostResolver { 39 class MockHostResolverBase : public HostResolver {
40 public: 40 public:
41 // HostResolver methods: 41 // HostResolver methods:
42 virtual int Resolve(const RequestInfo& info, 42 virtual int Resolve(const RequestInfo& info,
43 AddressList* addresses, 43 AddressList* addresses,
44 CompletionCallback* callback, 44 CompletionCallback* callback,
45 RequestHandle* out_req, 45 RequestHandle* out_req,
46 LoadLog* load_log); 46 const BoundNetLog& net_log);
47 virtual void CancelRequest(RequestHandle req); 47 virtual void CancelRequest(RequestHandle req);
48 virtual void AddObserver(Observer* observer); 48 virtual void AddObserver(Observer* observer);
49 virtual void RemoveObserver(Observer* observer); 49 virtual void RemoveObserver(Observer* observer);
50 50
51 RuleBasedHostResolverProc* rules() { return rules_; } 51 RuleBasedHostResolverProc* rules() { return rules_; }
52 52
53 // Controls whether resolutions complete synchronously or asynchronously. 53 // Controls whether resolutions complete synchronously or asynchronously.
54 void set_synchronous_mode(bool is_synchronous) { 54 void set_synchronous_mode(bool is_synchronous) {
55 synchronous_mode_ = is_synchronous; 55 synchronous_mode_ = is_synchronous;
56 } 56 }
(...skipping 125 matching lines...) Expand 10 before | Expand all | Expand 10 after
182 void Init(HostResolverProc* proc); 182 void Init(HostResolverProc* proc);
183 183
184 private: 184 private:
185 scoped_refptr<HostResolverProc> current_proc_; 185 scoped_refptr<HostResolverProc> current_proc_;
186 scoped_refptr<HostResolverProc> previous_proc_; 186 scoped_refptr<HostResolverProc> previous_proc_;
187 }; 187 };
188 188
189 } // namespace net 189 } // namespace net
190 190
191 #endif // NET_BASE_MOCK_HOST_RESOLVER_H_ 191 #endif // NET_BASE_MOCK_HOST_RESOLVER_H_
OLDNEW
« no previous file with comments | « net/base/mapped_host_resolver_unittest.cc ('k') | net/base/mock_host_resolver.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698