From 33058f2b292b3a581333bdfb21b8f671898c5060 Mon Sep 17 00:00:00 2001 From: Peter Bengtsson Date: Tue, 8 Dec 2020 14:40:17 -0500 Subject: initial commit --- files/zh-cn/web/api/storageestimate/index.html | 103 +++++++++++++++++++++++++ 1 file changed, 103 insertions(+) create mode 100644 files/zh-cn/web/api/storageestimate/index.html (limited to 'files/zh-cn/web/api/storageestimate') diff --git a/files/zh-cn/web/api/storageestimate/index.html b/files/zh-cn/web/api/storageestimate/index.html new file mode 100644 index 0000000000..74e0fa95cc --- /dev/null +++ b/files/zh-cn/web/api/storageestimate/index.html @@ -0,0 +1,103 @@ +--- +title: StorageEstimate +slug: Web/API/StorageEstimate +translation_of: Web/API/StorageEstimate +--- +
{{securecontext_header}}{{APIRef("Storage")}}
+ +
 
+ +

StorageEstimate 提供对你的域名或Web app的数据存储空间总量和已用量的估计值,该对象实例由{{domxref("StorageManager")}}的{{domxref("StorageManager.estimate", "estimate()")}} 方法返回的{{jsxref("Promise")}}返回.

+ +

这些值仅为估计值有多种原因,既有对性能的考虑,也有防止将其作为指纹(fingerprinting)的目的.详情请参看属性.

+ +

属性

+ +

该对象目前总是同时包含以下两个属性.

+ +
+
{{domxref("StorageEstimate.quota", "quota")}} {{securecontext_inline}}
+
用户设备为你的域名或Web app预留的存储空间总大小,且该大小为估计值.虽然实际上可能有比这更多的存储空间,但这时你不应使用那多余的部分.
+
{{domxref("StorageEstimate.usage", "usage")}} {{securecontext_inline}}
+
你的域名或Web app已经使用的存储空间大小,且该大小为估计值.剩余可用空间请综合quota属性计算.
+
+ +

规范

+ + + + + + + + + + + + + + +
SpecificationStatusComment
{{SpecName('Storage', '#dictdef-storageestimate', 'StorageEstimate')}}{{Spec2('Storage')}}Initial definition.
+ +

浏览器兼容性

+ +
{{CompatibilityTable}}
+ +
+ + + + + + + + + + + + + + + + + + + + + +
FeatureChromeFirefox (Gecko)Internet ExplorerMicrosoft EdgeOperaSafari (WebKit)
Basic support{{CompatChrome(55)}}{{CompatGeckoDesktop(57)}}{{CompatUnknown}}{{CompatUnknown}}{{CompatOpera(42)}}{{CompatUnknown}}
+
+ +
+ + + + + + + + + + + + + + + + + + + + + +
FeatureAndroid WebviewChrome for AndroidFirefox Mobile (Gecko)IE MobileOpera MobileSafari Mobile
Basic support{{CompatUnknown}}{{CompatChrome(55)}}{{ CompatGeckoMobile(57)}}{{CompatUnknown}}{{CompatOperaMobile(42)}}{{CompatUnknown}}
+
+ +

相关链接

+ + -- cgit v1.2.3-54-g00ecf