Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Please add Range::headers() -> Vec<String> #327

Closed
lucatrv opened this issue Jun 2, 2023 · 0 comments · Fixed by #413
Closed

Please add Range::headers() -> Vec<String> #327

lucatrv opened this issue Jun 2, 2023 · 0 comments · Fixed by #413

Comments

@lucatrv
Copy link
Contributor

lucatrv commented Jun 2, 2023

It is often required to get the first row values of a range deserialized to strings (which are the range headers), so IMHO it would be useful to add a specific helping method headers to Range, which would be equivalent to calling rows().next() and then converting to String. The csv crate has a similar method, see tutoral and documentation.
To convert each DataType value to String, the headers method should call ToString::to_string.

@lucatrv lucatrv changed the title Please add Range::get_headers() -> Vec<Option<String>> Please add headers() -> Vec<Option<String>> Jun 10, 2023
@lucatrv lucatrv changed the title Please add headers() -> Vec<Option<String>> Please add Range::headers() -> Vec<Option<String>> Jun 11, 2023
@lucatrv lucatrv changed the title Please add Range::headers() -> Vec<Option<String>> Please add Range::headers() -> Vec<String> Jun 30, 2023
lucatrv added a commit to lucatrv/calamine that referenced this issue Mar 1, 2024
lucatrv added a commit to lucatrv/calamine that referenced this issue Mar 2, 2024
@tafia tafia closed this as completed in #413 Mar 8, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant