| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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_PROXY_MOCK_PROXY_RESOLVER_H_ | 5 #ifndef NET_PROXY_MOCK_PROXY_RESOLVER_H_ |
| 6 #define NET_PROXY_MOCK_PROXY_RESOLVER_H_ | 6 #define NET_PROXY_MOCK_PROXY_RESOLVER_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include <vector> | 9 #include <vector> |
| 10 | 10 |
| (...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 69 | 69 |
| 70 virtual ~MockAsyncProxyResolverBase(); | 70 virtual ~MockAsyncProxyResolverBase(); |
| 71 | 71 |
| 72 // ProxyResolver implementation: | 72 // ProxyResolver implementation: |
| 73 virtual int GetProxyForURL(const GURL& url, | 73 virtual int GetProxyForURL(const GURL& url, |
| 74 ProxyInfo* results, | 74 ProxyInfo* results, |
| 75 OldCompletionCallback* callback, | 75 OldCompletionCallback* callback, |
| 76 RequestHandle* request_handle, | 76 RequestHandle* request_handle, |
| 77 const BoundNetLog& /*net_log*/) OVERRIDE; | 77 const BoundNetLog& /*net_log*/) OVERRIDE; |
| 78 virtual void CancelRequest(RequestHandle request_handle) OVERRIDE; | 78 virtual void CancelRequest(RequestHandle request_handle) OVERRIDE; |
| 79 virtual LoadState GetLoadState(RequestHandle request_handle) const OVERRIDE; |
| 80 virtual LoadState GetLoadStateThreadSafe( |
| 81 RequestHandle request_handle) const OVERRIDE; |
| 79 virtual int SetPacScript( | 82 virtual int SetPacScript( |
| 80 const scoped_refptr<ProxyResolverScriptData>& script_data, | 83 const scoped_refptr<ProxyResolverScriptData>& script_data, |
| 81 OldCompletionCallback* callback) OVERRIDE; | 84 OldCompletionCallback* callback) OVERRIDE; |
| 82 virtual void CancelSetPacScript() OVERRIDE; | 85 virtual void CancelSetPacScript() OVERRIDE; |
| 83 | 86 |
| 84 const RequestsList& pending_requests() const { | 87 const RequestsList& pending_requests() const { |
| 85 return pending_requests_; | 88 return pending_requests_; |
| 86 } | 89 } |
| 87 | 90 |
| 88 const RequestsList& cancelled_requests() const { | 91 const RequestsList& cancelled_requests() const { |
| (...skipping 23 matching lines...) Expand all Loading... |
| 112 | 115 |
| 113 class MockAsyncProxyResolverExpectsBytes : public MockAsyncProxyResolverBase { | 116 class MockAsyncProxyResolverExpectsBytes : public MockAsyncProxyResolverBase { |
| 114 public: | 117 public: |
| 115 MockAsyncProxyResolverExpectsBytes() | 118 MockAsyncProxyResolverExpectsBytes() |
| 116 : MockAsyncProxyResolverBase(true /*expects_pac_bytes*/) {} | 119 : MockAsyncProxyResolverBase(true /*expects_pac_bytes*/) {} |
| 117 }; | 120 }; |
| 118 | 121 |
| 119 } // namespace net | 122 } // namespace net |
| 120 | 123 |
| 121 #endif // NET_PROXY_MOCK_PROXY_RESOLVER_H_ | 124 #endif // NET_PROXY_MOCK_PROXY_RESOLVER_H_ |
| OLD | NEW |