草庐IT

BsonExtraElements

全部标签

c# - 如何通过Linq查询MongoDB中的BsonExtraElements

我使用mongodb[BsonExtraElements]功能来扩展我的类一些动态数据,但不幸的是我无法通过mongodbC#驱动程序创建查询。这是我的模型类:publicclassMongoProductEntity{publicMongoProductEntity(){AdditionalColumns=newBsonDocument{AllowDuplicateNames=false};}[BsonExtraElements]publicBsonDocumentAdditionalColumns{get;set;}publicstringBrandName{get;set;}}这