OLD | NEW |
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 | 4 |
5 #ifndef NET_HTTP_HTTP_PROXY_CLIENT_SOCKET_H_ | 5 #ifndef NET_HTTP_HTTP_PROXY_CLIENT_SOCKET_H_ |
6 #define NET_HTTP_HTTP_PROXY_CLIENT_SOCKET_H_ | 6 #define NET_HTTP_HTTP_PROXY_CLIENT_SOCKET_H_ |
7 | 7 |
8 #include <stdint.h> | 8 #include <stdint.h> |
9 | 9 |
10 #include <string> | 10 #include <string> |
11 | 11 |
12 #include "base/basictypes.h" | 12 #include "base/macros.h" |
13 #include "base/memory/ref_counted.h" | 13 #include "base/memory/ref_counted.h" |
14 #include "net/base/completion_callback.h" | 14 #include "net/base/completion_callback.h" |
15 #include "net/base/host_port_pair.h" | 15 #include "net/base/host_port_pair.h" |
16 #include "net/base/load_timing_info.h" | 16 #include "net/base/load_timing_info.h" |
17 #include "net/http/http_auth_controller.h" | 17 #include "net/http/http_auth_controller.h" |
18 #include "net/http/http_request_headers.h" | 18 #include "net/http/http_request_headers.h" |
19 #include "net/http/http_request_info.h" | 19 #include "net/http/http_request_info.h" |
20 #include "net/http/http_response_info.h" | 20 #include "net/http/http_response_info.h" |
21 #include "net/http/proxy_client_socket.h" | 21 #include "net/http/proxy_client_socket.h" |
22 #include "net/log/net_log.h" | 22 #include "net/log/net_log.h" |
(...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
77 void AddConnectionAttempts(const ConnectionAttempts& attempts) override {} | 77 void AddConnectionAttempts(const ConnectionAttempts& attempts) override {} |
78 int64_t GetTotalReceivedBytes() const override; | 78 int64_t GetTotalReceivedBytes() const override; |
79 | 79 |
80 // Socket implementation. | 80 // Socket implementation. |
81 int Read(IOBuffer* buf, | 81 int Read(IOBuffer* buf, |
82 int buf_len, | 82 int buf_len, |
83 const CompletionCallback& callback) override; | 83 const CompletionCallback& callback) override; |
84 int Write(IOBuffer* buf, | 84 int Write(IOBuffer* buf, |
85 int buf_len, | 85 int buf_len, |
86 const CompletionCallback& callback) override; | 86 const CompletionCallback& callback) override; |
87 int SetReceiveBufferSize(int32 size) override; | 87 int SetReceiveBufferSize(int32_t size) override; |
88 int SetSendBufferSize(int32 size) override; | 88 int SetSendBufferSize(int32_t size) override; |
89 int GetPeerAddress(IPEndPoint* address) const override; | 89 int GetPeerAddress(IPEndPoint* address) const override; |
90 int GetLocalAddress(IPEndPoint* address) const override; | 90 int GetLocalAddress(IPEndPoint* address) const override; |
91 | 91 |
92 private: | 92 private: |
93 enum State { | 93 enum State { |
94 STATE_NONE, | 94 STATE_NONE, |
95 STATE_GENERATE_AUTH_TOKEN, | 95 STATE_GENERATE_AUTH_TOKEN, |
96 STATE_GENERATE_AUTH_TOKEN_COMPLETE, | 96 STATE_GENERATE_AUTH_TOKEN_COMPLETE, |
97 STATE_SEND_REQUEST, | 97 STATE_SEND_REQUEST, |
98 STATE_SEND_REQUEST_COMPLETE, | 98 STATE_SEND_REQUEST_COMPLETE, |
(...skipping 68 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
167 ProxyDelegate* proxy_delegate_; | 167 ProxyDelegate* proxy_delegate_; |
168 | 168 |
169 const BoundNetLog net_log_; | 169 const BoundNetLog net_log_; |
170 | 170 |
171 DISALLOW_COPY_AND_ASSIGN(HttpProxyClientSocket); | 171 DISALLOW_COPY_AND_ASSIGN(HttpProxyClientSocket); |
172 }; | 172 }; |
173 | 173 |
174 } // namespace net | 174 } // namespace net |
175 | 175 |
176 #endif // NET_HTTP_HTTP_PROXY_CLIENT_SOCKET_H_ | 176 #endif // NET_HTTP_HTTP_PROXY_CLIENT_SOCKET_H_ |
OLD | NEW |