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_SOCKET_CLIENT_SOCKET_POOL_HISTOGRAMS_H_ | 5 #ifndef NET_SOCKET_CLIENT_SOCKET_POOL_HISTOGRAMS_H_ |
6 #define NET_SOCKET_CLIENT_SOCKET_POOL_HISTOGRAMS_H_ | 6 #define NET_SOCKET_CLIENT_SOCKET_POOL_HISTOGRAMS_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 #include <string> | 9 #include <string> |
10 | 10 |
(...skipping 10 matching lines...) Expand all Loading... |
21 public: | 21 public: |
22 ClientSocketPoolHistograms(const std::string& pool_name); | 22 ClientSocketPoolHistograms(const std::string& pool_name); |
23 ~ClientSocketPoolHistograms(); | 23 ~ClientSocketPoolHistograms(); |
24 | 24 |
25 void AddSocketType(int socket_reuse_type) const; | 25 void AddSocketType(int socket_reuse_type) const; |
26 void AddRequestTime(base::TimeDelta time) const; | 26 void AddRequestTime(base::TimeDelta time) const; |
27 void AddUnusedIdleTime(base::TimeDelta time) const; | 27 void AddUnusedIdleTime(base::TimeDelta time) const; |
28 void AddReusedIdleTime(base::TimeDelta time) const; | 28 void AddReusedIdleTime(base::TimeDelta time) const; |
29 | 29 |
30 private: | 30 private: |
31 scoped_refptr<base::Histogram> socket_type_; | 31 base::Histogram* socket_type_; |
32 scoped_refptr<base::Histogram> request_time_; | 32 base::Histogram* request_time_; |
33 scoped_refptr<base::Histogram> unused_idle_time_; | 33 base::Histogram* unused_idle_time_; |
34 scoped_refptr<base::Histogram> reused_idle_time_; | 34 base::Histogram* reused_idle_time_; |
35 | 35 |
36 bool is_http_proxy_connection_; | 36 bool is_http_proxy_connection_; |
37 bool is_socks_connection_; | 37 bool is_socks_connection_; |
38 | 38 |
39 DISALLOW_COPY_AND_ASSIGN(ClientSocketPoolHistograms); | 39 DISALLOW_COPY_AND_ASSIGN(ClientSocketPoolHistograms); |
40 }; | 40 }; |
41 | 41 |
42 } // namespace net | 42 } // namespace net |
43 | 43 |
44 #endif // NET_SOCKET_CLIENT_SOCKET_POOL_HISTOGRAMS_H_ | 44 #endif // NET_SOCKET_CLIENT_SOCKET_POOL_HISTOGRAMS_H_ |
OLD | NEW |