Uploaded image for project: 'Java Driver'
  1. Java Driver
  2. JAVA-2769

Ignore idProperty for embedded classes

    XMLWordPrintableJSON

Details

    • Icon: Improvement Improvement
    • Resolution: Won't Fix
    • Icon: Major - P3 Major - P3
    • None
    • None
    • POJO
    • None

    Description

      class Node {
        id: long
        left: Node
        right: Node
      }
      

      The id field will be converted to _id by annotations.
      Consider ignoring the idProperty when encoding/decoding the embedded Nodes.

      Relies on the context of the encoding / decoding to be known and handled by the PojoCodec.
      It requires, some mechanisim to opt-into, so to prevent it being a breaking change.

      Attachments

        Activity

          People

            ross@mongodb.com Ross Lawley
            ross@mongodb.com Ross Lawley
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: