Skip to content

Are nested dictionaries in MongoDocument supported? #28

@BeayemX

Description

@BeayemX

I have this weird problem that nested dictionaries don't have their values set. But nested Lists do work.

If I listen to the DidChangeRecord event and build the dictionary myself, casting the changedFields to <string, object> dictionaries and then casting the object to the desired class, everything works fine.

But the values in the collection are not correct. The length of the dictionary is always 0.

The structure looks like this:

class MyDocType : MongoDocument {
   public class List<MemberClass>
}

class MemberClass {
    Dictionary<string, SubClass> // this is always empty
}

Is this a known problem/limitation or should this be supported and I am doing something wrong?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions