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

Need to receive Complete ZoneId as Scalar #398

Open
KushagraBindal opened this issue May 21, 2021 · 1 comment
Open

Need to receive Complete ZoneId as Scalar #398

KushagraBindal opened this issue May 21, 2021 · 1 comment

Comments

@KushagraBindal
Copy link

For ZoneId I have seen some response on #228

In my case I have applied the above logic and my ZoneId is loaded successfully. But in my case my ZoneId output should contains the rules (ZoneRules) as well which is part of ZoneOffset (extending abstract class ZoneId). But while implementing the logic it is returning id only as the outcome. Can someone please help in extracting the ZoneOffset variables i.e. Rules.

https://docs.oracle.com/javase/8/docs/api/java/time/ZoneId.html
https://docs.oracle.com/javase/8/docs/api/java/time/ZoneOffset.html
https://docs.oracle.com/javase/8/docs/api/java/time/zone/ZoneRules.html

Please suggest.

@kaqqao
Copy link
Member

kaqqao commented Jun 6, 2021

I really don't think this is SPQR or even GraphQL specific question. The way to add a custom scalar is described in the linked issue. Everything beyond that is custom de/serialization logic. So you're really asking how serialize a ZoneId to a String, and I can't help you with that. I know as much about time zones as the next guy. You'll probably have better luck rephrasing your question and asking on StackOverflow.

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