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

Unified Diff: chrome/browser/extensions/api/system_storage/system_storage_api.h

Issue 18578008: [SystemInfo API] Move Storage API out of experimental namespace and rename to the "system" namespace (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix PermissionTest unittest. Created 7 years, 5 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/system_storage/system_storage_api.h
diff --git a/chrome/browser/extensions/api/system_info_storage/system_info_storage_api.h b/chrome/browser/extensions/api/system_storage/system_storage_api.h
similarity index 34%
rename from chrome/browser/extensions/api/system_info_storage/system_info_storage_api.h
rename to chrome/browser/extensions/api/system_storage/system_storage_api.h
index 7d99e844cfc5f6bbda8e2ca7e09b8a2c11ed0037..d0d84da60ad585b9c36f9e1bb64e383e50cd1c9f 100644
--- a/chrome/browser/extensions/api/system_info_storage/system_info_storage_api.h
+++ b/chrome/browser/extensions/api/system_storage/system_storage_api.h
@@ -1,10 +1,10 @@
// 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 CHROME_BROWSER_EXTENSIONS_API_SYSTEM_INFO_STORAGE_SYSTEM_INFO_STORAGE_API_H_
-#define CHROME_BROWSER_EXTENSIONS_API_SYSTEM_INFO_STORAGE_SYSTEM_INFO_STORAGE_API_H_
+#ifndef CHROME_BROWSER_EXTENSIONS_API_SYSTEM_STORAGE_SYSTEM_STORAGE_API_H_
+#define CHROME_BROWSER_EXTENSIONS_API_SYSTEM_STORAGE_SYSTEM_STORAGE_API_H_
-#include "chrome/browser/extensions/api/system_info_storage/storage_info_provider.h"
+#include "chrome/browser/extensions/api/system_storage/storage_info_provider.h"
#include "chrome/browser/extensions/extension_function.h"
#include "chrome/browser/storage_monitor/storage_monitor.h"
@@ -12,27 +12,26 @@ namespace extensions {
// Implementation of the systeminfo.storage.get API. It is an asynchronous
// call relative to browser UI thread.
-class SystemInfoStorageGetFunction : public AsyncExtensionFunction {
+class SystemStorageGetInfoFunction : public AsyncExtensionFunction {
public:
- DECLARE_EXTENSION_FUNCTION("experimental.systemInfo.storage.get",
- EXPERIMENTAL_SYSTEMINFO_STORAGE_GET)
- SystemInfoStorageGetFunction();
+ DECLARE_EXTENSION_FUNCTION("system.storage.getInfo", SYSTEM_STORAGE_GETINFO);
+ SystemStorageGetInfoFunction();
private:
- virtual ~SystemInfoStorageGetFunction();
+ virtual ~SystemStorageGetInfoFunction();
virtual bool RunImpl() OVERRIDE;
void OnGetStorageInfoCompleted(bool success);
};
-class SystemInfoStorageEjectDeviceFunction
+class SystemStorageEjectDeviceFunction
: public AsyncExtensionFunction {
public:
- DECLARE_EXTENSION_FUNCTION("experimental.systemInfo.storage.ejectDevice",
- EXPERIMENTAL_SYSTEMINFO_STORAGE_EJECTDEVICE);
+ DECLARE_EXTENSION_FUNCTION("system.storage.ejectDevice",
+ SYSTEM_STORAGE_EJECTDEVICE);
protected:
- virtual ~SystemInfoStorageEjectDeviceFunction();
+ virtual ~SystemStorageEjectDeviceFunction();
// AsyncExtensionFunction overrides.
virtual bool RunImpl() OVERRIDE;
@@ -44,50 +43,54 @@ class SystemInfoStorageEjectDeviceFunction
void HandleResponse(chrome::StorageMonitor::EjectStatus status);
};
-class SystemInfoStorageAddWatchFunction : public AsyncExtensionFunction {
+class SystemStorageAddAvailableCapacityWatchFunction
+ : public AsyncExtensionFunction {
public:
- DECLARE_EXTENSION_FUNCTION("experimental.systemInfo.storage.addWatch",
- EXPERIMENTAL_SYSTEMINFO_STORAGE_ADDWATCH);
- SystemInfoStorageAddWatchFunction();
+ DECLARE_EXTENSION_FUNCTION("system.storage.addAvailableCapacityWatch",
+ SYSTEM_STORAGE_ADDAVAILABLECAPACITYWATCH);
+ SystemStorageAddAvailableCapacityWatchFunction();
private:
- virtual ~SystemInfoStorageAddWatchFunction();
+ virtual ~SystemStorageAddAvailableCapacityWatchFunction();
virtual bool RunImpl() OVERRIDE;
};
-class SystemInfoStorageRemoveWatchFunction : public SyncExtensionFunction {
+class SystemStorageRemoveAvailableCapacityWatchFunction
+ : public SyncExtensionFunction {
public:
- DECLARE_EXTENSION_FUNCTION("experimental.systemInfo.storage.removeWatch",
- EXPERIMENTAL_SYSTEMINFO_STORAGE_REMOVEWATCH);
- SystemInfoStorageRemoveWatchFunction();
+ DECLARE_EXTENSION_FUNCTION("system.storage.removeAvailableCapacityWatch",
+ SYSTEM_STORAGE_REMOVEAVAILABLECAPACITYWATCH);
+ SystemStorageRemoveAvailableCapacityWatchFunction();
private:
- virtual ~SystemInfoStorageRemoveWatchFunction();
+ virtual ~SystemStorageRemoveAvailableCapacityWatchFunction();
virtual bool RunImpl() OVERRIDE;
};
-class SystemInfoStorageGetAllWatchFunction : public SyncExtensionFunction {
+class SystemStorageGetAllAvailableCapacityWatchesFunction
+ : public SyncExtensionFunction {
public:
- DECLARE_EXTENSION_FUNCTION("experimental.systemInfo.storage.getAllWatch",
- EXPERIMENTAL_SYSTEMINFO_STORAGE_GETALLWATCH);
- SystemInfoStorageGetAllWatchFunction();
+ DECLARE_EXTENSION_FUNCTION("system.storage.getAllAvailableCapacityWatches",
+ SYSTEM_STORAGE_GETALLAVAILABLECAPACITYWATCHES);
+ SystemStorageGetAllAvailableCapacityWatchesFunction();
private:
- virtual ~SystemInfoStorageGetAllWatchFunction();
+ virtual ~SystemStorageGetAllAvailableCapacityWatchesFunction();
virtual bool RunImpl() OVERRIDE;
};
-class SystemInfoStorageRemoveAllWatchFunction : public SyncExtensionFunction {
+class SystemStorageRemoveAllAvailableCapacityWatchesFunction
+ : public SyncExtensionFunction {
public:
- DECLARE_EXTENSION_FUNCTION("experimental.systemInfo.storage.removeAllWatch",
- EXPERIMENTAL_SYSTEMINFO_STORAGE_REMOVEALLWATCH);
- SystemInfoStorageRemoveAllWatchFunction();
+ DECLARE_EXTENSION_FUNCTION("system.storage.removeAllAvailableCapacityWatches",
+ SYSTEM_STORAGE_REMOVEALLAVAILABLECAPACITYWATCHES);
+ SystemStorageRemoveAllAvailableCapacityWatchesFunction();
private:
- virtual ~SystemInfoStorageRemoveAllWatchFunction();
+ virtual ~SystemStorageRemoveAllAvailableCapacityWatchesFunction();
virtual bool RunImpl() OVERRIDE;
};
} // namespace extensions
-#endif // CHROME_BROWSER_EXTENSIONS_API_SYSTEM_INFO_STORAGE_SYSTEM_INFO_STORAGE_API_H_
+#endif // CHROME_BROWSER_EXTENSIONS_API_SYSTEM_STORAGE_SYSTEM_STORAGE_API_H_

Powered by Google App Engine
This is Rietveld 408576698