Add Iterator types for bsoncore.Document and bsoncore.Array

XMLWordPrintableJSON

    • Type: Improvement
    • Resolution: Unresolved
    • Priority: Major - P3
    • None
    • Affects Version/s: None
    • Component/s: None
    • None
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      The bsoncore.Document#Elements and bsoncore.Array#Values functions return []Element and []Value, respectively. This API offers convenience at the expense of memory efficiency as it requires all Value/Element structs to be allocated at once.

      For use cases where memory management is critical, it might be worth adding Iterator types that return a single Value/Element at a time, thereby limiting the amount of memory that needs to be allocated at one point.

            Assignee:
            Unassigned
            Reporter:
            Divjot Arora (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated: