blob: 1c0703c89d244087a7dee50322e34aae8a9621ac [file] [log] [blame]
// Copyright 2019 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
// https://github.com/rknoll/content-index
[
Exposed=(Window,Worker),
RuntimeEnabled=ContentIndex
] interface ContentIndex {
[CallWith=ScriptState, RaisesException, MeasureAs=ContentIndexAdd] Promise<undefined> add(ContentDescription description);
[CallWith=ScriptState, RaisesException, MeasureAs=ContentIndexDelete, ImplementedAs=deleteDescription] Promise<undefined> delete(DOMString id);
[CallWith=ScriptState, RaisesException, MeasureAs=ContentIndexGet, ImplementedAs=getDescriptions] Promise<sequence<ContentDescription>> getAll();
};