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

Add a convenience function to (de-)serialize from / to files #144

Open
sschuberth opened this issue Aug 26, 2024 · 1 comment
Open

Add a convenience function to (de-)serialize from / to files #144

sschuberth opened this issue Aug 26, 2024 · 1 comment

Comments

@sschuberth
Copy link
Collaborator

Coming from this PR discussion, I wonder whether you guys have any experience with serialization performance from / to files (esp. on the JVM), an whether this library could be a good place to add a (maybe JVM-only) convenience function that uses either the string or the stream API for serialization, maybe even based on file length?

Please let me know what you think @Kantis et al!

@Kantis
Copy link
Owner

Kantis commented Oct 8, 2024

So far this project has only been focused on providing serializers, and utilities for writing serializers. I'm not really against adding it anyway though, as it's a sort-of generally useful companion to KxS. Would it make sense to add as a PR to kotlinx-serialization itself even?

If we choose to go ahead and add it in this project, my only wish is that we keep it tidy. Add the function as an extension to File or Path or something else appropriate, which the consumer would use to create a reference to the file.

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

No branches or pull requests

4 participants
@Kantis @sschuberth and others