LibWeb: Add IDBObjectStore

This commit is contained in:
stelar7 2024-11-07 18:56:26 +01:00 committed by Jelle Raaijmakers
commit 16ce2b975a
Notes: github-actions[bot] 2024-11-26 13:52:57 +00:00
8 changed files with 99 additions and 0 deletions

View file

@ -0,0 +1,28 @@
/*
* Copyright (c) 2024, stelar7 <dudedbz@gmail.com>
*
* SPDX-License-Identifier: BSD-2-Clause
*/
#pragma once
#include <LibGC/Heap.h>
#include <LibWeb/Bindings/PlatformObject.h>
namespace Web::IndexedDB {
// https://w3c.github.io/IndexedDB/#object-store-interface
class IDBObjectStore : public Bindings::PlatformObject {
WEB_PLATFORM_OBJECT(IDBObjectStore, Bindings::PlatformObject);
GC_DECLARE_ALLOCATOR(IDBObjectStore);
public:
virtual ~IDBObjectStore() override;
[[nodiscard]] static GC::Ref<IDBObjectStore> create(JS::Realm&);
protected:
explicit IDBObjectStore(JS::Realm&);
virtual void initialize(JS::Realm&) override;
};
}