Table of Contents

Interface IDistributedCacheSerializer

Namespace
Arbiter.CommandQuery.Definitions
Assembly
Arbiter.CommandQuery.dll

An interface defining serialization and deserialization support for IDistributedCache

public interface IDistributedCacheSerializer

Methods

FromByteArrayAsync<T>(byte[])

Deserializes an instance of T from the provided byteArray.

Task<T> FromByteArrayAsync<T>(byte[] byteArray)

Parameters

byteArray byte[]

The byte array to deserialize.

Returns

Task<T>

An instance of T deserialzied

Type Parameters

T

The type to deserialize

ToByteArrayAsync<T>(T)

Serializes instance to a byte array

Task<byte[]> ToByteArrayAsync<T>(T instance)

Parameters

instance T

The instance to serialize.

Returns

Task<byte[]>

The instance serialized to a byte array

Type Parameters

T

The type to serialize

See Also