1 /* This Source Code Form is subject to the terms of the Mozilla Public
2 * License, v. 2.0. If a copy of the MPL was not distributed with this file,
3 * You can obtain one at http://mozilla.org/MPL/2.0/. */
5 include protocol PBackground;
6 include protocol PQuotaRequest;
7 include protocol PQuotaUsageRequest;
9 include PBackgroundSharedTypes;
11 include "mozilla/dom/quota/SerializationHelpers.h";
13 using mozilla::OriginAttributesPattern
14 from "mozilla/OriginAttributes.h";
16 using mozilla::dom::quota::PersistenceType
17 from "mozilla/dom/quota/PersistenceType.h";
19 using mozilla::dom::quota::Client::Type
20 from "mozilla/dom/quota/Client.h";
22 using mozilla::dom::ContentParentId
23 from "mozilla/dom/ipc/IdType.h";
40 struct StorageNameParams
44 struct InitializePersistentOriginParams
46 PrincipalInfo principalInfo;
49 struct InitializeTemporaryOriginParams
51 PersistenceType persistenceType;
52 PrincipalInfo principalInfo;
55 struct GetFullOriginMetadataParams
57 PersistenceType persistenceType;
58 PrincipalInfo principalInfo;
66 struct OriginUsageParams
68 PrincipalInfo principalInfo;
72 union UsageRequestParams
78 struct ClearResetOriginParams
80 PrincipalInfo principalInfo;
81 PersistenceType persistenceType;
82 bool persistenceTypeIsExplicit;
84 bool clientTypeIsExplicit;
87 struct ResetOriginParams
89 ClearResetOriginParams commonParams;
92 struct PersistedParams
94 PrincipalInfo principalInfo;
99 PrincipalInfo principalInfo;
102 struct EstimateParams
104 PrincipalInfo principalInfo;
107 struct ListOriginsParams
114 InitializePersistentOriginParams;
115 InitializeTemporaryOriginParams;
116 GetFullOriginMetadataParams;
124 [ChildImpl=virtual, ParentImpl=virtual]
129 manages PQuotaRequest;
130 manages PQuotaUsageRequest;
135 async PQuotaUsageRequest(UsageRequestParams params);
137 async PQuotaRequest(RequestParams params);
139 async StorageInitialized()
140 returns(BoolResponse response);
142 async TemporaryStorageInitialized()
143 returns(BoolResponse response);
145 async InitializeStorage()
146 returns(BoolResponse response);
148 async InitializePersistentClient(PrincipalInfo principalInfo,
150 returns(BoolResponse response);
152 async InitializeTemporaryClient(PersistenceType persistenceType,
153 PrincipalInfo principalInfo,
155 returns(BoolResponse response);
157 async InitializeTemporaryStorage()
158 returns(BoolResponse response);
160 async ClearStoragesForOrigin(PersistenceType? persistenceType,
161 PrincipalInfo principalInfo,
163 returns(BoolResponse response);
165 async ClearStoragesForOriginPrefix(PersistenceType? persistenceType,
166 PrincipalInfo principalInfo)
167 returns(BoolResponse response);
169 // This can only be called from some other thread in the parent process!
170 async ClearStoragesForOriginAttributesPattern(OriginAttributesPattern pattern)
171 returns(BoolResponse response);
173 async ClearStoragesForPrivateBrowsing()
174 returns(BoolResponse response);
177 returns(BoolResponse response);
179 async ShutdownStorage()
180 returns(BoolResponse response);
182 async StartIdleMaintenance();
184 async StopIdleMaintenance();
186 async AbortOperationsForProcess(ContentParentId contentParentId);
191 } // namespace mozilla