Skip to content

Expose get_all method in Multimap interface and provide factory method for Multimap #268

Open
@wiktorn

Description

@wiktorn

I attempted to implement fix for osmcode/pyosmium#66 but I'm missing few constructs in libosmium.

  1. Factory methods for Multimaps. There are few approaches that I considered, but neither is without drawbacks:
  • just copy&paste most of MapFactory to Multimap
  • create generic MapFactory that can register and create both Map and Multimap by extending the template with one more argument, but this will break backward compatibility
  • create generic MapFactory as a "meta-template", and create separate factories for Map and MultiMap
  1. Multimap interface doesn't specify get_all method (not all implementing classes implement this) so there is no way to retrieve data using Multimap interface, user would have to bind to specific implementation

  2. (probably not that important) Multimap and Map miss iterator, begin, end triple to make it easy to expose a way to iterate through the (key, value) pairs

  3. multimap/all.hpp is missing multimap/hybrid.hpp #include

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