code: public AutoCloseable registerErrorHandler(final EventHandler<Exception> theHandler) {
      this.transport.registerErrorHandler(theHandler);
      return new SubscriptionHandler<>(
          new Exception("Token for finding the error handler subscription"), this.unsubscribeException);
    }
docs: Specify handler for error messages.
  @param theHandler Error handler.
  @return A new subscription object that will cancel its subscription on .close()