I'm working on an android client for a Restful servis. In short I have to send a request whitch looks like this:
<?xml version=\"1.0\" encoding=\"UTF-8\" standalone=\"yes\"?>
<RSAKeyValue xmlns=\"http://ift.tt/uq6naF\">
<Modulus>AKbIANPft2ug1a9Dht9GENdd5HtSdaEngCkbPYlz2syeulOpYJrS9UhRxvfWIlSPB3G1tJEGS5mibQtLcDS9zlnwsg8IoJ8Pq9Dd8XWmBa6oUYeotjA90YhC5F06085yew8nqPTOikdhpmBJT7AAmp9elnkSoVASD0WQnn1KqkCR</Modulus>
<Exponent>AQAB</Exponent>
</RSAKeyValue>
The Modulus and the Exponent are both ByteArrays, but when they go through the Marshaller they look like above. If I pass to the OutputStrem a simple ByteArray, my request looks like this:
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<RSAKeyValue xmlns="http://ift.tt/uq6naF">
<Modulus>[B@b2f43ee0</Modulus>
<Exponent>[B@b2f43f90</Exponent>
</RSAKeyValue>
Whitch the server can't process. So my question is, how to get those Strings whithout the JAXB Marshaller? I have to do this because the server unmarshalls the XML data via JAXB but I can't use JAXB in android.
No comments:
Post a Comment