CacheEntry class Null safety

The wrapper around the object that is added to the cache

Inheritance

Constructors

CacheEntry(String key, dynamic value, DateTime expiryTime, DateTime creationTime, {DateTime? accessTime, DateTime? updateTime, int? hitCount})

Properties

accessTime DateTime
Cache access time
read / write, inherited
creationTime DateTime
Cache creation time
read / write, inherited
expiryTime DateTime
Cache expiration time
read / write, inherited
hashCode int
The hash code for this object. [...]
read-only, inherited
hitCount int
Cache hitcount
read / write, inherited
key String
The cache key
final, inherited
props List<Object?>
The list of properties that will be used to determine whether two instances are equal.
read-only, override
runtimeType Type
A representation of the runtime type of the object.
read-only, inherited
stat CacheStat
Returns a CacheStat from this CacheEntry
read / write
stringify bool?
If set to true, the toString method will be overridden to output this instance's props. [...]
read-only, inherited
updateTime DateTime
Cache update time
read / write, inherited
value → dynamic
Returns the stored value
read-only
valueChanged bool
Returns true if the value was changed after retrieval from the store or if it was newly created
read-only

Methods

copyForUpdate(dynamic value, {String? key, DateTime? expiryTime, DateTime? creationTime, DateTime? accessTime, DateTime? updateTime, int? hitCount}) CacheEntry
Copies a CacheEntry [...]
isExpired([DateTime? now]) bool
Checks if the cache entry is expired [...]
inherited
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