-
Notifications
You must be signed in to change notification settings - Fork 60
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
JsonParser needs to have a way to get current event #303
Conversation
@Verdent is this what you are looking for? |
In this way, the implementations of jsonp can compile without implementing this method immediately. I am not sure if this is something we need to be worried about, but I saw there are already other default methods in the interface, so I was following that convention. |
using default is the only way to not break backward compatibility of the interface; w/o that every vendor would be required to implement it ... |
Sure, I was just wondering :-) |
*/ | ||
default public Event currentEvent() { | ||
throw new UnsupportedOperationException(); | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'd move this next to other event related methods (likely after the next()
) and improved javadoc to look more consistent with the rest. Ie return could be updated to @return the event for the current parsing state
Signed-off-by: Jorge Bescos Gascon <jorge.bescos.gascon@oracle.com>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks!
Relates to #282