CacheDataSerializer<T> class

Serializer definition for a single cache data type.

Constructors

CacheDataSerializer({required CacheDataEncoder<T> encode, required CacheDataDecoder<T> decode, String? typeKey, bool canHandle(Object? value)?})
Creates a serializer with encode/decode handlers.

Properties

decode CacheDataDecoder<T>
Function that deserializes stored payloads.
final
encode CacheDataEncoder<T>
Function that serializes typed values.
final
hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
type Type
Runtime type handled by this serializer.
final
typeKey String
Stable type identifier used during persistence.
final

Methods

matches(Object? value) bool
Returns whether this serializer can handle value.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

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