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

How to customize the time format for json serialization #222

Closed
odiwml147 opened this issue Nov 18, 2022 · 4 comments
Closed

How to customize the time format for json serialization #222

odiwml147 opened this issue Nov 18, 2022 · 4 comments

Comments

@odiwml147
Copy link

No description provided.

@jmluy
Copy link
Contributor

jmluy commented Nov 23, 2022

@odiwml147 do you mean writing existing objects in this project to JSON and converting the time to a specific format?

@odiwml147
Copy link
Author

@odiwml147 do you mean writing existing objects in this project to JSON and converting the time to a specific format?

Yes. For example, MeterValues.req, I want to customize the json format.

@jmluy
Copy link
Contributor

jmluy commented Dec 5, 2022

@odiwml147 do you mean writing existing objects in this project to JSON and converting the time to a specific format?

Yes. For example, MeterValues.req, I want to customize the json format.

It sounds like it's not something specific to this project and you can use something like Jackson and specify the format there?

@odiwml147
Copy link
Author

Thanks.OCPP Server supports the time string in ISO_ZONED_DATE_TIME format,can carry time zone information.This has solved my problem.But,OCPP Client only supports the time string in ISO_INSTANT format,it's just inconvenient to debug

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

2 participants