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

Unified Diff: webkit/browser/quota/storage_observer.h

Issue 539143002: Migrate webkit/browser/ to storage/browser/ (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix android build Created 6 years, 3 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « webkit/browser/quota/storage_monitor.cc ('k') | webkit/browser/quota/storage_observer.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webkit/browser/quota/storage_observer.h
diff --git a/webkit/browser/quota/storage_observer.h b/webkit/browser/quota/storage_observer.h
index 1272f941b2cb9dff0571dc345522978d905432c3..e732df1d4e1c8fd32e06800d17f1a10dae072d7c 100644
--- a/webkit/browser/quota/storage_observer.h
+++ b/webkit/browser/quota/storage_observer.h
@@ -2,78 +2,4 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#ifndef WEBKIT_BROWSER_QUOTA_STORAGE_OBSERVER_H_
-#define WEBKIT_BROWSER_QUOTA_STORAGE_OBSERVER_H_
-
-#include "base/basictypes.h"
-#include "base/time/time.h"
-#include "url/gurl.h"
-#include "webkit/browser/quota/quota_client.h"
-#include "webkit/common/quota/quota_types.h"
-
-namespace storage {
-
-// This interface is implemented by observers that wish to monitor storage
-// events, such as changes in quota or usage.
-class STORAGE_EXPORT StorageObserver {
- public:
- struct STORAGE_EXPORT Filter {
- // The storage type to monitor. This must not be kStorageTypeUnknown or
- // kStorageTypeQuotaNotManaged.
- StorageType storage_type;
-
- // The origin to monitor usage for. Must be specified.
- GURL origin;
-
- Filter();
- Filter(StorageType storage_type, const GURL& origin);
- bool operator==(const Filter& other) const;
- };
-
- struct STORAGE_EXPORT MonitorParams {
- // Storage type and origin to monitor.
- Filter filter;
-
- // The rate at which storage events will be fired. Events will be fired at
- // approximately this rate, or when a storage status change has been
- // detected, whichever is the least frequent.
- base::TimeDelta rate;
-
- // If set to true, the observer will be dispatched an event when added.
- bool dispatch_initial_state;
-
- MonitorParams();
- MonitorParams(StorageType storage_type,
- const GURL& origin,
- const base::TimeDelta& rate,
- bool get_initial_state);
- MonitorParams(const Filter& filter,
- const base::TimeDelta& rate,
- bool get_initial_state);
- };
-
- struct STORAGE_EXPORT Event {
- // The storage type and origin monitored.
- Filter filter;
-
- // The current usage corresponding to the filter.
- int64 usage;
-
- // The quota corresponding to the filter.
- int64 quota;
-
- Event();
- Event(const Filter& filter, int64 usage, int64 quota);
- bool operator==(const Event& other) const;
- };
-
- // Will be called on the IO thread when a storage event occurs.
- virtual void OnStorageEvent(const Event& event) = 0;
-
- protected:
- virtual ~StorageObserver() {}
-};
-
-} // namespace storage
-
-#endif // WEBKIT_BROWSER_QUOTA_STORAGE_OBSERVER_H_
+#include "storage/browser/quota/storage_observer.h"
« no previous file with comments | « webkit/browser/quota/storage_monitor.cc ('k') | webkit/browser/quota/storage_observer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698