MongoDB C#2.0驱动程序设置序列化选项

MongoDB C#2.0驱动程序设置序列化选项,c#,mongodb,C#,Mongodb,我已将C#MongoDB驱动程序更新为2.0 现在SetSerializationOptions不起作用。下面是旧代码 cm.GetMemberMap(m => m.ArrayField) .SetSerializationOptions( new ArraySerializationOptions( new RepresentationSerializationOptions(BsonType.ObjectId))); 请

我已将C#MongoDB驱动程序更新为2.0

现在
SetSerializationOptions
不起作用。下面是旧代码

cm.GetMemberMap(m => m.ArrayField)
      .SetSerializationOptions(
          new ArraySerializationOptions(
                new RepresentationSerializationOptions(BsonType.ObjectId)));

请帮助我替换2.0驱动程序中的上述代码?

新文档介绍了以下内容:

您需要设置一个新的序列化程序,并根据您的场景进行适当配置

克雷格