CacheEntry class

Represents a cached entry

Constructors

CacheEntry.new({required String content, required DateTime cachedAt, required DateTime expiresAt, required String url})
const
CacheEntry.fromJson(Map<String, dynamic> json)
Create from JSON
factory

Properties

cachedAt DateTime
When the content was cached
final
content String
The cached content
final
expiresAt DateTime
When the cache expires
final
hashCode int
The hash code for this object.
no setterinherited
isExpired bool
Check if the cache entry has expired
no setter
isValid bool
Check if the cache entry is still valid
no setter
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
url String
The URL that was cached
final

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toJson() Map<String, dynamic>
Convert to JSON for persistence
toString() String
A string representation of this object.
inherited

Operators

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