WebConfigRequestCache enum

Controls how requests will interact with the browser's HTTP cache.

Inheritance
Available extensions

Values

byDefault → const WebConfigRequestCache

The browser looks for a matching request in its HTTP cache.

  • If there is a match and it is fresh, it will be returned from the cache.
  • If there is a match but it is stale, the browser will make a conditional request to the remote server. If the server indicates that the resource has not changed, it will be returned from the cache. Otherwise the resource will be downloaded from the server and the cache will be updated.
  • If there is no match, the browser will make a normal request, and will update the cache with the downloaded resource.
noStore → const WebConfigRequestCache

The browser fetches the resource from the remote server without first looking in the cache, and will not update the cache with the downloaded resource.

reload → const WebConfigRequestCache

The browser fetches the resource from the remote server without first looking in the cache, but then will update the cache with the downloaded resource.

noCache → const WebConfigRequestCache

The browser looks for a matching request in its HTTP cache.

  • If there is a match, fresh or stale, the browser will make a conditional request to the remote server. If the server indicates that the resource has not changed, it will be returned from the cache. Otherwise the resource will be downloaded from the server and the cache will be updated.
  • If there is no match, the browser will make a normal request, and will update the cache with the downloaded resource.
forceCache → const WebConfigRequestCache

The browser looks for a matching request in its HTTP cache.

  • If there is a match, fresh or stale, it will be returned from the cache.
  • If there is no match, the browser will make a normal request, and will update the cache with the downloaded resource.
onlyIfCached → const WebConfigRequestCache

The browser looks for a matching request in its HTTP cache.

  • If there is a match, fresh or stale, it will be returned from the cache.
  • If there is no match, the browser will respond with a 504 Gateway timeout status.

The onlyIfCached mode can only be used if the request's mode is WebConfigRequestMode.sameOrigin.

Properties

hashCode int
The hash code for this object.
no setterinherited
index int
A numeric identifier for the enumerated value.
no setterinherited
name String

Available on Enum, provided by the EnumName extension

The name of the enum value.
no setter
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

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

Operators

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

Constants

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