docs: public byte[] toByteArray() {
          try {
              ByteArrayOutputStream baos = new ByteArrayOutputStream();
              ObjectOutputStream oos = new ObjectOutputStream(baos);
              oos.writeObject(this);
              return baos.toByteArray();
          } catch (IOException e) {
              throw E.ioException(e);
          }
      }