Table of Contents

Struct BsonSerializationArgs

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

Represents args common to all serializers.

public struct BsonSerializationArgs
Inherited Members
Extension Methods

Constructors

BsonSerializationArgs(Type, bool, bool)

Initializes a new instance of the BsonSerializationArgs struct.

public BsonSerializationArgs(Type nominalType, bool serializeAsNominalType, bool serializeIdFirst)

Parameters

nominalType Type

The nominal type.

serializeAsNominalType bool

Whether to serialize as the nominal type.

serializeIdFirst bool

Whether to serialize the id first.

Properties

NominalType

Gets or sets the nominal type.

public Type NominalType { get; set; }

Property Value

Type

The nominal type.

SerializeAsNominalType

Gets or sets a value indicating whether to serialize the value as if it were an instance of the nominal type.

public bool SerializeAsNominalType { get; set; }

Property Value

bool

SerializeIdFirst

Gets or sets a value indicating whether to serialize the id first.

public bool SerializeIdFirst { get; set; }

Property Value

bool