@cloudflare/workers-types 4.20240701.0 → 4.20240712.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/2021-11-03/index.d.ts +464 -468
- package/2021-11-03/index.ts +210 -193
- package/2022-01-31/index.d.ts +464 -468
- package/2022-01-31/index.ts +210 -193
- package/2022-03-21/index.d.ts +468 -474
- package/2022-03-21/index.ts +214 -199
- package/2022-08-04/index.d.ts +468 -474
- package/2022-08-04/index.ts +214 -199
- package/2022-10-31/index.d.ts +468 -474
- package/2022-10-31/index.ts +214 -199
- package/2022-11-30/index.d.ts +463 -469
- package/2022-11-30/index.ts +214 -199
- package/2023-03-01/index.d.ts +463 -469
- package/2023-03-01/index.ts +214 -199
- package/2023-07-01/index.d.ts +463 -469
- package/2023-07-01/index.ts +214 -199
- package/experimental/index.d.ts +470 -476
- package/experimental/index.ts +214 -199
- package/index.d.ts +464 -468
- package/index.ts +210 -193
- package/oldest/index.d.ts +464 -468
- package/oldest/index.ts +210 -193
- package/package.json +1 -1
package/2023-03-01/index.ts
CHANGED
|
@@ -286,16 +286,16 @@ export interface ServiceWorkerGlobalScope extends WorkerGlobalScope {
|
|
|
286
286
|
FixedLengthStream: typeof FixedLengthStream;
|
|
287
287
|
IdentityTransformStream: typeof IdentityTransformStream;
|
|
288
288
|
HTMLRewriter: typeof HTMLRewriter;
|
|
289
|
-
GPUAdapter: typeof
|
|
290
|
-
GPUOutOfMemoryError: typeof
|
|
291
|
-
GPUValidationError: typeof
|
|
292
|
-
GPUInternalError: typeof
|
|
293
|
-
GPUDeviceLostInfo: typeof
|
|
294
|
-
GPUBufferUsage: typeof
|
|
295
|
-
GPUShaderStage: typeof
|
|
296
|
-
GPUMapMode: typeof
|
|
297
|
-
GPUTextureUsage: typeof
|
|
298
|
-
GPUColorWrite: typeof
|
|
289
|
+
GPUAdapter: typeof GPUAdapter;
|
|
290
|
+
GPUOutOfMemoryError: typeof GPUOutOfMemoryError;
|
|
291
|
+
GPUValidationError: typeof GPUValidationError;
|
|
292
|
+
GPUInternalError: typeof GPUInternalError;
|
|
293
|
+
GPUDeviceLostInfo: typeof GPUDeviceLostInfo;
|
|
294
|
+
GPUBufferUsage: typeof GPUBufferUsage;
|
|
295
|
+
GPUShaderStage: typeof GPUShaderStage;
|
|
296
|
+
GPUMapMode: typeof GPUMapMode;
|
|
297
|
+
GPUTextureUsage: typeof GPUTextureUsage;
|
|
298
|
+
GPUColorWrite: typeof GPUColorWrite;
|
|
299
299
|
}
|
|
300
300
|
export declare function addEventListener<
|
|
301
301
|
Type extends keyof WorkerGlobalScopeEventMap,
|
|
@@ -442,7 +442,7 @@ export declare abstract class Navigator {
|
|
|
442
442
|
| FormData,
|
|
443
443
|
): boolean;
|
|
444
444
|
readonly userAgent: string;
|
|
445
|
-
readonly gpu:
|
|
445
|
+
readonly gpu: GPU;
|
|
446
446
|
}
|
|
447
447
|
/**
|
|
448
448
|
* Provides access to performance-related information for the current page. It's part of the High Resolution Time API, but is enhanced by the Performance Timeline API, the Navigation Timing API, the User Timing API, and the Resource Timing API.
|
|
@@ -2523,65 +2523,61 @@ export interface SocketInfo {
|
|
|
2523
2523
|
remoteAddress?: string;
|
|
2524
2524
|
localAddress?: string;
|
|
2525
2525
|
}
|
|
2526
|
-
export interface
|
|
2527
|
-
requestAdapter(
|
|
2528
|
-
param1?: gpuGPURequestAdapterOptions,
|
|
2529
|
-
): Promise<gpuGPUAdapter | null>;
|
|
2526
|
+
export interface GPU {
|
|
2527
|
+
requestAdapter(param1?: GPURequestAdapterOptions): Promise<GPUAdapter | null>;
|
|
2530
2528
|
}
|
|
2531
|
-
export declare abstract class
|
|
2532
|
-
requestDevice(param1?:
|
|
2533
|
-
requestAdapterInfo(unmaskHints?: string[]): Promise<
|
|
2534
|
-
get features():
|
|
2535
|
-
get limits():
|
|
2529
|
+
export declare abstract class GPUAdapter {
|
|
2530
|
+
requestDevice(param1?: GPUDeviceDescriptor): Promise<GPUDevice>;
|
|
2531
|
+
requestAdapterInfo(unmaskHints?: string[]): Promise<GPUAdapterInfo>;
|
|
2532
|
+
get features(): GPUSupportedFeatures;
|
|
2533
|
+
get limits(): GPUSupportedLimits;
|
|
2536
2534
|
}
|
|
2537
|
-
export interface
|
|
2538
|
-
createBuffer(param1:
|
|
2535
|
+
export interface GPUDevice extends EventTarget {
|
|
2536
|
+
createBuffer(param1: GPUBufferDescriptor): GPUBuffer;
|
|
2539
2537
|
createBindGroupLayout(
|
|
2540
|
-
descriptor:
|
|
2541
|
-
):
|
|
2542
|
-
createBindGroup(descriptor:
|
|
2543
|
-
createSampler(descriptor:
|
|
2544
|
-
createShaderModule(
|
|
2545
|
-
descriptor: gpuGPUShaderModuleDescriptor,
|
|
2546
|
-
): gpuGPUShaderModule;
|
|
2538
|
+
descriptor: GPUBindGroupLayoutDescriptor,
|
|
2539
|
+
): GPUBindGroupLayout;
|
|
2540
|
+
createBindGroup(descriptor: GPUBindGroupDescriptor): GPUBindGroup;
|
|
2541
|
+
createSampler(descriptor: GPUSamplerDescriptor): GPUSampler;
|
|
2542
|
+
createShaderModule(descriptor: GPUShaderModuleDescriptor): GPUShaderModule;
|
|
2547
2543
|
createPipelineLayout(
|
|
2548
|
-
descriptor:
|
|
2549
|
-
):
|
|
2544
|
+
descriptor: GPUPipelineLayoutDescriptor,
|
|
2545
|
+
): GPUPipelineLayout;
|
|
2550
2546
|
createComputePipeline(
|
|
2551
|
-
descriptor:
|
|
2552
|
-
):
|
|
2547
|
+
descriptor: GPUComputePipelineDescriptor,
|
|
2548
|
+
): GPUComputePipeline;
|
|
2553
2549
|
createRenderPipeline(
|
|
2554
|
-
descriptor:
|
|
2555
|
-
):
|
|
2550
|
+
descriptor: GPURenderPipelineDescriptor,
|
|
2551
|
+
): GPURenderPipeline;
|
|
2556
2552
|
createCommandEncoder(
|
|
2557
|
-
descriptor?:
|
|
2558
|
-
):
|
|
2559
|
-
createTexture(param1:
|
|
2553
|
+
descriptor?: GPUCommandEncoderDescriptor,
|
|
2554
|
+
): GPUCommandEncoder;
|
|
2555
|
+
createTexture(param1: GPUTextureDescriptor): GPUTexture;
|
|
2560
2556
|
destroy(): void;
|
|
2561
|
-
createQuerySet(descriptor:
|
|
2557
|
+
createQuerySet(descriptor: GPUQuerySetDescriptor): GPUQuerySet;
|
|
2562
2558
|
pushErrorScope(filter: string): void;
|
|
2563
|
-
popErrorScope(): Promise<
|
|
2564
|
-
get queue():
|
|
2565
|
-
get lost(): Promise<
|
|
2566
|
-
get features():
|
|
2567
|
-
get limits():
|
|
2559
|
+
popErrorScope(): Promise<GPUError | null>;
|
|
2560
|
+
get queue(): GPUQueue;
|
|
2561
|
+
get lost(): Promise<GPUDeviceLostInfo>;
|
|
2562
|
+
get features(): GPUSupportedFeatures;
|
|
2563
|
+
get limits(): GPUSupportedLimits;
|
|
2568
2564
|
}
|
|
2569
|
-
export interface
|
|
2565
|
+
export interface GPUDeviceDescriptor {
|
|
2570
2566
|
label?: string;
|
|
2571
2567
|
requiredFeatures?: string[];
|
|
2572
2568
|
requiredLimits?: Record<string, number | bigint>;
|
|
2573
|
-
defaultQueue?:
|
|
2569
|
+
defaultQueue?: GPUQueueDescriptor;
|
|
2574
2570
|
}
|
|
2575
|
-
export interface
|
|
2571
|
+
export interface GPUBufferDescriptor {
|
|
2576
2572
|
label: string;
|
|
2577
2573
|
size: number | bigint;
|
|
2578
2574
|
usage: number;
|
|
2579
2575
|
mappedAtCreation: boolean;
|
|
2580
2576
|
}
|
|
2581
|
-
export interface
|
|
2577
|
+
export interface GPUQueueDescriptor {
|
|
2582
2578
|
label?: string;
|
|
2583
2579
|
}
|
|
2584
|
-
export declare abstract class
|
|
2580
|
+
export declare abstract class GPUBufferUsage {
|
|
2585
2581
|
static readonly MAP_READ: number;
|
|
2586
2582
|
static readonly MAP_WRITE: number;
|
|
2587
2583
|
static readonly COPY_SRC: number;
|
|
@@ -2593,7 +2589,7 @@ export declare abstract class gpuGPUBufferUsage {
|
|
|
2593
2589
|
static readonly INDIRECT: number;
|
|
2594
2590
|
static readonly QUERY_RESOLVE: number;
|
|
2595
2591
|
}
|
|
2596
|
-
export interface
|
|
2592
|
+
export interface GPUBuffer {
|
|
2597
2593
|
getMappedRange(size?: number | bigint, param2?: number | bigint): ArrayBuffer;
|
|
2598
2594
|
unmap(): void;
|
|
2599
2595
|
destroy(): void;
|
|
@@ -2606,59 +2602,59 @@ export interface gpuGPUBuffer {
|
|
|
2606
2602
|
get usage(): number;
|
|
2607
2603
|
get mapState(): string;
|
|
2608
2604
|
}
|
|
2609
|
-
export declare abstract class
|
|
2605
|
+
export declare abstract class GPUShaderStage {
|
|
2610
2606
|
static readonly VERTEX: number;
|
|
2611
2607
|
static readonly FRAGMENT: number;
|
|
2612
2608
|
static readonly COMPUTE: number;
|
|
2613
2609
|
}
|
|
2614
|
-
export interface
|
|
2610
|
+
export interface GPUBindGroupLayoutDescriptor {
|
|
2615
2611
|
label?: string;
|
|
2616
|
-
entries:
|
|
2612
|
+
entries: GPUBindGroupLayoutEntry[];
|
|
2617
2613
|
}
|
|
2618
|
-
export interface
|
|
2614
|
+
export interface GPUBindGroupLayoutEntry {
|
|
2619
2615
|
binding: number;
|
|
2620
2616
|
visibility: number;
|
|
2621
|
-
buffer?:
|
|
2622
|
-
sampler?:
|
|
2623
|
-
texture?:
|
|
2624
|
-
storageTexture?:
|
|
2617
|
+
buffer?: GPUBufferBindingLayout;
|
|
2618
|
+
sampler?: GPUSamplerBindingLayout;
|
|
2619
|
+
texture?: GPUTextureBindingLayout;
|
|
2620
|
+
storageTexture?: GPUStorageTextureBindingLayout;
|
|
2625
2621
|
}
|
|
2626
|
-
export interface
|
|
2622
|
+
export interface GPUStorageTextureBindingLayout {
|
|
2627
2623
|
access?: string;
|
|
2628
2624
|
format: string;
|
|
2629
2625
|
viewDimension?: string;
|
|
2630
2626
|
}
|
|
2631
|
-
export interface
|
|
2627
|
+
export interface GPUTextureBindingLayout {
|
|
2632
2628
|
sampleType?: string;
|
|
2633
2629
|
viewDimension?: string;
|
|
2634
2630
|
multisampled?: boolean;
|
|
2635
2631
|
}
|
|
2636
|
-
export interface
|
|
2632
|
+
export interface GPUSamplerBindingLayout {
|
|
2637
2633
|
type?: string;
|
|
2638
2634
|
}
|
|
2639
|
-
export interface
|
|
2635
|
+
export interface GPUBufferBindingLayout {
|
|
2640
2636
|
type?: string;
|
|
2641
2637
|
hasDynamicOffset?: boolean;
|
|
2642
2638
|
minBindingSize?: number | bigint;
|
|
2643
2639
|
}
|
|
2644
|
-
export interface
|
|
2645
|
-
export interface
|
|
2646
|
-
export interface
|
|
2640
|
+
export interface GPUBindGroupLayout {}
|
|
2641
|
+
export interface GPUBindGroup {}
|
|
2642
|
+
export interface GPUBindGroupDescriptor {
|
|
2647
2643
|
label?: string;
|
|
2648
|
-
layout:
|
|
2649
|
-
entries:
|
|
2644
|
+
layout: GPUBindGroupLayout;
|
|
2645
|
+
entries: GPUBindGroupEntry[];
|
|
2650
2646
|
}
|
|
2651
|
-
export interface
|
|
2647
|
+
export interface GPUBindGroupEntry {
|
|
2652
2648
|
binding: number;
|
|
2653
|
-
resource:
|
|
2649
|
+
resource: GPUBufferBinding | GPUSampler;
|
|
2654
2650
|
}
|
|
2655
|
-
export interface
|
|
2656
|
-
buffer:
|
|
2651
|
+
export interface GPUBufferBinding {
|
|
2652
|
+
buffer: GPUBuffer;
|
|
2657
2653
|
offset?: number | bigint;
|
|
2658
2654
|
size?: number | bigint;
|
|
2659
2655
|
}
|
|
2660
|
-
export interface
|
|
2661
|
-
export interface
|
|
2656
|
+
export interface GPUSampler {}
|
|
2657
|
+
export interface GPUSamplerDescriptor {
|
|
2662
2658
|
label?: string;
|
|
2663
2659
|
addressModeU?: string;
|
|
2664
2660
|
addressModeV?: string;
|
|
@@ -2671,76 +2667,74 @@ export interface gpuGPUSamplerDescriptor {
|
|
|
2671
2667
|
compare: string;
|
|
2672
2668
|
maxAnisotropy?: number;
|
|
2673
2669
|
}
|
|
2674
|
-
export interface
|
|
2675
|
-
getCompilationInfo(): Promise<
|
|
2670
|
+
export interface GPUShaderModule {
|
|
2671
|
+
getCompilationInfo(): Promise<GPUCompilationInfo>;
|
|
2676
2672
|
}
|
|
2677
|
-
export interface
|
|
2673
|
+
export interface GPUShaderModuleDescriptor {
|
|
2678
2674
|
label?: string;
|
|
2679
2675
|
code: string;
|
|
2680
2676
|
}
|
|
2681
|
-
export interface
|
|
2682
|
-
export interface
|
|
2677
|
+
export interface GPUPipelineLayout {}
|
|
2678
|
+
export interface GPUPipelineLayoutDescriptor {
|
|
2683
2679
|
label?: string;
|
|
2684
|
-
bindGroupLayouts:
|
|
2680
|
+
bindGroupLayouts: GPUBindGroupLayout[];
|
|
2685
2681
|
}
|
|
2686
|
-
export interface
|
|
2687
|
-
getBindGroupLayout(index: number):
|
|
2682
|
+
export interface GPUComputePipeline {
|
|
2683
|
+
getBindGroupLayout(index: number): GPUBindGroupLayout;
|
|
2688
2684
|
}
|
|
2689
|
-
export interface
|
|
2685
|
+
export interface GPUComputePipelineDescriptor {
|
|
2690
2686
|
label?: string;
|
|
2691
|
-
compute:
|
|
2692
|
-
layout: string |
|
|
2687
|
+
compute: GPUProgrammableStage;
|
|
2688
|
+
layout: string | GPUPipelineLayout;
|
|
2693
2689
|
}
|
|
2694
|
-
export interface
|
|
2695
|
-
module:
|
|
2690
|
+
export interface GPUProgrammableStage {
|
|
2691
|
+
module: GPUShaderModule;
|
|
2696
2692
|
entryPoint: string;
|
|
2697
2693
|
constants?: Record<string, number>;
|
|
2698
2694
|
}
|
|
2699
|
-
export interface
|
|
2695
|
+
export interface GPUCommandEncoder {
|
|
2700
2696
|
get label(): string;
|
|
2701
2697
|
beginComputePass(
|
|
2702
|
-
descriptor?:
|
|
2703
|
-
):
|
|
2704
|
-
beginRenderPass(
|
|
2705
|
-
descriptor: gpuGPURenderPassDescriptor,
|
|
2706
|
-
): gpuGPURenderPassEncoder;
|
|
2698
|
+
descriptor?: GPUComputePassDescriptor,
|
|
2699
|
+
): GPUComputePassEncoder;
|
|
2700
|
+
beginRenderPass(descriptor: GPURenderPassDescriptor): GPURenderPassEncoder;
|
|
2707
2701
|
copyBufferToBuffer(
|
|
2708
|
-
source:
|
|
2702
|
+
source: GPUBuffer,
|
|
2709
2703
|
sourceOffset: number | bigint,
|
|
2710
|
-
destination:
|
|
2704
|
+
destination: GPUBuffer,
|
|
2711
2705
|
destinationOffset: number | bigint,
|
|
2712
2706
|
size: number | bigint,
|
|
2713
2707
|
): void;
|
|
2714
|
-
finish(param0?:
|
|
2708
|
+
finish(param0?: GPUCommandBufferDescriptor): GPUCommandBuffer;
|
|
2715
2709
|
copyTextureToBuffer(
|
|
2716
|
-
source:
|
|
2717
|
-
destination:
|
|
2718
|
-
copySize: Iterable<number> |
|
|
2710
|
+
source: GPUImageCopyTexture,
|
|
2711
|
+
destination: GPUImageCopyBuffer,
|
|
2712
|
+
copySize: Iterable<number> | GPUExtent3DDict,
|
|
2719
2713
|
): void;
|
|
2720
2714
|
copyBufferToTexture(
|
|
2721
|
-
source:
|
|
2722
|
-
destination:
|
|
2723
|
-
copySize: Iterable<number> |
|
|
2715
|
+
source: GPUImageCopyBuffer,
|
|
2716
|
+
destination: GPUImageCopyTexture,
|
|
2717
|
+
copySize: Iterable<number> | GPUExtent3DDict,
|
|
2724
2718
|
): void;
|
|
2725
2719
|
copyTextureToTexture(
|
|
2726
|
-
source:
|
|
2727
|
-
destination:
|
|
2728
|
-
copySize: Iterable<number> |
|
|
2720
|
+
source: GPUImageCopyTexture,
|
|
2721
|
+
destination: GPUImageCopyTexture,
|
|
2722
|
+
copySize: Iterable<number> | GPUExtent3DDict,
|
|
2729
2723
|
): void;
|
|
2730
2724
|
clearBuffer(
|
|
2731
|
-
buffer:
|
|
2725
|
+
buffer: GPUBuffer,
|
|
2732
2726
|
offset?: number | bigint,
|
|
2733
2727
|
size?: number | bigint,
|
|
2734
2728
|
): void;
|
|
2735
2729
|
}
|
|
2736
|
-
export interface
|
|
2730
|
+
export interface GPUCommandEncoderDescriptor {
|
|
2737
2731
|
label?: string;
|
|
2738
2732
|
}
|
|
2739
|
-
export interface
|
|
2740
|
-
setPipeline(pipeline:
|
|
2733
|
+
export interface GPUComputePassEncoder {
|
|
2734
|
+
setPipeline(pipeline: GPUComputePipeline): void;
|
|
2741
2735
|
setBindGroup(
|
|
2742
2736
|
index: number,
|
|
2743
|
-
bindGroup:
|
|
2737
|
+
bindGroup: GPUBindGroup | null,
|
|
2744
2738
|
dynamicOffsets?: Iterable<number>,
|
|
2745
2739
|
): void;
|
|
2746
2740
|
dispatchWorkgroups(
|
|
@@ -2750,52 +2744,52 @@ export interface gpuGPUComputePassEncoder {
|
|
|
2750
2744
|
): void;
|
|
2751
2745
|
end(): void;
|
|
2752
2746
|
}
|
|
2753
|
-
export interface
|
|
2747
|
+
export interface GPUComputePassDescriptor {
|
|
2754
2748
|
label?: string;
|
|
2755
|
-
timestampWrites?:
|
|
2749
|
+
timestampWrites?: GPUComputePassTimestampWrites;
|
|
2756
2750
|
}
|
|
2757
|
-
export interface
|
|
2758
|
-
export interface
|
|
2751
|
+
export interface GPUQuerySet {}
|
|
2752
|
+
export interface GPUQuerySetDescriptor {
|
|
2759
2753
|
label?: string;
|
|
2760
2754
|
}
|
|
2761
|
-
export interface
|
|
2762
|
-
querySet:
|
|
2755
|
+
export interface GPUComputePassTimestampWrites {
|
|
2756
|
+
querySet: GPUQuerySet;
|
|
2763
2757
|
beginningOfPassWriteIndex?: number;
|
|
2764
2758
|
endOfPassWriteIndex?: number;
|
|
2765
2759
|
}
|
|
2766
|
-
export interface
|
|
2760
|
+
export interface GPUCommandBufferDescriptor {
|
|
2767
2761
|
label?: string;
|
|
2768
2762
|
}
|
|
2769
|
-
export interface
|
|
2770
|
-
export interface
|
|
2771
|
-
submit(commandBuffers:
|
|
2763
|
+
export interface GPUCommandBuffer {}
|
|
2764
|
+
export interface GPUQueue {
|
|
2765
|
+
submit(commandBuffers: GPUCommandBuffer[]): void;
|
|
2772
2766
|
writeBuffer(
|
|
2773
|
-
buffer:
|
|
2767
|
+
buffer: GPUBuffer,
|
|
2774
2768
|
bufferOffset: number | bigint,
|
|
2775
2769
|
data: ArrayBuffer | ArrayBufferView,
|
|
2776
2770
|
dataOffset?: number | bigint,
|
|
2777
2771
|
size?: number | bigint,
|
|
2778
2772
|
): void;
|
|
2779
2773
|
}
|
|
2780
|
-
export declare abstract class
|
|
2774
|
+
export declare abstract class GPUMapMode {
|
|
2781
2775
|
static readonly READ: number;
|
|
2782
2776
|
static readonly WRITE: number;
|
|
2783
2777
|
}
|
|
2784
|
-
export interface
|
|
2778
|
+
export interface GPURequestAdapterOptions {
|
|
2785
2779
|
powerPreference: string;
|
|
2786
2780
|
forceFallbackAdapter?: boolean;
|
|
2787
2781
|
}
|
|
2788
|
-
export interface
|
|
2782
|
+
export interface GPUAdapterInfo {
|
|
2789
2783
|
get vendor(): string;
|
|
2790
2784
|
get architecture(): string;
|
|
2791
2785
|
get device(): string;
|
|
2792
2786
|
get description(): string;
|
|
2793
2787
|
}
|
|
2794
|
-
export interface
|
|
2788
|
+
export interface GPUSupportedFeatures {
|
|
2795
2789
|
has(name: string): boolean;
|
|
2796
2790
|
keys(): string[];
|
|
2797
2791
|
}
|
|
2798
|
-
export interface
|
|
2792
|
+
export interface GPUSupportedLimits {
|
|
2799
2793
|
get maxTextureDimension1D(): number;
|
|
2800
2794
|
get maxTextureDimension2D(): number;
|
|
2801
2795
|
get maxTextureDimension3D(): number;
|
|
@@ -2828,17 +2822,17 @@ export interface gpuGPUSupportedLimits {
|
|
|
2828
2822
|
get maxComputeWorkgroupSizeZ(): number;
|
|
2829
2823
|
get maxComputeWorkgroupsPerDimension(): number;
|
|
2830
2824
|
}
|
|
2831
|
-
export declare abstract class
|
|
2825
|
+
export declare abstract class GPUError {
|
|
2832
2826
|
get message(): string;
|
|
2833
2827
|
}
|
|
2834
|
-
export declare abstract class
|
|
2835
|
-
export declare abstract class
|
|
2836
|
-
export declare abstract class
|
|
2837
|
-
export declare abstract class
|
|
2828
|
+
export declare abstract class GPUOutOfMemoryError extends GPUError {}
|
|
2829
|
+
export declare abstract class GPUInternalError extends GPUError {}
|
|
2830
|
+
export declare abstract class GPUValidationError extends GPUError {}
|
|
2831
|
+
export declare abstract class GPUDeviceLostInfo {
|
|
2838
2832
|
get message(): string;
|
|
2839
2833
|
get reason(): string;
|
|
2840
2834
|
}
|
|
2841
|
-
export interface
|
|
2835
|
+
export interface GPUCompilationMessage {
|
|
2842
2836
|
get message(): string;
|
|
2843
2837
|
get type(): string;
|
|
2844
2838
|
get lineNum(): number;
|
|
@@ -2846,19 +2840,19 @@ export interface gpuGPUCompilationMessage {
|
|
|
2846
2840
|
get offset(): number;
|
|
2847
2841
|
get length(): number;
|
|
2848
2842
|
}
|
|
2849
|
-
export interface
|
|
2850
|
-
get messages():
|
|
2843
|
+
export interface GPUCompilationInfo {
|
|
2844
|
+
get messages(): GPUCompilationMessage[];
|
|
2851
2845
|
}
|
|
2852
|
-
export declare abstract class
|
|
2846
|
+
export declare abstract class GPUTextureUsage {
|
|
2853
2847
|
static readonly COPY_SRC: number;
|
|
2854
2848
|
static readonly COPY_DST: number;
|
|
2855
2849
|
static readonly TEXTURE_BINDING: number;
|
|
2856
2850
|
static readonly STORAGE_BINDING: number;
|
|
2857
2851
|
static readonly RENDER_ATTACHMENT: number;
|
|
2858
2852
|
}
|
|
2859
|
-
export interface
|
|
2853
|
+
export interface GPUTextureDescriptor {
|
|
2860
2854
|
label: string;
|
|
2861
|
-
size: number[] |
|
|
2855
|
+
size: number[] | GPUExtent3DDict;
|
|
2862
2856
|
mipLevelCount?: number;
|
|
2863
2857
|
sampleCount?: number;
|
|
2864
2858
|
dimension?: string;
|
|
@@ -2866,13 +2860,13 @@ export interface gpuGPUTextureDescriptor {
|
|
|
2866
2860
|
usage: number;
|
|
2867
2861
|
viewFormats?: string[];
|
|
2868
2862
|
}
|
|
2869
|
-
export interface
|
|
2863
|
+
export interface GPUExtent3DDict {
|
|
2870
2864
|
width: number;
|
|
2871
2865
|
height?: number;
|
|
2872
2866
|
depthOrArrayLayers?: number;
|
|
2873
2867
|
}
|
|
2874
|
-
export interface
|
|
2875
|
-
createView(descriptor?:
|
|
2868
|
+
export interface GPUTexture {
|
|
2869
|
+
createView(descriptor?: GPUTextureViewDescriptor): GPUTextureView;
|
|
2876
2870
|
destroy(): void;
|
|
2877
2871
|
get width(): number;
|
|
2878
2872
|
get height(): number;
|
|
@@ -2882,8 +2876,8 @@ export interface gpuGPUTexture {
|
|
|
2882
2876
|
get format(): string;
|
|
2883
2877
|
get usage(): number;
|
|
2884
2878
|
}
|
|
2885
|
-
export interface
|
|
2886
|
-
export interface
|
|
2879
|
+
export interface GPUTextureView {}
|
|
2880
|
+
export interface GPUTextureViewDescriptor {
|
|
2887
2881
|
label: string;
|
|
2888
2882
|
format: string;
|
|
2889
2883
|
dimension: string;
|
|
@@ -2893,91 +2887,91 @@ export interface gpuGPUTextureViewDescriptor {
|
|
|
2893
2887
|
baseArrayLayer?: number;
|
|
2894
2888
|
arrayLayerCount: number;
|
|
2895
2889
|
}
|
|
2896
|
-
export declare abstract class
|
|
2890
|
+
export declare abstract class GPUColorWrite {
|
|
2897
2891
|
static readonly RED: number;
|
|
2898
2892
|
static readonly GREEN: number;
|
|
2899
2893
|
static readonly BLUE: number;
|
|
2900
2894
|
static readonly ALPHA: number;
|
|
2901
2895
|
static readonly ALL: number;
|
|
2902
2896
|
}
|
|
2903
|
-
export interface
|
|
2904
|
-
export interface
|
|
2897
|
+
export interface GPURenderPipeline {}
|
|
2898
|
+
export interface GPURenderPipelineDescriptor {
|
|
2905
2899
|
label?: string;
|
|
2906
|
-
layout: string |
|
|
2907
|
-
vertex:
|
|
2908
|
-
primitive?:
|
|
2909
|
-
depthStencil?:
|
|
2910
|
-
multisample?:
|
|
2911
|
-
fragment?:
|
|
2912
|
-
}
|
|
2913
|
-
export interface
|
|
2914
|
-
module:
|
|
2900
|
+
layout: string | GPUPipelineLayout;
|
|
2901
|
+
vertex: GPUVertexState;
|
|
2902
|
+
primitive?: GPUPrimitiveState;
|
|
2903
|
+
depthStencil?: GPUDepthStencilState;
|
|
2904
|
+
multisample?: GPUMultisampleState;
|
|
2905
|
+
fragment?: GPUFragmentState;
|
|
2906
|
+
}
|
|
2907
|
+
export interface GPUVertexState {
|
|
2908
|
+
module: GPUShaderModule;
|
|
2915
2909
|
entryPoint: string;
|
|
2916
2910
|
constants?: Record<string, number>;
|
|
2917
|
-
buffers?:
|
|
2911
|
+
buffers?: GPUVertexBufferLayout[];
|
|
2918
2912
|
}
|
|
2919
|
-
export interface
|
|
2913
|
+
export interface GPUVertexBufferLayout {
|
|
2920
2914
|
arrayStride: number | bigint;
|
|
2921
2915
|
stepMode?: string;
|
|
2922
|
-
attributes:
|
|
2916
|
+
attributes: GPUVertexAttribute[];
|
|
2923
2917
|
}
|
|
2924
|
-
export interface
|
|
2918
|
+
export interface GPUVertexAttribute {
|
|
2925
2919
|
format: string;
|
|
2926
2920
|
offset: number | bigint;
|
|
2927
2921
|
shaderLocation: number;
|
|
2928
2922
|
}
|
|
2929
|
-
export interface
|
|
2923
|
+
export interface GPUPrimitiveState {
|
|
2930
2924
|
topology?: string;
|
|
2931
2925
|
stripIndexFormat?: string;
|
|
2932
2926
|
frontFace?: string;
|
|
2933
2927
|
cullMode?: string;
|
|
2934
2928
|
unclippedDepth?: boolean;
|
|
2935
2929
|
}
|
|
2936
|
-
export interface
|
|
2930
|
+
export interface GPUStencilFaceState {
|
|
2937
2931
|
compare?: string;
|
|
2938
2932
|
failOp?: string;
|
|
2939
2933
|
depthFailOp?: string;
|
|
2940
2934
|
passOp?: string;
|
|
2941
2935
|
}
|
|
2942
|
-
export interface
|
|
2936
|
+
export interface GPUDepthStencilState {
|
|
2943
2937
|
format: string;
|
|
2944
2938
|
depthWriteEnabled: boolean;
|
|
2945
2939
|
depthCompare: string;
|
|
2946
|
-
stencilFront?:
|
|
2947
|
-
stencilBack?:
|
|
2940
|
+
stencilFront?: GPUStencilFaceState;
|
|
2941
|
+
stencilBack?: GPUStencilFaceState;
|
|
2948
2942
|
stencilReadMask?: number;
|
|
2949
2943
|
stencilWriteMask?: number;
|
|
2950
2944
|
depthBias?: number;
|
|
2951
2945
|
depthBiasSlopeScale?: number;
|
|
2952
2946
|
depthBiasClamp?: number;
|
|
2953
2947
|
}
|
|
2954
|
-
export interface
|
|
2948
|
+
export interface GPUMultisampleState {
|
|
2955
2949
|
count?: number;
|
|
2956
2950
|
mask?: number;
|
|
2957
2951
|
alphaToCoverageEnabled?: boolean;
|
|
2958
2952
|
}
|
|
2959
|
-
export interface
|
|
2960
|
-
module:
|
|
2953
|
+
export interface GPUFragmentState {
|
|
2954
|
+
module: GPUShaderModule;
|
|
2961
2955
|
entryPoint: string;
|
|
2962
2956
|
constants?: Record<string, number>;
|
|
2963
|
-
targets:
|
|
2957
|
+
targets: GPUColorTargetState[];
|
|
2964
2958
|
}
|
|
2965
|
-
export interface
|
|
2959
|
+
export interface GPUColorTargetState {
|
|
2966
2960
|
format: string;
|
|
2967
|
-
blend:
|
|
2961
|
+
blend: GPUBlendState;
|
|
2968
2962
|
writeMask?: number;
|
|
2969
2963
|
}
|
|
2970
|
-
export interface
|
|
2971
|
-
color:
|
|
2972
|
-
alpha:
|
|
2964
|
+
export interface GPUBlendState {
|
|
2965
|
+
color: GPUBlendComponent;
|
|
2966
|
+
alpha: GPUBlendComponent;
|
|
2973
2967
|
}
|
|
2974
|
-
export interface
|
|
2968
|
+
export interface GPUBlendComponent {
|
|
2975
2969
|
operation?: string;
|
|
2976
2970
|
srcFactor?: string;
|
|
2977
2971
|
dstFactor?: string;
|
|
2978
2972
|
}
|
|
2979
|
-
export interface
|
|
2980
|
-
setPipeline(pipeline:
|
|
2973
|
+
export interface GPURenderPassEncoder {
|
|
2974
|
+
setPipeline(pipeline: GPURenderPipeline): void;
|
|
2981
2975
|
draw(
|
|
2982
2976
|
vertexCount: number,
|
|
2983
2977
|
instanceCount?: number,
|
|
@@ -2986,30 +2980,30 @@ export interface gpuGPURenderPassEncoder {
|
|
|
2986
2980
|
): void;
|
|
2987
2981
|
end(): void;
|
|
2988
2982
|
}
|
|
2989
|
-
export interface
|
|
2983
|
+
export interface GPURenderPassDescriptor {
|
|
2990
2984
|
label?: string;
|
|
2991
|
-
colorAttachments:
|
|
2992
|
-
depthStencilAttachment?:
|
|
2993
|
-
occlusionQuerySet?:
|
|
2994
|
-
timestampWrites?:
|
|
2985
|
+
colorAttachments: GPURenderPassColorAttachment[];
|
|
2986
|
+
depthStencilAttachment?: GPURenderPassDepthStencilAttachment;
|
|
2987
|
+
occlusionQuerySet?: GPUQuerySet;
|
|
2988
|
+
timestampWrites?: GPURenderPassTimestampWrites;
|
|
2995
2989
|
maxDrawCount?: number | bigint;
|
|
2996
2990
|
}
|
|
2997
|
-
export interface
|
|
2998
|
-
view:
|
|
2991
|
+
export interface GPURenderPassColorAttachment {
|
|
2992
|
+
view: GPUTextureView;
|
|
2999
2993
|
depthSlice?: number;
|
|
3000
|
-
resolveTarget?:
|
|
3001
|
-
clearValue?: number[] |
|
|
2994
|
+
resolveTarget?: GPUTextureView;
|
|
2995
|
+
clearValue?: number[] | GPUColorDict;
|
|
3002
2996
|
loadOp: string;
|
|
3003
2997
|
storeOp: string;
|
|
3004
2998
|
}
|
|
3005
|
-
export interface
|
|
2999
|
+
export interface GPUColorDict {
|
|
3006
3000
|
r: number;
|
|
3007
3001
|
g: number;
|
|
3008
3002
|
b: number;
|
|
3009
3003
|
a: number;
|
|
3010
3004
|
}
|
|
3011
|
-
export interface
|
|
3012
|
-
view:
|
|
3005
|
+
export interface GPURenderPassDepthStencilAttachment {
|
|
3006
|
+
view: GPUTextureView;
|
|
3013
3007
|
depthClearValue?: number;
|
|
3014
3008
|
depthLoadOp?: string;
|
|
3015
3009
|
depthStoreOp?: string;
|
|
@@ -3019,24 +3013,24 @@ export interface gpuGPURenderPassDepthStencilAttachment {
|
|
|
3019
3013
|
stencilStoreOp?: string;
|
|
3020
3014
|
stencilReadOnly?: boolean;
|
|
3021
3015
|
}
|
|
3022
|
-
export interface
|
|
3023
|
-
querySet:
|
|
3016
|
+
export interface GPURenderPassTimestampWrites {
|
|
3017
|
+
querySet: GPUQuerySet;
|
|
3024
3018
|
beginningOfPassWriteIndex?: number;
|
|
3025
3019
|
endOfPassWriteIndex?: number;
|
|
3026
3020
|
}
|
|
3027
|
-
export interface
|
|
3028
|
-
texture:
|
|
3021
|
+
export interface GPUImageCopyTexture {
|
|
3022
|
+
texture: GPUTexture;
|
|
3029
3023
|
mipLevel?: number;
|
|
3030
|
-
origin?: number[] |
|
|
3024
|
+
origin?: number[] | GPUOrigin3DDict;
|
|
3031
3025
|
aspect?: string;
|
|
3032
3026
|
}
|
|
3033
|
-
export interface
|
|
3034
|
-
buffer:
|
|
3027
|
+
export interface GPUImageCopyBuffer {
|
|
3028
|
+
buffer: GPUBuffer;
|
|
3035
3029
|
offset?: number | bigint;
|
|
3036
3030
|
bytesPerRow?: number;
|
|
3037
3031
|
rowsPerImage?: number;
|
|
3038
3032
|
}
|
|
3039
|
-
export interface
|
|
3033
|
+
export interface GPUOrigin3DDict {
|
|
3040
3034
|
x?: number;
|
|
3041
3035
|
y?: number;
|
|
3042
3036
|
z?: number;
|
|
@@ -4082,7 +4076,7 @@ export interface IncomingRequestCfPropertiesTLSClientAuthPlaceholder {
|
|
|
4082
4076
|
certNotAfter: "";
|
|
4083
4077
|
}
|
|
4084
4078
|
/** Possible outcomes of TLS verification */
|
|
4085
|
-
export type CertVerificationStatus =
|
|
4079
|
+
export declare type CertVerificationStatus =
|
|
4086
4080
|
/** Authentication succeeded */
|
|
4087
4081
|
| "SUCCESS"
|
|
4088
4082
|
/** No certificate was presented */
|
|
@@ -4100,7 +4094,7 @@ export type CertVerificationStatus =
|
|
|
4100
4094
|
/**
|
|
4101
4095
|
* An upstream endpoint's response to a TCP `keepalive` message from Cloudflare.
|
|
4102
4096
|
*/
|
|
4103
|
-
export type IncomingRequestCfPropertiesEdgeRequestKeepAliveStatus =
|
|
4097
|
+
export declare type IncomingRequestCfPropertiesEdgeRequestKeepAliveStatus =
|
|
4104
4098
|
| 0 /** Unknown */
|
|
4105
4099
|
| 1 /** no keepalives (not found) */
|
|
4106
4100
|
| 2 /** no connection re-use, opening keepalive connection failed */
|
|
@@ -4108,7 +4102,7 @@ export type IncomingRequestCfPropertiesEdgeRequestKeepAliveStatus =
|
|
|
4108
4102
|
| 4 /** connection re-use, refused by the origin server (`TCP FIN`) */
|
|
4109
4103
|
| 5; /** connection re-use, accepted by the origin server */
|
|
4110
4104
|
/** ISO 3166-1 Alpha-2 codes */
|
|
4111
|
-
export type Iso3166Alpha2Code =
|
|
4105
|
+
export declare type Iso3166Alpha2Code =
|
|
4112
4106
|
| "AD"
|
|
4113
4107
|
| "AE"
|
|
4114
4108
|
| "AF"
|
|
@@ -4359,7 +4353,14 @@ export type Iso3166Alpha2Code =
|
|
|
4359
4353
|
| "ZM"
|
|
4360
4354
|
| "ZW";
|
|
4361
4355
|
/** The 2-letter continent codes Cloudflare uses */
|
|
4362
|
-
export type ContinentCode =
|
|
4356
|
+
export declare type ContinentCode =
|
|
4357
|
+
| "AF"
|
|
4358
|
+
| "AN"
|
|
4359
|
+
| "AS"
|
|
4360
|
+
| "EU"
|
|
4361
|
+
| "NA"
|
|
4362
|
+
| "OC"
|
|
4363
|
+
| "SA";
|
|
4363
4364
|
export type CfProperties<HostMetadata = unknown> =
|
|
4364
4365
|
| IncomingRequestCfProperties<HostMetadata>
|
|
4365
4366
|
| RequestInitCfProperties;
|
|
@@ -4460,7 +4461,7 @@ export interface SendEmail {
|
|
|
4460
4461
|
export declare abstract class EmailEvent extends ExtendableEvent {
|
|
4461
4462
|
readonly message: ForwardableEmailMessage;
|
|
4462
4463
|
}
|
|
4463
|
-
export type EmailExportedHandler<Env = unknown> = (
|
|
4464
|
+
export declare type EmailExportedHandler<Env = unknown> = (
|
|
4464
4465
|
message: ForwardableEmailMessage,
|
|
4465
4466
|
env: Env,
|
|
4466
4467
|
ctx: ExecutionContext,
|
|
@@ -4589,6 +4590,20 @@ export interface JsonWebKeyWithKid extends JsonWebKey {
|
|
|
4589
4590
|
// Key Identifier of the JWK
|
|
4590
4591
|
readonly kid: string;
|
|
4591
4592
|
}
|
|
4593
|
+
export interface RateLimitOptions {
|
|
4594
|
+
key: string;
|
|
4595
|
+
}
|
|
4596
|
+
export interface RateLimitOutcome {
|
|
4597
|
+
success: boolean;
|
|
4598
|
+
}
|
|
4599
|
+
export interface RateLimit {
|
|
4600
|
+
/**
|
|
4601
|
+
* Rate limit a request based on the provided options.
|
|
4602
|
+
* @see https://developers.cloudflare.com/workers/runtime-apis/bindings/rate-limit/
|
|
4603
|
+
* @returns A promise that resolves with the outcome of the rate limit.
|
|
4604
|
+
*/
|
|
4605
|
+
limit(options: RateLimitOptions): Promise<RateLimitOutcome>;
|
|
4606
|
+
}
|
|
4592
4607
|
// Namespace for RPC utility types. Unfortunately, we can't use a `module` here as these types need
|
|
4593
4608
|
// to referenced by `Fetcher`. This is included in the "importable" version of the types which
|
|
4594
4609
|
// strips all `module` blocks.
|