@Test(expected=SerializationException.class) public void serializeNamedMessageWithExtras() throws SerializationException { HashMap<String, Object> extras = new HashMap<>(); extras.put("foo", "bar"); extras.put("baz", 42.0); VehicleMessage message = new NamedVehicleMessage("foo"); message.setExtras(extras); BinaryFormatter.serialize(message); }
public static byte[] serialize(VehicleMessage message) throws SerializationException { return preSerialize(message).toByteArray(); }
BinaryFormatter { public static byte[] serialize(VehicleMessage message) throws SerializationException { return preSerialize(message).toByteArray(); } }
BinaryFormatter { public static byte[] serialize(VehicleMessage message) throws SerializationException { return preSerialize(message).toByteArray(); }  }
BinaryFormatter { public static byte[] serialize(VehicleMessage message) throws SerializationException { return preSerialize(message).toByteArray(); }  static VehicleMessage deserialize(InputStream data); static byte[] serialize(VehicleMessage message); static MessageLite preSerialize(VehicleMessage message); }
BinaryFormatter { public static byte[] serialize(VehicleMessage message) throws SerializationException { return preSerialize(message).toByteArray(); }  static VehicleMessage deserialize(InputStream data); static byte[] serialize(VehicleMessage message); static MessageLite preSerialize(VehicleMessage message);  }