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

Usage of Java's LocalTime instead of Kotlinx's #587

Open
Jolanrensen opened this issue Feb 13, 2024 · 1 comment
Open

Usage of Java's LocalTime instead of Kotlinx's #587

Jolanrensen opened this issue Feb 13, 2024 · 1 comment
Labels
enhancement New feature or request good first issue Good issues to pick-up for newcomers
Milestone

Comments

@Jolanrensen
Copy link
Collaborator

Jolanrensen commented Feb 13, 2024

Convert toLocalTime uses Java's LocalTime instead of Kotlinx's.
We should use kotlinx.datetime.LocalTime instead of java.time.LocalTime if we ever want to go multiplatform and just for general consistency.

parse uses even more java.time versions: LocalDate, LocalDateTime, LocalTime,
as well as java.time.format.DateTimeFormatter, but I'm not sure if that can be replaced.

@Jolanrensen Jolanrensen added enhancement New feature or request invalid This issue/PR doesn't seem right labels Feb 13, 2024
@Jolanrensen Jolanrensen changed the title Convert toLocalTime uses Java's LocalTime instead of Kotlinx's Usage of Java's LocalTime instead of Kotlinx's Feb 13, 2024
@Jolanrensen Jolanrensen added this to the Backlog milestone Feb 13, 2024
@devcrocod
Copy link
Contributor

It’s hard for me to say now why java.time is used in parser
I assume that back then kotlinx-datetime was more limited in its capabilities

And so it is necessary to save java.time in the public api, since often use it anyway, but have a similar api for kotlinx-datetime. As for internal things, yea, it would be nice to have kotlinx-datetime

@zaleslaw zaleslaw added good first issue Good issues to pick-up for newcomers and removed invalid This issue/PR doesn't seem right labels Apr 8, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request good first issue Good issues to pick-up for newcomers
Projects
None yet
Development

No branches or pull requests

3 participants