ExpiryPolicy class Null safety

Defines functions to determine when cache entries will expire based on creation, access and modification operations.

Each of the functions return a new Duration that specifies the amount of time that must pass before a cache entry is considered expired.

Implementers

Constructors

ExpiryPolicy()
Builds a ExpiryPolicy
const

Properties

hashCode int
The hash code for this object. [...]
read-only, inherited
runtimeType Type
A representation of the runtime type of the object.
read-only, inherited

Methods

getExpiryForAccess() Duration?
Gets the Duration before an accessed CacheEntry is considered expired. [...]
getExpiryForCreation() Duration
Gets the Duration before a newly created CacheEntry is considered expired. [...]
getExpiryForUpdate() Duration?
Gets the Duration before an updated CacheEntry is considered expired. [...]
noSuchMethod(Invocation invocation) → dynamic
Invoked when a non-existent 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

eternal → const Duration
The value used to represent a eternal duration (not eternal but close enough)
Duration(days: 9999999)