0

Based of other questions here, I've so far learned that objects are written and read through the ObjectOutputStream and ObjectInputSteam, however, what I want to do is put the bytes of an object into a buffer, and socketchannel.write(buffer) to send the bytes. Then read the bytes into a buffer at the other endpoint, and deserialize them back into object.

maxkcy
  • 1
  • 2
  • See if this helps : https://stackoverflow.com/questions/2836646/java-serializable-object-to-byte-array – Arnaud Nov 23 '21 at 07:48

0 Answers0