I'm trying for educational purposes, use the camera of Android to get a photo and send this to a webservice using SOAP.
First, the camera send me a byte[]
array but this isn't serializable and I can't send this to the webservice. Now I'm trying to convert this into a String
(this type is serializable), and in the webservice reconvert this String
into a byte[]
array.
How I can do it?
For example, I'm trying:
request.addProperty("photo", (Arrays.toString((byte[])params[0])));
How I get this String
and convert to the original and exactly byte[]
?
Thanks in advance!