Sending a serialized object from Android to a servlet using HTTP client

前端 未结 3 470
死守一世寂寞
死守一世寂寞 2021-01-12 13:43

I have tried to create a android application that sends a serialzed object from the phone to a servlet the contents of the object is the input from the user which i will sto

相关标签:
3条回答
  • 2021-01-12 13:54

    Don't use serialization between architectures. Use JSON, XML, or something else that is architecture-neutral.

    0 讨论(0)
  • I second the suggestion of XStream. It is a very nice and easy API. I don't like the Serialization formats XML or JSON though because they are text based. For a more compact serialization format, try ProtoBuf from Google.

    0 讨论(0)
  • 2021-01-12 14:04

    As suggested, use XML or JSON. You can get XStream patched for Android from this blog in order to serialize your objects to XML.

    0 讨论(0)
提交回复
热议问题