Comments (8)
The first one named parse_zip_read()
takes a std::io::Read
as input. And that is actually the reason why we started using the verb parse
instead of read
, to avoid something like read_zip_read(read: impl Read)
from transit_model.
I think that would be a very nice API ❤️. Note that this is only about the GTFS API, maybe something similar for NTFS and the rest of the public API.
from transit_model.
It's a nice API, yes.
Not sure that from_zip
and from_path
would be used a lot (except for forcing one) as the perf price to have both is low.
At first sight, I would put it in 'polish' category, so my question for working on it is: what is the expected gain on that?
A lot of people would use the lib to do some opensource PT-stuffs that we would consider reusable?
(I compare it with the yak-shaving part of changing all the error-handling that seems more valuable, but I'm absolutely not confident in my judgement/ideas on that).
from transit_model.
yes I agree the gain would be quite minimal, it can maybe bring some reusers and lower the step to use transit_model
(even for CanalTP
), but the time to implement this is also very limited so I guess so trade off is not bad.
For from_zip
and from_path
you're right they are only meant to be used if the default magic
to call the right one is not ok for some specific use case.
from transit_model.
After discussion with @woshilapin:
parse_zip_read(read: impl Read, source_name: &str)
parse_zip_path(path: impl AsRef<Path>)
parse_dir_path(path: impl AsRef<Path>)
parse(path: impl AsRef<Path>)
from transit_model.
no parsing from reader?
from transit_model.
The first one named
parse_zip_read()
takes astd::io::Read
as input. And that is actually the reason why we started using the verbparse
instead ofread
, to avoid something likeread_zip_read(read: impl Read)
what is source_name
?
from transit_model.
it's uggly but it's an artifact since the FileHandler
needs a name for better errors.
from transit_model.
Related Issues (20)
- gtfs2netexfr installation issue HOT 11
- merge-ntfs HOT 2
- gtfs2ntfs : new way to generate prefixes ? HOT 4
- better object duplicate error HOT 4
- Error reading "./ntfs/feed_infos.txt" HOT 3
- Add more flexibility to read inputs HOT 1
- Allow reading GTFS csv files with a flexible option for columns number HOT 2
- Do gtfs2netexfr handle the pathways and levels GTFS extensions ? HOT 1
- FR: prefixes dans les id HOT 4
- Coordonnées WGS HOT 5
- SiteConnection id not unique HOT 2
- [tech] Improve ignored doc-tests
- [gtfs2netexfr] Help needed to pinpoint cause of "unused lines" pruning HOT 3
- transit_model fails to open zipped file. HOT 8
- TransXChange format HOT 1
- ODT : incorrect behavior ? HOT 10
- Problem with cargo install --path gtfs2netexfr HOT 4
- gtfs2netexfr : wrong StopPlaceType for bus HOT 5
- Dependency minidom 0.12 HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from transit_model.