Closed medwards closed 6 years ago
Oops I didn't re-read #5 before opening this.
It should be straightforward to rejig my TransitFeed
to have a baseline version that gives iterators on-demand. I'll probably have some layer on top of that that will hold on to transit objects for you and provide helper functions for searching.
I think both are useful, lets move this discussion to #5 though, and talk about what kind of API we want!
Duplicates #5
Feeds generally come in zip archives so provide a helper that will return all iterators or transit objects for a given archive (or folder).
My current version returns a struct of vectors that contain the successfully deserialized structs, and some indexes to help look up structs by id, but that could be deferred to the user to do.
It would be cool if the structs that result from a full archive referenced each other correctly (so a
StopTime
contains a reference to aStop
instead of thestop_id
). I want to fiddle with enums and see if jointly supporting this is possible but its a stretch idea.