ResponseCache class abstract

A key-value cache for ChatResponses used during evaluation.

Implementers
Annotations
  • @Source(name: 'IDistributedCache.cs', namespace: 'Microsoft.Extensions.Caching.Distributed', repository: 'dotnet/runtime', path: 'src/libraries/Microsoft.Extensions.Caching.Abstractions/')

Constructors

ResponseCache()

Properties

hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

deleteExpiredEntries() Future<void>
Removes all expired entries from the cache.
get(String key) Future<ChatResponse?>
Returns the cached ChatResponse for key, or null if not found or expired.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
remove(String key) Future<void>
Removes the entry for key from the cache.
reset() Future<void>
Clears all entries from the cache.
set(String key, ChatResponse response) Future<void>
Stores response in the cache under key.
toString() String
A string representation of this object.
inherited

Operators

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