Serenity Operating System
at master 38 lines 1.6 kB view raw
1#import <Fetch/Request.idl> 2#import <Fetch/Response.idl> 3#import <HTML/MessagePort.idl> 4 5// FIXME: Support VoidFunction in the IDL parser 6callback VoidFunction = undefined (); 7 8// https://html.spec.whatwg.org/multipage/webappapis.html#windoworworkerglobalscope 9interface mixin WindowOrWorkerGlobalScope { 10 [Replaceable] readonly attribute USVString origin; 11 readonly attribute boolean isSecureContext; 12 readonly attribute boolean crossOriginIsolated; 13 14 // FIXME: undefined reportError(any e); 15 16 // base64 utility methods 17 DOMString btoa(DOMString data); 18 ByteString atob(DOMString data); 19 20 // timers 21 // FIXME: long setTimeout(TimerHandler handler, optional long timeout = 0, any... arguments); 22 // FIXME: undefined clearTimeout(optional long id = 0); 23 // FIXME: long setInterval(TimerHandler handler, optional long timeout = 0, any... arguments); 24 // FIXME: undefined clearInterval(optional long id = 0); 25 26 // microtask queuing 27 undefined queueMicrotask(VoidFunction callback); 28 29 // ImageBitmap 30 // FIXME: Promise<ImageBitmap> createImageBitmap(ImageBitmapSource image, optional ImageBitmapOptions options = {}); 31 // FIXME: Promise<ImageBitmap> createImageBitmap(ImageBitmapSource image, long sx, long sy, long sw, long sh, optional ImageBitmapOptions options = {}); 32 33 // structured cloning 34 any structuredClone(any value, optional StructuredSerializeOptions options = {}); 35 36 // https://fetch.spec.whatwg.org/#fetch-method 37 [NewObject] Promise<Response> fetch(RequestInfo input, optional RequestInit init = {}); 38};