| 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 CHROME_BROWSER_BROWSING_DATA_QUOTA_HELPER_H_ | 5 #ifndef CHROME_BROWSER_BROWSING_DATA_QUOTA_HELPER_H_ |
| 6 #define CHROME_BROWSER_BROWSING_DATA_QUOTA_HELPER_H_ | 6 #define CHROME_BROWSER_BROWSING_DATA_QUOTA_HELPER_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include <list> | 9 #include <list> |
| 10 #include <string> | 10 #include <string> |
| 11 | 11 |
| 12 #include "base/callback.h" | 12 #include "base/callback.h" |
| 13 #include "base/memory/ref_counted.h" | 13 #include "base/memory/ref_counted.h" |
| 14 #include "base/message_loop_helpers.h" |
| 14 #include "base/message_loop_proxy.h" | 15 #include "base/message_loop_proxy.h" |
| 15 #include "base/time.h" | 16 #include "base/time.h" |
| 16 #include "content/public/browser/browser_thread.h" | 17 #include "content/public/browser/browser_thread.h" |
| 17 #include "webkit/quota/quota_types.h" | 18 #include "webkit/quota/quota_types.h" |
| 18 | 19 |
| 19 class BrowsingDataQuotaHelper; | 20 class BrowsingDataQuotaHelper; |
| 20 class Profile; | 21 class Profile; |
| 21 | 22 |
| 22 struct BrowsingDataQuotaHelperDeleter { | 23 struct BrowsingDataQuotaHelperDeleter { |
| 23 static void Destruct(const BrowsingDataQuotaHelper* helper); | 24 static void Destruct(const BrowsingDataQuotaHelper* helper); |
| (...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 66 virtual void StartFetching(const FetchResultCallback& callback) = 0; | 67 virtual void StartFetching(const FetchResultCallback& callback) = 0; |
| 67 virtual void CancelNotification() = 0; | 68 virtual void CancelNotification() = 0; |
| 68 | 69 |
| 69 virtual void RevokeHostQuota(const std::string& host) = 0; | 70 virtual void RevokeHostQuota(const std::string& host) = 0; |
| 70 | 71 |
| 71 protected: | 72 protected: |
| 72 explicit BrowsingDataQuotaHelper(base::MessageLoopProxy* io_thread_); | 73 explicit BrowsingDataQuotaHelper(base::MessageLoopProxy* io_thread_); |
| 73 virtual ~BrowsingDataQuotaHelper(); | 74 virtual ~BrowsingDataQuotaHelper(); |
| 74 | 75 |
| 75 private: | 76 private: |
| 76 friend class DeleteTask<const BrowsingDataQuotaHelper>; | 77 friend class base::DeleteHelper<BrowsingDataQuotaHelper>; |
| 77 friend struct BrowsingDataQuotaHelperDeleter; | 78 friend struct BrowsingDataQuotaHelperDeleter; |
| 78 scoped_refptr<base::MessageLoopProxy> io_thread_; | 79 scoped_refptr<base::MessageLoopProxy> io_thread_; |
| 79 | 80 |
| 80 DISALLOW_COPY_AND_ASSIGN(BrowsingDataQuotaHelper); | 81 DISALLOW_COPY_AND_ASSIGN(BrowsingDataQuotaHelper); |
| 81 }; | 82 }; |
| 82 | 83 |
| 83 #endif // CHROME_BROWSER_BROWSING_DATA_QUOTA_HELPER_H_ | 84 #endif // CHROME_BROWSER_BROWSING_DATA_QUOTA_HELPER_H_ |
| OLD | NEW |