Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(442)

Side by Side Diff: webkit/quota/mock_special_storage_policy.cc

Issue 10066044: RefCounted types should not have public destructors, webkit/ (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Implementation ordering Created 8 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « webkit/quota/mock_special_storage_policy.h ('k') | webkit/quota/quota_database_unittest.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 #include "webkit/quota/mock_special_storage_policy.h" 5 #include "webkit/quota/mock_special_storage_policy.h"
6 6
7 namespace quota { 7 namespace quota {
8 8
9 MockSpecialStoragePolicy::MockSpecialStoragePolicy() 9 MockSpecialStoragePolicy::MockSpecialStoragePolicy()
10 : all_unlimited_(false) {} 10 : all_unlimited_(false) {
11 11 }
12 MockSpecialStoragePolicy::~MockSpecialStoragePolicy() {}
13 12
14 bool MockSpecialStoragePolicy::IsStorageProtected(const GURL& origin) { 13 bool MockSpecialStoragePolicy::IsStorageProtected(const GURL& origin) {
15 return protected_.find(origin) != protected_.end(); 14 return protected_.find(origin) != protected_.end();
16 } 15 }
17 16
18 bool MockSpecialStoragePolicy::IsStorageUnlimited(const GURL& origin) { 17 bool MockSpecialStoragePolicy::IsStorageUnlimited(const GURL& origin) {
19 if (all_unlimited_) 18 if (all_unlimited_)
20 return true; 19 return true;
21 return unlimited_.find(origin) != unlimited_.end(); 20 return unlimited_.find(origin) != unlimited_.end();
22 } 21 }
23 22
24 bool MockSpecialStoragePolicy::IsStorageSessionOnly(const GURL& origin) { 23 bool MockSpecialStoragePolicy::IsStorageSessionOnly(const GURL& origin) {
25 return session_only_.find(origin) != session_only_.end(); 24 return session_only_.find(origin) != session_only_.end();
26 } 25 }
27 26
28 bool MockSpecialStoragePolicy::IsFileHandler(const std::string& extension_id) { 27 bool MockSpecialStoragePolicy::IsFileHandler(const std::string& extension_id) {
29 return file_handlers_.find(extension_id) != file_handlers_.end(); 28 return file_handlers_.find(extension_id) != file_handlers_.end();
30 } 29 }
31 30
32 bool MockSpecialStoragePolicy::HasSessionOnlyOrigins() { 31 bool MockSpecialStoragePolicy::HasSessionOnlyOrigins() {
33 return !session_only_.empty(); 32 return !session_only_.empty();
34 } 33 }
35 34
35 MockSpecialStoragePolicy::~MockSpecialStoragePolicy() {}
36
36 } // namespace quota 37 } // namespace quota
OLDNEW
« no previous file with comments | « webkit/quota/mock_special_storage_policy.h ('k') | webkit/quota/quota_database_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698