protected void writeBody(AMF0Body body) throws IOException {
        // write url
        if (body.getTarget() == null) {
            outputStream.writeUTF(NULL_MESSAGE);
        } else {
            outputStream.writeUTF(body.getTarget());
        }
        // write response
        if (body.getResponse() == null) {
            outputStream.writeUTF(NULL_MESSAGE);
        } else {
            outputStream.writeUTF(body.getResponse());
        }
        // Always, always there is four bytes of FF, which is -1 of course
        outputStream.writeInt(-1);
        // Write the data to the output stream
        writeData(body.getValue());
    }