mirror of
https://github.com/SerenityOS/serenity.git
synced 2025-01-23 18:02:05 -05:00
LibWeb: Add IDL definition for Web::Streams::QueuingStrategy
This commit is contained in:
parent
9df2d6ee0f
commit
42c102ecb6
3 changed files with 29 additions and 0 deletions
|
@ -550,6 +550,7 @@ class WritableStreamDefaultController;
|
||||||
class WritableStreamDefaultWriter;
|
class WritableStreamDefaultWriter;
|
||||||
|
|
||||||
struct PullIntoDescriptor;
|
struct PullIntoDescriptor;
|
||||||
|
struct QueuingStrategy;
|
||||||
struct QueuingStrategyInit;
|
struct QueuingStrategyInit;
|
||||||
struct UnderlyingSink;
|
struct UnderlyingSink;
|
||||||
struct UnderlyingSource;
|
struct UnderlyingSource;
|
||||||
|
|
21
Userland/Libraries/LibWeb/Streams/QueuingStrategy.h
Normal file
21
Userland/Libraries/LibWeb/Streams/QueuingStrategy.h
Normal file
|
@ -0,0 +1,21 @@
|
||||||
|
/*
|
||||||
|
* Copyright (c) 2023, Shannon Booth <shannon.ml.booth@gmail.com>
|
||||||
|
*
|
||||||
|
* SPDX-License-Identifier: BSD-2-Clause
|
||||||
|
*/
|
||||||
|
|
||||||
|
#pragma once
|
||||||
|
|
||||||
|
#include <AK/Optional.h>
|
||||||
|
#include <LibJS/Heap/GCPtr.h>
|
||||||
|
#include <LibWeb/WebIDL/CallbackType.h>
|
||||||
|
|
||||||
|
namespace Web::Streams {
|
||||||
|
|
||||||
|
// https://streams.spec.whatwg.org/#dictdef-queuingstrategy
|
||||||
|
struct QueuingStrategy {
|
||||||
|
Optional<double> high_water_mark;
|
||||||
|
JS::GCPtr<WebIDL::CallbackType> size;
|
||||||
|
};
|
||||||
|
|
||||||
|
}
|
7
Userland/Libraries/LibWeb/Streams/QueuingStrategy.idl
Normal file
7
Userland/Libraries/LibWeb/Streams/QueuingStrategy.idl
Normal file
|
@ -0,0 +1,7 @@
|
||||||
|
callback QueuingStrategySize = unrestricted double (any chunk);
|
||||||
|
|
||||||
|
// https://streams.spec.whatwg.org/#dictdef-queuingstrategy
|
||||||
|
dictionary QueuingStrategy {
|
||||||
|
unrestricted double highWaterMark;
|
||||||
|
QueuingStrategySize size;
|
||||||
|
};
|
Loading…
Add table
Reference in a new issue