27282930313233343536
final Packet packet = (Packet)value; if (packet.isEnd()) { writer.writeInt(Packet.END_REQUEST_NUMBER); } else { writer.writeInt(packet.requestNumber()); messageSerializer.write(packet.message(), writer); } } }