RequestCredentials enum

The credentials read-only property of the Request interface indicates whether the user agent should send or receive cookies from the other domain in the case of cross-origin requests.

MDN reference

Inheritance

Constructors

RequestCredentials(String value)
const

Values

omit → const RequestCredentials

Never send or receive cookies.

const RequestCredentials('omit')
sameOrigin → const RequestCredentials

Send user credentials (cookies, basic http auth, etc..) if the URL is on the same origin as the calling script.

This is the default value.

const RequestCredentials('same-origin')
include → const RequestCredentials

Always send user credentials (cookies, basic http auth, etc..), even for cross-origin calls.

const RequestCredentials('include')

Properties

hashCode int
The hash code for this object.
no setterinherited
index int
A numeric identifier for the enumerated value.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
value String
final

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited

Constants

values → const List<RequestCredentials>
A constant List of the values in this enum, in order of their declaration.