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 []byte Base64 encoding/decoding #122

Open
Qubitium opened this issue Dec 2, 2015 · 1 comment
Open

Need []byte Base64 encoding/decoding #122

Qubitium opened this issue Dec 2, 2015 · 1 comment

Comments

@Qubitium
Copy link

Qubitium commented Dec 2, 2015

JSON byte[] must be transmitted as base64 (default) or some other non-json-violating format since byte[] can contain quotes, colons, brackets symbols used by json spec.

[]byte Serialize:
--> first Base64.encode(in, Base64.DEFAULT)

[]byte Deserialize:
--> Base64.decode(in, Base64.DEFAULT)

Having the above auto support would be great and inline with other JSON parsers.

@Qubitium
Copy link
Author

Qubitium commented Dec 3, 2015

For those that need []byte Base64 support. For now you can create a new Object class that wraps a []byte and use a Custom StrintConverter to do the base64 encoding/decoding.

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

1 participant