Package FAtiMA.Core.util.parsers
Class BinaryStringConverter
java.lang.Object
FAtiMA.Core.util.parsers.BinaryStringConverter
this class contains methods to convert binary data (a byte array) into
a string and vice versa. Currently uses very simple conversion transferring
every byte into 2 characters that describe the hex value of the byte. In order
to improve performance we could use Base64, but this will need some more work as
Android and the regular sun api cannot use the same Base64 encoders/decoders and
we want to keep FatiMA code compatible to both platforms
more info about conversion here:
http://www.javaworld.com/javatips/jw-javatip117.html
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic byte[]decodeStringToBinary(String input) static StringencodeBinaryToString(byte[] input) static voidtest the conversion routines in a standalone program
-
Constructor Details
-
BinaryStringConverter
public BinaryStringConverter()
-
-
Method Details
-
encodeBinaryToString
-
decodeStringToBinary
-
main
test the conversion routines in a standalone program
-