Table of Contents

Class MemorySerializerBase<TItem, TMemory>

Namespace
MongoDB.Bson.Serialization.Serializers
Assembly
MongoDB.Bson.dll

Represents an abstract base class for Memory<T> and ReadOnlyMemory<T> serializers.

public abstract class MemorySerializerBase<TItem, TMemory> : StructSerializerBase<TMemory>, IBsonSerializer<TMemory>, IBsonSerializer, IRepresentationConfigurable<MemorySerializerBase<TItem, TMemory>>, IRepresentationConfigurable, IHasRepresentationSerializer where TMemory : struct

Type Parameters

TItem

The type of the item. Only primitive numeric types are supported.

TMemory

The type of the memory struct.

Inheritance
MemorySerializerBase<TItem, TMemory>
Implements
Derived
Inherited Members
Extension Methods

Constructors

MemorySerializerBase()

Initializes a new instance of the MemorySerializerBase<TItem, TMemory> class.

MemorySerializerBase(BsonType)

Initializes a new instance of the MemorySerializerBase<TItem, TMemory> class.

Properties

Representation

Gets the representation.

Methods

CreateMemory(TItem[])

Creates the Memory{TITem} structure.

Deserialize(BsonDeserializationContext, BsonDeserializationArgs)

Deserializes a value.

Equals(object)
GetHashCode()
GetMemory(TMemory)

Get the memory structure from TMemory instance.

Serialize(BsonSerializationContext, BsonSerializationArgs, TMemory)

Serializes a value.

WithRepresentation(BsonType)

Returns a serializer that has been reconfigured with the specified representation.