Uploaded image for project: 'C# Driver'
  1. C# Driver
  2. CSHARP-587

Overwrite serializers in BsonSerializer

    • Type: Icon: Improvement Improvement
    • Resolution: Done
    • Priority: Icon: Minor - P4 Minor - P4
    • None
    • Affects Version/s: None
    • Component/s: None
    • Labels:
      None

      It would be nice if there was a way to override default serializers for primitive types. While it can be worked around by registering serializers before the sctor of BsonSerializer executes or by using Reflection, a more straight-forward way would probably be to include a version of BsonSerializer.RegisterSerializer that allows to overwrite serializers for already covered types.

      This stackoverflow question might be able to provide more context (note, I am not the original poster of said question): http://stackoverflow.com/questions/12201812/mongodb-override-default-serializer-for-a-c-sharp-primitive-type/12636123#comment17048789_12636123

            Assignee:
            Unassigned Unassigned
            Reporter:
            manny Manuel Warum
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: