The problem is i have 6 different values to send. They are all primative data type accept the 2 AffineTransforms so thought it would be quicker to send them in a String, then send an object.
Ill try send the values that the AffineTransforms are made up of, and construct them from the values at the other end.
If anyone gets a better idea, let me know. Thanks.
Fortunately the ObjectOutputStream can write primitive data types too. (with writeByte,writeFloat etc...)
ByteArrayOutputStream baos=new ByteArrayOutputStream();
ObjectOutputStream oos=new ObjectOutputStream(baos);
ObjectInputStream ois=new ObjectInputStream(new ByteArrayInputStream(b));
Although if somebody has a better solution, I would like to see.