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

Unified Diff: chrome/browser/extensions/api/storage/settings_frontend.h

Issue 184043031: Split up extensions storage API implementations for sync and local storage. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase (split_sync) Created 6 years, 9 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
Index: chrome/browser/extensions/api/storage/settings_frontend.h
diff --git a/chrome/browser/extensions/api/storage/settings_frontend.h b/chrome/browser/extensions/api/storage/settings_frontend.h
index eadaaa29675740650a1be7fda05e6c18a071e405..cd0c594ef0834f157cffe4d5e1e708107d922618 100644
--- a/chrome/browser/extensions/api/storage/settings_frontend.h
+++ b/chrome/browser/extensions/api/storage/settings_frontend.h
@@ -12,11 +12,9 @@
#include "base/memory/scoped_ptr.h"
#include "chrome/browser/extensions/api/storage/settings_observer.h"
#include "chrome/browser/extensions/api/storage/settings_storage_factory.h"
-#include "chrome/browser/extensions/api/storage/settings_storage_quota_enforcer.h"
#include "chrome/browser/extensions/api/storage/value_store_cache.h"
#include "extensions/browser/api/storage/settings_namespace.h"
#include "extensions/browser/browser_context_keyed_api_factory.h"
-#include "sync/api/syncable_service.h"
namespace content {
class BrowserContext;
@@ -26,8 +24,6 @@ namespace extensions {
// The component of extension settings which runs on the UI thread, as opposed
// to SettingsBackend which lives on the FILE thread.
-// All public methods, must be called on the UI thread, with the exception of
-// GetBackendForSync(), which must be called on the FILE thread.
class SettingsFrontend : public BrowserContextKeyedAPI {
public:
// Returns the current instance for |context|.
@@ -41,9 +37,9 @@ class SettingsFrontend : public BrowserContextKeyedAPI {
// Public so tests can create and delete their own instances.
virtual ~SettingsFrontend();
- // Must only be called from the FILE thread. |type| should be either
- // APP_SETTINGS or EXTENSION_SETTINGS.
- syncer::SyncableService* GetBackendForSync(syncer::ModelType type) const;
+ // Returns the value store cache for |settings_namespace|.
+ ValueStoreCache* GetValueStoreCache(
+ settings_namespace::Namespace settings_namespace) const;
// Returns true if |settings_namespace| is a valid namespace.
bool IsStorageEnabled(settings_namespace::Namespace settings_namespace) const;
@@ -83,11 +79,6 @@ class SettingsFrontend : public BrowserContextKeyedAPI {
void Init(const scoped_refptr<SettingsStorageFactory>& storage_factory);
- // The quota limit configurations for the local and sync areas, taken out of
- // the schema in chrome/common/extensions/api/storage.json.
- const SettingsStorageQuotaEnforcer::Limits local_quota_limit_;
- const SettingsStorageQuotaEnforcer::Limits sync_quota_limit_;
-
// The (non-incognito) browser context this Frontend belongs to.
content::BrowserContext* const browser_context_;
« no previous file with comments | « chrome/browser/extensions/api/storage/settings_apitest.cc ('k') | chrome/browser/extensions/api/storage/settings_frontend.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698