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 // This class helps to remember what domains may be needed to be resolved when a | 5 // This class helps to remember what domains may be needed to be resolved when a |
6 // navigation takes place to a given URL. This information is gathered when a | 6 // navigation takes place to a given URL. This information is gathered when a |
7 // navigation to a subresource identifies a referring URL. | 7 // navigation to a subresource identifies a referring URL. |
8 // When future navigations take place to known referrer sites, then we | 8 // When future navigations take place to known referrer sites, then we |
9 // speculatively either pre-warm a TCP/IP conneciton, or at a minimum, resolve | 9 // speculatively either pre-warm a TCP/IP conneciton, or at a minimum, resolve |
10 // the host name via DNS. | 10 // the host name via DNS. |
11 | 11 |
12 // All access to this class is performed via the Predictor class, which only | 12 // All access to this class is performed via the Predictor class, which only |
13 // operates on the IO thread. | 13 // operates on the IO thread. |
14 | 14 |
15 #ifndef CHROME_BROWSER_NET_REFERRER_H_ | 15 #ifndef CHROME_BROWSER_NET_REFERRER_H_ |
16 #define CHROME_BROWSER_NET_REFERRER_H_ | 16 #define CHROME_BROWSER_NET_REFERRER_H_ |
17 #pragma once | 17 #pragma once |
18 | 18 |
19 #include <map> | 19 #include <map> |
20 | 20 |
21 #include "base/basictypes.h" | 21 #include "base/basictypes.h" |
22 #include "base/task.h" | |
23 #include "base/time.h" | 22 #include "base/time.h" |
24 #include "googleurl/src/gurl.h" | 23 #include "googleurl/src/gurl.h" |
25 #include "net/base/host_port_pair.h" | 24 #include "net/base/host_port_pair.h" |
26 | 25 |
27 namespace base { | 26 namespace base { |
28 class Value; | 27 class Value; |
29 } | 28 } |
30 | 29 |
31 namespace chrome_browser_net { | 30 namespace chrome_browser_net { |
32 | 31 |
(...skipping 102 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
135 | 134 |
136 // We put these into a std::map<>, so we need copy constructors. | 135 // We put these into a std::map<>, so we need copy constructors. |
137 // DISALLOW_COPY_AND_ASSIGN(Referrer); | 136 // DISALLOW_COPY_AND_ASSIGN(Referrer); |
138 // TODO(jar): Consider optimization to use pointers to these instances, and | 137 // TODO(jar): Consider optimization to use pointers to these instances, and |
139 // avoid deep copies during re-alloc of the containing map. | 138 // avoid deep copies during re-alloc of the containing map. |
140 }; | 139 }; |
141 | 140 |
142 } // namespace chrome_browser_net | 141 } // namespace chrome_browser_net |
143 | 142 |
144 #endif // CHROME_BROWSER_NET_REFERRER_H_ | 143 #endif // CHROME_BROWSER_NET_REFERRER_H_ |
OLD | NEW |