Request constructor
Request(
- Resource resource, {
- String? method,
- Headers? headers,
- Object? body,
- String? referrer,
- ReferrerPolicy? referrerPolicy,
- RequestMode? mode,
- RequestCredentials? credentials,
- RequestCache? cache,
- RequestRedirect? redirect,
- String? integrity,
- bool? keepalive,
- AbortSignal? signal,
Implementation
Request(
Resource resource, {
String? method,
Headers? headers,
Object? body,
String? referrer,
interop.ReferrerPolicy? referrerPolicy,
interop.RequestMode? mode,
interop.RequestCredentials? credentials,
interop.RequestCache? cache,
interop.RequestRedirect? redirect,
String? integrity,
bool? keepalive,
AbortSignal? signal,
}) : _delegate = interop.Request(
interop.requestFromResource(resource),
interop.RequestInit(
method: method,
headers: headers?.delegate,
// TODO(lesnitsky): support streams
body: body,
referrer: referrer,
referrerPolicy: referrerPolicy,
mode: mode,
credentials: credentials,
cache: cache,
redirect: redirect,
integrity: integrity,
keepalive: keepalive,
signal: signal?.delegate,
),
);