Is there charset which I could use to save 8bit data? I mean everything which is binary, without changing it content in string?
Asked
Active
Viewed 216 times
1
-
Are you looking for [Base64](http://en.wikipedia.org/wiki/Base64) encoding? – GriffeyDog Mar 07 '13 at 20:38
-
What makes string class that can't hold binary data? Why is that so? – oneat Mar 08 '13 at 17:21
2 Answers
4
The package java.io defines two kinds of classes to save data:
- XXXOutputStream, which are for saving raw 8-bytes data
- XXXWriter, which are for saving Strings
Just use the class from XXXOutputStream family that suits your needs. You don't need a Charset for that.

Cyrille Ka
- 15,328
- 5
- 38
- 58
0
I think you are looking for the datatype byte[]
.

pamphlet
- 2,054
- 1
- 17
- 27
-
-
I'm not sure what you're asking for. You want to use a `String` to manage binary data? Is that it? – pamphlet Mar 07 '13 at 18:41