summaryrefslogtreecommitdiffstats
path: root/extensions
diff options
context:
space:
mode:
Diffstat (limited to 'extensions')
-rw-r--r--extensions/browser/api/extensions_api_client.cc27
-rw-r--r--extensions/browser/api/extensions_api_client.h56
-rw-r--r--extensions/browser/api/storage/settings_namespace.cc46
-rw-r--r--extensions/browser/api/storage/settings_namespace.h34
-rw-r--r--extensions/extensions.gyp4
5 files changed, 0 insertions, 167 deletions
diff --git a/extensions/browser/api/extensions_api_client.cc b/extensions/browser/api/extensions_api_client.cc
deleted file mode 100644
index c4f8013..0000000
--- a/extensions/browser/api/extensions_api_client.cc
+++ /dev/null
@@ -1,27 +0,0 @@
-// Copyright 2014 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#include "extensions/browser/api/extensions_api_client.h"
-
-namespace extensions {
-namespace {
-
-ExtensionsAPIClient* g_instance = NULL;
-
-} // namespace
-
-ExtensionsAPIClient::ExtensionsAPIClient() { g_instance = this; }
-
-ExtensionsAPIClient::~ExtensionsAPIClient() { g_instance = NULL; }
-
-// static
-ExtensionsAPIClient* ExtensionsAPIClient::Get() { return g_instance; }
-
-void ExtensionsAPIClient::AddAdditionalValueStoreCaches(
- content::BrowserContext* context,
- const scoped_refptr<SettingsStorageFactory>& factory,
- const scoped_refptr<ObserverListThreadSafe<SettingsObserver> >& observers,
- std::map<settings_namespace::Namespace, ValueStoreCache*>* caches) {}
-
-} // namespace extensions
diff --git a/extensions/browser/api/extensions_api_client.h b/extensions/browser/api/extensions_api_client.h
deleted file mode 100644
index 88dbaa4..0000000
--- a/extensions/browser/api/extensions_api_client.h
+++ /dev/null
@@ -1,56 +0,0 @@
-// Copyright 2014 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#ifndef EXTENSIONS_BROWSER_API_EXTENSIONS_API_CLIENT_H_
-#define EXTENSIONS_BROWSER_API_EXTENSIONS_API_CLIENT_H_
-
-#include <map>
-
-#include "base/memory/ref_counted.h"
-#include "extensions/browser/api/storage/settings_namespace.h"
-
-template <class T>
-class ObserverListThreadSafe;
-
-namespace content {
-class BrowserContext;
-}
-
-namespace extensions {
-
-class SettingsObserver;
-class SettingsStorageFactory;
-class ValueStoreCache;
-
-// Allows the embedder of the extensions module to customize its support for
-// API features. The embedder must create a single instance in the browser
-// process. Provides a default implementation that does nothing.
-class ExtensionsAPIClient {
- public:
- // Construction sets the single instance.
- ExtensionsAPIClient();
-
- // Destruction clears the single instance.
- virtual ~ExtensionsAPIClient();
-
- // Returns the single instance of |this|.
- static ExtensionsAPIClient* Get();
-
- // Storage API support.
-
- // Add any additional value store caches (e.g. for chrome.storage.managed)
- // to |caches|. By default adds nothing.
- virtual void AddAdditionalValueStoreCaches(
- content::BrowserContext* context,
- const scoped_refptr<SettingsStorageFactory>& factory,
- const scoped_refptr<ObserverListThreadSafe<SettingsObserver> >& observers,
- std::map<settings_namespace::Namespace, ValueStoreCache*>* caches);
-
- // NOTE: If this interface gains too many methods (perhaps more than 20) it
- // should be split into one interface per API.
-};
-
-} // namespace extensions
-
-#endif // EXTENSIONS_BROWSER_API_EXTENSIONS_API_CLIENT_H_
diff --git a/extensions/browser/api/storage/settings_namespace.cc b/extensions/browser/api/storage/settings_namespace.cc
deleted file mode 100644
index e178c7c..0000000
--- a/extensions/browser/api/storage/settings_namespace.cc
+++ /dev/null
@@ -1,46 +0,0 @@
-// Copyright (c) 2012 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#include "extensions/browser/api/storage/settings_namespace.h"
-
-#include "base/logging.h"
-
-namespace extensions {
-
-namespace settings_namespace {
-
-namespace {
-const char kLocalNamespace[] = "local";
-const char kSyncNamespace[] = "sync";
-const char kManagedNamespace[] = "managed";
-} // namespace
-
-std::string ToString(Namespace settings_namespace) {
- switch (settings_namespace) {
- case LOCAL:
- return kLocalNamespace;
- case SYNC:
- return kSyncNamespace;
- case MANAGED:
- return kManagedNamespace;
- case INVALID:
- break;
- }
- NOTREACHED();
- return std::string();
-}
-
-Namespace FromString(const std::string& namespace_string) {
- if (namespace_string == kLocalNamespace)
- return LOCAL;
- if (namespace_string == kSyncNamespace)
- return SYNC;
- if (namespace_string == kManagedNamespace)
- return MANAGED;
- return INVALID;
-}
-
-} // namespace settings_namespace
-
-} // namespace extensions
diff --git a/extensions/browser/api/storage/settings_namespace.h b/extensions/browser/api/storage/settings_namespace.h
deleted file mode 100644
index 7a5a812..0000000
--- a/extensions/browser/api/storage/settings_namespace.h
+++ /dev/null
@@ -1,34 +0,0 @@
-// Copyright (c) 2012 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#ifndef EXTENSIONS_BROWSER_API_STORAGE_SETTINGS_NAMESPACE_H_
-#define EXTENSIONS_BROWSER_API_STORAGE_SETTINGS_NAMESPACE_H_
-
-#include <string>
-
-namespace extensions {
-
-namespace settings_namespace {
-
-// The namespaces of the storage areas.
-enum Namespace {
- LOCAL, // "local" i.e. chrome.storage.local
- SYNC, // "sync" i.e. chrome.storage.sync
- MANAGED, // "managed" i.e. chrome.storage.managed
- INVALID
-};
-
-// Converts a namespace to its string representation.
-// Namespace must not be INVALID.
-std::string ToString(Namespace settings_namespace);
-
-// Converts a string representation of a namespace to its namespace, or INVALID
-// if the string doesn't map to one.
-Namespace FromString(const std::string& ns_string);
-
-} // namespace settings_namespace
-
-} // namespace extensions
-
-#endif // EXTENSIONS_BROWSER_API_STORAGE_SETTINGS_NAMESPACE_H_
diff --git a/extensions/extensions.gyp b/extensions/extensions.gyp
index 4c69d6f..0c5d717 100644
--- a/extensions/extensions.gyp
+++ b/extensions/extensions.gyp
@@ -170,10 +170,6 @@
'browser/admin_policy.h',
'browser/api/async_api_function.cc',
'browser/api/async_api_function.h',
- 'browser/api/extensions_api_client.cc',
- 'browser/api/extensions_api_client.h',
- 'browser/api/storage/settings_namespace.cc',
- 'browser/api/storage/settings_namespace.h',
'browser/api_activity_monitor.h',
'browser/app_sorting.h',
'browser/blacklist_state.h',