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

ISOUtil.hex2byte should cry when hex string is not hex #505

Open
ar opened this issue Nov 21, 2022 · 1 comment
Open

ISOUtil.hex2byte should cry when hex string is not hex #505

ar opened this issue Nov 21, 2022 · 1 comment

Comments

@ar
Copy link
Member

ar commented Nov 21, 2022

ditto

@agustiza
Copy link

agustiza commented May 9, 2023

Apache commons-codec for example throws a checked DecoderException
https://github.com/apache/commons-codec/blob/master/src/main/java/org/apache/commons/codec/binary/Hex.java#L73

Should jpos hex2byte throw? Should it be a checked or an unchecked exception?

I'd go for a checked exception if breaking backward compatibility is not an issue. If not maybe an unchecked IllegalArgumentException

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