{
static Random random = new Random();
private void testObject(Object obj) throws Exception
{
ByteArrayOutputStream byteOut = new ByteArrayOutputStream();
JBossObjectOutputStream objout = new JBossObjectOutputStream(byteOut);
LocalMarshalledValue tstValue = new LocalMarshalledValue(obj);
objout.writeObject(tstValue);
objout.flush();
JBossObjectInputStream objinput = new JBossObjectInputStream(new ByteArrayInputStream(byteOut.toByteArray()));
LocalMarshalledValue localValue = (LocalMarshalledValue)objinput.readObject();
Object value = localValue.get();