Class NullableSerializer

| MongoDB CSharp Driver API Reference (original) (raw)

Namespace

MongoDB.Bson.Serialization.Serializers

Assembly

MongoDB.Bson.dll

Represents a serializer for nullable values.

public sealed class NullableSerializer<T> : SerializerBase<T?>, IBsonSerializer<T?>, IBsonSerializer, IChildSerializerConfigurable, INullableSerializer where T : struct

Type Parameters

T

The underlying type.

Inheritance

NullableSerializer

Implements

Inherited Members

Extension Methods

Constructors

NullableSerializer()

Initializes a new instance of the NullableSerializer class.

NullableSerializer(IBsonSerializerRegistry)

Initializes a new instance of the NullableSerializer class.

NullableSerializer(IBsonSerializer)

Initializes a new instance of the NullableSerializer class.

Properties

ValueSerializer

Gets the value serializer.

Methods

Deserialize(BsonDeserializationContext, BsonDeserializationArgs)

Deserializes a value.

Equals(object)

Determines whether the specified object is equal to the current object.

GetHashCode()

Serves as the default hash function.

Serialize(BsonSerializationContext, BsonSerializationArgs, T?)

Serializes a value.

WithSerializer(IBsonSerializer)

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