// Copyright 2023 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
[
Global=SharedStorageWorklet,
Exposed=SharedStorageWorklet
]
interface SharedStorageWorkletGlobalScope : WorkletGlobalScope {
[
ImplementedAs=Register,
RaisesException
] void register(DOMString name, NoArgumentConstructor operationCtor);
[CallWith=ScriptState, RaisesException]
readonly attribute SharedStorage sharedStorage;
[
CallWith=ScriptState,
RaisesException,
ContextEnabled=PrivateAggregationInSharedStorage
]
readonly attribute PrivateAggregation privateAggregation;
[
CallWith=ScriptState,
RaisesException
]
readonly attribute Crypto crypto;
};
callback RunFunctionForSharedStorageSelectURLOperation =
Promise<any>(sequence<DOMString> urls, optional any data);
callback RunFunctionForSharedStorageRunOperation =
Promise<any>(optional any data);