OLD | NEW |
1 /* | 1 /* |
2 Copyright (C) 1998 Lars Knoll (knoll@mpi-hd.mpg.de) | 2 Copyright (C) 1998 Lars Knoll (knoll@mpi-hd.mpg.de) |
3 Copyright (C) 2001 Dirk Mueller <mueller@kde.org> | 3 Copyright (C) 2001 Dirk Mueller <mueller@kde.org> |
4 Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All | 4 Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All |
5 rights reserved. | 5 rights reserved. |
6 Copyright (C) 2009 Torch Mobile Inc. http://www.torchmobile.com/ | 6 Copyright (C) 2009 Torch Mobile Inc. http://www.torchmobile.com/ |
7 | 7 |
8 This library is free software; you can redistribute it and/or | 8 This library is free software; you can redistribute it and/or |
9 modify it under the terms of the GNU Library General Public | 9 modify it under the terms of the GNU Library General Public |
10 License as published by the Free Software Foundation; either | 10 License as published by the Free Software Foundation; either |
(...skipping 227 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
238 HeapHashMap<Member<Resource>, RefPtr<ResourceTimingInfo>>; | 238 HeapHashMap<Member<Resource>, RefPtr<ResourceTimingInfo>>; |
239 ResourceTimingInfoMap resource_timing_info_map_; | 239 ResourceTimingInfoMap resource_timing_info_map_; |
240 | 240 |
241 RefPtr<ResourceTimingInfo> navigation_timing_info_; | 241 RefPtr<ResourceTimingInfo> navigation_timing_info_; |
242 | 242 |
243 Vector<RefPtr<ResourceTimingInfo>> scheduled_resource_timing_reports_; | 243 Vector<RefPtr<ResourceTimingInfo>> scheduled_resource_timing_reports_; |
244 | 244 |
245 HeapHashSet<Member<ResourceLoader>> loaders_; | 245 HeapHashSet<Member<ResourceLoader>> loaders_; |
246 HeapHashSet<Member<ResourceLoader>> non_blocking_loaders_; | 246 HeapHashSet<Member<ResourceLoader>> non_blocking_loaders_; |
247 | 247 |
248 // Used in hit rate histograms. | |
249 class DeadResourceStatsRecorder { | |
250 DISALLOW_NEW(); | |
251 | |
252 public: | |
253 DeadResourceStatsRecorder(); | |
254 ~DeadResourceStatsRecorder(); | |
255 | |
256 void Update(RevalidationPolicy); | |
257 | |
258 private: | |
259 int use_count_; | |
260 int revalidate_count_; | |
261 int load_count_; | |
262 }; | |
263 DeadResourceStatsRecorder dead_stats_recorder_; | |
264 | |
265 std::unique_ptr<HashSet<String>> preloaded_urls_for_test_; | 248 std::unique_ptr<HashSet<String>> preloaded_urls_for_test_; |
266 | 249 |
267 // 28 bits left | 250 // 28 bits left |
268 bool auto_load_images_ : 1; | 251 bool auto_load_images_ : 1; |
269 bool images_enabled_ : 1; | 252 bool images_enabled_ : 1; |
270 bool allow_stale_resources_ : 1; | 253 bool allow_stale_resources_ : 1; |
271 bool image_fetched_ : 1; | 254 bool image_fetched_ : 1; |
272 }; | 255 }; |
273 | 256 |
274 class ResourceCacheValidationSuppressor { | 257 class ResourceCacheValidationSuppressor { |
(...skipping 14 matching lines...) Expand all Loading... |
289 } | 272 } |
290 | 273 |
291 private: | 274 private: |
292 Member<ResourceFetcher> loader_; | 275 Member<ResourceFetcher> loader_; |
293 bool previous_state_; | 276 bool previous_state_; |
294 }; | 277 }; |
295 | 278 |
296 } // namespace blink | 279 } // namespace blink |
297 | 280 |
298 #endif // ResourceFetcher_h | 281 #endif // ResourceFetcher_h |
OLD | NEW |