Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 #include "content/browser/cache_storage/cache_storage_cache.h" | 5 #include "content/browser/cache_storage/cache_storage_cache.h" |
| 6 | 6 |
| 7 #include "base/files/file_path.h" | 7 #include "base/files/file_path.h" |
| 8 #include "base/files/scoped_temp_dir.h" | 8 #include "base/files/scoped_temp_dir.h" |
| 9 #include "base/memory/ref_counted.h" | 9 #include "base/memory/ref_counted.h" |
| 10 #include "base/memory/scoped_ptr.h" | 10 #include "base/memory/scoped_ptr.h" |
| (...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 84 } | 84 } |
| 85 int DoomEntriesBetween(base::Time initial_time, | 85 int DoomEntriesBetween(base::Time initial_time, |
| 86 base::Time end_time, | 86 base::Time end_time, |
| 87 const CompletionCallback& callback) override { | 87 const CompletionCallback& callback) override { |
| 88 return backend_->DoomEntriesBetween(initial_time, end_time, callback); | 88 return backend_->DoomEntriesBetween(initial_time, end_time, callback); |
| 89 } | 89 } |
| 90 int DoomEntriesSince(base::Time initial_time, | 90 int DoomEntriesSince(base::Time initial_time, |
| 91 const CompletionCallback& callback) override { | 91 const CompletionCallback& callback) override { |
| 92 return backend_->DoomEntriesSince(initial_time, callback); | 92 return backend_->DoomEntriesSince(initial_time, callback); |
| 93 } | 93 } |
| 94 int CalculateSizeOfEntriesBetween( | |
| 95 base::Time initial_time, | |
| 96 base::Time end_time, | |
| 97 const CompletionCallback& callback) override { | |
| 98 return backend_->DoomEntriesSince(initial_time, end_time, callback); | |
|
jkarlin
2015/09/03 11:05:53
Hmm, DoomEntriesSince doesn't seem right. Perhaps:
msramek
2015/09/03 11:22:22
We can just propagate the call to |backend_|. I no
| |
| 99 } | |
| 94 scoped_ptr<Iterator> CreateIterator() override { | 100 scoped_ptr<Iterator> CreateIterator() override { |
| 95 return backend_->CreateIterator(); | 101 return backend_->CreateIterator(); |
| 96 } | 102 } |
| 97 void GetStats(base::StringPairs* stats) override { | 103 void GetStats(base::StringPairs* stats) override { |
| 98 return backend_->GetStats(stats); | 104 return backend_->GetStats(stats); |
| 99 } | 105 } |
| 100 void OnExternalCacheHit(const std::string& key) override { | 106 void OnExternalCacheHit(const std::string& key) override { |
| 101 return backend_->OnExternalCacheHit(key); | 107 return backend_->OnExternalCacheHit(key); |
| 102 } | 108 } |
| 103 | 109 |
| (...skipping 902 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 1006 EXPECT_EQ(1, sequence_out); | 1012 EXPECT_EQ(1, sequence_out); |
| 1007 close_loop2->Run(); | 1013 close_loop2->Run(); |
| 1008 EXPECT_EQ(2, sequence_out); | 1014 EXPECT_EQ(2, sequence_out); |
| 1009 } | 1015 } |
| 1010 | 1016 |
| 1011 INSTANTIATE_TEST_CASE_P(CacheStorageCacheTest, | 1017 INSTANTIATE_TEST_CASE_P(CacheStorageCacheTest, |
| 1012 CacheStorageCacheTestP, | 1018 CacheStorageCacheTestP, |
| 1013 ::testing::Values(false, true)); | 1019 ::testing::Values(false, true)); |
| 1014 | 1020 |
| 1015 } // namespace content | 1021 } // namespace content |
| OLD | NEW |