@Override public Object readObject() throws IOException { try { Object result = in.readObject(); return result; } catch (ClassNotFoundException e) { throw Throwables.propagate(e); } } }
public Object deserialize(Object target) throws Exception{ SerializableWrapper wrapper = (SerializableWrapper)target; byte[] payload = wrapper.getPayload(); ByteArrayInputStream bais = new ByteArrayInputStream(payload); ObjectInputStream ois = new ObjectInputStream(bais); JBossObjectInputStream jbis = new JBossObjectInputStream(ois); Object result = jbis.readObject(); return result; } public void serialize(final Object[] targets) throws Exception
public Object get() throws IOException, ClassNotFoundException { ByteArrayInputStream bais = new ByteArrayInputStream(bytes); JBossObjectInputStream ois = new JBossObjectInputStream(bais); try { return ois.readObject(); } finally { ois.close(); bais.close(); } }
public Object get() throws IOException, ClassNotFoundException { ByteArrayInputStream bais = new ByteArrayInputStream(bytes); JBossObjectInputStream ois = new JBossObjectInputStream(bais); try { return ois.readObject(); } finally { ois.close(); bais.close(); } }