Struct RandomAccessCache.ReadOnlyMemoryKey
Represents ReadOnlyMemory<T> of byte as a key for RandomAccessCache<TValue>.
Inherited Members
Namespace: DotNext.Runtime.Caching
Assembly: DotNext.Threading.dll
Syntax
public readonly struct RandomAccessCache.ReadOnlyMemoryKey : ISupplier<ReadOnlySpan<byte>>, IFunctional
Constructors
View SourceReadOnlyMemoryKey(in ReadOnlyMemory<byte>)
Represents ReadOnlyMemory<T> of byte as a key for RandomAccessCache<TValue>.
Declaration
public ReadOnlyMemoryKey(in ReadOnlyMemory<byte> key)
Parameters
| Type | Name | Description |
|---|---|---|
| ReadOnlyMemory<byte> | key | The key. |
Operators
View Sourceimplicit operator ReadOnlySpan<byte>(ReadOnlyMemoryKey)
Converts key to ReadOnlySpan<T> over byte.
Declaration
public static implicit operator ReadOnlySpan<byte>(RandomAccessCache.ReadOnlyMemoryKey key)
Parameters
| Type | Name | Description |
|---|---|---|
| RandomAccessCache.ReadOnlyMemoryKey | key | The key to convert. |
Returns
| Type | Description |
|---|---|
| ReadOnlySpan<byte> | ReadOnlySpan<T> over byte which represents the key. |