code: static public String createString(Operation operation) throws SxmpErrorException, IOException {
          StringWriter sw = new StringWriter(1000);
          SxmpWriter.write(sw, operation);
          return sw.toString();
      }
docs: static public byte[] createByteArray(Operation operation) throws SxmpErrorException, IOException {
  most requests will be ~1000 bytes
  FastByteArrayOutputStream baos = new FastByteArrayOutputStream(1000);
  ByteArrayOutputStream baos = new ByteArrayOutputStream(1000);
  OutputStreamWriter out = new OutputStreamWriter(baos, "ISO-8859-1");
  SxmpWriter.write(out, operation);
  byte[] data = baos.toByteArray();
  out.close();
  baos.close();
  return data;
  }